@tachybase/client 0.23.48 → 1.0.6

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 (215) hide show
  1. package/es/api-client/APIClient.d.ts +5 -2
  2. package/es/api-client/APIClient.mjs +93 -49
  3. package/es/api-client/hooks/useRequest.d.ts +2 -0
  4. package/es/application/Application.d.ts +6 -0
  5. package/es/application/Application.mjs +19 -0
  6. package/es/application/CustomRouterContextProvider.d.ts +54 -0
  7. package/es/application/CustomRouterContextProvider.mjs +209 -0
  8. package/es/application/RouterManager.d.ts +8 -3
  9. package/es/application/RouterManager.mjs +48 -15
  10. package/es/application/hooks/index.d.ts +1 -0
  11. package/es/application/hooks/index.mjs +1 -0
  12. package/es/application/hooks/useGlobalVariable.d.ts +1 -0
  13. package/es/application/hooks/useGlobalVariable.mjs +18 -0
  14. package/es/application/schema-initializer/context/index.d.ts +1 -1
  15. package/es/application/schema-settings/hooks/index.d.ts +1 -1
  16. package/es/application/schema-settings/hooks/index.mjs +6 -8
  17. package/es/block-provider/hooks/index.d.ts +2 -0
  18. package/es/block-provider/hooks/index.mjs +29 -22
  19. package/es/built-in/context-menu/ContextMenu.provider.mjs +6 -6
  20. package/es/built-in/context-menu/ContextMenuItemsProps.d.ts +4 -4
  21. package/es/built-in/context-menu/ContextMenuItemsProps.mjs +6 -6
  22. package/es/built-in/context-menu/index.mjs +1 -1
  23. package/es/built-in/context-menu/useContextMenu.d.ts +2 -2
  24. package/es/built-in/index.mjs +8 -0
  25. package/es/built-in/locale/LocalePlugin.mjs +5 -1
  26. package/es/built-in/page-style/PageStyle.provider.mjs +2 -2
  27. package/es/built-in/system-settings/SystemSettingsProvider.d.ts +2 -3
  28. package/es/built-in/system-settings/SystemSettingsProvider.mjs +4 -3
  29. package/es/built-in/system-settings/SystemSettingsShortcut.mjs +11 -8
  30. package/es/collection-manager/Configuration/AddCollectionAction.mjs +12 -2
  31. package/es/collection-manager/Configuration/ImportXlsx/ImportXlsxMetaAction.d.ts +2 -0
  32. package/es/collection-manager/Configuration/ImportXlsx/ImportXlsxMetaAction.mjs +255 -0
  33. package/es/collection-manager/Configuration/ImportXlsx/XlsxCollectionSchema.d.ts +89 -0
  34. package/es/collection-manager/Configuration/ImportXlsx/XlsxCollectionSchema.mjs +96 -0
  35. package/es/collection-manager/Configuration/ImportXlsx/XlsxEditFieldAction.d.ts +3 -0
  36. package/es/collection-manager/Configuration/ImportXlsx/XlsxEditFieldAction.mjs +47 -0
  37. package/es/collection-manager/Configuration/ImportXlsx/setUpdateXlsxCollectionField.d.ts +3 -0
  38. package/es/collection-manager/Configuration/ImportXlsx/setUpdateXlsxCollectionField.mjs +44 -0
  39. package/es/collection-manager/Configuration/ImportXlsx/xlsxFieldsConfigure.d.ts +1 -0
  40. package/es/collection-manager/Configuration/ImportXlsx/xlsxFieldsConfigure.mjs +380 -0
  41. package/es/collection-manager/Configuration/ImportXlsx/xlsxFormValueContextProvider.d.ts +8 -0
  42. package/es/collection-manager/Configuration/ImportXlsx/xlsxFormValueContextProvider.mjs +4 -0
  43. package/es/collection-manager/Configuration/ImportXlsx/xlsxImportAction.d.ts +1 -0
  44. package/es/collection-manager/Configuration/ImportXlsx/xlsxImportAction.mjs +187 -0
  45. package/es/collection-manager/Configuration/ImportXlsx/xlsxPreviewTable.d.ts +1 -0
  46. package/es/collection-manager/Configuration/ImportXlsx/xlsxPreviewTable.mjs +30 -0
  47. package/es/collection-manager/collectionPlugin.mjs +3 -1
  48. package/es/collection-manager/templates/import.mjs +1 -1
  49. package/es/collection-manager/templates/sql.d.ts +1 -1
  50. package/es/collection-manager/templates/view.d.ts +1 -1
  51. package/es/collection-manager/templates/xlsx.d.ts +11 -0
  52. package/es/collection-manager/templates/xlsx.mjs +19 -0
  53. package/es/data-source/collection-field-interface/CollectionFieldInterface.d.ts +1 -0
  54. package/es/data-source/collection-field-interface/CollectionFieldInterface.mjs +18 -0
  55. package/es/data-source/collection-field-interface/CollectionFieldInterfaceManager.d.ts +8 -1
  56. package/es/data-source/collection-field-interface/CollectionFieldInterfaceManager.mjs +20 -0
  57. package/es/data-source/commonsSettingsItem/fieldComponent.mjs +3 -1
  58. package/es/data-source/data-source/DataSource.d.ts +1 -1
  59. package/es/filter-provider/utils.mjs +6 -0
  60. package/es/i18n/i18n.mjs +7 -12
  61. package/es/modules/actions/delete/deleteActionSettings.mjs +10 -0
  62. package/es/modules/blocks/data-blocks/form/FilterItemCustomSettings.mjs +1 -1
  63. package/es/modules/blocks/data-blocks/form/fieldSettingsFormItem.mjs +9 -4
  64. package/es/modules/blocks/data-blocks/table/hooks/useTableBlockProps.mjs +6 -4
  65. package/es/modules/blocks/data-blocks/table/tableBlockSettings.mjs +4 -0
  66. package/es/modules/blocks/data-blocks/table/tableColumnSettings.mjs +44 -0
  67. package/es/modules/blocks/filter-blocks/collapse/filterCollapseItemFieldSettings.mjs +4 -0
  68. package/es/modules/blocks/filter-blocks/form/filterFormItemFieldSettings.mjs +9 -0
  69. package/es/modules/fields/component/Radio/radioComponentFieldSettings.mjs +0 -4
  70. package/es/modules/fields/component/SubTable/secondLevelSelect.d.ts +11 -0
  71. package/es/modules/fields/component/SubTable/secondLevelSelect.mjs +102 -0
  72. package/es/modules/fields/component/SubTable/subTablePopoverComponentFieldSettings.d.ts +79 -41
  73. package/es/modules/fields/component/SubTable/subTablePopoverComponentFieldSettings.mjs +103 -100
  74. package/es/powered-by/index.mjs +4 -7
  75. package/es/schema-component/antd/action/Action.Designer.mjs +43 -5
  76. package/es/schema-component/antd/action/Action.Modal.mjs +19 -31
  77. package/es/schema-component/antd/action/Action.Modal.style.d.ts +4 -0
  78. package/es/schema-component/antd/action/Action.Modal.style.mjs +35 -0
  79. package/es/schema-component/antd/action/Action.mjs +1 -3
  80. package/es/schema-component/antd/action/utils.d.ts +1 -1
  81. package/es/schema-component/antd/action/utils.mjs +70 -70
  82. package/es/schema-component/antd/association-field/SubTabs/InternalCollapse.mjs +2 -1
  83. package/es/schema-component/antd/checkbox/Checkbox.mjs +9 -2
  84. package/es/schema-component/antd/index.d.ts +1 -0
  85. package/es/schema-component/antd/index.mjs +1 -0
  86. package/es/schema-component/antd/media-card/MediaCard.d.ts +11 -0
  87. package/es/schema-component/antd/media-card/MediaCard.mjs +35 -0
  88. package/es/schema-component/antd/media-card/index.d.ts +1 -0
  89. package/es/schema-component/antd/media-card/index.mjs +1 -0
  90. package/es/schema-component/antd/media-card/style.d.ts +3 -0
  91. package/es/schema-component/antd/media-card/style.mjs +25 -0
  92. package/es/schema-component/antd/page/Page.d.ts +1 -5
  93. package/es/schema-component/antd/page/Page.mjs +235 -144
  94. package/es/schema-component/antd/page/Page.style.d.ts +5 -0
  95. package/es/schema-component/antd/page/Page.style.mjs +45 -0
  96. package/es/schema-component/antd/page/PageDesigner.d.ts +3 -0
  97. package/es/schema-component/antd/page/PageDesigner.mjs +28 -0
  98. package/es/schema-component/antd/page/PageTabDesigner.d.ts +0 -3
  99. package/es/schema-component/antd/page/PageTabDesigner.mjs +3 -50
  100. package/es/schema-component/antd/page/style.d.ts +1 -1
  101. package/es/schema-component/antd/page/style.mjs +3 -13
  102. package/es/schema-component/antd/password/Password.d.ts +1 -1
  103. package/es/schema-component/antd/password/utils.d.ts +1 -1
  104. package/es/schema-component/antd/scroll-area/ScrollArea.d.ts +1 -1
  105. package/es/schema-component/antd/scroll-area/ScrollArea.mjs +2 -1
  106. package/es/schema-component/antd/variable/TextArea.mjs +1 -1
  107. package/es/schema-component/antd/variable/TextAreaWithGlobalScope.d.ts +13 -0
  108. package/es/schema-component/antd/variable/TextAreaWithGlobalScope.mjs +59 -0
  109. package/es/schema-component/antd/variable/index.d.ts +1 -0
  110. package/es/schema-component/antd/variable/index.mjs +3 -0
  111. package/es/schema-component/common/dnd-context/index.mjs +1 -7
  112. package/es/schema-component/common/sortable-item/DragHandlePageTab.d.ts +1 -0
  113. package/es/schema-component/common/sortable-item/DragHandlePageTab.mjs +71 -0
  114. package/es/schema-component/common/sortable-item/DragHandlePageTab.style.d.ts +3 -0
  115. package/es/schema-component/common/sortable-item/DragHandlePageTab.style.mjs +25 -0
  116. package/es/schema-items/GeneralSettings.mjs +5 -0
  117. package/es/schema-settings/EditCustomDefaultValue.mjs +1 -1
  118. package/es/schema-settings/SchemaSettings.mjs +1 -1
  119. package/es/schema-settings/SchemaSettingsDefaultValue.mjs +2 -0
  120. package/es/schema-settings/utils/createModalSettingsItem.d.ts +26 -0
  121. package/es/schema-settings/utils/createModalSettingsItem.mjs +46 -0
  122. package/es/schema-settings/utils/createSelectSettingsItem.d.ts +25 -0
  123. package/es/schema-settings/utils/createSelectSettingsItem.mjs +40 -0
  124. package/es/schema-settings/utils/createSwitchSettingsItem.d.ts +21 -0
  125. package/es/schema-settings/utils/createSwitchSettingsItem.mjs +38 -0
  126. package/es/schema-settings/utils/createTextSettingsItem.d.ts +9 -0
  127. package/es/schema-settings/utils/createTextSettingsItem.mjs +21 -0
  128. package/es/schema-settings/utils/index.d.ts +4 -0
  129. package/es/schema-settings/utils/index.mjs +4 -0
  130. package/es/schema-settings/utils/util.d.ts +12 -0
  131. package/es/schema-settings/utils/util.mjs +24 -0
  132. package/es/user/CurrentUserProvider.mjs +6 -3
  133. package/lib/api-client/APIClient.js +93 -49
  134. package/lib/application/Application.js +19 -0
  135. package/lib/application/CustomRouterContextProvider.js +276 -0
  136. package/lib/application/RouterManager.js +49 -15
  137. package/lib/application/hooks/index.js +9 -0
  138. package/lib/application/hooks/useGlobalVariable.js +52 -0
  139. package/lib/application/schema-initializer/hooks/index.js +2 -2
  140. package/lib/application/schema-settings/hooks/index.js +6 -8
  141. package/lib/block-provider/hooks/index.js +80 -59
  142. package/lib/built-in/context-menu/ContextMenu.provider.js +6 -6
  143. package/lib/built-in/context-menu/ContextMenuItemsProps.js +6 -6
  144. package/lib/built-in/context-menu/index.js +1 -1
  145. package/lib/built-in/index.js +8 -0
  146. package/lib/built-in/locale/LocalePlugin.js +5 -1
  147. package/lib/built-in/page-style/PageStyle.provider.js +2 -2
  148. package/lib/built-in/system-settings/SystemSettingsProvider.js +4 -3
  149. package/lib/built-in/system-settings/SystemSettingsShortcut.js +11 -8
  150. package/lib/collection-manager/Configuration/AddCollectionAction.js +12 -2
  151. package/lib/collection-manager/Configuration/ImportXlsx/ImportXlsxMetaAction.js +304 -0
  152. package/lib/collection-manager/Configuration/ImportXlsx/XlsxCollectionSchema.js +130 -0
  153. package/lib/collection-manager/Configuration/ImportXlsx/XlsxEditFieldAction.js +81 -0
  154. package/lib/collection-manager/Configuration/ImportXlsx/setUpdateXlsxCollectionField.js +78 -0
  155. package/lib/collection-manager/Configuration/ImportXlsx/xlsxFieldsConfigure.js +414 -0
  156. package/lib/collection-manager/Configuration/ImportXlsx/xlsxFormValueContextProvider.js +53 -0
  157. package/lib/collection-manager/Configuration/ImportXlsx/xlsxImportAction.js +235 -0
  158. package/lib/collection-manager/Configuration/ImportXlsx/xlsxPreviewTable.js +64 -0
  159. package/lib/collection-manager/collectionPlugin.js +3 -1
  160. package/lib/collection-manager/templates/import.js +1 -1
  161. package/lib/collection-manager/templates/xlsx.js +53 -0
  162. package/lib/data-source/collection-field-interface/CollectionFieldInterface.js +18 -0
  163. package/lib/data-source/collection-field-interface/CollectionFieldInterfaceManager.js +20 -0
  164. package/lib/data-source/commonsSettingsItem/fieldComponent.js +3 -1
  165. package/lib/filter-provider/utils.js +6 -0
  166. package/lib/i18n/i18n.js +7 -12
  167. package/lib/locale/en_US.js +1 -0
  168. package/lib/locale/zh-CN.js +14 -2
  169. package/lib/modules/actions/delete/deleteActionSettings.js +10 -0
  170. package/lib/modules/blocks/data-blocks/form/FilterItemCustomSettings.js +1 -1
  171. package/lib/modules/blocks/data-blocks/form/fieldSettingsFormItem.js +9 -4
  172. package/lib/modules/blocks/data-blocks/table/hooks/useTableBlockProps.js +6 -4
  173. package/lib/modules/blocks/data-blocks/table/tableBlockSettings.js +4 -0
  174. package/lib/modules/blocks/data-blocks/table/tableColumnSettings.js +44 -0
  175. package/lib/modules/blocks/filter-blocks/collapse/filterCollapseItemFieldSettings.js +4 -0
  176. package/lib/modules/blocks/filter-blocks/form/filterFormItemFieldSettings.js +9 -0
  177. package/lib/modules/fields/component/Radio/radioComponentFieldSettings.js +0 -4
  178. package/lib/modules/fields/component/SubTable/secondLevelSelect.js +136 -0
  179. package/lib/modules/fields/component/SubTable/subTablePopoverComponentFieldSettings.js +104 -103
  180. package/lib/powered-by/index.js +4 -7
  181. package/lib/schema-component/antd/action/Action.Designer.js +43 -5
  182. package/lib/schema-component/antd/action/Action.Modal.js +19 -31
  183. package/lib/schema-component/antd/action/Action.Modal.style.js +69 -0
  184. package/lib/schema-component/antd/action/Action.js +1 -3
  185. package/lib/schema-component/antd/action/utils.js +70 -70
  186. package/lib/schema-component/antd/association-field/SubTabs/InternalCollapse.js +2 -1
  187. package/lib/schema-component/antd/checkbox/Checkbox.js +9 -2
  188. package/lib/schema-component/antd/index.js +18 -4
  189. package/lib/schema-component/antd/media-card/MediaCard.js +69 -0
  190. package/lib/schema-component/antd/media-card/index.js +65 -0
  191. package/lib/schema-component/antd/media-card/style.js +59 -0
  192. package/lib/schema-component/antd/page/Page.js +235 -144
  193. package/lib/schema-component/antd/page/Page.style.js +79 -0
  194. package/lib/schema-component/antd/page/PageDesigner.js +62 -0
  195. package/lib/schema-component/antd/page/PageTabDesigner.js +2 -50
  196. package/lib/schema-component/antd/page/style.js +3 -13
  197. package/lib/schema-component/antd/scroll-area/ScrollArea.js +2 -1
  198. package/lib/schema-component/antd/variable/TextArea.js +1 -1
  199. package/lib/schema-component/antd/variable/TextAreaWithGlobalScope.js +94 -0
  200. package/lib/schema-component/antd/variable/index.js +13 -1
  201. package/lib/schema-component/common/dnd-context/index.js +1 -7
  202. package/lib/schema-component/common/sortable-item/DragHandlePageTab.js +105 -0
  203. package/lib/schema-component/common/sortable-item/DragHandlePageTab.style.js +59 -0
  204. package/lib/schema-items/GeneralSettings.js +5 -0
  205. package/lib/schema-settings/EditCustomDefaultValue.js +1 -1
  206. package/lib/schema-settings/SchemaSettings.js +1 -1
  207. package/lib/schema-settings/SchemaSettingsDefaultValue.js +2 -0
  208. package/lib/schema-settings/utils/createModalSettingsItem.js +94 -0
  209. package/lib/schema-settings/utils/createSelectSettingsItem.js +88 -0
  210. package/lib/schema-settings/utils/createSwitchSettingsItem.js +86 -0
  211. package/lib/schema-settings/utils/createTextSettingsItem.js +55 -0
  212. package/lib/schema-settings/utils/index.js +92 -0
  213. package/lib/schema-settings/utils/util.js +74 -0
  214. package/lib/user/CurrentUserProvider.js +6 -3
  215. package/package.json +7 -7
