@magmamath/students-features 0.6.6 → 0.6.7-rc.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.editorconfig +15 -0
- package/.eslintignore +2 -0
- package/.eslintrc +22 -0
- package/.gitattributes +3 -0
- package/.github/actions/setup/action.yml +37 -0
- package/.github/workflows/ci.yml +73 -0
- package/.gitignore +84 -0
- package/.npmrc +3 -0
- package/.nvmrc +1 -0
- package/.prettierrc +11 -0
- package/.release-it.json +17 -0
- package/.watchmanconfig +1 -0
- package/.yarn/plugins/@yarnpkg/plugin-interactive-tools.cjs +541 -0
- package/.yarn/plugins/@yarnpkg/plugin-workspace-tools.cjs +28 -0
- package/.yarn/releases/yarn-3.6.1.cjs +874 -0
- package/babel.config.js +5 -0
- package/bob.config.js +25 -0
- package/dist/commonjs/shared/translation/constants.js +5 -1
- package/dist/commonjs/shared/translation/constants.js.map +1 -1
- package/dist/commonjs/shared/translation/localization/ca.json +22 -0
- package/dist/commonjs/shared/translation/localization/sct.json +22 -0
- package/dist/commonjs/shared/translation/types.js +2 -0
- package/dist/commonjs/shared/translation/types.js.map +1 -1
- package/dist/module/shared/translation/constants.js +5 -1
- package/dist/module/shared/translation/constants.js.map +1 -1
- package/dist/module/shared/translation/localization/ca.json +22 -0
- package/dist/module/shared/translation/localization/sct.json +22 -0
- package/dist/module/shared/translation/types.js +2 -0
- package/dist/module/shared/translation/types.js.map +1 -1
- package/dist/typescript/commonjs/shared/translation/constants.d.ts +44 -0
- package/dist/typescript/commonjs/shared/translation/constants.d.ts.map +1 -1
- package/dist/typescript/commonjs/shared/translation/types.d.ts +3 -1
- package/dist/typescript/commonjs/shared/translation/types.d.ts.map +1 -1
- package/dist/typescript/commonjs/shared/translation/validation.types.d.ts +5 -1
- package/dist/typescript/commonjs/shared/translation/validation.types.d.ts.map +1 -1
- package/dist/typescript/module/shared/translation/constants.d.ts +44 -0
- package/dist/typescript/module/shared/translation/constants.d.ts.map +1 -1
- package/dist/typescript/module/shared/translation/types.d.ts +3 -1
- package/dist/typescript/module/shared/translation/types.d.ts.map +1 -1
- package/dist/typescript/module/shared/translation/validation.types.d.ts +5 -1
- package/dist/typescript/module/shared/translation/validation.types.d.ts.map +1 -1
- package/example/app.json +30 -0
- package/example/assets/adaptive-icon.png +0 -0
- package/example/assets/favicon.png +0 -0
- package/example/assets/icon.png +0 -0
- package/example/assets/splash-icon.png +0 -0
- package/example/babel.config.js +28 -0
- package/example/index.js +8 -0
- package/example/metro.config.js +18 -0
- package/example/package.json +25 -0
- package/example/src/App.tsx +8 -0
- package/example/tsconfig.json +6 -0
- package/package.json +1 -1
- package/src/shared/translation/constants.ts +4 -0
- package/src/shared/translation/localization/ca.json +22 -0
- package/src/shared/translation/localization/sct.json +22 -0
- package/src/shared/translation/types.ts +6 -0
- package/src/shared/translation/validation.types.ts +9 -1
- package/tsconfig.build.json +4 -0
- package/tsconfig.json +34 -0
- package/yarn.lock +8589 -0
|
@@ -1,6 +1,8 @@
|
|
|
1
1
|
import enTranslations from './localization/en.json'
|
|
2
2
|
import swTranslations from './localization/sw.json'
|
|
3
3
|
import gbTranslations from './localization/gb.json'
|
|
4
|
+
import caTranslations from './localization/ca.json'
|
|
5
|
+
import sctTranslations from './localization/sct.json'
|
|
4
6
|
import { RetrieveKeys } from '../../lib/types/keys'
|
|
5
7
|
import { ISValidTranslation } from './validation.types'
|
|
6
8
|
|
|
@@ -12,9 +14,13 @@ export enum Locale {
|
|
|
12
14
|
EN = 'en-SE',
|
|
13
15
|
SW = 'sv-SE',
|
|
14
16
|
GB = 'en-GB',
|
|
17
|
+
CA = 'en-CA',
|
|
18
|
+
SCT = 'en-SCT',
|
|
15
19
|
}
|
|
16
20
|
|
|
17
21
|
// Validation of translations, do not remove
|
|
18
22
|
type ISValidEN = ISValidTranslation<Translations>
|
|
19
23
|
type ISValidSW = ISValidTranslation<typeof swTranslations>
|
|
20
24
|
type ISValidGB = ISValidTranslation<typeof gbTranslations>
|
|
25
|
+
type ISValidCA = ISValidTranslation<typeof caTranslations>
|
|
26
|
+
type ISValidSCT = ISValidTranslation<typeof sctTranslations>
|
|
@@ -1,6 +1,8 @@
|
|
|
1
1
|
import enTranslations from './localization/en.json'
|
|
2
2
|
import swTranslations from './localization/sw.json'
|
|
3
3
|
import gbTranslations from './localization/gb.json'
|
|
4
|
+
import caTranslations from './localization/ca.json'
|
|
5
|
+
import sctTranslations from './localization/sct.json'
|
|
4
6
|
|
|
5
7
|
type Extends<T, U> = T extends U ? true : false
|
|
6
8
|
|
|
@@ -20,7 +22,13 @@ type FindDominantType<Types extends unknown[]> = Types extends [
|
|
|
20
22
|
: never
|
|
21
23
|
|
|
22
24
|
type DominantTranslation = FindDominantType<
|
|
23
|
-
[
|
|
25
|
+
[
|
|
26
|
+
typeof enTranslations,
|
|
27
|
+
typeof swTranslations,
|
|
28
|
+
typeof gbTranslations,
|
|
29
|
+
typeof caTranslations,
|
|
30
|
+
typeof sctTranslations,
|
|
31
|
+
]
|
|
24
32
|
>
|
|
25
33
|
|
|
26
34
|
export type ISValidTranslation<T extends DominantTranslation> = T
|
package/tsconfig.json
ADDED
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
{
|
|
2
|
+
"compilerOptions": {
|
|
3
|
+
"paths": {
|
|
4
|
+
"@magmamath/students-features": ["./src/index"]
|
|
5
|
+
},
|
|
6
|
+
"target": "esnext",
|
|
7
|
+
"baseUrl": "./",
|
|
8
|
+
"lib": [
|
|
9
|
+
"dom",
|
|
10
|
+
"dom.iterable",
|
|
11
|
+
"esnext"
|
|
12
|
+
],
|
|
13
|
+
"declaration": true,
|
|
14
|
+
"allowJs": true,
|
|
15
|
+
"skipLibCheck": true,
|
|
16
|
+
"esModuleInterop": true,
|
|
17
|
+
"allowSyntheticDefaultImports": true,
|
|
18
|
+
"strict": true,
|
|
19
|
+
"forceConsistentCasingInFileNames": true,
|
|
20
|
+
"module": "esnext",
|
|
21
|
+
"moduleResolution": "node",
|
|
22
|
+
"resolveJsonModule": true,
|
|
23
|
+
"isolatedModules": true,
|
|
24
|
+
"jsx": "react",
|
|
25
|
+
"experimentalDecorators": true
|
|
26
|
+
},
|
|
27
|
+
"include": [
|
|
28
|
+
"src"
|
|
29
|
+
],
|
|
30
|
+
"exclude": [
|
|
31
|
+
"node_modules",
|
|
32
|
+
"example"
|
|
33
|
+
]
|
|
34
|
+
}
|