@gluwa/connect-kit 0.2.0-next.8 → 0.2.1-next.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/CHANGELOG.md +37 -0
- package/assets/wc.png +0 -0
- package/dist/{chunk-VE5LB7BN.js → chunk-CJANPJHY.js} +4 -2
- package/dist/credit-connect.js +1 -1
- package/dist/index.css +211 -156
- package/dist/index.d.ts +4 -1
- package/dist/index.js +521 -197
- package/dist/package.json +1 -1
- package/package.json +6 -6
- package/src/ConnectKitProvider.tsx +8 -1
- package/src/components/qrArea/index.tsx +28 -4
- package/src/components/qrArea/style.scss +85 -34
- package/src/components/toast/index.tsx +41 -0
- package/src/components/toast/style.scss +108 -0
- package/src/core/config.ts +23 -2
- package/src/core/deeplinkSignal.ts +25 -0
- package/src/creditConnectConnector.ts +15 -5
- package/src/events/account.ts +15 -6
- package/src/hooks/useConnectBanner.ts +79 -0
- package/src/hooks/useConnectTimeout.ts +21 -9
- package/src/hooks/useMetaMaskExtension.ts +30 -0
- package/src/hooks/useWCState.ts +14 -10
- package/src/hooks/useWagmiConnect.ts +42 -20
- package/src/index.ts +1 -0
- package/src/layout/allWallets/index.tsx +17 -3
- package/src/layout/allWallets/style.scss +2 -7
- package/src/layout/connectDialog/asset/warningIcon.tsx +21 -0
- package/src/layout/connectDialog/idle/assets/banner-placeholder.png +0 -0
- package/src/layout/connectDialog/idle/index.tsx +40 -16
- package/src/layout/connectDialog/idle/style.scss +42 -51
- package/src/layout/connectDialog/index.tsx +196 -47
- package/src/layout/connectDialog/metaMask/index.tsx +3 -2
- package/src/layout/connectDialog/qr/index.tsx +3 -1
- package/src/layout/connectDialog/style.scss +2 -49
- package/src/layout/connectDialog/timeout/index.tsx +0 -5
- package/src/layout/connectDialog/timeout/style.scss +0 -5
- package/src/layout/connectDialog/walletQR/index.tsx +3 -1
- package/src/layout/detailPanel/index.tsx +39 -6
- package/src/layout/detailPanel/style.scss +7 -1
- package/src/layout/selectorPanel/index.tsx +1 -0
- package/src/types.ts +20 -0
- package/src/utils/platform.ts +7 -4
- package/src/wallet-display-override.ts +15 -0
- package/src/components/snackbar/index.tsx +0 -25
- package/src/components/snackbar/style.scss +0 -51
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,42 @@
|
|
|
1
1
|
# @gluwa/wallet-kit
|
|
2
2
|
|
|
3
|
+
## 0.2.1-next.1
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- 998578b: update version
|
|
8
|
+
- Updated dependencies [998578b]
|
|
9
|
+
- @gluwa/credit-connect-hub-node-ws@0.1.1-next.1
|
|
10
|
+
- @gluwa/credit-connect-sdk@0.2.1-next.7
|
|
11
|
+
- @gluwa/credit-connect-e2ee-tweetnacl@0.2.1-next.7
|
|
12
|
+
- @gluwa/credit-connect-storage-local@0.2.1-next.7
|
|
13
|
+
|
|
14
|
+
## 0.2.0-next.11
|
|
15
|
+
|
|
16
|
+
### Patch Changes
|
|
17
|
+
|
|
18
|
+
- Updated dependencies [4cba4bb]
|
|
19
|
+
- @gluwa/credit-connect-sdk@0.2.0-next.6
|
|
20
|
+
- @gluwa/credit-connect-e2ee-tweetnacl@0.2.0-next.6
|
|
21
|
+
- @gluwa/credit-connect-hub-node-ws@0.1.0-next.6
|
|
22
|
+
- @gluwa/credit-connect-storage-local@0.2.0-next.6
|
|
23
|
+
|
|
24
|
+
## 0.2.0-next.10
|
|
25
|
+
|
|
26
|
+
### Patch Changes
|
|
27
|
+
|
|
28
|
+
- Updated dependencies [0b7cf10]
|
|
29
|
+
- @gluwa/credit-connect-sdk@0.2.0-next.5
|
|
30
|
+
- @gluwa/credit-connect-e2ee-tweetnacl@0.2.0-next.5
|
|
31
|
+
- @gluwa/credit-connect-hub-node-ws@0.1.0-next.5
|
|
32
|
+
- @gluwa/credit-connect-storage-local@0.2.0-next.5
|
|
33
|
+
|
|
34
|
+
## 0.2.0-next.9
|
|
35
|
+
|
|
36
|
+
### Patch Changes
|
|
37
|
+
|
|
38
|
+
- 18e631a: fix bugs
|
|
39
|
+
|
|
3
40
|
## 0.2.0-next.8
|
|
4
41
|
|
|
5
42
|
### Patch Changes
|
package/assets/wc.png
CHANGED
|
Binary file
|
|
@@ -53,7 +53,7 @@ var creditConnectConnector = /* @__PURE__ */ __name((options) => {
|
|
|
53
53
|
});
|
|
54
54
|
if (state.status === "CONNECTING" && state.connectingPayload) {
|
|
55
55
|
console.log("[CC connector] emit display_uri", {
|
|
56
|
-
|
|
56
|
+
ready: true
|
|
57
57
|
});
|
|
58
58
|
(_a = options.onDisplayUri) == null ? void 0 : _a.call(options, state.connectingPayload);
|
|
59
59
|
emitWagmiMessage == null ? void 0 : emitWagmiMessage("display_uri", state.connectingPayload);
|
|
@@ -66,7 +66,9 @@ var creditConnectConnector = /* @__PURE__ */ __name((options) => {
|
|
|
66
66
|
}
|
|
67
67
|
});
|
|
68
68
|
manager.on("sessionExpired", (payload) => {
|
|
69
|
-
console.log("[CC connector] session expired \u2192 emit session_expired",
|
|
69
|
+
console.log("[CC connector] session expired \u2192 emit session_expired", {
|
|
70
|
+
reason: payload.reason
|
|
71
|
+
});
|
|
70
72
|
emitWagmiMessage == null ? void 0 : emitWagmiMessage("session_expired", payload);
|
|
71
73
|
});
|
|
72
74
|
return manager;
|
package/dist/credit-connect.js
CHANGED
package/dist/index.css
CHANGED
|
@@ -564,8 +564,9 @@
|
|
|
564
564
|
width: 100%;
|
|
565
565
|
max-width: none;
|
|
566
566
|
grid-template-columns: 1fr;
|
|
567
|
+
grid-template-rows: minmax(0, 1fr);
|
|
567
568
|
max-height: 82dvh;
|
|
568
|
-
height:
|
|
569
|
+
height: auto;
|
|
569
570
|
border-radius: 12px 12px 0 0;
|
|
570
571
|
}
|
|
571
572
|
.ck-root .ck-dialog[data-step=selector] .ck-detail {
|
|
@@ -575,46 +576,6 @@
|
|
|
575
576
|
display: none !important;
|
|
576
577
|
}
|
|
577
578
|
}
|
|
578
|
-
.ck-root .ck-dialog-snackbar {
|
|
579
|
-
position: fixed;
|
|
580
|
-
top: clamp(20px, 9.2vh, 99px);
|
|
581
|
-
left: 50%;
|
|
582
|
-
z-index: 1001;
|
|
583
|
-
width: min(100vw - 40px, 400px);
|
|
584
|
-
transform: translateX(-50%);
|
|
585
|
-
animation: ck-dialog-snackbar-in 0.2s ease;
|
|
586
|
-
}
|
|
587
|
-
@media (max-width: 767px) {
|
|
588
|
-
.ck-root .ck-dialog-snackbar {
|
|
589
|
-
top: clamp(env(safe-area-inset-top, 0px) + 20px, env(safe-area-inset-top, 0px) + 20px, env(safe-area-inset-top, 0px) + 20px);
|
|
590
|
-
left: 20px;
|
|
591
|
-
right: 20px;
|
|
592
|
-
width: auto;
|
|
593
|
-
transform: none;
|
|
594
|
-
}
|
|
595
|
-
}
|
|
596
|
-
@keyframes ck-dialog-snackbar-in {
|
|
597
|
-
from {
|
|
598
|
-
opacity: 0;
|
|
599
|
-
transform: translateX(-50%) translateY(8px);
|
|
600
|
-
}
|
|
601
|
-
to {
|
|
602
|
-
opacity: 1;
|
|
603
|
-
transform: translateX(-50%) translateY(0);
|
|
604
|
-
}
|
|
605
|
-
}
|
|
606
|
-
@media (max-width: 767px) {
|
|
607
|
-
@keyframes ck-dialog-snackbar-in {
|
|
608
|
-
from {
|
|
609
|
-
opacity: 0;
|
|
610
|
-
transform: translateY(8px);
|
|
611
|
-
}
|
|
612
|
-
to {
|
|
613
|
-
opacity: 1;
|
|
614
|
-
transform: translateY(0);
|
|
615
|
-
}
|
|
616
|
-
}
|
|
617
|
-
}
|
|
618
579
|
|
|
619
580
|
/* src/layout/selectorPanel/style.scss */
|
|
620
581
|
.ck-selector {
|
|
@@ -877,6 +838,7 @@
|
|
|
877
838
|
.ck-detail {
|
|
878
839
|
display: flex;
|
|
879
840
|
flex-direction: column;
|
|
841
|
+
min-width: 0;
|
|
880
842
|
background: var(--semantic-paper-dialog);
|
|
881
843
|
min-height: 0;
|
|
882
844
|
position: relative;
|
|
@@ -884,11 +846,12 @@
|
|
|
884
846
|
.ck-detail-header {
|
|
885
847
|
display: flex;
|
|
886
848
|
align-items: center;
|
|
849
|
+
position: relative;
|
|
850
|
+
z-index: 1;
|
|
887
851
|
gap: 10px;
|
|
888
852
|
height: 60px;
|
|
889
853
|
padding: 0 20px;
|
|
890
854
|
flex-shrink: 0;
|
|
891
|
-
background: var(--semantic-paper-sheet);
|
|
892
855
|
}
|
|
893
856
|
.ck-btn-back {
|
|
894
857
|
display: flex;
|
|
@@ -959,38 +922,31 @@
|
|
|
959
922
|
.ck-detail-body::-webkit-scrollbar-thumb:hover {
|
|
960
923
|
background-color: var(--scale-gray-400);
|
|
961
924
|
}
|
|
925
|
+
.ck-detail-body:has(.ck-all-wallets) {
|
|
926
|
+
padding-bottom: 0;
|
|
927
|
+
}
|
|
962
928
|
|
|
963
929
|
/* src/layout/connectDialog/idle/style.scss */
|
|
964
|
-
.ck-idle {
|
|
930
|
+
.ck-root .ck-idle {
|
|
965
931
|
display: flex;
|
|
966
932
|
flex-direction: column;
|
|
967
|
-
align-items:
|
|
968
|
-
|
|
969
|
-
|
|
970
|
-
|
|
971
|
-
|
|
972
|
-
|
|
973
|
-
|
|
974
|
-
.ck-idle-graphic {
|
|
975
|
-
max-width: 440px;
|
|
976
|
-
height: auto;
|
|
977
|
-
max-height: 240px;
|
|
978
|
-
flex-shrink: 0;
|
|
979
|
-
margin: 0;
|
|
933
|
+
align-items: flex-start;
|
|
934
|
+
gap: 6px;
|
|
935
|
+
position: absolute;
|
|
936
|
+
inset: 0;
|
|
937
|
+
z-index: 0;
|
|
938
|
+
padding: 60px;
|
|
939
|
+
box-sizing: border-box;
|
|
980
940
|
}
|
|
981
|
-
.ck-idle-
|
|
941
|
+
.ck-root .ck-idle-bg {
|
|
942
|
+
position: absolute;
|
|
943
|
+
inset: 0;
|
|
982
944
|
width: 100%;
|
|
983
945
|
height: 100%;
|
|
984
|
-
object-fit:
|
|
985
|
-
|
|
986
|
-
.ck-idle-text {
|
|
987
|
-
display: flex;
|
|
988
|
-
flex-direction: column;
|
|
989
|
-
align-items: center;
|
|
990
|
-
gap: 6px;
|
|
991
|
-
width: 100%;
|
|
946
|
+
object-fit: cover;
|
|
947
|
+
z-index: -1;
|
|
992
948
|
}
|
|
993
|
-
.ck-idle-title {
|
|
949
|
+
.ck-root .ck-idle-title {
|
|
994
950
|
--font-name: title1-bold;
|
|
995
951
|
font-family: "Inter-SB";
|
|
996
952
|
font-size: 32px;
|
|
@@ -998,22 +954,22 @@
|
|
|
998
954
|
letter-spacing: -0.03em;
|
|
999
955
|
}
|
|
1000
956
|
@media (max-width: 767px) {
|
|
1001
|
-
.ck-idle-title {
|
|
957
|
+
.ck-root .ck-idle-title {
|
|
1002
958
|
font-size: 28px;
|
|
1003
959
|
}
|
|
1004
960
|
}
|
|
1005
961
|
@media (max-width: 450px) {
|
|
1006
|
-
.ck-idle-title {
|
|
962
|
+
.ck-root .ck-idle-title {
|
|
1007
963
|
font-size: 24px;
|
|
1008
964
|
}
|
|
1009
965
|
}
|
|
1010
|
-
.ck-idle-title {
|
|
966
|
+
.ck-root .ck-idle-title {
|
|
1011
967
|
color: var(--scale-gray-900);
|
|
1012
|
-
text-align: center;
|
|
1013
|
-
width: 100%;
|
|
1014
|
-
letter-spacing: -0.96px;
|
|
1015
968
|
}
|
|
1016
|
-
.ck-idle-desc {
|
|
969
|
+
.ck-root .ck-idle-desc {
|
|
970
|
+
color: var(--scale-gray-600);
|
|
971
|
+
margin-top: 6px;
|
|
972
|
+
white-space: pre-line;
|
|
1017
973
|
--font-name: body4-l1-regular;
|
|
1018
974
|
font-family: "Inter-R";
|
|
1019
975
|
font-size: 15px;
|
|
@@ -1021,28 +977,24 @@
|
|
|
1021
977
|
letter-spacing: -0.01em;
|
|
1022
978
|
}
|
|
1023
979
|
@media (max-width: 767px) {
|
|
1024
|
-
.ck-idle-desc {
|
|
980
|
+
.ck-root .ck-idle-desc {
|
|
1025
981
|
font-size: 14px;
|
|
1026
982
|
}
|
|
1027
983
|
}
|
|
1028
984
|
@media (max-width: 450px) {
|
|
1029
|
-
.ck-idle-desc {
|
|
985
|
+
.ck-root .ck-idle-desc {
|
|
1030
986
|
font-size: 13px;
|
|
1031
987
|
}
|
|
1032
988
|
}
|
|
1033
|
-
.ck-idle-desc {
|
|
1034
|
-
color: var(--scale-gray-600);
|
|
1035
|
-
text-align: center;
|
|
1036
|
-
width: 100%;
|
|
1037
|
-
}
|
|
1038
989
|
.ck-root .ck-idle-link {
|
|
1039
|
-
display:
|
|
990
|
+
display: flex;
|
|
1040
991
|
align-items: center;
|
|
1041
|
-
|
|
992
|
+
margin: -2px -8px -8px -8px;
|
|
993
|
+
padding: 8px;
|
|
1042
994
|
}
|
|
1043
995
|
.ck-root .ck-idle-link span {
|
|
1044
|
-
--font-name: body4-l1-
|
|
1045
|
-
font-family: "Inter-
|
|
996
|
+
--font-name: body4-l1-bold;
|
|
997
|
+
font-family: "Inter-SB";
|
|
1046
998
|
font-size: 15px;
|
|
1047
999
|
line-height: 1.8;
|
|
1048
1000
|
letter-spacing: -0.01em;
|
|
@@ -1057,8 +1009,12 @@
|
|
|
1057
1009
|
font-size: 13px;
|
|
1058
1010
|
}
|
|
1059
1011
|
}
|
|
1012
|
+
.ck-root .ck-idle-link span {
|
|
1013
|
+
color: inherit;
|
|
1014
|
+
}
|
|
1060
1015
|
.ck-root .ck-idle-link svg {
|
|
1061
1016
|
flex-shrink: 0;
|
|
1017
|
+
color: inherit;
|
|
1062
1018
|
}
|
|
1063
1019
|
|
|
1064
1020
|
/* src/layout/connectDialog/loading/style.scss */
|
|
@@ -1114,11 +1070,11 @@
|
|
|
1114
1070
|
/* src/components/qrArea/style.scss */
|
|
1115
1071
|
.ck-qr-area {
|
|
1116
1072
|
display: flex;
|
|
1073
|
+
flex-direction: column;
|
|
1117
1074
|
align-items: center;
|
|
1118
|
-
justify-content: center;
|
|
1119
1075
|
flex: 1;
|
|
1120
1076
|
width: 100%;
|
|
1121
|
-
padding
|
|
1077
|
+
padding: 32px 0;
|
|
1122
1078
|
}
|
|
1123
1079
|
.ck-qr-text {
|
|
1124
1080
|
display: flex;
|
|
@@ -1128,6 +1084,11 @@
|
|
|
1128
1084
|
width: 100%;
|
|
1129
1085
|
margin-top: 24px;
|
|
1130
1086
|
}
|
|
1087
|
+
@media (max-width: 767px) {
|
|
1088
|
+
.ck-qr-text {
|
|
1089
|
+
gap: 12px;
|
|
1090
|
+
}
|
|
1091
|
+
}
|
|
1131
1092
|
.ck-qr-label {
|
|
1132
1093
|
--font-name: subtitle2-bold;
|
|
1133
1094
|
font-family: "Inter-SB";
|
|
@@ -1149,6 +1110,61 @@
|
|
|
1149
1110
|
color: var(--scale-gray-900);
|
|
1150
1111
|
text-align: center;
|
|
1151
1112
|
}
|
|
1113
|
+
.ck-root .ck-qr-open-app {
|
|
1114
|
+
display: none;
|
|
1115
|
+
align-items: center;
|
|
1116
|
+
justify-content: center;
|
|
1117
|
+
padding: 12px 28px;
|
|
1118
|
+
border: 1px solid var(--semantic-divider-divider-4);
|
|
1119
|
+
border-radius: 500px;
|
|
1120
|
+
--font-name: label4-bold;
|
|
1121
|
+
font-family: "Inter-SB";
|
|
1122
|
+
font-size: 15px;
|
|
1123
|
+
line-height: 1.5;
|
|
1124
|
+
letter-spacing: -0.01em;
|
|
1125
|
+
}
|
|
1126
|
+
@media (max-width: 767px) {
|
|
1127
|
+
.ck-root .ck-qr-open-app {
|
|
1128
|
+
font-size: 14px;
|
|
1129
|
+
}
|
|
1130
|
+
}
|
|
1131
|
+
@media (max-width: 450px) {
|
|
1132
|
+
.ck-root .ck-qr-open-app {
|
|
1133
|
+
font-size: 13px;
|
|
1134
|
+
}
|
|
1135
|
+
}
|
|
1136
|
+
.ck-root .ck-qr-open-app {
|
|
1137
|
+
color: var(--scale-gray-900);
|
|
1138
|
+
cursor: pointer;
|
|
1139
|
+
transition: background 0.15s ease;
|
|
1140
|
+
}
|
|
1141
|
+
@media (max-width: 767px) {
|
|
1142
|
+
.ck-root .ck-qr-open-app {
|
|
1143
|
+
display: inline-flex;
|
|
1144
|
+
}
|
|
1145
|
+
}
|
|
1146
|
+
.ck-root .ck-qr-open-app:hover {
|
|
1147
|
+
background: var(--scale-gray-100);
|
|
1148
|
+
}
|
|
1149
|
+
.ck-qr-open-app-skeleton {
|
|
1150
|
+
display: none;
|
|
1151
|
+
width: 116px;
|
|
1152
|
+
height: 44px;
|
|
1153
|
+
border-radius: 500px;
|
|
1154
|
+
background:
|
|
1155
|
+
linear-gradient(
|
|
1156
|
+
132deg,
|
|
1157
|
+
var(--scale-gray-100) 36%,
|
|
1158
|
+
var(--scale-gray-200) 51%,
|
|
1159
|
+
var(--scale-gray-100) 66%);
|
|
1160
|
+
background-size: 200% 100%;
|
|
1161
|
+
animation: ck-qr-shimmer 1.5s linear infinite;
|
|
1162
|
+
}
|
|
1163
|
+
@media (max-width: 767px) {
|
|
1164
|
+
.ck-qr-open-app-skeleton {
|
|
1165
|
+
display: block;
|
|
1166
|
+
}
|
|
1167
|
+
}
|
|
1152
1168
|
.ck-qr {
|
|
1153
1169
|
display: flex;
|
|
1154
1170
|
flex-direction: column;
|
|
@@ -1158,15 +1174,15 @@
|
|
|
1158
1174
|
overflow: hidden;
|
|
1159
1175
|
outline: none;
|
|
1160
1176
|
}
|
|
1161
|
-
.ck-qr-
|
|
1162
|
-
|
|
1163
|
-
}
|
|
1164
|
-
.ck-qr-timeout {
|
|
1177
|
+
.ck-qr-skeleton {
|
|
1178
|
+
padding: 20px;
|
|
1165
1179
|
border: 1px solid var(--semantic-divider-divider-1);
|
|
1180
|
+
border-radius: 20px;
|
|
1166
1181
|
}
|
|
1167
|
-
.ck-qr-skeleton {
|
|
1168
|
-
|
|
1169
|
-
|
|
1182
|
+
.ck-qr-skeleton-inner {
|
|
1183
|
+
display: block;
|
|
1184
|
+
width: 246px;
|
|
1185
|
+
height: 246px;
|
|
1170
1186
|
background:
|
|
1171
1187
|
linear-gradient(
|
|
1172
1188
|
132deg,
|
|
@@ -1177,11 +1193,40 @@
|
|
|
1177
1193
|
animation: ck-qr-shimmer 1.5s linear infinite;
|
|
1178
1194
|
}
|
|
1179
1195
|
@media (max-width: 767px) {
|
|
1180
|
-
.ck-qr-skeleton {
|
|
1181
|
-
width:
|
|
1182
|
-
height:
|
|
1196
|
+
.ck-qr-skeleton-inner {
|
|
1197
|
+
width: 198px;
|
|
1198
|
+
height: 198px;
|
|
1199
|
+
}
|
|
1200
|
+
}
|
|
1201
|
+
.ck-qr-timeout {
|
|
1202
|
+
width: 288px;
|
|
1203
|
+
height: 288px;
|
|
1204
|
+
border: 1px solid var(--semantic-divider-divider-1);
|
|
1205
|
+
background: var(--scale-gray-100);
|
|
1206
|
+
display: flex;
|
|
1207
|
+
align-items: center;
|
|
1208
|
+
justify-content: center;
|
|
1209
|
+
}
|
|
1210
|
+
@media (max-width: 767px) {
|
|
1211
|
+
.ck-qr-timeout {
|
|
1212
|
+
width: 240px;
|
|
1213
|
+
height: 240px;
|
|
1183
1214
|
}
|
|
1184
1215
|
}
|
|
1216
|
+
.ck-qr-copy-skeleton {
|
|
1217
|
+
display: block;
|
|
1218
|
+
width: 84px;
|
|
1219
|
+
height: 20px;
|
|
1220
|
+
border-radius: 4px;
|
|
1221
|
+
background:
|
|
1222
|
+
linear-gradient(
|
|
1223
|
+
132deg,
|
|
1224
|
+
var(--scale-gray-100) 36%,
|
|
1225
|
+
var(--scale-gray-200) 51%,
|
|
1226
|
+
var(--scale-gray-100) 66%);
|
|
1227
|
+
background-size: 200% 100%;
|
|
1228
|
+
animation: ck-qr-shimmer 1.5s linear infinite;
|
|
1229
|
+
}
|
|
1185
1230
|
@keyframes ck-qr-shimmer {
|
|
1186
1231
|
0% {
|
|
1187
1232
|
background-position: 200% 0;
|
|
@@ -1207,20 +1252,6 @@
|
|
|
1207
1252
|
height: 198px;
|
|
1208
1253
|
}
|
|
1209
1254
|
}
|
|
1210
|
-
.ck-qr-timeout {
|
|
1211
|
-
width: 248px;
|
|
1212
|
-
height: 248px;
|
|
1213
|
-
background: var(--scale-gray-100);
|
|
1214
|
-
display: flex;
|
|
1215
|
-
align-items: center;
|
|
1216
|
-
justify-content: center;
|
|
1217
|
-
}
|
|
1218
|
-
@media (max-width: 767px) {
|
|
1219
|
-
.ck-qr-timeout {
|
|
1220
|
-
width: 200px;
|
|
1221
|
-
height: 200px;
|
|
1222
|
-
}
|
|
1223
|
-
}
|
|
1224
1255
|
.ck-qr-timeout-inner {
|
|
1225
1256
|
display: flex;
|
|
1226
1257
|
flex-direction: column;
|
|
@@ -1382,26 +1413,6 @@
|
|
|
1382
1413
|
.ck-timeout-title {
|
|
1383
1414
|
color: var(--scale-gray-900);
|
|
1384
1415
|
}
|
|
1385
|
-
.ck-timeout-desc {
|
|
1386
|
-
--font-name: body4-l1-regular;
|
|
1387
|
-
font-family: "Inter-R";
|
|
1388
|
-
font-size: 15px;
|
|
1389
|
-
line-height: 1.8;
|
|
1390
|
-
letter-spacing: -0.01em;
|
|
1391
|
-
}
|
|
1392
|
-
@media (max-width: 767px) {
|
|
1393
|
-
.ck-timeout-desc {
|
|
1394
|
-
font-size: 14px;
|
|
1395
|
-
}
|
|
1396
|
-
}
|
|
1397
|
-
@media (max-width: 450px) {
|
|
1398
|
-
.ck-timeout-desc {
|
|
1399
|
-
font-size: 13px;
|
|
1400
|
-
}
|
|
1401
|
-
}
|
|
1402
|
-
.ck-timeout-desc {
|
|
1403
|
-
color: var(--scale-gray-600);
|
|
1404
|
-
}
|
|
1405
1416
|
.ck-root .ck-timeout-retry-btn {
|
|
1406
1417
|
display: inline-flex;
|
|
1407
1418
|
align-items: center;
|
|
@@ -1690,15 +1701,8 @@
|
|
|
1690
1701
|
gap: 8px;
|
|
1691
1702
|
flex-shrink: 0;
|
|
1692
1703
|
}
|
|
1693
|
-
|
|
1694
|
-
|
|
1695
|
-
flex-direction: column;
|
|
1696
|
-
align-items: flex-end;
|
|
1697
|
-
gap: 12px;
|
|
1698
|
-
}
|
|
1699
|
-
.ck-all-wallets-controls .ck-search {
|
|
1700
|
-
width: 100%;
|
|
1701
|
-
}
|
|
1704
|
+
.ck-all-wallets-controls .ck-search {
|
|
1705
|
+
min-width: 0;
|
|
1702
1706
|
}
|
|
1703
1707
|
.ck-wc-filter-btn {
|
|
1704
1708
|
display: inline-flex;
|
|
@@ -2009,40 +2013,85 @@
|
|
|
2009
2013
|
}
|
|
2010
2014
|
}
|
|
2011
2015
|
|
|
2012
|
-
/* src/components/
|
|
2013
|
-
.ck-
|
|
2016
|
+
/* src/components/toast/style.scss */
|
|
2017
|
+
.ck-toast-stack {
|
|
2018
|
+
position: fixed;
|
|
2019
|
+
top: clamp(20px, 9.2vh, 99px);
|
|
2020
|
+
left: 50%;
|
|
2021
|
+
z-index: 1001;
|
|
2014
2022
|
display: flex;
|
|
2023
|
+
flex-direction: column;
|
|
2015
2024
|
align-items: center;
|
|
2025
|
+
gap: 8px;
|
|
2026
|
+
max-width: calc(100vw - 40px);
|
|
2027
|
+
transform: translateX(-50%);
|
|
2028
|
+
}
|
|
2029
|
+
@media (max-width: 767px) {
|
|
2030
|
+
.ck-toast-stack {
|
|
2031
|
+
top: clamp(env(safe-area-inset-top, 0px) + 20px, env(safe-area-inset-top, 0px) + 20px, env(safe-area-inset-top, 0px) + 20px);
|
|
2032
|
+
left: 20px;
|
|
2033
|
+
right: 20px;
|
|
2034
|
+
align-items: stretch;
|
|
2035
|
+
max-width: none;
|
|
2036
|
+
transform: none;
|
|
2037
|
+
}
|
|
2038
|
+
}
|
|
2039
|
+
.ck-toast {
|
|
2040
|
+
display: flex;
|
|
2041
|
+
align-items: center;
|
|
2042
|
+
justify-content: space-between;
|
|
2016
2043
|
gap: 16px;
|
|
2044
|
+
width: max-content;
|
|
2045
|
+
min-width: min(400px, 100vw - 40px);
|
|
2046
|
+
max-width: 100%;
|
|
2017
2047
|
padding: 12px 16px;
|
|
2018
2048
|
border-radius: 8px;
|
|
2019
2049
|
background: var(--semantic-paper-sheet);
|
|
2020
2050
|
border: 1px solid var(--semantic-divider-divider-1);
|
|
2021
|
-
|
|
2022
|
-
max-width: 400px;
|
|
2051
|
+
animation: ck-toast-in 0.2s ease;
|
|
2023
2052
|
}
|
|
2024
2053
|
@media (max-width: 767px) {
|
|
2025
|
-
.ck-
|
|
2026
|
-
|
|
2054
|
+
.ck-toast {
|
|
2055
|
+
width: 100%;
|
|
2056
|
+
min-width: 0;
|
|
2057
|
+
}
|
|
2058
|
+
}
|
|
2059
|
+
@keyframes ck-toast-in {
|
|
2060
|
+
from {
|
|
2061
|
+
opacity: 0;
|
|
2062
|
+
transform: translateY(8px);
|
|
2063
|
+
}
|
|
2064
|
+
to {
|
|
2065
|
+
opacity: 1;
|
|
2066
|
+
transform: translateY(0);
|
|
2027
2067
|
}
|
|
2028
2068
|
}
|
|
2029
|
-
.ck-
|
|
2069
|
+
.ck-toast-content {
|
|
2030
2070
|
display: flex;
|
|
2031
2071
|
align-items: center;
|
|
2032
2072
|
gap: 8px;
|
|
2033
|
-
flex: 1;
|
|
2034
|
-
min-width: 0;
|
|
2035
2073
|
}
|
|
2036
|
-
|
|
2074
|
+
@media (max-width: 767px) {
|
|
2075
|
+
.ck-toast-content {
|
|
2076
|
+
flex: 1;
|
|
2077
|
+
min-width: 0;
|
|
2078
|
+
}
|
|
2079
|
+
}
|
|
2080
|
+
.ck-toast-icon {
|
|
2037
2081
|
display: flex;
|
|
2038
2082
|
align-items: center;
|
|
2039
2083
|
justify-content: center;
|
|
2040
2084
|
width: 24px;
|
|
2041
2085
|
height: 24px;
|
|
2042
2086
|
flex-shrink: 0;
|
|
2087
|
+
}
|
|
2088
|
+
.ck-toast-icon--success {
|
|
2043
2089
|
color: var(--semantic-information-success);
|
|
2044
2090
|
}
|
|
2045
|
-
.ck-
|
|
2091
|
+
.ck-toast-icon--warning {
|
|
2092
|
+
color: var(--semantic-information-caution);
|
|
2093
|
+
}
|
|
2094
|
+
.ck-toast-message {
|
|
2046
2095
|
--font-name: body3-l1-medium;
|
|
2047
2096
|
font-family: "Inter-M";
|
|
2048
2097
|
font-size: 16px;
|
|
@@ -2050,21 +2099,27 @@
|
|
|
2050
2099
|
letter-spacing: -0.01em;
|
|
2051
2100
|
}
|
|
2052
2101
|
@media (max-width: 767px) {
|
|
2053
|
-
.ck-
|
|
2102
|
+
.ck-toast-message {
|
|
2054
2103
|
font-size: 15px;
|
|
2055
2104
|
}
|
|
2056
2105
|
}
|
|
2057
2106
|
@media (max-width: 450px) {
|
|
2058
|
-
.ck-
|
|
2107
|
+
.ck-toast-message {
|
|
2059
2108
|
font-size: 14px;
|
|
2060
2109
|
}
|
|
2061
2110
|
}
|
|
2062
|
-
.ck-
|
|
2111
|
+
.ck-toast-message {
|
|
2063
2112
|
color: var(--scale-gray-900);
|
|
2064
|
-
|
|
2065
|
-
|
|
2113
|
+
white-space: nowrap;
|
|
2114
|
+
}
|
|
2115
|
+
@media (max-width: 767px) {
|
|
2116
|
+
.ck-toast-message {
|
|
2117
|
+
flex: 1;
|
|
2118
|
+
min-width: 0;
|
|
2119
|
+
white-space: normal;
|
|
2120
|
+
}
|
|
2066
2121
|
}
|
|
2067
|
-
.ck-root .ck-
|
|
2122
|
+
.ck-root .ck-toast-close {
|
|
2068
2123
|
display: flex;
|
|
2069
2124
|
align-items: center;
|
|
2070
2125
|
justify-content: center;
|
package/dist/index.d.ts
CHANGED
|
@@ -37,6 +37,7 @@ interface WCWallet {
|
|
|
37
37
|
}
|
|
38
38
|
type WCSubView = 'qr' | 'list' | 'wallet';
|
|
39
39
|
type ConnectKitTheme = 'light' | 'dark';
|
|
40
|
+
type ConnectBannerSiteKey = 'penguin-swap' | 'penguin-bridge' | 'penguin-base' | 'penguin-wallet';
|
|
40
41
|
interface ConnectResult {
|
|
41
42
|
address: `0x${string}`;
|
|
42
43
|
connectorId: ConnectorId;
|
|
@@ -63,6 +64,8 @@ interface ConnectModalProps {
|
|
|
63
64
|
|
|
64
65
|
interface ConnectKitProviderProps {
|
|
65
66
|
children: ReactNode;
|
|
67
|
+
siteKey: ConnectBannerSiteKey;
|
|
68
|
+
connectBannerUrl: string;
|
|
66
69
|
kitConfig?: ConnectKitConfig;
|
|
67
70
|
connectors: Connectors;
|
|
68
71
|
requiredChainId?: number;
|
|
@@ -111,4 +114,4 @@ declare const connectKit: {
|
|
|
111
114
|
};
|
|
112
115
|
};
|
|
113
116
|
|
|
114
|
-
export { type ConnectErrorContext, type ConnectErrorReason, type ConnectKitConfig, type ConnectKitContextValue, ConnectKitProvider, type ConnectKitProviderProps, type ConnectKitTheme, type ConnectModalProps, type ConnectResult, type ConnectorId, type ConnectorKey, type Connectors, type WCSubView, type WCWallet, connectKit, initConfig, useConnectKit };
|
|
117
|
+
export { type ConnectBannerSiteKey, type ConnectErrorContext, type ConnectErrorReason, type ConnectKitConfig, type ConnectKitContextValue, ConnectKitProvider, type ConnectKitProviderProps, type ConnectKitTheme, type ConnectModalProps, type ConnectResult, type ConnectorId, type ConnectorKey, type Connectors, type WCSubView, type WCWallet, connectKit, initConfig, useConnectKit };
|