@@ -0,0 +1,65 @@
1
+ "use strict";
2
+ var __webpack_modules__ = {
3
+ "./MediaCard": function(module) {
4
+ module.exports = require("./MediaCard.js");
5
+ }
6
+ };
7
+ var __webpack_module_cache__ = {};
8
+ function __webpack_require__(moduleId) {
9
+ var cachedModule = __webpack_module_cache__[moduleId];
10
+ if (void 0 !== cachedModule) return cachedModule.exports;
11
+ var module = __webpack_module_cache__[moduleId] = {
12
+ exports: {}
13
+ };
14
+ __webpack_modules__[moduleId](module, module.exports, __webpack_require__);
15
+ return module.exports;
16
+ }
17
+ (()=>{
18
+ __webpack_require__.n = function(module) {
19
+ var getter = module && module.__esModule ? function() {
20
+ return module['default'];
21
+ } : function() {
22
+ return module;
23
+ };
24
+ __webpack_require__.d(getter, {
25
+ a: getter
26
+ });
27
+ return getter;
28
+ };
29
+ })();
30
+ (()=>{
31
+ __webpack_require__.d = function(exports1, definition) {
32
+ for(var key in definition)if (__webpack_require__.o(definition, key) && !__webpack_require__.o(exports1, key)) Object.defineProperty(exports1, key, {
33
+ enumerable: true,
34
+ get: definition[key]
35
+ });
36
+ };
37
+ })();
38
+ (()=>{
39
+ __webpack_require__.o = function(obj, prop) {
40
+ return Object.prototype.hasOwnProperty.call(obj, prop);
41
+ };
42
+ })();
43
+ (()=>{
44
+ __webpack_require__.r = function(exports1) {
45
+ if ('undefined' != typeof Symbol && Symbol.toStringTag) Object.defineProperty(exports1, Symbol.toStringTag, {
46
+ value: 'Module'
47
+ });
48
+ Object.defineProperty(exports1, '__esModule', {
49
+ value: true
50
+ });
51
+ };
52
+ })();
53
+ var __webpack_exports__ = {};
54
+ __webpack_require__.r(__webpack_exports__);
55
+ var _MediaCard__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__("./MediaCard");
56
+ var __WEBPACK_REEXPORT_OBJECT__ = {};
57
+ for(var __WEBPACK_IMPORT_KEY__ in _MediaCard__WEBPACK_IMPORTED_MODULE_0__)if ("default" !== __WEBPACK_IMPORT_KEY__) __WEBPACK_REEXPORT_OBJECT__[__WEBPACK_IMPORT_KEY__] = (function(key) {
58
+ return _MediaCard__WEBPACK_IMPORTED_MODULE_0__[key];
59
+ }).bind(0, __WEBPACK_IMPORT_KEY__);
60
+ __webpack_require__.d(__webpack_exports__, __WEBPACK_REEXPORT_OBJECT__);
61
+ var __webpack_export_target__ = exports;
62
+ for(var __webpack_i__ in __webpack_exports__)__webpack_export_target__[__webpack_i__] = __webpack_exports__[__webpack_i__];
63
+ if (__webpack_exports__.__esModule) Object.defineProperty(__webpack_export_target__, '__esModule', {
64
+ value: true
65
+ });
@@ -0,0 +1,59 @@
1
+ "use strict";
2
+ var __webpack_require__ = {};
3
+ (()=>{
4
+ __webpack_require__.d = function(exports1, definition) {
5
+ for(var key in definition)if (__webpack_require__.o(definition, key) && !__webpack_require__.o(exports1, key)) Object.defineProperty(exports1, key, {
6
+ enumerable: true,
7
+ get: definition[key]
8
+ });
9
+ };
10
+ })();
11
+ (()=>{
12
+ __webpack_require__.o = function(obj, prop) {
13
+ return Object.prototype.hasOwnProperty.call(obj, prop);
14
+ };
15
+ })();
16
+ (()=>{
17
+ __webpack_require__.r = function(exports1) {
18
+ if ('undefined' != typeof Symbol && Symbol.toStringTag) Object.defineProperty(exports1, Symbol.toStringTag, {
19
+ value: 'Module'
20
+ });
21
+ Object.defineProperty(exports1, '__esModule', {
22
+ value: true
23
+ });
24
+ };
25
+ })();
26
+ var __webpack_exports__ = {};
27
+ __webpack_require__.r(__webpack_exports__);
28
+ __webpack_require__.d(__webpack_exports__, {
29
+ useStyles: ()=>useStyles
30
+ });
31
+ const external_antd_style_namespaceObject = require("antd-style");
32
+ function _tagged_template_literal(strings, raw) {
33
+ if (!raw) raw = strings.slice(0);
34
+ return Object.freeze(Object.defineProperties(strings, {
35
+ raw: {
36
+ value: Object.freeze(raw)
37
+ }
38
+ }));
39
+ }
40
+ function _templateObject() {
41
+ const data = _tagged_template_literal([
42
+ "\n display: flex;\n flex-direction: row;\n justify-content: center;\n align-items: center;\n gap: 10px;\n width: fit-content;\n padding: 10px;\n cursor: pointer;\n\n &.layout {\n flex-direction: column;\n }\n :hover {\n border-radius: 10px;\n transform: scale(1.05);\n transition: all 0.3s;\n }\n\n &.need-hover:hover {\n background-color: var(--colorPrimaryText);\n }\n\n .icon-wrapper {\n padding: 20px;\n border-radius: 40%;\n .icon {\n padding: 10px;\n border-radius: 50%;\n background-color: #ffffff;\n font-size: 20px;\n }\n }\n\n .title {\n flex: 1;\n display: inline-block;\n font-size: 16px;\n color: #2f2f2f;\n overflow: hidden;\n }\n "
43
+ ]);
44
+ _templateObject = function() {
45
+ return data;
46
+ };
47
+ return data;
48
+ }
49
+ const useStyles = (0, external_antd_style_namespaceObject.createStyles)((param)=>{
50
+ let { css, token } = param;
51
+ return {
52
+ mediaCardStyle: css(_templateObject())
53
+ };
54
+ });
55
+ var __webpack_export_target__ = exports;
56
+ for(var __webpack_i__ in __webpack_exports__)__webpack_export_target__[__webpack_i__] = __webpack_exports__[__webpack_i__];
57
+ if (__webpack_exports__.__esModule) Object.defineProperty(__webpack_export_target__, '__esModule', {
58
+ value: true
59
+ });
@@ -47,7 +47,9 @@ const components_namespaceObject = require("@tachybase/components");
47
47
  const schema_namespaceObject = require("@tachybase/schema");
