mirror of
https://github.com/logto-io/logto.git
synced 2024-12-16 20:26:19 -05:00
chore(deps): update silverhand configs monorepo packages to v6 (major) (#5750)
* chore: upgrade configs * refactor: fix lint errors * refactor: fix lint errors * refactor: fix stylelint issues --------- Co-authored-by: Gao Sun <gao@silverhand.io>
This commit is contained in:
parent
8ef021fb35
commit
8508469abf
543 changed files with 3148 additions and 2669 deletions
|
@ -41,7 +41,8 @@
|
|||
"peerDependencyRules": {
|
||||
"allowedVersions": {
|
||||
"react": "^18.0.0",
|
||||
"jest": "^29.1.2"
|
||||
"jest": "^29.1.2",
|
||||
"stylelint": "^16.0.0"
|
||||
}
|
||||
}
|
||||
},
|
||||
|
|
|
@ -29,11 +29,11 @@
|
|||
"prepack": "pnpm build"
|
||||
},
|
||||
"devDependencies": {
|
||||
"@silverhand/eslint-config": "5.0.0",
|
||||
"@silverhand/ts-config": "5.0.0",
|
||||
"@silverhand/eslint-config": "6.0.1",
|
||||
"@silverhand/ts-config": "6.0.0",
|
||||
"@types/node": "^20.9.5",
|
||||
"@vitest/coverage-v8": "^1.4.0",
|
||||
"eslint": "^8.44.0",
|
||||
"eslint": "^8.56.0",
|
||||
"lint-staged": "^15.0.0",
|
||||
"prettier": "^3.0.0",
|
||||
"typescript": "^5.3.3",
|
||||
|
|
|
@ -36,11 +36,7 @@ function getCircularReplacer() {
|
|||
|
||||
return function (this: unknown, key: string, value: unknown) {
|
||||
// Ignore `stack` property since ApplicationInsights will show it
|
||||
if (
|
||||
isObject(this) &&
|
||||
Object.prototype.hasOwnProperty.call(this, transformedKey) &&
|
||||
key === 'stack'
|
||||
) {
|
||||
if (isObject(this) && Object.hasOwn(this, transformedKey) && key === 'stack') {
|
||||
return;
|
||||
}
|
||||
|
||||
|
|
|
@ -71,8 +71,8 @@
|
|||
"zod": "^3.22.4"
|
||||
},
|
||||
"devDependencies": {
|
||||
"@silverhand/eslint-config": "5.0.0",
|
||||
"@silverhand/ts-config": "5.0.0",
|
||||
"@silverhand/eslint-config": "6.0.1",
|
||||
"@silverhand/ts-config": "6.0.0",
|
||||
"@types/inquirer": "^9.0.0",
|
||||
"@types/node": "^20.9.5",
|
||||
"@types/semver": "^7.3.12",
|
||||
|
@ -81,7 +81,7 @@
|
|||
"@types/yargs": "^17.0.13",
|
||||
"@vitest/coverage-v8": "^1.4.0",
|
||||
"@withtyped/server": "^0.13.3",
|
||||
"eslint": "^8.44.0",
|
||||
"eslint": "^8.56.0",
|
||||
"lint-staged": "^15.0.0",
|
||||
"prettier": "^3.0.0",
|
||||
"sinon": "^17.0.0",
|
||||
|
|
|
@ -68,7 +68,7 @@ export const downloadFile = async (url: string, destination: string) => {
|
|||
|
||||
file.on('error', (error) => {
|
||||
spinner.fail();
|
||||
reject(error.message);
|
||||
reject(new Error(error.message));
|
||||
});
|
||||
|
||||
file.on('finish', () => {
|
||||
|
|
|
@ -18,12 +18,12 @@
|
|||
"@rollup/plugin-node-resolve": "^15.2.3",
|
||||
"@rollup/plugin-typescript": "^11.1.6",
|
||||
"@shopify/jest-koa-mocks": "^5.0.0",
|
||||
"@silverhand/eslint-config": "5.0.0",
|
||||
"@silverhand/ts-config": "5.0.0",
|
||||
"@silverhand/eslint-config": "6.0.1",
|
||||
"@silverhand/ts-config": "6.0.0",
|
||||
"@types/node": "^20.11.20",
|
||||
"@types/supertest": "^6.0.2",
|
||||
"@vitest/coverage-v8": "^1.4.0",
|
||||
"eslint": "^8.44.0",
|
||||
"eslint": "^8.56.0",
|
||||
"lint-staged": "^15.0.2",
|
||||
"nock": "^13.3.1",
|
||||
"prettier": "^3.0.0",
|
||||
|
|
|
@ -17,12 +17,12 @@
|
|||
"@rollup/plugin-node-resolve": "^15.2.3",
|
||||
"@rollup/plugin-typescript": "^11.1.6",
|
||||
"@shopify/jest-koa-mocks": "^5.0.0",
|
||||
"@silverhand/eslint-config": "5.0.0",
|
||||
"@silverhand/ts-config": "5.0.0",
|
||||
"@silverhand/eslint-config": "6.0.1",
|
||||
"@silverhand/ts-config": "6.0.0",
|
||||
"@types/node": "^20.11.20",
|
||||
"@types/supertest": "^6.0.2",
|
||||
"@vitest/coverage-v8": "^1.4.0",
|
||||
"eslint": "^8.44.0",
|
||||
"eslint": "^8.56.0",
|
||||
"lint-staged": "^15.0.2",
|
||||
"nock": "^13.3.1",
|
||||
"prettier": "^3.0.0",
|
||||
|
|
|
@ -55,12 +55,12 @@
|
|||
"@rollup/plugin-json": "^6.1.0",
|
||||
"@rollup/plugin-node-resolve": "^15.2.3",
|
||||
"@rollup/plugin-typescript": "^11.1.6",
|
||||
"@silverhand/eslint-config": "5.0.0",
|
||||
"@silverhand/ts-config": "5.0.0",
|
||||
"@silverhand/eslint-config": "6.0.1",
|
||||
"@silverhand/ts-config": "6.0.0",
|
||||
"@types/node": "^20.11.20",
|
||||
"@types/supertest": "^6.0.2",
|
||||
"@vitest/coverage-v8": "^1.4.0",
|
||||
"eslint": "^8.44.0",
|
||||
"eslint": "^8.56.0",
|
||||
"lint-staged": "^15.0.2",
|
||||
"nock": "^13.3.1",
|
||||
"prettier": "^3.0.0",
|
||||
|
|
|
@ -55,12 +55,12 @@
|
|||
"@rollup/plugin-json": "^6.1.0",
|
||||
"@rollup/plugin-node-resolve": "^15.2.3",
|
||||
"@rollup/plugin-typescript": "^11.1.6",
|
||||
"@silverhand/eslint-config": "5.0.0",
|
||||
"@silverhand/ts-config": "5.0.0",
|
||||
"@silverhand/eslint-config": "6.0.1",
|
||||
"@silverhand/ts-config": "6.0.0",
|
||||
"@types/node": "^20.11.20",
|
||||
"@types/supertest": "^6.0.2",
|
||||
"@vitest/coverage-v8": "^1.4.0",
|
||||
"eslint": "^8.44.0",
|
||||
"eslint": "^8.56.0",
|
||||
"lint-staged": "^15.0.2",
|
||||
"nock": "^13.3.1",
|
||||
"prettier": "^3.0.0",
|
||||
|
|
|
@ -57,12 +57,12 @@
|
|||
"@rollup/plugin-json": "^6.1.0",
|
||||
"@rollup/plugin-node-resolve": "^15.2.3",
|
||||
"@rollup/plugin-typescript": "^11.1.6",
|
||||
"@silverhand/eslint-config": "5.0.0",
|
||||
"@silverhand/ts-config": "5.0.0",
|
||||
"@silverhand/eslint-config": "6.0.1",
|
||||
"@silverhand/ts-config": "6.0.0",
|
||||
"@types/node": "^20.11.20",
|
||||
"@types/supertest": "^6.0.2",
|
||||
"@vitest/coverage-v8": "^1.4.0",
|
||||
"eslint": "^8.44.0",
|
||||
"eslint": "^8.56.0",
|
||||
"lint-staged": "^15.0.2",
|
||||
"nock": "^13.3.1",
|
||||
"prettier": "^3.0.0",
|
||||
|
|
|
@ -58,12 +58,12 @@
|
|||
"@rollup/plugin-json": "^6.1.0",
|
||||
"@rollup/plugin-node-resolve": "^15.2.3",
|
||||
"@rollup/plugin-typescript": "^11.1.6",
|
||||
"@silverhand/eslint-config": "5.0.0",
|
||||
"@silverhand/ts-config": "5.0.0",
|
||||
"@silverhand/eslint-config": "6.0.1",
|
||||
"@silverhand/ts-config": "6.0.0",
|
||||
"@types/node": "^20.11.20",
|
||||
"@types/supertest": "^6.0.2",
|
||||
"@vitest/coverage-v8": "^1.4.0",
|
||||
"eslint": "^8.44.0",
|
||||
"eslint": "^8.56.0",
|
||||
"lint-staged": "^15.0.2",
|
||||
"nock": "^13.3.1",
|
||||
"prettier": "^3.0.0",
|
||||
|
|
|
@ -57,12 +57,12 @@
|
|||
"@rollup/plugin-json": "^6.1.0",
|
||||
"@rollup/plugin-node-resolve": "^15.2.3",
|
||||
"@rollup/plugin-typescript": "^11.1.6",
|
||||
"@silverhand/eslint-config": "5.0.0",
|
||||
"@silverhand/ts-config": "5.0.0",
|
||||
"@silverhand/eslint-config": "6.0.1",
|
||||
"@silverhand/ts-config": "6.0.0",
|
||||
"@types/node": "^20.11.20",
|
||||
"@types/supertest": "^6.0.2",
|
||||
"@vitest/coverage-v8": "^1.4.0",
|
||||
"eslint": "^8.44.0",
|
||||
"eslint": "^8.56.0",
|
||||
"lint-staged": "^15.0.2",
|
||||
"nock": "^13.3.1",
|
||||
"prettier": "^3.0.0",
|
||||
|
|
|
@ -56,12 +56,12 @@
|
|||
"@rollup/plugin-json": "^6.1.0",
|
||||
"@rollup/plugin-node-resolve": "^15.2.3",
|
||||
"@rollup/plugin-typescript": "^11.1.6",
|
||||
"@silverhand/eslint-config": "5.0.0",
|
||||
"@silverhand/ts-config": "5.0.0",
|
||||
"@silverhand/eslint-config": "6.0.1",
|
||||
"@silverhand/ts-config": "6.0.0",
|
||||
"@types/node": "^20.11.20",
|
||||
"@types/supertest": "^6.0.2",
|
||||
"@vitest/coverage-v8": "^1.4.0",
|
||||
"eslint": "^8.44.0",
|
||||
"eslint": "^8.56.0",
|
||||
"lint-staged": "^15.0.2",
|
||||
"nock": "^13.3.1",
|
||||
"prettier": "^3.0.0",
|
||||
|
|
|
@ -56,12 +56,12 @@
|
|||
"@rollup/plugin-json": "^6.1.0",
|
||||
"@rollup/plugin-node-resolve": "^15.2.3",
|
||||
"@rollup/plugin-typescript": "^11.1.6",
|
||||
"@silverhand/eslint-config": "5.0.0",
|
||||
"@silverhand/ts-config": "5.0.0",
|
||||
"@silverhand/eslint-config": "6.0.1",
|
||||
"@silverhand/ts-config": "6.0.0",
|
||||
"@types/node": "^20.11.20",
|
||||
"@types/supertest": "^6.0.2",
|
||||
"@vitest/coverage-v8": "^1.4.0",
|
||||
"eslint": "^8.44.0",
|
||||
"eslint": "^8.56.0",
|
||||
"lint-staged": "^15.0.2",
|
||||
"nock": "^13.3.1",
|
||||
"prettier": "^3.0.0",
|
||||
|
|
|
@ -56,12 +56,12 @@
|
|||
"@rollup/plugin-json": "^6.1.0",
|
||||
"@rollup/plugin-node-resolve": "^15.2.3",
|
||||
"@rollup/plugin-typescript": "^11.1.6",
|
||||
"@silverhand/eslint-config": "5.0.0",
|
||||
"@silverhand/ts-config": "5.0.0",
|
||||
"@silverhand/eslint-config": "6.0.1",
|
||||
"@silverhand/ts-config": "6.0.0",
|
||||
"@types/node": "^20.11.20",
|
||||
"@types/supertest": "^6.0.2",
|
||||
"@vitest/coverage-v8": "^1.4.0",
|
||||
"eslint": "^8.44.0",
|
||||
"eslint": "^8.56.0",
|
||||
"lint-staged": "^15.0.2",
|
||||
"nock": "^13.3.1",
|
||||
"prettier": "^3.0.0",
|
||||
|
|
|
@ -57,12 +57,12 @@
|
|||
"@rollup/plugin-json": "^6.1.0",
|
||||
"@rollup/plugin-node-resolve": "^15.2.3",
|
||||
"@rollup/plugin-typescript": "^11.1.6",
|
||||
"@silverhand/eslint-config": "5.0.0",
|
||||
"@silverhand/ts-config": "5.0.0",
|
||||
"@silverhand/eslint-config": "6.0.1",
|
||||
"@silverhand/ts-config": "6.0.0",
|
||||
"@types/node": "^20.11.20",
|
||||
"@types/supertest": "^6.0.2",
|
||||
"@vitest/coverage-v8": "^1.4.0",
|
||||
"eslint": "^8.44.0",
|
||||
"eslint": "^8.56.0",
|
||||
"lint-staged": "^15.0.2",
|
||||
"nock": "^13.3.1",
|
||||
"prettier": "^3.0.0",
|
||||
|
|
|
@ -56,12 +56,12 @@
|
|||
"@rollup/plugin-json": "^6.1.0",
|
||||
"@rollup/plugin-node-resolve": "^15.2.3",
|
||||
"@rollup/plugin-typescript": "^11.1.6",
|
||||
"@silverhand/eslint-config": "5.0.0",
|
||||
"@silverhand/ts-config": "5.0.0",
|
||||
"@silverhand/eslint-config": "6.0.1",
|
||||
"@silverhand/ts-config": "6.0.0",
|
||||
"@types/node": "^20.11.20",
|
||||
"@types/supertest": "^6.0.2",
|
||||
"@vitest/coverage-v8": "^1.4.0",
|
||||
"eslint": "^8.44.0",
|
||||
"eslint": "^8.56.0",
|
||||
"lint-staged": "^15.0.2",
|
||||
"nock": "^13.3.1",
|
||||
"prettier": "^3.0.0",
|
||||
|
|
|
@ -56,12 +56,12 @@
|
|||
"@rollup/plugin-json": "^6.1.0",
|
||||
"@rollup/plugin-node-resolve": "^15.2.3",
|
||||
"@rollup/plugin-typescript": "^11.1.6",
|
||||
"@silverhand/eslint-config": "5.0.0",
|
||||
"@silverhand/ts-config": "5.0.0",
|
||||
"@silverhand/eslint-config": "6.0.1",
|
||||
"@silverhand/ts-config": "6.0.0",
|
||||
"@types/node": "^20.11.20",
|
||||
"@types/supertest": "^6.0.2",
|
||||
"@vitest/coverage-v8": "^1.4.0",
|
||||
"eslint": "^8.44.0",
|
||||
"eslint": "^8.56.0",
|
||||
"lint-staged": "^15.0.2",
|
||||
"nock": "^13.3.1",
|
||||
"prettier": "^3.0.0",
|
||||
|
|
|
@ -57,12 +57,12 @@
|
|||
"@rollup/plugin-json": "^6.1.0",
|
||||
"@rollup/plugin-node-resolve": "^15.2.3",
|
||||
"@rollup/plugin-typescript": "^11.1.6",
|
||||
"@silverhand/eslint-config": "5.0.0",
|
||||
"@silverhand/ts-config": "5.0.0",
|
||||
"@silverhand/eslint-config": "6.0.1",
|
||||
"@silverhand/ts-config": "6.0.0",
|
||||
"@types/node": "^20.11.20",
|
||||
"@types/supertest": "^6.0.2",
|
||||
"@vitest/coverage-v8": "^1.4.0",
|
||||
"eslint": "^8.44.0",
|
||||
"eslint": "^8.56.0",
|
||||
"lint-staged": "^15.0.2",
|
||||
"nock": "^13.3.1",
|
||||
"prettier": "^3.0.0",
|
||||
|
|
|
@ -56,12 +56,12 @@
|
|||
"@rollup/plugin-json": "^6.1.0",
|
||||
"@rollup/plugin-node-resolve": "^15.2.3",
|
||||
"@rollup/plugin-typescript": "^11.1.6",
|
||||
"@silverhand/eslint-config": "5.0.0",
|
||||
"@silverhand/ts-config": "5.0.0",
|
||||
"@silverhand/eslint-config": "6.0.1",
|
||||
"@silverhand/ts-config": "6.0.0",
|
||||
"@types/node": "^20.11.20",
|
||||
"@types/supertest": "^6.0.2",
|
||||
"@vitest/coverage-v8": "^1.4.0",
|
||||
"eslint": "^8.44.0",
|
||||
"eslint": "^8.56.0",
|
||||
"lint-staged": "^15.0.2",
|
||||
"nock": "^13.3.1",
|
||||
"prettier": "^3.0.0",
|
||||
|
|
|
@ -56,12 +56,12 @@
|
|||
"@rollup/plugin-json": "^6.1.0",
|
||||
"@rollup/plugin-node-resolve": "^15.2.3",
|
||||
"@rollup/plugin-typescript": "^11.1.6",
|
||||
"@silverhand/eslint-config": "5.0.0",
|
||||
"@silverhand/ts-config": "5.0.0",
|
||||
"@silverhand/eslint-config": "6.0.1",
|
||||
"@silverhand/ts-config": "6.0.0",
|
||||
"@types/node": "^20.11.20",
|
||||
"@types/supertest": "^6.0.2",
|
||||
"@vitest/coverage-v8": "^1.4.0",
|
||||
"eslint": "^8.44.0",
|
||||
"eslint": "^8.56.0",
|
||||
"lint-staged": "^15.0.2",
|
||||
"nock": "^13.3.1",
|
||||
"prettier": "^3.0.0",
|
||||
|
|
|
@ -56,12 +56,12 @@
|
|||
"@rollup/plugin-json": "^6.1.0",
|
||||
"@rollup/plugin-node-resolve": "^15.2.3",
|
||||
"@rollup/plugin-typescript": "^11.1.6",
|
||||
"@silverhand/eslint-config": "5.0.0",
|
||||
"@silverhand/ts-config": "5.0.0",
|
||||
"@silverhand/eslint-config": "6.0.1",
|
||||
"@silverhand/ts-config": "6.0.0",
|
||||
"@types/node": "^20.11.20",
|
||||
"@types/supertest": "^6.0.2",
|
||||
"@vitest/coverage-v8": "^1.4.0",
|
||||
"eslint": "^8.44.0",
|
||||
"eslint": "^8.56.0",
|
||||
"lint-staged": "^15.0.2",
|
||||
"nock": "^13.3.1",
|
||||
"prettier": "^3.0.0",
|
||||
|
|
|
@ -56,12 +56,12 @@
|
|||
"@rollup/plugin-json": "^6.1.0",
|
||||
"@rollup/plugin-node-resolve": "^15.2.3",
|
||||
"@rollup/plugin-typescript": "^11.1.6",
|
||||
"@silverhand/eslint-config": "5.0.0",
|
||||
"@silverhand/ts-config": "5.0.0",
|
||||
"@silverhand/eslint-config": "6.0.1",
|
||||
"@silverhand/ts-config": "6.0.0",
|
||||
"@types/node": "^20.11.20",
|
||||
"@types/supertest": "^6.0.2",
|
||||
"@vitest/coverage-v8": "^1.4.0",
|
||||
"eslint": "^8.44.0",
|
||||
"eslint": "^8.56.0",
|
||||
"lint-staged": "^15.0.2",
|
||||
"nock": "^13.3.1",
|
||||
"prettier": "^3.0.0",
|
||||
|
|
|
@ -56,12 +56,12 @@
|
|||
"@rollup/plugin-json": "^6.1.0",
|
||||
"@rollup/plugin-node-resolve": "^15.2.3",
|
||||
"@rollup/plugin-typescript": "^11.1.6",
|
||||
"@silverhand/eslint-config": "5.0.0",
|
||||
"@silverhand/ts-config": "5.0.0",
|
||||
"@silverhand/eslint-config": "6.0.1",
|
||||
"@silverhand/ts-config": "6.0.0",
|
||||
"@types/node": "^20.11.20",
|
||||
"@types/supertest": "^6.0.2",
|
||||
"@vitest/coverage-v8": "^1.4.0",
|
||||
"eslint": "^8.44.0",
|
||||
"eslint": "^8.56.0",
|
||||
"lint-staged": "^15.0.2",
|
||||
"nock": "^13.3.1",
|
||||
"prettier": "^3.0.0",
|
||||
|
|
|
@ -56,12 +56,12 @@
|
|||
"@rollup/plugin-json": "^6.1.0",
|
||||
"@rollup/plugin-node-resolve": "^15.2.3",
|
||||
"@rollup/plugin-typescript": "^11.1.6",
|
||||
"@silverhand/eslint-config": "5.0.0",
|
||||
"@silverhand/ts-config": "5.0.0",
|
||||
"@silverhand/eslint-config": "6.0.1",
|
||||
"@silverhand/ts-config": "6.0.0",
|
||||
"@types/node": "^20.11.20",
|
||||
"@types/supertest": "^6.0.2",
|
||||
"@vitest/coverage-v8": "^1.4.0",
|
||||
"eslint": "^8.44.0",
|
||||
"eslint": "^8.56.0",
|
||||
"lint-staged": "^15.0.2",
|
||||
"nock": "^13.3.1",
|
||||
"prettier": "^3.0.0",
|
||||
|
|
|
@ -56,12 +56,12 @@
|
|||
"@rollup/plugin-json": "^6.1.0",
|
||||
"@rollup/plugin-node-resolve": "^15.2.3",
|
||||
"@rollup/plugin-typescript": "^11.1.6",
|
||||
"@silverhand/eslint-config": "5.0.0",
|
||||
"@silverhand/ts-config": "5.0.0",
|
||||
"@silverhand/eslint-config": "6.0.1",
|
||||
"@silverhand/ts-config": "6.0.0",
|
||||
"@types/node": "^20.11.20",
|
||||
"@types/supertest": "^6.0.2",
|
||||
"@vitest/coverage-v8": "^1.4.0",
|
||||
"eslint": "^8.44.0",
|
||||
"eslint": "^8.56.0",
|
||||
"lint-staged": "^15.0.2",
|
||||
"nock": "^13.3.1",
|
||||
"prettier": "^3.0.0",
|
||||
|
|
|
@ -56,12 +56,12 @@
|
|||
"@rollup/plugin-json": "^6.1.0",
|
||||
"@rollup/plugin-node-resolve": "^15.2.3",
|
||||
"@rollup/plugin-typescript": "^11.1.6",
|
||||
"@silverhand/eslint-config": "5.0.0",
|
||||
"@silverhand/ts-config": "5.0.0",
|
||||
"@silverhand/eslint-config": "6.0.1",
|
||||
"@silverhand/ts-config": "6.0.0",
|
||||
"@types/node": "^20.11.20",
|
||||
"@types/supertest": "^6.0.2",
|
||||
"@vitest/coverage-v8": "^1.4.0",
|
||||
"eslint": "^8.44.0",
|
||||
"eslint": "^8.56.0",
|
||||
"lint-staged": "^15.0.2",
|
||||
"nock": "^13.3.1",
|
||||
"prettier": "^3.0.0",
|
||||
|
|
|
@ -57,12 +57,12 @@
|
|||
"@rollup/plugin-json": "^6.1.0",
|
||||
"@rollup/plugin-node-resolve": "^15.2.3",
|
||||
"@rollup/plugin-typescript": "^11.1.6",
|
||||
"@silverhand/eslint-config": "5.0.0",
|
||||
"@silverhand/ts-config": "5.0.0",
|
||||
"@silverhand/eslint-config": "6.0.1",
|
||||
"@silverhand/ts-config": "6.0.0",
|
||||
"@types/node": "^20.11.20",
|
||||
"@types/supertest": "^6.0.2",
|
||||
"@vitest/coverage-v8": "^1.4.0",
|
||||
"eslint": "^8.44.0",
|
||||
"eslint": "^8.56.0",
|
||||
"lint-staged": "^15.0.2",
|
||||
"nock": "^13.3.1",
|
||||
"prettier": "^3.0.0",
|
||||
|
|
|
@ -58,12 +58,12 @@
|
|||
"@rollup/plugin-json": "^6.1.0",
|
||||
"@rollup/plugin-node-resolve": "^15.2.3",
|
||||
"@rollup/plugin-typescript": "^11.1.6",
|
||||
"@silverhand/eslint-config": "5.0.0",
|
||||
"@silverhand/ts-config": "5.0.0",
|
||||
"@silverhand/eslint-config": "6.0.1",
|
||||
"@silverhand/ts-config": "6.0.0",
|
||||
"@types/node": "^20.11.20",
|
||||
"@types/supertest": "^6.0.2",
|
||||
"@vitest/coverage-v8": "^1.4.0",
|
||||
"eslint": "^8.44.0",
|
||||
"eslint": "^8.56.0",
|
||||
"lint-staged": "^15.0.2",
|
||||
"nock": "^13.3.1",
|
||||
"prettier": "^3.0.0",
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
import { z } from 'zod';
|
||||
|
||||
const scopeOpenid = 'openid' as const;
|
||||
const scopeOpenid = 'openid';
|
||||
export const delimiter = /[ +]/;
|
||||
|
||||
// Space-delimited 'scope' MUST contain 'openid', see https://openid.net/specs/openid-connect-core-1_0.html#CodeFlowAuth
|
||||
|
|
|
@ -58,12 +58,12 @@
|
|||
"@rollup/plugin-json": "^6.1.0",
|
||||
"@rollup/plugin-node-resolve": "^15.2.3",
|
||||
"@rollup/plugin-typescript": "^11.1.6",
|
||||
"@silverhand/eslint-config": "5.0.0",
|
||||
"@silverhand/ts-config": "5.0.0",
|
||||
"@silverhand/eslint-config": "6.0.1",
|
||||
"@silverhand/ts-config": "6.0.0",
|
||||
"@types/node": "^20.11.20",
|
||||
"@types/supertest": "^6.0.2",
|
||||
"@vitest/coverage-v8": "^1.4.0",
|
||||
"eslint": "^8.44.0",
|
||||
"eslint": "^8.56.0",
|
||||
"lint-staged": "^15.0.2",
|
||||
"nock": "^13.3.1",
|
||||
"prettier": "^3.0.0",
|
||||
|
|
|
@ -56,12 +56,12 @@
|
|||
"@rollup/plugin-json": "^6.1.0",
|
||||
"@rollup/plugin-node-resolve": "^15.2.3",
|
||||
"@rollup/plugin-typescript": "^11.1.6",
|
||||
"@silverhand/eslint-config": "5.0.0",
|
||||
"@silverhand/ts-config": "5.0.0",
|
||||
"@silverhand/eslint-config": "6.0.1",
|
||||
"@silverhand/ts-config": "6.0.0",
|
||||
"@types/node": "^20.11.20",
|
||||
"@types/supertest": "^6.0.2",
|
||||
"@vitest/coverage-v8": "^1.4.0",
|
||||
"eslint": "^8.44.0",
|
||||
"eslint": "^8.56.0",
|
||||
"lint-staged": "^15.0.2",
|
||||
"nock": "^13.3.1",
|
||||
"prettier": "^3.0.0",
|
||||
|
|
|
@ -56,12 +56,12 @@
|
|||
"@rollup/plugin-json": "^6.1.0",
|
||||
"@rollup/plugin-node-resolve": "^15.2.3",
|
||||
"@rollup/plugin-typescript": "^11.1.6",
|
||||
"@silverhand/eslint-config": "5.0.0",
|
||||
"@silverhand/ts-config": "5.0.0",
|
||||
"@silverhand/eslint-config": "6.0.1",
|
||||
"@silverhand/ts-config": "6.0.0",
|
||||
"@types/node": "^20.11.20",
|
||||
"@types/supertest": "^6.0.2",
|
||||
"@vitest/coverage-v8": "^1.4.0",
|
||||
"eslint": "^8.44.0",
|
||||
"eslint": "^8.56.0",
|
||||
"lint-staged": "^15.0.2",
|
||||
"nock": "^13.3.1",
|
||||
"prettier": "^3.0.0",
|
||||
|
|
|
@ -27,7 +27,6 @@ function sendMessage(getConfig: GetConnectorConfig): SendMessageFunction {
|
|||
validateConfig(config, smsAeroConfigGuard);
|
||||
|
||||
const { email, apiKey, senderName, templates } = config;
|
||||
|
||||
const template = templates.find((template) => template.usageType === type);
|
||||
|
||||
assert(
|
||||
|
|
|
@ -16,13 +16,13 @@
|
|||
"@rollup/plugin-json": "^6.1.0",
|
||||
"@rollup/plugin-node-resolve": "^15.2.3",
|
||||
"@rollup/plugin-typescript": "^11.1.6",
|
||||
"@silverhand/eslint-config": "5.0.0",
|
||||
"@silverhand/ts-config": "5.0.0",
|
||||
"@silverhand/eslint-config": "6.0.1",
|
||||
"@silverhand/ts-config": "6.0.0",
|
||||
"@types/node": "^20.11.20",
|
||||
"@types/nodemailer": "^6.4.7",
|
||||
"@types/supertest": "^6.0.2",
|
||||
"@vitest/coverage-v8": "^1.4.0",
|
||||
"eslint": "^8.44.0",
|
||||
"eslint": "^8.56.0",
|
||||
"lint-staged": "^15.0.2",
|
||||
"nock": "^13.3.1",
|
||||
"prettier": "^3.0.0",
|
||||
|
|
|
@ -70,12 +70,6 @@ const parseContents = (contents: string, contentType: ContextType) => {
|
|||
case ContextType.Html: {
|
||||
return { html: contents };
|
||||
}
|
||||
default: {
|
||||
throw new ConnectorError(
|
||||
ConnectorErrorCodes.InvalidConfig,
|
||||
'`contentType` should be ContextType.'
|
||||
);
|
||||
}
|
||||
}
|
||||
};
|
||||
|
||||
|
|
|
@ -56,12 +56,12 @@
|
|||
"@rollup/plugin-json": "^6.1.0",
|
||||
"@rollup/plugin-node-resolve": "^15.2.3",
|
||||
"@rollup/plugin-typescript": "^11.1.6",
|
||||
"@silverhand/eslint-config": "5.0.0",
|
||||
"@silverhand/ts-config": "5.0.0",
|
||||
"@silverhand/eslint-config": "6.0.1",
|
||||
"@silverhand/ts-config": "6.0.0",
|
||||
"@types/node": "^20.11.20",
|
||||
"@types/supertest": "^6.0.2",
|
||||
"@vitest/coverage-v8": "^1.4.0",
|
||||
"eslint": "^8.44.0",
|
||||
"eslint": "^8.56.0",
|
||||
"lint-staged": "^15.0.2",
|
||||
"nock": "^13.3.1",
|
||||
"prettier": "^3.0.0",
|
||||
|
|
|
@ -8,8 +8,8 @@ import type { TencentErrorResponse, TencentSuccessResponse } from './schema.js';
|
|||
const endpoint = 'sms.tencentcloudapi.com';
|
||||
|
||||
function sha256Hmac(message: string, secret: string): string;
|
||||
// eslint-disable-next-line @typescript-eslint/ban-types
|
||||
function sha256Hmac(message: string, secret: string, encoding: BinaryToTextEncoding): Buffer;
|
||||
|
||||
function sha256Hmac(message: string, secret: string, encoding?: BinaryToTextEncoding) {
|
||||
const hmac = crypto.createHmac('sha256', secret);
|
||||
|
||||
|
|
|
@ -56,12 +56,12 @@
|
|||
"@rollup/plugin-json": "^6.1.0",
|
||||
"@rollup/plugin-node-resolve": "^15.2.3",
|
||||
"@rollup/plugin-typescript": "^11.1.6",
|
||||
"@silverhand/eslint-config": "5.0.0",
|
||||
"@silverhand/ts-config": "5.0.0",
|
||||
"@silverhand/eslint-config": "6.0.1",
|
||||
"@silverhand/ts-config": "6.0.0",
|
||||
"@types/node": "^20.11.20",
|
||||
"@types/supertest": "^6.0.2",
|
||||
"@vitest/coverage-v8": "^1.4.0",
|
||||
"eslint": "^8.44.0",
|
||||
"eslint": "^8.56.0",
|
||||
"lint-staged": "^15.0.2",
|
||||
"nock": "^13.3.1",
|
||||
"prettier": "^3.0.0",
|
||||
|
|
|
@ -56,12 +56,12 @@
|
|||
"@rollup/plugin-json": "^6.1.0",
|
||||
"@rollup/plugin-node-resolve": "^15.2.3",
|
||||
"@rollup/plugin-typescript": "^11.1.6",
|
||||
"@silverhand/eslint-config": "5.0.0",
|
||||
"@silverhand/ts-config": "5.0.0",
|
||||
"@silverhand/eslint-config": "6.0.1",
|
||||
"@silverhand/ts-config": "6.0.0",
|
||||
"@types/node": "^20.11.20",
|
||||
"@types/supertest": "^6.0.2",
|
||||
"@vitest/coverage-v8": "^1.4.0",
|
||||
"eslint": "^8.44.0",
|
||||
"eslint": "^8.56.0",
|
||||
"lint-staged": "^15.0.2",
|
||||
"nock": "^13.3.1",
|
||||
"prettier": "^3.0.0",
|
||||
|
|
|
@ -56,12 +56,12 @@
|
|||
"@rollup/plugin-json": "^6.1.0",
|
||||
"@rollup/plugin-node-resolve": "^15.2.3",
|
||||
"@rollup/plugin-typescript": "^11.1.6",
|
||||
"@silverhand/eslint-config": "5.0.0",
|
||||
"@silverhand/ts-config": "5.0.0",
|
||||
"@silverhand/eslint-config": "6.0.1",
|
||||
"@silverhand/ts-config": "6.0.0",
|
||||
"@types/node": "^20.11.20",
|
||||
"@types/supertest": "^6.0.2",
|
||||
"@vitest/coverage-v8": "^1.4.0",
|
||||
"eslint": "^8.44.0",
|
||||
"eslint": "^8.56.0",
|
||||
"lint-staged": "^15.0.2",
|
||||
"nock": "^13.3.1",
|
||||
"prettier": "^3.0.0",
|
||||
|
|
|
@ -56,12 +56,12 @@
|
|||
"@rollup/plugin-json": "^6.1.0",
|
||||
"@rollup/plugin-node-resolve": "^15.2.3",
|
||||
"@rollup/plugin-typescript": "^11.1.6",
|
||||
"@silverhand/eslint-config": "5.0.0",
|
||||
"@silverhand/ts-config": "5.0.0",
|
||||
"@silverhand/eslint-config": "6.0.1",
|
||||
"@silverhand/ts-config": "6.0.0",
|
||||
"@types/node": "^20.10.4",
|
||||
"@types/supertest": "^6.0.2",
|
||||
"@vitest/coverage-v8": "^1.4.0",
|
||||
"eslint": "^8.44.0",
|
||||
"eslint": "^8.56.0",
|
||||
"lint-staged": "^15.0.2",
|
||||
"nock": "^13.3.1",
|
||||
"prettier": "^3.0.0",
|
||||
|
|
|
@ -44,11 +44,11 @@
|
|||
"@parcel/transformer-mdx": "2.9.3",
|
||||
"@parcel/transformer-sass": "2.9.3",
|
||||
"@parcel/transformer-svg-react": "2.9.3",
|
||||
"@silverhand/eslint-config": "5.0.0",
|
||||
"@silverhand/eslint-config-react": "5.0.0",
|
||||
"@silverhand/eslint-config": "6.0.1",
|
||||
"@silverhand/eslint-config-react": "6.0.2",
|
||||
"@silverhand/essentials": "^2.9.0",
|
||||
"@silverhand/ts-config": "5.0.0",
|
||||
"@silverhand/ts-config-react": "5.0.0",
|
||||
"@silverhand/ts-config": "6.0.0",
|
||||
"@silverhand/ts-config-react": "6.0.0",
|
||||
"@swc/core": "^1.3.52",
|
||||
"@swc/jest": "^0.2.26",
|
||||
"@testing-library/react": "^15.0.0",
|
||||
|
@ -75,7 +75,7 @@
|
|||
"deep-object-diff": "^1.1.9",
|
||||
"deepmerge": "^4.2.2",
|
||||
"dnd-core": "^16.0.0",
|
||||
"eslint": "^8.44.0",
|
||||
"eslint": "^8.56.0",
|
||||
"history": "^5.3.0",
|
||||
"i18next": "^22.4.15",
|
||||
"i18next-browser-languagedetector": "^7.0.1",
|
||||
|
|
|
@ -16,7 +16,7 @@ import useUserOnboardingData from '@/onboarding/hooks/use-user-onboarding-data';
|
|||
import * as styles from './index.module.scss';
|
||||
|
||||
type Props = {
|
||||
invitations: InvitationListResponse;
|
||||
readonly invitations: InvitationListResponse;
|
||||
};
|
||||
|
||||
function InvitationList({ invitations }: Props) {
|
||||
|
|
|
@ -3,7 +3,7 @@ import { useContext, useEffect } from 'react';
|
|||
import AppLoading from '@/components/AppLoading';
|
||||
import { TenantsContext } from '@/contexts/TenantsProvider';
|
||||
|
||||
function Redirect({ toTenantId }: { toTenantId: string }) {
|
||||
function Redirect({ toTenantId }: { readonly toTenantId: string }) {
|
||||
const { navigateTenant } = useContext(TenantsContext);
|
||||
|
||||
useEffect(() => {
|
||||
|
|
|
@ -15,7 +15,7 @@ import useTheme from '@/hooks/use-theme';
|
|||
import * as styles from './index.module.scss';
|
||||
|
||||
type Props = {
|
||||
className?: string;
|
||||
readonly className?: string;
|
||||
};
|
||||
|
||||
function TenantLandingPageContent({ className }: Props) {
|
||||
|
|
|
@ -5,9 +5,9 @@ import ProgressBar from '../ProgressBar';
|
|||
import * as styles from './index.module.scss';
|
||||
|
||||
type Props = {
|
||||
step: number;
|
||||
totalSteps: number;
|
||||
children: ReactNode;
|
||||
readonly step: number;
|
||||
readonly totalSteps: number;
|
||||
readonly children: ReactNode;
|
||||
};
|
||||
|
||||
function ActionBar({ step, totalSteps, children }: Props) {
|
||||
|
|
|
@ -16,18 +16,18 @@ type Props = {
|
|||
/** A function that will be called when the user confirms the deletion. If not provided,
|
||||
* the delete button will not be displayed.
|
||||
*/
|
||||
onDelete?: () => void | Promise<void>;
|
||||
readonly onDelete?: () => void | Promise<void>;
|
||||
/**
|
||||
* A function that will be called when the user clicks the edit button. If not provided,
|
||||
* the edit button will not be displayed.
|
||||
*/
|
||||
onEdit?: () => void | Promise<void>;
|
||||
readonly onEdit?: () => void | Promise<void>;
|
||||
/** The translation key of the content that will be displayed in the confirmation modal. */
|
||||
deleteConfirmation: AdminConsoleKey;
|
||||
readonly deleteConfirmation: AdminConsoleKey;
|
||||
/** The name of the field that is being operated. */
|
||||
fieldName: AdminConsoleKey;
|
||||
readonly fieldName: AdminConsoleKey;
|
||||
/** Overrides the default translations of the edit and delete buttons. */
|
||||
textOverrides?: {
|
||||
readonly textOverrides?: {
|
||||
/** The translation key of the edit button. */
|
||||
edit?: AdminConsoleKey;
|
||||
/** The translation key of the delete button. */
|
||||
|
|
|
@ -12,11 +12,11 @@ import { onKeyDownHandler } from '@/utils/a11y';
|
|||
import * as styles from './index.module.scss';
|
||||
|
||||
type Props = {
|
||||
title?: string;
|
||||
errorCode?: string;
|
||||
errorMessage?: string;
|
||||
callStack?: string;
|
||||
children?: React.ReactNode;
|
||||
readonly title?: string;
|
||||
readonly errorCode?: string;
|
||||
readonly errorMessage?: string;
|
||||
readonly callStack?: string;
|
||||
readonly children?: React.ReactNode;
|
||||
};
|
||||
|
||||
function AppError({ title, errorCode, errorMessage, callStack, children }: Props) {
|
||||
|
|
|
@ -10,9 +10,9 @@ import {
|
|||
import useTheme from '@/hooks/use-theme';
|
||||
|
||||
type Props = {
|
||||
type: ApplicationType;
|
||||
className?: string;
|
||||
isThirdParty?: boolean;
|
||||
readonly type: ApplicationType;
|
||||
readonly className?: string;
|
||||
readonly isThirdParty?: boolean;
|
||||
};
|
||||
|
||||
const getIcon = (type: ApplicationType, isLightMode: boolean, isThirdParty?: boolean) => {
|
||||
|
|
|
@ -13,8 +13,8 @@ import { shouldRetryOnError } from '@/utils/request';
|
|||
import * as styles from './index.module.scss';
|
||||
|
||||
type Props = {
|
||||
applicationId: string;
|
||||
isLink?: boolean;
|
||||
readonly applicationId: string;
|
||||
readonly isLink?: boolean;
|
||||
};
|
||||
|
||||
function ApplicationName({ applicationId, isLink = false }: Props) {
|
||||
|
|
|
@ -10,8 +10,8 @@ import { TenantsContext } from '@/contexts/TenantsProvider';
|
|||
import Select from '@/ds-components/Select';
|
||||
|
||||
type Props = {
|
||||
value?: string;
|
||||
onChange: (value?: string) => void;
|
||||
readonly value?: string;
|
||||
readonly onChange: (value?: string) => void;
|
||||
};
|
||||
|
||||
function ApplicationSelector({ value, onChange }: Props) {
|
||||
|
|
|
@ -9,9 +9,9 @@ import useTenantPathname from '@/hooks/use-tenant-pathname';
|
|||
import * as styles from './index.module.scss';
|
||||
|
||||
type Props = {
|
||||
eventKey: string;
|
||||
isSuccess: boolean;
|
||||
to?: string;
|
||||
readonly eventKey: string;
|
||||
readonly isSuccess: boolean;
|
||||
readonly to?: string;
|
||||
};
|
||||
|
||||
function EventName({ eventKey, isSuccess, to }: Props) {
|
||||
|
|
|
@ -4,9 +4,9 @@ import { logEventTitle } from '@/consts/logs';
|
|||
import Select, { type Option } from '@/ds-components/Select';
|
||||
|
||||
type Props = {
|
||||
value?: string;
|
||||
onChange: (value?: string) => void;
|
||||
options?: Array<Option<string>>;
|
||||
readonly value?: string;
|
||||
readonly onChange: (value?: string) => void;
|
||||
readonly options?: Array<Option<string>>;
|
||||
};
|
||||
|
||||
const defaultEventOptions = Object.entries(logEventTitle).map(([value, title]) => ({
|
||||
|
|
|
@ -27,9 +27,9 @@ const auditLogEventOptions = Object.entries(auditLogEventTitle).map(([value, tit
|
|||
}));
|
||||
|
||||
type Props = {
|
||||
applicationId?: string;
|
||||
userId?: string;
|
||||
className?: string;
|
||||
readonly applicationId?: string;
|
||||
readonly userId?: string;
|
||||
readonly className?: string;
|
||||
};
|
||||
|
||||
function AuditLogTable({ applicationId, userId, className }: Props) {
|
||||
|
|
|
@ -14,8 +14,8 @@ import useSubscribe from '@/hooks/use-subscribe';
|
|||
import * as styles from './index.module.scss';
|
||||
|
||||
type Props = {
|
||||
cost: number;
|
||||
isManagePaymentVisible?: boolean;
|
||||
readonly cost: number;
|
||||
readonly isManagePaymentVisible?: boolean;
|
||||
};
|
||||
|
||||
function BillInfo({ cost, isManagePaymentVisible }: Props) {
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
import * as styles from './index.module.scss';
|
||||
|
||||
type Props = {
|
||||
children: React.ReactNode;
|
||||
readonly children: React.ReactNode;
|
||||
};
|
||||
|
||||
/**
|
||||
|
|
|
@ -11,16 +11,16 @@ import TextLink from '@/ds-components/TextLink';
|
|||
import useConfigs from '@/hooks/use-configs';
|
||||
|
||||
type Props = {
|
||||
hasSurpassedLimit: boolean;
|
||||
quotaItemPhraseKey: TFuncKey<'translation', 'admin_console.upsell.add_on_quota_item'>;
|
||||
quotaLimit?: number;
|
||||
className?: string;
|
||||
readonly hasSurpassedLimit: boolean;
|
||||
readonly quotaItemPhraseKey: TFuncKey<'translation', 'admin_console.upsell.add_on_quota_item'>;
|
||||
readonly quotaLimit?: number;
|
||||
readonly className?: string;
|
||||
/**
|
||||
* The key of the flag in `checkedChargeNotification` config from the AdminConsoleData.
|
||||
* Used to determine whether the notification has been checked.
|
||||
* @see{@link AdminConsoleData}
|
||||
*/
|
||||
checkedFlagKey: keyof Truthy<AdminConsoleData['checkedChargeNotification']>;
|
||||
readonly checkedFlagKey: keyof Truthy<AdminConsoleData['checkedChargeNotification']>;
|
||||
};
|
||||
|
||||
/**
|
||||
|
|
|
@ -19,10 +19,10 @@ import { uriValidator } from '@/utils/validator';
|
|||
import * as styles from './index.module.scss';
|
||||
|
||||
type Props = {
|
||||
isAllowEditTarget?: boolean;
|
||||
isDarkDefaultVisible?: boolean;
|
||||
isStandard?: boolean;
|
||||
conflictConnectorName?: Record<string, string>;
|
||||
readonly isAllowEditTarget?: boolean;
|
||||
readonly isDarkDefaultVisible?: boolean;
|
||||
readonly isStandard?: boolean;
|
||||
readonly conflictConnectorName?: Record<string, string>;
|
||||
};
|
||||
|
||||
function BasicForm({
|
||||
|
|
|
@ -17,7 +17,7 @@ import { jsonValidator } from '@/utils/validator';
|
|||
import * as styles from './index.module.scss';
|
||||
|
||||
type Props = {
|
||||
formItems: ConnectorConfigFormItem[];
|
||||
readonly formItems: ConnectorConfigFormItem[];
|
||||
};
|
||||
|
||||
function ConfigFormFields({ formItems }: Props) {
|
||||
|
|
|
@ -19,11 +19,11 @@ import ConfigFormFields from './ConfigFormFields';
|
|||
import * as styles from './index.module.scss';
|
||||
|
||||
type Props = {
|
||||
formItems?: ConnectorConfigFormItem[];
|
||||
className?: string;
|
||||
connectorId: string;
|
||||
connectorFactoryId?: string;
|
||||
connectorType?: ConnectorType;
|
||||
readonly formItems?: ConnectorConfigFormItem[];
|
||||
readonly className?: string;
|
||||
readonly connectorId: string;
|
||||
readonly connectorFactoryId?: string;
|
||||
readonly connectorType?: ConnectorType;
|
||||
};
|
||||
|
||||
function ConfigForm({
|
||||
|
|
|
@ -8,9 +8,9 @@ import useTheme from '@/hooks/use-theme';
|
|||
import * as styles from './index.module.scss';
|
||||
|
||||
type Props = {
|
||||
className?: string;
|
||||
data: Pick<ConnectorResponse, 'logo' | 'logoDark'>;
|
||||
size?: 'small' | 'medium' | 'large';
|
||||
readonly className?: string;
|
||||
readonly data: Pick<ConnectorResponse, 'logo' | 'logoDark'>;
|
||||
readonly size?: 'small' | 'medium' | 'large';
|
||||
};
|
||||
|
||||
function ConnectorLogo({ className, data, size = 'medium' }: Props) {
|
||||
|
|
|
@ -18,11 +18,11 @@ import { trySubmitSafe } from '@/utils/form';
|
|||
import * as styles from './index.module.scss';
|
||||
|
||||
type Props = {
|
||||
connectorFactoryId: string;
|
||||
connectorType: Exclude<ConnectorType, ConnectorType.Social>;
|
||||
className?: string;
|
||||
parse: () => unknown;
|
||||
updateUsage?: () => void;
|
||||
readonly connectorFactoryId: string;
|
||||
readonly connectorType: Exclude<ConnectorType, ConnectorType.Social>;
|
||||
readonly className?: string;
|
||||
readonly parse: () => unknown;
|
||||
readonly updateUsage?: () => void;
|
||||
};
|
||||
|
||||
type FormData = {
|
||||
|
|
|
@ -4,7 +4,7 @@ import { contactEmailLink } from '@/consts';
|
|||
import TextLink from '@/ds-components/TextLink';
|
||||
|
||||
type Props = {
|
||||
children?: ReactNode;
|
||||
readonly children?: ReactNode;
|
||||
};
|
||||
|
||||
function ContactUsPhraseLink({ children }: Props) {
|
||||
|
|
|
@ -17,7 +17,7 @@ import {
|
|||
} from './utils';
|
||||
|
||||
type ScriptProps = {
|
||||
userEmailHash?: string;
|
||||
readonly userEmailHash?: string;
|
||||
};
|
||||
|
||||
function GoogleScripts({ userEmailHash }: ScriptProps) {
|
||||
|
|
|
@ -8,7 +8,7 @@ import { type ConnectorGroup } from '@/types/connector';
|
|||
import * as styles from './index.module.scss';
|
||||
|
||||
type Props = {
|
||||
data: ConnectorGroup<ConnectorFactoryResponse>;
|
||||
readonly data: ConnectorGroup<ConnectorFactoryResponse>;
|
||||
};
|
||||
|
||||
function ConnectorRadio({ data: { name, logo, logoDark, description } }: Props) {
|
||||
|
|
|
@ -10,11 +10,11 @@ import * as styles from './index.module.scss';
|
|||
export type ConnectorRadioGroupSize = 'medium' | 'large' | 'xlarge';
|
||||
|
||||
type Props = {
|
||||
name: string;
|
||||
value?: string;
|
||||
groups: Array<ConnectorGroup<ConnectorFactoryResponse>>;
|
||||
size: ConnectorRadioGroupSize;
|
||||
onChange: (groupId: string) => void;
|
||||
readonly name: string;
|
||||
readonly value?: string;
|
||||
readonly groups: Array<ConnectorGroup<ConnectorFactoryResponse>>;
|
||||
readonly size: ConnectorRadioGroupSize;
|
||||
readonly onChange: (groupId: string) => void;
|
||||
};
|
||||
|
||||
function ConnectorRadioGroup({ name, groups, value, size, onChange }: Props) {
|
||||
|
|
|
@ -16,11 +16,11 @@ import { type ConnectorGroup } from '@/types/connector';
|
|||
import { hasReachedQuotaLimit } from '@/utils/quota';
|
||||
|
||||
type Props = {
|
||||
isCreatingSocialConnector: boolean;
|
||||
existingConnectors: ConnectorResponse[];
|
||||
selectedConnectorGroup?: ConnectorGroup<ConnectorFactoryResponse>;
|
||||
isCreateButtonDisabled: boolean;
|
||||
onClickCreateButton: () => void;
|
||||
readonly isCreatingSocialConnector: boolean;
|
||||
readonly existingConnectors: ConnectorResponse[];
|
||||
readonly selectedConnectorGroup?: ConnectorGroup<ConnectorFactoryResponse>;
|
||||
readonly isCreateButtonDisabled: boolean;
|
||||
readonly onClickCreateButton: () => void;
|
||||
};
|
||||
|
||||
function Footer({
|
||||
|
|
|
@ -9,9 +9,9 @@ import type { ConnectorGroup } from '@/types/connector';
|
|||
import * as styles from './index.module.scss';
|
||||
|
||||
type Props = {
|
||||
connectorGroup: ConnectorGroup<ConnectorFactoryResponse & { added: boolean }>;
|
||||
connectorId?: string;
|
||||
onConnectorIdChange: (value: string) => void;
|
||||
readonly connectorGroup: ConnectorGroup<ConnectorFactoryResponse & { added: boolean }>;
|
||||
readonly connectorId?: string;
|
||||
readonly onConnectorIdChange: (value: string) => void;
|
||||
};
|
||||
|
||||
function PlatformSelector({ connectorGroup, connectorId, onConnectorIdChange }: Props) {
|
||||
|
|
|
@ -6,7 +6,7 @@ import * as radioGroupStyles from '../ConnectorRadioGroup/index.module.scss';
|
|||
import * as styles from './index.module.scss';
|
||||
|
||||
type Props = {
|
||||
numberOfLoadingConnectors?: number;
|
||||
readonly numberOfLoadingConnectors?: number;
|
||||
};
|
||||
|
||||
function Skeleton({ numberOfLoadingConnectors = 8 }: Props) {
|
||||
|
|
|
@ -22,9 +22,9 @@ import * as styles from './index.module.scss';
|
|||
import { compareConnectors, getConnectorRadioGroupSize, getModalTitle } from './utils';
|
||||
|
||||
type Props = {
|
||||
isOpen: boolean;
|
||||
type?: ConnectorType;
|
||||
onClose?: (connectorId?: string) => void;
|
||||
readonly isOpen: boolean;
|
||||
readonly type?: ConnectorType;
|
||||
readonly onClose?: (connectorId?: string) => void;
|
||||
};
|
||||
|
||||
function CreateConnectorForm({ onClose, isOpen: isFormOpen, type }: Props) {
|
||||
|
|
|
@ -10,7 +10,7 @@ import { ReservedPlanName } from '@/types/subscriptions';
|
|||
import * as styles from './index.module.scss';
|
||||
|
||||
type Props = {
|
||||
tag: TenantTag;
|
||||
readonly tag: TenantTag;
|
||||
};
|
||||
|
||||
const descriptionMap: Record<TenantTag, AdminConsoleKey> = {
|
||||
|
|
|
@ -7,7 +7,7 @@ import * as styles from './index.module.scss';
|
|||
import useFeaturedPlanContent from './use-featured-plan-content';
|
||||
|
||||
type Props = {
|
||||
planId: string;
|
||||
readonly planId: string;
|
||||
};
|
||||
|
||||
function FeaturedPlanContent({ planId }: Props) {
|
||||
|
|
|
@ -18,8 +18,8 @@ import FeaturedPlanContent from './FeaturedPlanContent';
|
|||
import * as styles from './index.module.scss';
|
||||
|
||||
type Props = {
|
||||
plan: SubscriptionPlan;
|
||||
onSelect: () => void;
|
||||
readonly plan: SubscriptionPlan;
|
||||
readonly onSelect: () => void;
|
||||
};
|
||||
|
||||
function PlanCardItem({ plan, onSelect }: Props) {
|
||||
|
|
|
@ -22,8 +22,8 @@ import PlanCardItem from './PlanCardItem';
|
|||
import * as styles from './index.module.scss';
|
||||
|
||||
type Props = {
|
||||
tenantData?: CreateTenantData;
|
||||
onClose: (tenant?: TenantResponse) => void;
|
||||
readonly tenantData?: CreateTenantData;
|
||||
readonly onClose: (tenant?: TenantResponse) => void;
|
||||
};
|
||||
|
||||
function SelectTenantPlanModal({ tenantData, onClose }: Props) {
|
||||
|
|
|
@ -23,8 +23,8 @@ import * as styles from './index.module.scss';
|
|||
import { type CreateTenantData } from './type';
|
||||
|
||||
type Props = {
|
||||
isOpen: boolean;
|
||||
onClose: (tenant?: TenantResponse) => void;
|
||||
readonly isOpen: boolean;
|
||||
readonly onClose: (tenant?: TenantResponse) => void;
|
||||
};
|
||||
|
||||
const availableTags = [TenantTag.Development, TenantTag.Production];
|
||||
|
|
|
@ -2,7 +2,7 @@ import type { Nullable } from '@silverhand/essentials';
|
|||
import { isValid } from 'date-fns';
|
||||
|
||||
type Props = {
|
||||
children: Nullable<string | number>;
|
||||
readonly children: Nullable<string | number>;
|
||||
};
|
||||
|
||||
function DateTime({ children }: Props) {
|
||||
|
|
|
@ -6,12 +6,12 @@ import UnnamedTrans from '@/components/UnnamedTrans';
|
|||
import ConfirmModal from '@/ds-components/ConfirmModal';
|
||||
|
||||
type Props = {
|
||||
data: ConnectorResponse;
|
||||
isOpen: boolean;
|
||||
isInUse: boolean;
|
||||
isLoading: boolean;
|
||||
onCancel: () => void;
|
||||
onConfirm: () => void;
|
||||
readonly data: ConnectorResponse;
|
||||
readonly isOpen: boolean;
|
||||
readonly isInUse: boolean;
|
||||
readonly isLoading: boolean;
|
||||
readonly onCancel: () => void;
|
||||
readonly onConfirm: () => void;
|
||||
};
|
||||
|
||||
function DeleteConnectorConfirmModal({
|
||||
|
|
|
@ -6,12 +6,12 @@ import SubmitFormChangesActionBar from '../SubmitFormChangesActionBar';
|
|||
import * as styles from './index.module.scss';
|
||||
|
||||
type Props = {
|
||||
autoComplete?: string;
|
||||
isDirty: boolean;
|
||||
isSubmitting: boolean;
|
||||
onSubmit: () => Promise<void>;
|
||||
onDiscard: () => void;
|
||||
children: ReactNode;
|
||||
readonly autoComplete?: string;
|
||||
readonly isDirty: boolean;
|
||||
readonly isSubmitting: boolean;
|
||||
readonly onSubmit: () => Promise<void>;
|
||||
readonly onDiscard: () => void;
|
||||
readonly children: ReactNode;
|
||||
};
|
||||
|
||||
function DetailsForm({
|
||||
|
|
|
@ -53,45 +53,45 @@ type Props = {
|
|||
/**
|
||||
* The main 60x60 icon on the very left
|
||||
*/
|
||||
icon: ReactElement<HTMLElement>;
|
||||
readonly icon: ReactElement<HTMLElement>;
|
||||
/**
|
||||
* The main title of the header
|
||||
*/
|
||||
title: ReactNode;
|
||||
readonly title: ReactNode;
|
||||
/**
|
||||
* Shows a subtitle in the second row
|
||||
* Example usage: Secondary information of the user (if any) in user details page
|
||||
*/
|
||||
subtitle?: ReactNode;
|
||||
readonly subtitle?: ReactNode;
|
||||
/**
|
||||
* Shows a tag in the second row of the header metadata
|
||||
* Example usage: Application type "Native / SPA / Traditional"
|
||||
*/
|
||||
primaryTag?: ReactNode;
|
||||
readonly primaryTag?: ReactNode;
|
||||
/**
|
||||
* Shows a status tag in the second row of the header metadata
|
||||
* Example usage: Connector status "In use / Not in use" in connector details page
|
||||
*/
|
||||
statusTag?: StatusTag;
|
||||
readonly statusTag?: StatusTag;
|
||||
/**
|
||||
* Shows the entity identifier in a "Copy to clipboard" component
|
||||
* Example usage: "App ID" in application details page
|
||||
*/
|
||||
identifier?: Identifier;
|
||||
readonly identifier?: Identifier;
|
||||
/**
|
||||
* Shows an additional action button in the header, next to the "...(More)" button
|
||||
* Example usage: "Check Guide" button in application details page
|
||||
*/
|
||||
additionalActionButton?: AdditionalActionButton;
|
||||
readonly additionalActionButton?: AdditionalActionButton;
|
||||
/**
|
||||
* Shows additional custom element in the header, next to the "...(More)" button
|
||||
* Example usage (special use case): "Total email sent (count)" in Logto email connector
|
||||
*/
|
||||
additionalCustomElement?: ReactElement<ResponsiveCustomElement>;
|
||||
readonly additionalCustomElement?: ReactElement<ResponsiveCustomElement>;
|
||||
/**
|
||||
* Dropdown action menu items nested in the "...(More)" button
|
||||
*/
|
||||
actionMenuItems?: MenuItem[];
|
||||
readonly actionMenuItems?: MenuItem[];
|
||||
};
|
||||
|
||||
function DetailsPageHeader({
|
||||
|
|
|
@ -15,13 +15,13 @@ import Skeleton from './Skeleton';
|
|||
import * as styles from './index.module.scss';
|
||||
|
||||
type Props = {
|
||||
backLink: To;
|
||||
backLinkTitle?: AdminConsoleKey | ReactElement<typeof DangerousRaw>;
|
||||
isLoading?: boolean;
|
||||
error?: RequestError;
|
||||
onRetry?: () => void;
|
||||
children: ReactNode;
|
||||
className?: string;
|
||||
readonly backLink: To;
|
||||
readonly backLinkTitle?: AdminConsoleKey | ReactElement<typeof DangerousRaw>;
|
||||
readonly isLoading?: boolean;
|
||||
readonly error?: RequestError;
|
||||
readonly onRetry?: () => void;
|
||||
readonly children: ReactNode;
|
||||
readonly className?: string;
|
||||
};
|
||||
|
||||
function DetailsPage({
|
||||
|
|
|
@ -16,7 +16,7 @@ const domainStatusToTag: Record<
|
|||
};
|
||||
|
||||
type Props = {
|
||||
status: DomainStatus;
|
||||
readonly status: DomainStatus;
|
||||
};
|
||||
|
||||
function DomainStatusTag({ status }: Props) {
|
||||
|
|
|
@ -9,11 +9,11 @@ import Spacer from '@/ds-components/Spacer';
|
|||
import * as styles from './index.module.scss';
|
||||
|
||||
type Props = {
|
||||
title?: AdminConsoleKey;
|
||||
subtitle?: AdminConsoleKey;
|
||||
isOpen: boolean;
|
||||
children: React.ReactNode;
|
||||
onClose?: () => void;
|
||||
readonly title?: AdminConsoleKey;
|
||||
readonly subtitle?: AdminConsoleKey;
|
||||
readonly isOpen: boolean;
|
||||
readonly children: React.ReactNode;
|
||||
readonly onClose?: () => void;
|
||||
};
|
||||
|
||||
function Drawer({ title, subtitle, isOpen, children, onClose }: Props) {
|
||||
|
|
|
@ -18,11 +18,11 @@ export type EditScopeData = {
|
|||
|
||||
type Props = {
|
||||
/** The scope name displayed in the name input field */
|
||||
scopeName: string;
|
||||
readonly scopeName: string;
|
||||
/** The data to edit */
|
||||
data: EditScopeData;
|
||||
readonly data: EditScopeData;
|
||||
/** Determines the translation keys for texts in the editor modal */
|
||||
text: {
|
||||
readonly text: {
|
||||
/** The translation key of the modal title */
|
||||
title: AdminConsoleKey;
|
||||
/** The field name translation key for the name input */
|
||||
|
@ -32,8 +32,8 @@ type Props = {
|
|||
/** The placeholder translation key for the description input */
|
||||
descriptionPlaceholder: AdminConsoleKey;
|
||||
};
|
||||
onSubmit: (editedData: EditScopeData) => Promise<void>;
|
||||
onClose: () => void;
|
||||
readonly onSubmit: (editedData: EditScopeData) => Promise<void>;
|
||||
readonly onClose: () => void;
|
||||
};
|
||||
|
||||
function EditScopeModal({ scopeName, data, text, onClose, onSubmit }: Props) {
|
||||
|
|
|
@ -10,9 +10,9 @@ import useTheme from '@/hooks/use-theme';
|
|||
import * as styles from './index.module.scss';
|
||||
|
||||
type Props = {
|
||||
title?: ReactNode;
|
||||
size?: 'large' | 'medium' | 'small';
|
||||
className?: string;
|
||||
readonly title?: ReactNode;
|
||||
readonly size?: 'large' | 'medium' | 'small';
|
||||
readonly className?: string;
|
||||
};
|
||||
|
||||
function EmptyDataPlaceholder({ title, size = 'medium', className }: Props) {
|
||||
|
|
|
@ -8,7 +8,7 @@ import { getUserTitle } from '@/utils/user';
|
|||
import * as styles from './index.module.scss';
|
||||
|
||||
type UserItemProps = {
|
||||
entity: User;
|
||||
readonly entity: User;
|
||||
};
|
||||
|
||||
export function UserItem({ entity }: UserItemProps) {
|
||||
|
@ -22,7 +22,7 @@ export function UserItem({ entity }: UserItemProps) {
|
|||
}
|
||||
|
||||
type ApplicationItemProps = {
|
||||
entity: Application;
|
||||
readonly entity: Application;
|
||||
};
|
||||
|
||||
export function ApplicationItem({ entity }: ApplicationItemProps) {
|
||||
|
|
|
@ -28,11 +28,11 @@ type SearchProps = {
|
|||
};
|
||||
|
||||
export type Props<T> = {
|
||||
searchProps: SearchProps;
|
||||
onChange: (value: T[]) => void;
|
||||
selectedEntities: T[];
|
||||
emptyPlaceholder: AdminConsoleKey;
|
||||
renderEntity: (entity: T) => ReactNode;
|
||||
readonly searchProps: SearchProps;
|
||||
readonly onChange: (value: T[]) => void;
|
||||
readonly selectedEntities: T[];
|
||||
readonly emptyPlaceholder: AdminConsoleKey;
|
||||
readonly renderEntity: (entity: T) => ReactNode;
|
||||
};
|
||||
|
||||
const pageSize = defaultPageSize;
|
||||
|
|
|
@ -7,10 +7,10 @@ import { onKeyDownHandler } from '@/utils/a11y';
|
|||
import * as styles from './index.module.scss';
|
||||
|
||||
type Props<T> = {
|
||||
entity: T;
|
||||
isSelected: boolean;
|
||||
onSelect: () => void;
|
||||
render: (entity: T) => ReactNode;
|
||||
readonly entity: T;
|
||||
readonly isSelected: boolean;
|
||||
readonly onSelect: () => void;
|
||||
readonly render: (entity: T) => ReactNode;
|
||||
};
|
||||
|
||||
function SourceEntityItem<T extends Identifiable>({
|
||||
|
|
|
@ -8,9 +8,9 @@ import TargetEntityItem from '../TargetEntityItem';
|
|||
import * as styles from './index.module.scss';
|
||||
|
||||
type Props<T> = {
|
||||
renderEntity: (entity: T) => React.ReactNode;
|
||||
selectedEntities: T[];
|
||||
onChange: (value: T[]) => void;
|
||||
readonly renderEntity: (entity: T) => React.ReactNode;
|
||||
readonly selectedEntities: T[];
|
||||
readonly onChange: (value: T[]) => void;
|
||||
};
|
||||
|
||||
function TargetEntitiesBox<T extends Identifiable>({
|
||||
|
|
|
@ -7,9 +7,9 @@ import { type Identifiable } from '@/types/general';
|
|||
import * as styles from './index.module.scss';
|
||||
|
||||
type Props<T> = {
|
||||
entity: T;
|
||||
render: (entity: T) => ReactNode;
|
||||
onDelete: () => void;
|
||||
readonly entity: T;
|
||||
readonly render: (entity: T) => ReactNode;
|
||||
readonly onDelete: () => void;
|
||||
};
|
||||
|
||||
function TargetEntityItem<T extends Identifiable>({ entity, render, onDelete }: Props<T>) {
|
||||
|
|
|
@ -8,7 +8,7 @@ import TargetEntitiesBox from './components/TargetEntitiesBox';
|
|||
import * as styles from './index.module.scss';
|
||||
|
||||
type Props<T extends Identifiable> = SourceProps<T> & {
|
||||
errorMessage?: string;
|
||||
readonly errorMessage?: string;
|
||||
};
|
||||
|
||||
function EntitiesTransfer<T extends Identifiable>({ errorMessage, ...props }: Props<T>) {
|
||||
|
|
|
@ -9,7 +9,7 @@ import classNames from 'classnames';
|
|||
import * as styles from './index.module.scss';
|
||||
|
||||
type Props = {
|
||||
className?: string;
|
||||
readonly className?: string;
|
||||
};
|
||||
|
||||
function BetaTag({ className }: Props) {
|
||||
|
|
|
@ -14,10 +14,10 @@ type Props = {
|
|||
* plan has NO access to the feature (paywall), but it will always be visible for dev
|
||||
* tenants.
|
||||
*/
|
||||
isVisible: boolean;
|
||||
readonly isVisible: boolean;
|
||||
/** The minimum plan required to use the feature. */
|
||||
plan: Exclude<ReservedPlanId, ReservedPlanId.Free | ReservedPlanId.Development>;
|
||||
className?: string;
|
||||
readonly plan: Exclude<ReservedPlanId, ReservedPlanId.Free | ReservedPlanId.Development>;
|
||||
readonly className?: string;
|
||||
};
|
||||
|
||||
/**
|
||||
|
|
|
@ -5,8 +5,8 @@ import Card from '@/ds-components/Card';
|
|||
import * as styles from './index.module.scss';
|
||||
|
||||
type Props = {
|
||||
introduction: ReactNode;
|
||||
children: ReactNode;
|
||||
readonly introduction: ReactNode;
|
||||
readonly children: ReactNode;
|
||||
};
|
||||
|
||||
function FormCardLayout({ introduction, children }: Props) {
|
||||
|
|
|
@ -3,7 +3,7 @@ import FormCardLayout from '../FormCardLayout';
|
|||
import * as styles from './index.module.scss';
|
||||
|
||||
type Props = {
|
||||
formFieldCount?: number;
|
||||
readonly formFieldCount?: number;
|
||||
};
|
||||
|
||||
function Skeleton({ formFieldCount = 4 }: Props) {
|
||||
|
|
|
@ -9,12 +9,14 @@ import FormCardLayout from './FormCardLayout';
|
|||
import * as styles from './index.module.scss';
|
||||
|
||||
type Props = {
|
||||
title: AdminConsoleKey;
|
||||
tag?: ReactNode;
|
||||
description?: AdminConsoleKey;
|
||||
descriptionInterpolation?: Record<string, unknown>;
|
||||
learnMoreLink?: Pick<TextLinkProps, 'href' | 'targetBlank'> & { linkText?: AdminConsoleKey };
|
||||
children: ReactNode;
|
||||
readonly title: AdminConsoleKey;
|
||||
readonly tag?: ReactNode;
|
||||
readonly description?: AdminConsoleKey;
|
||||
readonly descriptionInterpolation?: Record<string, unknown>;
|
||||
readonly learnMoreLink?: Pick<TextLinkProps, 'href' | 'targetBlank'> & {
|
||||
linkText?: AdminConsoleKey;
|
||||
};
|
||||
readonly children: ReactNode;
|
||||
};
|
||||
|
||||
function FormCard({
|
||||
|
|
|
@ -19,10 +19,10 @@ export type SelectedGuide = {
|
|||
};
|
||||
|
||||
type Props = {
|
||||
data: Guide;
|
||||
onClick: (data: SelectedGuide) => void;
|
||||
hasBorder?: boolean;
|
||||
hasButton?: boolean;
|
||||
readonly data: Guide;
|
||||
readonly onClick: (data: SelectedGuide) => void;
|
||||
readonly hasBorder?: boolean;
|
||||
readonly hasButton?: boolean;
|
||||
};
|
||||
|
||||
function GuideCard({ data, onClick, hasBorder, hasButton }: Props) {
|
||||
|
|
|
@ -8,12 +8,12 @@ import GuideCard, { type SelectedGuide } from '../GuideCard';
|
|||
import * as styles from './index.module.scss';
|
||||
|
||||
type Props = {
|
||||
className?: string;
|
||||
categoryName?: string;
|
||||
guides?: readonly Guide[];
|
||||
hasCardBorder?: boolean;
|
||||
hasCardButton?: boolean;
|
||||
onClickGuide: (data: SelectedGuide) => void;
|
||||
readonly className?: string;
|
||||
readonly categoryName?: string;
|
||||
readonly guides?: readonly Guide[];
|
||||
readonly hasCardBorder?: boolean;
|
||||
readonly hasCardButton?: boolean;
|
||||
readonly onClickGuide: (data: SelectedGuide) => void;
|
||||
};
|
||||
|
||||
function GuideCardGroup(
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
@use '@/scss/dimensions' as dim;
|
||||
|
||||
.actionBar {
|
||||
inset: auto 0 0 0;
|
||||
inset: auto 0 0;
|
||||
width: 100%;
|
||||
padding: _.unit(4) _.unit(6);
|
||||
background-color: var(--color-layer-1);
|
||||
|
|
|
@ -7,10 +7,10 @@ import DynamicT from '@/ds-components/DynamicT';
|
|||
import * as styles from './index.module.scss';
|
||||
|
||||
type Props = {
|
||||
wrapperClassName?: string;
|
||||
content: AdminConsoleKey;
|
||||
buttonText: AdminConsoleKey;
|
||||
onClick: () => void;
|
||||
readonly wrapperClassName?: string;
|
||||
readonly content: AdminConsoleKey;
|
||||
readonly buttonText: AdminConsoleKey;
|
||||
readonly onClick: () => void;
|
||||
};
|
||||
|
||||
export default function ModalFooter({ wrapperClassName, content, buttonText, onClick }: Props) {
|
||||
|
|
Some files were not shown because too many files have changed in this diff Show more
Loading…
Reference in a new issue