Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

deps: Audit 10/03 #162

Merged
merged 7 commits into from
Oct 3, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
783 changes: 0 additions & 783 deletions .yarn/releases/yarn-3.2.3.cjs

This file was deleted.

874 changes: 874 additions & 0 deletions .yarn/releases/yarn-3.6.3.cjs

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion .yarnrc.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,4 +8,4 @@ plugins:
- path: .yarn/plugins/@yarnpkg/plugin-interactive-tools.cjs
spec: '@yarnpkg/plugin-interactive-tools'

yarnPath: .yarn/releases/yarn-3.2.3.cjs
yarnPath: .yarn/releases/yarn-3.6.3.cjs
21 changes: 18 additions & 3 deletions docs/add-new-language.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,9 @@ https://github.com/unicode-org/cldr/tree/main/common/annotations

Once you have a locale, add the locale in kebab-case to the following files:

- `packages/core/src/types.ts` (to `Locale` type)
- `packages/core/src/constants.ts` (to `SUPPORTED_LOCALES` constant)
- `packages/core/src/types.ts` (to `Locale` type)
- `packages/generator/src/constants.ts` (to `LOCALE_COUNTRIES` constant)
- `website/src/components/Filters.tsx` (to `LOCALES` constant)
- `.github/workflows/build.yml` (to `locale` matrix)

Expand Down Expand Up @@ -44,7 +45,14 @@ yarn run generate
> for any warnings and errors. If easily fixable, feel free to fix, otherwise report an issue!

If generation completed successfully, you should see the `packages/data/<locale>` directory with a
handful of files.
handful of files. Once created, create the following files:

- `packages/data/<locale>/compact.json.d.ts`
- `packages/data/<locale>/data.json.d.ts`
- `packages/data/<locale>/messages.json.d.ts`
- `packages/data/<locale>/shortcodes/<preset>.json.d.ts`

> These `.d.ts` files can be copied as-is from another locale, like English (en).

## 4) Verify data files

Expand All @@ -62,7 +70,14 @@ Although data files were generated, we should manually verify that the data is c
- Optional: Ensure that shortcodes in `shortcodes/emojibase.raw.json` align with the translations
from `po/<locale>/shortcodes.po`.

## 5) Create pull request
## 5) Update regex patterns

If applicable, when adding a non-Latin locale, you'll most likely need to update our regex pattern
to support the required Unicode range(s).

- `packages/regex/shortcode-native.js` - Add Unicode ranges.

## 6) Create pull request

Once verified, add the following files to git:

