@tachybase/client 1.3.20 → 1.3.22

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 (326) hide show
  1. package/es/api-client/APIClient.d.ts +1 -1
  2. package/es/api-client/APIClient.mjs +1 -1
  3. package/es/api-client/hooks/assign.mjs +1 -1
  4. package/es/api-client/hooks/useResource.d.ts +1 -1
  5. package/es/application/Application.d.ts +1 -2
  6. package/es/application/Application.mjs +2 -11
  7. package/es/application/WebSocketClient.mjs +1 -1
  8. package/es/application/components/index.d.ts +0 -2
  9. package/es/application/components/index.mjs +0 -2
  10. package/es/application/schema-initializer/context/index.d.ts +1 -1
  11. package/es/application/utils/globalDeps.d.ts +1 -1
  12. package/es/application/utils/globalDeps.mjs +4 -12
  13. package/es/application/utils/remotePlugins.d.ts +1 -1
  14. package/es/block-provider/FormFieldProvider.mjs +1 -1
  15. package/es/block-provider/hooks/index.mjs +2 -2
  16. package/es/block-provider/hooks/useParsedFilter.mjs +1 -1
  17. package/es/built-in/acl/Configuration/RolesResourcesActions.mjs +1 -1
  18. package/es/built-in/context-menu/ContextMenuItemsProps.mjs +1 -1
  19. package/es/built-in/index.d.ts +2 -1
  20. package/es/built-in/index.mjs +4 -3
  21. package/es/built-in/page-style/useTabSettings.mjs +3 -3
  22. package/es/built-in/pm/PluginManager.mjs +1 -1
  23. package/es/built-in/quick-access/ModalActionSchemaInitializerItem.mjs +1 -1
  24. package/es/collection-manager/Configuration/AddCollectionAction.mjs +1 -1
  25. package/es/collection-manager/Configuration/AddFieldAction.mjs +1 -1
  26. package/es/collection-manager/Configuration/AddSubFieldAction.mjs +1 -1
  27. package/es/collection-manager/Configuration/EditCollectionAction.mjs +1 -1
  28. package/es/collection-manager/Configuration/EditFieldAction.mjs +1 -1
  29. package/es/collection-manager/Configuration/EditSubFieldAction.mjs +1 -1
  30. package/es/collection-manager/Configuration/ImportXlsx/xlsxImportAction.mjs +1 -1
  31. package/es/collection-manager/Configuration/OverridingCollectionField.mjs +1 -1
  32. package/es/collection-manager/Configuration/SyncFieldsAction.mjs +1 -1
  33. package/es/collection-manager/Configuration/SyncSQLFieldsAction.mjs +1 -1
  34. package/es/collection-manager/Configuration/ViewInheritedField.mjs +1 -1
  35. package/es/collection-manager/collectionPlugin.mjs +36 -0
  36. package/es/collection-manager/hooks/useCollection_deprecated.d.ts +1 -1
  37. package/es/collection-manager/interfaces/json.mjs +1 -1
  38. package/es/collection-manager/interfaces/radioGroup.d.ts +11 -11
  39. package/es/collection-manager/interfaces/url.d.ts +4 -0
  40. package/es/collection-manager/interfaces/url.mjs +10 -1
  41. package/es/collection-manager/templates/expression.mjs +1 -1
  42. package/es/collection-manager/templates/properties/index.d.ts +1 -1
  43. package/es/collection-manager/templates/sql.d.ts +3 -3
  44. package/es/collection-manager/templates/view.d.ts +3 -3
  45. package/es/data-source/collection-field-interface/CollectionFieldInterface.mjs +1 -15
  46. package/es/data-source/data-block/DataBlockResourceProvider.d.ts +1 -1
  47. package/es/filter-provider/utils.mjs +1 -1
  48. package/es/modules/actions/link/customizeLinkActionSettings.mjs +1 -1
  49. package/es/modules/blocks/data-blocks/details-multi/detailsWithPaginationSettings.mjs +1 -1
  50. package/es/modules/blocks/data-blocks/form/FormBlockInitializer.d.ts +11 -11
  51. package/es/modules/blocks/data-blocks/form/fieldSettingsFormItem.mjs +2 -5
  52. package/es/modules/blocks/data-blocks/grid-card/gridCardBlockSettings.mjs +1 -1
  53. package/es/modules/blocks/data-blocks/list/listBlockSettings.mjs +1 -1
  54. package/es/modules/blocks/data-blocks/table/hooks/useTableBlockProps.mjs +14 -2
  55. package/es/modules/blocks/data-blocks/table/tableBlockSettings.mjs +1 -1
  56. package/es/modules/blocks/data-blocks/table/tableColumnSettings.mjs +1 -3
  57. package/es/modules/blocks/data-blocks/table-selector/tableSelectorBlockSettings.mjs +1 -1
  58. package/es/modules/blocks/filter-blocks/collapse/filterCollapseItemFieldSettings.mjs +0 -4
  59. package/es/modules/blocks/filter-blocks/form/filterFormItemFieldSettings.mjs +1 -5
  60. package/es/modules/blocks/filter-blocks/tree/filterTreeItemFieldSettings.mjs +1 -1
  61. package/es/modules/fields/component/Cascader/cascaderComponentFieldSettings.mjs +1 -1
  62. package/es/modules/fields/component/CustomTitle/customTitleComponentFieldSettings.mjs +95 -5
  63. package/es/modules/fields/component/InputPreview/inputPreviewComponentFieldSettings.d.ts +2 -0
  64. package/es/modules/fields/component/InputPreview/inputPreviewComponentFieldSettings.mjs +99 -0
  65. package/es/modules/fields/component/MultipleSelect/multipleSelectComponentFieldSettings.d.ts +2 -0
  66. package/es/modules/fields/component/MultipleSelect/multipleSelectComponentFieldSettings.mjs +64 -0
  67. package/es/modules/fields/component/Radio/radioComponentFieldSettings.mjs +15 -2
  68. package/es/modules/fields/component/Select/selectComponentFieldSettings.mjs +26 -7
  69. package/es/modules/fields/component/SubTable/subTablePopoverComponentFieldSettings.d.ts +1 -1
  70. package/es/modules/fields/component/SubTable/subTablePopoverComponentFieldSettings.mjs +1 -1
  71. package/es/modules/menu/GroupItem.mjs +1 -1
  72. package/es/modules/menu/LinkMenuItem.mjs +1 -1
  73. package/es/modules/menu/PageMenuItem.mjs +1 -1
  74. package/es/modules/menu/UploadMenuItem.mjs +1 -1
  75. package/es/schema-component/antd/action/Action.Designer.mjs +1 -1
  76. package/es/schema-component/antd/action/Action.mjs +1 -1
  77. package/es/schema-component/antd/association-field/InternalCascadeSelect.mjs +1 -1
  78. package/es/schema-component/antd/association-field/InternalCascader.mjs +1 -2
  79. package/es/schema-component/antd/association-field/InternalNester.mjs +1 -1
  80. package/es/schema-component/antd/association-field/InternalSubTable.mjs +1 -1
  81. package/es/schema-component/antd/association-field/InternalViewer.mjs +4 -58
  82. package/es/schema-component/antd/association-field/SubTabs/InternalCollapse.mjs +1 -1
  83. package/es/schema-component/antd/association-field/SubTabs/hook.mjs +1 -1
  84. package/es/schema-component/antd/association-field/hooks.d.ts +4 -0
  85. package/es/schema-component/antd/association-field/hooks.mjs +53 -2
  86. package/es/schema-component/antd/association-field/util.mjs +1 -1
  87. package/es/schema-component/antd/association-select/AssociationSelect.mjs +2 -2
  88. package/es/schema-component/antd/auto-complete/AutoComplete.mjs +1 -1
  89. package/es/schema-component/antd/color-picker/ColorPicker.mjs +1 -1
  90. package/es/schema-component/antd/color-picker/util.d.ts +1 -1
  91. package/es/schema-component/antd/color-picker/util.mjs +1 -1
  92. package/es/schema-component/antd/cron/Cron.mjs +1 -1
  93. package/es/schema-component/antd/date-picker/ReadPretty.mjs +1 -1
  94. package/es/schema-component/antd/date-picker/util.d.ts +1 -1
  95. package/es/schema-component/antd/date-picker/util.mjs +1 -1
  96. package/es/schema-component/antd/filter/FilterAction.mjs +1 -1
  97. package/es/schema-component/antd/form/Form.mjs +1 -1
  98. package/es/schema-component/antd/form-item/FormItem.Settings.mjs +1 -1
  99. package/es/schema-component/antd/form-item/FormItem.mjs +1 -1
  100. package/es/schema-component/antd/form-item/SchemaSettingOptions.mjs +1 -1
  101. package/es/schema-component/antd/form-item/hooks/useLazyLoadDisplayAssociationFieldsOfForm.mjs +1 -1
  102. package/es/schema-component/antd/form-item/hooks/useParseDefaultValue.mjs +1 -1
  103. package/es/schema-component/antd/form-v2/Form.Settings.mjs +1 -1
  104. package/es/schema-component/antd/form-v2/Form.mjs +1 -2
  105. package/es/schema-component/antd/form-v2/Templates.mjs +1 -1
  106. package/es/schema-component/antd/form-v2/utils.mjs +1 -2
  107. package/es/schema-component/antd/grid-card/GridCard.Decorator.mjs +1 -1
  108. package/es/schema-component/antd/grid-card/GridCard.Designer.mjs +1 -1
  109. package/es/schema-component/antd/icon-picker/IconPicker.mjs +1 -1
  110. package/es/schema-component/antd/index.d.ts +0 -1
  111. package/es/schema-component/antd/index.mjs +1 -2
  112. package/es/schema-component/antd/input/Input.mjs +2 -1
  113. package/es/schema-component/antd/input/ReadPretty.d.ts +1 -0
  114. package/es/schema-component/antd/input/ReadPretty.mjs +30 -2
  115. package/es/schema-component/antd/input-number/ReadPretty.mjs +1 -1
  116. package/es/schema-component/antd/list/List.Decorator.mjs +1 -1
  117. package/es/schema-component/antd/list/List.Designer.mjs +1 -1
  118. package/es/schema-component/antd/menu/Menu.Designer.mjs +1 -1
  119. package/es/schema-component/antd/menu/Menu.mjs +1 -1
  120. package/es/schema-component/antd/page/Page.Settings.mjs +0 -33
  121. package/es/schema-component/antd/page/Page.mjs +47 -96
  122. package/es/schema-component/antd/page/hooks/index.d.ts +1 -1
  123. package/es/schema-component/antd/page/hooks/index.mjs +1 -1
  124. package/es/schema-component/antd/page/index.d.ts +1 -0
  125. package/es/schema-component/antd/page/index.mjs +1 -0
  126. package/es/schema-component/antd/page/pageExtendComponentProvider.d.ts +3 -0
  127. package/es/schema-component/antd/page/pageExtendComponentProvider.mjs +9 -0
  128. package/es/schema-component/antd/page/style.d.ts +0 -5
  129. package/es/schema-component/antd/page/style.mjs +1 -45
  130. package/es/schema-component/antd/preview/Preview.mjs +1 -1
  131. package/es/schema-component/antd/quick-edit/QuickEdit.mjs +1 -1
  132. package/es/schema-component/antd/record-picker/util.mjs +1 -1
  133. package/es/schema-component/antd/select/FormulaSelect.mjs +17 -5
  134. package/es/schema-component/antd/select/ReadPretty.mjs +16 -3
  135. package/es/schema-component/antd/select/Select.mjs +7 -2
  136. package/es/schema-component/antd/select/utils.mjs +2 -2
  137. package/es/schema-component/antd/space/index.mjs +1 -1
  138. package/es/schema-component/antd/table/Table.Void.Designer.mjs +1 -1
  139. package/es/schema-component/antd/table-v2/Table.mjs +1 -1
  140. package/es/schema-component/antd/table-v2/TableBlockDesigner.mjs +1 -1
  141. package/es/schema-component/antd/table-v2/TableSelectorDesigner.mjs +1 -1
  142. package/es/schema-component/antd/time-picker/ReadPretty.mjs +1 -1
  143. package/es/schema-component/antd/time-picker/TimePicker.mjs +1 -1
  144. package/es/schema-component/antd/tree-select/ReadPretty.mjs +1 -1
  145. package/es/schema-component/antd/upload/ReadPretty.mjs +1 -2
  146. package/es/schema-component/antd/upload/Upload.mjs +1 -1
  147. package/es/schema-component/antd/variable/CodeMirror.mjs +1 -1
  148. package/es/schema-component/antd/variable/Input.mjs +1 -1
  149. package/es/schema-component/antd/variable/TextArea.mjs +1 -1
  150. package/es/schema-component/common/infinite-scroll/infinite-scroll.mjs +1 -1
  151. package/es/schema-component/hooks/useFieldModeOptions.mjs +13 -10
  152. package/es/schema-initializer/items/CustomFilterFormItemInitializer.mjs +2 -2
  153. package/es/schema-settings/DataTemplates/components/AsDefaultTemplate.mjs +1 -1
  154. package/es/schema-settings/DataTemplates/components/DataTemplateTitle.mjs +1 -1
  155. package/es/schema-settings/DataTemplates/components/Designer.mjs +1 -1
  156. package/es/schema-settings/DataTemplates/utils.mjs +1 -1
  157. package/es/schema-settings/EditFormulaTitleField.mjs +19 -1
  158. package/es/schema-settings/LinkageRules/LinkageRuleAction.mjs +1 -1
  159. package/es/schema-settings/LinkageRules/components/EnableLinkage.mjs +1 -1
  160. package/es/schema-settings/LinkageRules/components/LinkageHeader.mjs +1 -1
  161. package/es/schema-settings/SchemaSettings.mjs +2 -3
  162. package/es/schema-settings/SchemaSettingsDefaultValue.mjs +1 -1
  163. package/es/schema-settings/SchemaSettingsPlugin.mjs +4 -0
  164. package/es/schema-settings/SchemaSettingsSortingRule.mjs +1 -1
  165. package/es/schema-settings/VariableInput/hooks/useContextAssociationFields.mjs +1 -1
  166. package/es/schema-settings/filter-form/FormFilterScope.mjs +1 -1
  167. package/es/schema-settings/hooks/useParseDataScopeFilter.mjs +1 -1
  168. package/es/user/ChangePassword.mjs +2 -2
  169. package/es/user/CurrentUser.mjs +1 -1
  170. package/es/user/CurrentUserSettingsMenuProvider.mjs +1 -1
  171. package/es/variables/VariablesProvider.mjs +2 -2
  172. package/es/variables/hooks/useBuiltinVariables.mjs +1 -1
  173. package/lib/api-client/APIClient.js +2 -2
  174. package/lib/api-client/hooks/assign.js +1 -1
  175. package/lib/application/Application.js +6 -15
  176. package/lib/application/WebSocketClient.js +2 -2
  177. package/lib/application/components/index.js +0 -18
  178. package/lib/application/utils/globalDeps.js +3 -11
  179. package/lib/block-provider/FormFieldProvider.js +1 -1
  180. package/lib/block-provider/hooks/index.js +14 -14
  181. package/lib/block-provider/hooks/useParsedFilter.js +1 -1
  182. package/lib/built-in/acl/Configuration/RolesResourcesActions.js +4 -4
  183. package/lib/built-in/context-menu/ContextMenuItemsProps.js +1 -1
  184. package/lib/built-in/index.js +42 -16
  185. package/lib/built-in/page-style/useTabSettings.js +3 -3
  186. package/lib/built-in/pm/PluginManager.js +1 -1
  187. package/lib/built-in/quick-access/ModalActionSchemaInitializerItem.js +1 -1
  188. package/lib/collection-manager/Configuration/AddCollectionAction.js +2 -2
  189. package/lib/collection-manager/Configuration/AddFieldAction.js +2 -2
  190. package/lib/collection-manager/Configuration/AddSubFieldAction.js +2 -2
  191. package/lib/collection-manager/Configuration/EditCollectionAction.js +2 -2
  192. package/lib/collection-manager/Configuration/EditFieldAction.js +2 -2
  193. package/lib/collection-manager/Configuration/EditSubFieldAction.js +2 -2
  194. package/lib/collection-manager/Configuration/ImportXlsx/xlsxImportAction.js +2 -2
  195. package/lib/collection-manager/Configuration/OverridingCollectionField.js +2 -2
  196. package/lib/collection-manager/Configuration/SyncFieldsAction.js +2 -2
  197. package/lib/collection-manager/Configuration/SyncSQLFieldsAction.js +2 -2
  198. package/lib/collection-manager/Configuration/ViewInheritedField.js +2 -2
  199. package/lib/collection-manager/collectionPlugin.js +36 -0
  200. package/lib/collection-manager/interfaces/json.js +3 -3
  201. package/lib/collection-manager/interfaces/url.js +10 -1
  202. package/lib/collection-manager/templates/expression.js +1 -1
  203. package/lib/data-source/collection-field-interface/CollectionFieldInterface.js +1 -15
  204. package/lib/filter-provider/utils.js +1 -1
  205. package/lib/locale/zh-CN.js +1 -0
  206. package/lib/modules/actions/link/customizeLinkActionSettings.js +2 -2
  207. package/lib/modules/blocks/data-blocks/details-multi/detailsWithPaginationSettings.js +2 -2
  208. package/lib/modules/blocks/data-blocks/form/fieldSettingsFormItem.js +3 -6
  209. package/lib/modules/blocks/data-blocks/grid-card/gridCardBlockSettings.js +2 -2
  210. package/lib/modules/blocks/data-blocks/list/listBlockSettings.js +2 -2
  211. package/lib/modules/blocks/data-blocks/table/hooks/useTableBlockProps.js +14 -2
  212. package/lib/modules/blocks/data-blocks/table/tableBlockSettings.js +2 -2
  213. package/lib/modules/blocks/data-blocks/table/tableColumnSettings.js +1 -3
  214. package/lib/modules/blocks/data-blocks/table-selector/tableSelectorBlockSettings.js +2 -2
  215. package/lib/modules/blocks/filter-blocks/collapse/filterCollapseItemFieldSettings.js +0 -4
  216. package/lib/modules/blocks/filter-blocks/form/filterFormItemFieldSettings.js +3 -7
  217. package/lib/modules/blocks/filter-blocks/tree/filterTreeItemFieldSettings.js +3 -3
  218. package/lib/modules/fields/component/Cascader/cascaderComponentFieldSettings.js +2 -2
  219. package/lib/modules/fields/component/CustomTitle/customTitleComponentFieldSettings.js +93 -3
  220. package/lib/modules/fields/component/InputPreview/inputPreviewComponentFieldSettings.js +133 -0
  221. package/lib/modules/fields/component/MultipleSelect/multipleSelectComponentFieldSettings.js +98 -0
  222. package/lib/modules/fields/component/Radio/radioComponentFieldSettings.js +16 -3
  223. package/lib/modules/fields/component/Select/selectComponentFieldSettings.js +23 -4
  224. package/lib/modules/fields/component/SubTable/subTablePopoverComponentFieldSettings.js +3 -3
  225. package/lib/modules/menu/GroupItem.js +2 -2
  226. package/lib/modules/menu/LinkMenuItem.js +2 -2
  227. package/lib/modules/menu/PageMenuItem.js +2 -2
  228. package/lib/modules/menu/UploadMenuItem.js +2 -2
  229. package/lib/schema-component/antd/action/Action.Designer.js +3 -3
  230. package/lib/schema-component/antd/action/Action.js +1 -1
  231. package/lib/schema-component/antd/association-field/InternalCascadeSelect.js +4 -4
  232. package/lib/schema-component/antd/association-field/InternalCascader.js +4 -5
  233. package/lib/schema-component/antd/association-field/InternalNester.js +2 -2
  234. package/lib/schema-component/antd/association-field/InternalSubTable.js +2 -2
  235. package/lib/schema-component/antd/association-field/InternalViewer.js +1 -55
  236. package/lib/schema-component/antd/association-field/SubTabs/InternalCollapse.js +1 -1
  237. package/lib/schema-component/antd/association-field/SubTabs/hook.js +1 -1
  238. package/lib/schema-component/antd/association-field/hooks.js +55 -1
  239. package/lib/schema-component/antd/association-field/util.js +1 -1
  240. package/lib/schema-component/antd/association-select/AssociationSelect.js +12 -12
  241. package/lib/schema-component/antd/auto-complete/AutoComplete.js +1 -1
  242. package/lib/schema-component/antd/color-picker/ColorPicker.js +2 -2
  243. package/lib/schema-component/antd/color-picker/util.js +1 -1
  244. package/lib/schema-component/antd/cron/Cron.js +1 -1
  245. package/lib/schema-component/antd/date-picker/ReadPretty.js +1 -1
  246. package/lib/schema-component/antd/date-picker/util.js +1 -1
  247. package/lib/schema-component/antd/filter/FilterAction.js +1 -1
  248. package/lib/schema-component/antd/form/Form.js +3 -3
  249. package/lib/schema-component/antd/form-item/FormItem.Settings.js +3 -3
  250. package/lib/schema-component/antd/form-item/FormItem.js +2 -2
  251. package/lib/schema-component/antd/form-item/SchemaSettingOptions.js +5 -5
  252. package/lib/schema-component/antd/form-item/hooks/useLazyLoadDisplayAssociationFieldsOfForm.js +1 -1
  253. package/lib/schema-component/antd/form-item/hooks/useParseDefaultValue.js +1 -1
  254. package/lib/schema-component/antd/form-v2/Form.Settings.js +2 -2
  255. package/lib/schema-component/antd/form-v2/Form.js +3 -4
  256. package/lib/schema-component/antd/form-v2/Templates.js +1 -1
  257. package/lib/schema-component/antd/form-v2/utils.js +2 -3
  258. package/lib/schema-component/antd/grid-card/GridCard.Decorator.js +2 -2
  259. package/lib/schema-component/antd/grid-card/GridCard.Designer.js +2 -2
  260. package/lib/schema-component/antd/icon-picker/IconPicker.js +2 -2
  261. package/lib/schema-component/antd/index.js +120 -187
  262. package/lib/schema-component/antd/input/Input.js +2 -1
  263. package/lib/schema-component/antd/input/ReadPretty.js +34 -6
  264. package/lib/schema-component/antd/input-number/ReadPretty.js +1 -1
  265. package/lib/schema-component/antd/list/List.Decorator.js +2 -2
  266. package/lib/schema-component/antd/list/List.Designer.js +2 -2
  267. package/lib/schema-component/antd/menu/Menu.Designer.js +2 -2
  268. package/lib/schema-component/antd/menu/Menu.js +1 -1
  269. package/lib/schema-component/antd/page/Page.Settings.js +0 -33
  270. package/lib/schema-component/antd/page/Page.js +43 -92
  271. package/lib/schema-component/antd/page/hooks/index.js +5 -5
  272. package/lib/schema-component/antd/page/index.js +9 -0
  273. package/lib/{application/components/ShareSchemaComponent.js → schema-component/antd/page/pageExtendComponentProvider.js} +15 -10
  274. package/lib/schema-component/antd/page/style.js +2 -49
  275. package/lib/schema-component/antd/preview/Preview.js +2 -2
  276. package/lib/schema-component/antd/quick-edit/QuickEdit.js +3 -3
  277. package/lib/schema-component/antd/record-picker/util.js +1 -1
  278. package/lib/schema-component/antd/select/FormulaSelect.js +17 -5
  279. package/lib/schema-component/antd/select/ReadPretty.js +15 -2
  280. package/lib/schema-component/antd/select/Select.js +7 -2
  281. package/lib/schema-component/antd/select/utils.js +2 -2
  282. package/lib/schema-component/antd/space/index.js +2 -2
  283. package/lib/schema-component/antd/table/Table.Void.Designer.js +2 -2
  284. package/lib/schema-component/antd/table-v2/Table.js +1 -1
  285. package/lib/schema-component/antd/table-v2/TableBlockDesigner.js +2 -2
  286. package/lib/schema-component/antd/table-v2/TableSelectorDesigner.js +2 -2
  287. package/lib/schema-component/antd/time-picker/ReadPretty.js +2 -2
  288. package/lib/schema-component/antd/time-picker/TimePicker.js +3 -3
  289. package/lib/schema-component/antd/tree-select/ReadPretty.js +2 -2
  290. package/lib/schema-component/antd/upload/ReadPretty.js +2 -3
  291. package/lib/schema-component/antd/upload/Upload.js +2 -2
  292. package/lib/schema-component/antd/variable/CodeMirror.js +2 -2
  293. package/lib/schema-component/antd/variable/Input.js +1 -1
  294. package/lib/schema-component/antd/variable/TextArea.js +1 -1
  295. package/lib/schema-component/common/infinite-scroll/infinite-scroll.js +1 -1
  296. package/lib/schema-component/hooks/useFieldModeOptions.js +13 -10
  297. package/lib/schema-initializer/items/CustomFilterFormItemInitializer.js +4 -4
  298. package/lib/schema-settings/DataTemplates/components/AsDefaultTemplate.js +3 -3
  299. package/lib/schema-settings/DataTemplates/components/DataTemplateTitle.js +10 -10
  300. package/lib/schema-settings/DataTemplates/components/Designer.js +1 -1
  301. package/lib/schema-settings/DataTemplates/utils.js +4 -4
  302. package/lib/schema-settings/EditFormulaTitleField.js +19 -1
  303. package/lib/schema-settings/LinkageRules/LinkageRuleAction.js +2 -2
  304. package/lib/schema-settings/LinkageRules/components/EnableLinkage.js +3 -3
  305. package/lib/schema-settings/LinkageRules/components/LinkageHeader.js +10 -10
  306. package/lib/schema-settings/SchemaSettings.js +17 -18
  307. package/lib/schema-settings/SchemaSettingsDefaultValue.js +3 -3
  308. package/lib/schema-settings/SchemaSettingsPlugin.js +4 -0
  309. package/lib/schema-settings/SchemaSettingsSortingRule.js +2 -2
  310. package/lib/schema-settings/VariableInput/hooks/useContextAssociationFields.js +1 -1
  311. package/lib/schema-settings/filter-form/FormFilterScope.js +2 -2
  312. package/lib/schema-settings/hooks/useParseDataScopeFilter.js +1 -1
  313. package/lib/user/ChangePassword.js +2 -2
  314. package/lib/user/CurrentUser.js +1 -1
  315. package/lib/user/CurrentUserSettingsMenuProvider.js +1 -1
  316. package/lib/variables/VariablesProvider.js +2 -2
  317. package/lib/variables/hooks/useBuiltinVariables.js +1 -1
  318. package/package.json +9 -23
  319. package/es/application/components/SharePage.d.ts +0 -4
  320. package/es/application/components/SharePage.mjs +0 -113
  321. package/es/application/components/ShareSchemaComponent.d.ts +0 -1
  322. package/es/application/components/ShareSchemaComponent.mjs +0 -10
  323. package/es/schema-component/antd/page/hooks/useShareActions.d.ts +0 -7
  324. package/es/schema-component/antd/page/hooks/useShareActions.mjs +0 -242
  325. package/lib/application/components/SharePage.js +0 -156
  326. package/lib/schema-component/antd/page/hooks/useShareActions.js +0 -286
