@web3jskit/walletkit 0.0.1
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/README.md +1 -0
- package/dist/package.json +42 -0
- package/dist/src/assets/svg/dataBase.d.ts +6 -0
- package/dist/src/assets/svg/dataBase.js +7 -0
- package/dist/src/assets/svg/dataBase.js.map +1 -0
- package/dist/src/assets/svg/metaMaskWallet.d.ts +1 -0
- package/dist/src/assets/svg/metaMaskWallet.js +35 -0
- package/dist/src/assets/svg/metaMaskWallet.js.map +1 -0
- package/dist/src/components/ConnectButton/ConnectedInfo.d.ts +1 -0
- package/dist/src/components/ConnectButton/ConnectedInfo.js +12 -0
- package/dist/src/components/ConnectButton/ConnectedInfo.js.map +1 -0
- package/dist/src/components/ConnectButton/index.d.ts +8 -0
- package/dist/src/components/ConnectButton/index.js +15 -0
- package/dist/src/components/ConnectButton/index.js.map +1 -0
- package/dist/src/components/Connecting/index.d.ts +5 -0
- package/dist/src/components/Connecting/index.js +10 -0
- package/dist/src/components/Connecting/index.js.map +1 -0
- package/dist/src/components/Connecting/style.d.ts +2 -0
- package/dist/src/components/Connecting/style.js +52 -0
- package/dist/src/components/Connecting/style.js.map +1 -0
- package/dist/src/components/GetWallet/index.d.ts +6 -0
- package/dist/src/components/GetWallet/index.js +38 -0
- package/dist/src/components/GetWallet/index.js.map +1 -0
- package/dist/src/components/GetWallet/style.d.ts +2 -0
- package/dist/src/components/GetWallet/style.js +115 -0
- package/dist/src/components/GetWallet/style.js.map +1 -0
- package/dist/src/components/Header/ModalHeader.d.ts +7 -0
- package/dist/src/components/Header/ModalHeader.js +10 -0
- package/dist/src/components/Header/ModalHeader.js.map +1 -0
- package/dist/src/components/Header/style.d.ts +2 -0
- package/dist/src/components/Header/style.js +73 -0
- package/dist/src/components/Header/style.js.map +1 -0
- package/dist/src/components/Icon/index.d.ts +23 -0
- package/dist/src/components/Icon/index.js +47 -0
- package/dist/src/components/Icon/index.js.map +1 -0
- package/dist/src/components/Introduce/index.d.ts +5 -0
- package/dist/src/components/Introduce/index.js +9 -0
- package/dist/src/components/Introduce/index.js.map +1 -0
- package/dist/src/components/Introduce/style.d.ts +2 -0
- package/dist/src/components/Introduce/style.js +72 -0
- package/dist/src/components/Introduce/style.js.map +1 -0
- package/dist/src/components/Modal/ConnectModal.d.ts +8 -0
- package/dist/src/components/Modal/ConnectModal.js +82 -0
- package/dist/src/components/Modal/ConnectModal.js.map +1 -0
- package/dist/src/components/Modal/WalletInfoModal.d.ts +5 -0
- package/dist/src/components/Modal/WalletInfoModal.js +40 -0
- package/dist/src/components/Modal/WalletInfoModal.js.map +1 -0
- package/dist/src/components/Modal/index.d.ts +12 -0
- package/dist/src/components/Modal/index.js +53 -0
- package/dist/src/components/Modal/index.js.map +1 -0
- package/dist/src/components/Modal/style.d.ts +5 -0
- package/dist/src/components/Modal/style.js +156 -0
- package/dist/src/components/Modal/style.js.map +1 -0
- package/dist/src/components/SVGs/backArrowSvg.d.ts +2 -0
- package/dist/src/components/SVGs/backArrowSvg.js +4 -0
- package/dist/src/components/SVGs/backArrowSvg.js.map +1 -0
- package/dist/src/components/SVGs/closeSvg.d.ts +2 -0
- package/dist/src/components/SVGs/closeSvg.js +4 -0
- package/dist/src/components/SVGs/closeSvg.js.map +1 -0
- package/dist/src/components/SVGs/copiedSvg.d.ts +2 -0
- package/dist/src/components/SVGs/copiedSvg.js +4 -0
- package/dist/src/components/SVGs/copiedSvg.js.map +1 -0
- package/dist/src/components/SVGs/copySvg.d.ts +2 -0
- package/dist/src/components/SVGs/copySvg.js +4 -0
- package/dist/src/components/SVGs/copySvg.js.map +1 -0
- package/dist/src/components/SVGs/exitSvg.d.ts +2 -0
- package/dist/src/components/SVGs/exitSvg.js +4 -0
- package/dist/src/components/SVGs/exitSvg.js.map +1 -0
- package/dist/src/components/SVGs/metamaskQrCode.d.ts +2 -0
- package/dist/src/components/SVGs/metamaskQrCode.js +4 -0
- package/dist/src/components/SVGs/metamaskQrCode.js.map +1 -0
- package/dist/src/components/SVGs/spinSvg.d.ts +4 -0
- package/dist/src/components/SVGs/spinSvg.js +4 -0
- package/dist/src/components/SVGs/spinSvg.js.map +1 -0
- package/dist/src/components/Text/index.d.ts +18 -0
- package/dist/src/components/Text/index.js +23 -0
- package/dist/src/components/Text/index.js.map +1 -0
- package/dist/src/components/WalletKitProvider/ChainProvider.d.ts +9 -0
- package/dist/src/components/WalletKitProvider/ChainProvider.js +21 -0
- package/dist/src/components/WalletKitProvider/ChainProvider.js.map +1 -0
- package/dist/src/components/WalletKitProvider/I18nProvider.d.ts +13 -0
- package/dist/src/components/WalletKitProvider/I18nProvider.js +41 -0
- package/dist/src/components/WalletKitProvider/I18nProvider.js.map +1 -0
- package/dist/src/components/WalletKitProvider/ThemeProvider.d.ts +8 -0
- package/dist/src/components/WalletKitProvider/ThemeProvider.js +12 -0
- package/dist/src/components/WalletKitProvider/ThemeProvider.js.map +1 -0
- package/dist/src/components/WalletKitProvider/index.d.ts +11 -0
- package/dist/src/components/WalletKitProvider/index.js +14 -0
- package/dist/src/components/WalletKitProvider/index.js.map +1 -0
- package/dist/src/components/WalletList/index.d.ts +7 -0
- package/dist/src/components/WalletList/index.js +9 -0
- package/dist/src/components/WalletList/index.js.map +1 -0
- package/dist/src/components/WalletList/style.d.ts +2 -0
- package/dist/src/components/WalletList/style.js +101 -0
- package/dist/src/components/WalletList/style.js.map +1 -0
- package/dist/src/components/WalletTriggerButton/index.d.ts +10 -0
- package/dist/src/components/WalletTriggerButton/index.js +27 -0
- package/dist/src/components/WalletTriggerButton/index.js.map +1 -0
- package/dist/src/components/WalletTriggerButton/style.d.ts +2 -0
- package/dist/src/components/WalletTriggerButton/style.js +50 -0
- package/dist/src/components/WalletTriggerButton/style.js.map +1 -0
- package/dist/src/hooks/useWalletKit.d.ts +6 -0
- package/dist/src/hooks/useWalletKit.js +20 -0
- package/dist/src/hooks/useWalletKit.js.map +1 -0
- package/dist/src/index.d.ts +8 -0
- package/dist/src/index.js +9 -0
- package/dist/src/index.js.map +1 -0
- package/dist/src/locals/i18n.d.ts +2 -0
- package/dist/src/locals/i18n.js +17 -0
- package/dist/src/locals/i18n.js.map +1 -0
- package/dist/src/locals/languages/en.json +27 -0
- package/dist/src/locals/languages/zh.json +27 -0
- package/dist/src/locals/resources.d.ts +60 -0
- package/dist/src/locals/resources.js +11 -0
- package/dist/src/locals/resources.js.map +1 -0
- package/dist/src/stores/SlotsWalletStore.d.ts +18 -0
- package/dist/src/stores/SlotsWalletStore.js +33 -0
- package/dist/src/stores/SlotsWalletStore.js.map +1 -0
- package/dist/src/stores/index.d.ts +34 -0
- package/dist/src/stores/index.js +41 -0
- package/dist/src/stores/index.js.map +1 -0
- package/dist/src/styled/index.d.ts +17 -0
- package/dist/src/styled/index.js +76 -0
- package/dist/src/styled/index.js.map +1 -0
- package/dist/src/test/getwalletprovider.test.d.ts +1 -0
- package/dist/src/test/getwalletprovider.test.js +10 -0
- package/dist/src/test/getwalletprovider.test.js.map +1 -0
- package/dist/src/test/setup.d.ts +1 -0
- package/dist/src/test/setup.js +7 -0
- package/dist/src/test/setup.js.map +1 -0
- package/dist/src/theme/index.d.ts +53 -0
- package/dist/src/theme/index.js +92 -0
- package/dist/src/theme/index.js.map +1 -0
- package/dist/src/types/configType.d.ts +2 -0
- package/dist/src/types/configType.js +2 -0
- package/dist/src/types/configType.js.map +1 -0
- package/dist/src/types/slotsType.d.ts +23 -0
- package/dist/src/types/slotsType.js +2 -0
- package/dist/src/types/slotsType.js.map +1 -0
- package/dist/src/utils/formatter.d.ts +1 -0
- package/dist/src/utils/formatter.js +6 -0
- package/dist/src/utils/formatter.js.map +1 -0
- package/dist/src/utils/generateAvatar.d.ts +4 -0
- package/dist/src/utils/generateAvatar.js +32 -0
- package/dist/src/utils/generateAvatar.js.map +1 -0
- package/dist/src/wallets/GelWallet/index.d.ts +0 -0
- package/dist/src/wallets/GelWallet/index.js +2 -0
- package/dist/src/wallets/GelWallet/index.js.map +1 -0
- package/dist/src/wallets/SlotsWallets/index.d.ts +3 -0
- package/dist/src/wallets/SlotsWallets/index.js +26 -0
- package/dist/src/wallets/SlotsWallets/index.js.map +1 -0
- package/dist/tsconfig.build.tsbuildinfo +1 -0
- package/package.json +42 -0
- package/src/assets/svg/dataBase.ts +17 -0
- package/src/assets/svg/metaMaskWallet.ts +35 -0
- package/src/components/ConnectButton/ConnectedInfo.tsx +17 -0
- package/src/components/ConnectButton/index.tsx +41 -0
- package/src/components/Connecting/index.tsx +26 -0
- package/src/components/Connecting/style.ts +53 -0
- package/src/components/GetWallet/index.tsx +88 -0
- package/src/components/GetWallet/style.ts +116 -0
- package/src/components/Header/ModalHeader.tsx +24 -0
- package/src/components/Header/style.ts +74 -0
- package/src/components/Icon/index.tsx +120 -0
- package/src/components/Introduce/index.tsx +30 -0
- package/src/components/Introduce/style.ts +73 -0
- package/src/components/Modal/ConnectModal.tsx +131 -0
- package/src/components/Modal/WalletInfoModal.tsx +82 -0
- package/src/components/Modal/index.tsx +80 -0
- package/src/components/Modal/style.ts +160 -0
- package/src/components/SVGs/backArrowSvg.tsx +10 -0
- package/src/components/SVGs/closeSvg.tsx +11 -0
- package/src/components/SVGs/copiedSvg.tsx +11 -0
- package/src/components/SVGs/copySvg.tsx +11 -0
- package/src/components/SVGs/exitSvg.tsx +11 -0
- package/src/components/SVGs/metamaskQrCode.tsx +393 -0
- package/src/components/SVGs/spinSvg.tsx +10 -0
- package/src/components/Text/index.tsx +59 -0
- package/src/components/WalletKitProvider/ChainProvider.tsx +34 -0
- package/src/components/WalletKitProvider/I18nProvider.tsx +52 -0
- package/src/components/WalletKitProvider/ThemeProvider.tsx +16 -0
- package/src/components/WalletKitProvider/index.tsx +40 -0
- package/src/components/WalletList/index.tsx +35 -0
- package/src/components/WalletList/style.ts +101 -0
- package/src/components/WalletTriggerButton/index.tsx +50 -0
- package/src/components/WalletTriggerButton/style.ts +51 -0
- package/src/default.d.ts +18 -0
- package/src/hooks/useWalletKit.ts +38 -0
- package/src/index.ts +8 -0
- package/src/locals/i18n.ts +19 -0
- package/src/locals/languages/en.json +27 -0
- package/src/locals/languages/zh.json +27 -0
- package/src/locals/resources.ts +11 -0
- package/src/stores/SlotsWalletStore.ts +48 -0
- package/src/stores/index.ts +74 -0
- package/src/styled/index.ts +79 -0
- package/src/test/getwalletprovider.test.ts +9 -0
- package/src/test/setup.ts +7 -0
- package/src/theme/index.ts +93 -0
- package/src/theme/styled.d.ts +30 -0
- package/src/types/configType.ts +2 -0
- package/src/types/slotsType.ts +23 -0
- package/src/utils/formatter.ts +4 -0
- package/src/utils/generateAvatar.ts +35 -0
- package/src/wallets/GelWallet/index.ts +0 -0
- package/src/wallets/SlotsWallets/index.ts +30 -0
- package/tsconfig.build.json +4 -0
- package/tsconfig.json +55 -0
- package/vitest.config.ts +10 -0
|
@@ -0,0 +1,93 @@
|
|
|
1
|
+
import { createGlobalStyle } from 'styled-components';
|
|
2
|
+
|
|
3
|
+
export const themeStyle = {
|
|
4
|
+
darkMode: {
|
|
5
|
+
textColor: '#ffffff',
|
|
6
|
+
textColor1: '#757575 ',
|
|
7
|
+
textColor2: '#ffffff',
|
|
8
|
+
textColor3: '#5c5c5c',
|
|
9
|
+
textColor4: '#ffffff',
|
|
10
|
+
textColor5: '#858585',
|
|
11
|
+
buttonBg: '#ffffff',
|
|
12
|
+
buttonColor: '#000000',
|
|
13
|
+
modalBg: '#191919',
|
|
14
|
+
modalSideBg: '#171717',
|
|
15
|
+
itemActiveBg: 'rgba(255, 255, 255, 0.20)',
|
|
16
|
+
itemHoverBg: 'rgba(255, 255, 255, 0.10)',
|
|
17
|
+
blue: '#00a6ff',
|
|
18
|
+
gray: '#acacac',
|
|
19
|
+
borderColor: '#2a2a2a',
|
|
20
|
+
backArrowColor: '#fbfbfb',
|
|
21
|
+
closeBtnBg: 'rgba(146, 146, 146, .2)',
|
|
22
|
+
closeBtnColor: '#ffffff',
|
|
23
|
+
closeBtnHoverBg: 'rgba(146, 146, 146, .4)',
|
|
24
|
+
infoBtnBg: 'rgba(224, 232, 255, 0.1)',
|
|
25
|
+
infoBtnHoverBg: 'rgba(224, 232, 255, 0.2)',
|
|
26
|
+
cardBg: 'linear-gradient(126deg, rgba(120, 120, 120, 0.2) 9.49%, rgba(0, 0, 0, 0) 71.04%), #1A1B1F',
|
|
27
|
+
spinColor: '#ffffff'
|
|
28
|
+
},
|
|
29
|
+
lightMode: {
|
|
30
|
+
textColor: '#000000',
|
|
31
|
+
textColor1: '#757575',
|
|
32
|
+
textColor2: '#444444',
|
|
33
|
+
textColor3: '#a8a8a8',
|
|
34
|
+
textColor4: '#111111',
|
|
35
|
+
textColor5: '#858585',
|
|
36
|
+
buttonBg: '#000000',
|
|
37
|
+
buttonColor: '#ffffff',
|
|
38
|
+
modalBg: '#ffffff',
|
|
39
|
+
modalSideBg: '#f9f9f9',
|
|
40
|
+
itemActiveBg: 'rgba(0, 0, 0, 0.20)',
|
|
41
|
+
itemHoverBg: 'rgba(0, 0, 0, 0.10)',
|
|
42
|
+
blue: '#00a6ff',
|
|
43
|
+
gray: '#acacac',
|
|
44
|
+
borderColor: '#f0f0f0',
|
|
45
|
+
backArrowColor: '#161617',
|
|
46
|
+
closeBtnBg: 'rgba(146, 146, 146, .3)',
|
|
47
|
+
closeBtnColor: '#ffffff',
|
|
48
|
+
closeBtnHoverBg: 'rgba(146, 146, 146, .5)',
|
|
49
|
+
infoBtnBg: 'rgba(0, 0, 0, 0.05)',
|
|
50
|
+
infoBtnHoverBg: 'rgba(0, 0, 0, 0.1)',
|
|
51
|
+
cardBg: 'linear-gradient(126deg,rgba(200, 200, 200, 0.2) 9.49%, rgba(255, 255, 255, 0) 71.04%),#f5f5f5',
|
|
52
|
+
spinColor: '#6a6a6a'
|
|
53
|
+
}
|
|
54
|
+
};
|
|
55
|
+
|
|
56
|
+
export const ThemedGlobalStyle = createGlobalStyle`
|
|
57
|
+
|
|
58
|
+
.gap-2 {
|
|
59
|
+
gap: 2px;
|
|
60
|
+
}
|
|
61
|
+
|
|
62
|
+
.gap-4 {
|
|
63
|
+
gap: 4px;
|
|
64
|
+
}
|
|
65
|
+
|
|
66
|
+
.gap-6 {
|
|
67
|
+
gap: 6px;
|
|
68
|
+
}
|
|
69
|
+
|
|
70
|
+
.gap-8 {
|
|
71
|
+
gap: 8px;
|
|
72
|
+
}
|
|
73
|
+
|
|
74
|
+
.gap-10 {
|
|
75
|
+
gap: 10px;
|
|
76
|
+
}
|
|
77
|
+
|
|
78
|
+
.gap-12 {
|
|
79
|
+
gap: 12px;
|
|
80
|
+
}
|
|
81
|
+
|
|
82
|
+
.gap-14 {
|
|
83
|
+
gap: 14px;
|
|
84
|
+
}
|
|
85
|
+
|
|
86
|
+
.gap-16 {
|
|
87
|
+
gap: 16px;
|
|
88
|
+
}
|
|
89
|
+
|
|
90
|
+
.pd-tb-10{
|
|
91
|
+
padding: 10px 0;
|
|
92
|
+
}
|
|
93
|
+
`;
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
// styled.d.ts
|
|
2
|
+
import 'styled-components';
|
|
3
|
+
|
|
4
|
+
declare module 'styled-components' {
|
|
5
|
+
export interface DefaultTheme {
|
|
6
|
+
textColor: string;
|
|
7
|
+
textColor1: string;
|
|
8
|
+
textColor2: string;
|
|
9
|
+
textColor3: string;
|
|
10
|
+
textColor4: string;
|
|
11
|
+
textColor5: string;
|
|
12
|
+
buttonBg: string;
|
|
13
|
+
buttonColor: string;
|
|
14
|
+
modalBg: string;
|
|
15
|
+
modalSideBg: string;
|
|
16
|
+
itemActiveBg: string;
|
|
17
|
+
itemHoverBg: string;
|
|
18
|
+
blue: string;
|
|
19
|
+
gray: string;
|
|
20
|
+
borderColor: string;
|
|
21
|
+
backArrowColor: string;
|
|
22
|
+
closeBtnBg: string;
|
|
23
|
+
closeBtnColor: string;
|
|
24
|
+
closeBtnHoverBg: string;
|
|
25
|
+
infoBtnBg: string;
|
|
26
|
+
infoBtnHoverBg: string;
|
|
27
|
+
cardBg: string;
|
|
28
|
+
spinColor: string;
|
|
29
|
+
}
|
|
30
|
+
}
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
export interface EIP6963ProviderInfo {
|
|
2
|
+
uuid: string;
|
|
3
|
+
name: string;
|
|
4
|
+
icon: string;
|
|
5
|
+
rdns: string;
|
|
6
|
+
}
|
|
7
|
+
export interface ISlots {
|
|
8
|
+
EIP6963ProviderInfo?: EIP6963ProviderInfo;
|
|
9
|
+
isEIP6963Provider?: boolean;
|
|
10
|
+
injected?: boolean;
|
|
11
|
+
provider: any;
|
|
12
|
+
namespace: string;
|
|
13
|
+
}
|
|
14
|
+
export interface ICreateSlots {
|
|
15
|
+
slots?: Array<ISlots>;
|
|
16
|
+
}
|
|
17
|
+
export interface ISlotsConnector {
|
|
18
|
+
uuid: string;
|
|
19
|
+
walletName: string;
|
|
20
|
+
walletIcon: string;
|
|
21
|
+
connector?: any;
|
|
22
|
+
connectorNamespace?: string;
|
|
23
|
+
}
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
export function generateRandomAvatar() {
|
|
2
|
+
const animalColors = {
|
|
3
|
+
'🐵': '#8B4513',
|
|
4
|
+
'🐶': '#A0522D',
|
|
5
|
+
'🐺': '#696969',
|
|
6
|
+
'🦊': '#FF8C00',
|
|
7
|
+
'🦝': '#808080',
|
|
8
|
+
'🐱': '#FAFAD2',
|
|
9
|
+
'🦁': '#FFA500',
|
|
10
|
+
'🐯': '#FF8C00',
|
|
11
|
+
'🐮': '#8B4513',
|
|
12
|
+
'🐷': '#FF8CBC',
|
|
13
|
+
'🐗': '#8B4513',
|
|
14
|
+
'🦒': '#FFD700',
|
|
15
|
+
'🐭': '#D3D3D3',
|
|
16
|
+
'🐹': '#DEB887',
|
|
17
|
+
'🐰': '#FFF5EE',
|
|
18
|
+
'🐻': '#8B4513',
|
|
19
|
+
'🐨': '#A9A9A9',
|
|
20
|
+
'🐼': '#FFFFFF',
|
|
21
|
+
'🐸': '#7CFC00'
|
|
22
|
+
};
|
|
23
|
+
|
|
24
|
+
const keys = Object.keys(animalColors) as (keyof typeof animalColors)[];
|
|
25
|
+
const randomIndex = Math.floor(Math.random() * keys.length);
|
|
26
|
+
const text = keys[randomIndex];
|
|
27
|
+
|
|
28
|
+
if (!text) {
|
|
29
|
+
throw new Error('Unexpected undefined value from keys[randomIndex]');
|
|
30
|
+
}
|
|
31
|
+
|
|
32
|
+
const bg = animalColors[text];
|
|
33
|
+
|
|
34
|
+
return { text, bg };
|
|
35
|
+
}
|
|
File without changes
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
import type { EIP6963ProviderInfo, ICreateSlots, ISlots } from '../../types/slotsType';
|
|
2
|
+
|
|
3
|
+
export function announceProvider(info: EIP6963ProviderInfo, provider: any) {
|
|
4
|
+
(window as any)['ethereum'] = provider;
|
|
5
|
+
try {
|
|
6
|
+
window.dispatchEvent(
|
|
7
|
+
new CustomEvent('eip6963:announceProvider', {
|
|
8
|
+
detail: Object.freeze({ info, provider })
|
|
9
|
+
})
|
|
10
|
+
);
|
|
11
|
+
window.dispatchEvent(new Event('eip6963:requestProvider'));
|
|
12
|
+
} catch (e) {
|
|
13
|
+
console.error(e);
|
|
14
|
+
}
|
|
15
|
+
}
|
|
16
|
+
|
|
17
|
+
export function createSlots({ slots }: ICreateSlots) {
|
|
18
|
+
if (slots && slots?.length) {
|
|
19
|
+
const providers: any = {};
|
|
20
|
+
|
|
21
|
+
slots?.map((slot: ISlots) => {
|
|
22
|
+
if (slot?.isEIP6963Provider && slot?.EIP6963ProviderInfo && !slot?.injected) {
|
|
23
|
+
announceProvider(slot.EIP6963ProviderInfo, slot.provider);
|
|
24
|
+
}
|
|
25
|
+
providers[slot.namespace] = slot.provider;
|
|
26
|
+
});
|
|
27
|
+
return providers;
|
|
28
|
+
}
|
|
29
|
+
return;
|
|
30
|
+
}
|
package/tsconfig.json
ADDED
|
@@ -0,0 +1,55 @@
|
|
|
1
|
+
{
|
|
2
|
+
"compilerOptions": {
|
|
3
|
+
"target": "ES2021",
|
|
4
|
+
"lib": ["DOM", "DOM.Iterable", "ESNext"],
|
|
5
|
+
"module": "ESNext",
|
|
6
|
+
"skipLibCheck": true,
|
|
7
|
+
"strict": true,
|
|
8
|
+
"forceConsistentCasingInFileNames": true,
|
|
9
|
+
"esModuleInterop": true,
|
|
10
|
+
"moduleResolution": "Bundler",
|
|
11
|
+
"experimentalDecorators": true,
|
|
12
|
+
"resolveJsonModule": true,
|
|
13
|
+
"removeComments": true,
|
|
14
|
+
"isolatedModules": true,
|
|
15
|
+
"allowJs": false,
|
|
16
|
+
"allowSyntheticDefaultImports": true,
|
|
17
|
+
"allowUnreachableCode": false,
|
|
18
|
+
"noUnusedLocals": true,
|
|
19
|
+
"noUnusedParameters": true,
|
|
20
|
+
"noImplicitReturns": true,
|
|
21
|
+
"noImplicitOverride": true,
|
|
22
|
+
"noFallthroughCasesInSwitch": true,
|
|
23
|
+
"noPropertyAccessFromIndexSignature": true,
|
|
24
|
+
"noUncheckedIndexedAccess": true,
|
|
25
|
+
"verbatimModuleSyntax": true,
|
|
26
|
+
"sourceMap": true,
|
|
27
|
+
"incremental": true,
|
|
28
|
+
// "composite": true,
|
|
29
|
+
"preserveSymlinks": false,
|
|
30
|
+
"declaration": true,
|
|
31
|
+
"declarationDir": "dist",
|
|
32
|
+
"jsx": "react-jsx",
|
|
33
|
+
"outDir": "dist" // 指定输出目录
|
|
34
|
+
|
|
35
|
+
//
|
|
36
|
+
// "noEmit": true,
|
|
37
|
+
// "alwaysStrict": true,
|
|
38
|
+
// "strictNullChecks": true,
|
|
39
|
+
// "noImplicitAny": true,
|
|
40
|
+
// "noImplicitThis": true,
|
|
41
|
+
// "downlevelIteration": true,
|
|
42
|
+
},
|
|
43
|
+
"exclude": [
|
|
44
|
+
"node_modules",
|
|
45
|
+
"src/**/*.test.tsx",
|
|
46
|
+
"src/**/*.test.ts",
|
|
47
|
+
"dist",
|
|
48
|
+
"types",
|
|
49
|
+
"out",
|
|
50
|
+
".next",
|
|
51
|
+
".turbo",
|
|
52
|
+
"coverage"
|
|
53
|
+
],
|
|
54
|
+
"include": ["src/**/*", "package.json"]
|
|
55
|
+
}
|