tntd 2.0.13 → 2.0.14
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/es/array-input/index.js +31 -6
- package/es/columns/index.js +12 -6
- package/es/development-login/LoginModal.js +10 -4
- package/es/drawer/drawer.js +8 -4
- package/es/ellipsis/index.js +25 -14
- package/es/empty/empty.js +13 -9
- package/es/handle/index.js +27 -14
- package/es/img/Contain.js +19 -13
- package/es/img/Cover.js +24 -13
- package/es/img/index.js +21 -14
- package/es/index.js +1 -0
- package/es/loading-button/index.js +13 -6
- package/es/locale/default.js +2 -0
- package/es/locale/en_US.js +2 -0
- package/es/locale/zh_CN.js +2 -0
- package/es/page/Box.js +28 -19
- package/es/page/index.js +38 -22
- package/es/page/utils.js +5 -0
- package/es/prev-locale.js +3 -0
- package/es/query-form/Field/Checkbox.js +8 -4
- package/es/query-form/Field/Select.js +17 -10
- package/es/query-form/Field/SelectInput.js +18 -4
- package/es/query-form/Field/fieldsMap.js +1 -0
- package/es/query-form/Field/index.js +11 -2
- package/es/query-form/createActions.js +8 -0
- package/es/query-form/index.js +34 -2
- package/es/query-list-scene/List.js +39 -18
- package/es/query-list-scene/QueryForm.js +19 -10
- package/es/query-list-scene/QueryListScene.js +2 -0
- package/es/query-list-scene/Toolbar.js +10 -6
- package/es/query-list-scene/createActions.js +3 -0
- package/es/render-empty/render-empty.js +2 -0
- package/es/steps/steps.js +17 -9
- package/es/steps/style/nav.less +3 -1
- package/es/svg-components/illustration-403.js +2 -0
- package/es/svg-components/illustration-404.js +2 -0
- package/es/svg-components/illustration-500.js +2 -0
- package/es/svg-components/illustration-empty.js +2 -0
- package/es/svg-components/illustration-failure.js +2 -0
- package/es/svg-components/illustration-no-access.js +2 -0
- package/es/svg-components/illustration-no-chart.js +2 -0
- package/es/svg-components/illustration-no-result.js +2 -0
- package/es/svg-components/illustration-offline.js +2 -0
- package/es/svg-components/illustration-success.js +2 -0
- package/es/table/assets/image-loading-background.js +2 -0
- package/es/table/assets/image-loading.js +2 -0
- package/es/table/hooks/use-column-setting.js +1 -0
- package/es/table/table.js +19 -14
- package/es/table/table.stories.js +2 -0
- package/es/table/utils.js +6 -2
- package/es/title/index.js +14 -10
- package/es/tntd-cascader/AntdCascader/component/context.js +4 -2
- package/es/tntd-cascader/AntdCascader/component/defaultRenderEmpty.js +2 -0
- package/es/tntd-cascader/AntdCascader/component/getIcons.js +15 -6
- package/es/tntd-cascader/AntdCascader/config/utils.js +2 -0
- package/es/tntd-cascader/AntdCascader/config/warning.js +8 -4
- package/es/tntd-cascader/AntdCascader/index.js +73 -51
- package/es/tntd-cascader/rc-cascader/Cascader.js +113 -86
- package/es/tntd-cascader/rc-cascader/OptionList/Column.js +26 -16
- package/es/tntd-cascader/rc-cascader/OptionList/index.js +43 -26
- package/es/tntd-cascader/rc-cascader/OptionList/useActive.js +7 -5
- package/es/tntd-cascader/rc-cascader/OptionList/useKeyboard.js +41 -12
- package/es/tntd-cascader/rc-cascader/hooks/useDisplayValues.js +10 -4
- package/es/tntd-cascader/rc-cascader/hooks/useEntities.js +4 -2
- package/es/tntd-cascader/rc-cascader/hooks/useMissingValues.js +1 -0
- package/es/tntd-cascader/rc-cascader/hooks/useRefFunc.js +1 -0
- package/es/tntd-cascader/rc-cascader/hooks/useSearchConfig.js +7 -2
- package/es/tntd-cascader/rc-cascader/hooks/useSearchOptions.js +15 -8
- package/es/tntd-cascader/rc-cascader/utils/commonUtil.js +6 -2
- package/es/tntd-cascader/rc-cascader/utils/treeUtil.js +4 -2
- package/es/tntd-cascader/rc-cascader/utils/warningPropsUtil.js +7 -2
- package/es/tntd-icon/fonts/iconfont.js +12 -7
- package/es/tntd-icon/index.js +9 -5
- package/es/tntd-layout/ActionsContext.js +2 -2
- package/es/tntd-layout/AppList.js +14 -2
- package/es/tntd-layout/Application.js +4 -0
- package/es/tntd-layout/Avatar.js +4 -0
- package/es/tntd-layout/CompatibleLanguage.js +13 -0
- package/es/tntd-layout/EnterpriseLayout/Avatar.js +4 -0
- package/es/tntd-layout/EnterpriseLayout/Language.js +6 -0
- package/es/tntd-layout/EnterpriseLayout/Theme.js +4 -0
- package/es/tntd-layout/EnterpriseLayout/index.js +2 -2
- package/es/tntd-layout/GlobalNavigation/NavigationPopup.js +33 -2
- package/es/tntd-layout/GlobalNavigation/index.js +6 -0
- package/es/tntd-layout/HeaderActions.js +32 -28
- package/es/tntd-layout/HeaderNavs.js +14 -6
- package/es/tntd-layout/HeaderTabs.js +35 -14
- package/es/tntd-layout/Language.js +6 -0
- package/es/tntd-layout/Layout.js +7 -2
- package/es/tntd-layout/Logo.js +11 -4
- package/es/tntd-layout/OrgAppList.js +39 -22
- package/es/tntd-layout/SideMenu.js +45 -8
- package/es/tntd-layout/Theme.js +6 -0
- package/es/tntd-layout/index.js +17 -9
- package/es/tntd-layout/paaslayout/CompactSideMenu.js +15 -0
- package/es/tntd-layout/paaslayout/SideMenu.js +15 -0
- package/es/tntd-layout/paaslayout/index.js +13 -4
- package/es/tntd-layout/storage.js +2 -2
- package/es/tntd-modal/index.js +18 -12
- package/es/tntd-second-page/index.js +3 -0
- package/es/tntd-select/DropDownWrap.js +8 -4
- package/es/tntd-select/index.js +118 -74
- package/es/utils/checkAuth.js +1 -0
- package/es/utils/findMenuInfoByPath.js +3 -0
- package/es/utils/index.js +11 -2
- package/lib/affix/index.js +10 -4
- package/lib/alert/index.js +10 -4
- package/lib/anchor/index.js +10 -4
- package/lib/array-input/icon.js +7 -1
- package/lib/array-input/index.js +91 -41
- package/lib/auth-context/index.js +3 -0
- package/lib/auto-complete/index.js +10 -4
- package/lib/avatar/index.js +10 -4
- package/lib/back-top/index.js +10 -4
- package/lib/badge/index.js +10 -4
- package/lib/breadcrumb/index.js +10 -4
- package/lib/button/index.js +10 -4
- package/lib/calendar/index.js +10 -4
- package/lib/card/index.js +10 -4
- package/lib/carousel/index.js +10 -4
- package/lib/cascader/index.js +10 -4
- package/lib/checkbox/index.js +10 -4
- package/lib/col/index.js +10 -4
- package/lib/collapse/index.js +11 -4
- package/lib/columns/index.js +28 -14
- package/lib/comment/index.js +10 -4
- package/lib/config-provider/config-provider.js +2 -0
- package/lib/config-provider/index.js +10 -4
- package/lib/date-picker/index.js +10 -4
- package/lib/descriptions/index.js +10 -4
- package/lib/development-login/LoginModal.js +50 -25
- package/lib/development-login/index.js +22 -11
- package/lib/divider/index.js +10 -4
- package/lib/drawer/drawer.js +16 -6
- package/lib/drawer/index.js +5 -1
- package/lib/dropdown/index.js +10 -4
- package/lib/ellipsis/Svg/CopySVG.js +4 -0
- package/lib/ellipsis/Svg/TickSVG.js +4 -0
- package/lib/ellipsis/index.js +73 -42
- package/lib/empty/empty.js +30 -14
- package/lib/empty/empty.stories.js +21 -3
- package/lib/empty/index.js +5 -1
- package/lib/exception/exception.js +14 -7
- package/lib/exception/index.js +4 -1
- package/lib/form/index.js +10 -4
- package/lib/handle/index.js +46 -19
- package/lib/icon/index.js +10 -4
- package/lib/img/Contain.js +23 -12
- package/lib/img/Cover.js +53 -31
- package/lib/img/index.js +47 -29
- package/lib/index.js +187 -100
- package/lib/input/index.js +10 -4
- package/lib/input-number/index.js +10 -4
- package/lib/layout/index.js +10 -4
- package/lib/list/index.js +10 -4
- package/lib/loading-button/index.js +32 -15
- package/lib/locale/default.js +5 -0
- package/lib/locale/en_US.js +4 -0
- package/lib/locale/index.js +6 -3
- package/lib/locale/zh_CN.js +4 -0
- package/lib/locale-provider/index.js +10 -4
- package/lib/mention/index.js +10 -4
- package/lib/mentions/index.js +10 -4
- package/lib/menu/index.js +10 -4
- package/lib/message/index.js +11 -4
- package/lib/modal/index.js +11 -4
- package/lib/notification/index.js +10 -4
- package/lib/page/Box.js +37 -24
- package/lib/page/index.js +66 -37
- package/lib/page/utils.js +9 -1
- package/lib/page-header/index.js +10 -4
- package/lib/pagination/index.js +10 -4
- package/lib/popconfirm/index.js +10 -4
- package/lib/popover/index.js +10 -4
- package/lib/prev-locale.js +10 -1
- package/lib/progress/index.js +10 -4
- package/lib/query-form/Field/Checkbox.js +11 -2
- package/lib/query-form/Field/Select.js +45 -27
- package/lib/query-form/Field/SelectInput.js +46 -21
- package/lib/query-form/Field/fieldsMap.js +12 -1
- package/lib/query-form/Field/index.js +70 -38
- package/lib/query-form/createActions.js +7 -0
- package/lib/query-form/index.js +121 -52
- package/lib/query-form/useForm.js +4 -0
- package/lib/query-list-scene/List.js +111 -58
- package/lib/query-list-scene/QueryForm.js +67 -37
- package/lib/query-list-scene/QueryListScene.js +42 -21
- package/lib/query-list-scene/Title.js +5 -1
- package/lib/query-list-scene/Toolbar.js +15 -8
- package/lib/query-list-scene/createActions.js +6 -0
- package/lib/query-list-scene/index.js +10 -0
- package/lib/query-list-scene/useActions.js +4 -0
- package/lib/radio/index.js +10 -4
- package/lib/rate/index.js +10 -4
- package/lib/render-empty/index.js +2 -0
- package/lib/render-empty/render-empty.js +8 -0
- package/lib/result/index.js +10 -4
- package/lib/row/index.js +10 -4
- package/lib/select/index.js +10 -4
- package/lib/skeleton/index.js +10 -4
- package/lib/slider/index.js +10 -4
- package/lib/spin/index.js +10 -4
- package/lib/statistic/index.js +10 -4
- package/lib/steps/index.js +5 -1
- package/lib/steps/steps.js +29 -12
- package/lib/steps/style/nav.less +3 -1
- package/lib/svg-components/illustration-403.js +9 -3
- package/lib/svg-components/illustration-404.js +9 -3
- package/lib/svg-components/illustration-500.js +9 -3
- package/lib/svg-components/illustration-empty.js +9 -3
- package/lib/svg-components/illustration-failure.js +9 -3
- package/lib/svg-components/illustration-no-access.js +9 -3
- package/lib/svg-components/illustration-no-chart.js +9 -3
- package/lib/svg-components/illustration-no-result.js +9 -3
- package/lib/svg-components/illustration-offline.js +9 -3
- package/lib/svg-components/illustration-success.js +9 -3
- package/lib/svg-components/index.js +11 -0
- package/lib/switch/index.js +10 -4
- package/lib/table/assets/image-loading-background.js +9 -3
- package/lib/table/assets/image-loading.js +9 -3
- package/lib/table/context.js +2 -0
- package/lib/table/hooks/index.js +2 -1
- package/lib/table/hooks/use-column-setting.js +16 -8
- package/lib/table/index.js +5 -1
- package/lib/table/table.js +63 -34
- package/lib/table/table.stories.js +11 -2
- package/lib/table/utils.js +11 -2
- package/lib/tabs/index.js +10 -4
- package/lib/tag/index.js +10 -4
- package/lib/time-picker/index.js +10 -4
- package/lib/timeline/index.js +10 -4
- package/lib/title/index.js +20 -10
- package/lib/tntd-cascader/AntdCascader/component/DisabledContext.js +11 -4
- package/lib/tntd-cascader/AntdCascader/component/FormItemInputContext.js +8 -3
- package/lib/tntd-cascader/AntdCascader/component/SizeContext.js +8 -3
- package/lib/tntd-cascader/AntdCascader/component/context.js +9 -3
- package/lib/tntd-cascader/AntdCascader/component/defaultRenderEmpty.js +12 -4
- package/lib/tntd-cascader/AntdCascader/component/getIcons.js +37 -19
- package/lib/tntd-cascader/AntdCascader/component/useCompactItemContext.js +17 -8
- package/lib/tntd-cascader/AntdCascader/config/utils.js +15 -6
- package/lib/tntd-cascader/AntdCascader/config/warning.js +15 -7
- package/lib/tntd-cascader/AntdCascader/index.js +133 -80
- package/lib/tntd-cascader/AntdCascader/interface.js +3 -0
- package/lib/tntd-cascader/index.js +2 -0
- package/lib/tntd-cascader/rc-cascader/Cascader.js +188 -123
- package/lib/tntd-cascader/rc-cascader/OptionList/Checkbox.js +21 -11
- package/lib/tntd-cascader/rc-cascader/OptionList/Column.js +88 -60
- package/lib/tntd-cascader/rc-cascader/OptionList/index.js +109 -65
- package/lib/tntd-cascader/rc-cascader/OptionList/useActive.js +33 -18
- package/lib/tntd-cascader/rc-cascader/OptionList/useKeyboard.js +106 -56
- package/lib/tntd-cascader/rc-cascader/context.js +8 -3
- package/lib/tntd-cascader/rc-cascader/hooks/useDisplayValues.js +31 -14
- package/lib/tntd-cascader/rc-cascader/hooks/useEntities.js +15 -5
- package/lib/tntd-cascader/rc-cascader/hooks/useMissingValues.js +11 -3
- package/lib/tntd-cascader/rc-cascader/hooks/useRefFunc.js +8 -3
- package/lib/tntd-cascader/rc-cascader/hooks/useSearchConfig.js +15 -3
- package/lib/tntd-cascader/rc-cascader/hooks/useSearchOptions.js +41 -26
- package/lib/tntd-cascader/rc-cascader/index.js +3 -0
- package/lib/tntd-cascader/rc-cascader/utils/commonUtil.js +20 -9
- package/lib/tntd-cascader/rc-cascader/utils/treeUtil.js +8 -0
- package/lib/tntd-cascader/rc-cascader/utils/warningPropsUtil.js +14 -7
- package/lib/tntd-icon/fonts/iconfont.js +12 -7
- package/lib/tntd-icon/index.js +17 -6
- package/lib/tntd-layout/ActionsContext.js +3 -0
- package/lib/tntd-layout/AppList.js +105 -30
- package/lib/tntd-layout/Application.js +84 -22
- package/lib/tntd-layout/Avatar.js +72 -18
- package/lib/tntd-layout/CompatibleLanguage.js +105 -32
- package/lib/tntd-layout/EnterpriseLayout/Avatar.js +80 -24
- package/lib/tntd-layout/EnterpriseLayout/Language.js +45 -14
- package/lib/tntd-layout/EnterpriseLayout/Theme.js +46 -16
- package/lib/tntd-layout/EnterpriseLayout/index.js +12 -4
- package/lib/tntd-layout/GlobalNavigation/NavigationPopup.js +174 -45
- package/lib/tntd-layout/GlobalNavigation/index.js +70 -19
- package/lib/tntd-layout/Header.js +54 -20
- package/lib/tntd-layout/HeaderActions.js +64 -33
- package/lib/tntd-layout/HeaderNavs.js +59 -19
- package/lib/tntd-layout/HeaderTabs.js +111 -43
- package/lib/tntd-layout/Iconfont.js +5 -0
- package/lib/tntd-layout/Language.js +45 -14
- package/lib/tntd-layout/Layout.js +113 -74
- package/lib/tntd-layout/Logo.js +41 -14
- package/lib/tntd-layout/OrgAppList.js +119 -51
- package/lib/tntd-layout/SideMenu.js +120 -42
- package/lib/tntd-layout/Theme.js +71 -19
- package/lib/tntd-layout/createActions.js +5 -0
- package/lib/tntd-layout/images/index.js +28 -0
- package/lib/tntd-layout/index.js +49 -21
- package/lib/tntd-layout/paaslayout/CompactSideMenu.js +81 -29
- package/lib/tntd-layout/paaslayout/Header.js +47 -14
- package/lib/tntd-layout/paaslayout/Logo.js +19 -2
- package/lib/tntd-layout/paaslayout/SideMenu.js +82 -31
- package/lib/tntd-layout/paaslayout/index.js +108 -62
- package/lib/tntd-layout/storage.d.ts +1 -1
- package/lib/tntd-layout/storage.d.ts.map +1 -1
- package/lib/tntd-layout/storage.js +33 -3
- package/lib/tntd-modal/index.js +51 -32
- package/lib/tntd-second-page/index.js +24 -14
- package/lib/tntd-select/DropDownWrap.js +45 -24
- package/lib/tntd-select/index.js +206 -117
- package/lib/tooltip/index.js +10 -4
- package/lib/transfer/index.js +10 -4
- package/lib/tree/index.js +10 -4
- package/lib/tree-select/index.js +10 -4
- package/lib/typography/index.js +10 -4
- package/lib/upload/index.js +10 -4
- package/lib/utils/checkAuth.js +10 -4
- package/lib/utils/findMenuInfoByPath.js +7 -1
- package/lib/utils/index.js +41 -13
- package/lib/version/index.js +10 -4
- package/package.json +1 -1
- package/es/array-input/style/index.js +0 -1
- package/es/array-input/style/index.js.map +0 -1
- package/es/auth-context/style/index.js +0 -1
- package/es/auth-context/style/index.js.map +0 -1
- package/es/development-login/style/index.js +0 -1
- package/es/development-login/style/index.js.map +0 -1
- package/es/ellipsis/style/index.js +0 -1
- package/es/ellipsis/style/index.js.map +0 -1
- package/es/empty/render-empty.js +0 -22
- package/es/empty/render-empty.js.map +0 -1
- package/es/empty/style/index.js +0 -2
- package/es/empty/style/index.js.map +0 -1
- package/es/handle/style/index.js +0 -1
- package/es/handle/style/index.js.map +0 -1
- package/es/icon-list/style/index.js +0 -1
- package/es/icon-list/style/index.js.map +0 -1
- package/es/img/style/index.js +0 -1
- package/es/img/style/index.js.map +0 -1
- package/es/loading-button/style/index.js +0 -1
- package/es/loading-button/style/index.js.map +0 -1
- package/es/page/style/index.js +0 -1
- package/es/page/style/index.js.map +0 -1
- package/es/query-form/style/index.js +0 -1
- package/es/query-form/style/index.js.map +0 -1
- package/es/query-list-scene/style/index.js +0 -1
- package/es/query-list-scene/style/index.js.map +0 -1
- package/es/render-empty/style/index.js +0 -1
- package/es/render-empty/style/index.js.map +0 -1
- package/es/table/style/index.js +0 -2
- package/es/table/style/index.js.map +0 -1
- package/es/title/style/index.js +0 -1
- package/es/title/style/index.js.map +0 -1
- package/es/tntd-icon/style/index.js +0 -1
- package/es/tntd-icon/style/index.js.map +0 -1
- package/es/tntd-layout/style/index.js +0 -1
- package/es/tntd-layout/style/index.js.map +0 -1
- package/es/tntd-modal/style/index.js +0 -1
- package/es/tntd-modal/style/index.js.map +0 -1
- package/es/tntd-select/style/index.js +0 -1
- package/es/tntd-select/style/index.js.map +0 -1
- package/lib/array-input/style/index.d.ts +0 -1
- package/lib/array-input/style/index.d.ts.map +0 -1
- package/lib/array-input/style/index.js +0 -1
- package/lib/array-input/style/index.js.map +0 -1
- package/lib/auth-context/style/index.d.ts +0 -1
- package/lib/auth-context/style/index.d.ts.map +0 -1
- package/lib/auth-context/style/index.js +0 -1
- package/lib/auth-context/style/index.js.map +0 -1
- package/lib/development-login/style/index.d.ts +0 -1
- package/lib/development-login/style/index.d.ts.map +0 -1
- package/lib/development-login/style/index.js +0 -1
- package/lib/development-login/style/index.js.map +0 -1
- package/lib/ellipsis/style/index.d.ts +0 -1
- package/lib/ellipsis/style/index.d.ts.map +0 -1
- package/lib/ellipsis/style/index.js +0 -1
- package/lib/ellipsis/style/index.js.map +0 -1
- package/lib/empty/render-empty.d.ts +0 -3
- package/lib/empty/render-empty.d.ts.map +0 -1
- package/lib/empty/render-empty.js +0 -32
- package/lib/empty/render-empty.js.map +0 -1
- package/lib/empty/style/index.d.ts +0 -3
- package/lib/empty/style/index.d.ts.map +0 -1
- package/lib/empty/style/index.js +0 -4
- package/lib/empty/style/index.js.map +0 -1
- package/lib/handle/style/index.d.ts +0 -1
- package/lib/handle/style/index.d.ts.map +0 -1
- package/lib/handle/style/index.js +0 -1
- package/lib/handle/style/index.js.map +0 -1
- package/lib/icon-list/style/index.d.ts +0 -3
- package/lib/icon-list/style/index.d.ts.map +0 -1
- package/lib/icon-list/style/index.js +0 -8
- package/lib/icon-list/style/index.js.map +0 -1
- package/lib/img/style/index.d.ts +0 -1
- package/lib/img/style/index.d.ts.map +0 -1
- package/lib/img/style/index.js +0 -1
- package/lib/img/style/index.js.map +0 -1
- package/lib/loading-button/style/index.d.ts +0 -1
- package/lib/loading-button/style/index.d.ts.map +0 -1
- package/lib/loading-button/style/index.js +0 -1
- package/lib/loading-button/style/index.js.map +0 -1
- package/lib/page/style/index.d.ts +0 -1
- package/lib/page/style/index.d.ts.map +0 -1
- package/lib/page/style/index.js +0 -1
- package/lib/page/style/index.js.map +0 -1
- package/lib/query-form/style/index.d.ts +0 -1
- package/lib/query-form/style/index.d.ts.map +0 -1
- package/lib/query-form/style/index.js +0 -1
- package/lib/query-form/style/index.js.map +0 -1
- package/lib/query-list-scene/style/index.d.ts +0 -1
- package/lib/query-list-scene/style/index.d.ts.map +0 -1
- package/lib/query-list-scene/style/index.js +0 -1
- package/lib/query-list-scene/style/index.js.map +0 -1
- package/lib/render-empty/style/index.d.ts +0 -2
- package/lib/render-empty/style/index.d.ts.map +0 -1
- package/lib/render-empty/style/index.js +0 -3
- package/lib/render-empty/style/index.js.map +0 -1
- package/lib/table/style/index.d.ts +0 -3
- package/lib/table/style/index.d.ts.map +0 -1
- package/lib/table/style/index.js +0 -4
- package/lib/table/style/index.js.map +0 -1
- package/lib/title/style/index.d.ts +0 -1
- package/lib/title/style/index.d.ts.map +0 -1
- package/lib/title/style/index.js +0 -1
- package/lib/title/style/index.js.map +0 -1
- package/lib/tntd-icon/style/index.d.ts +0 -1
- package/lib/tntd-icon/style/index.d.ts.map +0 -1
- package/lib/tntd-icon/style/index.js +0 -1
- package/lib/tntd-icon/style/index.js.map +0 -1
- package/lib/tntd-layout/style/index.d.ts +0 -1
- package/lib/tntd-layout/style/index.d.ts.map +0 -1
- package/lib/tntd-layout/style/index.js +0 -1
- package/lib/tntd-layout/style/index.js.map +0 -1
- package/lib/tntd-modal/style/index.d.ts +0 -1
- package/lib/tntd-modal/style/index.d.ts.map +0 -1
- package/lib/tntd-modal/style/index.js +0 -1
- package/lib/tntd-modal/style/index.js.map +0 -1
- package/lib/tntd-select/style/index.d.ts +0 -1
- package/lib/tntd-select/style/index.d.ts.map +0 -1
- package/lib/tntd-select/style/index.js +0 -1
- package/lib/tntd-select/style/index.js.map +0 -1
package/es/query-form/index.js
CHANGED
|
@@ -12,6 +12,7 @@ import { getLanguage, getText } from '../prev-locale';
|
|
|
12
12
|
import Icon from '../tntd-icon';
|
|
13
13
|
import './index.less';
|
|
14
14
|
const clsPrefix = 'tnt-queryform';
|
|
15
|
+
|
|
15
16
|
class QueryForm extends React.PureComponent {
|
|
16
17
|
constructor(props) {
|
|
17
18
|
super(props);
|
|
@@ -23,6 +24,7 @@ class QueryForm extends React.PureComponent {
|
|
|
23
24
|
const {
|
|
24
25
|
current
|
|
25
26
|
} = this.fieldsRef;
|
|
27
|
+
|
|
26
28
|
if (current) {
|
|
27
29
|
setTimeout(() => {
|
|
28
30
|
this.setState({
|
|
@@ -46,6 +48,7 @@ class QueryForm extends React.PureComponent {
|
|
|
46
48
|
writable: true,
|
|
47
49
|
value: () => {
|
|
48
50
|
var _a, _b;
|
|
51
|
+
|
|
49
52
|
(_b = (_a = this.props).onSearch) === null || _b === void 0 ? void 0 : _b.call(_a, this.form.getValues());
|
|
50
53
|
}
|
|
51
54
|
});
|
|
@@ -69,6 +72,7 @@ class QueryForm extends React.PureComponent {
|
|
|
69
72
|
writable: true,
|
|
70
73
|
value: () => {
|
|
71
74
|
var _a, _b;
|
|
75
|
+
|
|
72
76
|
this.setState({
|
|
73
77
|
expanded: !this.state.expanded
|
|
74
78
|
});
|
|
@@ -117,14 +121,18 @@ class QueryForm extends React.PureComponent {
|
|
|
117
121
|
showFieldCount,
|
|
118
122
|
children
|
|
119
123
|
} = this.props;
|
|
124
|
+
|
|
120
125
|
if (showFieldCount) {
|
|
121
126
|
const drawerFieldsValueCount = children.reduce((acc, cur, index) => {
|
|
122
127
|
var _a;
|
|
128
|
+
|
|
123
129
|
if (index >= showFieldCount && (values === null || values === void 0 ? void 0 : values[(_a = cur === null || cur === void 0 ? void 0 : cur.props) === null || _a === void 0 ? void 0 : _a.name])) {
|
|
124
130
|
acc++;
|
|
125
131
|
}
|
|
132
|
+
|
|
126
133
|
return acc;
|
|
127
134
|
}, 0);
|
|
135
|
+
|
|
128
136
|
if (drawerFieldsValueCount !== this.state.drawerFieldsValueCount) {
|
|
129
137
|
this.setState({
|
|
130
138
|
drawerFieldsValueCount
|
|
@@ -142,6 +150,7 @@ class QueryForm extends React.PureComponent {
|
|
|
142
150
|
const {
|
|
143
151
|
current
|
|
144
152
|
} = this.fieldsRef;
|
|
153
|
+
|
|
145
154
|
if (current) {
|
|
146
155
|
const observer = new ResizeObserver(this.onWindowResize);
|
|
147
156
|
observer.observe(current);
|
|
@@ -172,6 +181,7 @@ class QueryForm extends React.PureComponent {
|
|
|
172
181
|
this.form.setData('initialValues', initialValues);
|
|
173
182
|
this.form.setData('values', Object.assign({}, initialValues));
|
|
174
183
|
}
|
|
184
|
+
|
|
175
185
|
render() {
|
|
176
186
|
const {
|
|
177
187
|
children,
|
|
@@ -191,6 +201,7 @@ class QueryForm extends React.PureComponent {
|
|
|
191
201
|
drawerVisible,
|
|
192
202
|
drawerFieldsValueCount
|
|
193
203
|
} = this.state;
|
|
204
|
+
|
|
194
205
|
const renderFormActions = renderActions || (() => React.createElement(React.Fragment, null, showFieldCount && React.createElement(Badge, {
|
|
195
206
|
count: drawerFieldsValueCount
|
|
196
207
|
}, React.createElement(Button, {
|
|
@@ -208,8 +219,10 @@ class QueryForm extends React.PureComponent {
|
|
|
208
219
|
onClick: this.onToggleExpand
|
|
209
220
|
}, this.getText(expanded ? 'collapse' : 'expand')), React.Children.map(children, child => {
|
|
210
221
|
var _a;
|
|
222
|
+
|
|
211
223
|
return child && ((_a = child === null || child === void 0 ? void 0 : child.props) === null || _a === void 0 ? void 0 : _a.align) === 'right' && React.cloneElement(child);
|
|
212
224
|
})));
|
|
225
|
+
|
|
213
226
|
return React.createElement("div", {
|
|
214
227
|
ref: this.formBoxRef,
|
|
215
228
|
className: classnames(clsPrefix, {
|
|
@@ -225,6 +238,7 @@ class QueryForm extends React.PureComponent {
|
|
|
225
238
|
ref: this.fieldsRef
|
|
226
239
|
}, React.Children.map(children, (child, index) => {
|
|
227
240
|
var _a;
|
|
241
|
+
|
|
228
242
|
return child && ((_a = child === null || child === void 0 ? void 0 : child.props) === null || _a === void 0 ? void 0 : _a.align) !== 'right' && (!showFieldCount || showFieldCount > index) && React.cloneElement(child, {
|
|
229
243
|
form: this.form,
|
|
230
244
|
initialValue: initialValues === null || initialValues === void 0 ? void 0 : initialValues[child.props.name],
|
|
@@ -261,13 +275,16 @@ class QueryForm extends React.PureComponent {
|
|
|
261
275
|
className: `${clsPrefix}-extra`
|
|
262
276
|
}, extraActions));
|
|
263
277
|
}
|
|
278
|
+
|
|
264
279
|
getText(key) {
|
|
265
280
|
return getText(key, this.props.language || getLanguage());
|
|
266
281
|
}
|
|
282
|
+
|
|
267
283
|
isFieldsWidthOverflow() {
|
|
268
284
|
const {
|
|
269
285
|
current
|
|
270
286
|
} = this.fieldsRef;
|
|
287
|
+
|
|
271
288
|
if (current) {
|
|
272
289
|
return parseFloat(window.getComputedStyle(current).width, 10) < [].reduce.call(current.children, (acc, cur) => {
|
|
273
290
|
const {
|
|
@@ -279,25 +296,33 @@ class QueryForm extends React.PureComponent {
|
|
|
279
296
|
return acc;
|
|
280
297
|
}, 0);
|
|
281
298
|
}
|
|
299
|
+
|
|
282
300
|
return false;
|
|
283
301
|
}
|
|
302
|
+
|
|
284
303
|
updateFieldHeight() {
|
|
285
304
|
var _a, _b, _c;
|
|
305
|
+
|
|
286
306
|
const {
|
|
287
307
|
formBoxRef,
|
|
288
308
|
fieldsRef
|
|
289
309
|
} = this;
|
|
310
|
+
|
|
290
311
|
const getFieldHeight = () => {
|
|
291
312
|
var _a;
|
|
313
|
+
|
|
292
314
|
const {
|
|
293
315
|
current
|
|
294
316
|
} = fieldsRef;
|
|
295
317
|
let height = '32px';
|
|
318
|
+
|
|
296
319
|
if (current && ((_a = current.children) === null || _a === void 0 ? void 0 : _a[0])) {
|
|
297
320
|
height = window.getComputedStyle(current.children[0]).height;
|
|
298
321
|
}
|
|
322
|
+
|
|
299
323
|
return height;
|
|
300
324
|
};
|
|
325
|
+
|
|
301
326
|
const queryFormActionsDom = (_a = formBoxRef === null || formBoxRef === void 0 ? void 0 : formBoxRef.current) === null || _a === void 0 ? void 0 : _a.querySelector(`.${clsPrefix}-actions`);
|
|
302
327
|
const queryFormExtraDom = (_b = formBoxRef === null || formBoxRef === void 0 ? void 0 : formBoxRef.current) === null || _b === void 0 ? void 0 : _b.querySelector(`.${clsPrefix}-extra`);
|
|
303
328
|
const formItemsDomList = (_c = fieldsRef === null || fieldsRef === void 0 ? void 0 : fieldsRef.current) === null || _c === void 0 ? void 0 : _c.querySelectorAll('.ant-form-item-control');
|
|
@@ -313,6 +338,7 @@ class QueryForm extends React.PureComponent {
|
|
|
313
338
|
item.style.lineHeight = fieldHeight;
|
|
314
339
|
});
|
|
315
340
|
}
|
|
341
|
+
|
|
316
342
|
componentDidMount() {
|
|
317
343
|
const {
|
|
318
344
|
current
|
|
@@ -322,18 +348,20 @@ class QueryForm extends React.PureComponent {
|
|
|
322
348
|
showExpand = true
|
|
323
349
|
} = this.props;
|
|
324
350
|
this.updateFieldHeight();
|
|
325
|
-
this.form.on('search', this.search);
|
|
326
|
-
// 未设置第一行显示数量且禁止了展开操作 或 自定义了操作区域,则不需要处理展开计算逻辑
|
|
351
|
+
this.form.on('search', this.search); // 未设置第一行显示数量且禁止了展开操作 或 自定义了操作区域,则不需要处理展开计算逻辑
|
|
327
352
|
// || renderActions
|
|
353
|
+
|
|
328
354
|
if (!showFieldCount && !showExpand) {
|
|
329
355
|
return;
|
|
330
356
|
}
|
|
357
|
+
|
|
331
358
|
if (!showFieldCount) {
|
|
332
359
|
if (current && this.isFieldsWidthOverflow()) {
|
|
333
360
|
this.setState({
|
|
334
361
|
showMore: true
|
|
335
362
|
});
|
|
336
363
|
}
|
|
364
|
+
|
|
337
365
|
this.removeResizeListener = this.addResizeListener();
|
|
338
366
|
} else {
|
|
339
367
|
this.updateDrawerFieldsValueCount();
|
|
@@ -341,14 +369,18 @@ class QueryForm extends React.PureComponent {
|
|
|
341
369
|
this.form.on('setValue', this.updateDrawerFieldsValueCount);
|
|
342
370
|
}
|
|
343
371
|
}
|
|
372
|
+
|
|
344
373
|
componentWillUnmount() {
|
|
345
374
|
var _a;
|
|
375
|
+
|
|
346
376
|
(_a = this.removeResizeListener) === null || _a === void 0 ? void 0 : _a.call(this);
|
|
347
377
|
this.form.off('setValues', this.updateDrawerFieldsValueCount);
|
|
348
378
|
this.form.off('setValue', this.updateDrawerFieldsValueCount);
|
|
349
379
|
this.form.off('search', this.search);
|
|
350
380
|
}
|
|
381
|
+
|
|
351
382
|
}
|
|
383
|
+
|
|
352
384
|
QueryForm.Field = Field;
|
|
353
385
|
QueryForm.useForm = useForm;
|
|
354
386
|
QueryForm.createForm = createActions;
|
|
@@ -3,9 +3,12 @@ import _pickBy from "lodash/pickBy";
|
|
|
3
3
|
import _isEmpty from "lodash/isEmpty";
|
|
4
4
|
import _get from "lodash/get";
|
|
5
5
|
import _debounce from "lodash/debounce";
|
|
6
|
+
|
|
6
7
|
var __rest = this && this.__rest || function (s, e) {
|
|
7
8
|
var t = {};
|
|
9
|
+
|
|
8
10
|
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0) t[p] = s[p];
|
|
11
|
+
|
|
9
12
|
if (s != null && typeof Object.getOwnPropertySymbols === "function") for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {
|
|
10
13
|
if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i])) t[p[i]] = s[p[i]];
|
|
11
14
|
}
|
|
@@ -15,6 +18,8 @@ var __rest = this && this.__rest || function (s, e) {
|
|
|
15
18
|
* @file QueryList
|
|
16
19
|
* @author you.zhang
|
|
17
20
|
*/
|
|
21
|
+
|
|
22
|
+
|
|
18
23
|
import cn from 'classnames';
|
|
19
24
|
import React, { createRef } from 'react';
|
|
20
25
|
import { findDOMNode } from 'react-dom';
|
|
@@ -24,6 +29,7 @@ import Table from '../table';
|
|
|
24
29
|
export default class QueryList extends React.PureComponent {
|
|
25
30
|
constructor(props) {
|
|
26
31
|
var _a;
|
|
32
|
+
|
|
27
33
|
super(props);
|
|
28
34
|
Object.defineProperty(this, "onWindowResize", {
|
|
29
35
|
enumerable: true,
|
|
@@ -61,19 +67,22 @@ export default class QueryList extends React.PureComponent {
|
|
|
61
67
|
pagination
|
|
62
68
|
} = this.state;
|
|
63
69
|
const hasPagination = this.props.pagination !== false;
|
|
70
|
+
|
|
64
71
|
if (hasPagination) {
|
|
65
72
|
params = Object.assign({
|
|
66
73
|
pageSize: pagination.pageSize,
|
|
67
74
|
current: pagination.current
|
|
68
75
|
}, params);
|
|
69
76
|
}
|
|
77
|
+
|
|
70
78
|
showLoading && this.setState({
|
|
71
79
|
loading: true
|
|
72
|
-
});
|
|
73
|
-
|
|
80
|
+
}); // 当用户操作查询还未得到服务端响应前,不要执行轮询请求时序问题导致覆盖
|
|
81
|
+
|
|
74
82
|
if (!isInterval) {
|
|
75
83
|
this.isFetching = true;
|
|
76
84
|
}
|
|
85
|
+
|
|
77
86
|
actions.setData('submittedFormData', params);
|
|
78
87
|
return query(_pickBy(params, val => val !== '' && val !== null && val !== undefined)).then(result => {
|
|
79
88
|
const dataSource = hasPagination ? result.data || [] : result;
|
|
@@ -141,8 +150,8 @@ export default class QueryList extends React.PureComponent {
|
|
|
141
150
|
callback,
|
|
142
151
|
showLoading = true
|
|
143
152
|
} = {}) => {
|
|
144
|
-
this.formData = Object.assign(Object.assign({}, this.formData), values);
|
|
145
|
-
|
|
153
|
+
this.formData = Object.assign(Object.assign({}, this.formData), values); // this.props.actions.setData('formData', this.formData);
|
|
154
|
+
|
|
146
155
|
return this.fetchData(this.formData, {
|
|
147
156
|
callback,
|
|
148
157
|
showLoading
|
|
@@ -165,17 +174,18 @@ export default class QueryList extends React.PureComponent {
|
|
|
165
174
|
sorter: _isEmpty(sorter) ? undefined : sorter
|
|
166
175
|
};
|
|
167
176
|
console.log('onTableChange...', actions.getSubmittedFormData(), this.formData);
|
|
168
|
-
Object.assign(this.formData, tableParams);
|
|
169
|
-
// 排序变化暂时不处理,因为有时可能是前端sorter不需要走请求
|
|
177
|
+
Object.assign(this.formData, tableParams); // 排序变化暂时不处理,因为有时可能是前端sorter不需要走请求
|
|
170
178
|
// 所以暂时排序有使用者自己处理
|
|
179
|
+
|
|
171
180
|
if (!localPagination) {
|
|
172
181
|
this.fetchData(Object.assign(Object.assign({}, actions.getSubmittedFormData()), tableParams));
|
|
173
182
|
return;
|
|
174
183
|
}
|
|
184
|
+
|
|
175
185
|
const {
|
|
176
186
|
dataSource
|
|
177
|
-
} = this.state;
|
|
178
|
-
|
|
187
|
+
} = this.state; // 前端本地分页
|
|
188
|
+
|
|
179
189
|
if (localPagination) {
|
|
180
190
|
this.setState({
|
|
181
191
|
dataSource,
|
|
@@ -213,6 +223,7 @@ export default class QueryList extends React.PureComponent {
|
|
|
213
223
|
} = tableBody;
|
|
214
224
|
return scrollHeight === scrollTop + offsetHeight;
|
|
215
225
|
};
|
|
226
|
+
|
|
216
227
|
this.setState({
|
|
217
228
|
hasScrollToBottom: isScrollToBottom(tableBody)
|
|
218
229
|
});
|
|
@@ -238,18 +249,20 @@ export default class QueryList extends React.PureComponent {
|
|
|
238
249
|
actions.on('setPagination', this.updatePagination);
|
|
239
250
|
actions.on('setFormData', this.onFormChange);
|
|
240
251
|
}
|
|
252
|
+
|
|
241
253
|
render() {
|
|
242
254
|
const _a = this.props,
|
|
243
|
-
|
|
244
|
-
|
|
245
|
-
|
|
246
|
-
|
|
247
|
-
|
|
248
|
-
|
|
249
|
-
|
|
250
|
-
|
|
251
|
-
|
|
252
|
-
|
|
255
|
+
{
|
|
256
|
+
columns,
|
|
257
|
+
children,
|
|
258
|
+
pagination,
|
|
259
|
+
localPagination = false,
|
|
260
|
+
paginationSticky = false,
|
|
261
|
+
className = '',
|
|
262
|
+
qlsProps
|
|
263
|
+
} = _a,
|
|
264
|
+
rest = __rest(_a, ["columns", "children", "pagination", "localPagination", "paginationSticky", "className", "qlsProps"]);
|
|
265
|
+
|
|
253
266
|
const {
|
|
254
267
|
dataSource,
|
|
255
268
|
loading,
|
|
@@ -286,13 +299,16 @@ export default class QueryList extends React.PureComponent {
|
|
|
286
299
|
onChange: this.onTableChange
|
|
287
300
|
}), !columns && children)));
|
|
288
301
|
}
|
|
302
|
+
|
|
289
303
|
componentDidMount() {
|
|
290
304
|
var _a;
|
|
305
|
+
|
|
291
306
|
const {
|
|
292
307
|
qlsProps,
|
|
293
308
|
actions
|
|
294
309
|
} = this.props;
|
|
295
310
|
this.formData = Object.assign(Object.assign({}, actions.getFormData() || {}), qlsProps.memory ? actions.getPagination() : {});
|
|
311
|
+
|
|
296
312
|
if (!qlsProps.initSearch) {
|
|
297
313
|
// 默认进来不请求
|
|
298
314
|
this.fetchData(this.formData).finally(() => {
|
|
@@ -316,12 +332,15 @@ export default class QueryList extends React.PureComponent {
|
|
|
316
332
|
}, ms);
|
|
317
333
|
}
|
|
318
334
|
};
|
|
335
|
+
|
|
319
336
|
doIntervalQuery(qlsProps.interval);
|
|
320
337
|
}
|
|
321
338
|
});
|
|
322
339
|
}
|
|
340
|
+
|
|
323
341
|
if ((_a = this.state.scroll) === null || _a === void 0 ? void 0 : _a.y) {
|
|
324
342
|
window.addEventListener('resize', this.onWindowResize);
|
|
343
|
+
|
|
325
344
|
if (this.tableRef.current) {
|
|
326
345
|
// table内垂直滚动,需要动态设置分页组件上阴影样式
|
|
327
346
|
const tableBody = findDOMNode(this.tableRef.current).querySelector('.ant-table-body');
|
|
@@ -331,6 +350,7 @@ export default class QueryList extends React.PureComponent {
|
|
|
331
350
|
}
|
|
332
351
|
}
|
|
333
352
|
}
|
|
353
|
+
|
|
334
354
|
componentWillUnmount() {
|
|
335
355
|
const {
|
|
336
356
|
actions
|
|
@@ -343,4 +363,5 @@ export default class QueryList extends React.PureComponent {
|
|
|
343
363
|
window.removeEventListener('resize', this.onWindowResize);
|
|
344
364
|
this.timmer && clearTimeout(this.timmer);
|
|
345
365
|
}
|
|
366
|
+
|
|
346
367
|
}
|
|
@@ -1,11 +1,14 @@
|
|
|
1
1
|
var __rest = this && this.__rest || function (s, e) {
|
|
2
2
|
var t = {};
|
|
3
|
+
|
|
3
4
|
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0) t[p] = s[p];
|
|
5
|
+
|
|
4
6
|
if (s != null && typeof Object.getOwnPropertySymbols === "function") for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {
|
|
5
7
|
if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i])) t[p[i]] = s[p[i]];
|
|
6
8
|
}
|
|
7
9
|
return t;
|
|
8
10
|
};
|
|
11
|
+
|
|
9
12
|
import React from 'react';
|
|
10
13
|
import classnames from 'classnames';
|
|
11
14
|
import Form from '../query-form';
|
|
@@ -25,8 +28,8 @@ export default class QueryForm extends React.PureComponent {
|
|
|
25
28
|
const values = actions.getFormData();
|
|
26
29
|
const params = Object.assign(Object.assign({}, values), {
|
|
27
30
|
current: 1
|
|
28
|
-
});
|
|
29
|
-
|
|
31
|
+
}); // memory 与 url解析setForm时 监听事件异步
|
|
32
|
+
|
|
30
33
|
actions.setData('formData', values);
|
|
31
34
|
Promise.resolve().then(() => {
|
|
32
35
|
onSearch && onSearch(params);
|
|
@@ -96,16 +99,18 @@ export default class QueryForm extends React.PureComponent {
|
|
|
96
99
|
actions.on('setFormData', this.setFormData);
|
|
97
100
|
actions.on('resetFormData', this.resetFormData);
|
|
98
101
|
}
|
|
102
|
+
|
|
99
103
|
render() {
|
|
100
104
|
const _a = this.props,
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
105
|
+
{
|
|
106
|
+
className,
|
|
107
|
+
actions,
|
|
108
|
+
extraActions,
|
|
109
|
+
extralActions,
|
|
110
|
+
qlsProps
|
|
111
|
+
} = _a,
|
|
112
|
+
props = __rest(_a, ["className", "actions", "extraActions", "extralActions", "qlsProps"]);
|
|
113
|
+
|
|
109
114
|
return React.createElement(Form, Object.assign({}, props, {
|
|
110
115
|
form: this.form,
|
|
111
116
|
className: classnames(clsPrefix, {
|
|
@@ -118,18 +123,21 @@ export default class QueryForm extends React.PureComponent {
|
|
|
118
123
|
onReset: this.onReset
|
|
119
124
|
}));
|
|
120
125
|
}
|
|
126
|
+
|
|
121
127
|
componentDidMount() {
|
|
122
128
|
const {
|
|
123
129
|
initialValues = {},
|
|
124
130
|
actions,
|
|
125
131
|
qlsProps
|
|
126
132
|
} = this.props;
|
|
133
|
+
|
|
127
134
|
if (qlsProps.memory) {
|
|
128
135
|
actions.setFormData(Object.assign(Object.assign({}, initialValues), actions.getFormData()), false);
|
|
129
136
|
} else {
|
|
130
137
|
actions.setData('formData', initialValues);
|
|
131
138
|
}
|
|
132
139
|
}
|
|
140
|
+
|
|
133
141
|
componentWillUnmount() {
|
|
134
142
|
const {
|
|
135
143
|
actions
|
|
@@ -137,5 +145,6 @@ export default class QueryForm extends React.PureComponent {
|
|
|
137
145
|
actions.removeListener('setFormData', this.setFormData);
|
|
138
146
|
actions.removeListener('resetFormData', this.resetFormData);
|
|
139
147
|
}
|
|
148
|
+
|
|
140
149
|
}
|
|
141
150
|
QueryForm.Field = Form.Field;
|
|
@@ -8,6 +8,7 @@ export default class QueryListScene extends React.Component {
|
|
|
8
8
|
super(props);
|
|
9
9
|
this.actions = props.actions || createActions();
|
|
10
10
|
}
|
|
11
|
+
|
|
11
12
|
render() {
|
|
12
13
|
const {
|
|
13
14
|
title,
|
|
@@ -32,4 +33,5 @@ export default class QueryListScene extends React.Component {
|
|
|
32
33
|
actions: this.actions
|
|
33
34
|
}))));
|
|
34
35
|
}
|
|
36
|
+
|
|
35
37
|
}
|
|
@@ -1,21 +1,25 @@
|
|
|
1
1
|
var __rest = this && this.__rest || function (s, e) {
|
|
2
2
|
var t = {};
|
|
3
|
+
|
|
3
4
|
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0) t[p] = s[p];
|
|
5
|
+
|
|
4
6
|
if (s != null && typeof Object.getOwnPropertySymbols === "function") for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {
|
|
5
7
|
if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i])) t[p[i]] = s[p[i]];
|
|
6
8
|
}
|
|
7
9
|
return t;
|
|
8
10
|
};
|
|
11
|
+
|
|
9
12
|
import React from 'react';
|
|
10
13
|
import cn from 'classnames';
|
|
11
14
|
export default (_a => {
|
|
12
15
|
var {
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
16
|
+
className,
|
|
17
|
+
children,
|
|
18
|
+
actions,
|
|
19
|
+
qslProps
|
|
20
|
+
} = _a,
|
|
21
|
+
rest = __rest(_a, ["className", "children", "actions", "qslProps"]);
|
|
22
|
+
|
|
19
23
|
return React.createElement("div", Object.assign({}, rest, {
|
|
20
24
|
className: cn('tnt-querylistscene-toolbar', {
|
|
21
25
|
[className]: className
|
|
@@ -19,6 +19,7 @@ export default (() => {
|
|
|
19
19
|
getPagination: () => _get(data, 'pagination'),
|
|
20
20
|
setFormData: (formData, needSearch = true) => {
|
|
21
21
|
_set('formData', formData);
|
|
22
|
+
|
|
22
23
|
eventEmitter.emit('setFormData', formData, needSearch);
|
|
23
24
|
},
|
|
24
25
|
resetFormData: (needSearch = false) => {
|
|
@@ -26,10 +27,12 @@ export default (() => {
|
|
|
26
27
|
},
|
|
27
28
|
setTableDataSource: dataSource => {
|
|
28
29
|
_set('dataSource', dataSource);
|
|
30
|
+
|
|
29
31
|
eventEmitter.emit('setTableDataSource', dataSource);
|
|
30
32
|
},
|
|
31
33
|
setPagination: pagination => {
|
|
32
34
|
_set('pagination', pagination);
|
|
35
|
+
|
|
33
36
|
eventEmitter.emit('setPagination', pagination);
|
|
34
37
|
},
|
|
35
38
|
// 重置记忆数据,form、pagination
|
|
@@ -8,6 +8,7 @@ export const renderEmpty = componentName => React.createElement(ConfigConsumer,
|
|
|
8
8
|
return React.createElement(Empty, {
|
|
9
9
|
type: "no-result"
|
|
10
10
|
});
|
|
11
|
+
|
|
11
12
|
case 'Select':
|
|
12
13
|
case 'TreeSelect':
|
|
13
14
|
case 'Cascader':
|
|
@@ -16,6 +17,7 @@ export const renderEmpty = componentName => React.createElement(ConfigConsumer,
|
|
|
16
17
|
return React.createElement(Empty, {
|
|
17
18
|
size: "mini"
|
|
18
19
|
});
|
|
20
|
+
|
|
19
21
|
default:
|
|
20
22
|
return React.createElement(Empty, null);
|
|
21
23
|
}
|
package/es/steps/steps.js
CHANGED
|
@@ -1,11 +1,14 @@
|
|
|
1
1
|
var __rest = this && this.__rest || function (s, e) {
|
|
2
2
|
var t = {};
|
|
3
|
+
|
|
3
4
|
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0) t[p] = s[p];
|
|
5
|
+
|
|
4
6
|
if (s != null && typeof Object.getOwnPropertySymbols === "function") for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {
|
|
5
7
|
if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i])) t[p[i]] = s[p[i]];
|
|
6
8
|
}
|
|
7
9
|
return t;
|
|
8
10
|
};
|
|
11
|
+
|
|
9
12
|
import classNames from 'classnames';
|
|
10
13
|
import React from 'react';
|
|
11
14
|
import { ConfigConsumer } from 'antd/es/config-provider';
|
|
@@ -13,12 +16,14 @@ import { default as AntdSteps } from 'antd/es/steps';
|
|
|
13
16
|
export * from 'antd/es/steps';
|
|
14
17
|
export function Steps(_a) {
|
|
15
18
|
var {
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
19
|
+
className,
|
|
20
|
+
type,
|
|
21
|
+
children
|
|
22
|
+
} = _a,
|
|
23
|
+
rest = __rest(_a, ["className", "type", "children"]);
|
|
24
|
+
|
|
21
25
|
let navContainDesc = false;
|
|
26
|
+
|
|
22
27
|
if (children) {
|
|
23
28
|
if (Array.isArray(children)) {
|
|
24
29
|
navContainDesc = children.some(child => {
|
|
@@ -28,6 +33,7 @@ export function Steps(_a) {
|
|
|
28
33
|
});
|
|
29
34
|
}
|
|
30
35
|
}
|
|
36
|
+
|
|
31
37
|
return React.createElement(ConfigConsumer, null, ({
|
|
32
38
|
getPrefixCls
|
|
33
39
|
}) => {
|
|
@@ -42,12 +48,14 @@ export function Steps(_a) {
|
|
|
42
48
|
}, rest));
|
|
43
49
|
});
|
|
44
50
|
}
|
|
51
|
+
|
|
45
52
|
Steps.Step = function (_a) {
|
|
46
53
|
var {
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
54
|
+
description,
|
|
55
|
+
className
|
|
56
|
+
} = _a,
|
|
57
|
+
rest = __rest(_a, ["description", "className"]);
|
|
58
|
+
|
|
51
59
|
return React.createElement(ConfigConsumer, null, ({
|
|
52
60
|
getPrefixCls
|
|
53
61
|
}) => {
|
package/es/steps/style/nav.less
CHANGED
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import * as React from 'react';
|
|
2
|
+
|
|
2
3
|
function SvgIllustration403(props, svgRef) {
|
|
3
4
|
return React.createElement("svg", Object.assign({
|
|
4
5
|
viewBox: "0 0 330 250",
|
|
@@ -206,6 +207,7 @@ function SvgIllustration403(props, svgRef) {
|
|
|
206
207
|
fillRule: "nonzero"
|
|
207
208
|
})))));
|
|
208
209
|
}
|
|
210
|
+
|
|
209
211
|
const ForwardRef = React.forwardRef(SvgIllustration403);
|
|
210
212
|
const MemoForwardRef = React.memo(ForwardRef);
|
|
211
213
|
export default MemoForwardRef;
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import * as React from 'react';
|
|
2
|
+
|
|
2
3
|
function SvgIllustration404(props, svgRef) {
|
|
3
4
|
return React.createElement("svg", Object.assign({
|
|
4
5
|
viewBox: "0 0 330 250",
|
|
@@ -290,6 +291,7 @@ function SvgIllustration404(props, svgRef) {
|
|
|
290
291
|
fill: "#D6DAE1"
|
|
291
292
|
}))));
|
|
292
293
|
}
|
|
294
|
+
|
|
293
295
|
const ForwardRef = React.forwardRef(SvgIllustration404);
|
|
294
296
|
const MemoForwardRef = React.memo(ForwardRef);
|
|
295
297
|
export default MemoForwardRef;
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import * as React from 'react';
|
|
2
|
+
|
|
2
3
|
function SvgIllustration500(props, svgRef) {
|
|
3
4
|
return React.createElement("svg", Object.assign({
|
|
4
5
|
viewBox: "0 0 330 250",
|
|
@@ -321,6 +322,7 @@ function SvgIllustration500(props, svgRef) {
|
|
|
321
322
|
d: "M77.945 35.44a1.074 1.074 0 002.112 0l.704-9.68A1.764 1.764 0 0079 24a1.81 1.81 0 00-1.76 1.936l.704 9.504zM79 38.08a1.76 1.76 0 101.76 1.76A1.663 1.663 0 0079 38.08z"
|
|
322
323
|
}))));
|
|
323
324
|
}
|
|
325
|
+
|
|
324
326
|
const ForwardRef = React.forwardRef(SvgIllustration500);
|
|
325
327
|
const MemoForwardRef = React.memo(ForwardRef);
|
|
326
328
|
export default MemoForwardRef;
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import * as React from 'react';
|
|
2
|
+
|
|
2
3
|
function SvgIllustrationEmpty(props, svgRef) {
|
|
3
4
|
return React.createElement("svg", Object.assign({
|
|
4
5
|
viewBox: "0 0 80 50",
|
|
@@ -54,6 +55,7 @@ function SvgIllustrationEmpty(props, svgRef) {
|
|
|
54
55
|
r: 5.186
|
|
55
56
|
})))));
|
|
56
57
|
}
|
|
58
|
+
|
|
57
59
|
const ForwardRef = React.forwardRef(SvgIllustrationEmpty);
|
|
58
60
|
const MemoForwardRef = React.memo(ForwardRef);
|
|
59
61
|
export default MemoForwardRef;
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import * as React from 'react';
|
|
2
|
+
|
|
2
3
|
function SvgIllustrationFailure(props, svgRef) {
|
|
3
4
|
return React.createElement("svg", Object.assign({
|
|
4
5
|
viewBox: "0 0 160 160",
|
|
@@ -112,6 +113,7 @@ function SvgIllustrationFailure(props, svgRef) {
|
|
|
112
113
|
fillRule: "nonzero"
|
|
113
114
|
})));
|
|
114
115
|
}
|
|
116
|
+
|
|
115
117
|
const ForwardRef = React.forwardRef(SvgIllustrationFailure);
|
|
116
118
|
const MemoForwardRef = React.memo(ForwardRef);
|
|
117
119
|
export default MemoForwardRef;
|