@@ -61,4 +61,3 @@ export * from './variable';
61
61
  export * from './media-card';
62
62
  export * from './tracking-link';
63
63
  export { PageHeader } from '@ant-design/pro-layout';
64
- export { CodeMirror } from '@tachybase/components';
@@ -1,7 +1,6 @@
1
1
  import "./index.css";
2
2
  import { genStyleHook } from "./__builtins__/index.mjs";
3
3
  import { PageHeader } from "@ant-design/pro-layout";
4
- import { CodeMirror } from "@tachybase/components";
5
4
  export * from "./AntdSchemaComponentProvider.mjs";
6
5
  export * from "./action/index.mjs";
7
6
  export * from "./appends-tree-select/index.mjs";
@@ -62,4 +61,4 @@ export * from "./upload/index.mjs";
62
61
  export * from "./variable/index.mjs";
63
62
  export * from "./media-card/index.mjs";
64
63
  export * from "./tracking-link/index.mjs";
65
- export { CodeMirror, PageHeader, genStyleHook };
64
+ export { PageHeader, genStyleHook };
@@ -20,7 +20,8 @@ const Input_Input = Object.assign(connect(Input, mapProps((props, field)=>({
20
20
  })), mapReadPretty(ReadPretty.TextArea)),
21
21
  URL: connect(Input, mapReadPretty(ReadPretty.URL)),
22
22
  JSON: connect(Json, mapReadPretty(ReadPretty.JSON)),
23
- ReadPretty: ReadPretty.Input
23
+ ReadPretty: ReadPretty.Input,
24
+ Preview: ReadPretty.Preview
24
25
  });
