@aplus-frontend/ui 7.0.0-beta.2 → 7.0.0
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/index.mjs +216 -218
- package/es/src/ag-grid/editable/form-item.vue.mjs +68 -63
- package/es/src/ag-grid/editable/index.vue.mjs +66 -61
- package/es/src/ag-grid/editable/interface.d.ts +3 -1
- package/es/src/ag-grid/hooks/use-columns-def.mjs +71 -70
- package/es/src/ag-grid/hooks/use-editable-form-item-api.mjs +65 -63
- package/es/src/ag-grid/index.vue.mjs +1 -0
- package/es/src/ag-grid/interface.d.ts +1 -0
- package/es/src/ag-grid/style/custom-header.d.ts +2 -2
- package/es/src/ag-grid/style/editable.d.ts +2 -2
- package/es/src/ag-grid/style/index.d.ts +30 -3
- package/es/src/ag-grid/style/index.mjs +56 -43
- package/es/src/ag-grid/theme.mjs +12 -11
- package/es/src/ap-action/item/index.vue2.mjs +14 -12
- package/es/src/ap-action/item-dropdown/index.vue.mjs +18 -17
- package/es/src/ap-action/style/dropdown-item.d.ts +2 -2
- package/es/src/ap-action/style/dropdown-item.mjs +4 -4
- package/es/src/ap-action/style/index.d.ts +7 -4
- package/es/src/ap-action/style/index.mjs +29 -23
- package/es/src/ap-button/ap-button.vue.mjs +45 -49
- package/es/src/ap-button/style/index.d.ts +2 -2
- package/es/src/ap-button/style/index.mjs +5 -4
- package/es/src/ap-button/utils/index.mjs +16 -16
- package/es/src/ap-descriptions/style/index.d.ts +2 -2
- package/es/src/ap-download/ap-download.vue.d.ts +4 -4
- package/es/src/ap-download/ap-download.vue.mjs +27 -27
- package/es/src/ap-download/hooks/useStyle.mjs +9 -9
- package/es/src/ap-download/interface.d.ts +4 -0
- package/es/src/ap-download/style/index.d.ts +2 -2
- package/es/src/ap-drawer/style/index.d.ts +2 -2
- package/es/src/ap-field/style/index.d.ts +2 -2
- package/es/src/ap-form/style/drawer-form.d.ts +2 -2
- package/es/src/ap-form/style/item-group.d.ts +2 -2
- package/es/src/ap-form/style/item-text-group.d.ts +2 -2
- package/es/src/ap-form/style/item.d.ts +3 -4
- package/es/src/ap-form/style/item.mjs +12 -16
- package/es/src/ap-form/style/modal-form.d.ts +4 -3
- package/es/src/ap-form/style/modal-form.mjs +26 -13
- package/es/src/ap-form/style/search-form-sorter.d.ts +4 -3
- package/es/src/ap-form/style/search-form-sorter.mjs +20 -13
- package/es/src/ap-form/style/search-form.d.ts +2 -2
- package/es/src/ap-form/style/token.d.ts +25 -1
- package/es/src/ap-grid/hooks/use-table-style.mjs +1 -1
- package/es/src/ap-grid/index.vue.mjs +2 -2
- package/es/src/ap-grid/style/editable.d.ts +2 -2
- package/es/src/ap-grid/style/index.d.ts +6 -3
- package/es/src/ap-grid/style/index.mjs +10 -7
- package/es/src/ap-grid/utils/col.mjs +33 -33
- package/es/src/ap-list/style/index.d.ts +2 -2
- package/es/src/ap-modal/interface.d.ts +31 -11
- package/es/src/ap-modal/utils/createModal.mjs +52 -45
- package/es/src/ap-pro-card/style/divider.d.ts +2 -2
- package/es/src/ap-pro-card/style/index.d.ts +2 -2
- package/es/src/ap-pro-card/style/operation.d.ts +2 -2
- package/es/src/ap-pro-card/style/statistic.d.ts +2 -2
- package/es/src/ap-pro-card/style/statistics-card.d.ts +2 -2
- package/es/src/ap-pro-card/style/title.d.ts +2 -2
- package/es/src/ap-table/ap-table.vue2.mjs +2 -2
- package/es/src/ap-table/style/ellipsis.d.ts +2 -2
- package/es/src/ap-table/style/index-comp.d.ts +2 -2
- package/es/src/ap-table/style/index.d.ts +2 -2
- package/es/src/ap-table/style/setting.d.ts +2 -2
- package/es/src/ap-table/utils.mjs +14 -11
- package/es/src/ap-tag/ap-tag.vue.mjs +7 -6
- package/es/src/ap-tag/style/group.d.ts +2 -2
- package/es/src/ap-tag/style/index.d.ts +2 -2
- package/es/src/ap-upload/style/index.d.ts +2 -2
- package/es/src/business/ag-grid-modal/style/index.d.ts +2 -2
- package/es/src/business/ag-grid-modal/style/selected-items.d.ts +2 -2
- package/es/src/business/ag-grid-modal/utils.mjs +23 -23
- package/es/src/business/ap-appendix/style/index.d.ts +5 -4
- package/es/src/business/ap-appendix/style/index.mjs +20 -17
- package/es/src/business/ap-appendix/style/token.d.ts +4 -0
- package/es/src/business/ap-appendix/style/token.mjs +6 -0
- package/es/src/business/ap-attachment/ApAttachment.mjs +64 -60
- package/es/src/business/ap-attachment/style/index.d.ts +2 -2
- package/es/src/business/ap-attachment/style/index.mjs +1 -0
- package/es/src/business/ap-batch-action/style/index.d.ts +3 -3
- package/es/src/business/ap-batch-action/style/index.mjs +4 -4
- package/es/src/business/ap-batch-action-group/ApBatchActionGroup.vue2.mjs +50 -56
- package/es/src/business/ap-batch-action-group/style/index.d.ts +3 -0
- package/es/src/business/ap-batch-action-group/style/index.mjs +14 -0
- package/es/src/business/ap-card/style/index.d.ts +3 -3
- package/es/src/business/ap-card/style/index.mjs +8 -8
- package/es/src/business/ap-copy/style/index.d.ts +2 -2
- package/es/src/business/ap-draggable-grid/style/index.d.ts +2 -2
- package/es/src/business/ap-expand-alert/ApExpandAlert.vue.d.ts +3 -2
- package/es/src/business/ap-expand-alert/ApExpandAlert.vue2.mjs +57 -49
- package/es/src/business/ap-expand-alert/index.d.ts +5 -2
- package/es/src/business/ap-expand-alert/interface.d.ts +1 -1
- package/es/src/business/ap-expand-alert/style/index.d.ts +2 -2
- package/es/src/business/ap-image/style/index.d.ts +3 -3
- package/es/src/business/ap-image/style/index.mjs +6 -6
- package/es/src/business/ap-input-radio/style/index.d.ts +2 -2
- package/es/src/business/ap-label/style/index.d.ts +2 -2
- package/es/src/business/ap-ladder/style/index.d.ts +2 -2
- package/es/src/business/ap-product-info/style/index.d.ts +2 -2
- package/es/src/business/ap-radio-group/style/index.d.ts +2 -2
- package/es/src/business/ap-radio-group/style/index.mjs +3 -3
- package/es/src/business/ap-select-layout/style/index.d.ts +2 -2
- package/es/src/business/ap-size-input/style/index.d.ts +2 -2
- package/es/src/business/ap-status/style/index.d.ts +2 -2
- package/es/src/business/ap-summary/style/index.d.ts +2 -2
- package/es/src/business/ap-table-modal/style/index.d.ts +2 -2
- package/es/src/business/ap-table-modal/table-modal.vue2.mjs +23 -23
- package/es/src/business/ap-title/style/index.d.ts +2 -2
- package/es/src/business/ap-upload-file/ap-upload-single/style/index.d.ts +2 -2
- package/es/src/business/ap-value-select-card/style/index.d.ts +2 -2
- package/es/src/business/ap-view/style/index.d.ts +3 -3
- package/es/src/business/ap-view/style/index.mjs +19 -22
- package/es/src/business/batch-input-group/style/index.d.ts +5 -2
- package/es/src/business/batch-input-group/style/index.mjs +9 -5
- package/es/src/business/hooks/usePageListAgGrid.mjs +7 -6
- package/es/src/check-card/style/index.d.ts +2 -2
- package/es/src/check-card/style/index.mjs +37 -31
- package/es/src/config-provider/config-provider.d.ts +1 -2
- package/es/src/config-provider/hooks/use-global-config.d.ts +1 -2
- package/es/src/config-provider/hooks/use-global-config.mjs +42 -33
- package/es/src/config-provider/hooks/use-token.d.ts +7 -2
- package/es/src/config-provider/hooks/use-token.mjs +6 -3
- package/es/src/config-provider/index.d.ts +1 -2
- package/es/src/design-token/constants.d.ts +1 -6
- package/es/src/design-token/constants.mjs +2 -100
- package/es/src/design-token/index.d.ts +1 -1
- package/es/src/design-token/index.mjs +5 -6
- package/es/src/design-token/interface.d.ts +9 -1
- package/es/src/design-token/interface.mjs +1 -0
- package/es/src/editable-table/style/index.d.ts +2 -2
- package/es/src/full-screen/index.vue.mjs +31 -30
- package/es/src/full-screen/style/index.d.ts +2 -2
- package/es/src/index.mjs +196 -198
- package/es/src/mask/style/index.d.ts +2 -2
- package/es/src/mask/style/index.mjs +2 -2
- package/es/src/scroll-bar/style/index.d.ts +2 -2
- package/es/src/scroll-bar/style/index.mjs +17 -17
- package/es/src/scroll-view/style/index.d.ts +2 -2
- package/es/src/splitter/style/index.d.ts +11 -3
- package/es/src/splitter/style/index.mjs +1 -2
- package/es/src/text/style/group.d.ts +2 -2
- package/es/src/text/style/index.d.ts +6 -3
- package/es/src/text/style/index.mjs +22 -18
- package/es/src/utils/cssinjs/index.d.ts +3 -7
- package/es/src/utils/cssinjs/index.mjs +55 -39
- package/es/src/utils/cssinjs/instance.mjs +7 -7
- package/es/src/utils/cssinjs/plugin-append-cssvar.d.ts +6 -0
- package/es/src/utils/cssinjs/plugin-append-cssvar.mjs +6 -0
- package/es/src/utils/cssinjs/plugin-specificity.mjs +6 -6
- package/es/src/utils/cssinjs/utils.d.ts +6 -0
- package/es/src/utils/cssinjs/utils.mjs +15 -0
- package/es/src/version.d.ts +1 -1
- package/es/src/version.mjs +1 -1
- package/lib/index.js +1 -1
- package/lib/src/ag-grid/editable/form-item.vue.js +1 -1
- package/lib/src/ag-grid/editable/index.vue.js +1 -1
- package/lib/src/ag-grid/editable/interface.d.ts +3 -1
- package/lib/src/ag-grid/hooks/use-columns-def.js +1 -1
- package/lib/src/ag-grid/hooks/use-editable-form-item-api.js +1 -1
- package/lib/src/ag-grid/index.vue.js +1 -1
- package/lib/src/ag-grid/interface.d.ts +1 -0
- package/lib/src/ag-grid/style/custom-header.d.ts +2 -2
- package/lib/src/ag-grid/style/editable.d.ts +2 -2
- package/lib/src/ag-grid/style/index.d.ts +30 -3
- package/lib/src/ag-grid/style/index.js +1 -1
- package/lib/src/ag-grid/theme.js +1 -1
- package/lib/src/ap-action/item/index.vue2.js +1 -1
- package/lib/src/ap-action/item-dropdown/index.vue.js +1 -1
- package/lib/src/ap-action/style/dropdown-item.d.ts +2 -2
- package/lib/src/ap-action/style/dropdown-item.js +1 -1
- package/lib/src/ap-action/style/index.d.ts +7 -4
- package/lib/src/ap-action/style/index.js +1 -1
- package/lib/src/ap-button/ap-button.vue.js +1 -1
- package/lib/src/ap-button/style/index.d.ts +2 -2
- package/lib/src/ap-button/style/index.js +1 -1
- package/lib/src/ap-button/utils/index.js +1 -1
- package/lib/src/ap-descriptions/style/index.d.ts +2 -2
- package/lib/src/ap-download/ap-download.vue.d.ts +4 -4
- package/lib/src/ap-download/ap-download.vue.js +1 -1
- package/lib/src/ap-download/hooks/useStyle.js +1 -1
- package/lib/src/ap-download/interface.d.ts +4 -0
- package/lib/src/ap-download/style/index.d.ts +2 -2
- package/lib/src/ap-drawer/style/index.d.ts +2 -2
- package/lib/src/ap-field/style/index.d.ts +2 -2
- package/lib/src/ap-form/style/drawer-form.d.ts +2 -2
- package/lib/src/ap-form/style/item-group.d.ts +2 -2
- package/lib/src/ap-form/style/item-text-group.d.ts +2 -2
- package/lib/src/ap-form/style/item.d.ts +3 -4
- package/lib/src/ap-form/style/item.js +1 -1
- package/lib/src/ap-form/style/modal-form.d.ts +4 -3
- package/lib/src/ap-form/style/modal-form.js +1 -1
- package/lib/src/ap-form/style/search-form-sorter.d.ts +4 -3
- package/lib/src/ap-form/style/search-form-sorter.js +1 -1
- package/lib/src/ap-form/style/search-form.d.ts +2 -2
- package/lib/src/ap-form/style/token.d.ts +25 -1
- package/lib/src/ap-grid/hooks/use-table-style.js +1 -1
- package/lib/src/ap-grid/index.vue.js +1 -1
- package/lib/src/ap-grid/style/editable.d.ts +2 -2
- package/lib/src/ap-grid/style/index.d.ts +6 -3
- package/lib/src/ap-grid/style/index.js +1 -1
- package/lib/src/ap-grid/utils/col.js +1 -1
- package/lib/src/ap-list/style/index.d.ts +2 -2
- package/lib/src/ap-modal/interface.d.ts +31 -11
- package/lib/src/ap-modal/utils/createModal.js +1 -1
- package/lib/src/ap-pro-card/style/divider.d.ts +2 -2
- package/lib/src/ap-pro-card/style/index.d.ts +2 -2
- package/lib/src/ap-pro-card/style/operation.d.ts +2 -2
- package/lib/src/ap-pro-card/style/statistic.d.ts +2 -2
- package/lib/src/ap-pro-card/style/statistics-card.d.ts +2 -2
- package/lib/src/ap-pro-card/style/title.d.ts +2 -2
- package/lib/src/ap-table/ap-table.vue2.js +1 -1
- package/lib/src/ap-table/style/ellipsis.d.ts +2 -2
- package/lib/src/ap-table/style/index-comp.d.ts +2 -2
- package/lib/src/ap-table/style/index.d.ts +2 -2
- package/lib/src/ap-table/style/setting.d.ts +2 -2
- package/lib/src/ap-table/utils.js +1 -1
- package/lib/src/ap-tag/ap-tag.vue.js +1 -1
- package/lib/src/ap-tag/style/group.d.ts +2 -2
- package/lib/src/ap-tag/style/index.d.ts +2 -2
- package/lib/src/ap-upload/style/index.d.ts +2 -2
- package/lib/src/business/ag-grid-modal/style/index.d.ts +2 -2
- package/lib/src/business/ag-grid-modal/style/selected-items.d.ts +2 -2
- package/lib/src/business/ag-grid-modal/utils.js +1 -1
- package/lib/src/business/ap-appendix/style/index.d.ts +5 -4
- package/lib/src/business/ap-appendix/style/index.js +1 -1
- package/lib/src/business/ap-appendix/style/token.d.ts +4 -0
- package/lib/src/business/ap-appendix/style/token.js +1 -0
- package/lib/src/business/ap-attachment/ApAttachment.js +1 -1
- package/lib/src/business/ap-attachment/style/index.d.ts +2 -2
- package/lib/src/business/ap-attachment/style/index.js +1 -1
- package/lib/src/business/ap-batch-action/style/index.d.ts +3 -3
- package/lib/src/business/ap-batch-action/style/index.js +1 -1
- package/lib/src/business/ap-batch-action-group/ApBatchActionGroup.vue2.js +1 -1
- package/lib/src/business/ap-batch-action-group/style/index.d.ts +3 -0
- package/lib/src/business/ap-batch-action-group/style/index.js +1 -0
- package/lib/src/business/ap-card/style/index.d.ts +3 -3
- package/lib/src/business/ap-card/style/index.js +1 -1
- package/lib/src/business/ap-copy/style/index.d.ts +2 -2
- package/lib/src/business/ap-draggable-grid/style/index.d.ts +2 -2
- package/lib/src/business/ap-expand-alert/ApExpandAlert.vue.d.ts +3 -2
- package/lib/src/business/ap-expand-alert/ApExpandAlert.vue2.js +1 -1
- package/lib/src/business/ap-expand-alert/index.d.ts +5 -2
- package/lib/src/business/ap-expand-alert/interface.d.ts +1 -1
- package/lib/src/business/ap-expand-alert/style/index.d.ts +2 -2
- package/lib/src/business/ap-image/style/index.d.ts +3 -3
- package/lib/src/business/ap-image/style/index.js +1 -1
- package/lib/src/business/ap-input-radio/style/index.d.ts +2 -2
- package/lib/src/business/ap-label/style/index.d.ts +2 -2
- package/lib/src/business/ap-ladder/style/index.d.ts +2 -2
- package/lib/src/business/ap-product-info/style/index.d.ts +2 -2
- package/lib/src/business/ap-radio-group/style/index.d.ts +2 -2
- package/lib/src/business/ap-radio-group/style/index.js +1 -1
- package/lib/src/business/ap-select-layout/style/index.d.ts +2 -2
- package/lib/src/business/ap-size-input/style/index.d.ts +2 -2
- package/lib/src/business/ap-status/style/index.d.ts +2 -2
- package/lib/src/business/ap-summary/style/index.d.ts +2 -2
- package/lib/src/business/ap-table-modal/style/index.d.ts +2 -2
- package/lib/src/business/ap-table-modal/table-modal.vue2.js +1 -1
- package/lib/src/business/ap-title/style/index.d.ts +2 -2
- package/lib/src/business/ap-upload-file/ap-upload-single/style/index.d.ts +2 -2
- package/lib/src/business/ap-value-select-card/style/index.d.ts +2 -2
- package/lib/src/business/ap-view/style/index.d.ts +3 -3
- package/lib/src/business/ap-view/style/index.js +1 -1
- package/lib/src/business/batch-input-group/style/index.d.ts +5 -2
- package/lib/src/business/batch-input-group/style/index.js +1 -1
- package/lib/src/business/hooks/usePageListAgGrid.js +1 -1
- package/lib/src/check-card/style/index.d.ts +2 -2
- package/lib/src/check-card/style/index.js +1 -1
- package/lib/src/config-provider/config-provider.d.ts +1 -2
- package/lib/src/config-provider/hooks/use-global-config.d.ts +1 -2
- package/lib/src/config-provider/hooks/use-global-config.js +1 -1
- package/lib/src/config-provider/hooks/use-token.d.ts +7 -2
- package/lib/src/config-provider/hooks/use-token.js +1 -1
- package/lib/src/config-provider/index.d.ts +1 -2
- package/lib/src/design-token/constants.d.ts +1 -6
- package/lib/src/design-token/constants.js +1 -1
- package/lib/src/design-token/index.d.ts +1 -1
- package/lib/src/design-token/index.js +1 -1
- package/lib/src/design-token/interface.d.ts +9 -1
- package/lib/src/design-token/interface.js +1 -0
- package/lib/src/editable-table/style/index.d.ts +2 -2
- package/lib/src/full-screen/index.vue.js +1 -1
- package/lib/src/full-screen/style/index.d.ts +2 -2
- package/lib/src/index.js +1 -1
- package/lib/src/mask/style/index.d.ts +2 -2
- package/lib/src/mask/style/index.js +2 -2
- package/lib/src/scroll-bar/style/index.d.ts +2 -2
- package/lib/src/scroll-bar/style/index.js +1 -1
- package/lib/src/scroll-view/style/index.d.ts +2 -2
- package/lib/src/splitter/style/index.d.ts +11 -3
- package/lib/src/splitter/style/index.js +1 -1
- package/lib/src/text/style/group.d.ts +2 -2
- package/lib/src/text/style/index.d.ts +6 -3
- package/lib/src/text/style/index.js +1 -1
- package/lib/src/utils/cssinjs/index.d.ts +3 -7
- package/lib/src/utils/cssinjs/index.js +1 -1
- package/lib/src/utils/cssinjs/instance.js +1 -1
- package/lib/src/utils/cssinjs/plugin-append-cssvar.d.ts +6 -0
- package/lib/src/utils/cssinjs/plugin-append-cssvar.js +1 -0
- package/lib/src/utils/cssinjs/plugin-specificity.js +1 -1
- package/lib/src/utils/cssinjs/utils.d.ts +6 -0
- package/lib/src/utils/cssinjs/utils.js +1 -0
- package/lib/src/version.d.ts +1 -1
- package/lib/src/version.js +1 -1
- package/package.json +1 -1
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { GenStyleFunc } from '../../design-token/interface';
|
|
2
|
-
import {
|
|
2
|
+
import { ComputedRef } from 'vue';
|
|
3
3
|
export declare const genDrawerFormStyle: GenStyleFunc;
|
|
4
|
-
declare const _default: (prefixCls: string) =>
|
|
4
|
+
declare const _default: (prefixCls: string) => ComputedRef<string>;
|
|
5
5
|
export default _default;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { GenStyleFunc } from '../../design-token/interface';
|
|
2
|
-
import {
|
|
2
|
+
import { ComputedRef } from 'vue';
|
|
3
3
|
export declare const genItemGroupStyle: GenStyleFunc;
|
|
4
|
-
declare const _default: (prefixCls: string) =>
|
|
4
|
+
declare const _default: (prefixCls: string) => ComputedRef<string>;
|
|
5
5
|
export default _default;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { GenStyleFunc } from '../../design-token/interface';
|
|
2
|
-
import {
|
|
2
|
+
import { ComputedRef } from 'vue';
|
|
3
3
|
export declare const genFormItemTextGroupStyle: GenStyleFunc;
|
|
4
|
-
declare const _default: (prefixCls: string) =>
|
|
4
|
+
declare const _default: (prefixCls: string) => ComputedRef<string>;
|
|
5
5
|
export default _default;
|
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
import { GenStyleFunc } from '../../design-token/interface';
|
|
2
|
-
import {
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
declare const _default: (prefixCls: string) => Ref<string | undefined, string | undefined>;
|
|
2
|
+
import { ComputedRef } from 'vue';
|
|
3
|
+
export declare const genApFormItemStyle: GenStyleFunc;
|
|
4
|
+
declare const _default: (prefixCls: string) => ComputedRef<string>;
|
|
6
5
|
export default _default;
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import { genComponentStyleHook as
|
|
2
|
-
const
|
|
3
|
-
const { componentCls:
|
|
1
|
+
import { genComponentStyleHook as a } from "../../utils/cssinjs/index.mjs";
|
|
2
|
+
const i = (n) => {
|
|
3
|
+
const { componentCls: e, namespace: t } = n;
|
|
4
4
|
return {
|
|
5
|
-
[
|
|
5
|
+
[e]: {
|
|
6
6
|
// bordered
|
|
7
7
|
"&--bordered": {
|
|
8
8
|
boxSizing: "border-box",
|
|
@@ -12,7 +12,7 @@ const r = (n) => {
|
|
|
12
12
|
".ant-input-affix-wrapper": {
|
|
13
13
|
padding: 0
|
|
14
14
|
},
|
|
15
|
-
[`&:has(.${
|
|
15
|
+
[`&:has(.${t}-batch-input-group):has(.ant-select)`]: {
|
|
16
16
|
".ant-input-affix-wrapper": {
|
|
17
17
|
paddingInlineEnd: n.space
|
|
18
18
|
}
|
|
@@ -81,9 +81,9 @@ const r = (n) => {
|
|
|
81
81
|
},
|
|
82
82
|
"&:focus": {
|
|
83
83
|
borderColor: n.activeColorBase,
|
|
84
|
-
boxShadow:
|
|
84
|
+
boxShadow: "0 0 0 2px rgba(5, 155, 255, 0.1)"
|
|
85
85
|
},
|
|
86
|
-
[`.${
|
|
86
|
+
[`.${t}-batch-input-group-popover-input__popover`]: {
|
|
87
87
|
width: "calc(100% + 12px)"
|
|
88
88
|
}
|
|
89
89
|
},
|
|
@@ -97,12 +97,12 @@ const r = (n) => {
|
|
|
97
97
|
// focus
|
|
98
98
|
"&--focused": {
|
|
99
99
|
borderColor: n.activeColorBase,
|
|
100
|
-
boxShadow:
|
|
100
|
+
boxShadow: "0 0 0 2px rgba(5, 155, 255, 0.1)"
|
|
101
101
|
},
|
|
102
102
|
// other
|
|
103
103
|
".ant-form-show-help": {
|
|
104
104
|
".ant-form-item-explain-error": {
|
|
105
|
-
|
|
105
|
+
fontSize: n.fontSize,
|
|
106
106
|
lineHeight: "16px"
|
|
107
107
|
}
|
|
108
108
|
},
|
|
@@ -124,12 +124,8 @@ const r = (n) => {
|
|
|
124
124
|
}
|
|
125
125
|
}
|
|
126
126
|
};
|
|
127
|
-
},
|
|
128
|
-
"ApForm",
|
|
129
|
-
(n) => [r(n)],
|
|
130
|
-
{ apFormBorderedShadowColor: "rgba(5, 155, 255, 0.1)" }
|
|
131
|
-
);
|
|
127
|
+
}, o = a("ApForm", (n) => [i(n)]);
|
|
132
128
|
export {
|
|
133
|
-
|
|
134
|
-
|
|
129
|
+
o as default,
|
|
130
|
+
i as genApFormItemStyle
|
|
135
131
|
};
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { GenStyleFunc } from '../../design-token/interface';
|
|
2
|
-
import {
|
|
3
|
-
|
|
4
|
-
declare const
|
|
2
|
+
import { ApFormToken } from './token';
|
|
3
|
+
import { ComputedRef } from 'vue';
|
|
4
|
+
export declare const genModalFormStyle: GenStyleFunc<ApFormToken>;
|
|
5
|
+
declare const _default: (prefixCls: string) => ComputedRef<string>;
|
|
5
6
|
export default _default;
|
|
@@ -1,32 +1,45 @@
|
|
|
1
|
-
import { genComponentStyleHook as
|
|
2
|
-
const e = (
|
|
3
|
-
const { componentCls:
|
|
1
|
+
import { genComponentStyleHook as d } from "../../utils/cssinjs/index.mjs";
|
|
2
|
+
const e = (o) => {
|
|
3
|
+
const { componentCls: a } = o;
|
|
4
4
|
return {
|
|
5
|
-
[
|
|
5
|
+
[a]: {
|
|
6
6
|
".ant-modal-content": {
|
|
7
7
|
padding: 0
|
|
8
8
|
},
|
|
9
9
|
".ant-modal-header": {
|
|
10
|
-
|
|
10
|
+
paddingInline: o.apFormModalHeaderPaddingInline,
|
|
11
|
+
paddingBlock: o.apFormModalHeaderPaddingBlock,
|
|
11
12
|
borderBottom: "1px solid #E9EDF3",
|
|
12
13
|
marginBottom: 0
|
|
13
14
|
},
|
|
14
|
-
[`${
|
|
15
|
-
padding:
|
|
15
|
+
[`${a}__content`]: {
|
|
16
|
+
padding: o.apFormModalContentPadding
|
|
16
17
|
},
|
|
17
|
-
[`${
|
|
18
|
-
padding:
|
|
18
|
+
[`${a}__footer`]: {
|
|
19
|
+
padding: o.apFormModalFooterPadding
|
|
19
20
|
},
|
|
20
|
-
[`${
|
|
21
|
+
[`${a}__footer-admin`]: {
|
|
21
22
|
borderTop: "1px solid #E9EDF3"
|
|
22
23
|
},
|
|
23
24
|
".ant-modal-close": {
|
|
24
|
-
top:
|
|
25
|
+
top: `calc(${o.apFormModalHeaderPaddingBlock} - (${o.apFormModalCloseSize} - 22px) / 2)`,
|
|
26
|
+
width: o.apFormModalCloseSize,
|
|
27
|
+
height: o.apFormModalCloseSize
|
|
25
28
|
}
|
|
26
29
|
}
|
|
27
30
|
};
|
|
28
|
-
},
|
|
31
|
+
}, r = d(
|
|
32
|
+
"ApForm.Modal",
|
|
33
|
+
(o) => [e(o)],
|
|
34
|
+
{
|
|
35
|
+
apFormModalHeaderPaddingInline: 20,
|
|
36
|
+
apFormModalHeaderPaddingBlock: 15,
|
|
37
|
+
apFormModalContentPadding: "20px 20px 0px",
|
|
38
|
+
apFormModalFooterPadding: "12px 20px",
|
|
39
|
+
apFormModalCloseSize: 32
|
|
40
|
+
}
|
|
41
|
+
);
|
|
29
42
|
export {
|
|
30
|
-
|
|
43
|
+
r as default,
|
|
31
44
|
e as genModalFormStyle
|
|
32
45
|
};
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { GenStyleFunc } from '../../design-token/interface';
|
|
2
|
-
import {
|
|
3
|
-
|
|
4
|
-
declare const
|
|
2
|
+
import { ApFormToken } from './token';
|
|
3
|
+
import { ComputedRef } from 'vue';
|
|
4
|
+
export declare const genSearchFormSorter: GenStyleFunc<ApFormToken>;
|
|
5
|
+
declare const _default: (prefixCls: string) => ComputedRef<string>;
|
|
5
6
|
export default _default;
|
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
import { resetComponent as e } from "../../style/index.mjs";
|
|
2
|
-
import { genComponentStyleHook as
|
|
3
|
-
import { genPopoverStyle as
|
|
4
|
-
const
|
|
2
|
+
import { genComponentStyleHook as a } from "../../utils/cssinjs/index.mjs";
|
|
3
|
+
import { genPopoverStyle as t } from "./search-form.mjs";
|
|
4
|
+
const i = (r) => {
|
|
5
5
|
const { componentCls: o } = r;
|
|
6
6
|
return {
|
|
7
7
|
[o]: {
|
|
8
8
|
[`${o}-content`]: {
|
|
9
|
-
width:
|
|
9
|
+
width: r.searchFormSorterWidth
|
|
10
10
|
},
|
|
11
11
|
[`${o}-header`]: {
|
|
12
12
|
padding: `${r.spaceXL} ${r.spaceXL} 0px`,
|
|
@@ -23,7 +23,7 @@ const a = (r) => {
|
|
|
23
23
|
},
|
|
24
24
|
"&-action-wrapper": {
|
|
25
25
|
padding: r.space,
|
|
26
|
-
margin: `calc(
|
|
26
|
+
margin: `calc(-1 * ${r.space})`,
|
|
27
27
|
cursor: "pointer"
|
|
28
28
|
},
|
|
29
29
|
"&-reset-btn": {
|
|
@@ -35,14 +35,14 @@ const a = (r) => {
|
|
|
35
35
|
display: "flex",
|
|
36
36
|
flexDirection: "row",
|
|
37
37
|
flexWrap: "wrap",
|
|
38
|
-
marginInlineStart:
|
|
39
|
-
marginInlineEnd:
|
|
40
|
-
rowGap:
|
|
38
|
+
marginInlineStart: `calc(${r.searchFormSorterItemGap} / -2)`,
|
|
39
|
+
marginInlineEnd: `calc(${r.searchFormSorterItemGap} / -2)`,
|
|
40
|
+
rowGap: r.searchFormSorterItemGap
|
|
41
41
|
},
|
|
42
42
|
[`${o}-sorter-item`]: {
|
|
43
43
|
flex: "0 0 33.333333%",
|
|
44
44
|
maxWidth: "33.333333%",
|
|
45
|
-
paddingInline: r.
|
|
45
|
+
paddingInline: `calc(${r.searchFormSorterItemGap} / 2)`,
|
|
46
46
|
"> div": {
|
|
47
47
|
border: `1px solid ${r.colorBg1}`,
|
|
48
48
|
borderRadius: r.borderRadius,
|
|
@@ -72,10 +72,17 @@ const a = (r) => {
|
|
|
72
72
|
textOverflow: "ellipsis"
|
|
73
73
|
}
|
|
74
74
|
},
|
|
75
|
-
...
|
|
75
|
+
...t(r)
|
|
76
76
|
};
|
|
77
|
-
},
|
|
77
|
+
}, s = a(
|
|
78
|
+
"ApForm.SearchFormSorter",
|
|
79
|
+
(r) => [i(r)],
|
|
80
|
+
{
|
|
81
|
+
searchFormSorterWidth: 560,
|
|
82
|
+
searchFormSorterItemGap: 8
|
|
83
|
+
}
|
|
84
|
+
);
|
|
78
85
|
export {
|
|
79
|
-
|
|
80
|
-
|
|
86
|
+
s as default,
|
|
87
|
+
i as genSearchFormSorter
|
|
81
88
|
};
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { GenStyleFunc, StyleMixin } from '../../design-token/interface';
|
|
2
|
-
import {
|
|
2
|
+
import { ComputedRef } from 'vue';
|
|
3
3
|
export declare const genPopoverStyle: StyleMixin;
|
|
4
4
|
export declare const genSearchFormStyle: GenStyleFunc;
|
|
5
|
-
declare const _default: (prefixCls: string) =>
|
|
5
|
+
declare const _default: (prefixCls: string) => ComputedRef<string>;
|
|
6
6
|
export default _default;
|
|
@@ -1,3 +1,27 @@
|
|
|
1
1
|
export type ApFormToken = {
|
|
2
|
-
|
|
2
|
+
/**
|
|
3
|
+
* 对话框表单头部边距
|
|
4
|
+
*/
|
|
5
|
+
apFormModalHeaderPaddingInline: number;
|
|
6
|
+
apFormModalHeaderPaddingBlock: number;
|
|
7
|
+
/**
|
|
8
|
+
* 对话框表单内容区边距
|
|
9
|
+
*/
|
|
10
|
+
apFormModalContentPadding: string | number;
|
|
11
|
+
/**
|
|
12
|
+
* 对话框表单底部Footer区域边距
|
|
13
|
+
*/
|
|
14
|
+
apFormModalFooterPadding: string | number;
|
|
15
|
+
/**
|
|
16
|
+
* 关闭按钮的尺寸
|
|
17
|
+
*/
|
|
18
|
+
apFormModalCloseSize: number;
|
|
19
|
+
/**
|
|
20
|
+
* 查询表单排序弹框宽度
|
|
21
|
+
*/
|
|
22
|
+
searchFormSorterWidth: number;
|
|
23
|
+
/**
|
|
24
|
+
* 查询表单排序元素间距
|
|
25
|
+
*/
|
|
26
|
+
searchFormSorterItemGap: number;
|
|
3
27
|
};
|
|
@@ -8,7 +8,7 @@ const x = () => {
|
|
|
8
8
|
"--vxe-ui-table-row-checkbox-checked-background-color": e.controlItemBgActive,
|
|
9
9
|
"--vxe-ui-table-row-hover-checkbox-checked-background-color": e.controlItemBgActiveHover,
|
|
10
10
|
"--vxe-ui-font-primary-color": e.colorPrimary,
|
|
11
|
-
"--vxe-ui-table-header-background-color": "var(--
|
|
11
|
+
"--vxe-ui-table-header-background-color": "var(--table-header-bg)",
|
|
12
12
|
"--vxe-ui-table-cell-padding-default": "12px",
|
|
13
13
|
"--vxe-ui-table-cell-padding-medium": "9px",
|
|
14
14
|
"--vxe-ui-table-row-height-medium": "36px",
|
|
@@ -535,8 +535,8 @@ const lo = /* @__PURE__ */ Je({
|
|
|
535
535
|
direction: "horizontal",
|
|
536
536
|
"scroll-container": Re.value,
|
|
537
537
|
"extra-size": -4.2,
|
|
538
|
-
"bar-color": "var(--
|
|
539
|
-
"track-color": "var(--
|
|
538
|
+
"bar-color": "var(--scrollbar-thumb-color-base)",
|
|
539
|
+
"track-color": "var(--table-header-bg, #f2f6f9)"
|
|
540
540
|
}, null, 8, ["scroll-container"])) : y("", !0),
|
|
541
541
|
e.pagination !== !1 ? (s(), d(t(pt), S({
|
|
542
542
|
key: 1,
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { GenStyleFunc } from '../../design-token/interface';
|
|
2
|
-
import {
|
|
2
|
+
import { ComputedRef } from 'vue';
|
|
3
3
|
export declare const genEditableGridStyle: GenStyleFunc;
|
|
4
|
-
declare const _default: (prefixCls: string) =>
|
|
4
|
+
declare const _default: (prefixCls: string) => ComputedRef<string>;
|
|
5
5
|
export default _default;
|
|
@@ -1,5 +1,8 @@
|
|
|
1
1
|
import { GenStyleFunc } from '../../design-token/interface';
|
|
2
|
-
import {
|
|
3
|
-
export
|
|
4
|
-
|
|
2
|
+
import { ComputedRef } from 'vue';
|
|
3
|
+
export type ApGridToken = {
|
|
4
|
+
apGridFixedScrollingBoxShadowColor: string;
|
|
5
|
+
};
|
|
6
|
+
export declare const genApGridStyle: GenStyleFunc<ApGridToken>;
|
|
7
|
+
declare const _default: (prefixCls: string) => ComputedRef<string>;
|
|
5
8
|
export default _default;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { genSettingTriggerBtnStyle as r } from "../../ap-table/style/index.mjs";
|
|
2
|
-
import { multiRows as o, resetScrollbar as
|
|
3
|
-
import { genComponentStyleHook as
|
|
2
|
+
import { multiRows as o, resetScrollbar as d } from "../../style/index.mjs";
|
|
3
|
+
import { genComponentStyleHook as p } from "../../utils/cssinjs/index.mjs";
|
|
4
4
|
import { aplusApGridIconFont as c } from "./font.mjs";
|
|
5
5
|
const g = (e) => {
|
|
6
6
|
const { componentCls: i, namespace: t } = e, l = `${i}-vxe-wrapper`, a = `${i}-pagination-wrapper`, n = `.${t}-scroll-bar`;
|
|
@@ -8,7 +8,7 @@ const g = (e) => {
|
|
|
8
8
|
c,
|
|
9
9
|
{
|
|
10
10
|
[i]: {
|
|
11
|
-
...
|
|
11
|
+
...d(e),
|
|
12
12
|
".vxe-table--render-default.size--medium .vxe-body--column.is--padding div.vxe-cell": {
|
|
13
13
|
minHeight: "unset !important",
|
|
14
14
|
padding: "9px 12px",
|
|
@@ -152,7 +152,6 @@ const g = (e) => {
|
|
|
152
152
|
"&__title": {
|
|
153
153
|
...o(e),
|
|
154
154
|
fontWeight: "bold",
|
|
155
|
-
textAlign: "right",
|
|
156
155
|
"&--single": {
|
|
157
156
|
flex: "unset"
|
|
158
157
|
}
|
|
@@ -209,9 +208,13 @@ const g = (e) => {
|
|
|
209
208
|
}
|
|
210
209
|
}
|
|
211
210
|
];
|
|
212
|
-
}, m =
|
|
213
|
-
|
|
214
|
-
]
|
|
211
|
+
}, m = p(
|
|
212
|
+
"ApGrid",
|
|
213
|
+
(e) => [g(e)],
|
|
214
|
+
{
|
|
215
|
+
apGridFixedScrollingBoxShadowColor: "#dae0e7"
|
|
216
|
+
}
|
|
217
|
+
);
|
|
215
218
|
export {
|
|
216
219
|
m as default,
|
|
217
220
|
g as genApGridStyle
|
|
@@ -1,23 +1,23 @@
|
|
|
1
|
-
import { createVNode as u, Fragment as
|
|
2
|
-
import { isArray as
|
|
3
|
-
import { valueEnumToArray as S, objectToString as $, getTableTitle as
|
|
1
|
+
import { createVNode as u, Fragment as T } from "vue";
|
|
2
|
+
import { isArray as x, isUndefined as E, isString as o, isBoolean as F, isNumber as O, pick as R } from "lodash-unified";
|
|
3
|
+
import { valueEnumToArray as S, objectToString as $, getTableTitle as v, getTableRenderType as V, getTableRenderProps as B, getTableCellRenderNode as M } from "../../ap-table/utils.mjs";
|
|
4
4
|
import { noRenderAsFormItemValueList as _ } from "../../ap-table/constants.mjs";
|
|
5
5
|
import "../../ap-table/components/paragraph-ellipsis/index.vue.mjs";
|
|
6
6
|
import j from "../../ap-table/components/paragraph-ellipsis/index.vue2.mjs";
|
|
7
|
-
function
|
|
7
|
+
function c(e, t) {
|
|
8
8
|
if (t)
|
|
9
|
-
return
|
|
9
|
+
return x(t) ? t.reduce((r, n) => r?.[n], e) : e?.[t];
|
|
10
10
|
}
|
|
11
|
-
function
|
|
11
|
+
function A(e) {
|
|
12
12
|
if (!E(e))
|
|
13
|
-
return
|
|
13
|
+
return x(e) ? e.reduce((t, r) => o(r) ? `${t}${t ? "." : ""}${r}` : `${t}[${r}]`, "") : String(e);
|
|
14
14
|
}
|
|
15
|
-
function
|
|
15
|
+
function N(e) {
|
|
16
16
|
if (e)
|
|
17
17
|
return e === !0 ? "left" : e;
|
|
18
18
|
}
|
|
19
19
|
function q(e) {
|
|
20
|
-
return
|
|
20
|
+
return F(e) ? {
|
|
21
21
|
sortable: e
|
|
22
22
|
} : e ? {
|
|
23
23
|
sortable: !0,
|
|
@@ -29,7 +29,7 @@ function q(e) {
|
|
|
29
29
|
}
|
|
30
30
|
function I(e) {
|
|
31
31
|
let t;
|
|
32
|
-
return
|
|
32
|
+
return F(e.filters) && e.valueEnum ? t = S(e.valueEnum) : t = e.filters, t?.map((r) => ({
|
|
33
33
|
label: o(r.text) ? r.text : "",
|
|
34
34
|
value: r.value
|
|
35
35
|
}));
|
|
@@ -65,10 +65,10 @@ function z(e, t, r) {
|
|
|
65
65
|
}
|
|
66
66
|
return r;
|
|
67
67
|
}
|
|
68
|
-
function
|
|
69
|
-
const n =
|
|
70
|
-
return n.field =
|
|
71
|
-
header: () =>
|
|
68
|
+
function y(e, t, r) {
|
|
69
|
+
const n = R(e, ["width", "minWidth", "align"]);
|
|
70
|
+
return n.field = A(e.dataIndex), n.fixed = N(e.fixed), n.slots = {
|
|
71
|
+
header: () => v(e, r, void 0, t)
|
|
72
72
|
}, n.headerAlign = e.align, n.showOverflow = !1, n.showFooterOverflow = !1, n;
|
|
73
73
|
}
|
|
74
74
|
function D(e, t, r) {
|
|
@@ -88,65 +88,65 @@ const G = ({
|
|
|
88
88
|
}), l = M(s, d, t.record, n), a = r.renderText?.({
|
|
89
89
|
value: e,
|
|
90
90
|
...t
|
|
91
|
-
}) || e, p = r.renderText ? u(
|
|
91
|
+
}) || e, p = r.renderText ? u(T, null, [r.renderText?.({
|
|
92
92
|
value: e,
|
|
93
93
|
...t
|
|
94
94
|
})]) : l;
|
|
95
95
|
let f = i ? z(r, a, p) : p;
|
|
96
96
|
if (r.customRender) {
|
|
97
|
-
const
|
|
97
|
+
const w = r._path || [], h = D(t.record, t.rowIndex, t.params?.rowKey);
|
|
98
98
|
f = r.customRender({
|
|
99
99
|
value: e,
|
|
100
100
|
...t,
|
|
101
101
|
column: r,
|
|
102
102
|
originalNode: f,
|
|
103
103
|
originalText: a,
|
|
104
|
-
path: [...
|
|
104
|
+
path: h && [...w, String(h)]
|
|
105
105
|
});
|
|
106
106
|
}
|
|
107
|
-
return u(
|
|
107
|
+
return u(T, null, [f]);
|
|
108
108
|
};
|
|
109
|
-
function
|
|
110
|
-
const i =
|
|
111
|
-
i.field =
|
|
109
|
+
function b(e, t, r, n) {
|
|
110
|
+
const i = R(e, ["width", "minWidth", "align", "resizable", "className", "headerClassName", "footerClassName", "treeNode"]);
|
|
111
|
+
i.field = A(e.dataIndex), i.fixed = N(e.fixed), i.headerAlign = e.align, i.footerAlign = e.align, i.showOverflow = !1, i.showFooterOverflow = !1, Object.assign(i, q(e.sorter)), i.filters = I(e), i.filterMultiple = e.filterMultiple, i.filterMethod = W(e.onFilter);
|
|
112
112
|
const s = ({
|
|
113
113
|
row: d,
|
|
114
114
|
rowIndex: l
|
|
115
115
|
}) => G({
|
|
116
|
-
value:
|
|
117
|
-
text:
|
|
116
|
+
value: c(d, e.dataIndex),
|
|
117
|
+
text: c(d, e.dataIndex),
|
|
118
118
|
record: d,
|
|
119
119
|
index: l,
|
|
120
120
|
renderIndex: l,
|
|
121
121
|
column: e
|
|
122
122
|
}, e, n);
|
|
123
123
|
return i.slots = {
|
|
124
|
-
header: () =>
|
|
124
|
+
header: () => v(e, r, void 0, t),
|
|
125
125
|
default: s,
|
|
126
126
|
footer: s
|
|
127
127
|
}, e.html && (delete i.slots.default, delete i.slots.footer, i.type = "html"), e.seq && (i.type = "seq", i.slots = {}), i;
|
|
128
128
|
}
|
|
129
129
|
function X(e, t, r, n) {
|
|
130
130
|
if (!e.children?.length)
|
|
131
|
-
return
|
|
131
|
+
return b(e, t, r, n);
|
|
132
132
|
function i(d) {
|
|
133
133
|
return d.map((l) => {
|
|
134
134
|
if (l.children?.length) {
|
|
135
|
-
const a =
|
|
135
|
+
const a = y(l, t, r);
|
|
136
136
|
return a.children = i(l.children), a;
|
|
137
137
|
}
|
|
138
|
-
return
|
|
138
|
+
return b(l, t, r, n);
|
|
139
139
|
});
|
|
140
140
|
}
|
|
141
|
-
const s =
|
|
141
|
+
const s = y(e, t, r);
|
|
142
142
|
return s.children = i(e.children), s;
|
|
143
143
|
}
|
|
144
144
|
export {
|
|
145
145
|
G as contentCustom,
|
|
146
|
-
|
|
147
|
-
|
|
146
|
+
A as dataIndexToField,
|
|
147
|
+
c as getValueByDataIndex,
|
|
148
148
|
X as transformCol,
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
149
|
+
N as transformFixed,
|
|
150
|
+
y as transformToColGroup,
|
|
151
|
+
b as transformToColumn
|
|
152
152
|
};
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { GenStyleFunc } from '../../design-token/interface';
|
|
2
|
-
import {
|
|
2
|
+
import { ComputedRef } from 'vue';
|
|
3
3
|
export type ApListToken = {
|
|
4
4
|
apListSpinnigOpacity: number;
|
|
5
5
|
};
|
|
6
6
|
export declare const genApListStyle: GenStyleFunc<ApListToken>;
|
|
7
|
-
declare const _default: (prefixCls: string) =>
|
|
7
|
+
declare const _default: (prefixCls: string) => ComputedRef<string>;
|
|
8
8
|
export default _default;
|
|
@@ -1,19 +1,19 @@
|
|
|
1
1
|
import { ModalProps, ModalFuncProps } from '@aplus-frontend/antdv';
|
|
2
2
|
import { ModalFunc, ModalStaticFunctions } from '@aplus-frontend/antdv/lib/modal/confirm';
|
|
3
|
-
import { AppContext } from 'vue';
|
|
4
|
-
export type CreateModalFuncProps<ContentRecord = any> = Omit<ModalProps, 'open' | 'onUpdate:open' | 'destroyOnClose' | 'onCancel' | 'onOk' | 'getContainer' | 'icon'> & Partial<{
|
|
3
|
+
import { AppContext, VNodeChild } from 'vue';
|
|
4
|
+
export type CreateModalFuncProps<ContentRecord = any> = Omit<ModalProps, 'open' | 'onUpdate:open' | 'destroyOnClose' | 'onCancel' | 'onOk' | 'getContainer' | 'icon' | 'footer'> & Partial<{
|
|
5
5
|
/**
|
|
6
6
|
* 点击取消回调
|
|
7
7
|
* @param params content组件内使用defineExpose导出的对象
|
|
8
8
|
* @returns
|
|
9
9
|
*/
|
|
10
|
-
onCancel: (
|
|
10
|
+
onCancel: (contentExposed: ContentRecord) => any | Promise<any>;
|
|
11
11
|
/**
|
|
12
12
|
* 点击确定回调
|
|
13
13
|
* @param params content组件内使用defineExpose导出的对象
|
|
14
14
|
* @returns
|
|
15
15
|
*/
|
|
16
|
-
onOk: (
|
|
16
|
+
onOk: (contentExposed: ContentRecord) => any | Promise<any>;
|
|
17
17
|
/**
|
|
18
18
|
* 指定弹框挂载的 HTML 节点
|
|
19
19
|
*/
|
|
@@ -34,8 +34,28 @@ export type CreateModalFuncProps<ContentRecord = any> = Omit<ModalProps, 'open'
|
|
|
34
34
|
* 弹窗的上下文,一般用于获取全局注册组件、vuex 等内容
|
|
35
35
|
*/
|
|
36
36
|
appContext: AppContext;
|
|
37
|
+
/**
|
|
38
|
+
* 底部内容,当不需要默认底部按钮时,可以设为 :footer="null"
|
|
39
|
+
*/
|
|
40
|
+
footer: ((params: {
|
|
41
|
+
/**
|
|
42
|
+
* 原始的底部内容
|
|
43
|
+
*/
|
|
44
|
+
originNode: VNodeChild;
|
|
45
|
+
/**
|
|
46
|
+
* 底部按钮
|
|
47
|
+
*/
|
|
48
|
+
extra: {
|
|
49
|
+
okBtn: VNodeChild;
|
|
50
|
+
cancelBtn: VNodeChild;
|
|
51
|
+
};
|
|
52
|
+
/**
|
|
53
|
+
* content组件内使用defineExpose导出的对象
|
|
54
|
+
*/
|
|
55
|
+
contentExposed: ContentRecord;
|
|
56
|
+
}) => VNodeChild) | VNodeChild;
|
|
37
57
|
}>;
|
|
38
|
-
export type CreateModalFuncReturn = {
|
|
58
|
+
export type CreateModalFuncReturn<ContentRecord = any> = {
|
|
39
59
|
/**
|
|
40
60
|
* 销毁弹框
|
|
41
61
|
* @returns
|
|
@@ -46,7 +66,7 @@ export type CreateModalFuncReturn = {
|
|
|
46
66
|
* @param newConfig
|
|
47
67
|
* @returns
|
|
48
68
|
*/
|
|
49
|
-
update: (newConfig: CreateModalFuncProps) => void;
|
|
69
|
+
update: (newConfig: CreateModalFuncProps<ContentRecord>) => void;
|
|
50
70
|
/**
|
|
51
71
|
* 打开弹框
|
|
52
72
|
* @returns
|
|
@@ -58,7 +78,7 @@ export type CreateModalFuncReturn = {
|
|
|
58
78
|
*/
|
|
59
79
|
close: () => void;
|
|
60
80
|
};
|
|
61
|
-
export type CreateModalFunc = (props: CreateModalFuncProps) => CreateModalFuncReturn
|
|
81
|
+
export type CreateModalFunc = <ContentRecord = any>(props: CreateModalFuncProps<ContentRecord>) => CreateModalFuncReturn<ContentRecord>;
|
|
62
82
|
export type ModalStreamNextFunc<ModalType extends ModalStreamTypeKey = ModalStreamTypeKey> = (option?: {
|
|
63
83
|
/**
|
|
64
84
|
* 下一步弹框的id
|
|
@@ -121,18 +141,18 @@ export type ModalFuncStream<ModalType extends ModalStreamTypeKey = ModalStreamTy
|
|
|
121
141
|
export type CreateModalStream<ModalType extends ModalStreamTypeKey = ModalStreamTypeKey> = Omit<CreateModalFuncProps, 'destroyOnClose' | 'onOk' | 'onCancel'> & {
|
|
122
142
|
/**
|
|
123
143
|
* 点击确定回调
|
|
124
|
-
* * @param
|
|
144
|
+
* * @param contentExposed content组件内使用defineExpose导出的对象
|
|
125
145
|
* @param next 下一步
|
|
126
146
|
* @returns
|
|
127
147
|
*/
|
|
128
|
-
onOk?: (
|
|
148
|
+
onOk?: (contentExposed: any, next: ModalStreamNextFunc<ModalType>) => any | Promise<any>;
|
|
129
149
|
/**
|
|
130
150
|
* 点击取消回调
|
|
131
|
-
* * @param
|
|
151
|
+
* * @param contentExposed content组件内使用defineExpose导出的对象
|
|
132
152
|
* @param next 下一步
|
|
133
153
|
* @returns
|
|
134
154
|
*/
|
|
135
|
-
onCancel?: (
|
|
155
|
+
onCancel?: (contentExposed: any, next: ModalStreamNextFunc<ModalType>) => any | Promise<any>;
|
|
136
156
|
};
|
|
137
157
|
export type ModalStreamTypeKey = keyof ModalStreamType;
|
|
138
158
|
export type CreateModalStreamProps<ModalType extends ModalStreamTypeKey = ModalStreamTypeKey> = ModalType extends ModalStreamTypeKey ? {
|