48
48
  const icons_namespaceObject = require("@ant-design/icons");
49
49
  const pro_layout_namespaceObject = require("@ant-design/pro-layout");
50
+ const core_namespaceObject = require("@dnd-kit/core");
50
51
  const external_antd_namespaceObject = require("antd");
52
+ const external_antd_style_namespaceObject = require("antd-style");
51
53
  const external_classnames_namespaceObject = require("classnames");
52
54
  var external_classnames_default = /*#__PURE__*/ __webpack_require__.n(external_classnames_namespaceObject);
53
55
  const external_react_error_boundary_namespaceObject = require("react-error-boundary");
@@ -64,40 +66,24 @@ const useGetAriaLabelOfSchemaInitializer_js_namespaceObject = require("../../../
64
66
  const theme_index_js_namespaceObject = require("../../../style/theme/index.js");
65
67
  const external_common_index_js_namespaceObject = require("../../common/index.js");
66
68
  const sortable_item_index_js_namespaceObject = require("../../common/sortable-item/index.js");
69
+ const DragHandlePageTab_js_namespaceObject = require("../../common/sortable-item/DragHandlePageTab.js");
67
70
  const external_core_index_js_namespaceObject = require("../../core/index.js");
68
71
  const external_hooks_index_js_namespaceObject = require("../../hooks/index.js");
69
72
  const external_error_fallback_index_js_namespaceObject = require("../error-fallback/index.js");
70
73
  const external_FixedBlock_js_namespaceObject = require("./FixedBlock.js");
71
74
  var external_FixedBlock_js_default = /*#__PURE__*/ __webpack_require__.n(external_FixedBlock_js_namespaceObject);
75
+ const external_Page_style_js_namespaceObject = require("./Page.style.js");
76
+ const external_PageDesigner_js_namespaceObject = require("./PageDesigner.js");
72
77
  const external_PageTabDesigner_js_namespaceObject = require("./PageTabDesigner.js");
73
78
  const external_style_js_namespaceObject = require("./style.js");
74
79
  const Page = (props)=>{
75
- var _fieldSchema_xcomponentprops, _fieldSchema_xcomponentprops1, _fieldSchema_xcomponentprops2;
80
+ var _fieldSchema_xcomponentprops, _fieldSchema_xcomponentprops1;
76
81
  const { children, ...others } = props;
77
82
  const { t } = (0, external_react_i18next_namespaceObject.useTranslation)();
78
- const compile = (0, external_hooks_index_js_namespaceObject.useCompile)();
79
83
  const { title, setTitle } = (0, document_title_index_js_namespaceObject.useDocumentTitle)();
80
84
  const fieldSchema = (0, schema_namespaceObject.useFieldSchema)();
81
- const dn = (0, external_hooks_index_js_namespaceObject.useDesignable)();
82
- const { theme } = (0, theme_index_js_namespaceObject.useGlobalTheme)();
83
- const { getAriaLabel } = (0, useGetAriaLabelOfSchemaInitializer_js_namespaceObject.useGetAriaLabelOfSchemaInitializer)();
84
- const { hiddenScrollArea } = (0, useContextMenu_js_namespaceObject.useContextMenu)();
85
- const [hasMounted, setHasMounted] = (0, external_react_namespaceObject.useState)(false);
86
- (0, external_react_namespaceObject.useEffect)(()=>{
87
- setTimeout(()=>{
88
- setHasMounted(true);
89
- });
90
- }, []);
91
- (0, external_react_namespaceObject.useEffect)(()=>{
92
- if (!title) setTitle(t(fieldSchema.title));
93
- }, [
94
- fieldSchema.title,
95
- title
96
- ]);
97
85
  const disablePageHeader = null === (_fieldSchema_xcomponentprops = fieldSchema['x-component-props']) || void 0 === _fieldSchema_xcomponentprops ? void 0 : _fieldSchema_xcomponentprops.disablePageHeader;
98
86
  const enablePageTabs = null === (_fieldSchema_xcomponentprops1 = fieldSchema['x-component-props']) || void 0 === _fieldSchema_xcomponentprops1 ? void 0 : _fieldSchema_xcomponentprops1.enablePageTabs;
99
- const hidePageTitle = null === (_fieldSchema_xcomponentprops2 = fieldSchema['x-component-props']) || void 0 === _fieldSchema_xcomponentprops2 ? void 0 : _fieldSchema_xcomponentprops2.hidePageTitle;
100
- const options = (0, external_react_namespaceObject.useContext)(schema_namespaceObject.SchemaOptionsContext);
101
87
  const [searchParams, setSearchParams] = (0, external_react_router_dom_namespaceObject.useSearchParams)();
102
88
  const [loading, setLoading] = (0, external_react_namespaceObject.useState)(false);
103
89
  const activeKey = (0, external_react_namespaceObject.useMemo)(()=>searchParams.get('tab') || Object.keys(fieldSchema.properties || {}).shift(), [
@@ -105,144 +91,248 @@ const Page = (props)=>{
105
91
  searchParams
106
92
  ]);
107
93
  const [height, setHeight] = (0, external_react_namespaceObject.useState)(0);
108
- const { wrapSSR, hashId, componentCls } = (0, external_style_js_namespaceObject.useStyles)();
109
94
  const aclStyles = (0, style_js_namespaceObject.useStyles)();
110
- const handleErrors = (error)=>{
111
- var _window_Sentry, _window;
112
- null === (_window = window) || void 0 === _window || null === (_window_Sentry = _window.Sentry) || void 0 === _window_Sentry || _window_Sentry.captureException(error);
113
- console.error(error);
114
- };
115
- const pageHeaderTitle = hidePageTitle ? void 0 : fieldSchema.title || compile(title);
95
+ const { wrapSSR, hashId, componentCls } = (0, external_style_js_namespaceObject.getStyles)();
96
+ (0, external_react_namespaceObject.useEffect)(()=>{
97
+ if (!title) setTitle(t(fieldSchema.title));
98
+ }, [
99
+ fieldSchema.title,
100
+ title
101
+ ]);
116
102
  return wrapSSR(/*#__PURE__*/ (0, jsx_runtime_namespaceObject.jsx)(FilterProvider_js_namespaceObject.FilterBlockProvider, {
117
103
  children: /*#__PURE__*/ (0, jsx_runtime_namespaceObject.jsxs)("div", {
118
104
  className: "".concat(componentCls, " ").concat(hashId, " ").concat(aclStyles.styles),
119
105
  children: [
120
- /*#__PURE__*/ (0, jsx_runtime_namespaceObject.jsx)(external_PageTabDesigner_js_namespaceObject.PageDesigner, {
106
+ /*#__PURE__*/ (0, jsx_runtime_namespaceObject.jsx)(external_PageDesigner_js_namespaceObject.PageDesigner, {
121
107
  title: fieldSchema.title || title
122
108
  }),
123
- /*#__PURE__*/ (0, jsx_runtime_namespaceObject.jsx)("div", {
124
- ref: (ref)=>{
125
- setHeight(Math.floor((null == ref ? void 0 : ref.getBoundingClientRect().height) || 0) + 1);
109
+ /*#__PURE__*/ (0, jsx_runtime_namespaceObject.jsx)(PageHeader, {
110
+ disablePageHeader: disablePageHeader,
111
+ enablePageTabs: enablePageTabs,
112
+ activeKey: activeKey,
113
+ title: title,
114
+ fieldSchema: fieldSchema,
115
+ parentProps: others,
116
+ setHeight: setHeight,
117
+ setLoading: setLoading,
118
+ setSearchParams: setSearchParams
119
+ }),
120
+ /*#__PURE__*/ (0, jsx_runtime_namespaceObject.jsx)(PageContentComponent, {
121
+ loading: loading,
122
+ disablePageHeader: disablePageHeader,
123
+ enablePageTabs: enablePageTabs,
124
+ fieldSchema: fieldSchema,
125
+ activeKey: activeKey,
126
+ height: height,
127
+ children: children
128
+ })
129
+ ]
130
+ })
131
+ }));
132
+ };
133
+ const PageHeader = (props)=>{
134
+ var _fieldSchema_xcomponentprops;
135
+ const { disablePageHeader, enablePageTabs, setHeight, activeKey, setLoading, setSearchParams, fieldSchema, title, parentProps } = props;
136
+ const { theme } = (0, theme_index_js_namespaceObject.useGlobalTheme)();
137
+ const options = (0, external_react_namespaceObject.useContext)(schema_namespaceObject.SchemaOptionsContext);
138
+ const compile = (0, external_hooks_index_js_namespaceObject.useCompile)();
139
+ const { showScrollArea } = (0, useContextMenu_js_namespaceObject.useContextMenu)();
140
+ const hidePageTitle = null === (_fieldSchema_xcomponentprops = fieldSchema['x-component-props']) || void 0 === _fieldSchema_xcomponentprops ? void 0 : _fieldSchema_xcomponentprops.hidePageTitle;
141
+ const pageHeaderTitle = hidePageTitle ? void 0 : fieldSchema.title || compile(title);
142
+ const items = fieldSchema.mapProperties((schema)=>({
143
+ key: schema.name,
144
+ label: /*#__PURE__*/ (0, jsx_runtime_namespaceObject.jsx)(TabItem, {
145
+ schema: schema
146
+ })
147
+ }));
148
+ return /*#__PURE__*/ (0, jsx_runtime_namespaceObject.jsx)("div", {
149
+ ref: (ref)=>{
150
+ setHeight(Math.floor((null == ref ? void 0 : ref.getBoundingClientRect().height) || 0) + 1);
151
+ },
152
+ className: "tb-page-header-wrapper",
153
+ children: !disablePageHeader && /*#__PURE__*/ (0, jsx_runtime_namespaceObject.jsx)(pro_layout_namespaceObject.PageHeader, {
154
+ className: external_classnames_default()('pageHeaderCss', pageHeaderTitle || enablePageTabs ? '' : 'height0'),
155
+ ghost: false,
156
+ title: pageHeaderTitle || ' ',
157
+ ...parentProps,
158
+ extra: !enablePageTabs && showScrollArea && /*#__PURE__*/ (0, jsx_runtime_namespaceObject.jsx)(external_index_js_namespaceObject.ScrollArea, {}),
159
+ footer: enablePageTabs && /*#__PURE__*/ (0, jsx_runtime_namespaceObject.jsx)(TabComponent, {
160
+ activeKey: activeKey,
161
+ setLoading: setLoading,
162
+ setSearchParams: setSearchParams,
163
+ showScrollArea: showScrollArea,
164
+ options: options,
165
+ theme: theme,
166
+ items: items
167
+ })
168
+ })
169
+ });
170
+ };
171
+ const TabComponent = (props)=>{
172
+ const { activeKey, setLoading, setSearchParams, showScrollArea, options, theme, items } = props;
173
+ const { styles } = (0, external_Page_style_js_namespaceObject.useStyles)();
174
+ const [hasMounted, setHasMounted] = (0, external_react_namespaceObject.useState)(false);
175
+ const sensors = (0, core_namespaceObject.useSensors)((0, core_namespaceObject.useSensor)(core_namespaceObject.PointerSensor, {
176
+ activationConstraint: {
177
+ distance: 5
178
+ }
179
+ }));
180
+ const handleTabClick = (activeKey)=>{
181
+ setLoading(true);
182
+ setSearchParams([
183
+ [
184
+ 'tab',
185
+ activeKey
186
+ ]
187
+ ]);
188
+ setTimeout(()=>{
189
+ setLoading(false);
190
+ }, 50);
191
+ };
192
+ (0, external_react_namespaceObject.useEffect)(()=>{
193
+ setTimeout(()=>{
194
+ setHasMounted(true);
195
+ });
196
+ }, []);
197
+ return /*#__PURE__*/ (0, jsx_runtime_namespaceObject.jsx)(external_common_index_js_namespaceObject.DndContext, {
198
+ sensors: sensors,
199
+ children: /*#__PURE__*/ (0, jsx_runtime_namespaceObject.jsx)(external_antd_namespaceObject.Tabs, {
200
+ className: styles.tabComponentClass,
201
+ type: "card",
202
+ size: 'small',
203
+ animated: hasMounted,
204
+ activeKey: activeKey,
205
+ items: items,
206
+ onTabClick: handleTabClick,
207
+ tabBarExtraContent: /*#__PURE__*/ (0, jsx_runtime_namespaceObject.jsx)(TabBarExtraContent, {
208
+ theme: theme,
209
+ showScrollArea: showScrollArea,
210
+ options: options
211
+ })
212
+ })
213
+ });
214
+ };
215
+ const TabItem = (props)=>{
216
+ const { schema } = props;
217
+ const { t } = (0, external_react_i18next_namespaceObject.useTranslation)();
218
+ const { styles } = (0, external_Page_style_js_namespaceObject.useStyles)();
219
+ return /*#__PURE__*/ (0, jsx_runtime_namespaceObject.jsx)(sortable_item_index_js_namespaceObject.SortableItem, {
220
+ id: schema.name,
221
+ schema: schema,
222
+ className: external_classnames_default()('tb-action-link', 'designerCss', props.className, styles.tabItemClass),
223
+ children: /*#__PURE__*/ (0, jsx_runtime_namespaceObject.jsxs)(DragHandlePageTab_js_namespaceObject.DragHandlePageTab, {
224
+ children: [
225
+ schema['x-icon'] && /*#__PURE__*/ (0, jsx_runtime_namespaceObject.jsx)(external_icon_index_js_namespaceObject.Icon, {
226
+ style: {
227
+ marginRight: 8
126
228
  },
127
- className: "tb-page-header-wrapper",
128
- children: !disablePageHeader && /*#__PURE__*/ (0, jsx_runtime_namespaceObject.jsx)(pro_layout_namespaceObject.PageHeader, {
129
- className: external_classnames_default()('pageHeaderCss', pageHeaderTitle || enablePageTabs ? '' : 'height0'),
130
- ghost: false,
131
- title: pageHeaderTitle || ' ',
132
- ...others,
133
- footer: enablePageTabs && /*#__PURE__*/ (0, jsx_runtime_namespaceObject.jsx)(external_common_index_js_namespaceObject.DndContext, {
134
- children: /*#__PURE__*/ (0, jsx_runtime_namespaceObject.jsx)(external_antd_namespaceObject.Tabs, {
135
- size: 'small',
136
- animated: hasMounted,
137
- activeKey: activeKey,
138
- onTabClick: (activeKey)=>{
139
- setLoading(true);
140
- setSearchParams([
141
- [
142
- 'tab',
143
- activeKey
144
- ]
145
- ]);
146
- setTimeout(()=>{
147
- setLoading(false);
148
- }, 50);
149
- },
150
- tabBarExtraContent: /*#__PURE__*/ (0, jsx_runtime_namespaceObject.jsxs)("div", {
151
- className: "tb-tabs-wrapper",
152
- children: [
153
- !hiddenScrollArea && /*#__PURE__*/ (0, jsx_runtime_namespaceObject.jsx)(external_index_js_namespaceObject.ScrollArea, {}),
154
- dn.designable && /*#__PURE__*/ (0, jsx_runtime_namespaceObject.jsx)(external_antd_namespaceObject.Button, {
155
- "aria-label": getAriaLabel('tabs'),
156
- icon: /*#__PURE__*/ (0, jsx_runtime_namespaceObject.jsx)(icons_namespaceObject.PlusOutlined, {}),
157
- className: 'addTabBtn',
158
- type: 'dashed',
159
- onClick: async ()=>{
160
- const values = await (0, external_index_js_namespaceObject.FormDialog)(t('Add tab'), ()=>/*#__PURE__*/ (0, jsx_runtime_namespaceObject.jsx)(external_core_index_js_namespaceObject.SchemaComponentOptions, {
161
- scope: options.scope,
162
- components: {
163
- ...options.components
164
- },
165
- children: /*#__PURE__*/ (0, jsx_runtime_namespaceObject.jsx)(components_namespaceObject.FormLayout, {
166
- layout: 'vertical',
167
- children: /*#__PURE__*/ (0, jsx_runtime_namespaceObject.jsx)(external_core_index_js_namespaceObject.SchemaComponent, {
168
- schema: {
169
- properties: {
170
- title: {
171
- title: t('Tab name'),
172
- 'x-component': 'Input',
173
- 'x-decorator': 'FormItem',
174
- required: true
175
- },
176
- icon: {
177
- title: t('Icon'),
178
- 'x-component': 'IconPicker',
179
- 'x-decorator': 'FormItem'
180
- }
181
- }
182
- }
183
- })
184
- })
185
- }), theme).open({
186
- initialValues: {}
187
- });
188
- const { title, icon } = values;
189
- dn.insertBeforeEnd({
190
- type: 'void',
191
- title,
192
- 'x-icon': icon,
193
- 'x-component': 'Grid',
194
- 'x-initializer': 'page:addBlock',
195
- properties: {}
196
- });
197
- },
198
- children: t('Add tab')
199
- })
200
- ]
201
- }),
202
- items: fieldSchema.mapProperties((schema)=>({
203
- label: /*#__PURE__*/ (0, jsx_runtime_namespaceObject.jsxs)(sortable_item_index_js_namespaceObject.SortableItem, {
204
- id: schema.name,
205
- schema: schema,
206
- className: external_classnames_default()('tb-action-link', 'designerCss', props.className),
207
- children: [
208
- schema['x-icon'] && /*#__PURE__*/ (0, jsx_runtime_namespaceObject.jsx)(external_icon_index_js_namespaceObject.Icon, {
209
- style: {
210
- marginRight: 8
211
- },
212
- type: schema['x-icon']
213
- }),
214
- /*#__PURE__*/ (0, jsx_runtime_namespaceObject.jsx)("span", {
215
- children: schema.title || t('Unnamed')
216
- }),
217
- /*#__PURE__*/ (0, jsx_runtime_namespaceObject.jsx)(external_PageTabDesigner_js_namespaceObject.PageTabDesigner, {
218
- schema: schema
219
- })
220
- ]
221
- }),
222
- key: schema.name
223
- }))
224
- })
225
- }),
226
- extra: !enablePageTabs && !hiddenScrollArea && /*#__PURE__*/ (0, jsx_runtime_namespaceObject.jsx)(external_index_js_namespaceObject.ScrollArea, {})
227
- })
229
+ type: schema['x-icon']
230
+ }),
231
+ /*#__PURE__*/ (0, jsx_runtime_namespaceObject.jsx)("span", {
232
+ children: schema.title || t('Unnamed')
228
233
  }),
229
234
  /*#__PURE__*/ (0, jsx_runtime_namespaceObject.jsx)("div", {
230
- className: "tb-page-wrapper",
231
- children: /*#__PURE__*/ (0, jsx_runtime_namespaceObject.jsx)(external_react_error_boundary_namespaceObject.ErrorBoundary, {
232
- FallbackComponent: external_error_fallback_index_js_namespaceObject.ErrorFallback,
233
- onError: handleErrors,
234
- children: PageContent(loading, disablePageHeader, enablePageTabs, fieldSchema, activeKey, height, props)
235
+ className: "tab-designer-wrapper",
236
+ children: /*#__PURE__*/ (0, jsx_runtime_namespaceObject.jsx)(external_PageTabDesigner_js_namespaceObject.PageTabDesigner, {
237
+ schema: schema
235
238
  })
236
239
  })
237
240
  ]
238
241
  })
239
- }));
242
+ });
243
+ };
244
+ const TabBarExtraContent = (props)=>{
245
+ const { showScrollArea, options, theme } = props;
246
+ const dn = (0, external_hooks_index_js_namespaceObject.useDesignable)();
247
+ const { t } = (0, external_react_i18next_namespaceObject.useTranslation)();
248
+ const { getAriaLabel } = (0, useGetAriaLabelOfSchemaInitializer_js_namespaceObject.useGetAriaLabelOfSchemaInitializer)();
249
+ const { styles } = (0, external_Page_style_js_namespaceObject.useStyles)();
250
+ const handleAddTab = async ()=>{
251
+ const values = await (0, external_index_js_namespaceObject.FormDialog)(t('Add tab'), ()=>/*#__PURE__*/ (0, jsx_runtime_namespaceObject.jsx)(AddTabForm, {
252
+ options: options
253
+ }), theme).open({
254
+ initialValues: {}
255
+ });
256
+ const { title, icon } = values;
257
+ dn.insertBeforeEnd({
258
+ type: 'void',
259
+ title,
260
+ 'x-icon': icon,
261
+ 'x-component': 'Grid',
262
+ 'x-initializer': 'page:addBlock',
263
+ properties: {}
264
+ });
265
+ };
266
+ return /*#__PURE__*/ (0, jsx_runtime_namespaceObject.jsxs)("div", {
267
+ className: (0, external_antd_style_namespaceObject.cx)(styles.tabWrapper, {
268
+ designable: dn.designable
269
+ }),
270
+ children: [
271
+ dn.designable && /*#__PURE__*/ (0, jsx_runtime_namespaceObject.jsx)(external_antd_namespaceObject.Button, {
272
+ className: "add-tab-btn",
273
+ type: "text",
274
+ "aria-label": getAriaLabel('tabs'),
275
+ icon: /*#__PURE__*/ (0, jsx_runtime_namespaceObject.jsx)(icons_namespaceObject.PlusOutlined, {}),
276
+ onClick: handleAddTab
277
+ }),
278
+ showScrollArea && /*#__PURE__*/ (0, jsx_runtime_namespaceObject.jsx)(external_index_js_namespaceObject.ScrollArea, {
279
+ className: "scroll-area-extra-content"
280
+ })
281
+ ]
282
+ });
283
+ };
284
+ const AddTabForm = (props)=>{
285
+ const { options } = props;
286
+ const { t } = (0, external_react_i18next_namespaceObject.useTranslation)();
287
+ return /*#__PURE__*/ (0, jsx_runtime_namespaceObject.jsx)(external_core_index_js_namespaceObject.SchemaComponentOptions, {
288
+ scope: options.scope,
289
+ components: {
290
+ ...options.components
291
+ },
292
+ children: /*#__PURE__*/ (0, jsx_runtime_namespaceObject.jsx)(components_namespaceObject.FormLayout, {
293
+ layout: 'vertical',
294
+ children: /*#__PURE__*/ (0, jsx_runtime_namespaceObject.jsx)(external_core_index_js_namespaceObject.SchemaComponent, {
295
+ schema: {
296
+ properties: {
297
+ title: {
298
+ title: t('Tab name'),
299
+ 'x-component': 'Input',
300
+ 'x-decorator': 'FormItem',
301
+ required: true
302
+ },
303
+ icon: {
304
+ title: t('Icon'),
305
+ 'x-component': 'IconPicker',
306
+ 'x-decorator': 'FormItem'
307
+ }
308
+ }
309
+ }
310
+ })
311
+ })
312
+ });
240
313
  };
241
- Page.displayName = 'Page';
242
- function PageContent(loading, disablePageHeader, enablePageTabs, fieldSchema, activeKey, height, props) {
314
+ const PageContentComponent = (props)=>{
315
+ const handleErrors = (error)=>{
316
+ var _window_Sentry, _window;
317
+ null === (_window = window) || void 0 === _window || null === (_window_Sentry = _window.Sentry) || void 0 === _window_Sentry || _window_Sentry.captureException(error);
318
+ console.error(error);
319
+ };
320
+ return /*#__PURE__*/ (0, jsx_runtime_namespaceObject.jsx)("div", {
321
+ className: "tb-page-wrapper",
322
+ children: /*#__PURE__*/ (0, jsx_runtime_namespaceObject.jsx)(external_react_error_boundary_namespaceObject.ErrorBoundary, {
323
+ FallbackComponent: external_error_fallback_index_js_namespaceObject.ErrorFallback,
324
+ onError: handleErrors,
325
+ children: /*#__PURE__*/ (0, jsx_runtime_namespaceObject.jsx)(PageContent, {
326
+ ...props
327
+ })
328
+ })
329
+ });
330
+ };
331
+ const PageContent = (props)=>{
332
+ const { loading, disablePageHeader, enablePageTabs, fieldSchema, activeKey, height, children } = props;
243
333
  const { token } = (0, index_js_namespaceObject.useToken)();
244
334
  if (loading) return;
245
- return !disablePageHeader && enablePageTabs ? fieldSchema.mapProperties((schema)=>{
335
+ if (!disablePageHeader && enablePageTabs) return fieldSchema.mapProperties((schema)=>{
246
336
  if (schema.name !== activeKey) return null;
247
337
  return /*#__PURE__*/ (0, jsx_runtime_namespaceObject.jsx)(external_FixedBlock_js_default(), {
248
338
  height: "calc(".concat(height, "px + 46px + ").concat(token.marginLG, "px * 2)"),
@@ -254,14 +344,15 @@ function PageContent(loading, disablePageHeader, enablePageTabs, fieldSchema, ac
254
344
  })
255
345
  })
256
346
  }, schema.name);
257
- }) : /*#__PURE__*/ (0, jsx_runtime_namespaceObject.jsx)(external_FixedBlock_js_default(), {
347
+ });
348
+ return /*#__PURE__*/ (0, jsx_runtime_namespaceObject.jsx)(external_FixedBlock_js_default(), {
258
349
  height: "calc(".concat(height, "px + 46px + ").concat(token.marginLG, "px * 2)"),
259
350
  children: /*#__PURE__*/ (0, jsx_runtime_namespaceObject.jsx)("div", {
260
351
  className: "pageWithFixedBlockCss tb-page-content",
261
- children: props.children
352
+ children: children
262
353
  })
263
354
  });
264
- }
355
+ };
265
356
  var __webpack_export_target__ = exports;
266
357
  for(var __webpack_i__ in __webpack_exports__)__webpack_export_target__[__webpack_i__] = __webpack_exports__[__webpack_i__];
267
358
  if (__webpack_exports__.__esModule) Object.defineProperty(__webpack_export_target__, '__esModule', {
@@ -0,0 +1,79 @@
1
+ "use strict";
2
+ var __webpack_require__ = {};
3
+ (()=>{
4
+ __webpack_require__.d = function(exports1, definition) {
5
+ for(var key in definition)if (__webpack_require__.o(definition, key) && !__webpack_require__.o(exports1, key)) Object.defineProperty(exports1, key, {
6
+ enumerable: true,
7
+ get: definition[key]
8
+ });
9
+ };
10
+ })();
11
+ (()=>{
12
+ __webpack_require__.o = function(obj, prop) {
13
+ return Object.prototype.hasOwnProperty.call(obj, prop);
14
+ };
15
+ })();
16
+ (()=>{
17
+ __webpack_require__.r = function(exports1) {
18
+ if ('undefined' != typeof Symbol && Symbol.toStringTag) Object.defineProperty(exports1, Symbol.toStringTag, {
19
+ value: 'Module'
20
+ });
21
+ Object.defineProperty(exports1, '__esModule', {
22
+ value: true
23
+ });
24
+ };
25
+ })();
26
+ var __webpack_exports__ = {};
27
+ __webpack_require__.r(__webpack_exports__);
28
+ __webpack_require__.d(__webpack_exports__, {
29
+ useStyles: ()=>useStyles
30
+ });
31
+ const external_antd_style_namespaceObject = require("antd-style");
32
+ function _tagged_template_literal(strings, raw) {
33
+ if (!raw) raw = strings.slice(0);
34
+ return Object.freeze(Object.defineProperties(strings, {
35
+ raw: {
36
+ value: Object.freeze(raw)
37
+ }
38
+ }));
39
+ }
40
+ function _templateObject() {
41
+ const data = _tagged_template_literal([
42
+ "\n .ant-tabs-nav-wrap.ant-tabs-nav-wrap {\n flex: none;\n }\n .ant-tabs-tab.ant-tabs-tab {\n border: none;\n background-color: #ffffff;\n }\n\n .ant-tabs-tab-active.ant-tabs-tab-active.ant-tabs-tab-active.ant-tabs-tab-active {\n border-radius: 8px 8px 0 0;\n box-shadow: none;\n text-shadow: none;\n background-color: var(--tb-box-bg);\n }\n .ant-tabs-extra-content {\n flex: 1;\n }\n "
43
+ ]);
44
+ _templateObject = function() {
45
+ return data;
46
+ };
47
+ return data;
48
+ }
49
+ function _templateObject1() {
50
+ const data = _tagged_template_literal([
51
+ "\n display: flex;\n flex-direction: row;\n justify-content: flex-end;\n\n &.designable {\n justify-content: space-between;\n }\n\n .scroll-area-extra-content {\n align-self: flex-end;\n }\n "
52
+ ]);
53
+ _templateObject1 = function() {
54
+ return data;
55
+ };
56
+ return data;
57
+ }
58
+ function _templateObject2() {
59
+ const data = _tagged_template_literal([
60
+ "\n position: relative;\n &:hover {\n .tab-designer-wrapper {\n display: block;\n }\n }\n .tab-designer-wrapper {\n display: none;\n position: absolute;\n top: 0;\n right: 0;\n padding: 0 2px;\n border-radius: 3px;\n color: #000000;\n background-color: #ffffff;\n\n &:hover {\n color: #ffffff;\n background-color: var(--colorSettings);\n }\n }\n "
61
+ ]);
62
+ _templateObject2 = function() {
63
+ return data;
64
+ };
65
+ return data;
66
+ }
67
+ const useStyles = (0, external_antd_style_namespaceObject.createStyles)((param)=>{
68
+ let { css, token } = param;
69
+ return {
70
+ tabComponentClass: css(_templateObject()),
71
+ tabWrapper: css(_templateObject1()),
72
+ tabItemClass: css(_templateObject2())
73
+ };
74
+ });
75
+ var __webpack_export_target__ = exports;
76
+ for(var __webpack_i__ in __webpack_exports__)__webpack_export_target__[__webpack_i__] = __webpack_exports__[__webpack_i__];
77
+ if (__webpack_exports__.__esModule) Object.defineProperty(__webpack_export_target__, '__esModule', {
78
+ value: true
79
+ });