25
26
  const input_Input = Input_Input;
26
27
  export { Input_Input as Input, ReadPretty as InputReadPretty, input_Input as default };
@@ -18,4 +18,5 @@ export declare const ReadPretty: {
18
18
  ellipsis: boolean;
19
19
  }) => import("react/jsx-runtime").JSX.Element;
20
20
  JSON: (props: any) => import("react/jsx-runtime").JSX.Element;
21
+ Preview: (props: any) => any;
21
22
  };
@@ -1,8 +1,9 @@
1
1
  import { jsx, jsxs } from "react/jsx-runtime";
2
2
  import "react";
3
- import { usePrefixCls } from "@tachybase/components";
3
+ import { useFieldSchema } from "@tachybase/schema";
4
4
  import { css } from "@emotion/css";
5
- import { Typography } from "antd";
5
+ import { usePrefixCls } from "@tego/client";
6
+ import { Image, Typography } from "antd";
6
7
  import classnames from "classnames";
7
8
  import { useCompile } from "../../index.mjs";
8
9
  import { EllipsisWithTooltip } from "./EllipsisWithTooltip.mjs";
@@ -151,9 +152,36 @@ const _JSON = (props)=>{
151
152
  children: null != props.value ? JSON.stringify(props.value, null, null != (_props_space = props.space) ? _props_space : 2) : ''
152
153
  });
