From 0a7ea3506ad5cc3c509ff83818c575d6466c137f Mon Sep 17 00:00:00 2001 From: "Steven R. Loomis" Date: Thu, 5 Sep 2024 09:22:54 -0500 Subject: [PATCH] CLDR-17803 site: add navigation (#4020) --- .github/workflows/site.yml | 2 + docs/site/.gitignore | 3 + docs/site/_config.yml | 1 - docs/site/_headers | 2 + docs/site/_layouts/page.html | 20 +- docs/site/assets/css/page.css | 17 + docs/site/assets/js/build.mjs | 59 +++ docs/site/assets/js/cldrsite.js | 214 ++++++++++ docs/site/development.md | 2 +- docs/site/development/cldr-big-red-switch.md | 6 +- docs/site/development/coding-cldr-tools.md | 5 + docs/site/development/development-process.md | 12 +- .../update-languagescriptregion-subtags.md | 8 +- docs/site/downloads.md | 4 + docs/site/index/corrigenda.md | 4 +- docs/site/package-lock.json | 369 ++++++++++++++++++ docs/site/package.json | 19 + tools/scripts/web/docker/README.md | 4 + 18 files changed, 726 insertions(+), 25 deletions(-) create mode 100644 docs/site/.gitignore create mode 100644 docs/site/_headers create mode 100644 docs/site/assets/js/build.mjs create mode 100644 docs/site/assets/js/cldrsite.js create mode 100644 docs/site/development/coding-cldr-tools.md create mode 100644 docs/site/downloads.md create mode 100644 docs/site/package-lock.json create mode 100644 docs/site/package.json diff --git a/.github/workflows/site.yml b/.github/workflows/site.yml index 87f2021f978..3f7946caf03 100644 --- a/.github/workflows/site.yml +++ b/.github/workflows/site.yml @@ -34,6 +34,8 @@ jobs: bundler-cache: true - name: Setup Jekyll run: 'gem install bundler jekyll kramdown-parser-gfm webrick' + - name: Setup assets + run: 'cd docs/site/assets && npm ci && npm run build' - name: Build cldr.pages.dev run: 'cd docs/site && jekyll build' - name: Pre-install Wrangler diff --git a/docs/site/.gitignore b/docs/site/.gitignore new file mode 100644 index 00000000000..f72d4052c50 --- /dev/null +++ b/docs/site/.gitignore @@ -0,0 +1,3 @@ +/node_modules +/assets/json +/assets/vendor diff --git a/docs/site/_config.yml b/docs/site/_config.yml index ab7eabda587..bc499f53c14 100644 --- a/docs/site/_config.yml +++ b/docs/site/_config.yml @@ -18,4 +18,3 @@ defaults: path: '' values: layout: page - diff --git a/docs/site/_headers b/docs/site/_headers new file mode 100644 index 00000000000..516ed2f1318 --- /dev/null +++ b/docs/site/_headers @@ -0,0 +1,2 @@ +/node_modules/*.js + content-type: application-javascript; charset=utf-8 diff --git a/docs/site/_layouts/page.html b/docs/site/_layouts/page.html index adff46349b0..5961ee550f1 100644 --- a/docs/site/_layouts/page.html +++ b/docs/site/_layouts/page.html @@ -14,23 +14,27 @@
[Unicode]   - - - CLDR Site / {{page.title}} - - + + + This navigation UI is temporary, just to give access to the pages.
-
Home - | Site - Map | Search
+ + +
{{ content }}
+ + + diff --git a/docs/site/assets/css/page.css b/docs/site/assets/css/page.css index 50fbaf70a46..8fef6bdf28a 100644 --- a/docs/site/assets/css/page.css +++ b/docs/site/assets/css/page.css @@ -21,6 +21,23 @@ header > div.icon { flex-grow: 1; } +header .title { + color: white; + font-size: 1.5em; +} + +header .nav, header .nav > div { + display: inline; +} + +header .nav a, header .nav .title { + color: white; +} + +header .nav ul b { + color: yellow; +} + footer { width: 100%; margin-left: auto; diff --git a/docs/site/assets/js/build.mjs b/docs/site/assets/js/build.mjs new file mode 100644 index 00000000000..899911350bd --- /dev/null +++ b/docs/site/assets/js/build.mjs @@ -0,0 +1,59 @@ +// extract site frontmatter, save to json + +import * as fs from "node:fs/promises"; +import * as path from "node:path"; +import { default as process } from "node:process"; +import { default as matter } from "gray-matter"; + +const SKIP_THESE = /(node_modules|\.jekyll-cache)/; + +async function processFile(d, fullPath, out) { + const f = await fs.readFile(fullPath, "utf-8"); + const m = matter(f); + if (m && m.data) { + const { data } = m; + out.all.push({ ...data, fullPath }); + } else { + out.app.push({ fullPath }); // synthesize data? + } +} + +/** process one dirent */ +async function processEntry(d, out, e) { + const fullpath = path.join(d, e.name); + if (SKIP_THESE.test(e.name)) return; + if (e.isDirectory()) { + return await traverse(fullpath, out); + } else if (!e.isFile() || !/\.md$/.test(e.name)) { + return; + } + await processFile(d, fullpath, out); +} + +/** + * @param {string} d path to directory + * @param {object} out output struct + */ +async function traverse(d, out) { + const dirents = await fs.readdir(d, { withFileTypes: true }); + const promises = dirents.map((e) => processEntry(d, out, e)); + return Promise.all(promises); +} + +async function main() { + const out = { + all: [], + dirs: {}, + }; + await fs.mkdir("assets/json/", { recursive: true }); + await traverse(".", out); + await fs.writeFile("assets/json/tree.json", JSON.stringify(out, null, " ")); +} + +main().then( + () => console.log("Done."), + (e) => { + console.error(e); + process.exitCode = 1; + } +); diff --git a/docs/site/assets/js/cldrsite.js b/docs/site/assets/js/cldrsite.js new file mode 100644 index 00000000000..fbfac161684 --- /dev/null +++ b/docs/site/assets/js/cldrsite.js @@ -0,0 +1,214 @@ +const { ref } = Vue; + +// site management + +let myPath = window.location.pathname.slice(1) || "index.html" +if (!/\.html/.test(myPath)) { + myPath = `${myPath}.html`; // cloudflare likes to drop the .html +} + +/** replace a/b/c.md with a/b */ +function path2dir(p) { + const dir = p.split("/").slice(0, -1).join("/"); + return dir; +} + +/** replace a/b/c.md with a/b/c.html */ +function md2html(p) { + return p.replace(/\.md$/, ".html"); +} + +/** replace a/b/c.html with a/b/c.md */ +function html2md(p) { + return p.replace(/\.html$/, ".md"); +} + +/** load and cook the site data */ +async function siteData() { + // load the json + const d = await fetch("/assets/json/tree.json"); + const j = await d.json(); + const { all } = j; + + // 'all' is an array of { title, fullPath } entries. + // Flat list of paths + const allPaths = all.map(({ fullPath }) => fullPath); + // Find all 'directories' (ending with /) + const allDirs = new Set(); + allPaths.forEach((p) => { + const segs = p.split("/").slice(0, -1); // ['', 'dir1'] + for (let n = 0; n <= segs.length; n++) { + // add all parent paths, so: '', dir1, dir1/dir2 etc. + const subpath = segs.slice(0, n).join("/"); + allDirs.add(subpath); + } + }); + j.allDirs = {}; + j.allIndexes = []; + // allDirs: '', index, downloads, etc… + allDirs.forEach((dir) => { + // presumed index page: /downloads -> /downloads.md + // also / -> /index.md + const dirIndex = `${dir || "index"}.md`; + // console.dir({dir, dirIndex}); + if (allPaths.indexOf(dirIndex) !== -1) { + j.allDirs[dir] = { index: dirIndex }; + j.allIndexes.push(dirIndex); + } else { + console.error(`No index page: ${dirIndex}`); + j.allDirs[dir] = {}; + } + j.allDirs[dir].pages = []; + }); + allPaths.forEach((p) => { + const dir = path2dir(p); + j.allDirs[dir].pages.push(p); + }); + // map md -> title + j.title = {}; + all.forEach(({ title, fullPath }) => (j.title[fullPath] = title)); + return j; +} + +const app = Vue.createApp( + { + setup(props) { + const tree = ref({}); + const status = ref(null); + + return { + tree, + status, + }; + }, + mounted() { + const t = this; + siteData().then( + (d) => (t.tree.value = d), + (e) => (t.status = e) + ); + }, + props: { + path: String, + }, + computed: { + mdPath() { + if (this.path) { + return html2md(this.path); + } + return null; + }, + ourDir() { + if (this.path) { + return path2dir(this.path); + } + return ""; + }, + ourIndex() { + if (this.tree?.value) { + // first ARE we an index page? + if (this.tree.value.allIndexes.indexOf(this.mdPath) != -1) { + return this.mdPath; // we are an index + } + return this.tree.value.allDirs[this.ourDir].index; + } + return null; + }, + ourIndexHtml() { + if (this.ourIndex) { + return md2html(this.ourIndex); + } else { + return null; + } + }, + ourIndexTitle() { + if (this.ourIndex && this.tree?.value) { + return this.tree.value.title[this.ourIndex] || this.ourIndex; + } else { + return null; + } + }, + ourTitle() { + if (this.tree?.value) { + if (this.path === "") return this.rootTitle; + return this.tree.value.title[html2md(this.path)]; + } + }, + // title of root + rootTitle() { + return this.tree?.value?.title["index.md"]; + }, + // list of pages for siblings of this dir + siblingPages() { + if (!this.tree?.value) return []; + let dirForPage = this.ourDir; + if (this.tree.value.allIndexes.indexOf(this.mdPath) != -1) { + const dirPages = Object.entries(this.tree?.value?.allDirs) + .filter(([k, {index}]) => index == this.mdPath)[0]; + if (dirPages) { + // our page is an index -so, show the subpages instead of the siblings. + dirForPage = dirPages[0]; // the adjusted index + } + } + let thePages = this.tree?.value?.allDirs[dirForPage].pages ?? []; + if (dirForPage === "") { + thePages = [...thePages, ...this.tree?.value?.allDirs["index"].pages]; + } + const c = new Intl.Collator([]); + return thePages + .map((path) => ({ + path, + html: md2html(path), + title: this.tree.value.title[path] ?? path, + })) + .sort((a, b) => c.compare(a.title, b.title)); + }, + }, + template: `
+
{{ status }}
+
Loading…
+ + {{ rootTitle }} | + + + + + {{ ourIndexTitle }} + + | + + {{ ourTitle }} + +
`, + }, + { + // path of / goes to /index.html + path: myPath, + } +); + +// app.component("CldrPage", { +// setup() {}, +// template: `

Hello

+// `, +// }); + +// app.component("CldrList", { +// setup() {}, +// template: ` +//

Hullo

+// `, +// }); + +app.mount("#nav"); diff --git a/docs/site/development.md b/docs/site/development.md index b19d1fd381b..6b3107bbb66 100644 --- a/docs/site/development.md +++ b/docs/site/development.md @@ -4,4 +4,4 @@ title: Internal Development # Internal Development -![Unicode copyright](https://www.unicode.org/img/hb_notice.gif) \ No newline at end of file +![Unicode copyright](https://www.unicode.org/img/hb_notice.gif) diff --git a/docs/site/development/cldr-big-red-switch.md b/docs/site/development/cldr-big-red-switch.md index 68d6e47a301..f25bf979637 100644 --- a/docs/site/development/cldr-big-red-switch.md +++ b/docs/site/development/cldr-big-red-switch.md @@ -1,5 +1,5 @@ --- -title: CLDR: Big Red Switch +title: 'CLDR: Big Red Switch' --- # CLDR: Big Red Switch @@ -12,7 +12,7 @@ title: CLDR: Big Red Switch ### Trial New Version (Let us know if you need write access!) -(For editors: [List View of BRS](https://cldr.unicode.org/development/cldr-big-red-switch/list-view-of-brs), [Spreadsheet View](https://docs.google.com/spreadsheets/d/1dIOLxKX2gW7BRDVdMBH9qr1GdxpPj8Bc1Pe-02p_92k/edit#gid=0)) +(For editors: [List View of BRS](https://cldr.unicode.org/development/cldr-big-red-switch/list-view-of-brs), [Spreadsheet View](https://docs.google.com/spreadsheets/d/1dIOLxKX2gW7BRDVdMBH9qr1GdxpPj8Bc1Pe-02p_92k/edit#gid=0)) ## Contributor Message @@ -28,4 +28,4 @@ However, names are not automatically entered there, since some people may not wi 2. e\-mail that list **on BCC:** the above message with a subject line of "\[CLDR X.Y Contributor Message]", and a request to please keep the subject line intact. 3. Then, the subject line can be used to filter/locate the contributor requests. -![Unicode copyright](https://www.unicode.org/img/hb_notice.gif) \ No newline at end of file +![Unicode copyright](https://www.unicode.org/img/hb_notice.gif) diff --git a/docs/site/development/coding-cldr-tools.md b/docs/site/development/coding-cldr-tools.md new file mode 100644 index 00000000000..d5af3a51403 --- /dev/null +++ b/docs/site/development/coding-cldr-tools.md @@ -0,0 +1,5 @@ +--- +title: "Coding CLDR Tools" +--- + +Pages concerning coding CLDR Tools diff --git a/docs/site/development/development-process.md b/docs/site/development/development-process.md index 93ec64d24f9..d48ae78ae53 100644 --- a/docs/site/development/development-process.md +++ b/docs/site/development/development-process.md @@ -11,9 +11,9 @@ title: Handling Tickets (bugs/enhancements) ### Pre\-Assessment for Weekly Triage -*There is a pre\-assessment of tickets to make the triage flow faster. This pre\-assessment should be done off\-line prior to every Wednesday in time for the TC triage. DO NOT fix a bug until it's been approved by the TC in triage.* +*There is a pre\-assessment of tickets to make the triage flow faster. This pre\-assessment should be done off\-line prior to every Wednesday in time for the TC triage. DO NOT fix a bug until it's been approved by the TC in triage.* -*The triage is a part of Monday and Wednesday meetings.* +*The triage is a part of Monday and Wednesday meetings.* 1. Ticket comes in, and the default is **Priority**\=assess, **Milestone**\=to\-assess 1. If user sets Component (we always should!) automatically assigns the Owner based on the component owner for the pre\-assessment. \[Add link to Components and Owner] @@ -22,7 +22,7 @@ title: Handling Tickets (bugs/enhancements) 2. All TC members, look at [To\-assess by Owner / Component](https://unicode.org/cldr/trac/report/100) before each triage day. 1. Assess the **to\-assess** tickets assigned to you. 2. You can close bugs as duplicate or if user misunderstanding if it is very clear without committee discussion. Always include a comment if you close the ticket. - 3. If the component is wrong, change component and reassign to the right component owner. + 3. If the component is wrong, change component and reassign to the right component owner. 1. (TODO: copy components to that page, and add notes to clarify; if possible, link to list of components \+ descriptions at top of new ticket). http://cldr.unicode.org/index/bug\-reports 4. Add your assessment information: 1. Change **Milestone** to “assessed” @@ -36,7 +36,7 @@ title: Handling Tickets (bugs/enhancements) 1. Follow the triage practice by making changes to all fields, Owner, Component, Priority, … or closing the ticket. 2. Update Milestone to one of the following (VV \= the current milestone, eg 35\) 1. **VV** if the (new) Owner agrees that it is a priority — and has some level of commitment to fix during release - 2. **VV\-optional**, eg 35\-optional + 2. **VV\-optional**, eg 35\-optional 1. A **future** milestone 3. Triage decides whether it's for Design or Accepted. (**design** indicates for more discussion needed. See design section below.). 5. Other ticket handling practices: @@ -48,7 +48,7 @@ title: Handling Tickets (bugs/enhancements) ### Design -When a ticket is in design, the owner is responsible for bringing back to the committee to approve the design before any lasting (aside from tests, instrumentation, etc.) work is checked in. +When a ticket is in design, the owner is responsible for bringing back to the committee to approve the design before any lasting (aside from tests, instrumentation, etc.) work is checked in. 1. The Owner is responsible for documenting the results of the discussion in the TC in comments in the ticket. 2. The Reviewer is responsible for verifying that the design was accepted by the TC before accepting. @@ -166,4 +166,4 @@ If there is a test failure that is due to a bug that cannot be fixed right now ( 1. The future folder tickets are moved to the discuss folder 2. Unscheduled tickets (with no release number) are re\-evaluated. -![Unicode copyright](https://www.unicode.org/img/hb_notice.gif) \ No newline at end of file +![Unicode copyright](https://www.unicode.org/img/hb_notice.gif) diff --git a/docs/site/development/updating-codes/update-languagescriptregion-subtags.md b/docs/site/development/updating-codes/update-languagescriptregion-subtags.md index 51b35bd05e7..54dfd70181d 100644 --- a/docs/site/development/updating-codes/update-languagescriptregion-subtags.md +++ b/docs/site/development/updating-codes/update-languagescriptregion-subtags.md @@ -22,7 +22,7 @@ title: Update Language/Script/Region Subtags - Save as {CLDR}/tools/cldr\-code/src/main/resources/org/unicode/cldr/util/data/language\-subtag\-registry - Go to http://data.iana.org/TLD/ - Right\-click on [tlds\-alpha\-by\-domain.txt](http://data.iana.org/TLD/tlds-alpha-by-domain.txt) save as - - {{CLDR}/tools/cldr\-code/src/main/resources/org/unicode/cldr/util//data/[tlds\-alpha\-by\-domain.txt](http://data.iana.org/TLD/tlds-alpha-by-domain.txt) + - {CLDR}/tools/cldr\-code/src/main/resources/org/unicode/cldr/util//data/[tlds\-alpha\-by\-domain.txt](http://data.iana.org/TLD/tlds-alpha-by-domain.txt) - If using Eclipse, refresh the files - Diff each with the old copy to check for consistency - Certain of the steps below require that you note certain differences. @@ -65,9 +65,9 @@ title: Update Language/Script/Region Subtags - ~~Todo: fix GenerateEnums around Utility.getUTF8Data("territory\_codes.txt");~~ - Then run GenerateEnums.java, and make sure it completes with no exceptions. Fix any necessary results. - Missing alpha3 for: xx, or "In RFC 4646 but not in CLDR: \[EA, EZ, IC, UN]" - - Ignore if it is {EA, EZ, IC, UN} Otherwise means you needed to do "For new territories" above + - Ignore if it is `{EA, EZ, IC, UN}` Otherwise means you needed to do "For new territories" above - Collision with: xx - - Ignore if it is {{MM, BU, 104}, {TP, TL, 626}, {YU, CS, 891}, {ZR, CD, 180}} + - Ignore if it is `{MM, BU, 104}, {TP, TL, 626}, {YU, CS, 891}, {ZR, CD, 180}` - Not in World but in CLDR: \[002, 003, 005, 009, 011, 013, 014, 015, 017\... Ignore 3\-digit coes - (should have exception lists in tool for the Ignore's above) - Run **ConsoleCheckCLDR \-f en \-z FINAL\_TESTING \-e** @@ -79,4 +79,4 @@ title: Update Language/Script/Region Subtags - You may also have to fix the coverageLevels.txt file for an error like: - Error: (TestCoverageLevel.java:604\) Comprehensive \& no exception for path \=\> //ldml/localeDisplayNames/territories/territory\[@type\="202"] -![Unicode copyright](https://www.unicode.org/img/hb_notice.gif) \ No newline at end of file +![Unicode copyright](https://www.unicode.org/img/hb_notice.gif) diff --git a/docs/site/downloads.md b/docs/site/downloads.md new file mode 100644 index 00000000000..c0ba26dd517 --- /dev/null +++ b/docs/site/downloads.md @@ -0,0 +1,4 @@ +--- +title: CLDR Downloads +--- + diff --git a/docs/site/index/corrigenda.md b/docs/site/index/corrigenda.md index 1359fe007ae..7da7241fe63 100644 --- a/docs/site/index/corrigenda.md +++ b/docs/site/index/corrigenda.md @@ -1,5 +1,5 @@ --- -title: CLDR Releases/Downloads +title: Corrigenda and Errata --- # Corrigenda and Errata @@ -15,4 +15,4 @@ At this time, there is only one Corrigendum: Each release of CLDR is a stable release and may be used as reference material or cited as a normative reference by other specifications. Each version, once published, is absolutely stable and will never change. However, implementations may - and are encouraged to - apply fixes for corrigenda and errata to their use of an appropriate version. For example, an implementation may claim conformance to "CLDR 1.3, as amended by Corrigendum 1". -![Unicode copyright](https://www.unicode.org/img/hb_notice.gif) \ No newline at end of file +![Unicode copyright](https://www.unicode.org/img/hb_notice.gif) diff --git a/docs/site/package-lock.json b/docs/site/package-lock.json new file mode 100644 index 00000000000..01a0940a8a0 --- /dev/null +++ b/docs/site/package-lock.json @@ -0,0 +1,369 @@ +{ + "name": "@unicode-org/cldr-site", + "version": "1.0.0", + "lockfileVersion": 3, + "requires": true, + "packages": { + "": { + "name": "@unicode-org/cldr-site", + "version": "1.0.0", + "hasInstallScript": true, + "license": "Unicode-3.0", + "dependencies": { + "gray-matter": "^4.0.3", + "vue": "^3.5.0" + } + }, + "node_modules/@babel/helper-string-parser": { + "version": "7.24.8", + "resolved": "https://registry.npmjs.org/@babel/helper-string-parser/-/helper-string-parser-7.24.8.tgz", + "integrity": "sha512-pO9KhhRcuUyGnJWwyEgnRJTSIZHiT+vMD0kPeD+so0l7mxkMT19g3pjY9GTnHySck/hDzq+dtW/4VgnMkippsQ==", + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/helper-validator-identifier": { + "version": "7.24.7", + "resolved": "https://registry.npmjs.org/@babel/helper-validator-identifier/-/helper-validator-identifier-7.24.7.tgz", + "integrity": "sha512-rR+PBcQ1SMQDDyF6X0wxtG8QyLCgUB0eRAGguqRLfkCA87l7yAP7ehq8SNj96OOGTO8OBV70KhuFYcIkHXOg0w==", + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/parser": { + "version": "7.25.6", + "resolved": "https://registry.npmjs.org/@babel/parser/-/parser-7.25.6.tgz", + "integrity": "sha512-trGdfBdbD0l1ZPmcJ83eNxB9rbEax4ALFTF7fN386TMYbeCQbyme5cOEXQhbGXKebwGaB/J52w1mrklMcbgy6Q==", + "dependencies": { + "@babel/types": "^7.25.6" + }, + "bin": { + "parser": "bin/babel-parser.js" + }, + "engines": { + "node": ">=6.0.0" + } + }, + "node_modules/@babel/types": { + "version": "7.25.6", + "resolved": "https://registry.npmjs.org/@babel/types/-/types-7.25.6.tgz", + "integrity": "sha512-/l42B1qxpG6RdfYf343Uw1vmDjeNhneUXtzhojE7pDgfpEypmRhI6j1kr17XCVv4Cgl9HdAiQY2x0GwKm7rWCw==", + "dependencies": { + "@babel/helper-string-parser": "^7.24.8", + "@babel/helper-validator-identifier": "^7.24.7", + "to-fast-properties": "^2.0.0" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@jridgewell/sourcemap-codec": { + "version": "1.5.0", + "resolved": "https://registry.npmjs.org/@jridgewell/sourcemap-codec/-/sourcemap-codec-1.5.0.tgz", + "integrity": "sha512-gv3ZRaISU3fjPAgNsriBRqGWQL6quFx04YMPW/zD8XMLsU32mhCCbfbO6KZFLjvYpCZ8zyDEgqsgf+PwPaM7GQ==" + }, + "node_modules/@vue/compiler-core": { + "version": "3.5.0", + "resolved": "https://registry.npmjs.org/@vue/compiler-core/-/compiler-core-3.5.0.tgz", + "integrity": "sha512-ja7cpqAOfw4tyFAxgBz70Z42miNDeaqTxExTsnXDLomRpqfyCgyvZvFp482fmsElpfvsoMJUsvzULhvxUTW6Iw==", + "dependencies": { + "@babel/parser": "^7.25.3", + "@vue/shared": "3.5.0", + "entities": "^4.5.0", + "estree-walker": "^2.0.2", + "source-map-js": "^1.2.0" + } + }, + "node_modules/@vue/compiler-dom": { + "version": "3.5.0", + "resolved": "https://registry.npmjs.org/@vue/compiler-dom/-/compiler-dom-3.5.0.tgz", + "integrity": "sha512-xYjUybWZXl+1R/toDy815i4PbeehL2hThiSGkcpmIOCy2HoYyeeC/gAWK/Y/xsoK+GSw198/T5O31bYuQx5uvQ==", + "dependencies": { + "@vue/compiler-core": "3.5.0", + "@vue/shared": "3.5.0" + } + }, + "node_modules/@vue/compiler-sfc": { + "version": "3.5.0", + "resolved": "https://registry.npmjs.org/@vue/compiler-sfc/-/compiler-sfc-3.5.0.tgz", + "integrity": "sha512-B9DgLtrqok2GLuaFjLlSL15ZG3ZDBiitUH1ecex9guh/ZcA5MCdwuVE6nsfQxktuZY/QY0awJ35/ripIviCQTQ==", + "dependencies": { + "@babel/parser": "^7.25.3", + "@vue/compiler-core": "3.5.0", + "@vue/compiler-dom": "3.5.0", + "@vue/compiler-ssr": "3.5.0", + "@vue/shared": "3.5.0", + "estree-walker": "^2.0.2", + "magic-string": "^0.30.11", + "postcss": "^8.4.44", + "source-map-js": "^1.2.0" + } + }, + "node_modules/@vue/compiler-ssr": { + "version": "3.5.0", + "resolved": "https://registry.npmjs.org/@vue/compiler-ssr/-/compiler-ssr-3.5.0.tgz", + "integrity": "sha512-E263QZmA1dqRd7c3u/sWTLRMpQOT0aZ8av/L9SoD/v/BVMZaWFHPUUBswS+bzrfvG2suJF8vSLKx6k6ba5SUdA==", + "dependencies": { + "@vue/compiler-dom": "3.5.0", + "@vue/shared": "3.5.0" + } + }, + "node_modules/@vue/reactivity": { + "version": "3.5.0", + "resolved": "https://registry.npmjs.org/@vue/reactivity/-/reactivity-3.5.0.tgz", + "integrity": "sha512-Ew3F5riP3B3ZDGjD3ZKb9uZylTTPSqt8hAf4sGbvbjrjDjrFb3Jm15Tk1/w7WwTE5GbQ2Qhwxx1moc9hr8A/OQ==", + "dependencies": { + "@vue/shared": "3.5.0" + } + }, + "node_modules/@vue/runtime-core": { + "version": "3.5.0", + "resolved": "https://registry.npmjs.org/@vue/runtime-core/-/runtime-core-3.5.0.tgz", + "integrity": "sha512-mQyW0F9FaNRdt8ghkAs+BMG3iQ7LGgWKOpkzUzR5AI5swPNydHGL5hvVTqFaeMzwecF1g0c86H4yFQsSxJhH1w==", + "dependencies": { + "@vue/reactivity": "3.5.0", + "@vue/shared": "3.5.0" + } + }, + "node_modules/@vue/runtime-dom": { + "version": "3.5.0", + "resolved": "https://registry.npmjs.org/@vue/runtime-dom/-/runtime-dom-3.5.0.tgz", + "integrity": "sha512-NQQXjpdXgyYVJ2M56FJ+lSJgZiecgQ2HhxhnQBN95FymXegRNY/N2htI7vOTwpP75pfxhIeYOJ8mE8sW8KAW6A==", + "dependencies": { + "@vue/reactivity": "3.5.0", + "@vue/runtime-core": "3.5.0", + "@vue/shared": "3.5.0", + "csstype": "^3.1.3" + } + }, + "node_modules/@vue/server-renderer": { + "version": "3.5.0", + "resolved": "https://registry.npmjs.org/@vue/server-renderer/-/server-renderer-3.5.0.tgz", + "integrity": "sha512-HyDIFUg+l7L4PKrEnJlCYWHUOlm6NxZhmSxIefZ5MTYjkIPfDfkwhX7hqxAQHfgIAE1uLMLQZwuNR/ozI0NhZg==", + "dependencies": { + "@vue/compiler-ssr": "3.5.0", + "@vue/shared": "3.5.0" + }, + "peerDependencies": { + "vue": "3.5.0" + } + }, + "node_modules/@vue/shared": { + "version": "3.5.0", + "resolved": "https://registry.npmjs.org/@vue/shared/-/shared-3.5.0.tgz", + "integrity": "sha512-m9IgiteBpCkFaMNwCOBkFksA7z8QiKc30ooRuoXWUFRDu0mGyNPlFHmbncF0/Kra1RlX8QrmBbRaIxVvikaR0Q==" + }, + "node_modules/argparse": { + "version": "1.0.10", + "resolved": "https://registry.npmjs.org/argparse/-/argparse-1.0.10.tgz", + "integrity": "sha512-o5Roy6tNG4SL/FOkCAN6RzjiakZS25RLYFrcMttJqbdd8BWrnA+fGz57iN5Pb06pvBGvl5gQ0B48dJlslXvoTg==", + "dependencies": { + "sprintf-js": "~1.0.2" + } + }, + "node_modules/csstype": { + "version": "3.1.3", + "resolved": "https://registry.npmjs.org/csstype/-/csstype-3.1.3.tgz", + "integrity": "sha512-M1uQkMl8rQK/szD0LNhtqxIPLpimGm8sOBwU7lLnCpSbTyY3yeU1Vc7l4KT5zT4s/yOxHH5O7tIuuLOCnLADRw==" + }, + "node_modules/entities": { + "version": "4.5.0", + "resolved": "https://registry.npmjs.org/entities/-/entities-4.5.0.tgz", + "integrity": "sha512-V0hjH4dGPh9Ao5p0MoRY6BVqtwCjhz6vI5LT8AJ55H+4g9/4vbHx1I54fS0XuclLhDHArPQCiMjDxjaL8fPxhw==", + "engines": { + "node": ">=0.12" + }, + "funding": { + "url": "https://github.com/fb55/entities?sponsor=1" + } + }, + "node_modules/esprima": { + "version": "4.0.1", + "resolved": "https://registry.npmjs.org/esprima/-/esprima-4.0.1.tgz", + "integrity": "sha512-eGuFFw7Upda+g4p+QHvnW0RyTX/SVeJBDM/gCtMARO0cLuT2HcEKnTPvhjV6aGeqrCB/sbNop0Kszm0jsaWU4A==", + "bin": { + "esparse": "bin/esparse.js", + "esvalidate": "bin/esvalidate.js" + }, + "engines": { + "node": ">=4" + } + }, + "node_modules/estree-walker": { + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/estree-walker/-/estree-walker-2.0.2.tgz", + "integrity": "sha512-Rfkk/Mp/DL7JVje3u18FxFujQlTNR2q6QfMSMB7AvCBx91NGj/ba3kCfza0f6dVDbw7YlRf/nDrn7pQrCCyQ/w==" + }, + "node_modules/extend-shallow": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/extend-shallow/-/extend-shallow-2.0.1.tgz", + "integrity": "sha512-zCnTtlxNoAiDc3gqY2aYAWFx7XWWiasuF2K8Me5WbN8otHKTUKBwjPtNpRs/rbUZm7KxWAaNj7P1a/p52GbVug==", + "dependencies": { + "is-extendable": "^0.1.0" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/gray-matter": { + "version": "4.0.3", + "resolved": "https://registry.npmjs.org/gray-matter/-/gray-matter-4.0.3.tgz", + "integrity": "sha512-5v6yZd4JK3eMI3FqqCouswVqwugaA9r4dNZB1wwcmrD02QkV5H0y7XBQW8QwQqEaZY1pM9aqORSORhJRdNK44Q==", + "dependencies": { + "js-yaml": "^3.13.1", + "kind-of": "^6.0.2", + "section-matter": "^1.0.0", + "strip-bom-string": "^1.0.0" + }, + "engines": { + "node": ">=6.0" + } + }, + "node_modules/is-extendable": { + "version": "0.1.1", + "resolved": "https://registry.npmjs.org/is-extendable/-/is-extendable-0.1.1.tgz", + "integrity": "sha512-5BMULNob1vgFX6EjQw5izWDxrecWK9AM72rugNr0TFldMOi0fj6Jk+zeKIt0xGj4cEfQIJth4w3OKWOJ4f+AFw==", + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/js-yaml": { + "version": "3.14.1", + "resolved": "https://registry.npmjs.org/js-yaml/-/js-yaml-3.14.1.tgz", + "integrity": "sha512-okMH7OXXJ7YrN9Ok3/SXrnu4iX9yOk+25nqX4imS2npuvTYDmo/QEZoqwZkYaIDk3jVvBOTOIEgEhaLOynBS9g==", + "dependencies": { + "argparse": "^1.0.7", + "esprima": "^4.0.0" + }, + "bin": { + "js-yaml": "bin/js-yaml.js" + } + }, + "node_modules/kind-of": { + "version": "6.0.3", + "resolved": "https://registry.npmjs.org/kind-of/-/kind-of-6.0.3.tgz", + "integrity": "sha512-dcS1ul+9tmeD95T+x28/ehLgd9mENa3LsvDTtzm3vyBEO7RPptvAD+t44WVXaUjTBRcrpFeFlC8WCruUR456hw==", + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/magic-string": { + "version": "0.30.11", + "resolved": "https://registry.npmjs.org/magic-string/-/magic-string-0.30.11.tgz", + "integrity": "sha512-+Wri9p0QHMy+545hKww7YAu5NyzF8iomPL/RQazugQ9+Ez4Ic3mERMd8ZTX5rfK944j+560ZJi8iAwgak1Ac7A==", + "dependencies": { + "@jridgewell/sourcemap-codec": "^1.5.0" + } + }, + "node_modules/nanoid": { + "version": "3.3.7", + "resolved": "https://registry.npmjs.org/nanoid/-/nanoid-3.3.7.tgz", + "integrity": "sha512-eSRppjcPIatRIMC1U6UngP8XFcz8MQWGQdt1MTBQ7NaAmvXDfvNxbvWV3x2y6CdEUciCSsDHDQZbhYaB8QEo2g==", + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/ai" + } + ], + "bin": { + "nanoid": "bin/nanoid.cjs" + }, + "engines": { + "node": "^10 || ^12 || ^13.7 || ^14 || >=15.0.1" + } + }, + "node_modules/picocolors": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/picocolors/-/picocolors-1.1.0.tgz", + "integrity": "sha512-TQ92mBOW0l3LeMeyLV6mzy/kWr8lkd/hp3mTg7wYK7zJhuBStmGMBG0BdeDZS/dZx1IukaX6Bk11zcln25o1Aw==" + }, + "node_modules/postcss": { + "version": "8.4.44", + "resolved": "https://registry.npmjs.org/postcss/-/postcss-8.4.44.tgz", + "integrity": "sha512-Aweb9unOEpQ3ezu4Q00DPvvM2ZTUitJdNKeP/+uQgr1IBIqu574IaZoURId7BKtWMREwzKa9OgzPzezWGPWFQw==", + "funding": [ + { + "type": "opencollective", + "url": "https://opencollective.com/postcss/" + }, + { + "type": "tidelift", + "url": "https://tidelift.com/funding/github/npm/postcss" + }, + { + "type": "github", + "url": "https://github.com/sponsors/ai" + } + ], + "dependencies": { + "nanoid": "^3.3.7", + "picocolors": "^1.0.1", + "source-map-js": "^1.2.0" + }, + "engines": { + "node": "^10 || ^12 || >=14" + } + }, + "node_modules/section-matter": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/section-matter/-/section-matter-1.0.0.tgz", + "integrity": "sha512-vfD3pmTzGpufjScBh50YHKzEu2lxBWhVEHsNGoEXmCmn2hKGfeNLYMzCJpe8cD7gqX7TJluOVpBkAequ6dgMmA==", + "dependencies": { + "extend-shallow": "^2.0.1", + "kind-of": "^6.0.0" + }, + "engines": { + "node": ">=4" + } + }, + "node_modules/source-map-js": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/source-map-js/-/source-map-js-1.2.0.tgz", + "integrity": "sha512-itJW8lvSA0TXEphiRoawsCksnlf8SyvmFzIhltqAHluXd88pkCd+cXJVHTDwdCr0IzwptSm035IHQktUu1QUMg==", + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/sprintf-js": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/sprintf-js/-/sprintf-js-1.0.3.tgz", + "integrity": "sha512-D9cPgkvLlV3t3IzL0D0YLvGA9Ahk4PcvVwUbN0dSGr1aP0Nrt4AEnTUbuGvquEC0mA64Gqt1fzirlRs5ibXx8g==" + }, + "node_modules/strip-bom-string": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/strip-bom-string/-/strip-bom-string-1.0.0.tgz", + "integrity": "sha512-uCC2VHvQRYu+lMh4My/sFNmF2klFymLX1wHJeXnbEJERpV/ZsVuonzerjfrGpIGF7LBVa1O7i9kjiWvJiFck8g==", + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/to-fast-properties": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/to-fast-properties/-/to-fast-properties-2.0.0.tgz", + "integrity": "sha512-/OaKK0xYrs3DmxRYqL/yDc+FxFUVYhDlXMhRmv3z915w2HF1tnN1omB354j8VUGO/hbRzyD6Y3sA7v7GS/ceog==", + "engines": { + "node": ">=4" + } + }, + "node_modules/vue": { + "version": "3.5.0", + "resolved": "https://registry.npmjs.org/vue/-/vue-3.5.0.tgz", + "integrity": "sha512-1t70favYoFijwfWJ7g81aTd32obGaAnKYE9FNyMgnEzn3F4YncRi/kqAHHKloG0VXTD8vBYMhbgLKCA+Sk6QDw==", + "dependencies": { + "@vue/compiler-dom": "3.5.0", + "@vue/compiler-sfc": "3.5.0", + "@vue/runtime-dom": "3.5.0", + "@vue/server-renderer": "3.5.0", + "@vue/shared": "3.5.0" + }, + "peerDependencies": { + "typescript": "*" + }, + "peerDependenciesMeta": { + "typescript": { + "optional": true + } + } + } + } +} diff --git a/docs/site/package.json b/docs/site/package.json new file mode 100644 index 00000000000..3eac2b7b0ac --- /dev/null +++ b/docs/site/package.json @@ -0,0 +1,19 @@ +{ + "name": "@unicode-org/cldr-site", + "version": "1.0.0", + "main": "index.js", + "scripts": { + "test": "echo \"Error: no test specified\" && exit 1", + "build": "node assets/js/build.mjs", + "postinstall": "mkdir -p assets/vendor ; cp node_modules/vue/dist/vue.global.prod.js assets/vendor" + }, + "keywords": [], + "author": "Steven R. Loomis ", + "license": "Unicode-3.0", + "description": "Static Assets for CLDR Site", + "private": true, + "dependencies": { + "gray-matter": "^4.0.3", + "vue": "^3.5.0" + } +} diff --git a/tools/scripts/web/docker/README.md b/tools/scripts/web/docker/README.md index 73d23405b86..7a248e1bf57 100644 --- a/tools/scripts/web/docker/README.md +++ b/tools/scripts/web/docker/README.md @@ -1,5 +1,9 @@ # Docker for CLDR Site +## Installing assets + +1. run `npm i` and `npm run build` in `docs/site` + ## Previewing locally 1. install https://docker.io