mtxuilib 0.1.182 → 0.1.183

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 (593) hide show
  1. package/package.json +1 -1
  2. package/dist/common/DebugFormState.d.ts +0 -4
  3. package/dist/common/DebugFormState.js +0 -11
  4. package/dist/common/DeleteComfirm.d.ts +0 -22
  5. package/dist/common/DeleteComfirm.js +0 -52
  6. package/dist/common/FullCenter.d.ts +0 -2
  7. package/dist/common/FullCenter.js +0 -6
  8. package/dist/common/GlobalSearch.d.ts +0 -11
  9. package/dist/common/GlobalSearch.js +0 -25
  10. package/dist/common/HtmlChangesObserver.d.ts +0 -1
  11. package/dist/common/HtmlChangesObserver.js +0 -53
  12. package/dist/common/MtImage.d.ts +0 -5
  13. package/dist/common/MtImage.js +0 -28
  14. package/dist/common/MtProgressBar.d.ts +0 -1
  15. package/dist/common/MtProgressBar.js +0 -6
  16. package/dist/common/NotFoundGoBack.d.ts +0 -1
  17. package/dist/common/NotFoundGoBack.js +0 -10
  18. package/dist/common/SlntTree/Slnt.z.d.ts +0 -28
  19. package/dist/common/SlntTree/Slnt.z.js +0 -13
  20. package/dist/common/SlntTree/SlntChildrenTabs.d.ts +0 -1
  21. package/dist/common/SlntTree/SlntChildrenTabs.js +0 -26
  22. package/dist/common/SlntTree/SlntTreeNode.d.ts +0 -19
  23. package/dist/common/SlntTree/SlntTreeNode.js +0 -45
  24. package/dist/common/TrpcQuery.d.ts +0 -0
  25. package/dist/common/TrpcQuery.js +0 -1
  26. package/dist/common/devtools/DebugValue.d.ts +0 -5
  27. package/dist/common/devtools/DebugValue.js +0 -8
  28. package/dist/common/devtools/DevTools.d.ts +0 -2
  29. package/dist/common/devtools/DevTools.js +0 -24
  30. package/dist/common/markdown.d.ts +0 -3
  31. package/dist/common/markdown.js +0 -4
  32. package/dist/common/mtlink.d.ts +0 -14
  33. package/dist/common/mtlink.js +0 -15
  34. package/dist/common/pip/PipExamplePage.d.ts +0 -1
  35. package/dist/common/pip/PipExamplePage.js +0 -20
  36. package/dist/common/pip/ReactDocumentPictureInPicture.d.ts +0 -28
  37. package/dist/common/pip/ReactDocumentPictureInPicture.js +0 -117
  38. package/dist/common/react-markdown/Code.d.ts +0 -6
  39. package/dist/common/react-markdown/Code.js +0 -9
  40. package/dist/common/react-markdown/MarkdownToolbar.d.ts +0 -4
  41. package/dist/common/react-markdown/MarkdownToolbar.js +0 -12
  42. package/dist/common/react-markdown/ReactMarkdownExample.d.ts +0 -1
  43. package/dist/common/react-markdown/ReactMarkdownExample.js +0 -19
  44. package/dist/common/schema-form/SchemaFormFieldsRender.d.ts +0 -4
  45. package/dist/common/schema-form/SchemaFormFieldsRender.js +0 -12
  46. package/dist/common/schema-form/SchemaFormView.d.ts +0 -12
  47. package/dist/common/schema-form/SchemaFormView.js +0 -19
  48. package/dist/common/schema-form/schema-form.z.d.ts +0 -90
  49. package/dist/common/schema-form/schema-form.z.js +0 -19
  50. package/dist/common/table/SimpleTable.d.ts +0 -4
  51. package/dist/common/table/SimpleTable.js +0 -10
  52. package/dist/common/table/cells/ExpenderCell.d.ts +0 -2
  53. package/dist/common/table/cells/ExpenderCell.js +0 -7
  54. package/dist/common/table/cells/SelectCell.d.ts +0 -12
  55. package/dist/common/table/cells/SelectCell.js +0 -19
  56. package/dist/common/table/cells/Text.d.ts +0 -8
  57. package/dist/common/table/cells/Text.js +0 -13
  58. package/dist/common/table/cells/ViewLink.d.ts +0 -12
  59. package/dist/common/table/cells/ViewLink.js +0 -19
  60. package/dist/common/table/cells/container/cellWrapper.d.ts +0 -6
  61. package/dist/common/table/cells/container/cellWrapper.js +0 -5
  62. package/dist/common/table/cells/number.d.ts +0 -2
  63. package/dist/common/table/cells/number.js +0 -10
  64. package/dist/common/table/cells/string.d.ts +0 -2
  65. package/dist/common/table/cells/string.js +0 -15
  66. package/dist/common/table/data-table-pagination.d.ts +0 -6
  67. package/dist/common/table/data-table-pagination.js +0 -10
  68. package/dist/common/table/data-table-view-options.d.ts +0 -6
  69. package/dist/common/table/data-table-view-options.js +0 -13
  70. package/dist/common/table/datatable-view-options.d.ts +0 -12
  71. package/dist/common/table/datatable-view-options.js +0 -2
  72. package/dist/common/table/example/ExampleTable.d.ts +0 -1
  73. package/dist/common/table/example/ExampleTable.js +0 -84
  74. package/dist/common/table/header/SimpleHeader.d.ts +0 -4
  75. package/dist/common/table/header/SimpleHeader.js +0 -16
  76. package/dist/common/table/header/header.d.ts +0 -5
  77. package/dist/common/table/header/header.js +0 -16
  78. package/dist/common/table/table.z.d.ts +0 -189
  79. package/dist/common/table/table.z.js +0 -35
  80. package/dist/common/tailwind-indicator.d.ts +0 -1
  81. package/dist/common/tailwind-indicator.js +0 -7
  82. package/dist/common/theme/mode-toggle.d.ts +0 -1
  83. package/dist/common/theme/mode-toggle.js +0 -10
  84. package/dist/common/theme/theme-toggle.d.ts +0 -1
  85. package/dist/common/theme/theme-toggle.js +0 -9
  86. package/dist/common/tiptap/MenuBar.d.ts +0 -1
  87. package/dist/common/tiptap/MenuBar.js +0 -34
  88. package/dist/common/tiptap/TiptapEditor.d.ts +0 -5
  89. package/dist/common/tiptap/TiptapEditor.js +0 -46
  90. package/dist/common/tiptap/examples/Demo-Default.d.ts +0 -1
  91. package/dist/common/tiptap/examples/Demo-Default.js +0 -84
  92. package/dist/common/tiptap/examples/Demo-Tiptap.d.ts +0 -1
  93. package/dist/common/tiptap/examples/Demo-Tiptap.js +0 -13
  94. package/dist/components/ChatMessageBubble.d.ts +0 -6
  95. package/dist/components/ChatMessageBubble.js +0 -7
  96. package/dist/components/IntermediateStep.d.ts +0 -4
  97. package/dist/components/IntermediateStep.js +0 -9
  98. package/dist/components/UploadDocumentsForm.d.ts +0 -1
  99. package/dist/components/UploadDocumentsForm.js +0 -28
  100. package/dist/components/auth/LoginDlg.d.ts +0 -0
  101. package/dist/components/auth/LoginDlg.js +0 -1
  102. package/dist/components/button-scroll-to-bottom.d.ts +0 -7
  103. package/dist/components/button-scroll-to-bottom.js +0 -8
  104. package/dist/components/chat-share-dialog.d.ts +0 -9
  105. package/dist/components/chat-share-dialog.js +0 -33
  106. package/dist/components/empty-screen.d.ts +0 -1
  107. package/dist/components/empty-screen.js +0 -4
  108. package/dist/components/external-link.d.ts +0 -4
  109. package/dist/components/external-link.js +0 -4
  110. package/dist/components/message.d.ts +0 -16
  111. package/dist/components/message.js +0 -43
  112. package/dist/components/spinner.d.ts +0 -1
  113. package/dist/components/spinner.js +0 -3
  114. package/dist/components/tool-ui/BlogHomePage.d.ts +0 -5
  115. package/dist/components/tool-ui/BlogHomePage.js +0 -8
  116. package/dist/components/tool-ui/BlogHomePage.z.d.ts +0 -60
  117. package/dist/components/tool-ui/BlogHomePage.z.js +0 -20
  118. package/dist/components/tool-ui/DemoCategoryGen.d.ts +0 -3
  119. package/dist/components/tool-ui/DemoCategoryGen.js +0 -8
  120. package/dist/components/tool-ui/OpenBrowser.d.ts +0 -1
  121. package/dist/components/tool-ui/OpenBrowser.js +0 -25
  122. package/dist/demos/bigcode/BigCode.d.ts +0 -4
  123. package/dist/demos/bigcode/BigCode.js +0 -11
  124. package/dist/demos/condition-type/serialize.d.ts +0 -3
  125. package/dist/demos/condition-type/serialize.js +0 -31
  126. package/dist/demos/lib.d.ts +0 -3
  127. package/dist/demos/lib.js +0 -20
  128. package/dist/demos/scrollarea/LongListDemo.d.ts +0 -1
  129. package/dist/demos/scrollarea/LongListDemo.js +0 -7
  130. package/dist/demos/scrollarea/ScrollAreaDemo.d.ts +0 -1
  131. package/dist/demos/scrollarea/ScrollAreaDemo.js +0 -14
  132. package/dist/demos/suspense-ssr/ExampleOg.d.ts +0 -4
  133. package/dist/demos/suspense-ssr/ExampleOg.js +0 -7
  134. package/dist/demos/suspense-ssr/ExamplePage.d.ts +0 -3
  135. package/dist/demos/suspense-ssr/ExamplePage.js +0 -13
  136. package/dist/demos/suspense-ssr/ExampleProviderProviders.d.ts +0 -3
  137. package/dist/demos/suspense-ssr/ExampleProviderProviders.js +0 -9
  138. package/dist/demos/suspense-ssr/ReadMe.d.ts +0 -1
  139. package/dist/demos/suspense-ssr/ReadMe.js +0 -6
  140. package/dist/demos/suspense-ssr/examplesPostDetail.d.ts +0 -3
  141. package/dist/demos/suspense-ssr/examplesPostDetail.js +0 -20
  142. package/dist/demos/suspense-ssr/examplesPosts.d.ts +0 -1
  143. package/dist/demos/suspense-ssr/examplesPosts.js +0 -17
  144. package/dist/form/EditFormToolbar.d.ts +0 -13
  145. package/dist/form/EditFormToolbar.js +0 -51
  146. package/dist/form/PopupFormV2.d.ts +0 -46
  147. package/dist/form/PopupFormV2.js +0 -74
  148. package/dist/form/SchemaFormFieldRender.d.ts +0 -6
  149. package/dist/form/SchemaFormFieldRender.js +0 -28
  150. package/dist/form/ZodForm.d.ts +0 -13
  151. package/dist/form/ZodForm.js +0 -32
  152. package/dist/form/deleteConform.d.ts +0 -8
  153. package/dist/form/deleteConform.js +0 -38
  154. package/dist/hooks/use-config.d.ts +0 -5
  155. package/dist/hooks/use-config.js +0 -8
  156. package/dist/hooks/use-copy-to-clipboard.d.ts +0 -7
  157. package/dist/hooks/use-copy-to-clipboard.js +0 -20
  158. package/dist/hooks/use-enter-submit.d.ts +0 -5
  159. package/dist/hooks/use-enter-submit.js +0 -11
  160. package/dist/hooks/use-local-storage.d.ts +0 -1
  161. package/dist/hooks/use-local-storage.js +0 -15
  162. package/dist/hooks/use-lock-body.d.ts +0 -1
  163. package/dist/hooks/use-lock-body.js +0 -8
  164. package/dist/hooks/use-media-query.d.ts +0 -7
  165. package/dist/hooks/use-media-query.js +0 -33
  166. package/dist/hooks/use-mutation-observer.d.ts +0 -7
  167. package/dist/hooks/use-mutation-observer.js +0 -15
  168. package/dist/hooks/use-router.d.ts +0 -18
  169. package/dist/hooks/use-router.js +0 -51
  170. package/dist/hooks/use-scroll-anchor.d.ts +0 -8
  171. package/dist/hooks/use-scroll-anchor.js +0 -70
  172. package/dist/hooks/use-streamable-text.d.ts +0 -2
  173. package/dist/hooks/use-streamable-text.js +0 -19
  174. package/dist/hooks/useIsIntersecting.d.ts +0 -2
  175. package/dist/hooks/useIsIntersecting.js +0 -17
  176. package/dist/hooks/useLayoutPath.d.ts +0 -2
  177. package/dist/hooks/useLayoutPath.js +0 -21
  178. package/dist/hooks/useMounted.d.ts +0 -1
  179. package/dist/hooks/useMounted.js +0 -8
  180. package/dist/hooks/useScript.d.ts +0 -3
  181. package/dist/hooks/useScript.js +0 -66
  182. package/dist/icons/Cross2Icon.d.ts +0 -1
  183. package/dist/icons/Cross2Icon.js +0 -1
  184. package/dist/icons/DotsHorizontalIcon.d.ts +0 -1
  185. package/dist/icons/DotsHorizontalIcon.js +0 -1
  186. package/dist/icons/MixerHorizontal.d.ts +0 -1
  187. package/dist/icons/MixerHorizontal.js +0 -1
  188. package/dist/icons/crazy-spinner.d.ts +0 -2
  189. package/dist/icons/crazy-spinner.js +0 -5
  190. package/dist/icons/font-default.d.ts +0 -3
  191. package/dist/icons/font-default.js +0 -4
  192. package/dist/icons/font-mono.d.ts +0 -3
  193. package/dist/icons/font-mono.js +0 -4
  194. package/dist/icons/font-serif.d.ts +0 -3
  195. package/dist/icons/font-serif.js +0 -4
  196. package/dist/icons/github.d.ts +0 -3
  197. package/dist/icons/github.js +0 -4
  198. package/dist/icons/icons-ai.d.ts +0 -31
  199. package/dist/icons/icons-ai.js +0 -87
  200. package/dist/icons/icons.d.ts +0 -132
  201. package/dist/icons/icons.js +0 -147
  202. package/dist/icons/index.d.ts +0 -4
  203. package/dist/icons/index.js +0 -4
  204. package/dist/icons/loading-circle.d.ts +0 -3
  205. package/dist/icons/loading-circle.js +0 -4
  206. package/dist/icons/magic.d.ts +0 -3
  207. package/dist/icons/magic.js +0 -4
  208. package/dist/lib/clientlib.d.ts +0 -5
  209. package/dist/lib/clientlib.js +0 -37
  210. package/dist/lib/componentHelper.d.ts +0 -7
  211. package/dist/lib/componentHelper.js +0 -43
  212. package/dist/lib/domutils.d.ts +0 -2
  213. package/dist/lib/domutils.js +0 -11
  214. package/dist/lib/errors.d.ts +0 -4
  215. package/dist/lib/errors.js +0 -8
  216. package/dist/lib/highlight-code.d.ts +0 -1
  217. package/dist/lib/highlight-code.js +0 -20
  218. package/dist/lib/htmlparse/components/ItemActionButton.d.ts +0 -2
  219. package/dist/lib/htmlparse/components/ItemActionButton.js +0 -25
  220. package/dist/lib/htmlparse/htmlParse.d.ts +0 -2
  221. package/dist/lib/htmlparse/htmlParse.js +0 -32
  222. package/dist/lib/react-query/ReactQueryProvider.d.ts +0 -4
  223. package/dist/lib/react-query/ReactQueryProvider.js +0 -31
  224. package/dist/lib/render.d.ts +0 -3
  225. package/dist/lib/render.js +0 -21
  226. package/dist/lib/service-worker/ServiceWorkerMain.d.ts +0 -1
  227. package/dist/lib/service-worker/ServiceWorkerMain.js +0 -25
  228. package/dist/lib/service-worker/sw.d.ts +0 -5
  229. package/dist/lib/service-worker/sw.js +0 -31
  230. package/dist/lib/types.d.ts +0 -32
  231. package/dist/lib/types.js +0 -1
  232. package/dist/lib/utils.d.ts +0 -38
  233. package/dist/lib/utils.js +0 -206
  234. package/dist/lib/zustand.d.ts +0 -9
  235. package/dist/lib/zustand.js +0 -30
  236. package/dist/misc/CustomErrorRetry.d.ts +0 -4
  237. package/dist/misc/CustomErrorRetry.js +0 -9
  238. package/dist/misc/ExampleErrorDemo.d.ts +0 -3
  239. package/dist/misc/ExampleErrorDemo.js +0 -14
  240. package/dist/misc/MtErrorBoundary.d.ts +0 -16
  241. package/dist/misc/MtErrorBoundary.js +0 -23
  242. package/dist/misc/MtErrorBoundary.stories.d.ts +0 -15
  243. package/dist/misc/MtErrorBoundary.stories.js +0 -27
  244. package/dist/misc/MtErrorBoundaryV2.d.ts +0 -2
  245. package/dist/misc/MtErrorBoundaryV2.js +0 -7
  246. package/dist/misc/MtErrorBoundaryV2.stories.d.ts +0 -14
  247. package/dist/misc/MtErrorBoundaryV2.stories.js +0 -25
  248. package/dist/mtapp/History.d.ts +0 -23
  249. package/dist/mtapp/History.js +0 -58
  250. package/dist/mtapp/MtAppProvider.d.ts +0 -53
  251. package/dist/mtapp/MtAppProvider.js +0 -62
  252. package/dist/mtedtior/LzMtEditor.d.ts +0 -6
  253. package/dist/mtedtior/LzMtEditor.js +0 -7
  254. package/dist/mtedtior/MtEditor.d.ts +0 -29
  255. package/dist/mtedtior/MtEditor.js +0 -106
  256. package/dist/mtedtior/components/editor-bubble-item.d.ts +0 -9
  257. package/dist/mtedtior/components/editor-bubble-item.js +0 -14
  258. package/dist/mtedtior/components/editor-bubble.d.ts +0 -7
  259. package/dist/mtedtior/components/editor-bubble.js +0 -43
  260. package/dist/mtedtior/components/editor-command-item.d.ts +0 -19
  261. package/dist/mtedtior/components/editor-command-item.js +0 -16
  262. package/dist/mtedtior/components/editor-command.d.ts +0 -29
  263. package/dist/mtedtior/components/editor-command.js +0 -46
  264. package/dist/mtedtior/components/editor.d.ts +0 -21
  265. package/dist/mtedtior/components/editor.js +0 -12
  266. package/dist/mtedtior/components/index.d.ts +0 -8
  267. package/dist/mtedtior/components/index.js +0 -6
  268. package/dist/mtedtior/content.d.ts +0 -132
  269. package/dist/mtedtior/content.js +0 -248
  270. package/dist/mtedtior/extensions/ai-highlight.d.ts +0 -22
  271. package/dist/mtedtior/extensions/ai-highlight.js +0 -88
  272. package/dist/mtedtior/extensions/custom-keymap.d.ts +0 -10
  273. package/dist/mtedtior/extensions/custom-keymap.js +0 -38
  274. package/dist/mtedtior/extensions/drag-and-drop.d.ts +0 -6
  275. package/dist/mtedtior/extensions/drag-and-drop.js +0 -165
  276. package/dist/mtedtior/extensions/image-resizer.d.ts +0 -2
  277. package/dist/mtedtior/extensions/image-resizer.js +0 -31
  278. package/dist/mtedtior/extensions/index.d.ts +0 -23
  279. package/dist/mtedtior/extensions/index.js +0 -73
  280. package/dist/mtedtior/extensions/mathematics.d.ts +0 -20
  281. package/dist/mtedtior/extensions/mathematics.js +0 -110
  282. package/dist/mtedtior/extensions/slash-command.d.ts +0 -33
  283. package/dist/mtedtior/extensions/slash-command.js +0 -224
  284. package/dist/mtedtior/extensions/twitter.d.ts +0 -22
  285. package/dist/mtedtior/extensions/twitter.js +0 -84
  286. package/dist/mtedtior/extensions/updated-image.d.ts +0 -2
  287. package/dist/mtedtior/extensions/updated-image.js +0 -17
  288. package/dist/mtedtior/generative/ai-completion-command.d.ts +0 -5
  289. package/dist/mtedtior/generative/ai-completion-command.js +0 -30
  290. package/dist/mtedtior/generative/ai-selector-commands.d.ts +0 -5
  291. package/dist/mtedtior/generative/ai-selector-commands.js +0 -42
  292. package/dist/mtedtior/generative/ai-selector.d.ts +0 -6
  293. package/dist/mtedtior/generative/ai-selector.js +0 -50
  294. package/dist/mtedtior/generative/generative-menu-switch.d.ts +0 -8
  295. package/dist/mtedtior/generative/generative-menu-switch.js +0 -26
  296. package/dist/mtedtior/mtextesions/DemoComponent.d.ts +0 -2
  297. package/dist/mtedtior/mtextesions/DemoComponent.js +0 -32
  298. package/dist/mtedtior/mtextesions/image-upload.d.ts +0 -1
  299. package/dist/mtedtior/mtextesions/image-upload.js +0 -52
  300. package/dist/mtedtior/mtextesions/slash-command.d.ts +0 -2
  301. package/dist/mtedtior/mtextesions/slash-command.js +0 -194
  302. package/dist/mtedtior/mtextesions/tw_extensions.d.ts +0 -1
  303. package/dist/mtedtior/mtextesions/tw_extensions.js +0 -137
  304. package/dist/mtedtior/plugins/index.d.ts +0 -1
  305. package/dist/mtedtior/plugins/index.js +0 -1
  306. package/dist/mtedtior/plugins/upload-images.d.ts +0 -13
  307. package/dist/mtedtior/plugins/upload-images.js +0 -98
  308. package/dist/mtedtior/selectors/color-selector.d.ts +0 -8
  309. package/dist/mtedtior/selectors/color-selector.js +0 -104
  310. package/dist/mtedtior/selectors/link-selector.d.ts +0 -8
  311. package/dist/mtedtior/selectors/link-selector.js +0 -50
  312. package/dist/mtedtior/selectors/math-selector.d.ts +0 -1
  313. package/dist/mtedtior/selectors/math-selector.js +0 -22
  314. package/dist/mtedtior/selectors/node-selector.d.ts +0 -14
  315. package/dist/mtedtior/selectors/node-selector.js +0 -77
  316. package/dist/mtedtior/selectors/text-buttons.d.ts +0 -1
  317. package/dist/mtedtior/selectors/text-buttons.js +0 -44
  318. package/dist/mtedtior/utils/summary.d.ts +0 -1
  319. package/dist/mtedtior/utils/summary.js +0 -8
  320. package/dist/mtedtior/utils/utils.d.ts +0 -9
  321. package/dist/mtedtior/utils/utils.js +0 -32
  322. package/dist/mtedtior/utils.d.ts +0 -9
  323. package/dist/mtedtior/utils.js +0 -33
  324. package/dist/styled-system/css/conditions.d.mts +0 -3
  325. package/dist/styled-system/css/conditions.mjs +0 -30
  326. package/dist/styled-system/css/css.d.mts +0 -6
  327. package/dist/styled-system/css/css.mjs +0 -37
  328. package/dist/styled-system/css/cva.d.mts +0 -14
  329. package/dist/styled-system/css/cva.mjs +0 -72
  330. package/dist/styled-system/css/cx.d.mts +0 -1
  331. package/dist/styled-system/css/cx.mjs +0 -11
  332. package/dist/styled-system/css/index.d.mts +0 -4
  333. package/dist/styled-system/css/index.mjs +0 -4
  334. package/dist/styled-system/css/sva.d.mts +0 -10
  335. package/dist/styled-system/css/sva.mjs +0 -31
  336. package/dist/styled-system/helpers.d.mts +0 -39
  337. package/dist/styled-system/helpers.mjs +0 -248
  338. package/dist/styled-system/patterns/aspect-ratio.d.mts +0 -5
  339. package/dist/styled-system/patterns/aspect-ratio.mjs +0 -36
  340. package/dist/styled-system/patterns/bleed.d.mts +0 -5
  341. package/dist/styled-system/patterns/bleed.mjs +0 -22
  342. package/dist/styled-system/patterns/box.d.mts +0 -5
  343. package/dist/styled-system/patterns/box.mjs +0 -13
  344. package/dist/styled-system/patterns/center.d.mts +0 -5
  345. package/dist/styled-system/patterns/center.mjs +0 -19
  346. package/dist/styled-system/patterns/circle.d.mts +0 -5
  347. package/dist/styled-system/patterns/circle.mjs +0 -23
  348. package/dist/styled-system/patterns/container.d.mts +0 -5
  349. package/dist/styled-system/patterns/container.mjs +0 -19
  350. package/dist/styled-system/patterns/cq.d.mts +0 -5
  351. package/dist/styled-system/patterns/cq.mjs +0 -19
  352. package/dist/styled-system/patterns/divider.d.mts +0 -5
  353. package/dist/styled-system/patterns/divider.mjs +0 -23
  354. package/dist/styled-system/patterns/flex.d.mts +0 -5
  355. package/dist/styled-system/patterns/flex.mjs +0 -24
  356. package/dist/styled-system/patterns/float.d.mts +0 -5
  357. package/dist/styled-system/patterns/float.mjs +0 -50
  358. package/dist/styled-system/patterns/grid-item.d.mts +0 -5
  359. package/dist/styled-system/patterns/grid-item.mjs +0 -23
  360. package/dist/styled-system/patterns/grid.d.mts +0 -5
  361. package/dist/styled-system/patterns/grid.mjs +0 -25
  362. package/dist/styled-system/patterns/hstack.d.mts +0 -5
  363. package/dist/styled-system/patterns/hstack.mjs +0 -22
  364. package/dist/styled-system/patterns/index.d.mts +0 -20
  365. package/dist/styled-system/patterns/index.mjs +0 -20
  366. package/dist/styled-system/patterns/link-overlay.d.mts +0 -5
  367. package/dist/styled-system/patterns/link-overlay.mjs +0 -22
  368. package/dist/styled-system/patterns/spacer.d.mts +0 -5
  369. package/dist/styled-system/patterns/spacer.mjs +0 -19
  370. package/dist/styled-system/patterns/square.d.mts +0 -5
  371. package/dist/styled-system/patterns/square.mjs +0 -22
  372. package/dist/styled-system/patterns/stack.d.mts +0 -5
  373. package/dist/styled-system/patterns/stack.mjs +0 -22
  374. package/dist/styled-system/patterns/visually-hidden.d.mts +0 -5
  375. package/dist/styled-system/patterns/visually-hidden.mjs +0 -16
  376. package/dist/styled-system/patterns/vstack.d.mts +0 -5
  377. package/dist/styled-system/patterns/vstack.mjs +0 -22
  378. package/dist/styled-system/patterns/wrap.d.mts +0 -5
  379. package/dist/styled-system/patterns/wrap.mjs +0 -23
  380. package/dist/styled-system/tokens/index.d.mts +0 -6
  381. package/dist/styled-system/tokens/index.mjs +0 -1885
  382. package/dist/tailwind.d.ts +0 -3
  383. package/dist/tailwind.js +0 -72
  384. package/dist/tools/countDown.d.ts +0 -32
  385. package/dist/tools/countDown.js +0 -35
  386. package/dist/tools/devTools/cloudflareTunnel.d.ts +0 -17
  387. package/dist/tools/devTools/cloudflareTunnel.js +0 -43
  388. package/dist/tools/devTools/docker-compose.d.ts +0 -8
  389. package/dist/tools/devTools/docker-compose.js +0 -13
  390. package/dist/tools/devTools/dpMtCfWorkerTool.d.ts +0 -8
  391. package/dist/tools/devTools/dpMtCfWorkerTool.js +0 -13
  392. package/dist/tools/devTools/getIp.d.ts +0 -14
  393. package/dist/tools/devTools/getIp.js +0 -29
  394. package/dist/tools/devTools/installOsPackages.d.ts +0 -8
  395. package/dist/tools/devTools/installOsPackages.js +0 -29
  396. package/dist/tools/devTools/ollamaService.d.ts +0 -14
  397. package/dist/tools/devTools/ollamaService.js +0 -28
  398. package/dist/tools/devTools/vncServer.d.ts +0 -1
  399. package/dist/tools/devTools/vncServer.js +0 -1
  400. package/dist/tools/genSiteHeaderBarsTool.d.ts +0 -14
  401. package/dist/tools/genSiteHeaderBarsTool.js +0 -16
  402. package/dist/tools/hello1Tool.d.ts +0 -14
  403. package/dist/tools/hello1Tool.js +0 -15
  404. package/dist/tools/rag/RagHello.d.ts +0 -8
  405. package/dist/tools/rag/RagHello.js +0 -14
  406. package/dist/tools/rag/addResoure.d.ts +0 -18
  407. package/dist/tools/rag/addResoure.js +0 -27
  408. package/dist/tools/rag/getInformation.d.ts +0 -18
  409. package/dist/tools/rag/getInformation.js +0 -15
  410. package/dist/tools/rag/ui/RagInput.d.ts +0 -2
  411. package/dist/tools/rag/ui/RagInput.js +0 -29
  412. package/dist/tools/search/exampleSearchTool.d.ts +0 -8
  413. package/dist/tools/search/exampleSearchTool.js +0 -13
  414. package/dist/tools/webbot/callAdminBot.d.ts +0 -8
  415. package/dist/tools/webbot/callAdminBot.js +0 -14
  416. package/dist/tools/welcomeAdminTool.d.ts +0 -8
  417. package/dist/tools/welcomeAdminTool.js +0 -13
  418. package/dist/types/common.d.ts +0 -15
  419. package/dist/types/common.js +0 -1
  420. package/dist/ui/accordion.d.ts +0 -7
  421. package/dist/ui/accordion.js +0 -14
  422. package/dist/ui/alert-dialog.d.ts +0 -20
  423. package/dist/ui/alert-dialog.js +0 -27
  424. package/dist/ui/alert.d.ts +0 -8
  425. package/dist/ui/alert.js +0 -22
  426. package/dist/ui/aspect-ratio.d.ts +0 -3
  427. package/dist/ui/aspect-ratio.js +0 -4
  428. package/dist/ui/avatar.d.ts +0 -6
  429. package/dist/ui/avatar.js +0 -12
  430. package/dist/ui/badge.d.ts +0 -9
  431. package/dist/ui/badge.js +0 -20
  432. package/dist/ui/breadcrumb.d.ts +0 -19
  433. package/dist/ui/breadcrumb.js +0 -23
  434. package/dist/ui/button.d.ts +0 -11
  435. package/dist/ui/button.js +0 -33
  436. package/dist/ui/calendar.d.ts +0 -8
  437. package/dist/ui/calendar.js +0 -40
  438. package/dist/ui/card.d.ts +0 -8
  439. package/dist/ui/card.js +0 -16
  440. package/dist/ui/checkbox.d.ts +0 -4
  441. package/dist/ui/checkbox.js +0 -9
  442. package/dist/ui/codeblock.d.ts +0 -12
  443. package/dist/ui/codeblock.js +0 -85
  444. package/dist/ui/collapsible.d.ts +0 -5
  445. package/dist/ui/collapsible.js +0 -6
  446. package/dist/ui/command.d.ts +0 -50
  447. package/dist/ui/command.js +0 -29
  448. package/dist/ui/context-menu.d.ts +0 -27
  449. package/dist/ui/context-menu.js +0 -34
  450. package/dist/ui/dialog.d.ts +0 -19
  451. package/dist/ui/dialog.js +0 -23
  452. package/dist/ui/drawer.d.ts +0 -24
  453. package/dist/ui/drawer.js +0 -23
  454. package/dist/ui/dropdown-menu.d.ts +0 -27
  455. package/dist/ui/dropdown-menu.js +0 -36
  456. package/dist/ui/form.d.ts +0 -23
  457. package/dist/ui/form.js +0 -62
  458. package/dist/ui/hover-card.d.ts +0 -6
  459. package/dist/ui/hover-card.js +0 -10
  460. package/dist/ui/input.d.ts +0 -5
  461. package/dist/ui/input.js +0 -8
  462. package/dist/ui/label.d.ts +0 -5
  463. package/dist/ui/label.js +0 -10
  464. package/dist/ui/menubar.d.ts +0 -33
  465. package/dist/ui/menubar.js +0 -36
  466. package/dist/ui/mt/Boundary.d.ts +0 -9
  467. package/dist/ui/mt/Boundary.js +0 -10
  468. package/dist/ui/mt/Button.d.ts +0 -1
  469. package/dist/ui/mt/Button.js +0 -2
  470. package/dist/ui/mt/DropdownMenuItemLink.d.ts +0 -7
  471. package/dist/ui/mt/DropdownMenuItemLink.js +0 -8
  472. package/dist/ui/mt/ErrorMessage.d.ts +0 -2
  473. package/dist/ui/mt/ErrorMessage.js +0 -6
  474. package/dist/ui/mt/ExampleTree.d.ts +0 -1
  475. package/dist/ui/mt/ExampleTree.js +0 -79
  476. package/dist/ui/mt/MtDialog.d.ts +0 -19
  477. package/dist/ui/mt/MtDialog.js +0 -38
  478. package/dist/ui/mt/MtForm.d.ts +0 -1
  479. package/dist/ui/mt/MtForm.js +0 -3
  480. package/dist/ui/mt/NavTag.d.ts +0 -10
  481. package/dist/ui/mt/NavTag.js +0 -28
  482. package/dist/ui/mt/ScreenPanel.d.ts +0 -4
  483. package/dist/ui/mt/ScreenPanel.js +0 -9
  484. package/dist/ui/mt/Separator.d.ts +0 -1
  485. package/dist/ui/mt/Separator.js +0 -3
  486. package/dist/ui/mt/SimpleModel.d.ts +0 -3
  487. package/dist/ui/mt/SimpleModel.js +0 -27
  488. package/dist/ui/mt/SimpleTag.d.ts +0 -5
  489. package/dist/ui/mt/SimpleTag.js +0 -6
  490. package/dist/ui/mt/Slot.d.ts +0 -1
  491. package/dist/ui/mt/Slot.js +0 -1
  492. package/dist/ui/mt/Tree.d.ts +0 -14
  493. package/dist/ui/mt/Tree.js +0 -63
  494. package/dist/ui/mt/WithLinkIf.d.ts +0 -4
  495. package/dist/ui/mt/WithLinkIf.js +0 -10
  496. package/dist/ui/mt/headline.d.ts +0 -7
  497. package/dist/ui/mt/headline.js +0 -4
  498. package/dist/ui/mt/input-field/InputField.d.ts +0 -4
  499. package/dist/ui/mt/input-field/InputField.js +0 -19
  500. package/dist/ui/mt/input-field/SingleUploadForm.d.ts +0 -2
  501. package/dist/ui/mt/input-field/SingleUploadForm.js +0 -62
  502. package/dist/ui/mt/input-field/TextArea.d.ts +0 -4
  503. package/dist/ui/mt/input-field/TextArea.js +0 -13
  504. package/dist/ui/mt/input-field/TextFileInput.d.ts +0 -8
  505. package/dist/ui/mt/input-field/TextFileInput.js +0 -36
  506. package/dist/ui/mt/input-field/select/InputSelect.d.ts +0 -8
  507. package/dist/ui/mt/input-field/select/InputSelect.js +0 -16
  508. package/dist/ui/mt/inputs/SearchInput.d.ts +0 -2
  509. package/dist/ui/mt/inputs/SearchInput.js +0 -10
  510. package/dist/ui/mt/inputs/TaskStatusInput.d.ts +0 -2
  511. package/dist/ui/mt/inputs/TaskStatusInput.js +0 -22
  512. package/dist/ui/mt/inputs/UrlsInput.d.ts +0 -2
  513. package/dist/ui/mt/inputs/UrlsInput.js +0 -15
  514. package/dist/ui/mt/inputs/input.d.ts +0 -1
  515. package/dist/ui/mt/inputs/input.js +0 -2
  516. package/dist/ui/mt/modal/MtModal.d.ts +0 -29
  517. package/dist/ui/mt/modal/MtModal.js +0 -52
  518. package/dist/ui/mt/mt-tree-view/MtTreeViewExample.d.ts +0 -1
  519. package/dist/ui/mt/mt-tree-view/MtTreeViewExample.js +0 -2
  520. package/dist/ui/mt/mt-tree-view/mt-tree-view-api.d.ts +0 -39
  521. package/dist/ui/mt/mt-tree-view/mt-tree-view-api.js +0 -132
  522. package/dist/ui/mt/mt-tree-view/mt-treeview.d.ts +0 -24
  523. package/dist/ui/mt/mt-tree-view/mt-treeview.js +0 -25
  524. package/dist/ui/mt/mtlink.d.ts +0 -14
  525. package/dist/ui/mt/mtlink.js +0 -15
  526. package/dist/ui/mt/pagination.d.ts +0 -7
  527. package/dist/ui/mt/pagination.js +0 -30
  528. package/dist/ui/mt/skeleton/NewLoading.d.ts +0 -1
  529. package/dist/ui/mt/skeleton/NewLoading.js +0 -6
  530. package/dist/ui/mt/skeleton/SkeletonInput.d.ts +0 -1
  531. package/dist/ui/mt/skeleton/SkeletonInput.js +0 -5
  532. package/dist/ui/mt/skeleton/SkeletonLayout.d.ts +0 -1
  533. package/dist/ui/mt/skeleton/SkeletonLayout.js +0 -6
  534. package/dist/ui/mt/skeleton/SkeletonLoading.d.ts +0 -3
  535. package/dist/ui/mt/skeleton/SkeletonLoading.js +0 -10
  536. package/dist/ui/mt/skeleton/skeleton-card.d.ts +0 -3
  537. package/dist/ui/mt/skeleton/skeleton-card.js +0 -5
  538. package/dist/ui/mt/skeleton/skeleton2.d.ts +0 -1
  539. package/dist/ui/mt/skeleton/skeleton2.js +0 -4
  540. package/dist/ui/mt/skeleton/skeletons.d.ts +0 -6
  541. package/dist/ui/mt/skeleton/skeletons.js +0 -6
  542. package/dist/ui/mt/skeleton.d.ts +0 -5
  543. package/dist/ui/mt/skeleton.js +0 -5
  544. package/dist/ui/mt/types.d.ts +0 -4
  545. package/dist/ui/mt/types.js +0 -1
  546. package/dist/ui/navigation-menu.d.ts +0 -12
  547. package/dist/ui/navigation-menu.js +0 -25
  548. package/dist/ui/pagination.d.ts +0 -28
  549. package/dist/ui/pagination.js +0 -23
  550. package/dist/ui/popover.d.ts +0 -6
  551. package/dist/ui/popover.js +0 -10
  552. package/dist/ui/progress.d.ts +0 -4
  553. package/dist/ui/progress.js +0 -8
  554. package/dist/ui/radio-group.d.ts +0 -5
  555. package/dist/ui/radio-group.js +0 -15
  556. package/dist/ui/resizable.d.ts +0 -23
  557. package/dist/ui/resizable.js +0 -9
  558. package/dist/ui/scroll-area.d.ts +0 -5
  559. package/dist/ui/scroll-area.js +0 -12
  560. package/dist/ui/select.d.ts +0 -11
  561. package/dist/ui/select.js +0 -22
  562. package/dist/ui/separator.d.ts +0 -4
  563. package/dist/ui/separator.js +0 -8
  564. package/dist/ui/sheet.d.ts +0 -25
  565. package/dist/ui/sheet.js +0 -37
  566. package/dist/ui/skeleton.d.ts +0 -2
  567. package/dist/ui/skeleton.js +0 -6
  568. package/dist/ui/slider.d.ts +0 -4
  569. package/dist/ui/slider.js +0 -8
  570. package/dist/ui/sonner.d.ts +0 -4
  571. package/dist/ui/sonner.js +0 -16
  572. package/dist/ui/switch.d.ts +0 -4
  573. package/dist/ui/switch.js +0 -8
  574. package/dist/ui/table.d.ts +0 -10
  575. package/dist/ui/table.js +0 -20
  576. package/dist/ui/tabs.d.ts +0 -7
  577. package/dist/ui/tabs.js +0 -13
  578. package/dist/ui/textarea.d.ts +0 -5
  579. package/dist/ui/textarea.js +0 -8
  580. package/dist/ui/toast.d.ts +0 -15
  581. package/dist/ui/toast.js +0 -33
  582. package/dist/ui/toaster.d.ts +0 -1
  583. package/dist/ui/toaster.js +0 -10
  584. package/dist/ui/toggle.d.ts +0 -12
  585. package/dist/ui/toggle.js +0 -26
  586. package/dist/ui/tooltip.d.ts +0 -7
  587. package/dist/ui/tooltip.js +0 -11
  588. package/dist/ui/use-toast.d.ts +0 -44
  589. package/dist/ui/use-toast.js +0 -124
  590. package/dist/video-player/mt-video-player.d.ts +0 -6
  591. package/dist/video-player/mt-video-player.js +0 -28
  592. package/dist/video-player/video-player2/modal-video-player.d.ts +0 -12
  593. package/dist/video-player/video-player2/modal-video-player.js +0 -12
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "mtxuilib",
3
3
  "private": false,