153
154
  };
155
+ const sizes = {
156
+ small: 24,
157
+ middle: 48,
158
+ large: 72,
159
+ oversized: 120
160
+ };
161
+ const _Preview = (props)=>{
162
+ var _fieldSchema_xcomponentprops, _fieldSchema_xcomponentprops1;
163
+ const fieldSchema = useFieldSchema();
164
+ const size = (null == (_fieldSchema_xcomponentprops = fieldSchema['x-component-props']) ? void 0 : _fieldSchema_xcomponentprops['size']) || 'small';
165
+ const objectFit = (null == (_fieldSchema_xcomponentprops1 = fieldSchema['x-component-props']) ? void 0 : _fieldSchema_xcomponentprops1['objectFit']) || 'cover';
166
+ if (!props.value) return props.value;
167
+ return /*#__PURE__*/ jsx(Image, {
168
+ style: [
169
+ 'small',
170
+ 'middle',
171
+ 'large',
172
+ 'oversized'
173
+ ].includes(size) ? {
174
+ width: sizes[size],
175
+ height: sizes[size],
176
+ objectFit
177
+ } : {},
178
+ src: props.value
179
+ });
180
+ };
154
181
  ReadPretty.Input = _Input;
155
182
  ReadPretty.TextArea = _TextArea;