Expand Down
1 change: 0 additions & 1 deletion lerna.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
{
"version": "independent",
"npmClient": "yarn",
"useWorkspaces": true,
"command": {
"publish": {
"ignoreChanges": [
Expand Down
26 changes: 13 additions & 13 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -26,26 +26,26 @@
},
"devDependencies": {
"@moonrepo/dev": "^2.0.1",
"@types/jest": "^29.5.2",
"babel-preset-moon": "^2.0.4",
"eslint": "^8.42.0",
"eslint-config-moon": "^2.0.4",
"fast-glob": "^3.2.12",
"@types/jest": "^29.5.5",
"babel-preset-moon": "^2.0.9",
"eslint": "^8.50.0",
"eslint-config-moon": "^2.0.10",
"fast-glob": "^3.3.1",
"fetch-mock-jest": "^1.5.1",
"filesize": "^10.0.7",
"filesize": "^10.1.0",
"gzip-size": "^7.0.0",
"jest": "^29.5.0",
"jest-preset-moon": "^2.0.2",
"lerna": "^6.6.2",
"packemon": "^3.1.1",
"prettier": "^2.8.8",
"jest": "^29.7.0",
"jest-preset-moon": "^2.0.5",
"lerna": "^7.3.0",
"packemon": "^3.2.2",
"prettier": "^3.0.3",
"prettier-config-moon": "^1.1.2",
"tsconfig-moon": "^1.3.0",
"typescript": "^5.1.3"
"typescript": "^5.2.2"
},
"workspaces": [
"packages/*",
"website"
],
"packageManager": "yarn@3.2.3"
"packageManager": "yarn@3.6.3"
}
2 changes: 1 addition & 1 deletion packages/data/bn/messages.raw.json
Original file line number Diff line number Diff line change
Expand Up @@ -431,7 +431,7 @@
},
{
"key": "light-video",
"message": "light, film & video",
"message": "আলো, ফিল্ম এবং ভিডিও",
"order": 71
},
{
Expand Down
12 changes: 6 additions & 6 deletions packages/generator/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -22,17 +22,17 @@
"src/**/*"
],
"dependencies": {
"@types/cheerio": "^0.22.31",
"@types/fs-extra": "^11.0.1",
"@types/node": "^16.18.35",
"@types/node-fetch": "^2.6.4",
"chalk": "^5.2.0",
"@types/cheerio": "^0.22.32",
"@types/fs-extra": "^11.0.2",
"@types/node": "^16.18.57",
"@types/node-fetch": "^2.6.6",
"chalk": "^5.3.0",
"cheerio": "^1.0.0-rc.12",
"emojibase": "workspace:*",
"fs-extra": "^11.1.1",
"kuroshiro": "^1.2.0",
"kuroshiro-analyzer-kuromoji": "^1.1.0",
"node-fetch": "^2.6.11",
"node-fetch": "^2.7.0",
"pofile": "^1.1.4",
"regexgen": "^1.3.0",
"transliteration": "^2.3.5"
Expand Down
4 changes: 2 additions & 2 deletions packages/generator/src/types.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
/* eslint-disable @typescript-eslint/sort-type-union-intersection-members */
/* eslint-disable @typescript-eslint/sort-type-constituents */

import {
Emoticon,
Expand Down Expand Up @@ -151,7 +151,7 @@ export interface EmojiVariation {

export type EmojiVariationMap = HexcodeMap<EmojiVariation>;

export type EmoticonMap = Record<string, string | string[]>;
export type EmoticonMap = Record<string, string[] | string>;

export interface ParsedLine {
comment: string;
Expand Down
122 changes: 64 additions & 58 deletions website/docs/datasets.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -309,62 +309,64 @@ Sorted by original size in ascending order.

| File | Size | Gzipped |
| ----------------- | --------: | -------: |
| zh-hant/data.json | 618.51 kB | 70.87 kB |
| zh/data.json | 644.31 kB | 77.6 kB |
| sv/data.json | 655.71 kB | 76.61 kB |
| nb/data.json | 656.88 kB | 77.11 kB |
| da/data.json | 662.03 kB | 76.79 kB |
| en/data.json | 663.71 kB | 75.37 kB |
| en-gb/data.json | 664.55 kB | 75.76 kB |
| et/data.json | 668.66 kB | 76.04 kB |
| fi/data.json | 672.37 kB | 79.93 kB |
| fr/data.json | 676.05 kB | 76.21 kB |
| ko/data.json | 676.8 kB | 80.19 kB |
| nl/data.json | 677.16 kB | 77.06 kB |
| lt/data.json | 677.57 kB | 79.59 kB |
| pt/data.json | 678.34 kB | 79.25 kB |
| ja/data.json | 682.64 kB | 80.75 kB |
| ms/data.json | 687.95 kB | 76.79 kB |
| hu/data.json | 689.29 kB | 79.48 kB |
| es/data.json | 696.81 kB | 79.55 kB |
| pl/data.json | 697.16 kB | 83.29 kB |
| es-mx/data.json | 697.81 kB | 80.03 kB |
| it/data.json | 700 kB | 81.31 kB |
| de/data.json | 702.08 kB | 84.69 kB |
| ru/data.json | 813.49 kB | 90.15 kB |
| th/data.json | 829.6 kB | 81.09 kB |
| uk/data.json | 832.55 kB | 89.41 kB |
| zh-hant/data.json | 623.94 kB | 71.93 kB |
| zh/data.json | 649.54 kB | 78.48 kB |
| sv/data.json | 661.26 kB | 77.51 kB |
| nb/data.json | 662.25 kB | 77.91 kB |
| da/data.json | 667.38 kB | 77.6 kB |
| en/data.json | 669.12 kB | 76.2 kB |
| en-gb/data.json | 669.78 kB | 76.55 kB |
| et/data.json | 674.23 kB | 76.97 kB |
| fi/data.json | 678.06 kB | 80.86 kB |
| fr/data.json | 681.72 kB | 77.14 kB |
| ko/data.json | 682.57 kB | 81.2 kB |
| nl/data.json | 682.76 kB | 77.89 kB |
| lt/data.json | 683.25 kB | 80.51 kB |
| pt/data.json | 683.99 kB | 80.14 kB |
| ja/data.json | 688.5 kB | 81.74 kB |
| ms/data.json | 693.49 kB | 77.7 kB |
| hu/data.json | 694.91 kB | 80.44 kB |
| es/data.json | 701.52 kB | 80.37 kB |
| pl/data.json | 703.05 kB | 84.31 kB |
| es-mx/data.json | 703.29 kB | 80.9 kB |
| it/data.json | 705.65 kB | 82.21 kB |
| de/data.json | 707.7 kB | 85.53 kB |
| ru/data.json | 820.21 kB | 91.16 kB |
| th/data.json | 837.09 kB | 82.18 kB |
| uk/data.json | 838.77 kB | 90.47 kB |
| bn/data.json | 901.68 kB | 86.84 kB |

</TabItem>
<TabItem value="compact">

| File | Size | Gzipped |
| -------------------- | --------: | -------: |
| zh-hant/compact.json | 432.61 kB | 61.95 kB |
| zh/compact.json | 458.41 kB | 68.35 kB |
| sv/compact.json | 469.8 kB | 67.48 kB |
| nb/compact.json | 470.98 kB | 69.29 kB |
| da/compact.json | 476.12 kB | 67.7 kB |
| en/compact.json | 477.8 kB | 66.55 kB |
| en-gb/compact.json | 478.65 kB | 66.94 kB |
| et/compact.json | 482.76 kB | 66.97 kB |
| fi/compact.json | 486.46 kB | 70.42 kB |
| fr/compact.json | 490.15 kB | 67.17 kB |
| ko/compact.json | 490.89 kB | 70.46 kB |
| nl/compact.json | 491.25 kB | 67.92 kB |
| lt/compact.json | 491.66 kB | 70.12 kB |
| pt/compact.json | 492.44 kB | 70.17 kB |
| ja/compact.json | 496.73 kB | 71.02 kB |
| ms/compact.json | 502.05 kB | 67.89 kB |
| hu/compact.json | 503.38 kB | 69.87 kB |
| es/compact.json | 510.9 kB | 70.55 kB |
| pl/compact.json | 511.25 kB | 73.97 kB |
| es-mx/compact.json | 511.9 kB | 70.97 kB |
| it/compact.json | 514.09 kB | 72.14 kB |
| de/compact.json | 516.18 kB | 74.97 kB |
| ru/compact.json | 627.58 kB | 80.59 kB |
| th/compact.json | 643.69 kB | 71.89 kB |
| uk/compact.json | 646.65 kB | 79.62 kB |
| zh-hant/compact.json | 436.57 kB | 63.09 kB |
| zh/compact.json | 462.18 kB | 69.27 kB |
| sv/compact.json | 473.9 kB | 68.4 kB |
| nb/compact.json | 474.89 kB | 70.08 kB |
| da/compact.json | 480.01 kB | 68.59 kB |
| en/compact.json | 481.76 kB | 67.38 kB |
| en-gb/compact.json | 482.41 kB | 67.76 kB |
| et/compact.json | 486.86 kB | 67.94 kB |
| fi/compact.json | 490.69 kB | 71.4 kB |
| fr/compact.json | 494.35 kB | 68.11 kB |
| ko/compact.json | 495.2 kB | 71.43 kB |
| nl/compact.json | 495.4 kB | 68.77 kB |
| lt/compact.json | 495.88 kB | 71 kB |
| pt/compact.json | 496.62 kB | 71.1 kB |
| ja/compact.json | 501.13 kB | 72.02 kB |
| ms/compact.json | 506.12 kB | 68.78 kB |
| hu/compact.json | 507.55 kB | 70.81 kB |
| es/compact.json | 514.15 kB | 71.38 kB |
| pl/compact.json | 515.68 kB | 75 kB |
| es-mx/compact.json | 515.92 kB | 71.82 kB |
| it/compact.json | 518.28 kB | 73.11 kB |
| de/compact.json | 520.33 kB | 75.84 kB |
| ru/compact.json | 632.84 kB | 81.53 kB |
| th/compact.json | 649.72 kB | 72.93 kB |
| uk/compact.json | 651.41 kB | 80.7 kB |
| bn/compact.json | 714.31 kB | 77.21 kB |

</TabItem>
<TabItem value="shortcodes">
Expand All @@ -383,6 +385,7 @@ Sorted by original size in ascending order.
| ru/shortcodes/emojibase.json | 19.23 kB | 5.93 kB |
| ru/shortcodes/emojibase-native.json | 25.23 kB | 6.56 kB |
| nb/shortcodes/cldr-native.json | 35.13 kB | 6.66 kB |
| da/shortcodes/emojibase-native.json | 36.68 kB | 6.69 kB |
| es-mx/shortcodes/cldr-native.json | 38.87 kB | 8.1 kB |
| es/shortcodes/cldr-native.json | 39.03 kB | 8.05 kB |
| de/shortcodes/cldr-native.json | 41.96 kB | 6.68 kB |
Expand Down Expand Up @@ -413,14 +416,16 @@ Sorted by original size in ascending order.
| et/shortcodes/cldr.json | 142.76 kB | 26.43 kB |
| da/shortcodes/cldr.json | 143.09 kB | 26.15 kB |
| fi/shortcodes/cldr.json | 144.43 kB | 26.77 kB |
| en-gb/shortcodes/emojibase.json | 144.86 kB | 28.54 kB |
| nl/shortcodes/cldr.json | 147.05 kB | 26.84 kB |
| zh/shortcodes/cldr.json | 147.37 kB | 24.83 kB |
| ru/shortcodes/cldr.json | 147.76 kB | 27.41 kB |
| pt/shortcodes/cldr.json | 147.81 kB | 27.03 kB |
| de/shortcodes/cldr.json | 148.09 kB | 27.02 kB |
| ja/shortcodes/cldr-native.json | 148.39 kB | 27.98 kB |
| en-gb/shortcodes/emojibase.json | 148.6 kB | 29.3 kB |
| en/shortcodes/emojibase.json | 149.51 kB | 29.52 kB |
| da/shortcodes/emojibase.json | 150.69 kB | 30.24 kB |
| bn/shortcodes/cldr.json | 151.07 kB | 27.71 kB |
| ms/shortcodes/cldr.json | 154.59 kB | 27.13 kB |
| lt/shortcodes/cldr.json | 154.8 kB | 27.92 kB |
| pl/shortcodes/cldr.json | 154.82 kB | 27.99 kB |
Expand All @@ -435,6 +440,7 @@ Sorted by original size in ascending order.
| en/shortcodes/joypixels.json | 207.8 kB | 33.35 kB |
| th/shortcodes/cldr-native.json | 221.23 kB | 30.44 kB |
| uk/shortcodes/cldr-native.json | 223.98 kB | 32.08 kB |
| bn/shortcodes/cldr-native.json | 261.25 kB | 31.63 kB |

</TabItem>
<TabItem value="messages">
Expand Down Expand Up @@ -465,20 +471,20 @@ Sorted by original size in ascending order.
| lt/messages.json | 6.8 kB | 1.97 kB |
| ru/messages.json | 7.79 kB | 2.31 kB |
| uk/messages.json | 7.86 kB | 2.35 kB |
| bn/messages.json | 8.6 kB | 2.31 kB |
| th/messages.json | 9.05 kB | 2.4 kB |

</TabItem>
<TabItem value="other">

| File | Size | Gzipped |
| ----------------------- | --------: | -------: |
| index.js | 44 B | 62 B |
| meta/groups.json | 3.87 kB | 1.24 kB |
| meta/unicode.json | 68.39 kB | 12.05 kB |
| versions/unicode.json | 89.46 kB | 11.45 kB |
| versions/emoji.json | 89.5 kB | 11.56 kB |
| meta/unicode-names.json | 222.32 kB | 27.68 kB |
| meta/hexcodes.json | 238.07 kB | 26.85 kB |
| meta/groups.json | 3.9 kB | 1.26 kB |
| meta/unicode.json | 68.74 kB | 12.12 kB |
| versions/unicode.json | 89.95 kB | 11.54 kB |
| versions/emoji.json | 89.99 kB | 11.65 kB |
| meta/unicode-names.json | 223.66 kB | 27.88 kB |
| meta/hexcodes.json | 239.23 kB | 27.06 kB |

</TabItem>
</Tabs>
Expand Down
2 changes: 1 addition & 1 deletion website/docs/regex.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -102,7 +102,7 @@ import PROPERTY_EMOJI_REGEX from 'emojibase-regex/property';
| property/emoji.js | 103 B | 93 B |
| property/index.js | 115 B | 102 B |
| emoticon.js | 463 B | 249 B |
| shortcode-native.js | 567 B | 378 B |
| shortcode-native.js | 616 B | 393 B |
| text.js | 1.52 kB | 609 B |
| codepoint/text.js | 1.87 kB | 639 B |
| emoji.js | 10.55 kB | 2.26 kB |
Expand Down
20 changes: 10 additions & 10 deletions website/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -11,21 +11,21 @@
"serve": "docusaurus serve"
},
"dependencies": {
"@docusaurus/core": "^2.4.1",
"@docusaurus/module-type-aliases": "^2.4.1",
"@docusaurus/preset-classic": "^2.4.1",
"@docusaurus/core": "^2.4.3",
"@docusaurus/module-type-aliases": "^2.4.3",
"@docusaurus/preset-classic": "^2.4.3",
"@mdx-js/react": "^1.6.22",
"clsx": "^1.2.1",
"docusaurus-plugin-typedoc-api": "^3.0.0",
"clsx": "^2.0.0",
"docusaurus-plugin-typedoc-api": "^3.0.1",
"emojibase": "workspace:*",
"lodash": "^4.17.21",
"react": "^17.0.2",
"react-dom": "^17.0.2",
"url-search-params-polyfill": "^8.2.3"
"react": "^18.2.0",
"react-dom": "^18.2.0",
"url-search-params-polyfill": "^8.2.5"
},
"devDependencies": {
"@types/lodash": "^4.14.195",
"@types/react": "^17.0.61"
"@types/lodash": "^4.14.199",
"@types/react": "^18.2.24"
},
"browserslist": {
"production": [
Expand Down
2 changes: 1 addition & 1 deletion website/src/components/Filters.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -361,7 +361,7 @@ export default function Filters({
<label htmlFor="subgroup">Subgroup</label>

<select
disabled={disabled || !groupsMeta || !groupsMeta.hierarchy[group] || !subgroupLabels}
disabled={disabled || !groupsMeta?.hierarchy[group] || !subgroupLabels}
id="subgroup"
name="subgroup"
value={subgroup}
Expand Down
Loading