4
- "version": "0.1.182",
4
+ "version": "0.1.183",
5
5
  "publishConfig": {
6
6
  "access": "public"
7
7
  },
@@ -1,4 +0,0 @@
1
- import { UseFormReturn } from "react-hook-form";
2
- export declare const DebugFormState: (props: {
3
- form: UseFormReturn<any>;
4
- }) => null;
@@ -1,11 +0,0 @@
1
- "use client";
2
- import { useMemo } from "react";
3
- export const DebugFormState = (props) => {
4
- const { form } = props;
5
- useMemo(() => {
6
- if (form?.formState?.errors && Object.keys(form?.formState?.errors).length > 0) {
7
- console.warn("DebugFormState", form?.formState?.errors);
8
- }
9
- }, [form?.formState?.errors]);
10
- return null;
11
- };
@@ -1,22 +0,0 @@
1
- import { type PropsWithChildren } from "react";
2
- import { type StateCreator } from "zustand";
3
- type MtxFormProps = {
4
- open?: boolean;
5
- };
6
- type ConfirmCallbackFnType = () => void;
7
- export interface DeleteConformState extends MtxFormProps {
8
- setOpen: (open: boolean) => void;
9
- confirmCallback?: ConfirmCallbackFnType;
10
- setConfirmCallback: (confirmCallback: ConfirmCallbackFnType) => void;
11
- }
12
- export declare const createFormSlice: StateCreator<DeleteConformState, [
13
- ], [
14
- ], DeleteConformState>;
15
- export declare const DeleteConfirmProvider: (props: PropsWithChildren<MtxFormProps>) => import("react/jsx-runtime").JSX.Element;
16
- export declare const useDeleteConfirm: () => {
17
- show: (props: {
18
- callback: () => void;
19
- }) => void;
20
- };
21
- export declare const DeleteConfirmDlg: () => import("react/jsx-runtime").JSX.Element;
22
- export {};
@@ -1,52 +0,0 @@
1
- "use client";
2
- import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
3
- import { createContext, useCallback, useContext, useMemo, } from "react";
4
- import { createStore, useStore } from "zustand";
5
- import { immer } from "zustand/middleware/immer";
6
- import { MtButton } from "../ui/mt/Button";
7
- import { Dialog, DialogContent, DialogDescription, DialogTitle, } from "../ui/dialog";
8
- export const createFormSlice = (set, get) => ({
9
- setOpen: (open) => set({ open }),
10
- setConfirmCallback: (confirmCallback) => set({ confirmCallback }),
11
- });
12
- const createDeleteConformStore = (initProps) => {
13
- return createStore()(immer((...a) => ({
14
- ...createFormSlice(...a),
15
- ...initProps,
16
- })));
17
- };
18
- const formContext = createContext(null);
19
- export const DeleteConfirmProvider = (props) => {
20
- const { children, ...etc } = props;
21
- const mystore = useMemo(() => createDeleteConformStore(etc), [etc]);
22
- return (_jsxs(formContext.Provider, { value: mystore, children: [children, _jsx(DeleteConfirmDlg, {})] }));
23
- };
24
- function useDeleteConfirmStore(selector) {
25
- const store = useContext(formContext);
26
- if (!store)
27
- throw new Error("useDeleteConfirm Missing MtxFormProvider");
28
- return useStore(store, selector);
29
- }
30
- export const useDeleteConfirm = () => {
31
- const setOpen = useDeleteConfirmStore((x) => x.setOpen);
32
- const setConfirmCallback = useDeleteConfirmStore((x) => x.setConfirmCallback);
33
- const show = useCallback((props) => {
34
- setConfirmCallback(props.callback);
35
- setOpen(true);
36
- }, [setConfirmCallback, setOpen]);
37
- return {
38
- show,
39
- };
40
- };
41
- export const DeleteConfirmDlg = () => {
42
- const open = useDeleteConfirmStore((x) => x.open);
43
- const setOpen = useDeleteConfirmStore((x) => x.setOpen);
44
- const confirmCallback = useDeleteConfirmStore((x) => x.confirmCallback);
45
- return (_jsx(Dialog, { open: open, onOpenChange: setOpen, children: _jsxs(DialogContent, { children: [_jsx(DialogTitle, { children: "delete confirm" }), _jsx(DialogDescription, { children: "will delete item, continue?" }), _jsx(MtButton, { variant: "destructive", onClick: async () => {
46
- setOpen(false);
47
- confirmCallback && confirmCallback();
48
- }, children: "Continue" }), _jsx(MtButton, { variant: "outline", onClick: () => {
49
- setOpen(false);
50
- confirmCallback && confirmCallback();
51
- }, children: "Cancel" })] }) }));
52
- };
@@ -1,2 +0,0 @@
1
- import { PropsWithChildren } from "react";
2
- export declare const FullCenter: (props: PropsWithChildren) => import("react/jsx-runtime").JSX.Element;
@@ -1,6 +0,0 @@
1
- "use client";
2
- import { jsx as _jsx } from "react/jsx-runtime";
3
- export const FullCenter = (props) => {
4
- const { children } = props;
5
- return (_jsx("div", { className: "flex h-full w-full items-center justify-center", children: _jsx("div", { className: "flex-1", children: children }) }));
6
- };
@@ -1,11 +0,0 @@
1
- import { type PropsWithChildren } from "react";
2
- import { type StateCreator } from "zustand";
3
- type GlobalSearchProps = {};
4
- export interface GlobalSearchState extends GlobalSearchProps {
5
- q?: string;
6
- setQ?: (q: string) => void;
7
- }
8
- export declare const createFormSlice: StateCreator<GlobalSearchState, [], [], GlobalSearchState>;
9
- export declare const GlobalSearchProvider: (props: PropsWithChildren<GlobalSearchProps>) => import("react/jsx-runtime").JSX.Element;
10
- export declare function useGlobalSearch<T>(selector: (state: GlobalSearchState) => T): T;
11
- export {};
@@ -1,25 +0,0 @@
1
- "use client";
2
- import { jsx as _jsx } from "react/jsx-runtime";
3
- import { createContext, useContext, useMemo } from "react";
4
- import { createStore, useStore } from "zustand";
5
- export const createFormSlice = (set, get) => ({
6
- setQ: (q) => set({ q }),
7
- });
8
- const createDeleteConformStore = (initProps) => {
9
- return createStore()((...a) => ({
10
- ...createFormSlice(...a),
11
- ...initProps,
12
- }));
13
- };
14
- const formContext = createContext(null);
15
- export const GlobalSearchProvider = (props) => {
16
- const { children, ...etc } = props;
17
- const mystore = useMemo(() => createDeleteConformStore(etc), [etc]);
18
- return (_jsx(formContext.Provider, { value: mystore, children: children }));
19
- };
20
- export function useGlobalSearch(selector) {
21
- const store = useContext(formContext);
22
- if (!store)
23
- throw new Error("useGlobalSearch Missing GlobalSearchProvider");
24
- return useStore(store, selector);
25
- }
@@ -1 +0,0 @@
1
- export declare function HtmlChangesObserver({ children }: React.PropsWithChildren): import("react/jsx-runtime").JSX.Element;
@@ -1,53 +0,0 @@
1
- "use client";
2
- import { jsx as _jsx } from "react/jsx-runtime";
3
- import { HtmlDiffer } from "html-differ";
4
- import { useEffect, useRef } from "react";
5
- const styles = {
6
- none: "background: transparent; color:black",
7
- gray: "background: transparent; color: gray",
8
- bgGreen: "background: green; color:black",
9
- bgRed: "background: red; color:black",
10
- };
11
- export function HtmlChangesObserver({ children }) {
12
- const targetNode = useRef(null);
13
- useEffect(() => {
14
- const differ = new HtmlDiffer();
15
- let lastHtml = targetNode.current.innerHTML;
16
- function observeChanges() {
17
- const newHtml = targetNode.current.innerHTML;
18
- if (newHtml !== lastHtml) {
19
- const diff = differ.diffHtml(lastHtml, newHtml);
20
- lastHtml = newHtml;
21
- logDiff(diff);
22
- }
23
- if (running) {
24
- requestAnimationFrame(observeChanges);
25
- }
26
- }
27
- let running = true;
28
- requestAnimationFrame(observeChanges);
29
- return () => {
30
- running = false;
31
- };
32
- }, []);
33
- return _jsx("div", { ref: targetNode, children: children });
34
- }
35
- function logDiff(diff) {
36
- let output = "", styleArr = [];
37
- if (diff.length === 1 && !diff[0].added && !diff[0].removed)
38
- return output;
39
- for (const part of diff) {
40
- var index = diff.indexOf(part), partValue = part.value;
41
- if (part.added || part.removed) {
42
- output += index === 0 ? "\n" : "";
43
- output += "%c" + partValue;
44
- styleArr.push(part.added ? styles.bgGreen : styles.bgRed);
45
- }
46
- else {
47
- output += index !== 0 ? "" : "\n";
48
- output += "%c" + partValue;
49
- styleArr.push(styles.gray);
50
- }
51
- }
52
- console.log(performance.now() + "ms DOM changes: " + output, ...styleArr);
53
- }
@@ -1,5 +0,0 @@
1
- import Image from 'next/image';
2
- import { ComponentProps } from "react";
3
- type Props = ComponentProps<typeof Image>;
4
- export declare const MtImage: (props: Props) => import("react/jsx-runtime").JSX.Element;
5
- export {};
@@ -1,28 +0,0 @@
1
- import { jsx as _jsx } from "react/jsx-runtime";
2
- import { isCloudflarePage } from 'mtxlib/utils';
3
- import Image from 'next/image';
4
- const normalizeSrc = (src) => {
5
- return src.startsWith('/') ? src.slice(1) : src;
6
- };
7
- const cloudflareLoader = ({ src, width, quality }) => {
8
- const params = [`width=${width}`];
9
- if (quality) {
10
- params.push(`quality=${quality}`);
11
- }
12
- const paramsString = params.join(',');
13
- return `https://cfgomtm.yuepa8.com/cdn-cgi/image/${paramsString}/${normalizeSrc(src)}`;
14
- };
15
- const exampleImageLoader = ({ src, width, quality }) => {
16
- return `https://example.com/${src}?w=${width}&q=${quality || 75}`;
17
- };
18
- function getImageLoader() {
19
- if (isCloudflarePage()) {
20
- return cloudflareLoader;
21
- }
22
- else {
23
- exampleImageLoader;
24
- }
25
- }
26
- export const MtImage = (props) => {
27
- return _jsx(Image, { ...props, loader: getImageLoader() });
28
- };
@@ -1 +0,0 @@
1
- export declare const MtProgressBar: () => import("react/jsx-runtime").JSX.Element;
@@ -1,6 +0,0 @@
1
- "use client";
2
- import { jsx as _jsx } from "react/jsx-runtime";
3
- import { AppProgressBar } from "next-nprogress-bar";
4
- export const MtProgressBar = () => {
5
- return _jsx(AppProgressBar, { height: "4px", color: "#4934eb", options: { showSpinner: false }, shallowRouting: true });
6
- };
@@ -1 +0,0 @@
1
- export declare const NotFoundGoBack: () => import("react/jsx-runtime").JSX.Element;
@@ -1,10 +0,0 @@
1
- 'use client';
2
- import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
3
- import { useRouter } from "next/navigation";
4
- import { Button } from "../ui/button";
5
- export const NotFoundGoBack = () => {
6
- const router = useRouter();
7
- return (_jsxs("div", { className: "container flex flex-col", children: [_jsx("div", { className: "mx-auto p-8", children: "not found" }), _jsx(Button, { className: "mx-auto p-8", onClick: () => {
8
- router.back();
9
- }, children: "Go back" })] }));
10
- };
@@ -1,28 +0,0 @@
1
- import { z } from "zod";
2
- declare const slntTreeNodeBaseSchema: z.ZodObject<{
3
- id: z.ZodString;
4
- pid: z.ZodOptional<z.ZodString>;
5
- label: z.ZodOptional<z.ZodString>;
6
- icon: z.ZodOptional<z.ZodString>;
7
- routeName: z.ZodOptional<z.ZodString>;
8
- routeType: z.ZodOptional<z.ZodEnum<["default", "list", "detail"]>>;
9
- }, "strip", z.ZodTypeAny, {
10
- id: string;
11
- label?: string | undefined;
12
- icon?: string | undefined;
13
- pid?: string | undefined;
14
- routeName?: string | undefined;
15
- routeType?: "default" | "list" | "detail" | undefined;
16
- }, {
17
- id: string;
18
- label?: string | undefined;
19
- icon?: string | undefined;
20
- pid?: string | undefined;
21
- routeName?: string | undefined;
22
- routeType?: "default" | "list" | "detail" | undefined;
23
- }>;
24
- export type DashMenuTreeItem = z.infer<typeof slntTreeNodeBaseSchema> & {
25
- children?: DashMenuTreeItem[];
26
- };
27
- export declare const treeNodeSchema: z.ZodType<DashMenuTreeItem>;
28
- export {};
@@ -1,13 +0,0 @@
1
- import { z } from "zod";
2
- const DashMenuTreeItemRouteType = ["default", "list", "detail"];
3
- const slntTreeNodeBaseSchema = z.object({
4
- id: z.string(),
5
- pid: z.string().optional(),
6
- label: z.string().optional(),
7
- icon: z.string().optional(),
8
- routeName: z.string().optional(),
9
- routeType: z.enum(DashMenuTreeItemRouteType).optional(),
10
- });
11
- export const treeNodeSchema = slntTreeNodeBaseSchema.extend({
12
- children: z.lazy(() => treeNodeSchema.array()).optional(),
13
- });
@@ -1 +0,0 @@
1
- export declare const SlntChildrenTabs: () => import("react/jsx-runtime").JSX.Element;
@@ -1,26 +0,0 @@
1
- "use client";
2
- import { jsx as _jsx } from "react/jsx-runtime";
3
- import { urlJoinPaths } from "mtxlib/http/url";
4
- import { usePathname, useSelectedLayoutSegment, useSelectedLayoutSegments, } from "next/navigation";
5
- import { cn } from "../../lib/utils";
6
- import { MtLink } from "../mtlink";
7
- import { useMenuTreeStore } from "./SlntTreeNode";
8
- export const SlntChildrenTabs = () => {
9
- const parentData = useMenuTreeStore((x) => x.menuNode);
10
- const pathName = usePathname();
11
- const segments = useSelectedLayoutSegments();
12
- const segment = useSelectedLayoutSegment();
13
- const basePath = pathName.slice(0, -segments.join("/").length);
14
- const basePath3 = "/" + segments.join("/");
15
- return (_jsx("div", { className: "flex gap-1 ", children: parentData?.children?.map((item, i) => {
16
- let href = `${urlJoinPaths(basePath, item.routeName || "")}`;
17
- if (!segments?.length) {
18
- href = urlJoinPaths(pathName, item.routeName || "");
19
- }
20
- return (_jsx(TabItem, { activate: segment == item.routeName, children: _jsx(MtLink, { variant: "ghost", href: href, children: item.label }, i) }, i));
21
- }) }));
22
- };
23
- const TabItem = (props) => {
24
- const { activate, ...etc } = props;
25
- return (_jsx("div", { "data-state": activate && "active", className: cn("ring-offset-background focus-visible:ring-ring data-[state=active]:bg-background data-[state=active]:text-foreground inline-flex items-center justify-center whitespace-nowrap rounded-md px-3 py-1 text-sm font-medium transition-all focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-offset-2 disabled:pointer-events-none disabled:opacity-50 data-[state=active]:shadow"), ...etc }));
26
- };
@@ -1,19 +0,0 @@
1
- import { PropsWithChildren } from "react";
2
- import { DashMenuTreeItem } from "./Slnt.z";
3
- export type SLNTProps = {
4
- menuNode?: DashMenuTreeItem;
5
- };
6
- export interface SlntState extends SLNTProps {
7
- }
8
- export declare const slntContext: import("react").Context<(Omit<import("zustand").StoreApi<SlntState>, "setState"> & {
9
- setState(nextStateOrUpdater: SlntState | Partial<SlntState> | ((state: import("immer").WritableDraft<SlntState>) => void), shouldReplace?: boolean | undefined): void;
10
- }) | null>;
11
- type ModalProviderProps = React.PropsWithChildren<SLNTProps>;
12
- export declare const MenuTreeProvider: (props: ModalProviderProps) => import("react/jsx-runtime").JSX.Element;
13
- export declare const DEFAULT_USE_SHALLOW = true;
14
- export declare function useMenuTreeStore(): SlntState;
15
- export declare function useMenuTreeStore<T>(selector: (state: SlntState) => T): T;
16
- export declare const SlntTreeNode: (props: {
17
- treeData?: DashMenuTreeItem;
18
- } & PropsWithChildren) => import("react/jsx-runtime").JSX.Element;
19
- export {};
@@ -1,45 +0,0 @@
1
- "use client";
2
- import { jsx as _jsx } from "react/jsx-runtime";
3
- import { useSelectedLayoutSegment, useSelectedLayoutSegments, } from "next/navigation";
4
- import { createContext, useContext, useMemo } from "react";
5
- import { useStore } from "zustand";
6
- import { immer } from "zustand/middleware/immer";
7
- import { useShallow } from "zustand/react/shallow";
8
- import { createStore } from "zustand/vanilla";
9
- const createModalStore = (initProps) => {
10
- return createStore()(immer((set, get) => ({
11
- ...initProps,
12
- })));
13
- };
14
- export const slntContext = createContext(null);
15
- export const MenuTreeProvider = (props) => {
16
- const { children, ...etc } = props;
17
- const mystore = useMemo(() => createModalStore(etc), [etc]);
18
- return (_jsx(slntContext.Provider, { value: mystore, children: children }));
19
- };
20
- export const DEFAULT_USE_SHALLOW = true;
21
- export function useMenuTreeStore(selector) {
22
- const store = useContext(slntContext);
23
- if (!store)
24
- return null;
25
- if (selector) {
26
- return useStore(store, DEFAULT_USE_SHALLOW ? useShallow(selector) : selector);
27
- }
28
- return useStore(store);
29
- }
30
- export const SlntTreeNode = (props) => {
31
- const { children, treeData } = props;
32
- const parentData = useMenuTreeStore((x) => x?.menuNode);
33
- const segment = useSelectedLayoutSegment();
34
- const segments = useSelectedLayoutSegments();
35
- const parent = parentData || treeData;
36
- if (!parent) {
37
- throw new Error("must within parentNodes or rootNodes ");
38
- }
39
- const currNode = useMemo(() => {
40
- const fined = parent.children?.find((x) => x.routeName == segment);
41
- console.log({ message: `(SlntTreeNode)${segment}`, fined, parent });
42
- return fined;
43
- }, [parent, segment]);
44
- return (_jsx(MenuTreeProvider, { menuNode: currNode, children: children }));
45
- };
File without changes
@@ -1 +0,0 @@
1
- "use strict";
@@ -1,5 +0,0 @@
1
- export declare const DebugValue: (props: {
2
- title?: string;
3
- data: any;
4
- className?: string;
5
- }) => import("react/jsx-runtime").JSX.Element;
@@ -1,8 +0,0 @@
1
- "use client";
2
- import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
3
- import { Dialog, DialogContent, DialogTrigger } from "../../ui/dialog";
4
- import { MtButton } from "../../ui/mt/Button";
5
- export const DebugValue = (props) => {
6
- const { title, data, className } = props;
7
- return (_jsxs(Dialog, { children: [_jsx(DialogTrigger, { asChild: true, children: _jsx(MtButton, { variant: "outline", className: className, children: title || "debug" }) }), _jsx(DialogContent, { className: "max-h-lvh w-full overflow-scroll bg-red-100", children: _jsx("pre", { className: " text-xs", children: JSON.stringify(data, null, 2) }) })] }));
8
- };
@@ -1,2 +0,0 @@
1
- export declare const HOTKEY_Debug = "alt+.";
2
- export declare const DevTools: () => import("react/jsx-runtime").JSX.Element | null;
@@ -1,24 +0,0 @@
1
- "use client";
2
- import { jsx as _jsx, Fragment as _Fragment, jsxs as _jsxs } from "react/jsx-runtime";
3
- import dynamic from "next/dynamic";
4
- import { useHotkeys } from "react-hotkeys-hook";
5
- import { useMtapp } from "../../mtapp/MtAppProvider";
6
- import { TailwindIndicator } from "../tailwind-indicator";
7
- const ReactQueryDevtoolsProduction = dynamic(() => import("@tanstack/react-query-devtools/build/modern/production.js").then((d) => ({
8
- default: d.ReactQueryDevtools,
9
- })), {
10
- ssr: false,
11
- });
12
- export const HOTKEY_Debug = "alt+.";
13
- export const DevTools = () => {
14
- const debug = useMtapp((x) => x.debug);
15
- const setDebug = useMtapp((x) => x.setDebug);
16
- useHotkeys(HOTKEY_Debug, () => {
17
- console.log("debug2:%o", !debug);
18
- setDebug(!debug);
19
- }, [debug, setDebug]);
20
- if (!debug) {
21
- return null;
22
- }
23
- return (_jsxs(_Fragment, { children: [_jsx(ReactQueryDevtoolsProduction, { buttonPosition: "bottom-right" }), _jsx(TailwindIndicator, {})] }));
24
- };
@@ -1,3 +0,0 @@
1
- import { FC } from 'react';
2
- import { Options } from 'react-markdown';
3
- export declare const MemoizedReactMarkdown: FC<Options>;
@@ -1,4 +0,0 @@
1
- import { memo } from 'react';
2
- import ReactMarkdown from 'react-markdown';
3
- export const MemoizedReactMarkdown = memo(ReactMarkdown, (prevProps, nextProps) => prevProps.children === nextProps.children &&
4
- prevProps.className === nextProps.className);
@@ -1,14 +0,0 @@
1
- import { VariantProps } from "class-variance-authority";
2
- import Link from "next/link";
3
- import React, { ComponentProps } from "react";
4
- import { buttonVariants } from "../ui/button";
5
- export interface TMtLinkProps extends ComponentProps<typeof Link>, VariantProps<typeof buttonVariants> {
6
- asChild?: boolean;
7
- }
8
- export declare const MtLink: React.ForwardRefExoticComponent<Omit<TMtLinkProps, "ref"> & React.RefAttributes<HTMLAnchorElement>>;
9
- type ExternalLinkProps = ComponentProps<"a">;
10
- interface TExternalLink extends ExternalLinkProps {
11
- children?: React.ReactNode;
12
- }
13
- export declare function MtExternalLink({ children, className, ...props }: TExternalLink): import("react/jsx-runtime").JSX.Element;
14
- export {};
@@ -1,15 +0,0 @@
1
- 'use client';
2
- import { jsx as _jsx } from "react/jsx-runtime";
3
- import { Slot } from "@radix-ui/react-slot";
4
- import Link from "next/link";
5
- import React from "react";
6
- import { cn } from "../lib/utils";
7
- import { buttonVariants } from "../ui/button";
8
- export const MtLink = React.forwardRef(({ className, variant, size, asChild = false, ...props }, ref) => {
9
- const Comp = asChild ? Slot : Link;
10
- return (_jsx(Comp, { className: cn(((variant) && buttonVariants({ variant: variant, className }))), ref: ref, ...props }));
11
- });
12
- MtLink.displayName = "MtLink";
13
- export function MtExternalLink({ children, className, ...props }) {
14
- return (_jsx("a", { className: cn(className, "hover:text-brandtext-500 hover:underline hover:brightness-150"), rel: "noopener noreferrer", ...props, children: children }));
15
- }
@@ -1 +0,0 @@
1
- export default function PipExamplePage(): import("react/jsx-runtime").JSX.Element;
@@ -1,20 +0,0 @@
1
- "use client";
2
- import { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from "react/jsx-runtime";
3
- import ReactDocumentPictureInPicture from "mtxuilib/common/pip/ReactDocumentPictureInPicture";
4
- import { MtButton } from "mtxuilib/ui/mt/Button";
5
- import { useRef, useState } from "react";
6
- export default function PipExamplePage() {
7
- const pipWindowRef = useRef(null);
8
- return (_jsx(_Fragment, { children: _jsx(ReactDocumentPictureInPicture, { ref: pipWindowRef, width: "50%", height: "100%", buttonRenderer: ({ open, close, toggle, isOpen }) => (_jsxs("div", { className: "flex gap-2", children: [_jsxs("b", { children: ["Is ", isOpen ? "Open" : "Closed", " "] }), _jsx(MtButton, { onClick: open, children: "Open" }), _jsx(MtButton, { onClick: close, children: "Close" }), _jsx(MtButton, { onClick: toggle, children: "Toggle" })] })), children: _jsx(Comp, { pipWindowRef: pipWindowRef }) }) }));
9
- }
10
- const Comp = (props) => {
11
- const { pipWindowRef } = props;
12
- const [text, setText] = useState("tet1");
13
- return (_jsxs("div", { className: "prose", children: [_jsx("h1", { children: "\u753B\u4E2D\u753B\u663E\u793A\uFF08\u8303\u4F8B\uFF09" }), _jsxs("div", { children: [_jsx("button", { onClick: () => {
14
- console.log("关闭");
15
- setText("ssssssssssssssss");
16
- }, children: "sssss" }), _jsxs(MtButton, { onClick: () => {
17
- console.log("关闭");
18
- setText("ssssssssssssssss");
19
- }, children: ["\u5173\u95ED333 ", text] })] }), _jsx("i", { children: "This text should be displayed in a Document Picture in Picture filling the maximum allow height and 50% of the width of the original window" })] }));
20
- };
@@ -1,28 +0,0 @@
1
- import { ReactNode } from "react";
2
- export type ReactDocumentPictureInPictureForwardRefType = {
3
- window: () => Window | undefined;
4
- isOpen: boolean;
5
- close: () => void;
6
- };
7
- export declare enum FeatureUnavailableReasonEnum {
8
- USING_UNSECURE_PROTOCOL = "USING_UNSECURE_PROTOCOL",
9
- API_NOT_SUPPORTED = "API_NOT_SUPPORTED"
10
- }
11
- export type ReactDocumentPictureInPicturePropsType = {
12
- width?: string | number;
13
- height?: string | number;
14
- shareStyles?: boolean;
15
- onOpen?: () => void;
16
- onClose?: () => void;
17
- onResize?: (width: number, height: number) => void;
18
- featureUnavailableRenderer?: ReactNode | ((reason: FeatureUnavailableReasonEnum) => ReactNode);
19
- buttonRenderer?: ReactNode | ((props: {
20
- open: () => void;
21
- close: () => void;
22
- toggle: () => void;
23
- isOpen: boolean;
24
- }) => ReactNode);
25
- children?: ReactNode;
26
- };
27
- declare const ReactDocumentPictureInPicture: import("react").ForwardRefExoticComponent<ReactDocumentPictureInPicturePropsType & import("react").RefAttributes<ReactDocumentPictureInPictureForwardRefType>>;
28
- export default ReactDocumentPictureInPicture;