156
183
  ReadPretty.URL = _URL;
157
184
  ReadPretty.Html = _Html;
158
185
  ReadPretty.JSON = _JSON;
186
+ ReadPretty.Preview = _Preview;
159
187
  export { ReadPretty };
@@ -1,7 +1,7 @@
1
1
  import { jsx, jsxs } from "react/jsx-runtime";
2
2
  import { useMemo } from "react";
3
3
  import { isValid } from "@tachybase/schema";
4
- import { toFixedByStep } from "@tachybase/utils/client";
4
+ import { toFixedByStep } from "@tego/client";
5
5
  import { format as external_d3_format_format } from "d3-format";
6
6
  import { round } from "mathjs";
7
7
  function countDecimalPlaces(value) {
@@ -1,7 +1,7 @@
1
1
  import { jsx } from "react/jsx-runtime";
2
2
  import { createContext, useContext, useEffect, useMemo } from "react";
3
- import { FormLayout } from "@tachybase/components";
4
3
  import { FormContext, createForm, useField } from "@tachybase/schema";
4
+ import { FormLayout } from "@tego/client";
5
5
  import { createStyles } from "antd-style";
6
6
  import lodash from "lodash";
7
7
  import { withDynamicSchemaProps } from "../../../application/hoc/withDynamicSchemaProps.mjs";
@@ -1,7 +1,7 @@
1
1
  import { jsx, jsxs } from "react/jsx-runtime";
2
2
  import "react";
3
- import { ArrayItems } from "@tachybase/components";
4
3
  import { useField, useFieldSchema } from "@tachybase/schema";
4
+ import { ArrayItems } from "@tego/client";
5
5
  import lodash from "lodash";
6
6
  import { useTranslation } from "react-i18next";
7
7
  import { useFormBlockContext } from "../../../block-provider/index.mjs";
@@ -1,6 +1,6 @@
1
1
  import { jsx, jsxs } from "react/jsx-runtime";
2
- import { TreeSelect } from "@tachybase/components";
3
2
  import { onFieldChange, useField, useFieldSchema } from "@tachybase/schema";
3
+ import { TreeSelect } from "@tego/client";
4
4
  import { App } from "antd";
5
5
  import { saveAs } from "file-saver";
6
6
  import { useTranslation } from "react-i18next";
@@ -1,8 +1,8 @@
1
1
  import { jsx, jsxs } from "react/jsx-runtime";
2
2
  import { createContext, useContext, useEffect, useMemo, useRef, useState } from "react";
3
3
  import { FieldContext, RecursionField, SchemaContext, SchemaExpressionScopeContext, observer, uid, useField, useFieldSchema } from "@tachybase/schema";
4
- import { error } from "@tachybase/utils/client";
5
4
  import { PointerSensor, useSensor, useSensors } from "@dnd-kit/core";
5
+ import { error } from "@tego/client";
6
6
  import { Button, Menu, Popover } from "antd";
7
7
  import { createPortal } from "react-dom";
8
8
  import { DndContext, SortableItem, createDesignable, useDesignable, useDesigner } from "../../index.mjs";
@@ -1,6 +1,5 @@
1
1
  import { useField, useFieldSchema } from "@tachybase/schema";
2
2
  import { useTranslation } from "react-i18next";
3
- import { useMatch } from "react-router";
4
3
  import { useDesignable } from "../../index.mjs";
5
4
  import { SchemaSettings } from "../../../application/schema-settings/index.mjs";
6
5
  import { useSchemaToolbar } from "../../../application/schema-toolbar/index.mjs";
@@ -37,38 +36,6 @@ const pageSettings = new SchemaSettings({
37
36
  };
38
37
  }
39
38
  },
40
- {
41
- name: 'enablesharePage',
42
- type: 'switch',
43
- useVisible () {
44
- const isShare = useMatch('/share/:name');
45
- return !isShare;
46
- },
47
- useComponentProps () {
48
- var _fieldSchema_xcomponentprops;
49
- const { dn } = useDesignable();
50
- const { t } = useTranslation();
51
- const fieldSchema = useFieldSchema();
52
- const { title } = useSchemaToolbar();
53
- return {
54
- title: t('Enable Share page'),
55
- checked: null == (_fieldSchema_xcomponentprops = fieldSchema['x-component-props']) ? void 0 : _fieldSchema_xcomponentprops.enableSharePage,
56
- onChange (v) {
57
- fieldSchema['x-component-props'] = fieldSchema['x-component-props'] || {};
58
- fieldSchema['x-component-props']['enableSharePage'] = v;
59
- if (!fieldSchema.title) fieldSchema.title = title;
60
- dn.emit('patch', {
61
- schema: {
62
- ['x-uid']: fieldSchema['x-uid'],
63
- ['x-component-props']: fieldSchema['x-component-props'],
64
- title: fieldSchema.title
65
- }
66
- });
67
- dn.refresh();
68
- }
69
- };
70
- }
71
- },
72
39
  {
73
40
  name: 'divider',
74
41
  type: 'divider',
@@ -1,17 +1,17 @@
1
1
  import { Fragment, jsx, jsxs } from "react/jsx-runtime";
2
2
  import { useContext, useEffect, useMemo, useState } from "react";
3
- import { FormLayout } from "@tachybase/components";
4
3
  import { Schema, SchemaOptionsContext, useFieldSchema } from "@tachybase/schema";
5
- import { PlusOutlined, ShareAltOutlined } from "@ant-design/icons";
4
+ import { PlusOutlined } from "@ant-design/icons";
6
5
  import { PageHeader } from "@ant-design/pro-layout";
7
6
  import { PointerSensor, useSensor, useSensors } from "@dnd-kit/core";
8
- import { Button, Modal, Tabs } from "antd";
7
+ import { FormLayout } from "@tego/client";
8
+ import { Button, Tabs } from "antd";
9
9
  import { cx } from "antd-style";
10
10
  import classnames from "classnames";
11
11
  import { ErrorBoundary } from "react-error-boundary";
12
12
  import { useTranslation } from "react-i18next";
13
- import { useMatch, useSearchParams } from "react-router-dom";
14
- import { FormDialog, ScrollArea } from "../index.mjs";
13
+ import { useSearchParams } from "react-router-dom";
14
+ import { FormDialog, PageExtendComponentProvider, ScrollArea } from "../index.mjs";
15
15
  import { useToken } from "../__builtins__/index.mjs";
16
16
  import { useStyles } from "../../../built-in/acl/style.mjs";
17
17
  import { useContextMenu } from "../../../built-in/context-menu/useContextMenu.mjs";
@@ -27,11 +27,10 @@ import { SchemaComponent, SchemaComponentOptions } from "../../core/index.mjs";
27
27
  import { useCompile, useDesignable } from "../../hooks/index.mjs";
28
28
  import { ErrorFallback } from "../error-fallback/index.mjs";
29
29
  import FixedBlock from "./FixedBlock.mjs";
30
- import { useShareActions } from "./hooks/useShareActions.mjs";
31
30
  import { useStyles as external_Page_style_mjs_useStyles } from "./Page.style.mjs";
32
31
  import { PageDesigner } from "./PageDesigner.mjs";
33
32
  import { PageTabDesigner } from "./PageTabDesigner.mjs";
34
- import { getStyles, useStyles as external_style_mjs_useStyles } from "./style.mjs";
33
+ import { getStyles } from "./style.mjs";
35
34
  const Page = (props)=>{
36
35
  var _fieldSchema_xcomponentprops, _fieldSchema_xcomponentprops1, _fieldSchema_xcomponentprops2;
37
36
  const { children, ...others } = props;
@@ -89,29 +88,21 @@ const Page = (props)=>{
89
88
  }));
