@matchain/matchid-sdk-react 0.1.53-alpha.5 → 0.1.53-alpha.7

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.
Files changed (57) hide show
  1. package/dist/assets/icon/index.d.mts +1 -1
  2. package/dist/assets/icon/index.d.ts +1 -1
  3. package/dist/{chunk-V2S54LGG.mjs → chunk-AYMVU44P.mjs} +44 -2
  4. package/dist/chunk-AYMVU44P.mjs.map +1 -0
  5. package/dist/{chunk-LEHYGXVJ.mjs → chunk-W7CCPGOT.mjs} +5554 -5376
  6. package/dist/chunk-W7CCPGOT.mjs.map +1 -0
  7. package/dist/components/index.d.mts +3 -3
  8. package/dist/components/index.d.ts +3 -3
  9. package/dist/components/index.js +422 -275
  10. package/dist/components/index.js.map +1 -1
  11. package/dist/components/index.mjs +6 -4
  12. package/dist/hooks/api/index.d.mts +2 -2
  13. package/dist/hooks/api/index.d.ts +2 -2
  14. package/dist/hooks/api/index.js +103 -33
  15. package/dist/hooks/api/index.js.map +1 -1
  16. package/dist/hooks/api/index.mjs +7 -7
  17. package/dist/hooks/index.d.mts +2 -2
  18. package/dist/hooks/index.d.ts +2 -2
  19. package/dist/hooks/index.js +180 -159
  20. package/dist/hooks/index.js.map +1 -1
  21. package/dist/hooks/index.mjs +4 -4
  22. package/dist/{index-Dt92N6yZ.d.ts → index-BIvPr81B.d.ts} +18 -3
  23. package/dist/{index-D_UNctDI.d.mts → index-BXNFULAw.d.mts} +10 -4
  24. package/dist/{index-CFqk8eNo.d.ts → index-BkWS_v10.d.mts} +1 -1
  25. package/dist/{index-BhU3hF7y.d.ts → index-C2-EMz0t.d.ts} +25 -5
  26. package/dist/{index-DaXXoRxr.d.ts → index-CZHjwqDb.d.ts} +1 -1
  27. package/dist/{index-C5StsjWY.d.ts → index-DDCyj-Fl.d.ts} +10 -4
  28. package/dist/{index-wqqEUufi.d.mts → index-DKFnMFMm.d.mts} +25 -5
  29. package/dist/{index-Bpd2gBNh.d.mts → index-DYkN9eDY.d.mts} +1 -1
  30. package/dist/{index-W6yjuOKT.d.mts → index-TVbqpk9T.d.mts} +18 -3
  31. package/dist/{index-D1QeVZyN.d.ts → index-TsJwrYwh.d.mts} +3 -2
  32. package/dist/{index-mxbJ8CFx.d.mts → index-tFT-63LO.d.ts} +1 -1
  33. package/dist/{index-BaYTgL99.d.mts → index-uhLehOUk.d.ts} +3 -2
  34. package/dist/index.css +115 -15
  35. package/dist/index.d.mts +7 -7
  36. package/dist/index.d.ts +7 -7
  37. package/dist/index.js +562 -414
  38. package/dist/index.js.map +1 -1
  39. package/dist/index.mjs +5 -7
  40. package/dist/types/index.d.mts +1 -1
  41. package/dist/types/index.d.ts +1 -1
  42. package/dist/{types-Bx_FJ11s.d.mts → types-i_ugbm5B.d.mts} +7 -1
  43. package/dist/{types-Bx_FJ11s.d.ts → types-i_ugbm5B.d.ts} +7 -1
  44. package/dist/ui/index.d.mts +3 -3
  45. package/dist/ui/index.d.ts +3 -3
  46. package/dist/ui/index.js +44 -2
  47. package/dist/ui/index.js.map +1 -1
  48. package/dist/ui/index.mjs +7 -3
  49. package/example/src/App.tsx +30 -7
  50. package/example/src/pages/Contact/index.tsx +4 -0
  51. package/example/src/pages/UI/components/Tabs.tsx +18 -0
  52. package/example/src/pages/UI/index.tsx +2 -0
  53. package/package.json +4 -1
  54. package/dist/chunk-LEHYGXVJ.mjs.map +0 -1
  55. package/dist/chunk-RT42O3OC.mjs +0 -97
  56. package/dist/chunk-RT42O3OC.mjs.map +0 -1
  57. package/dist/chunk-V2S54LGG.mjs.map +0 -1
