@tonconnect/ui 2.0.10-beta.2 → 2.0.10-beta.3
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/dist/tonconnect-ui.min.js +152 -153
- package/dist/tonconnect-ui.min.js.map +1 -1
- package/lib/index.cjs +70 -70
- package/lib/index.cjs.map +1 -1
- package/lib/index.mjs +70 -70
- package/lib/index.mjs.map +1 -1
- package/package.json +1 -1
package/lib/index.mjs
CHANGED
|
@@ -2061,12 +2061,12 @@ const walletModal$1 = {
|
|
|
2061
2061
|
loading: "Loading wallets",
|
|
2062
2062
|
wallets: "Wallets",
|
|
2063
2063
|
mobileUniversalModal: {
|
|
2064
|
-
connectYourWallet: "Connect your TON
|
|
2064
|
+
connectYourWallet: "Connect your TON\xA0wallet",
|
|
2065
2065
|
openWalletOnTelegramOrSelect: "Use Wallet in Telegram or choose other application",
|
|
2066
2066
|
openWalletOnTelegram: "Connect Wallet in Telegram",
|
|
2067
2067
|
chooseOtherApplication: "Choose other application",
|
|
2068
2068
|
openLink: "Open Link",
|
|
2069
|
-
scan: "Scan with your mobile
|
|
2069
|
+
scan: "Scan with your mobile\xA0wallet"
|
|
2070
2070
|
},
|
|
2071
2071
|
desktopUniversalModal: {
|
|
2072
2072
|
connectYourWallet: "Connect your TON wallet",
|
|
@@ -2118,7 +2118,7 @@ const en = {
|
|
|
2118
2118
|
const common = {
|
|
2119
2119
|
close: "\u0417\u0430\u043A\u0440\u044B\u0442\u044C",
|
|
2120
2120
|
openWallet: "\u041E\u0442\u043A\u0440\u044B\u0442\u044C \u043A\u043E\u0448\u0435\u043B\u0451\u043A",
|
|
2121
|
-
copyLink: "\
|
|
2121
|
+
copyLink: "\u0421\u043A\u043E\u043F\u0438\u0440\u043E\u0432\u0430\u0442\u044C",
|
|
2122
2122
|
linkCopied: "\u0421\u0441\u044B\u043B\u043A\u0430 \u0441\u043A\u043E\u043F\u0438\u0440\u043E\u0432\u0430\u043D\u0430",
|
|
2123
2123
|
copied: "\u0421\u043A\u043E\u043F\u0438\u0440\u043E\u0432\u0430\u043D\u043E",
|
|
2124
2124
|
yourWallet: "\u0412\u0430\u0448 \u043A\u043E\u0448\u0435\u043B\u0451\u043A",
|
|
@@ -2159,7 +2159,7 @@ const walletModal = {
|
|
|
2159
2159
|
loading: "\u041A\u043E\u0448\u0435\u043B\u044C\u043A\u0438 \u0437\u0430\u0433\u0440\u0443\u0436\u0430\u044E\u0442\u0441\u044F",
|
|
2160
2160
|
wallets: "\u041A\u043E\u0448\u0435\u043B\u044C\u043A\u0438",
|
|
2161
2161
|
mobileUniversalModal: {
|
|
2162
|
-
connectYourWallet: "\u041F\u043E\u0434\u043A\u043B\u044E\u0447\u0438\u0442\u0435 \u043A\u043E\u0448\u0435\u043B\u0451\u043A",
|
|
2162
|
+
connectYourWallet: "\u041F\u043E\u0434\u043A\u043B\u044E\u0447\u0438\u0442\u0435 TON\xA0\u043A\u043E\u0448\u0435\u043B\u0451\u043A",
|
|
2163
2163
|
openWalletOnTelegramOrSelect: "\u041F\u043E\u0434\u043A\u043B\u044E\u0447\u0438\u0442\u0435 Wallet \u0432\xA0Telegram \u0438\u043B\u0438\xA0\u0432\u044B\u0431\u0435\u0440\u0435\u0442\u0435 \u0434\u0440\u0443\u0433\u043E\u0435 \u043F\u0440\u0438\u043B\u043E\u0436\u0435\u043D\u0438\u0435",
|
|
2164
2164
|
openWalletOnTelegram: "\u041E\u0442\u043A\u0440\u044B\u0442\u044C Wallet \u0432 Telegram",
|
|
2165
2165
|
chooseOtherApplication: "\u0412\u044B\u0431\u0435\u0440\u0438\u0442\u0435 \u0434\u0440\u0443\u0433\u043E\u0435 \u043F\u0440\u0438\u043B\u043E\u0436\u0435\u043D\u0438\u0435",
|
|
@@ -5823,7 +5823,6 @@ const ImageContainer = styled.div`
|
|
|
5823
5823
|
left: 0;
|
|
5824
5824
|
right: 0;
|
|
5825
5825
|
border: 0.5px solid rgba(0, 0, 0, 0.08);
|
|
5826
|
-
|
|
5827
5826
|
border-radius: inherit;
|
|
5828
5827
|
}
|
|
5829
5828
|
`;
|
|
@@ -5838,11 +5837,11 @@ const WalletImage = (props) => {
|
|
|
5838
5837
|
return props.class;
|
|
5839
5838
|
},
|
|
5840
5839
|
get children() {
|
|
5841
|
-
return createComponent(ImageStyled$2, {
|
|
5840
|
+
return [createComponent(ImageStyled$2, {
|
|
5842
5841
|
get src() {
|
|
5843
5842
|
return props.src;
|
|
5844
5843
|
}
|
|
5845
|
-
});
|
|
5844
|
+
}), createMemo(() => props.badge)];
|
|
5846
5845
|
}
|
|
5847
5846
|
});
|
|
5848
5847
|
};
|
|
@@ -5856,13 +5855,41 @@ const badgeBorders = {
|
|
|
5856
5855
|
s: "6px",
|
|
5857
5856
|
none: "0"
|
|
5858
5857
|
};
|
|
5858
|
+
const WalletUlContainer = styled.ul`
|
|
5859
|
+
display: flex;
|
|
5860
|
+
gap: 0;
|
|
5861
|
+
width: 100%;
|
|
5862
|
+
overflow-x: auto;
|
|
5863
|
+
padding: 8px 12px 16px 12px;
|
|
5864
|
+
margin: 0;
|
|
5865
|
+
list-style: none;
|
|
5866
|
+
flex-wrap: nowrap;
|
|
5867
|
+
|
|
5868
|
+
&&::-webkit-scrollbar {
|
|
5869
|
+
display: none;
|
|
5870
|
+
}
|
|
5871
|
+
-ms-overflow-style: none;
|
|
5872
|
+
scrollbar-width: none;
|
|
5873
|
+
|
|
5874
|
+
> li {
|
|
5875
|
+
display: flex;
|
|
5876
|
+
flex: 1;
|
|
5877
|
+
min-width: 78px;
|
|
5878
|
+
height: fit-content;
|
|
5879
|
+
}
|
|
5880
|
+
|
|
5881
|
+
> li > button {
|
|
5882
|
+
width: 100%;
|
|
5883
|
+
}
|
|
5884
|
+
`;
|
|
5859
5885
|
const WalletItemStyled = styled.button`
|
|
5860
5886
|
position: relative;
|
|
5861
5887
|
cursor: pointer;
|
|
5862
5888
|
border: none;
|
|
5863
5889
|
background-color: unset;
|
|
5864
5890
|
padding: 8px 4px;
|
|
5865
|
-
width:
|
|
5891
|
+
width: 100%;
|
|
5892
|
+
min-width: 78px;
|
|
5866
5893
|
display: flex;
|
|
5867
5894
|
flex-direction: column;
|
|
5868
5895
|
align-items: center;
|
|
@@ -5879,11 +5906,6 @@ const WalletItemStyled = styled.button`
|
|
|
5879
5906
|
transform: scale(0.96);
|
|
5880
5907
|
}
|
|
5881
5908
|
|
|
5882
|
-
${media("mobile")} {
|
|
5883
|
-
padding: 8px 0;
|
|
5884
|
-
width: 78px;
|
|
5885
|
-
}
|
|
5886
|
-
|
|
5887
5909
|
${mediaTouch} {
|
|
5888
5910
|
&:active {
|
|
5889
5911
|
transform: scale(0.92);
|
|
@@ -5894,13 +5916,13 @@ const ImageStyled$1 = styled(WalletImage)`
|
|
|
5894
5916
|
width: 60px;
|
|
5895
5917
|
height: 60px;
|
|
5896
5918
|
border-radius: ${(props) => borders$3[props.theme.borderRadius]};
|
|
5897
|
-
|
|
5898
5919
|
margin-bottom: 8px;
|
|
5920
|
+
position: relative;
|
|
5899
5921
|
`;
|
|
5900
5922
|
const BadgeStyled = styled(Image)`
|
|
5901
5923
|
position: absolute;
|
|
5902
|
-
right:
|
|
5903
|
-
|
|
5924
|
+
right: -6px;
|
|
5925
|
+
bottom: -6px;
|
|
5904
5926
|
width: 24px;
|
|
5905
5927
|
height: 24px;
|
|
5906
5928
|
border-radius: ${(props) => badgeBorders[props.theme.borderRadius]};
|
|
@@ -5962,12 +5984,15 @@ const WalletItem = (props) => {
|
|
|
5962
5984
|
return [createMemo(() => createMemo(() => typeof props.icon === "string")() ? createComponent(ImageStyled$1, {
|
|
5963
5985
|
get src() {
|
|
5964
5986
|
return props.icon;
|
|
5987
|
+
},
|
|
5988
|
+
get badge() {
|
|
5989
|
+
return createMemo(() => !!props.badgeUrl)() && createComponent(BadgeStyled, {
|
|
5990
|
+
get src() {
|
|
5991
|
+
return props.badgeUrl;
|
|
5992
|
+
}
|
|
5993
|
+
});
|
|
5965
5994
|
}
|
|
5966
|
-
}) : props.icon),
|
|
5967
|
-
get src() {
|
|
5968
|
-
return props.badgeUrl;
|
|
5969
|
-
}
|
|
5970
|
-
})), (() => {
|
|
5995
|
+
}) : props.icon), (() => {
|
|
5971
5996
|
const _el$ = _tmpl$$q.cloneNode(true);
|
|
5972
5997
|
use((el) => ctxRef = el, _el$);
|
|
5973
5998
|
insert(_el$, createComponent(StyledText, {
|
|
@@ -6677,7 +6702,7 @@ const AccountButtonDropdownStyled = styled.div`
|
|
|
6677
6702
|
|
|
6678
6703
|
color: ${(props) => props.theme.colors.text.primary}
|
|
6679
6704
|
`;
|
|
6680
|
-
const UlStyled
|
|
6705
|
+
const UlStyled = styled.ul`
|
|
6681
6706
|
background-color: ${(props) => props.theme.colors.background.primary};
|
|
6682
6707
|
padding: 8px;
|
|
6683
6708
|
`;
|
|
@@ -6738,7 +6763,7 @@ const AccountButtonDropdown = (props) => {
|
|
|
6738
6763
|
},
|
|
6739
6764
|
"data-tc-dropdown": "true",
|
|
6740
6765
|
get children() {
|
|
6741
|
-
return createComponent(UlStyled
|
|
6766
|
+
return createComponent(UlStyled, {
|
|
6742
6767
|
get children() {
|
|
6743
6768
|
return [(() => {
|
|
6744
6769
|
const _el$ = _tmpl$$5.cloneNode(true);
|
|
@@ -8159,6 +8184,7 @@ const WalletsUl = styled.ul`
|
|
|
8159
8184
|
align-self: flex-start;
|
|
8160
8185
|
max-width: 400px;
|
|
8161
8186
|
margin: 0 auto;
|
|
8187
|
+
list-style: none;
|
|
8162
8188
|
|
|
8163
8189
|
> li {
|
|
8164
8190
|
display: block;
|
|
@@ -8166,7 +8192,20 @@ const WalletsUl = styled.ul`
|
|
|
8166
8192
|
}
|
|
8167
8193
|
|
|
8168
8194
|
${media("mobile")} {
|
|
8169
|
-
|
|
8195
|
+
display: grid;
|
|
8196
|
+
grid-template-columns: repeat(4, 1fr);
|
|
8197
|
+
gap: 0;
|
|
8198
|
+
padding: 8px 12px 16px;
|
|
8199
|
+
max-width: none;
|
|
8200
|
+
|
|
8201
|
+
> li {
|
|
8202
|
+
min-width: 78px;
|
|
8203
|
+
display: flex;
|
|
8204
|
+
}
|
|
8205
|
+
|
|
8206
|
+
> li > * {
|
|
8207
|
+
width: 100%;
|
|
8208
|
+
}
|
|
8170
8209
|
}
|
|
8171
8210
|
`;
|
|
8172
8211
|
styled(Button)`
|
|
@@ -9578,29 +9617,6 @@ const tgBorders = {
|
|
|
9578
9617
|
s: "6px",
|
|
9579
9618
|
none: "0"
|
|
9580
9619
|
};
|
|
9581
|
-
const UlStyled = styled.ul`
|
|
9582
|
-
display: flex;
|
|
9583
|
-
justify-content: space-between;
|
|
9584
|
-
margin: 0 auto;
|
|
9585
|
-
width: fit-content;
|
|
9586
|
-
max-width: 100%;
|
|
9587
|
-
min-width: 100%;
|
|
9588
|
-
height: fit-content;
|
|
9589
|
-
overflow-x: auto;
|
|
9590
|
-
overflow-y: hidden;
|
|
9591
|
-
padding: 8px 19px 16px 19px;
|
|
9592
|
-
|
|
9593
|
-
&&::-webkit-scrollbar {
|
|
9594
|
-
display: none;
|
|
9595
|
-
}
|
|
9596
|
-
|
|
9597
|
-
-ms-overflow-style: none;
|
|
9598
|
-
scrollbar-width: none;
|
|
9599
|
-
|
|
9600
|
-
> li {
|
|
9601
|
-
height: fit-content;
|
|
9602
|
-
}
|
|
9603
|
-
`;
|
|
9604
9620
|
styled.li`
|
|
9605
9621
|
width: 82px;
|
|
9606
9622
|
min-width: 82px;
|
|
@@ -9631,27 +9647,6 @@ styled.li`
|
|
|
9631
9647
|
}
|
|
9632
9648
|
}
|
|
9633
9649
|
`;
|
|
9634
|
-
styled.div`
|
|
9635
|
-
width: 1px;
|
|
9636
|
-
margin: 0 10px;
|
|
9637
|
-
height: 24px;
|
|
9638
|
-
position: relative;
|
|
9639
|
-
top: 26px;
|
|
9640
|
-
|
|
9641
|
-
background-color: ${(props) => props.theme.colors.icon.secondary};
|
|
9642
|
-
opacity: 0.2;
|
|
9643
|
-
`;
|
|
9644
|
-
styled.div`
|
|
9645
|
-
width: 60px;
|
|
9646
|
-
height: 60px;
|
|
9647
|
-
border-radius: ${(props) => borders$1[props.theme.borderRadius]};
|
|
9648
|
-
display: flex;
|
|
9649
|
-
align-items: center;
|
|
9650
|
-
justify-content: center;
|
|
9651
|
-
|
|
9652
|
-
background-color: ${(props) => props.theme.colors.background.tint};
|
|
9653
|
-
margin-bottom: 8px;
|
|
9654
|
-
`;
|
|
9655
9650
|
const H1Styled$2 = styled(H1)`
|
|
9656
9651
|
margin-top: 38px;
|
|
9657
9652
|
margin-bottom: 4px;
|
|
@@ -9689,6 +9684,11 @@ const TelegramButtonStyled = styled(Button)`
|
|
|
9689
9684
|
font-weight: 500;
|
|
9690
9685
|
font-size: 16px;
|
|
9691
9686
|
line-height: 20px;
|
|
9687
|
+
|
|
9688
|
+
@media (max-width: 375px) {
|
|
9689
|
+
margin: 0 16px 24px;
|
|
9690
|
+
width: calc(100% - 32px);
|
|
9691
|
+
}
|
|
9692
9692
|
`;
|
|
9693
9693
|
const TGImageStyled = styled(Image)`
|
|
9694
9694
|
background-color: transparent;
|
|
@@ -9928,7 +9928,7 @@ const MobileUniversalModal = (props) => {
|
|
|
9928
9928
|
padding: "0 24px 8px 24px",
|
|
9929
9929
|
margin: "0",
|
|
9930
9930
|
children: "Choose other application"
|
|
9931
|
-
}), createComponent(
|
|
9931
|
+
}), createComponent(WalletUlContainer, {
|
|
9932
9932
|
get children() {
|
|
9933
9933
|
return [createComponent(For, {
|
|
9934
9934
|
get each() {
|
|
@@ -11032,7 +11032,7 @@ class TonConnectUITracker {
|
|
|
11032
11032
|
}
|
|
11033
11033
|
}
|
|
11034
11034
|
}
|
|
11035
|
-
const tonConnectUiVersion = "2.0.10-beta.
|
|
11035
|
+
const tonConnectUiVersion = "2.0.10-beta.3";
|
|
11036
11036
|
class TonConnectUI {
|
|
11037
11037
|
constructor(options) {
|
|
11038
11038
|
__publicField(this, "walletInfoStorage", new WalletInfoStorage());
|