90
89
  };
91
90
  const Page_PageHeader = (props)=>{
92
- var _fieldSchema_xcomponentprops;
91
+ var _fieldSchema_xcomponentprops, _Object_values, _Object_values1;
93
92
  const { disablePageHeader, enablePageTabs, setHeight, activeKey, setLoading, setSearchParams, fieldSchema, title, parentProps, enableSharePage } = props;
94
93
  const { theme } = useGlobalTheme();
95
94
  const options = useContext(SchemaOptionsContext);
96
95
  const compile = useCompile();
97
- const [open, setOpen] = useState(false);
98
- const [imageOpen, setImageOpen] = useState(false);
99
96
  const { showScrollArea } = useContextMenu();
100
97
  const hidePageTitle = null == (_fieldSchema_xcomponentprops = fieldSchema['x-component-props']) ? void 0 : _fieldSchema_xcomponentprops.hidePageTitle;
98
+ const extendComponents = fieldSchema['x-extend-components'] || {};
101
99
  const pageHeaderTitle = hidePageTitle ? void 0 : fieldSchema.title || compile(title);
102
- const isShare = useMatch('/share/:name');
103
100
  const items = fieldSchema.mapProperties((schema)=>({
104
101
  key: schema.name,
105
102
  label: /*#__PURE__*/ jsx(TabItem, {
106
103
  schema: schema
107
104
  })
108
105
  }));
109
- const { t } = useTranslation();
110
- const { styles } = external_style_mjs_useStyles();
111
- const { copyLink, imageAction } = useShareActions({
112
- title: pageHeaderTitle,
113
- uid: ''
114
- });
115
106
  return /*#__PURE__*/ jsxs("div", {
116
107
  ref: (ref)=>{
117
108
  setHeight(Math.floor((null == ref ? void 0 : ref.getBoundingClientRect().height) || 0) + 1);
@@ -123,12 +114,29 @@ const Page_PageHeader = (props)=>{
123
114
  ghost: false,
124
115
  title: pageHeaderTitle || ' ',
125
116
  ...parentProps,
126
- extra: /*#__PURE__*/ jsx(HeaderExtra, {
127
- enablePageTabs: enablePageTabs,
128
- showScrollArea: showScrollArea,
129
- isShare: isShare,
130
- setOpen: setOpen,
131
- enableSharePage: enableSharePage
117
+ extra: /*#__PURE__*/ jsxs(Fragment, {
118
+ children: [
119
+ null == (_Object_values = Object.values(extendComponents)) ? void 0 : _Object_values.map((item, index)=>{
120
+ const schema = {
121
+ type: 'void',
122
+ name: item.name,
123
+ 'x-component': item.component,
124
+ 'x-component-props': {}
125
+ };
126
+ const componentProps = {
127
+ ...props,
128
+ isExtra: true,
129
+ fieldSchema
130
+ };
131
+ return /*#__PURE__*/ jsx(PageExtendComponentProvider, {
132
+ ...componentProps,
133
+ children: /*#__PURE__*/ jsx(SchemaComponent, {
134
+ schema: schema
135
+ })
136
+ });
137
+ }),
138
+ !enablePageTabs && showScrollArea && /*#__PURE__*/ jsx(ScrollArea, {})
139
+ ]
132
140
  }),
133
141
  footer: enablePageTabs && /*#__PURE__*/ jsx(TabComponent, {
134
142
  activeKey: activeKey,
@@ -140,84 +148,27 @@ const Page_PageHeader = (props)=>{
140
148
  items: items
141
149
  })
142
150
  }),
143
- disablePageHeader && enableSharePage && !isShare && /*#__PURE__*/ jsx("div", {
144
- className: "tb-page-header-button",
145
- children: /*#__PURE__*/ jsx(Button, {
146
- icon: /*#__PURE__*/ jsx(ShareAltOutlined, {}),
147
- onClick: ()=>{
148
- setOpen(true);
149
- },
150
- children: t('Share')
151
- })
152
- }),
153
- /*#__PURE__*/ jsxs(Modal, {
154
- open: open,
155
- className: styles.firstmodal,
156
- title: t('Share'),
157
- footer: null,
158
- width: 500,
159
- onCancel: ()=>{
160
- setOpen(false);
161
- },
162
- children: [
163
- /*#__PURE__*/ jsxs("div", {
164
- className: styles.secondmodal,
165
- children: [
166
- /*#__PURE__*/ jsxs("div", {
167
- className: "tb-header-modal-list",
168
- onClick: copyLink,
169
- children: [
170
- /*#__PURE__*/ jsx(Icon, {
171
- type: "PaperClipOutlined"
172
- }),
173
- t('Copy link')
174
- ]
175
- }),
176
- /*#__PURE__*/ jsxs("div", {
177
- className: "tb-header-modal-list",
178
- onClick: ()=>{
179
- setImageOpen(true);
180
- },
181
- children: [
182
- /*#__PURE__*/ jsx(Icon, {
183
- type: "QrcodeOutlined"
184
- }),
185
- t('Generate QR code')
186
- ]
187
- })
188
- ]
189
- }),
190
- /*#__PURE__*/ jsx(Modal, {
191
- className: styles.imageModal,
192
- open: imageOpen,
193
- footer: null,
194
- onCancel: ()=>{
195
- setImageOpen(false);
196
- },
197
- children: imageAction()
151
+ null == (_Object_values1 = Object.values(extendComponents)) ? void 0 : _Object_values1.map((item, index)=>{
152
+ const schema = {
153
+ type: 'void',
154
+ name: 'icon' + item.name,
155
+ 'x-component': item.component,
156
+ 'x-component-props': {}
157
+ };
158
+ const componentProps = {
159
+ ...props,
160
+ fieldSchema
161
+ };
162
+ return /*#__PURE__*/ jsx(PageExtendComponentProvider, {
163
+ ...componentProps,
164
+ children: /*#__PURE__*/ jsx(SchemaComponent, {
165
+ schema: schema
198
166
  })
199
- ]
167
+ });
200
168
  })
201
169
  ]
202
170
  });
203
171
  };
204
- const HeaderExtra = (param)=>{
205
- let { enablePageTabs, showScrollArea, isShare, setOpen, enableSharePage } = param;
206
- return /*#__PURE__*/ jsxs(Fragment, {
207
- children: [
208
- !isShare && /*#__PURE__*/ jsx(Button, {
209
- icon: /*#__PURE__*/ jsx(ShareAltOutlined, {}),
210
- onClick: ()=>{
211
- setOpen(true);
212
- },
213
- style: {
214
- visibility: "".concat(enableSharePage ? 'visible' : 'hidden')
215
- }
216
- }),
217
- !enablePageTabs && showScrollArea && /*#__PURE__*/ jsx(ScrollArea, {})
218
- ]
219
- });
220
- };
221
172
  const TabComponent = (props)=>{
222
173
  const { activeKey, setLoading, setSearchParams, showScrollArea, options, theme, items } = props;
223
174
  const { styles } = external_Page_style_mjs_useStyles();
@@ -1 +1 @@
1
- export * from './useShareActions';
1
+ export * from './useIsBlockInPage';
@@ -1 +1 @@
1
- export * from "./useShareActions.mjs";
1
+ export * from "./useIsBlockInPage.mjs";
@@ -4,3 +4,4 @@ export * from './PageTab.Settings';
4
4
  export * from './Page.Settings';
5
5
  export * from './FixedBlockDesignerItem';
6
6
  export * from './hooks';
7
+ export * from './pageExtendComponentProvider';
@@ -4,3 +4,4 @@ export * from "./PageTab.Settings.mjs";
4
4
  export * from "./Page.Settings.mjs";
5
5
  export * from "./FixedBlockDesignerItem.mjs";
6
6
  export * from "./hooks/index.mjs";
7
+ export * from "./pageExtendComponentProvider.mjs";
@@ -0,0 +1,3 @@
1
+ export declare const PageExtendComponentContext: import("react").Context<{}>;
2
+ export declare const PageExtendComponentProvider: (props: any) => import("react/jsx-runtime").JSX.Element;
3
+ export declare const usePageExtendComponentContext: () => {};
@@ -0,0 +1,9 @@
1
+ import { jsx } from "react/jsx-runtime";
2
+ import { createContext, useContext } from "react";
3
+ const PageExtendComponentContext = /*#__PURE__*/ createContext({});
4
+ const PageExtendComponentProvider = (props)=>/*#__PURE__*/ jsx(PageExtendComponentContext.Provider, {
5
+ value: props,
6
+ children: props.children
7
+ });
8
+ const usePageExtendComponentContext = ()=>useContext(PageExtendComponentContext);
9
+ export { PageExtendComponentContext, PageExtendComponentProvider, usePageExtendComponentContext };
@@ -1,6 +1 @@
1
1
  export declare const getStyles: (props?: any) => import("./../__builtins__").UseComponentStyleResult;
2
- export declare const useStyles: (props?: unknown) => import("antd-style").ReturnStyles<{
3
- firstmodal: import("antd-style").SerializedStyles;
4
- secondmodal: import("antd-style").SerializedStyles;
5
- imageModal: import("antd-style").SerializedStyles;
6
- }>;
@@ -1,40 +1,4 @@
1
- import { createStyles } from "antd-style";
2
1
  import { genStyleHook } from "../__builtins__/index.mjs";
3
- function _tagged_template_literal(strings, raw) {
4
- if (!raw) raw = strings.slice(0);
5
- return Object.freeze(Object.defineProperties(strings, {
6
- raw: {
7
- value: Object.freeze(raw)
8
- }
9
- }));
10
- }
11
- function _templateObject() {
12
- const data = _tagged_template_literal([
13
- "\n .ant-modal-content {\n position: relative;\n overflow: hidden;\n border-radius: 16px;\n &::before,\n &::after {\n content: '';\n position: absolute;\n width: 300px;\n height: 300px;\n background: radial-gradient(circle, rgba(0, 149, 255, 0.11) 0%, transparent 70%);\n z-index: 0;\n pointer-events: none;\n }\n\n &::before {\n top: -165px;\n left: -10px;\n }\n\n &::after {\n bottom: -160px;\n right: -150px;\n }\n .ant-modal-header {\n text-align: center;\n margin-bottom: 20px;\n margin-top: 15px;\n .ant-modal-title {\n font-size: x-large;\n font-weight: 400;\n }\n }\n .ant-modal-body {\n justify-items: center;\n }\n }\n "
14
- ]);
15
- _templateObject = function() {
16
- return data;
17
- };
18
- return data;
19
- }
20
- function _templateObject1() {
21
- const data = _tagged_template_literal([
22
- "\n display: flex;\n justify-content: center;\n align-items: center;\n width: 100%;\n margin-top: 20px;\n margin-bottom: 40px;\n position: relative;\n gap: 20%;\n padding-left: 10%;\n padding-right: 10%;\n .tb-header-modal-list {\n width: 50%;\n gap: 10px;\n display: flex;\n flex-direction: column;\n justify-content: center;\n text-align: center;\n border: 1px solid transparent;\n border-color: rgba(203, 227, 254, 0.62);\n box-shadow: none;\n border-radius: 12px;\n padding: 16px;\n transition:\n box-shadow 0.2s ease,\n transform 0.2s ease;\n z-index: 1;\n position: relative;\n &:hover {\n border-color: rgba(0, 120, 255, 0.3);\n box-shadow: 0 4px 16px rgba(0, 120, 255, 0.15);\n }\n &:active {\n box-shadow: none;\n transform: translateY(2px);\n }\n .anticon {\n width: 100%;\n display: flex;\n justify-content: center;\n svg {\n width: 30px;\n height: 30px;\n }\n }\n .tb-header-modal-list-text {\n text-align: center;\n }\n }\n "
23
- ]);
24
- _templateObject1 = function() {
25
- return data;
26
- };
27
- return data;
28
- }
29
- function _templateObject2() {
30
- const data = _tagged_template_literal([
31
- "\n display: flex;\n justify-content: center;\n .ant-modal-content {\n width: 280px;\n height: 360px;\n }\n "
32
- ]);
33
- _templateObject2 = function() {
34
- return data;
35
- };
36
- return data;
37
- }
38
2
  const getStyles = genStyleHook('tb-page', (token)=>{
39
3
  const { componentCls } = token;
40
4
  return {
@@ -179,12 +143,4 @@ const getStyles = genStyleHook('tb-page', (token)=>{
179
143
  }
180
144
  };
181
145
  });
182
- const useStyles = createStyles((param)=>{
183
- let { css, token } = param;
184
- return {
185
- firstmodal: css(_templateObject()),
186
- secondmodal: css(_templateObject1()),
187
- imageModal: css(_templateObject2())
188
- };
189
- });
190
- export { getStyles, useStyles };
146
+ export { getStyles };
@@ -1,8 +1,8 @@
1
1
  import { Fragment, jsx, jsxs } from "react/jsx-runtime";
2
2
  import { useEffect, useRef, useState } from "react";
3
- import { Lightbox } from "@tachybase/components";
4
3
  import { connect, mapReadPretty } from "@tachybase/schema";
5
4
  import { DeleteOutlined, DownloadOutlined, PlusOutlined } from "@ant-design/icons";
5
+ import { Lightbox } from "@tego/client";
6
6
  import { Button, Progress, Space, Upload } from "antd";
7
7
  import classnames from "classnames";
8
8
  import { saveAs } from "file-saver";
@@ -1,7 +1,7 @@
1
1
  import { jsx } from "react/jsx-runtime";
2
2
  import react, { useMemo, useRef } from "react";
3
- import { FormItem } from "@tachybase/components";
4
3
  import { FormContext, RecursionField, createForm, observer, useField, useFieldSchema } from "@tachybase/schema";
4
+ import { FormItem } from "@tego/client";
5
5
  import { createStyles } from "antd-style";
6
6
  import { useCollectionManager_deprecated } from "../../../collection-manager/index.mjs";
7
7
  import { StablePopover } from "../popover/index.mjs";
@@ -1,6 +1,6 @@
1
1
  import react from "react";
2
2
  import { isArr } from "@tachybase/schema";
3
- import { getDefaultFormat, str2moment } from "@tachybase/utils/client";
3
+ import { getDefaultFormat, str2moment } from "@tego/client";
4
4
  import { Tag } from "antd";
5
5
  import { useCollectionManager_deprecated } from "../../../collection-manager/index.mjs";
6
6
  const useLabelUiSchema = (collectionField, label)=>{
@@ -1,8 +1,8 @@
1
1
  import { jsx } from "react/jsx-runtime";
2
2
  import { useEffect, useMemo, useState } from "react";
3
3
  import { isValid, toArr, useFieldSchema, useForm } from "@tachybase/schema";
4
- import { isPlainObject } from "@tachybase/utils/client";
5
4
  import { CloseCircleFilled, CloseOutlined } from "@ant-design/icons";
5
+ import { isPlainObject } from "@tego/client";
6
6
  import { Empty, Select, Spin, Tag } from "antd";
7
7
  import { useAPIClient, useRequest } from "../../../api-client/index.mjs";
8
8
  import { useCollection_deprecated } from "../../../collection-manager/index.mjs";
@@ -103,6 +103,7 @@ const useLabelOptions = (others)=>{
103
103
  const collectionField = useMemo(()=>getField(fieldSchema['x-collection-field']), [
104
104
  fieldSchema['x-collection-field']
105
105
  ]);
106
+ if (!(null == collectionField ? void 0 : collectionField.target) && !fieldSchema['collectionName']) return others;
106
107
  const request = {
107
108
  resource: (null == collectionField ? void 0 : collectionField.target) || fieldSchema['collectionName'],
108
109
  action: 'list',
@@ -151,16 +152,18 @@ const useLabelOptions = (others)=>{
151
152
  }
152
153
  return others;
153
154
  };
154
- const FormulaSelect_FormulaSelect = (props)=>{
155
+ const FormulaSelect = (props)=>{
155
156
  const { objectValue, loading, value, rawOptions, defaultValue, ...others } = props;
156
157
  let mode = props.multiple ? 'multiple' : props.mode;
157
158
  const filterField = null == others ? void 0 : others['params'];
158
159
  const [options, setOptions] = useState([]);
159
160
  const [collectionName, setCollectionName] = useState('');
161
+ const fieldSchema = useFieldSchema();
160
162
  const api = useAPIClient();
161
163
  if (mode && ![
162
164
  'multiple',
163
- 'tags'
165
+ 'tags',
166
+ 'CustomTitle'
164
167
  ].includes(mode)) mode = void 0;
165
168
  const fieldProps = {
166
169
  ...others
@@ -182,6 +185,7 @@ const FormulaSelect_FormulaSelect = (props)=>{
182
185
  } else if ((null == others ? void 0 : others.collection) === collectionName) fieldProps['options'] = options.map((option)=>({
183
186
  ...option
184
187
  }));
188
+ else fieldProps['options'] = getFormulaValue(props.fieldNames['formula'], (null == props ? void 0 : props.options) || [], fieldSchema);
185
189
  const modifiedProps = useLabelOptions(fieldProps);
186
190
  return /*#__PURE__*/ jsx(ObjectSelect, {
187
191
  rawOptions: rawOptions,
@@ -192,5 +196,13 @@ const FormulaSelect_FormulaSelect = (props)=>{
192
196
  loading: loading
193
197
  });
194
198
  };
195
- const FormulaSelect = FormulaSelect_FormulaSelect;
196
- export { FormulaSelect as default };
199
+ const select_FormulaSelect = FormulaSelect;
200
+ const getFormulaValue = (template, options, fieldSchema)=>options.map((item)=>{
201
+ const label = item.label;
202
+ const customLabel = template.replace(new RegExp("{{".concat(fieldSchema['name'], "}}"), 'g'), label);
203
+ return {
204
+ ...item,
205
+ label: customLabel
206
+ };
207
+ });
208
+ export { select_FormulaSelect as default };
@@ -1,12 +1,12 @@
1
1
  import { jsx } from "react/jsx-runtime";
2
2
  import "react";
3
- import { isArrayField, isValid, observer, useField } from "@tachybase/schema";
3
+ import { isArrayField, isValid, observer, useField, useFieldSchema } from "@tachybase/schema";
4
4
  import { Tag } from "antd";
5
5
  import { useCollectionField } from "../../../data-source/collection-field/CollectionFieldProvider.mjs";
6
6
  import { EllipsisWithTooltip } from "../input/EllipsisWithTooltip.mjs";
7
7
  import { defaultFieldNames, getCurrentOptions } from "./utils.mjs";
8
8
  const ReadPretty = observer((props)=>{
9
- var _field_value;
9
+ var _field_value, _fieldSchema_xcomponentprops_fieldNames, _fieldSchema_xcomponentprops;
10
10
  const fieldNames = {
11
11
  ...defaultFieldNames,
12
12
  ...props.fieldNames
@@ -15,8 +15,10 @@ const ReadPretty = observer((props)=>{
15
15
  if (!isValid(props.value)) return /*#__PURE__*/ jsx("div", {});
16
16
  if (isArrayField(field) && (null == field ? void 0 : null == (_field_value = field.value) ? void 0 : _field_value.length) === 0) return /*#__PURE__*/ jsx("div", {});
17
17
  const collectionField = useCollectionField();
18
+ const fieldSchema = useFieldSchema();
18
19
  const dataSource = field.dataSource || props.options || (null == collectionField ? void 0 : collectionField.uiSchema.enum) || [];
19
- const currentOptions = getCurrentOptions(field.value, dataSource, fieldNames);
20
+ const options = getCurrentOptions(field.value, dataSource, fieldNames);
21
+ const currentOptions = getFormulaValue(null == (_fieldSchema_xcomponentprops = fieldSchema['x-component-props']) ? void 0 : null == (_fieldSchema_xcomponentprops_fieldNames = _fieldSchema_xcomponentprops.fieldNames) ? void 0 : _fieldSchema_xcomponentprops_fieldNames['formula'], options, fieldSchema);
20
22
  return /*#__PURE__*/ jsx("div", {
21
23
  children: /*#__PURE__*/ jsx(EllipsisWithTooltip, {
22
24
  ellipsis: props.ellipsis,
@@ -30,4 +32,15 @@ const ReadPretty = observer((props)=>{
30
32
  }, {
31
33
  displayName: 'ReadPretty'
32
34
  });
35
+ const getFormulaValue = (template, options, fieldSchema)=>{
36
+ if (!template) return options;
37
+ return options.map((item)=>{
38
+ const label = item.label;
39
+ const customLabel = template.replace(new RegExp("{{".concat(fieldSchema['name'], "}}"), 'g'), label);
40
+ return {
41
+ ...item,
42
+ label: customLabel
43
+ };
44
+ });
45
+ };
33
46
  export { ReadPretty };