package/dist/ui/index.mjs CHANGED
@@ -11,8 +11,10 @@ import {
11
11
  Overlay,
12
12
  Popover,
13
13
  Radio,
14
- Switch
15
- } from "../chunk-V2S54LGG.mjs";
14
+ Skeleton_default,
15
+ Switch,
16
+ Tabs
17
+ } from "../chunk-AYMVU44P.mjs";
16
18
  import "../chunk-3USZ4ZZY.mjs";
17
19
  import "../chunk-J5LGTIGS.mjs";
18
20
  export {
@@ -28,6 +30,8 @@ export {
28
30
  Overlay,
29
31
  Popover,
30
32
  Radio,
31
- Switch
33
+ Skeleton_default as Skeleton,
34
+ Switch,
35
+ Tabs
32
36
  };
33
37
  //# sourceMappingURL=index.mjs.map
@@ -14,6 +14,7 @@ import useLocalStore from "@/store/useLocalStore";
14
14
  import {LoginButton} from "@matchain/matchid-sdk-react/components";
15
15
  import UI from "@/pages/UI";
16
16
  import TgApp from "@/pages/TgApp";
17
+ import Contact from "./pages/Contact";
17
18
 
18
19
 
19
20
  function Nav() {
@@ -51,6 +52,12 @@ function Nav() {
51
52
  url: '/wallet',
52
53
  onActive: location.pathname === '/wallet',
53
54
  hidden: !isLogin
55
+ },
56
+ {
57
+ name: 'Contact',
58
+ url: '/contact',
59
+ onActive: location.pathname === '/contact',
60
+ hidden: !isLogin
54
61
  }
55
62
  ]
56
63
  return list
@@ -59,7 +66,7 @@ function Nav() {
59
66
  <nav className={`text-2xl mb-5 p-2 text-red-600 flex gap-10 flex-wrap`}>
60
67
  {menus.map((menu) => {
61
68
  return <Link key={menu.url} to={menu.url}
62
- className={`text-2xl ${menu.onActive ? 'text-red-600' : 'text-gray-400'} ${menu.hidden?'hidden' :''}`}>{menu.name}</Link>
69
+ className={`text-2xl ${menu.onActive ? 'text-red-600' : 'text-gray-400'} ${menu.hidden ? 'hidden' : ''}`}>{menu.name}</Link>
63
70
  })}
64
71
 
65
72
  <LoginButton/>
@@ -69,15 +76,29 @@ function Nav() {
69
76
  }
70
77
 
71
78
  function RouterApp() {
72
- const {appid, setAppid, locale, setLocale, endpoints, setEndpoints, setWalletType,walletType,backgroundColor,setBackgroundColor,color,setColor} = useLocalStore()
79
+ const {
80
+ appid,
81
+ setAppid,
82
+ locale,
83
+ setLocale,
84
+ endpoints,
85
+ setEndpoints,
86
+ setWalletType,
87
+ walletType,
88
+ backgroundColor,
89
+ setBackgroundColor,
90
+ color,
91
+ setColor
92
+ } = useLocalStore()
73
93
 
74
94
  return <Router>
75
95
  <div className={`mb-2 p-2 flex gap-2 flex-col`}>
76
96
  <div>
77
97
  <label>BackgroundColor:</label>
78
- <input value={backgroundColor} placeholder={"BackgroundColor"} className={"border-solid border"} onChange={(ele) => {
79
- setBackgroundColor(ele.target.value)
80
- }}/></div>
98
+ <input value={backgroundColor} placeholder={"BackgroundColor"} className={"border-solid border"}
99
+ onChange={(ele) => {
100
+ setBackgroundColor(ele.target.value)
101
+ }}/></div>
81
102
  <div>
82
103
  <label>Color:</label>
83
104
  <input value={color} placeholder={"Color"} className={"border-solid border"} onChange={(ele) => {
@@ -128,6 +149,7 @@ function RouterApp() {
128
149
  <Route element={<RoutePrivate/>}>
129
150
  <Route path="/user" element={<User/>}/>
130
151
  <Route path="/wallet" element={<Wallet/>}/>
152
+ <Route path="/contact" element={<Contact/>}/>
131
153
  </Route>
132
154
  </Routes>
133
155
  </div>
@@ -135,7 +157,7 @@ function RouterApp() {
135
157
  }
136
158
 
137
159
  function App() {
138
- const {appid, locale, endpoints,walletType,backgroundColor,color} = useLocalStore()
160
+ const {appid, locale, endpoints, walletType, backgroundColor, color} = useLocalStore()
139
161
 
140
162
  return <div style={{
141
163
  backgroundColor: backgroundColor,
@@ -157,7 +179,8 @@ function App() {
157
179
  }}
158
180
  >
159
181
  <RouterApp/>
160
- </MatchProvider></div>;
182
+ </MatchProvider>
183
+ </div>;
161
184
  }
162
185
 
163
186
  export default App;
@@ -0,0 +1,4 @@
1
+ import {ContactList} from "@matchain/matchid-sdk-react/components"
2
+ export default function Contact(){
3
+ return <ContactList/>
4
+ }
@@ -0,0 +1,18 @@
1
+ import {useState} from "react";
2
+ import {Tabs} from "@matchain/matchid-sdk-react/ui"
3
+ export default function TabsDemo(){
4
+ const list = ['Tab1', 'Tab2', 'Tab3']
5
+ const [activeTab, setActiveTab] = useState(0)
6
+ return <div>
7
+ <Tabs tabs={list} activeTab={activeTab} setActiveTab={setActiveTab}/>
8
+ <div>
9
+ {list.map((tab, index) => {
10
+ return <div key={index} style={{display: activeTab === index ? 'block' : 'none'}}>
11
+ {tab}
12
+ </div>
13
+ })}
14
+ </div>
15
+ </div>
16
+
17
+
18
+ }
@@ -1,11 +1,13 @@
1
1
  import SwitchDemo from "@/pages/UI/components/Switch";
2
2
  import AlphaAvatarDemo from "@/pages/UI/components/AlphaAvatar";
3
3
  import RadioDemo from "@/pages/UI/components/Radio";
4
+ import TabsDemo from "@/pages/UI/components/Tabs";
4
5
 
5
6
  export default function UI(){
6
7
  return <div>
7
8
  <SwitchDemo/>
8
9
  <AlphaAvatarDemo/>
9
10
  <RadioDemo/>
11
+ <TabsDemo/>
10
12
  </div>
11
13
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@matchain/matchid-sdk-react",
3
- "version": "0.1.53-alpha.5",
3
+ "version": "0.1.53-alpha.7",
4
4
  "main": "dist/index.js",
5
5
  "types": "dist/index.d.ts",
6
6
  "exports": {
@@ -73,11 +73,13 @@
73
73
  "axios-retry": "^4.5.0",
74
74
  "copy-to-clipboard": "^3.3.3",
75
75
  "ethers": "^5.7.2",
76
+ "lodash": "^4.17.21",
76
77
  "moment": "^2.30.1",
77
78
  "react-infinite-scroll-component": "^6.1.0",
78
79
  "react-intl": "^7.1.0",
79
80
  "react-qrcode": "^0.3.6",
80
81
  "react-router-dom": "^6.0.0",
82
+ "react-virtuoso": "^4.12.5",
81
83
  "sats-connect": "^3.0.1",
82
84
  "siwe": "^2.3.2",
83
85
  "styled-components": "^6.1.13",
@@ -87,6 +89,7 @@
87
89
  },
88
90
  "devDependencies": {
89
91
  "@swc/core": "^1.9.1",
92
+ "@types/lodash": "^4.17.16",
90
93
  "@types/react": "^18.0.0",
91
94
  "@types/react-dom": "^18.0.0",
92
95
  "@types/react-modal": "^3.16.3",