diff --git a/packages/core/client/src/application/schema-initializer/components/style.ts b/packages/core/client/src/application/schema-initializer/components/style.ts index 9f57d6270..48e3760b5 100644 --- a/packages/core/client/src/application/schema-initializer/components/style.ts +++ b/packages/core/client/src/application/schema-initializer/components/style.ts @@ -1,6 +1,6 @@ import { genStyleHook } from '../../../schema-component/antd/__builtins__'; -export const useSchemaInitializerStyles = genStyleHook('nb-schema-initializer', (token) => { +export const useSchemaInitializerStyles = genStyleHook('tb-schema-initializer', (token) => { const { componentCls } = token; return { [componentCls]: { diff --git a/packages/core/client/src/built-in/acl/Configuration/schemas/scopes.ts b/packages/core/client/src/built-in/acl/Configuration/schemas/scopes.ts index 843bbcef0..642547476 100644 --- a/packages/core/client/src/built-in/acl/Configuration/schemas/scopes.ts +++ b/packages/core/client/src/built-in/acl/Configuration/schemas/scopes.ts @@ -59,7 +59,7 @@ export const scopesSchema: ISchema = { title: '{{ t("Select record") }}', 'x-component': 'RecordPicker.Selector', 'x-component-props': { - className: 'nb-record-picker-selector', + className: 'tb-record-picker-selector', }, properties: { tableBlock: { @@ -109,7 +109,7 @@ export const scopesSchema: ISchema = { title: '{{ t("Add record") }}', 'x-component': 'Action.Container', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, properties: { formBlock: { @@ -236,7 +236,7 @@ export const scopesSchema: ISchema = { title: '{{ t("Edit record") }}', 'x-component': 'Action.Container', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, properties: { formBlock: { diff --git a/packages/core/client/src/built-in/admin-layout/index.tsx b/packages/core/client/src/built-in/admin-layout/index.tsx index 77ec37669..a7e9f88b5 100644 --- a/packages/core/client/src/built-in/admin-layout/index.tsx +++ b/packages/core/client/src/built-in/admin-layout/index.tsx @@ -341,7 +341,7 @@ const MenuEditor = (props) => { * 鼠标悬浮在顶部“更多”按钮时显示的子菜单的样式 */ const GlobalStyleForAdminLayout = createGlobalStyle` - .nb-container-of-header-submenu { + .tb-container-of-header-submenu { .ant-menu.ant-menu-submenu.ant-menu-submenu-popup { .ant-menu.ant-menu-sub.ant-menu-vertical { background-color: ${(p) => { @@ -387,7 +387,7 @@ const SetThemeOfHeaderSubmenu = ({ children }) => { useEffect(() => { containerRef.current = document.createElement('div'); - containerRef.current.classList.add('nb-container-of-header-submenu'); + containerRef.current.classList.add('tb-container-of-header-submenu'); document.body.appendChild(containerRef.current); return () => { diff --git a/packages/core/client/src/built-in/context-menu/ContextMenuItemsProps.tsx b/packages/core/client/src/built-in/context-menu/ContextMenuItemsProps.tsx index e6cf58020..d3bf52eab 100644 --- a/packages/core/client/src/built-in/context-menu/ContextMenuItemsProps.tsx +++ b/packages/core/client/src/built-in/context-menu/ContextMenuItemsProps.tsx @@ -102,7 +102,7 @@ const checkedAutoPage = (position, message, t) => { const navbarHeight = navbar.getBoundingClientRect(); const classId = uid(); if (blockElement) { - const page = blockElement?.closest('.ant-nb-page '); + const page = blockElement?.closest('.ant-tb-page '); const drawer = blockElement?.closest('.ant-drawer-body'); const modal = blockElement?.closest('.ant-modal-body'); const tabNav = amplifierBlock.querySelector('.ant-tabs-nav'); @@ -154,7 +154,7 @@ const checkedAutoPage = (position, message, t) => { }; const removeNode = ({ gridRow: blockElement, classId }) => { - const page = blockElement?.closest('.ant-nb-page '); + const page = blockElement?.closest('.ant-tb-page '); const drawer = blockElement?.closest('.ant-drawer-body'); const parentNode = blockElement.parentNode; const tabNav = document.querySelector('.ant-tabs-nav'); diff --git a/packages/core/client/src/built-in/pm/PluginDocument.tsx b/packages/core/client/src/built-in/pm/PluginDocument.tsx index ff593939a..58466954a 100644 --- a/packages/core/client/src/built-in/pm/PluginDocument.tsx +++ b/packages/core/client/src/built-in/pm/PluginDocument.tsx @@ -67,7 +67,7 @@ export const PluginDocument: React.FC = memo((props) => { ) : (
)} diff --git a/packages/core/client/src/collection-manager/interfaces/properties/index.ts b/packages/core/client/src/collection-manager/interfaces/properties/index.ts index e851deeaf..853dcee8a 100644 --- a/packages/core/client/src/collection-manager/interfaces/properties/index.ts +++ b/packages/core/client/src/collection-manager/interfaces/properties/index.ts @@ -378,7 +378,7 @@ export const recordPickerViewer = { title: '{{ t("View record") }}', 'x-component': 'RecordPicker.Viewer', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, properties: { tabs: { diff --git a/packages/core/client/src/modules/actions/add-child/CreateChildInitializer.tsx b/packages/core/client/src/modules/actions/add-child/CreateChildInitializer.tsx index 1c6fc0599..b9d96474c 100644 --- a/packages/core/client/src/modules/actions/add-child/CreateChildInitializer.tsx +++ b/packages/core/client/src/modules/actions/add-child/CreateChildInitializer.tsx @@ -24,7 +24,7 @@ export const CreateChildInitializer = (props) => { title: '{{ t("Add record") }}', 'x-component': 'Action.Container', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, properties: { tabs: { diff --git a/packages/core/client/src/modules/actions/add-new/CreateActionInitializer.tsx b/packages/core/client/src/modules/actions/add-new/CreateActionInitializer.tsx index f100bd431..9047427aa 100644 --- a/packages/core/client/src/modules/actions/add-new/CreateActionInitializer.tsx +++ b/packages/core/client/src/modules/actions/add-new/CreateActionInitializer.tsx @@ -25,7 +25,7 @@ export const CreateActionInitializer = () => { title: '{{ t("Add record") }}', 'x-component': 'Action.Container', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, properties: { tabs: { diff --git a/packages/core/client/src/modules/actions/add-record/CustomizeAddRecordActionInitializer.tsx b/packages/core/client/src/modules/actions/add-record/CustomizeAddRecordActionInitializer.tsx index aa389c0de..bfb343674 100644 --- a/packages/core/client/src/modules/actions/add-record/CustomizeAddRecordActionInitializer.tsx +++ b/packages/core/client/src/modules/actions/add-record/CustomizeAddRecordActionInitializer.tsx @@ -21,7 +21,7 @@ export const CustomizeAddRecordActionInitializer = () => { title: '{{t("Add record")}}', 'x-component': 'Action.Container', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, properties: { tabs: { diff --git a/packages/core/client/src/modules/actions/disassociate/__e2e__/templatesOfPage.ts b/packages/core/client/src/modules/actions/disassociate/__e2e__/templatesOfPage.ts index b8ff791c8..dc735d76e 100644 --- a/packages/core/client/src/modules/actions/disassociate/__e2e__/templatesOfPage.ts +++ b/packages/core/client/src/modules/actions/disassociate/__e2e__/templatesOfPage.ts @@ -148,7 +148,7 @@ export const disassociatePage: PageConfig = { title: '{{ t("Edit record") }}', 'x-component': 'Action.Container', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, properties: { tabs: { diff --git a/packages/core/client/src/modules/actions/view-edit-popup/PopupActionInitializer.tsx b/packages/core/client/src/modules/actions/view-edit-popup/PopupActionInitializer.tsx index 313a04397..c388767f1 100644 --- a/packages/core/client/src/modules/actions/view-edit-popup/PopupActionInitializer.tsx +++ b/packages/core/client/src/modules/actions/view-edit-popup/PopupActionInitializer.tsx @@ -20,7 +20,7 @@ export const PopupActionInitializer = (props) => { title: '{{ t("Popup") }}', 'x-component': 'Action.Container', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, properties: { tabs: { diff --git a/packages/core/client/src/modules/actions/view-edit-popup/UpdateActionInitializer.tsx b/packages/core/client/src/modules/actions/view-edit-popup/UpdateActionInitializer.tsx index c7a1c5487..f0db1a42d 100644 --- a/packages/core/client/src/modules/actions/view-edit-popup/UpdateActionInitializer.tsx +++ b/packages/core/client/src/modules/actions/view-edit-popup/UpdateActionInitializer.tsx @@ -20,7 +20,7 @@ export const UpdateActionInitializer = (props) => { title: '{{ t("Edit record") }}', 'x-component': 'Action.Container', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, properties: { tabs: { diff --git a/packages/core/client/src/modules/actions/view-edit-popup/ViewActionInitializer.tsx b/packages/core/client/src/modules/actions/view-edit-popup/ViewActionInitializer.tsx index bf6347d28..957b5b387 100644 --- a/packages/core/client/src/modules/actions/view-edit-popup/ViewActionInitializer.tsx +++ b/packages/core/client/src/modules/actions/view-edit-popup/ViewActionInitializer.tsx @@ -19,7 +19,7 @@ export const ViewActionInitializer = (props) => { title: '{{ t("View record") }}', 'x-component': 'Action.Container', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, properties: { tabs: { diff --git a/packages/core/client/src/modules/blocks/data-blocks/form/__e2e__/form-create/templatesOfBug.ts b/packages/core/client/src/modules/blocks/data-blocks/form/__e2e__/form-create/templatesOfBug.ts index a62ed8480..4467ee0ff 100644 --- a/packages/core/client/src/modules/blocks/data-blocks/form/__e2e__/form-create/templatesOfBug.ts +++ b/packages/core/client/src/modules/blocks/data-blocks/form/__e2e__/form-create/templatesOfBug.ts @@ -410,7 +410,7 @@ export const T2174 = { title: '{{ t("View record") }}', 'x-component': 'Action.Container', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, 'x-index': 1, properties: { @@ -694,7 +694,7 @@ export const T2174 = { title: '{{ t("View record") }}', 'x-component': 'AssociationField.Viewer', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, 'x-index': 1, properties: { @@ -999,7 +999,7 @@ export const T2614: PageConfig = { title: '{{ t("View record") }}', 'x-component': 'Action.Container', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, properties: { tabs: { @@ -1328,7 +1328,7 @@ export const T2614: PageConfig = { title: '{{ t("Edit record") }}', 'x-component': 'Action.Container', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, properties: { tabs: { @@ -1803,7 +1803,7 @@ export const T2993: PageConfig = { title: '{{ t("Add record") }}', 'x-component': 'Action.Container', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, properties: { tabs: { @@ -2385,7 +2385,7 @@ export const T2615: PageConfig = { title: '{{ t("Add record") }}', 'x-component': 'Action.Container', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, properties: { tabs: { @@ -2666,7 +2666,7 @@ export const T2615: PageConfig = { title: '{{ t("Edit record") }}', 'x-component': 'Action.Container', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, properties: { tabs: { @@ -2909,7 +2909,7 @@ export const T2615: PageConfig = { title: '{{ t("View record") }}', 'x-component': 'Action.Container', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, properties: { tabs: { @@ -3293,7 +3293,7 @@ export const T2845: PageConfig = { title: '{{ t("Add record") }}', 'x-component': 'Action.Container', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, 'x-index': 1, properties: { @@ -3519,7 +3519,7 @@ export const T2845: PageConfig = { 'x-component-props': { className: - 'nb-action-popup', + 'tb-action-popup', }, 'x-index': 1, properties: { @@ -3618,7 +3618,7 @@ export const T2845: PageConfig = { 'x-component': 'AssociationField.Viewer', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, 'x-index': 2, properties: { @@ -3935,7 +3935,7 @@ export const T2845: PageConfig = { title: '{{ t("Edit record") }}', 'x-component': 'Action.Container', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, 'x-index': 1, properties: { @@ -4304,7 +4304,7 @@ export const T2845: PageConfig = { title: '{{ t("View record") }}', 'x-component': 'Action.Container', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, 'x-index': 1, properties: { @@ -4801,7 +4801,7 @@ export const T2200 = { title: '{{ t("Edit record") }}', 'x-component': 'Action.Container', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, properties: { tabs: { @@ -5822,7 +5822,7 @@ export const T3529: PageConfig = { title: '{{ t("View record") }}', 'x-component': 'Action.Container', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, properties: { tabs: { diff --git a/packages/core/client/src/modules/blocks/data-blocks/table-selector/__e2e__/templatesOfBug.ts b/packages/core/client/src/modules/blocks/data-blocks/table-selector/__e2e__/templatesOfBug.ts index 74d81ebef..50ad6e9cc 100644 --- a/packages/core/client/src/modules/blocks/data-blocks/table-selector/__e2e__/templatesOfBug.ts +++ b/packages/core/client/src/modules/blocks/data-blocks/table-selector/__e2e__/templatesOfBug.ts @@ -142,7 +142,7 @@ export const tableSelectorDataScopeVariable: PageConfig = { title: '{{ t("View record") }}', 'x-component': 'Action.Container', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, properties: { tabs: { @@ -263,7 +263,7 @@ export const tableSelectorDataScopeVariable: PageConfig = { '{{ t("Select record") }}', 'x-component-props': { className: - 'nb-record-picker-selector', + 'tb-record-picker-selector', }, 'x-index': 1, properties: { @@ -455,7 +455,7 @@ export const tableSelectorDataScopeVariable: PageConfig = { 'x-component-props': { className: - 'nb-action-popup', + 'tb-action-popup', }, properties: { diff --git a/packages/core/client/src/modules/blocks/data-blocks/table/__e2e__/templatesOfBug.ts b/packages/core/client/src/modules/blocks/data-blocks/table/__e2e__/templatesOfBug.ts index b8da7b390..5890c7820 100644 --- a/packages/core/client/src/modules/blocks/data-blocks/table/__e2e__/templatesOfBug.ts +++ b/packages/core/client/src/modules/blocks/data-blocks/table/__e2e__/templatesOfBug.ts @@ -445,7 +445,7 @@ export const T2187 = { title: '{{ t("Duplicate") }}', 'x-component': 'Action.Container', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, properties: { tabs: { @@ -839,7 +839,7 @@ export const T3686: PageConfig = { title: '{{ t("View record") }}', 'x-component': 'Action.Container', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, properties: { tabs: { diff --git a/packages/core/client/src/modules/dialog/__e2e__/templatesOfBug.ts b/packages/core/client/src/modules/dialog/__e2e__/templatesOfBug.ts index caf05e49a..e8876d894 100644 --- a/packages/core/client/src/modules/dialog/__e2e__/templatesOfBug.ts +++ b/packages/core/client/src/modules/dialog/__e2e__/templatesOfBug.ts @@ -133,7 +133,7 @@ export const T2797: PageConfig = { title: '{{ t("Popup") }}', 'x-component': 'Action.Container', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, 'x-index': 1, properties: { @@ -256,7 +256,7 @@ export const T2797: PageConfig = { title: '{{ t("Popup") }}', 'x-component': 'Action.Container', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, 'x-index': 1, properties: { @@ -712,7 +712,7 @@ export const T2838: PageConfig = { title: '{{ t("Edit record") }}', 'x-component': 'Action.Container', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, 'x-index': 1, properties: { @@ -825,7 +825,7 @@ export const T2838: PageConfig = { title: '{{ t("Edit record") }}', 'x-component': 'Action.Container', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, 'x-index': 1, properties: { @@ -992,7 +992,7 @@ export const T2838: PageConfig = { 'x-component-props': { className: - 'nb-action-popup', + 'tb-action-popup', }, 'x-index': 1, properties: @@ -1597,7 +1597,7 @@ export const tableWithRoles: PageConfig = { title: '{{ t("View record") }}', 'x-component': 'Action.Container', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, properties: { tabs: { @@ -1812,7 +1812,7 @@ export const tableWithUsers = { title: '{{ t("View record") }}', 'x-component': 'Action.Container', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, properties: { tabs: { @@ -2058,7 +2058,7 @@ export const tableWithInherit = { title: '{{ t("View record") }}', 'x-component': 'Action.Container', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, properties: { tabs: { @@ -2289,7 +2289,7 @@ export const tableWithInheritWithoutAssociation = { title: '{{ t("View record") }}', 'x-component': 'Action.Container', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, properties: { tabs: { diff --git a/packages/core/client/src/schema-component/antd/action/Action.Drawer.style.ts b/packages/core/client/src/schema-component/antd/action/Action.Drawer.style.ts index 60cb5e77e..0adb63d77 100644 --- a/packages/core/client/src/schema-component/antd/action/Action.Drawer.style.ts +++ b/packages/core/client/src/schema-component/antd/action/Action.Drawer.style.ts @@ -1,17 +1,17 @@ import { genStyleHook } from '../__builtins__'; -export const useStyles = genStyleHook('nb-action-drawer', (token) => { +export const useStyles = genStyleHook('tb-action-drawer', (token) => { const { componentCls } = token; return { [componentCls]: { overflow: 'hidden', '&.reset': { - '&.nb-action-popup': { + '&.tb-action-popup': { '.ant-drawer-header': { display: 'none' }, '.ant-drawer-body': { paddingTop: token.paddingContentVerticalLG, backgroundColor: 'var(--colorBgDrawer)' }, }, - '&.nb-record-picker-selector': { + '&.tb-record-picker-selector': { '.ant-drawer-wrapper-body': { backgroundColor: 'var(--colorBgDrawer)', }, diff --git a/packages/core/client/src/schema-component/antd/action/Action.Link.tsx b/packages/core/client/src/schema-component/antd/action/Action.Link.tsx index e7e4e1c1d..0c4bb43f9 100644 --- a/packages/core/client/src/schema-component/antd/action/Action.Link.tsx +++ b/packages/core/client/src/schema-component/antd/action/Action.Link.tsx @@ -10,7 +10,7 @@ import { ComposedAction } from './types'; export const ActionLink: ComposedAction = withDynamicSchemaProps( observer((props: any) => { return ( - + ); }), { displayName: 'ActionLink' }, diff --git a/packages/core/client/src/schema-component/antd/action/Action.Modal.tsx b/packages/core/client/src/schema-component/antd/action/Action.Modal.tsx index 4be7bc2ae..cd52a673b 100644 --- a/packages/core/client/src/schema-component/antd/action/Action.Modal.tsx +++ b/packages/core/client/src/schema-component/antd/action/Action.Modal.tsx @@ -14,7 +14,7 @@ import { ComposedActionDrawer } from './types'; const useStyles = createStyles(({ css }) => { return { container: css` - &.nb-action-popup { + &.tb-action-popup { .ant-modal-header { display: none; } diff --git a/packages/core/client/src/schema-component/antd/action/Action.Page.tsx b/packages/core/client/src/schema-component/antd/action/Action.Page.tsx index c210d0deb..07de4bfc1 100644 --- a/packages/core/client/src/schema-component/antd/action/Action.Page.tsx +++ b/packages/core/client/src/schema-component/antd/action/Action.Page.tsx @@ -43,7 +43,7 @@ export const ActionPage: ComposedActionDrawer = observer( {containerRef?.current && visible && createPortal( -
+
{ +const useStyles = genStyleHook('tb-action', (token) => { const { componentCls } = token; return { [componentCls]: { position: 'relative', '&:hover': { '> .general-schema-designer': { display: 'block' } }, - '&.nb-action-link': { + '&.tb-action-link': { margin: '-12px', padding: '12px', }, diff --git a/packages/core/client/src/schema-component/antd/action/Action.tsx b/packages/core/client/src/schema-component/antd/action/Action.tsx index 180a3eefe..c2699b7c7 100644 --- a/packages/core/client/src/schema-component/antd/action/Action.tsx +++ b/packages/core/client/src/schema-component/antd/action/Action.tsx @@ -147,7 +147,7 @@ export const Action: ComposedAction = withDynamicSchemaProps( style={buttonStyle} onClick={handleButtonClick} component={tarComponent || Button} - className={classnames(componentCls, hashId, className, 'nb-action')} + className={classnames(componentCls, hashId, className, 'tb-action')} type={props.type === 'danger' ? undefined : props.type} > {actionTitle} diff --git a/packages/core/client/src/schema-component/antd/action/ActionBar.tsx b/packages/core/client/src/schema-component/antd/action/ActionBar.tsx index a78fcf3ca..ce723ffa3 100644 --- a/packages/core/client/src/schema-component/antd/action/ActionBar.tsx +++ b/packages/core/client/src/schema-component/antd/action/ActionBar.tsx @@ -68,7 +68,7 @@ export const ActionBar = withDynamicSchemaProps(
{props.children && (
@@ -101,7 +101,7 @@ export const ActionBar = withDynamicSchemaProps( } } {...others} - className={cx(others.className, 'nb-action-bar')} + className={cx(others.className, 'tb-action-bar')} >
{ expect(document.querySelector('.ant-drawer')).not.toBeInTheDocument(); expect(document.querySelector('.ant-modal')).not.toBeInTheDocument(); - expect(document.querySelector('.nb-action-page')).not.toBeInTheDocument(); + expect(document.querySelector('.tb-action-page')).not.toBeInTheDocument(); // drawer await userEvent.click(getByText('Drawer')); @@ -63,7 +63,7 @@ describe('Action', () => { await waitFor(() => { expect(document.querySelector('.ant-drawer')).toBeInTheDocument(); expect(document.querySelector('.ant-modal')).not.toBeInTheDocument(); - expect(document.querySelector('.nb-action-page')).not.toBeInTheDocument(); + expect(document.querySelector('.tb-action-page')).not.toBeInTheDocument(); }); await userEvent.click(getByText('Close')); @@ -75,7 +75,7 @@ describe('Action', () => { await waitFor(() => { expect(document.querySelector('.ant-drawer')).not.toBeInTheDocument(); expect(document.querySelector('.ant-modal')).toBeInTheDocument(); - expect(document.querySelector('.nb-action-page')).not.toBeInTheDocument(); + expect(document.querySelector('.tb-action-page')).not.toBeInTheDocument(); }); await userEvent.click(getByText('Close')); @@ -87,12 +87,12 @@ describe('Action', () => { await waitFor(() => { expect(document.querySelector('.ant-drawer')).not.toBeInTheDocument(); expect(document.querySelector('.ant-modal')).not.toBeInTheDocument(); - expect(document.querySelector('.nb-action-page')).toBeInTheDocument(); + expect(document.querySelector('.tb-action-page')).toBeInTheDocument(); }); await userEvent.click(getByText('Close')); // TODO: 点击关闭按钮时应该消失 - // expect(document.querySelector('.nb-action-page')).not.toBeInTheDocument(); + // expect(document.querySelector('.tb-action-page')).not.toBeInTheDocument(); }); }); diff --git a/packages/core/client/src/schema-component/antd/association-field/schema.ts b/packages/core/client/src/schema-component/antd/association-field/schema.ts index 9ae7a8073..a7c9ebcc3 100644 --- a/packages/core/client/src/schema-component/antd/association-field/schema.ts +++ b/packages/core/client/src/schema-component/antd/association-field/schema.ts @@ -16,7 +16,7 @@ export default { 'x-action': 'create', title: '{{ t("Add record") }}', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, properties: { tabs: { @@ -49,7 +49,7 @@ export default { 'x-component': 'AssociationField.Selector', title: '{{ t("Select record") }}', 'x-component-props': { - className: 'nb-record-picker-selector', + className: 'tb-record-picker-selector', }, properties: { grid: { @@ -91,7 +91,7 @@ export default { title: '{{ t("View record") }}', 'x-component': 'AssociationField.Viewer', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, properties: { tabs: { diff --git a/packages/core/client/src/schema-component/antd/association-filter/AssociationFilter.Item.style.ts b/packages/core/client/src/schema-component/antd/association-filter/AssociationFilter.Item.style.ts index a14233b71..2f537a7fa 100644 --- a/packages/core/client/src/schema-component/antd/association-filter/AssociationFilter.Item.style.ts +++ b/packages/core/client/src/schema-component/antd/association-filter/AssociationFilter.Item.style.ts @@ -1,6 +1,6 @@ import { genStyleHook } from '../__builtins__'; -const useStyles = genStyleHook('nb-association-filter-item', (token) => { +const useStyles = genStyleHook('tb-association-filter-item', (token) => { const { componentCls } = token; return { diff --git a/packages/core/client/src/schema-component/antd/grid-card/GridCard.Decorator.style.ts b/packages/core/client/src/schema-component/antd/grid-card/GridCard.Decorator.style.ts index d43a0a101..c29acd370 100644 --- a/packages/core/client/src/schema-component/antd/grid-card/GridCard.Decorator.style.ts +++ b/packages/core/client/src/schema-component/antd/grid-card/GridCard.Decorator.style.ts @@ -1,12 +1,12 @@ import { genStyleHook } from '../__builtins__'; -const useStyles = genStyleHook('nb-grid-card', (token) => { +const useStyles = genStyleHook('tb-grid-card', (token) => { const { componentCls } = token; return { [componentCls]: { '& > .tb-block-item': { marginBottom: token.marginLG, - '& > .nb-action-bar:has(:first-child:not(:empty))': { + '& > .tb-action-bar:has(:first-child:not(:empty))': { padding: token.marginLG, background: token.colorBgContainer, }, diff --git a/packages/core/client/src/schema-component/antd/grid-card/GridCard.Item.tsx b/packages/core/client/src/schema-component/antd/grid-card/GridCard.Item.tsx index 023df983c..36b41f094 100644 --- a/packages/core/client/src/schema-component/antd/grid-card/GridCard.Item.tsx +++ b/packages/core/client/src/schema-component/antd/grid-card/GridCard.Item.tsx @@ -28,7 +28,7 @@ const useStyles = createStyles(({ css }) => { padding: 24px 24px 0px; height: 100%; } - .nb-action-bar { + .tb-action-bar { padding: 5px 0; } `, diff --git a/packages/core/client/src/schema-component/antd/grid-card/GridCard.tsx b/packages/core/client/src/schema-component/antd/grid-card/GridCard.tsx index d0d36ebfe..6963ef284 100644 --- a/packages/core/client/src/schema-component/antd/grid-card/GridCard.tsx +++ b/packages/core/client/src/schema-component/antd/grid-card/GridCard.tsx @@ -136,7 +136,7 @@ const InternalGridCard = (props) => { useGridCardActionBarProps, }} > - + { +const useStyles = genStyleHook('tb-grid', (token) => { const { componentCls } = token; return { diff --git a/packages/core/client/src/schema-component/antd/grid/Grid.tsx b/packages/core/client/src/schema-component/antd/grid/Grid.tsx index 58c3a296e..db23242e7 100644 --- a/packages/core/client/src/schema-component/antd/grid/Grid.tsx +++ b/packages/core/client/src/schema-component/antd/grid/Grid.tsx @@ -158,7 +158,7 @@ const ColDivider = (props) => { dividerRef.current = el; } }} - className={cls('nb-col-divider', 'ColDivider')} + className={cls('tb-col-divider', 'ColDivider')} style={droppableStyle} >
{ }); return ( - + ); }; @@ -332,7 +332,7 @@ export const Grid: any = observer( -
+
{showDivider ? (
@@ -504,7 +504,7 @@ Grid.Col = observer( return ( -
+
{props.children}
diff --git a/packages/core/client/src/schema-component/antd/input-number/ReadPretty.tsx b/packages/core/client/src/schema-component/antd/input-number/ReadPretty.tsx index b470ff316..35c597d31 100644 --- a/packages/core/client/src/schema-component/antd/input-number/ReadPretty.tsx +++ b/packages/core/client/src/schema-component/antd/input-number/ReadPretty.tsx @@ -119,7 +119,7 @@ export const ReadPretty: React.FC = (props: any) } return ( -
+
{addonBefore} {addonAfter} diff --git a/packages/core/client/src/schema-component/antd/list/List.Item.tsx b/packages/core/client/src/schema-component/antd/list/List.Item.tsx index 8132f2790..5449a6fad 100644 --- a/packages/core/client/src/schema-component/antd/list/List.Item.tsx +++ b/packages/core/client/src/schema-component/antd/list/List.Item.tsx @@ -12,7 +12,7 @@ import { useDesignable } from '../../hooks'; const useStyles = createStyles(({ css }, props: { designable: boolean }) => { return { item: css` - .nb-action-bar { + .tb-action-bar { gap: 20px !important; margin-top: ${props.designable ? '20px' : '0px'}; } diff --git a/packages/core/client/src/schema-component/antd/list/List.style.ts b/packages/core/client/src/schema-component/antd/list/List.style.ts index df67186a3..b309c6d40 100644 --- a/packages/core/client/src/schema-component/antd/list/List.style.ts +++ b/packages/core/client/src/schema-component/antd/list/List.style.ts @@ -1,12 +1,12 @@ import { genStyleHook } from '../__builtins__'; -const useStyles = genStyleHook('nb-list', (token) => { +const useStyles = genStyleHook('tb-list', (token) => { const { componentCls } = token; return { [componentCls]: { width: '100%', marginBottom: 0, - // '.nb-action-bar:not(:empty)': { marginTop: token.marginXS }, + // '.tb-action-bar:not(:empty)': { marginTop: token.marginXS }, '&:hover': { '> .general-schema-designer': { display: 'block' } }, '> .general-schema-designer': { position: 'absolute', diff --git a/packages/core/client/src/schema-component/antd/list/List.tsx b/packages/core/client/src/schema-component/antd/list/List.tsx index 47b2b443c..af262742b 100644 --- a/packages/core/client/src/schema-component/antd/list/List.tsx +++ b/packages/core/client/src/schema-component/antd/list/List.tsx @@ -60,7 +60,7 @@ const InternalList = (props) => { useListActionBarProps, }} > - + ) : (
diff --git a/packages/core/client/src/schema-component/antd/markdown/Markdown.tsx b/packages/core/client/src/schema-component/antd/markdown/Markdown.tsx index 0ae171fd9..a432d32f6 100644 --- a/packages/core/client/src/schema-component/antd/markdown/Markdown.tsx +++ b/packages/core/client/src/schema-component/antd/markdown/Markdown.tsx @@ -32,7 +32,7 @@ export const MarkdownReadPretty = (props) => { const text = convertToText(html); const value = (
); diff --git a/packages/core/client/src/schema-component/antd/markdown/style.ts b/packages/core/client/src/schema-component/antd/markdown/style.ts index 4fc2a8d61..58b47ee08 100644 --- a/packages/core/client/src/schema-component/antd/markdown/style.ts +++ b/packages/core/client/src/schema-component/antd/markdown/style.ts @@ -2,7 +2,7 @@ import { TinyColor } from '@ctrl/tinycolor'; import { genStyleHook } from './../__builtins__'; -export const useStyles = genStyleHook('nb-markdown', (token, { isDarkTheme }) => { +export const useStyles = genStyleHook('tb-markdown', (token, { isDarkTheme }) => { const { componentCls } = token; const colorFillAlterSolid = new TinyColor(token.colorFillAlter) .onBackground(token.colorBgContainer) @@ -10,7 +10,7 @@ export const useStyles = genStyleHook('nb-markdown', (token, { isDarkTheme }) => const defaultStyle: any = { // default style of markdown - '&.nb-markdown-default': { + '&.tb-markdown-default': { 'pre code.hljs': { display: 'block', overflowX: 'auto', padding: '1em' }, 'code.hljs': { padding: '3px 5px' }, ':not(pre) code': { @@ -55,7 +55,7 @@ export const useStyles = genStyleHook('nb-markdown', (token, { isDarkTheme }) => }, // table style of markdown - '&.nb-markdown-table': { + '&.tb-markdown-table': { table: { borderCollapse: 'collapse', width: '100%', @@ -80,7 +80,7 @@ export const useStyles = genStyleHook('nb-markdown', (token, { isDarkTheme }) => const darkStyle: any = { // default style of markdown - '&.nb-markdown-default': { + '&.tb-markdown-default': { 'pre code.hljs': { display: 'block', overflowX: 'auto', padding: '1em' }, 'code.hljs': { padding: '3px 5px' }, ':not(pre) code': { @@ -118,7 +118,7 @@ export const useStyles = genStyleHook('nb-markdown', (token, { isDarkTheme }) => }, // table style of markdown - '&.nb-markdown-table': { + '&.tb-markdown-table': { table: { borderCollapse: 'collapse', width: '100%', diff --git a/packages/core/client/src/schema-component/antd/menu/Menu.styles.ts b/packages/core/client/src/schema-component/antd/menu/Menu.styles.ts index 2b045ee53..a5118450e 100644 --- a/packages/core/client/src/schema-component/antd/menu/Menu.styles.ts +++ b/packages/core/client/src/schema-component/antd/menu/Menu.styles.ts @@ -17,7 +17,7 @@ export const useStyles = createStyles(({ css, token }) => { display: block; } } - &.nb-action-link { + &.tb-action-link { > .general-schema-designer { top: -10px; bottom: -10px; @@ -69,7 +69,7 @@ export const useStyles = createStyles(({ css, token }) => { display: block; } } - &.nb-action-link { + &.tb-action-link { > .general-schema-designer { top: -10px; bottom: -10px; diff --git a/packages/core/client/src/schema-component/antd/page/FixedBlock.tsx b/packages/core/client/src/schema-component/antd/page/FixedBlock.tsx index 0d08d661e..b2e632589 100644 --- a/packages/core/client/src/schema-component/antd/page/FixedBlock.tsx +++ b/packages/core/client/src/schema-component/antd/page/FixedBlock.tsx @@ -47,7 +47,7 @@ export const FixedBlockWrapper = (props) => { if (!fixedBlock && fixedBlockUID) return <>{props.children}; return (
{ {schema['x-icon'] && } {schema.title || t('Unnamed')} @@ -179,7 +179,7 @@ export const Page = (props) => { /> )}
-
+
{PageContent(loading, disablePageHeader, enablePageTabs, fieldSchema, activeKey, height, props)} @@ -226,7 +226,7 @@ function PageContent( }) ) : ( -
{props.children}
+
{props.children}
); } diff --git a/packages/core/client/src/schema-component/antd/page/style.ts b/packages/core/client/src/schema-component/antd/page/style.ts index 9da11333f..d1e607755 100644 --- a/packages/core/client/src/schema-component/antd/page/style.ts +++ b/packages/core/client/src/schema-component/antd/page/style.ts @@ -1,6 +1,6 @@ import { genStyleHook } from './../__builtins__'; -export const useStyles = genStyleHook('nb-page', (token) => { +export const useStyles = genStyleHook('tb-page', (token) => { const { componentCls } = token; return { @@ -67,7 +67,7 @@ export const useStyles = genStyleHook('nb-page', (token) => { '.designerCss': { position: 'relative', '&:hover': { '> .general-schema-designer': { display: 'block' } }, - '&.nb-action-link': { + '&.tb-action-link': { '> .general-schema-designer': { top: '-10px', bottom: '-10px', @@ -105,12 +105,12 @@ export const useStyles = genStyleHook('nb-page', (token) => { '.pageWithFixedBlockCss': { height: '100%', - '> .nb-grid:not(:last-child)': { - '> .nb-schema-initializer-button': { display: 'none' }, + '> .tb-grid:not(:last-child)': { + '> .tb-schema-initializer-button': { display: 'none' }, }, }, - '.nb-page-wrapper': { + '.tb-page-wrapper': { margin: token.marginLG, flex: 1, }, diff --git a/packages/core/client/src/schema-component/antd/preview/Preview.tsx b/packages/core/client/src/schema-component/antd/preview/Preview.tsx index 9f42a8e9b..ca9c7a090 100644 --- a/packages/core/client/src/schema-component/antd/preview/Preview.tsx +++ b/packages/core/client/src/schema-component/antd/preview/Preview.tsx @@ -59,7 +59,7 @@ export const FileSelector = (props: Props) => { return wrapSSR(
-
+
{list.map((file) => { const handleClick = (e) => { diff --git a/packages/core/client/src/schema-component/antd/record-picker/demos/demo1.tsx b/packages/core/client/src/schema-component/antd/record-picker/demos/demo1.tsx index e242faa84..35146b856 100644 --- a/packages/core/client/src/schema-component/antd/record-picker/demos/demo1.tsx +++ b/packages/core/client/src/schema-component/antd/record-picker/demos/demo1.tsx @@ -73,7 +73,7 @@ const schema: ISchema = { title: '{{ t("Select record") }}', 'x-component': 'RecordPicker.Selector', 'x-component-props': { - className: 'nb-record-picker-selector', + className: 'tb-record-picker-selector', }, properties: { tableBlock: { diff --git a/packages/core/client/src/schema-component/antd/rich-text/style.ts b/packages/core/client/src/schema-component/antd/rich-text/style.ts index c85f9fbc0..c27addcab 100644 --- a/packages/core/client/src/schema-component/antd/rich-text/style.ts +++ b/packages/core/client/src/schema-component/antd/rich-text/style.ts @@ -6,7 +6,7 @@ import { genStyleHook } from './../__builtins__'; * Copyright (c) 2014, Jason Chen * Copyright (c) 2013, salesforce.com */ -export const useStyles = genStyleHook('nb-rich-text', (token) => { +export const useStyles = genStyleHook('tb-rich-text', (token) => { const { componentCls } = token; return { diff --git a/packages/core/client/src/schema-component/antd/table-v2/Table.styles.ts b/packages/core/client/src/schema-component/antd/table-v2/Table.styles.ts index a962e506d..79ddd2e52 100644 --- a/packages/core/client/src/schema-component/antd/table-v2/Table.styles.ts +++ b/packages/core/client/src/schema-component/antd/table-v2/Table.styles.ts @@ -30,7 +30,7 @@ export const useStyles = createStyles(({ css, token }) => { `, toolbar: css` // 扩大 SchemaToolbar 的面积 - .nb-action-link { + .tb-action-link { margin: -${token.paddingContentVerticalLG}px -${token.marginSM}px; padding: ${token.paddingContentVerticalLG}px ${token.marginSM}px; } @@ -64,7 +64,7 @@ export const useStyles = createStyles(({ css, token }) => { bodyCell: css` max-width: 300px; white-space: nowrap; - .nb-read-pretty-input-number { + .tb-read-pretty-input-number { text-align: right; } .ant-color-picker-trigger { @@ -80,21 +80,21 @@ export const useStyles = createStyles(({ css, token }) => { align-items: center; justify-content: space-evenly; padding-right: 8px; - .nb-table-index { + .tb-table-index { opacity: 0; } &:not(.checked) { - .nb-table-index { + .tb-table-index { opacity: 1; } } `, rowSelectHover: css` &:hover { - .nb-table-index { + .tb-table-index { opacity: 0; } - .nb-origin-node { + .tb-origin-node { display: block; } } diff --git a/packages/core/client/src/schema-component/antd/table-v2/Table.tsx b/packages/core/client/src/schema-component/antd/table-v2/Table.tsx index 17a252fff..2a8f8bb7d 100644 --- a/packages/core/client/src/schema-component/antd/table-v2/Table.tsx +++ b/packages/core/client/src/schema-component/antd/table-v2/Table.tsx @@ -212,7 +212,7 @@ const SortHandle = (props) => { const TableIndex = (props) => { const { index, ...otherProps } = props; return ( -
+
{index}
); @@ -432,7 +432,7 @@ export const Table: any = withDynamicSchemaProps( {showIndex && }
{isRowSelect && ( -
+
{originNode}
)} diff --git a/packages/core/client/src/schema-component/antd/table/Table.Array.tsx b/packages/core/client/src/schema-component/antd/table/Table.Array.tsx index 33ad625f7..47fb3204f 100644 --- a/packages/core/client/src/schema-component/antd/table/Table.Array.tsx +++ b/packages/core/client/src/schema-component/antd/table/Table.Array.tsx @@ -61,19 +61,19 @@ const useStyles = createStyles(({ css, token }) => { align-items: center; justify-content: space-evenly; padding-right: 8px; - .nb-table-index { + .tb-table-index { opacity: 0; } &:not(.checked) { - .nb-table-index { + .tb-table-index { opacity: 1; } } &:hover { - .nb-table-index { + .tb-table-index { opacity: 0; } - .nb-origin-node { + .tb-origin-node { display: block; } } @@ -159,7 +159,7 @@ const SortHandle = (props) => { const TableIndex = (props) => { const { index, ...otherProps } = props; return ( -
+
{index + 1}
); @@ -250,7 +250,7 @@ export const TableArray: React.FC = observer( )}
-
+
{originNode}
diff --git a/packages/core/client/src/schema-component/antd/tabs/Tabs.tsx b/packages/core/client/src/schema-component/antd/tabs/Tabs.tsx index acb3be742..8c1822b09 100644 --- a/packages/core/client/src/schema-component/antd/tabs/Tabs.tsx +++ b/packages/core/client/src/schema-component/antd/tabs/Tabs.tsx @@ -21,7 +21,7 @@ const useStyles = createStyles(({ css }) => { display: block; } } - &.nb-action-link { + &.tb-action-link { > .general-schema-designer { top: -10px; bottom: -10px; @@ -108,7 +108,7 @@ Tabs.TabPane = observer( const Designer = useDesigner(); const field = useField(); return ( - + {props.icon && } {props.tab || field.title} diff --git a/packages/core/client/src/schema-component/antd/upload/ReadPretty.tsx b/packages/core/client/src/schema-component/antd/upload/ReadPretty.tsx index f2b7f12b8..1f128cde0 100644 --- a/packages/core/client/src/schema-component/antd/upload/ReadPretty.tsx +++ b/packages/core/client/src/schema-component/antd/upload/ReadPretty.tsx @@ -43,8 +43,8 @@ ReadPretty.File = function File(props: UploadProps) { className={cls( `${prefixCls}-wrapper`, `${prefixCls}-picture-card-wrapper`, - `nb-upload`, - size ? `nb-upload-${size}` : null, + `tb-upload`, + size ? `tb-upload-${size}` : null, hashId, )} > diff --git a/packages/core/client/src/schema-component/antd/upload/Upload.tsx b/packages/core/client/src/schema-component/antd/upload/Upload.tsx index cf0a1ce37..df0e22405 100644 --- a/packages/core/client/src/schema-component/antd/upload/Upload.tsx +++ b/packages/core/client/src/schema-component/antd/upload/Upload.tsx @@ -49,7 +49,7 @@ Upload.Attachment = connect((props: UploadProps) => { return wrapSSR(
-
+
{fileList.map((file, index) => { const fileProps = { diff --git a/packages/core/client/src/schema-component/antd/upload/style.ts b/packages/core/client/src/schema-component/antd/upload/style.ts index 01e4bc423..e667b1f2b 100644 --- a/packages/core/client/src/schema-component/antd/upload/style.ts +++ b/packages/core/client/src/schema-component/antd/upload/style.ts @@ -5,7 +5,7 @@ export const useStyles = genStyleHook('upload', (token) => { return { [`${componentCls}-wrapper`]: { - '&.nb-upload-small': { + '&.tb-upload-small': { [`${componentCls}-list-picture-card-container${componentCls}-list-picture-card-container`]: { margin: '0 3px 3px 0 !important', height: '32px !important', @@ -20,7 +20,7 @@ export const useStyles = genStyleHook('upload', (token) => { padding: '1px !important', }, }, - '&.nb-upload-large': { + '&.tb-upload-large': { [`${componentCls}-list-picture-card-container${componentCls}-list-picture-card-container`]: { margin: '0 3px 3px 0 !important', height: '160px !important', @@ -28,7 +28,7 @@ export const useStyles = genStyleHook('upload', (token) => { marginBlock: '0 28px !important', }, }, - '&.nb-upload': { + '&.tb-upload': { [`${componentCls}-list-item${componentCls}-list-item-list-type-picture-card`]: { padding: '3px !important', }, diff --git a/packages/core/client/src/schema-component/antd/variable/VariableSelect.style.ts b/packages/core/client/src/schema-component/antd/variable/VariableSelect.style.ts index b1bfa32cc..2c1498ece 100644 --- a/packages/core/client/src/schema-component/antd/variable/VariableSelect.style.ts +++ b/packages/core/client/src/schema-component/antd/variable/VariableSelect.style.ts @@ -1,6 +1,6 @@ import { genStyleHook } from '../__builtins__'; -const useStyles = genStyleHook('nb-variable-select', (token) => { +const useStyles = genStyleHook('tb-variable-select', (token) => { const { componentCls } = token; return { diff --git a/packages/core/client/src/schema-component/common/sortable-item/SortableItem.tsx b/packages/core/client/src/schema-component/common/sortable-item/SortableItem.tsx index 0f7c2c1f0..1805d43bd 100644 --- a/packages/core/client/src/schema-component/common/sortable-item/SortableItem.tsx +++ b/packages/core/client/src/schema-component/common/sortable-item/SortableItem.tsx @@ -44,7 +44,7 @@ export const Sortable = (props: any) => { { role: 'none', ...others, - className: cx('nb-sortable-designer', props.className), + className: cx('tb-sortable-designer', props.className), ref: setNodeRef, style: droppableStyle, }, diff --git a/packages/core/client/src/schema-initializer/items/SelectActionInitializer.tsx b/packages/core/client/src/schema-initializer/items/SelectActionInitializer.tsx index c9dba9525..1fc2df0ba 100644 --- a/packages/core/client/src/schema-initializer/items/SelectActionInitializer.tsx +++ b/packages/core/client/src/schema-initializer/items/SelectActionInitializer.tsx @@ -18,7 +18,7 @@ export const SelectActionInitializer = (props) => { 'x-component': 'AssociationField.Selector', title: '{{ t("Select record") }}', 'x-component-props': { - className: 'nb-record-picker-selector', + className: 'tb-record-picker-selector', }, properties: { grid: { diff --git a/packages/core/client/src/schema-templates/schemas/uiSchemaTemplates.ts b/packages/core/client/src/schema-templates/schemas/uiSchemaTemplates.ts index 820ff33aa..291e8a688 100644 --- a/packages/core/client/src/schema-templates/schemas/uiSchemaTemplates.ts +++ b/packages/core/client/src/schema-templates/schemas/uiSchemaTemplates.ts @@ -120,7 +120,7 @@ export const uiSchemaTemplatesSchema: ISchema = { title: '{{ t("Edit record") }}', 'x-component': 'Action.Container', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, properties: { form: { diff --git a/packages/core/test/src/e2e/templatesOfPage.ts b/packages/core/test/src/e2e/templatesOfPage.ts index 918da263f..216140603 100644 --- a/packages/core/test/src/e2e/templatesOfPage.ts +++ b/packages/core/test/src/e2e/templatesOfPage.ts @@ -1290,7 +1290,7 @@ export const oneEmptyTableBlockWithActions: PageConfig = { title: '{{ t("Add record") }}', 'x-component': 'Action.Container', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, properties: { tabs: { @@ -1409,7 +1409,7 @@ export const oneEmptyTableBlockWithActions: PageConfig = { title: '{{t("Add record")}}', 'x-component': 'Action.Container', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, properties: { tabs: { @@ -1522,7 +1522,7 @@ export const oneEmptyTableBlockWithActions: PageConfig = { title: '{{ t("View record") }}', 'x-component': 'Action.Container', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, properties: { tabs: { @@ -1596,7 +1596,7 @@ export const oneEmptyTableBlockWithActions: PageConfig = { title: '{{ t("Edit record") }}', 'x-component': 'Action.Container', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, properties: { tabs: { @@ -1695,7 +1695,7 @@ export const oneEmptyTableBlockWithActions: PageConfig = { title: '{{ t("Duplicate") }}', 'x-component': 'Action.Container', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, properties: { tabs: { @@ -1897,7 +1897,7 @@ export const oneTableBlockWithActionsAndFormBlocks: PageConfig = { title: '{{ t("Add record") }}', 'x-component': 'Action.Container', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, properties: { tabs: { @@ -2102,7 +2102,7 @@ export const oneTableBlockWithActionsAndFormBlocks: PageConfig = { title: '{{t("Add record")}}', 'x-component': 'Action.Container', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, properties: { tabs: { @@ -2302,7 +2302,7 @@ export const oneTableBlockWithActionsAndFormBlocks: PageConfig = { title: '{{ t("View record") }}', 'x-component': 'Action.Container', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, properties: { tabs: { @@ -2462,7 +2462,7 @@ export const oneTableBlockWithActionsAndFormBlocks: PageConfig = { title: '{{ t("Edit record") }}', 'x-component': 'Action.Container', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, properties: { tabs: { @@ -2738,7 +2738,7 @@ export const oneEmptyTableBlockWithCustomizeActions: PageConfig = { title: '{{t("Bulk edit")}}', 'x-component': 'Action.Container', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, properties: { tabs: { @@ -2962,7 +2962,7 @@ export const oneFormBlockWithRolesFieldBasedUsers: PageConfig = { 'x-component': 'AssociationField.Selector', title: '{{ t("Select record") }}', 'x-component-props': { - className: 'nb-record-picker-selector', + className: 'tb-record-picker-selector', }, 'x-index': 1, properties: { @@ -3179,7 +3179,7 @@ export const oneFormBlockWithAllAssociationFieldsAndSelectorMode: PageConfig = { 'x-component': 'AssociationField.Selector', title: '{{ t("Select record") }}', 'x-component-props': { - className: 'nb-record-picker-selector', + className: 'tb-record-picker-selector', }, 'x-index': 1, properties: { @@ -3282,7 +3282,7 @@ export const oneFormBlockWithAllAssociationFieldsAndSelectorMode: PageConfig = { 'x-component': 'AssociationField.Selector', title: '{{ t("Select record") }}', 'x-component-props': { - className: 'nb-record-picker-selector', + className: 'tb-record-picker-selector', }, 'x-index': 1, properties: { @@ -3385,7 +3385,7 @@ export const oneFormBlockWithAllAssociationFieldsAndSelectorMode: PageConfig = { 'x-component': 'AssociationField.Selector', title: '{{ t("Select record") }}', 'x-component-props': { - className: 'nb-record-picker-selector', + className: 'tb-record-picker-selector', }, 'x-index': 1, properties: { @@ -3488,7 +3488,7 @@ export const oneFormBlockWithAllAssociationFieldsAndSelectorMode: PageConfig = { 'x-component': 'AssociationField.Selector', title: '{{ t("Select record") }}', 'x-component-props': { - className: 'nb-record-picker-selector', + className: 'tb-record-picker-selector', }, 'x-index': 1, properties: { @@ -3591,7 +3591,7 @@ export const oneFormBlockWithAllAssociationFieldsAndSelectorMode: PageConfig = { 'x-component': 'AssociationField.Selector', title: '{{ t("Select record") }}', 'x-component-props': { - className: 'nb-record-picker-selector', + className: 'tb-record-picker-selector', }, 'x-index': 1, properties: { @@ -3976,7 +3976,7 @@ export const oneTableBlockWithAddNewAndViewAndEditAndBasicFields: PageConfig = { title: '{{ t("Add record") }}', 'x-component': 'Action.Container', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, properties: { tabs: { @@ -4589,7 +4589,7 @@ export const oneTableBlockWithAddNewAndViewAndEditAndBasicFields: PageConfig = { title: '{{ t("View record") }}', 'x-component': 'Action.Container', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, properties: { tabs: { @@ -4689,7 +4689,7 @@ export const oneTableBlockWithAddNewAndViewAndEditAndBasicFields: PageConfig = { title: '{{ t("Edit record") }}', 'x-component': 'Action.Container', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, properties: { tabs: { @@ -5226,7 +5226,7 @@ export const oneTableBlockWithAddNewAndViewAndEditAndBasicFields: PageConfig = { title: '{{ t("Edit record") }}', 'x-component': 'Action.Container', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, properties: { tabs: { @@ -5978,7 +5978,7 @@ export const oneTableBlockWithAddNewAndViewAndEditAndBasicFieldsAndSubTable: Pag title: '{{ t("Edit record") }}', 'x-component': 'Action.Container', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, properties: { tabs: { @@ -6352,7 +6352,7 @@ export const oneTableBlockWithAddNewAndViewAndEditAndChoicesFields: PageConfig = title: '{{ t("Add record") }}', 'x-component': 'Action.Container', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, properties: { tabs: { @@ -6801,7 +6801,7 @@ export const oneTableBlockWithAddNewAndViewAndEditAndChoicesFields: PageConfig = title: '{{ t("View record") }}', 'x-component': 'Action.Container', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, properties: { tabs: { @@ -6901,7 +6901,7 @@ export const oneTableBlockWithAddNewAndViewAndEditAndChoicesFields: PageConfig = title: '{{ t("Edit record") }}', 'x-component': 'Action.Container', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, properties: { tabs: { @@ -7263,7 +7263,7 @@ export const oneTableBlockWithAddNewAndViewAndEditAndChoicesFields: PageConfig = title: '{{ t("Edit record") }}', 'x-component': 'Action.Container', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, properties: { tabs: { @@ -7787,7 +7787,7 @@ export const oneTableBlockWithAddNewAndViewAndEditAndMediaFields: PageConfig = { title: '{{ t("Add record") }}', 'x-component': 'Action.Container', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, properties: { tabs: { @@ -8119,7 +8119,7 @@ export const oneTableBlockWithAddNewAndViewAndEditAndMediaFields: PageConfig = { title: '{{ t("View record") }}', 'x-component': 'Action.Container', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, properties: { tabs: { @@ -8219,7 +8219,7 @@ export const oneTableBlockWithAddNewAndViewAndEditAndMediaFields: PageConfig = { title: '{{ t("Edit record") }}', 'x-component': 'Action.Container', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, properties: { tabs: { @@ -8467,7 +8467,7 @@ export const oneTableBlockWithAddNewAndViewAndEditAndMediaFields: PageConfig = { title: '{{ t("Edit record") }}', 'x-component': 'Action.Container', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, properties: { tabs: { @@ -8877,7 +8877,7 @@ export const oneTableBlockWithAddNewAndViewAndEditAndDatetimeFields: PageConfig title: '{{ t("Add record") }}', 'x-component': 'Action.Container', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, properties: { tabs: { @@ -9172,7 +9172,7 @@ export const oneTableBlockWithAddNewAndViewAndEditAndDatetimeFields: PageConfig title: '{{ t("View record") }}', 'x-component': 'Action.Container', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, properties: { tabs: { @@ -9272,7 +9272,7 @@ export const oneTableBlockWithAddNewAndViewAndEditAndDatetimeFields: PageConfig title: '{{ t("Edit record") }}', 'x-component': 'Action.Container', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, properties: { tabs: { @@ -9482,7 +9482,7 @@ export const oneTableBlockWithAddNewAndViewAndEditAndDatetimeFields: PageConfig title: '{{ t("Edit record") }}', 'x-component': 'Action.Container', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, properties: { tabs: { @@ -9854,7 +9854,7 @@ export const oneTableBlockWithAddNewAndViewAndEditAndAssociationFields: PageConf title: '{{ t("Add record") }}', 'x-component': 'Action.Container', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, properties: { tabs: { @@ -10256,7 +10256,7 @@ export const oneTableBlockWithAddNewAndViewAndEditAndAssociationFields: PageConf title: '{{ t("View record") }}', 'x-component': 'Action.Container', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, properties: { tabs: { @@ -10356,7 +10356,7 @@ export const oneTableBlockWithAddNewAndViewAndEditAndAssociationFields: PageConf title: '{{ t("Edit record") }}', 'x-component': 'Action.Container', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, properties: { tabs: { @@ -10674,7 +10674,7 @@ export const oneTableBlockWithAddNewAndViewAndEditAndAssociationFields: PageConf title: '{{ t("Edit record") }}', 'x-component': 'Action.Container', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, properties: { tabs: { @@ -11477,7 +11477,7 @@ export const oneTableBlockWithAddNewAndViewAndEditAndAdvancedFields: PageConfig title: '{{ t("Add record") }}', 'x-component': 'Action.Container', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, properties: { tabs: { @@ -11849,7 +11849,7 @@ export const oneTableBlockWithAddNewAndViewAndEditAndAdvancedFields: PageConfig title: '{{ t("View record") }}', 'x-component': 'Action.Container', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, properties: { tabs: { @@ -11949,7 +11949,7 @@ export const oneTableBlockWithAddNewAndViewAndEditAndAdvancedFields: PageConfig title: '{{ t("Edit record") }}', 'x-component': 'Action.Container', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, properties: { tabs: { @@ -12238,7 +12238,7 @@ export const oneTableBlockWithAddNewAndViewAndEditAndAdvancedFields: PageConfig title: '{{ t("Edit record") }}', 'x-component': 'Action.Container', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, properties: { tabs: { @@ -12689,7 +12689,7 @@ export const oneTableBlockWithAddNewAndViewAndEditAndSystemInfoFields: PageConfi title: '{{ t("Add record") }}', 'x-component': 'Action.Container', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, properties: { tabs: { @@ -12864,7 +12864,7 @@ export const oneTableBlockWithAddNewAndViewAndEditAndSystemInfoFields: PageConfi title: '{{ t("View record") }}', 'x-component': 'RecordPicker.Viewer', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, properties: { tabs: { @@ -12956,7 +12956,7 @@ export const oneTableBlockWithAddNewAndViewAndEditAndSystemInfoFields: PageConfi title: '{{ t("View record") }}', 'x-component': 'RecordPicker.Viewer', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, properties: { tabs: { @@ -13243,7 +13243,7 @@ export const oneTableBlockWithAddNewAndViewAndEditAndSystemInfoFields: PageConfi title: '{{ t("View record") }}', 'x-component': 'Action.Container', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, properties: { tabs: { @@ -13343,7 +13343,7 @@ export const oneTableBlockWithAddNewAndViewAndEditAndSystemInfoFields: PageConfi title: '{{ t("Edit record") }}', 'x-component': 'Action.Container', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, properties: { tabs: { @@ -13513,7 +13513,7 @@ export const oneTableBlockWithAddNewAndViewAndEditAndSystemInfoFields: PageConfi 'x-component': 'RecordPicker.Viewer', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, properties: { tabs: { @@ -13614,7 +13614,7 @@ export const oneTableBlockWithAddNewAndViewAndEditAndSystemInfoFields: PageConfi 'x-component': 'RecordPicker.Viewer', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, properties: { tabs: { @@ -13830,7 +13830,7 @@ export const oneTableBlockWithAddNewAndViewAndEditAndSystemInfoFields: PageConfi title: '{{ t("Edit record") }}', 'x-component': 'Action.Container', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, properties: { tabs: { @@ -14011,7 +14011,7 @@ export const oneTableBlockWithAddNewAndViewAndEditAndSystemInfoFields: PageConfi 'x-component': 'RecordPicker.Viewer', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, properties: { tabs: { @@ -14112,7 +14112,7 @@ export const oneTableBlockWithAddNewAndViewAndEditAndSystemInfoFields: PageConfi 'x-component': 'RecordPicker.Viewer', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, properties: { tabs: { @@ -15475,7 +15475,7 @@ export const oneTableSubformWithMultiLevelAssociationFields: PageConfig = { title: '{{ t("Add record") }}', 'x-component': 'Action.Container', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, properties: { tabs: { @@ -15590,7 +15590,7 @@ export const oneTableSubformWithMultiLevelAssociationFields: PageConfig = { title: '{{ t("View record") }}', 'x-component': 'Action.Container', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, properties: { tabs: { @@ -16271,7 +16271,7 @@ export const oneTableSubformWithMultiLevelAssociationFields: PageConfig = { title: '{{ t("Edit record") }}', 'x-component': 'Action.Container', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, properties: { tabs: { @@ -17189,7 +17189,7 @@ export const oneTableSubtableWithMultiLevelAssociationFields: PageConfig = { title: '{{ t("Add record") }}', 'x-component': 'Action.Container', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, properties: { tabs: { @@ -17304,7 +17304,7 @@ export const oneTableSubtableWithMultiLevelAssociationFields: PageConfig = { title: '{{ t("View record") }}', 'x-component': 'Action.Container', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, properties: { tabs: { @@ -17404,7 +17404,7 @@ export const oneTableSubtableWithMultiLevelAssociationFields: PageConfig = { title: '{{ t("Edit record") }}', 'x-component': 'Action.Container', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, properties: { tabs: { @@ -17735,7 +17735,7 @@ export const oneTableSubtableWithMultiLevelAssociationFields: PageConfig = { title: '{{ t("Edit record") }}', 'x-component': 'Action.Container', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, properties: { tabs: { @@ -18201,7 +18201,7 @@ export const formBlockDefaultValueTemplate: PageConfig = { title: '{{ t("Add record") }}', 'x-component': 'Action.Container', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, properties: { tabs: { @@ -18477,7 +18477,7 @@ export const formBlockDefaultValueTemplate: PageConfig = { title: '{{ t("View record") }}', 'x-component': 'Action.Container', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, properties: { tabs: { @@ -18551,7 +18551,7 @@ export const formBlockDefaultValueTemplate: PageConfig = { title: '{{ t("Edit record") }}', 'x-component': 'Action.Container', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, properties: { tabs: { diff --git a/packages/core/utils/src/isPortalInBody.ts b/packages/core/utils/src/isPortalInBody.ts index 2e3e7c03d..899b6c3e3 100644 --- a/packages/core/utils/src/isPortalInBody.ts +++ b/packages/core/utils/src/isPortalInBody.ts @@ -5,8 +5,8 @@ export const isPortalInBody = (dom: Element) => { while (dom) { - // 如果有 `nb-action` 类名,说明是一个 Action 按钮,其本身已经阻止了冒泡,不需要再次阻止,如果阻止会导致点击无效 - if (dom.id === 'root' || dom.classList?.contains('nb-action')) { + // 如果有 `tb-action` 类名,说明是一个 Action 按钮,其本身已经阻止了冒泡,不需要再次阻止,如果阻止会导致点击无效 + if (dom.id === 'root' || dom.classList?.contains('tb-action')) { return false; } dom = dom.parentNode as Element; diff --git a/packages/plugins/@hera/plugin-core/src/client/components/fields/AssociatedField.tsx b/packages/plugins/@hera/plugin-core/src/client/components/fields/AssociatedField.tsx index b8692b3ae..2bd9a5f85 100644 --- a/packages/plugins/@hera/plugin-core/src/client/components/fields/AssociatedField.tsx +++ b/packages/plugins/@hera/plugin-core/src/client/components/fields/AssociatedField.tsx @@ -16,7 +16,7 @@ const viewerSchema: ISchema = { title: '{{ t("View record") }}', 'x-component': 'AssociationField.Viewer', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, properties: { tabs: { diff --git a/packages/plugins/@hera/plugin-core/src/client/schema-initializer/actions/hooks/useCreateActionProps.tsx b/packages/plugins/@hera/plugin-core/src/client/schema-initializer/actions/hooks/useCreateActionProps.tsx index 251f9c6ae..bc983b7cf 100644 --- a/packages/plugins/@hera/plugin-core/src/client/schema-initializer/actions/hooks/useCreateActionProps.tsx +++ b/packages/plugins/@hera/plugin-core/src/client/schema-initializer/actions/hooks/useCreateActionProps.tsx @@ -32,7 +32,7 @@ const viewerSchema: ISchema = { title: tval('View record'), 'x-component': pageDetailsViewer, 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, properties: { page: { diff --git a/packages/plugins/@hera/plugin-homepage/src/client/HomePageConfiguration.tsx b/packages/plugins/@hera/plugin-homepage/src/client/HomePageConfiguration.tsx index d85a57a0b..7f6e56cb8 100644 --- a/packages/plugins/@hera/plugin-homepage/src/client/HomePageConfiguration.tsx +++ b/packages/plugins/@hera/plugin-homepage/src/client/HomePageConfiguration.tsx @@ -61,7 +61,7 @@ export const HomePageConfiguration = (props) => { title: '{{ t("Add record") }}', 'x-component': 'Action.Container', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, properties: { tabs: { @@ -337,7 +337,7 @@ export const HomePageConfiguration = (props) => { title: '{{ t("Edit record") }}', 'x-component': 'Action.Container', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, properties: { tabs: { diff --git a/packages/plugins/@tachybase/plugin-acl/src/client/__e2e__/utils.ts b/packages/plugins/@tachybase/plugin-acl/src/client/__e2e__/utils.ts index dc0f584ab..9dd0b87de 100644 --- a/packages/plugins/@tachybase/plugin-acl/src/client/__e2e__/utils.ts +++ b/packages/plugins/@tachybase/plugin-acl/src/client/__e2e__/utils.ts @@ -92,7 +92,7 @@ export const oneTableBlock: PageConfig = { version: '2.0', 'x-component': 'Action.Container', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, _isJSONSchemaObject: true, properties: { @@ -826,7 +826,7 @@ export const oneTableBlock: PageConfig = { version: '2.0', 'x-component': 'Action.Container', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, _isJSONSchemaObject: true, properties: { @@ -1156,7 +1156,7 @@ export const oneTableBlock: PageConfig = { version: '2.0', 'x-component': 'Action.Container', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, _isJSONSchemaObject: true, properties: { @@ -1230,7 +1230,7 @@ export const oneTableBlock: PageConfig = { version: '2.0', 'x-component': 'Action.Container', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, _isJSONSchemaObject: true, properties: { @@ -1819,7 +1819,7 @@ export const oneTableBlock: PageConfig = { version: '2.0', 'x-component': 'Action.Container', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, _isJSONSchemaObject: true, properties: { @@ -2702,7 +2702,7 @@ export const newTableBlock: PageConfig = { title: '{{t("Bulk edit")}}', 'x-component': 'Action.Container', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, properties: { tabs: { @@ -2781,7 +2781,7 @@ export const newTableBlock: PageConfig = { title: '{{ t("Add record") }}', 'x-component': 'Action.Container', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, properties: { tabs: { @@ -2925,7 +2925,7 @@ export const newTableBlock: PageConfig = { title: '{{ t("View record") }}', 'x-component': 'Action.Container', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, properties: { tabs: { @@ -3000,7 +3000,7 @@ export const newTableBlock: PageConfig = { title: '{{ t("Edit record") }}', 'x-component': 'Action.Container', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, properties: { tabs: { diff --git a/packages/plugins/@tachybase/plugin-acl/src/client/schemas/scopes.ts b/packages/plugins/@tachybase/plugin-acl/src/client/schemas/scopes.ts index 77e90fe28..933e47a17 100644 --- a/packages/plugins/@tachybase/plugin-acl/src/client/schemas/scopes.ts +++ b/packages/plugins/@tachybase/plugin-acl/src/client/schemas/scopes.ts @@ -57,7 +57,7 @@ export const scopesSchema: ISchema = { title: '{{ t("Select record") }}', 'x-component': 'RecordPicker.Selector', 'x-component-props': { - className: 'nb-record-picker-selector', + className: 'tb-record-picker-selector', }, properties: { tableBlock: { @@ -107,7 +107,7 @@ export const scopesSchema: ISchema = { title: '{{ t("Add record") }}', 'x-component': 'Action.Container', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, properties: { formBlock: { @@ -234,7 +234,7 @@ export const scopesSchema: ISchema = { title: '{{ t("Edit record") }}', 'x-component': 'Action.Container', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, properties: { formBlock: { diff --git a/packages/plugins/@tachybase/plugin-action-bulk-edit/src/client/BulkEditActionInitializer.tsx b/packages/plugins/@tachybase/plugin-action-bulk-edit/src/client/BulkEditActionInitializer.tsx index 0717e7ef7..0ab655087 100644 --- a/packages/plugins/@tachybase/plugin-action-bulk-edit/src/client/BulkEditActionInitializer.tsx +++ b/packages/plugins/@tachybase/plugin-action-bulk-edit/src/client/BulkEditActionInitializer.tsx @@ -20,7 +20,7 @@ export const BulkEditActionInitializer = () => { title: '{{t("Bulk edit")}}', 'x-component': 'Action.Container', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, properties: { tabs: { diff --git a/packages/plugins/@tachybase/plugin-action-bulk-edit/src/client/__e2e__/utils.ts b/packages/plugins/@tachybase/plugin-action-bulk-edit/src/client/__e2e__/utils.ts index ef6178a70..0c65ca4b3 100644 --- a/packages/plugins/@tachybase/plugin-action-bulk-edit/src/client/__e2e__/utils.ts +++ b/packages/plugins/@tachybase/plugin-action-bulk-edit/src/client/__e2e__/utils.ts @@ -227,7 +227,7 @@ export const oneEmptyGantt: PageConfig = { type: 'void', 'x-component': 'Action.Drawer', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, title: '{{ t("View record") }}', properties: { @@ -405,7 +405,7 @@ export const oneEmptyTableBlockWithCustomizeActions: PageConfig = { title: '{{t("Bulk edit")}}', 'x-component': 'Action.Container', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, properties: { tabs: { diff --git a/packages/plugins/@tachybase/plugin-action-bulk-update/src/client/__e2e__/utils.ts b/packages/plugins/@tachybase/plugin-action-bulk-update/src/client/__e2e__/utils.ts index b1322d164..a5af75730 100644 --- a/packages/plugins/@tachybase/plugin-action-bulk-update/src/client/__e2e__/utils.ts +++ b/packages/plugins/@tachybase/plugin-action-bulk-update/src/client/__e2e__/utils.ts @@ -270,7 +270,7 @@ export const oneEmptyGantt: PageConfig = { type: 'void', 'x-component': 'Action.Drawer', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, title: '{{ t("View record") }}', properties: { diff --git a/packages/plugins/@tachybase/plugin-action-duplicate/src/client/DuplicateAction.tsx b/packages/plugins/@tachybase/plugin-action-duplicate/src/client/DuplicateAction.tsx index c9a66a3a6..309a3005c 100644 --- a/packages/plugins/@tachybase/plugin-action-duplicate/src/client/DuplicateAction.tsx +++ b/packages/plugins/@tachybase/plugin-action-duplicate/src/client/DuplicateAction.tsx @@ -162,7 +162,7 @@ export const DuplicateAction = observer(
{isLinkBtn ? ( { title: '{{ t("Duplicate") }}', 'x-component': 'Action.Container', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, properties: { tabs: { diff --git a/packages/plugins/@tachybase/plugin-action-duplicate/src/client/__e2e__/utils.ts b/packages/plugins/@tachybase/plugin-action-duplicate/src/client/__e2e__/utils.ts index 1314db906..c7d3eb0a0 100644 --- a/packages/plugins/@tachybase/plugin-action-duplicate/src/client/__e2e__/utils.ts +++ b/packages/plugins/@tachybase/plugin-action-duplicate/src/client/__e2e__/utils.ts @@ -227,7 +227,7 @@ export const oneEmptyGantt: PageConfig = { type: 'void', 'x-component': 'Action.Drawer', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, title: '{{ t("View record") }}', properties: { @@ -440,7 +440,7 @@ export const oneEmptyTableBlockWithDuplicateActions: PageConfig = { title: '{{ t("Duplicate") }}', 'x-component': 'Action.Container', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, properties: { tabs: { diff --git a/packages/plugins/@tachybase/plugin-action-print/src/client/__e2e__/utils.ts b/packages/plugins/@tachybase/plugin-action-print/src/client/__e2e__/utils.ts index 5aba2553e..da18f9681 100644 --- a/packages/plugins/@tachybase/plugin-action-print/src/client/__e2e__/utils.ts +++ b/packages/plugins/@tachybase/plugin-action-print/src/client/__e2e__/utils.ts @@ -205,7 +205,7 @@ export const oneTableWithViewAction: PageConfig = { version: '2.0', 'x-component': 'Action.Container', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, _isJSONSchemaObject: true, properties: { @@ -476,7 +476,7 @@ export const oneCalenderWithViewAction: PageConfig = { version: '2.0', 'x-component': 'Action.Container', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, _isJSONSchemaObject: true, properties: { @@ -762,7 +762,7 @@ export const oneCalenderWithViewAction: PageConfig = { version: '2.0', 'x-component': 'Action.Drawer', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, _isJSONSchemaObject: true, properties: { diff --git a/packages/plugins/@tachybase/plugin-audit-logs/src/client/components/AuditLogsViewActionInitializer.tsx b/packages/plugins/@tachybase/plugin-audit-logs/src/client/components/AuditLogsViewActionInitializer.tsx index ceca9a84c..73a3ed1c0 100644 --- a/packages/plugins/@tachybase/plugin-audit-logs/src/client/components/AuditLogsViewActionInitializer.tsx +++ b/packages/plugins/@tachybase/plugin-audit-logs/src/client/components/AuditLogsViewActionInitializer.tsx @@ -89,7 +89,7 @@ export const AuditLogsViewActionInitializer = () => { title: tval('View record'), 'x-component': 'Action.Container', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, properties: { tabs: { @@ -257,7 +257,7 @@ export const AuditLogsViewActionInitializer = () => { title: tval('View record'), 'x-component': 'RecordPicker.Viewer', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, properties: { tabs: { diff --git a/packages/plugins/@tachybase/plugin-audit-logs/src/client/deplicated/AuditLogs.tsx b/packages/plugins/@tachybase/plugin-audit-logs/src/client/deplicated/AuditLogs.tsx index 45ab3a3a5..ac1a8cfe1 100644 --- a/packages/plugins/@tachybase/plugin-audit-logs/src/client/deplicated/AuditLogs.tsx +++ b/packages/plugins/@tachybase/plugin-audit-logs/src/client/deplicated/AuditLogs.tsx @@ -197,7 +197,7 @@ export const AuditLogs: any = () => { title: tval('View record'), 'x-component': 'Action.Container', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, properties: { grid: { diff --git a/packages/plugins/@tachybase/plugin-audit-logs/src/client/utils.ts b/packages/plugins/@tachybase/plugin-audit-logs/src/client/utils.ts index dcb3e4a6d..84e684c91 100644 --- a/packages/plugins/@tachybase/plugin-audit-logs/src/client/utils.ts +++ b/packages/plugins/@tachybase/plugin-audit-logs/src/client/utils.ts @@ -188,7 +188,7 @@ export const createSchema = () => { type: 'void', 'x-component': 'Action.Container', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, title: tval('View record'), properties: { diff --git a/packages/plugins/@tachybase/plugin-calendar/src/client/__e2e__/templates.ts b/packages/plugins/@tachybase/plugin-calendar/src/client/__e2e__/templates.ts index 51f6163f2..ef1eb740b 100644 --- a/packages/plugins/@tachybase/plugin-calendar/src/client/__e2e__/templates.ts +++ b/packages/plugins/@tachybase/plugin-calendar/src/client/__e2e__/templates.ts @@ -145,7 +145,7 @@ export const oneTableWithCalendarCollection: PageConfig = { title: '{{ t("View record") }}', 'x-component': 'Action.Container', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, properties: { tabs: { diff --git a/packages/plugins/@tachybase/plugin-calendar/src/client/calendar/style.ts b/packages/plugins/@tachybase/plugin-calendar/src/client/calendar/style.ts index df553b72b..3464b5370 100644 --- a/packages/plugins/@tachybase/plugin-calendar/src/client/calendar/style.ts +++ b/packages/plugins/@tachybase/plugin-calendar/src/client/calendar/style.ts @@ -1,6 +1,6 @@ import { genStyleHook } from '@tachybase/client'; -export default genStyleHook('nb-calendar', (token) => { +export default genStyleHook('tb-calendar', (token) => { const { componentCls } = token; return { diff --git a/packages/plugins/@tachybase/plugin-calendar/src/client/schema-initializer/createCalendarBlockUISchema.ts b/packages/plugins/@tachybase/plugin-calendar/src/client/schema-initializer/createCalendarBlockUISchema.ts index 1987a31e2..3975aa691 100644 --- a/packages/plugins/@tachybase/plugin-calendar/src/client/schema-initializer/createCalendarBlockUISchema.ts +++ b/packages/plugins/@tachybase/plugin-calendar/src/client/schema-initializer/createCalendarBlockUISchema.ts @@ -55,7 +55,7 @@ export const createCalendarBlockUISchema = (options: { type: 'void', 'x-component': 'Action.Drawer', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, title: generateNTemplate('View record'), properties: { diff --git a/packages/plugins/@tachybase/plugin-calendar/src/client/schema-initializer/initializers/CalendarFormActionInitializers.tsx b/packages/plugins/@tachybase/plugin-calendar/src/client/schema-initializer/initializers/CalendarFormActionInitializers.tsx index 959103e72..0f05ccd36 100644 --- a/packages/plugins/@tachybase/plugin-calendar/src/client/schema-initializer/initializers/CalendarFormActionInitializers.tsx +++ b/packages/plugins/@tachybase/plugin-calendar/src/client/schema-initializer/initializers/CalendarFormActionInitializers.tsx @@ -95,7 +95,7 @@ export const CalendarFormActionInitializers = new SchemaInitializer({ title: generateNTemplate('Popup'), 'x-component': 'Action.Container', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, properties: { tabs: { diff --git a/packages/plugins/@tachybase/plugin-comments/src/client/styles.ts b/packages/plugins/@tachybase/plugin-comments/src/client/styles.ts index ea422cb96..2df59ff35 100644 --- a/packages/plugins/@tachybase/plugin-comments/src/client/styles.ts +++ b/packages/plugins/@tachybase/plugin-comments/src/client/styles.ts @@ -1,6 +1,6 @@ import { genStyleHook } from '@tachybase/client'; -export const styles = genStyleHook('nb-comment', (tokens) => { +export const styles = genStyleHook('tb-comment', (tokens) => { const { componentCls } = tokens; return { [componentCls]: { diff --git a/packages/plugins/@tachybase/plugin-data-source-external/src/client/features/rest-api/collection-add/PreviewComponent.tsx b/packages/plugins/@tachybase/plugin-data-source-external/src/client/features/rest-api/collection-add/PreviewComponent.tsx index ff832203f..1d6304ec8 100644 --- a/packages/plugins/@tachybase/plugin-data-source-external/src/client/features/rest-api/collection-add/PreviewComponent.tsx +++ b/packages/plugins/@tachybase/plugin-data-source-external/src/client/features/rest-api/collection-add/PreviewComponent.tsx @@ -72,12 +72,12 @@ export const PreviewComponent = (props) => { }, [form.values.fields]); return ( -
+
{dataSource?.length > 0 && ( <>
diff --git a/packages/plugins/@tachybase/plugin-data-source-external/src/client/features/rest-api/request-configs/debug-area/Debug.schema.ts b/packages/plugins/@tachybase/plugin-data-source-external/src/client/features/rest-api/request-configs/debug-area/Debug.schema.ts index 42c246758..3bca2e5e8 100644 --- a/packages/plugins/@tachybase/plugin-data-source-external/src/client/features/rest-api/request-configs/debug-area/Debug.schema.ts +++ b/packages/plugins/@tachybase/plugin-data-source-external/src/client/features/rest-api/request-configs/debug-area/Debug.schema.ts @@ -58,7 +58,7 @@ export const useSchemaDebug = () => { 'x-component': 'Action.Modal', 'x-component-props': { className: cx( - 'nb-action-popup', + 'tb-action-popup', css` .ant-modal-content { padding: 0; diff --git a/packages/plugins/@tachybase/plugin-data-source-manager/src/client/component/CollectionsManager/schema/collections.ts b/packages/plugins/@tachybase/plugin-data-source-manager/src/client/component/CollectionsManager/schema/collections.ts index 95891ebe9..2f7f6ff0e 100644 --- a/packages/plugins/@tachybase/plugin-data-source-manager/src/client/component/CollectionsManager/schema/collections.ts +++ b/packages/plugins/@tachybase/plugin-data-source-manager/src/client/component/CollectionsManager/schema/collections.ts @@ -309,7 +309,7 @@ export const collectionTableSchema: ISchema = { role: 'button', 'aria-label': '{{ "delete-button-" + $record.name }}', type: 'primary', - className: 'nb-action-link', + className: 'tb-action-link', }, }, }, diff --git a/packages/plugins/@tachybase/plugin-data-source-manager/src/client/component/MainDataSourceManager/Configuration/schemas/collections.ts b/packages/plugins/@tachybase/plugin-data-source-manager/src/client/component/MainDataSourceManager/Configuration/schemas/collections.ts index d4a1f6714..377fce594 100644 --- a/packages/plugins/@tachybase/plugin-data-source-manager/src/client/component/MainDataSourceManager/Configuration/schemas/collections.ts +++ b/packages/plugins/@tachybase/plugin-data-source-manager/src/client/component/MainDataSourceManager/Configuration/schemas/collections.ts @@ -339,7 +339,7 @@ export const collectionTableSchema: ISchema = { role: 'button', 'aria-label': '{{ "delete-button-" + $record.name }}', type: 'primary', - className: 'nb-action-link', + className: 'tb-action-link', }, }, }, diff --git a/packages/plugins/@tachybase/plugin-data-source-manager/src/client/component/PermissionManager/schemas/scopes.ts b/packages/plugins/@tachybase/plugin-data-source-manager/src/client/component/PermissionManager/schemas/scopes.ts index 243e905da..87ae074f2 100644 --- a/packages/plugins/@tachybase/plugin-data-source-manager/src/client/component/PermissionManager/schemas/scopes.ts +++ b/packages/plugins/@tachybase/plugin-data-source-manager/src/client/component/PermissionManager/schemas/scopes.ts @@ -61,7 +61,7 @@ export const getScopesSchema = (dataSourceKey) => { title: '{{ t("Select record") }}', 'x-component': 'RecordPicker.Selector', 'x-component-props': { - className: 'nb-record-picker-selector', + className: 'tb-record-picker-selector', }, properties: { tableBlock: { @@ -111,7 +111,7 @@ export const getScopesSchema = (dataSourceKey) => { title: '{{ t("Add record") }}', 'x-component': 'Action.Container', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, properties: { formBlock: { @@ -237,7 +237,7 @@ export const getScopesSchema = (dataSourceKey) => { title: '{{ t("Edit record") }}', 'x-component': 'Action.Container', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, properties: { formBlock: { diff --git a/packages/plugins/@tachybase/plugin-data-visualization/src/client/filter/FilterBlockInitializer.tsx b/packages/plugins/@tachybase/plugin-data-visualization/src/client/filter/FilterBlockInitializer.tsx index 8e12dcaf3..dabc7e7a4 100644 --- a/packages/plugins/@tachybase/plugin-data-visualization/src/client/filter/FilterBlockInitializer.tsx +++ b/packages/plugins/@tachybase/plugin-data-visualization/src/client/filter/FilterBlockInitializer.tsx @@ -63,7 +63,7 @@ export const ChartFilterGrid: React.FC = (props) => { return (
{ +export default genStyleHook('tb-field-markdown-vditor', (token) => { const { componentCls } = token; return { diff --git a/packages/plugins/@tachybase/plugin-gantt/src/client/__e2e__/utils.ts b/packages/plugins/@tachybase/plugin-gantt/src/client/__e2e__/utils.ts index 5aa78f2b5..dbc4c5d9a 100644 --- a/packages/plugins/@tachybase/plugin-gantt/src/client/__e2e__/utils.ts +++ b/packages/plugins/@tachybase/plugin-gantt/src/client/__e2e__/utils.ts @@ -270,7 +270,7 @@ export const oneEmptyGantt: PageConfig = { type: 'void', 'x-component': 'Action.Drawer', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, title: '{{ t("View record") }}', properties: { diff --git a/packages/plugins/@tachybase/plugin-gantt/src/client/components/other/tooltip.tsx b/packages/plugins/@tachybase/plugin-gantt/src/client/components/other/tooltip.tsx index f651b6e15..78d572592 100644 --- a/packages/plugins/@tachybase/plugin-gantt/src/client/components/other/tooltip.tsx +++ b/packages/plugins/@tachybase/plugin-gantt/src/client/components/other/tooltip.tsx @@ -122,7 +122,7 @@ export const StandardTooltipContent: React.FC<{ fontFamily, }; return ( -
+
{task.name}: {getYmd(task.start)} ~ {getYmd(task.end)} diff --git a/packages/plugins/@tachybase/plugin-gantt/src/client/createGanttBlockUISchema.tsx b/packages/plugins/@tachybase/plugin-gantt/src/client/createGanttBlockUISchema.tsx index fe4f69c34..679834c37 100644 --- a/packages/plugins/@tachybase/plugin-gantt/src/client/createGanttBlockUISchema.tsx +++ b/packages/plugins/@tachybase/plugin-gantt/src/client/createGanttBlockUISchema.tsx @@ -91,7 +91,7 @@ export const createGanttBlockUISchema = (options: { type: 'void', 'x-component': 'Action.Drawer', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, title: '{{ t("View record") }}', properties: { diff --git a/packages/plugins/@tachybase/plugin-graph-collection-manager/src/client/style.tsx b/packages/plugins/@tachybase/plugin-graph-collection-manager/src/client/style.tsx index b71f8d59d..e3efb465f 100644 --- a/packages/plugins/@tachybase/plugin-graph-collection-manager/src/client/style.tsx +++ b/packages/plugins/@tachybase/plugin-graph-collection-manager/src/client/style.tsx @@ -221,7 +221,7 @@ const useStyles = createStyles(({ token, css }) => { `, collectionListClass: css` - .nb-action-bar { + .tb-action-bar { float: right; position: fixed; margin-top: 24px; diff --git a/packages/plugins/@tachybase/plugin-kanban/src/client/Kanban.Card.tsx b/packages/plugins/@tachybase/plugin-kanban/src/client/Kanban.Card.tsx index 414b68fb2..8fce2bb32 100644 --- a/packages/plugins/@tachybase/plugin-kanban/src/client/Kanban.Card.tsx +++ b/packages/plugins/@tachybase/plugin-kanban/src/client/Kanban.Card.tsx @@ -43,7 +43,7 @@ export const KanbanCard: any = observer( .ant-card-body { padding: 16px; } - .nb-row-divider { + .tb-row-divider { height: 16px; margin-top: -16px; &:last-child { @@ -63,8 +63,8 @@ export const KanbanCard: any = observer( .ant-formily-item { margin-bottom: 12px; } - .nb-grid-row:last-of-type { - .nb-grid-col { + .tb-grid-row:last-of-type { + .tb-grid-col { .tb-form-item:last-of-type { .ant-formily-item { margin-bottom: 0; diff --git a/packages/plugins/@tachybase/plugin-kanban/src/client/__e2e__/utils.ts b/packages/plugins/@tachybase/plugin-kanban/src/client/__e2e__/utils.ts index 74077e349..40963c0b3 100644 --- a/packages/plugins/@tachybase/plugin-kanban/src/client/__e2e__/utils.ts +++ b/packages/plugins/@tachybase/plugin-kanban/src/client/__e2e__/utils.ts @@ -202,7 +202,7 @@ export const oneEmptyKanbanBlock: PageConfig = { title: '{{ t("View record") }}', 'x-component': 'Action.Container', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, properties: { tabs: { diff --git a/packages/plugins/@tachybase/plugin-kanban/src/client/createKanbanBlockUISchema.ts b/packages/plugins/@tachybase/plugin-kanban/src/client/createKanbanBlockUISchema.ts index 49a821626..e5559f3d7 100644 --- a/packages/plugins/@tachybase/plugin-kanban/src/client/createKanbanBlockUISchema.ts +++ b/packages/plugins/@tachybase/plugin-kanban/src/client/createKanbanBlockUISchema.ts @@ -78,7 +78,7 @@ export const createKanbanBlockUISchema = (options: { title: '{{ t("View record") }}', 'x-component': 'Action.Container', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, properties: { tabs: { diff --git a/packages/plugins/@tachybase/plugin-map/src/client/block/createMapBlockUISchema.ts b/packages/plugins/@tachybase/plugin-map/src/client/block/createMapBlockUISchema.ts index 0383b9163..006cd7609 100644 --- a/packages/plugins/@tachybase/plugin-map/src/client/block/createMapBlockUISchema.ts +++ b/packages/plugins/@tachybase/plugin-map/src/client/block/createMapBlockUISchema.ts @@ -45,7 +45,7 @@ export const createMapBlockUISchema = (options: { type: 'void', 'x-component': 'Action.Drawer', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, title: '{{ t("View record") }}', properties: { diff --git a/packages/plugins/@tachybase/plugin-messages/src/client/components/MessageViewActionInitializer.tsx b/packages/plugins/@tachybase/plugin-messages/src/client/components/MessageViewActionInitializer.tsx index 54fc7844e..18b562d54 100644 --- a/packages/plugins/@tachybase/plugin-messages/src/client/components/MessageViewActionInitializer.tsx +++ b/packages/plugins/@tachybase/plugin-messages/src/client/components/MessageViewActionInitializer.tsx @@ -62,7 +62,7 @@ export const MessageViewActionInitializer = () => { title: tval('View record'), 'x-component': 'Action.Container', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, properties: { tabs: { @@ -230,7 +230,7 @@ export const MessageViewActionInitializer = () => { title: tval('View record'), 'x-component': 'RecordPicker.Viewer', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, properties: { tabs: { diff --git a/packages/plugins/@tachybase/plugin-messages/src/client/deplicated/Message.tsx b/packages/plugins/@tachybase/plugin-messages/src/client/deplicated/Message.tsx index d02701701..70e812f84 100644 --- a/packages/plugins/@tachybase/plugin-messages/src/client/deplicated/Message.tsx +++ b/packages/plugins/@tachybase/plugin-messages/src/client/deplicated/Message.tsx @@ -197,7 +197,7 @@ export const Message: any = () => { title: tval('View record'), 'x-component': 'Action.Container', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, properties: { grid: { diff --git a/packages/plugins/@tachybase/plugin-mobile-client/src/client/core/schema/components/container/Container.tsx b/packages/plugins/@tachybase/plugin-mobile-client/src/client/core/schema/components/container/Container.tsx index 7bf29b055..4cd26e0e3 100644 --- a/packages/plugins/@tachybase/plugin-mobile-client/src/client/core/schema/components/container/Container.tsx +++ b/packages/plugins/@tachybase/plugin-mobile-client/src/client/core/schema/components/container/Container.tsx @@ -56,13 +56,13 @@ const InternalContainer: React.FC = (props) => { return ( - +
{redirectToUid ? ( @@ -76,7 +76,7 @@ const InternalContainer: React.FC = (props) => { )}
{isTabBarEnabled && ( -
+
{ diff --git a/packages/plugins/@tachybase/plugin-mobile-client/src/client/core/schema/components/header/Header.tsx b/packages/plugins/@tachybase/plugin-mobile-client/src/client/core/schema/components/header/Header.tsx index 94b267123..c1d22eac7 100644 --- a/packages/plugins/@tachybase/plugin-mobile-client/src/client/core/schema/components/header/Header.tsx +++ b/packages/plugins/@tachybase/plugin-mobile-client/src/client/core/schema/components/header/Header.tsx @@ -35,7 +35,7 @@ const InternalHeader = (props: HeaderProps) => { }, [token.colorBgContainer]); return ( - + navigate(-1)}> {compiledTitle} diff --git a/packages/plugins/@tachybase/plugin-mobile-client/src/client/core/schema/components/menu/Menu.Item.tsx b/packages/plugins/@tachybase/plugin-mobile-client/src/client/core/schema/components/menu/Menu.Item.tsx index b05b8bcb4..b6ef6bf8f 100644 --- a/packages/plugins/@tachybase/plugin-mobile-client/src/client/core/schema/components/menu/Menu.Item.tsx +++ b/packages/plugins/@tachybase/plugin-mobile-client/src/client/core/schema/components/menu/Menu.Item.tsx @@ -40,7 +40,7 @@ const InternalMenuItem: React.FC = (props) => { return ( { }; return ( - + {designable && ( diff --git a/packages/plugins/@tachybase/plugin-mobile-client/src/client/core/schema/components/page/Page.tsx b/packages/plugins/@tachybase/plugin-mobile-client/src/client/core/schema/components/page/Page.tsx index 0916566e8..dba29310b 100644 --- a/packages/plugins/@tachybase/plugin-mobile-client/src/client/core/schema/components/page/Page.tsx +++ b/packages/plugins/@tachybase/plugin-mobile-client/src/client/core/schema/components/page/Page.tsx @@ -72,7 +72,7 @@ const InternalPage: React.FC = (props) => { { ); return ( - +
.ant-nb-grid { + & > .ant-tb-grid { margin-top: 14px; } `]: (tabsSchema && !isTabsEnabled) || !tabsSchema, diff --git a/packages/plugins/@tachybase/plugin-mobile-client/src/client/core/schema/components/page/style.ts b/packages/plugins/@tachybase/plugin-mobile-client/src/client/core/schema/components/page/style.ts index 652debc91..462fd88d6 100644 --- a/packages/plugins/@tachybase/plugin-mobile-client/src/client/core/schema/components/page/style.ts +++ b/packages/plugins/@tachybase/plugin-mobile-client/src/client/core/schema/components/page/style.ts @@ -3,7 +3,7 @@ import { createStyles } from '@tachybase/client'; const useStyles = createStyles(({ token, css }) => { return { globalActionCSS: css` - #nb-position-container > & { + #tb-position-container > & { height: ${token.sizeXXL}px; border-top: 1px solid var(--tb-box-bg); margin-bottom: 0px !important; diff --git a/packages/plugins/@tachybase/plugin-mobile-client/src/client/core/schema/components/settings/Settings.tsx b/packages/plugins/@tachybase/plugin-mobile-client/src/client/core/schema/components/settings/Settings.tsx index 35a909396..1204b369f 100644 --- a/packages/plugins/@tachybase/plugin-mobile-client/src/client/core/schema/components/settings/Settings.tsx +++ b/packages/plugins/@tachybase/plugin-mobile-client/src/client/core/schema/components/settings/Settings.tsx @@ -8,7 +8,7 @@ export const InternalSettings = () => { return ( = () => { return ( { return ( .nb-action-bar { + & > .tb-action-bar { padding: unset !important; background: unset !important; } diff --git a/packages/plugins/@tachybase/plugin-mobile-client/src/client/devices/iOS6.tsx b/packages/plugins/@tachybase/plugin-mobile-client/src/client/devices/iOS6.tsx index 795ef6abc..80663eb4b 100644 --- a/packages/plugins/@tachybase/plugin-mobile-client/src/client/devices/iOS6.tsx +++ b/packages/plugins/@tachybase/plugin-mobile-client/src/client/devices/iOS6.tsx @@ -9,7 +9,7 @@ const iOS6: React.FC = (props) => { return (
= (props) => { return (
.general-schema-designer { display: block; @@ -50,7 +50,7 @@ const commonDesignerCSS = css` `; const drawerProps: DrawerProps = { - getContainer: '.nb-mobile-application', + getContainer: '.tb-mobile-application', width: '90%', style: { position: 'absolute', @@ -90,7 +90,7 @@ const MApplication: React.FC = (props) => {
= (props) => { )} {/* Global action will insert here */} -
+
diff --git a/packages/plugins/@tachybase/plugin-snapshot-field/src/client/interface.ts b/packages/plugins/@tachybase/plugin-snapshot-field/src/client/interface.ts index 2bce66145..b4e1c043a 100644 --- a/packages/plugins/@tachybase/plugin-snapshot-field/src/client/interface.ts +++ b/packages/plugins/@tachybase/plugin-snapshot-field/src/client/interface.ts @@ -72,7 +72,7 @@ const recordPickerViewer = { title: `{{t('View record')}}`, 'x-component': 'RecordPicker.Viewer', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, properties: { tabs: { diff --git a/packages/plugins/@tachybase/plugin-ui-schema-storage/src/server/__tests__/fixtures/data.ts b/packages/plugins/@tachybase/plugin-ui-schema-storage/src/server/__tests__/fixtures/data.ts index 964096a6f..1abcf84ed 100644 --- a/packages/plugins/@tachybase/plugin-ui-schema-storage/src/server/__tests__/fixtures/data.ts +++ b/packages/plugins/@tachybase/plugin-ui-schema-storage/src/server/__tests__/fixtures/data.ts @@ -310,7 +310,7 @@ export default { 'x-decorator': 'CollectionProvider_deprecated', 'x-decorator-props': { name: 'attachments' }, 'x-component': 'Action.Drawer', - 'x-component-props': { className: 'nb-action-popup' }, + 'x-component-props': { className: 'tb-action-popup' }, type: 'void', title: 'Drawer Title', properties: { @@ -564,7 +564,7 @@ export default { 'x-decorator': 'CollectionProvider_deprecated', 'x-decorator-props': { name: 't_94rsj6kbzvn' }, 'x-component': 'Action.Drawer', - 'x-component-props': { className: 'nb-action-popup' }, + 'x-component-props': { className: 'tb-action-popup' }, type: 'void', title: 'Drawer Title', properties: { @@ -725,7 +725,7 @@ export default { 'x-decorator': 'CollectionProvider_deprecated', 'x-decorator-props': { name: 'users' }, 'x-component': 'Action.Drawer', - 'x-component-props': { className: 'nb-action-popup' }, + 'x-component-props': { className: 'tb-action-popup' }, type: 'void', title: 'Drawer Title', properties: { @@ -953,7 +953,7 @@ export default { 'x-decorator': 'CollectionProvider_deprecated', 'x-decorator-props': { name: 't_j6omof6tza8' }, 'x-component': 'Action.Drawer', - 'x-component-props': { className: 'nb-action-popup' }, + 'x-component-props': { className: 'tb-action-popup' }, type: 'void', title: 'Drawer Title', properties: { @@ -1226,7 +1226,7 @@ export default { 'x-decorator-props': { name: 'users' }, 'x-component': 'Action.Drawer', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, type: 'void', title: 'Drawer Title', @@ -1417,7 +1417,7 @@ export default { 'x-decorator-props': { name: 'attachments' }, 'x-component': 'Action.Drawer', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, type: 'void', title: 'Drawer Title', @@ -1857,7 +1857,7 @@ export default { 'x-decorator': 'CollectionProvider_deprecated', 'x-decorator-props': { name: 'users' }, 'x-component': 'Action.Drawer', - 'x-component-props': { className: 'nb-action-popup' }, + 'x-component-props': { className: 'tb-action-popup' }, type: 'void', title: 'Drawer Title', properties: { @@ -2021,7 +2021,7 @@ export default { 'x-decorator': 'CollectionProvider_deprecated', 'x-decorator-props': { name: 'attachments' }, 'x-component': 'Action.Drawer', - 'x-component-props': { className: 'nb-action-popup' }, + 'x-component-props': { className: 'tb-action-popup' }, type: 'void', title: 'Drawer Title', properties: { @@ -2257,7 +2257,7 @@ export default { version: '2.0', type: 'void', 'x-component': 'Action.Container', - 'x-component-props': { className: 'nb-action-popup' }, + 'x-component-props': { className: 'tb-action-popup' }, title: '{{ t("View record") }}', properties: { tabs: { @@ -2484,7 +2484,7 @@ export default { }, 'x-component': 'Action.Drawer', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, type: 'void', title: 'Drawer Title', @@ -2704,7 +2704,7 @@ export default { }, 'x-component': 'Action.Drawer', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, type: 'void', title: 'Drawer Title', @@ -2851,7 +2851,7 @@ export default { 'x-decorator-props': { name: 'users' }, 'x-component': 'Action.Drawer', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, type: 'void', title: 'Drawer Title', @@ -3314,7 +3314,7 @@ export default { 'Action.Drawer', 'x-component-props': { className: - 'nb-action-popup', + 'tb-action-popup', }, type: 'void', title: 'Drawer Title', @@ -3711,7 +3711,7 @@ export default { 'x-decorator': 'CollectionProvider_deprecated', 'x-decorator-props': { name: 'attachments' }, 'x-component': 'Action.Drawer', - 'x-component-props': { className: 'nb-action-popup' }, + 'x-component-props': { className: 'tb-action-popup' }, type: 'void', title: 'Drawer Title', properties: { @@ -3965,7 +3965,7 @@ export default { 'x-decorator': 'CollectionProvider_deprecated', 'x-decorator-props': { name: 't_94rsj6kbzvn' }, 'x-component': 'Action.Drawer', - 'x-component-props': { className: 'nb-action-popup' }, + 'x-component-props': { className: 'tb-action-popup' }, type: 'void', title: 'Drawer Title', properties: { @@ -4127,7 +4127,7 @@ export default { 'x-decorator': 'CollectionProvider_deprecated', 'x-decorator-props': { name: 'users' }, 'x-component': 'Action.Drawer', - 'x-component-props': { className: 'nb-action-popup' }, + 'x-component-props': { className: 'tb-action-popup' }, type: 'void', title: 'Drawer Title', properties: { @@ -4355,7 +4355,7 @@ export default { 'x-decorator': 'CollectionProvider_deprecated', 'x-decorator-props': { name: 't_j6omof6tza8' }, 'x-component': 'Action.Drawer', - 'x-component-props': { className: 'nb-action-popup' }, + 'x-component-props': { className: 'tb-action-popup' }, type: 'void', title: 'Drawer Title', properties: { @@ -4635,7 +4635,7 @@ export default { 'x-decorator-props': { name: 'users' }, 'x-component': 'Action.Drawer', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, type: 'void', title: 'Drawer Title', @@ -4835,7 +4835,7 @@ export default { }, 'x-component': 'Action.Drawer', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, type: 'void', title: 'Drawer Title', @@ -5173,7 +5173,7 @@ export default { }, 'x-component': 'Action.Drawer', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, type: 'void', title: 'Drawer Title', @@ -5384,7 +5384,7 @@ export default { }, 'x-component': 'Action.Drawer', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, type: 'void', title: 'Drawer Title', @@ -5636,7 +5636,7 @@ export default { 'x-decorator': 'CollectionProvider_deprecated', 'x-decorator-props': { name: 'users' }, 'x-component': 'Action.Drawer', - 'x-component-props': { className: 'nb-action-popup' }, + 'x-component-props': { className: 'tb-action-popup' }, type: 'void', title: 'Drawer Title', properties: { @@ -6022,7 +6022,7 @@ export default { 'x-decorator': 'CollectionProvider_deprecated', 'x-decorator-props': { name: 't_94rsj6kbzvn' }, 'x-component': 'Action.Drawer', - 'x-component-props': { className: 'nb-action-popup' }, + 'x-component-props': { className: 'tb-action-popup' }, type: 'void', title: 'Drawer Title', properties: { @@ -6207,7 +6207,7 @@ export default { 'x-decorator': 'CollectionProvider_deprecated', 'x-decorator-props': { name: 'users' }, 'x-component': 'Action.Drawer', - 'x-component-props': { className: 'nb-action-popup' }, + 'x-component-props': { className: 'tb-action-popup' }, type: 'void', title: 'Drawer Title', properties: { diff --git a/packages/plugins/@tachybase/plugin-workflow/src/client/features/approval/configuration/instruction-carbon-copy/show-interface/style.ts b/packages/plugins/@tachybase/plugin-workflow/src/client/features/approval/configuration/instruction-carbon-copy/show-interface/style.ts index b8a8de876..86bd58395 100644 --- a/packages/plugins/@tachybase/plugin-workflow/src/client/features/approval/configuration/instruction-carbon-copy/show-interface/style.ts +++ b/packages/plugins/@tachybase/plugin-workflow/src/client/features/approval/configuration/instruction-carbon-copy/show-interface/style.ts @@ -3,7 +3,7 @@ import { css } from '@tachybase/client'; export const schemaStyle = { ActionStyle: css` .ant-drawer-body { - background: var(--nb-box-bg); + background: var(--tb-box-bg); } `, }; diff --git a/packages/plugins/@tachybase/plugin-workflow/src/client/features/approval/usage/approval-block/launch/VC.ViewActionLaunch.tsx b/packages/plugins/@tachybase/plugin-workflow/src/client/features/approval/usage/approval-block/launch/VC.ViewActionLaunch.tsx index 7b4d59350..0fe7b4ea3 100644 --- a/packages/plugins/@tachybase/plugin-workflow/src/client/features/approval/usage/approval-block/launch/VC.ViewActionLaunch.tsx +++ b/packages/plugins/@tachybase/plugin-workflow/src/client/features/approval/usage/approval-block/launch/VC.ViewActionLaunch.tsx @@ -23,7 +23,7 @@ export const ViewActionLaunch = ({ popoverComponent = 'Action.Drawer', popoverCo type: 'void', 'x-component': popoverComponent, 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', ...popoverComponentProps, }, properties: { diff --git a/packages/plugins/@tachybase/plugin-workflow/src/client/features/approval/usage/approval-block/todos/VC.ViewActionTodos.tsx b/packages/plugins/@tachybase/plugin-workflow/src/client/features/approval/usage/approval-block/todos/VC.ViewActionTodos.tsx index 2aded9af9..61306cc89 100644 --- a/packages/plugins/@tachybase/plugin-workflow/src/client/features/approval/usage/approval-block/todos/VC.ViewActionTodos.tsx +++ b/packages/plugins/@tachybase/plugin-workflow/src/client/features/approval/usage/approval-block/todos/VC.ViewActionTodos.tsx @@ -21,7 +21,7 @@ export const ViewActionTodos = ({ popoverComponent = 'Action.Drawer', popoverCom type: 'void', 'x-component': popoverComponent, 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', ...popoverComponentProps, }, properties: { diff --git a/packages/plugins/@tachybase/plugin-workflow/src/client/features/approval/usage/approval-common/notice-columns/column.action.tsx b/packages/plugins/@tachybase/plugin-workflow/src/client/features/approval/usage/approval-common/notice-columns/column.action.tsx index 74b81d29a..c03b5aea2 100644 --- a/packages/plugins/@tachybase/plugin-workflow/src/client/features/approval/usage/approval-common/notice-columns/column.action.tsx +++ b/packages/plugins/@tachybase/plugin-workflow/src/client/features/approval/usage/approval-common/notice-columns/column.action.tsx @@ -15,7 +15,7 @@ const createSchema = ({ record }) => { type: 'void', 'x-component': 'Action.Drawer', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, properties: { content: { diff --git a/packages/plugins/@tachybase/plugin-workflow/src/client/features/manual/WorkflowTodo.tsx b/packages/plugins/@tachybase/plugin-workflow/src/client/features/manual/WorkflowTodo.tsx index abbdc3524..d5c0fb441 100644 --- a/packages/plugins/@tachybase/plugin-workflow/src/client/features/manual/WorkflowTodo.tsx +++ b/packages/plugins/@tachybase/plugin-workflow/src/client/features/manual/WorkflowTodo.tsx @@ -592,7 +592,7 @@ function Drawer() { name: `drawer-${id}-${status}`, 'x-component': 'Action.Drawer', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, title: `${workflow.title} - ${node.title ?? `#${node.id}`}`, properties: { diff --git a/packages/plugins/@tachybase/plugin-workflow/src/client/features/notice/configuration/show-interface/style.ts b/packages/plugins/@tachybase/plugin-workflow/src/client/features/notice/configuration/show-interface/style.ts index b8a8de876..86bd58395 100644 --- a/packages/plugins/@tachybase/plugin-workflow/src/client/features/notice/configuration/show-interface/style.ts +++ b/packages/plugins/@tachybase/plugin-workflow/src/client/features/notice/configuration/show-interface/style.ts @@ -3,7 +3,7 @@ import { css } from '@tachybase/client'; export const schemaStyle = { ActionStyle: css` .ant-drawer-body { - background: var(--nb-box-bg); + background: var(--tb-box-bg); } `, }; diff --git a/packages/plugins/@tachybase/plugin-workflow/src/client/features/notice/usage/column/column.action.tsx b/packages/plugins/@tachybase/plugin-workflow/src/client/features/notice/usage/column/column.action.tsx index 52f051d1b..e1e0f52ed 100644 --- a/packages/plugins/@tachybase/plugin-workflow/src/client/features/notice/usage/column/column.action.tsx +++ b/packages/plugins/@tachybase/plugin-workflow/src/client/features/notice/usage/column/column.action.tsx @@ -15,7 +15,7 @@ const createSchema = ({ record }) => { type: 'void', 'x-component': 'Action.Drawer', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, properties: { content: { diff --git a/packages/plugins/@tachybase/plugin-workflow/src/client/features/webhook/WebhookManager.tsx b/packages/plugins/@tachybase/plugin-workflow/src/client/features/webhook/WebhookManager.tsx index 1eb51d7e7..4dd385709 100644 --- a/packages/plugins/@tachybase/plugin-workflow/src/client/features/webhook/WebhookManager.tsx +++ b/packages/plugins/@tachybase/plugin-workflow/src/client/features/webhook/WebhookManager.tsx @@ -110,7 +110,7 @@ const schema: ISchema = { title: '{{ t("Add record") }}', 'x-component': 'Action.Container', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, properties: { tabs: { @@ -455,7 +455,7 @@ const schema: ISchema = { title: '{{ t("Edit record") }}', 'x-component': 'Action.Container', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, properties: { tabs: { @@ -687,7 +687,7 @@ const schema: ISchema = { title: '{{ t("Edit record") }}', 'x-component': 'Action.Container', 'x-component-props': { - className: 'nb-action-popup', + className: 'tb-action-popup', }, properties: { tabs: {