@kengic/vue 0.26.6-beta.8 → 0.26.6-beta.80
Sign up to get free protection for your applications and to get access to all the features.
- package/CHANGELOG.md +16 -0
- package/dist/close-outlined-DMcSQWxQ.e0f0942c.mjs +8 -0
- package/dist/fullscreen-exit-outlined-X1iYkFc4.e18d74f5.mjs +8 -0
- package/dist/fullscreen-exit-outlined.a75b82c2.mjs +8 -0
- package/dist/fullscreen-outlined-DDBrsRcy.697b9c42.mjs +8 -0
- package/dist/fullscreen-outlined.c9ba7960.mjs +8 -0
- package/dist/index.css +1 -1
- package/dist/kengic-vue.js +60617 -44321
- package/dist/src/api/WMS/Controllers/DescriptionController/List.d.ts +51 -0
- package/dist/src/api/WMS/Controllers/DescriptionController/ListByCodeNamesAndCodeValues.d.ts +16 -0
- package/dist/src/api/WMS/Controllers/DescriptionController/index.d.ts +2 -0
- package/dist/src/api/WMS/Controllers/SysPermissionController/List.d.ts +73 -0
- package/dist/src/api/WMS/Controllers/SysPermissionController/index.d.ts +1 -0
- package/dist/src/api/WMS/Controllers/VarConfigDescriptionController/Add.d.ts +16 -0
- package/dist/src/api/WMS/Controllers/VarConfigDescriptionController/index.d.ts +1 -0
- package/dist/src/api/WMS/Controllers/VarConfigPossibilityController/ExecuteQuery.d.ts +18 -0
- package/dist/src/api/WMS/Controllers/VarConfigPossibilityController/index.d.ts +1 -0
- package/dist/src/api/WMS/Controllers/VarController/GetAll.d.ts +16 -0
- package/dist/src/api/WMS/Controllers/VarController/index.d.ts +1 -0
- package/dist/src/api/WMS/Controllers/VarDdaController/Create.d.ts +16 -0
- package/dist/src/api/WMS/Controllers/VarDdaController/GetResultSetMetadataFromSql.d.ts +16 -0
- package/dist/src/api/WMS/Controllers/VarDdaController/ValidateCopySql.d.ts +16 -0
- package/dist/src/api/WMS/Controllers/VarDdaController/ValidateCreateSql.d.ts +16 -0
- package/dist/src/api/WMS/Controllers/VarDdaController/ValidateDeleteSql.d.ts +16 -0
- package/dist/src/api/WMS/Controllers/VarDdaController/ValidateFrmId.d.ts +16 -0
- package/dist/src/api/WMS/Controllers/VarDdaController/ValidateSearchSql.d.ts +16 -0
- package/dist/src/api/WMS/Controllers/VarDdaController/ValidateUpdateSql.d.ts +16 -0
- package/dist/src/api/WMS/Controllers/VarDdaController/ValidateVarButtonVarName.d.ts +16 -0
- package/dist/src/api/WMS/Controllers/VarDdaController/index.d.ts +9 -0
- package/dist/src/api/WMS/Controllers/VarGridMasterController/QueryByID.d.ts +19 -0
- package/dist/src/api/WMS/Controllers/VarGridMasterController/Update.d.ts +16 -0
- package/dist/src/api/WMS/Controllers/VarGridMasterController/index.d.ts +2 -0
- package/dist/src/api/WMS/Controllers/VarProfileMasterController/QueryByID.d.ts +19 -0
- package/dist/src/api/WMS/Controllers/VarProfileMasterController/index.d.ts +1 -0
- package/dist/src/api/WMS/Controllers/VarVariableController/Delete.d.ts +16 -0
- package/dist/src/api/WMS/Controllers/VarVariableController/index.d.ts +1 -0
- package/dist/src/api/WMS/Controllers/WhController/ListVO.d.ts +54 -0
- package/dist/src/api/WMS/Controllers/WhController/index.d.ts +1 -0
- package/dist/src/api/WMS/Controllers/WorkstationController/List.d.ts +25 -0
- package/dist/src/api/WMS/Controllers/WorkstationController/index.d.ts +1 -0
- package/dist/src/api/WMS/Controllers/index.d.ts +11 -0
- package/dist/src/api/WMS/index.d.ts +2 -0
- package/dist/src/api/WMS/models.d.ts +1018 -0
- package/dist/src/api/api.d.ts +1 -0
- package/dist/src/api/def.d.ts +1 -0
- package/dist/src/api/index.d.ts +2 -0
- package/dist/src/component/KgAppSelect/KgAppSelect.d.ts +47 -0
- package/dist/src/component/KgAppSelect/index.d.ts +3 -0
- package/dist/src/component/KgAppSelect/index.hooks.d.ts +41 -0
- package/dist/src/component/KgAppSelect/index.store.d.ts +74 -0
- package/dist/src/component/KgButton/KgButton.Item.d.ts +41 -0
- package/dist/src/component/KgButton/KgButton.Item.data.d.ts +31 -0
- package/dist/src/component/KgButton/KgButton.d.ts +40 -0
- package/dist/src/component/KgButton/components/KgButton.Copy.d.ts +40 -0
- package/dist/src/component/KgButton/components/KgButton.Create.d.ts +40 -0
- package/dist/src/component/KgButton/components/KgButton.Delete.d.ts +40 -0
- package/dist/src/component/KgButton/components/KgButton.Export.d.ts +40 -0
- package/dist/src/component/KgButton/components/KgButton.Import.d.ts +40 -0
- package/dist/src/component/KgButton/components/KgButton.ImportTemplate.d.ts +40 -0
- package/dist/src/component/KgButton/components/KgButton.Other.d.ts +40 -0
- package/dist/src/component/KgButton/components/KgButton.Search.d.ts +40 -0
- package/dist/src/component/KgButton/components/KgButton.Update.d.ts +40 -0
- package/dist/src/component/KgButton/index.d.ts +62 -0
- package/dist/src/component/KgButton/index.hooks.d.ts +183 -0
- package/dist/src/component/KgButton/index.store.d.ts +116 -0
- package/dist/src/component/KgCanvas/KgCanvas.d.ts +122 -0
- package/dist/src/component/KgCanvas/KgCanvas.service.d.ts +43 -0
- package/dist/src/component/KgCanvas/KgCanvasContextMenu.d.ts +107 -0
- package/dist/src/component/KgCanvas/KgCanvasToolbarFullscreen.d.ts +38 -0
- package/dist/src/component/KgCanvas/KgCanvasTooltip.d.ts +31 -0
- package/dist/src/component/KgCanvas/index.d.ts +4 -0
- package/dist/src/component/KgCanvas/index.hooks.d.ts +67 -0
- package/dist/src/component/KgCanvas/index.store.d.ts +239 -0
- package/dist/src/component/KgForm/KgForm.d.ts +414 -0
- package/dist/src/component/KgForm/index.d.ts +604 -0
- package/dist/src/component/KgForm/index.hooks.d.ts +73 -0
- package/dist/src/component/KgForm/index.store.d.ts +221 -0
- package/dist/src/component/KgForm/index.vm.d.ts +9 -0
- package/dist/src/component/KgForm.Item/KgForm.Item.d.ts +97 -0
- package/dist/src/component/KgForm.Item/KgForm.Item.service.d.ts +17 -0
- package/dist/src/component/KgForm.Item/addon/KgForm.Item.Addon.DynamicQueryOperator.d.ts +49 -0
- package/dist/src/component/KgForm.Item/addon/KgForm.Item.Addon.Lookup.Modal.d.ts +16 -0
- package/dist/src/component/KgForm.Item/addon/KgForm.Item.Addon.Lookup.d.ts +31 -0
- package/dist/src/component/KgForm.Item/components/KgForm.Item.Checkbox.d.ts +100 -0
- package/dist/src/component/KgForm.Item/components/KgForm.Item.CheckboxGroup.d.ts +99 -0
- package/dist/src/component/KgForm.Item/components/KgForm.Item.Date.d.ts +97 -0
- package/dist/src/component/KgForm.Item/components/KgForm.Item.DateRange.d.ts +97 -0
- package/dist/src/component/KgForm.Item/components/KgForm.Item.Image.d.ts +92 -0
- package/dist/src/component/KgForm.Item/components/KgForm.Item.Input.d.ts +96 -0
- package/dist/src/component/KgForm.Item/components/KgForm.Item.InputNumber.d.ts +96 -0
- package/dist/src/component/KgForm.Item/components/KgForm.Item.InputPassword.d.ts +96 -0
- package/dist/src/component/KgForm.Item/components/KgForm.Item.RadioGroup.d.ts +98 -0
- package/dist/src/component/KgForm.Item/components/KgForm.Item.Select.d.ts +98 -0
- package/dist/src/component/KgForm.Item/components/KgForm.Item.Select.service.d.ts +29 -0
- package/dist/src/component/KgForm.Item/components/KgForm.Item.Switch.d.ts +96 -0
- package/dist/src/component/KgForm.Item/components/KgForm.Item.TextArea.d.ts +96 -0
- package/dist/src/component/KgForm.Item/index.d.ts +2 -0
- package/dist/src/component/KgForm.Item/index.vm.d.ts +124 -0
- package/dist/src/component/KgImage/KgImage.d.ts +100 -0
- package/dist/src/component/KgImage/index.d.ts +1 -0
- package/dist/src/component/KgLayoutHeader/components/KgLayoutHeaderLocale.d.ts +38 -0
- package/dist/src/component/KgLayoutHeader/index.d.ts +2 -0
- package/dist/src/component/KgLayoutHeader/index.hooks.d.ts +4 -0
- package/dist/src/component/KgModal/KgModal.d.ts +823 -0
- package/dist/src/component/KgModal/KgModalHeaderButtons.d.ts +92 -0
- package/dist/src/component/KgModal/hooks/useDragToMove.d.ts +12 -0
- package/dist/src/component/KgModal/hooks/useDragToResize.d.ts +29 -0
- package/dist/src/component/KgModal/index.d.ts +1 -0
- package/dist/src/component/KgModal/index.vm.d.ts +8 -0
- package/dist/src/component/KgProgressA/KgProgressA.d.ts +85 -0
- package/dist/src/component/KgProgressA/index.d.ts +1 -0
- package/dist/src/component/KgResizable/KgResizable.d.ts +91 -0
- package/dist/src/component/KgResizable/KgResizable.service.d.ts +12 -0
- package/dist/src/component/KgResizable/index.d.ts +1 -0
- package/dist/src/component/KgSearch/KgSearch.d.ts +26 -0
- package/dist/src/component/KgSearch/KgSearch.service.d.ts +32 -0
- package/dist/src/component/KgSearch/components/KgSearch.ConfigModal.d.ts +16 -0
- package/dist/src/component/KgSearch/index.d.ts +3 -0
- package/dist/src/component/KgSearch/index.hooks.d.ts +67 -0
- package/dist/src/component/KgSearch/index.store.d.ts +147 -0
- package/dist/src/component/KgSearch/index.vm.d.ts +1 -0
- package/dist/src/component/KgStation/KgStation.d.ts +47 -0
- package/dist/src/component/KgStation/index.d.ts +3 -0
- package/dist/src/component/KgStation/index.hooks.d.ts +29 -0
- package/dist/src/component/KgStation/index.store.d.ts +45 -0
- package/dist/src/component/KgSubmit/KgSubmit.d.ts +21 -0
- package/dist/src/component/KgSubmit/KgSubmit.service.d.ts +29 -0
- package/dist/src/component/KgSubmit/index.d.ts +4 -0
- package/dist/src/component/KgSubmit/index.hooks.d.ts +295 -0
- package/dist/src/component/KgSubmit/index.store.d.ts +194 -0
- package/dist/src/component/KgSubmit/index.vm.d.ts +57 -0
- package/dist/src/component/KgTable/KgTable.d.ts +39 -0
- package/dist/src/component/KgTable/KgTable.service.d.ts +34 -0
- package/dist/src/component/KgTable/components/KgTable.BodyCell.d.ts +60 -0
- package/dist/src/component/KgTable/components/KgTable.HeaderCell.d.ts +52 -0
- package/dist/src/component/KgTable/components/KgTable.Info.d.ts +57 -0
- package/dist/src/component/KgTable/components/setting/KgTable.Setting.VarGridMaster.SaveAs.d.ts +5 -0
- package/dist/src/component/KgTable/components/setting/KgTable.Setting.d.ts +21 -0
- package/dist/src/component/KgTable/components/setting/KgTable.Setting.service.d.ts +22 -0
- package/dist/src/component/KgTable/components/setting/config/KgTable.Setting.ConfigModal.d.ts +16 -0
- package/dist/src/component/KgTable/index.d.ts +4 -0
- package/dist/src/component/KgTable/index.hooks.d.ts +148 -0
- package/dist/src/component/KgTable/index.store.d.ts +241 -0
- package/dist/src/component/KgTable/index.vm.d.ts +67 -0
- package/dist/src/component/KgVar/KgVar.d.ts +114 -0
- package/dist/src/component/KgVar/KgVarFactory.d.ts +61 -0
- package/dist/src/component/KgVar/index.d.ts +5 -0
- package/dist/src/component/KgVar/index.hooks.d.ts +189 -0
- package/dist/src/component/KgVar/index.store.d.ts +266 -0
- package/dist/src/component/KgVar/index.store.service.d.ts +30 -0
- package/dist/src/component/KgVar/index.vm.d.ts +57 -0
- package/dist/src/component/KgVarConfig/KgVarConfig.d.ts +3 -0
- package/dist/src/component/KgVarConfig/components/KgVarConfig.SelectFormIdModal.d.ts +27 -0
- package/dist/src/component/KgVarConfig/components/KgVarConfigModal.d.ts +15 -0
- package/dist/src/component/KgVarConfig/components/button/KgVarConfig.Modal.Button.VarButton.d.ts +7 -0
- package/dist/src/component/KgVarConfig/components/button/KgVarConfig.Modal.Button.VarButtonConfig.d.ts +7 -0
- package/dist/src/component/KgVarConfig/components/button/KgVarConfig.Modal.Button.d.ts +5 -0
- package/dist/src/component/KgVarConfig/components/child/KgVarConfig.Modal.Child.d.ts +7 -0
- package/dist/src/component/KgVarConfig/components/search/KgVarConfig.Modal.Search.VarProfileConfig.d.ts +7 -0
- package/dist/src/component/KgVarConfig/components/search/KgVarConfig.Modal.Search.VarProfileMaster.d.ts +7 -0
- package/dist/src/component/KgVarConfig/components/search/KgVarConfig.Modal.Search.VarProfileMaster.service.d.ts +7 -0
- package/dist/src/component/KgVarConfig/components/search/KgVarConfig.Modal.Search.d.ts +5 -0
- package/dist/src/component/KgVarConfig/components/submit/KgVarConfig.Modal.Submit.VarSubmitConfig.d.ts +7 -0
- package/dist/src/component/KgVarConfig/components/submit/KgVarConfig.Modal.Submit.VarSubmitDetail.d.ts +7 -0
- package/dist/src/component/KgVarConfig/components/submit/KgVarConfig.Modal.Submit.d.ts +5 -0
- package/dist/src/component/KgVarConfig/components/table/KgVarConfig.Modal.Table.VarGridConfig.d.ts +7 -0
- package/dist/src/component/KgVarConfig/components/table/KgVarConfig.Modal.Table.VarGridMaster.d.ts +7 -0
- package/dist/src/component/KgVarConfig/components/table/KgVarConfig.Modal.Table.VarGridMaster.service.d.ts +23 -0
- package/dist/src/component/KgVarConfig/components/table/KgVarConfig.Modal.Table.d.ts +5 -0
- package/dist/src/component/KgVarConfig/components/var/KgVarConfig.Modal.Var.VarConfigControl.d.ts +2 -0
- package/dist/src/component/KgVarConfig/components/var/KgVarConfig.Modal.Var.VarConfigDescription.d.ts +2 -0
- package/dist/src/component/KgVarConfig/components/var/KgVarConfig.Modal.Var.VarConfigInput.d.ts +2 -0
- package/dist/src/component/KgVarConfig/components/var/KgVarConfig.Modal.Var.VarConfigLookup.d.ts +2 -0
- package/dist/src/component/KgVarConfig/components/var/KgVarConfig.Modal.Var.VarConfigPossibility.d.ts +2 -0
- package/dist/src/component/KgVarConfig/components/var/KgVarConfig.Modal.Var.VarConfigTip.d.ts +2 -0
- package/dist/src/component/KgVarConfig/components/var/KgVarConfig.Modal.Var.VarVariable.d.ts +2 -0
- package/dist/src/component/KgVarConfig/index.d.ts +3 -0
- package/dist/src/component/KgVarConfig/index.hooks.d.ts +17 -0
- package/dist/src/component/KgVarConfig/index.store.d.ts +16 -0
- package/dist/src/component/KgVarConfig/index.vm.d.ts +50 -0
- package/dist/src/component/KgWarehouse/KgWarehouse.d.ts +47 -0
- package/dist/src/component/KgWarehouse/index.d.ts +4 -0
- package/dist/src/component/KgWarehouse/index.guard.d.ts +8 -0
- package/dist/src/component/KgWarehouse/index.hooks.d.ts +27 -0
- package/dist/src/component/KgWarehouse/index.store.d.ts +63 -0
- package/dist/src/component/KgYesOrNo/KgYesOrNo.d.ts +60 -0
- package/dist/src/component/KgYesOrNo/index.d.ts +1 -0
- package/dist/src/component/index.d.ts +21 -0
- package/dist/src/component/util.d.ts +14 -0
- package/dist/src/config/index.d.ts +3 -0
- package/dist/src/config/index.hooks.d.ts +36 -0
- package/dist/src/config/index.store.d.ts +315 -0
- package/dist/src/config/setup/index.d.ts +3 -0
- package/dist/src/config/setup/setup.d.ts +28 -0
- package/dist/src/config/setup/setupKgLocale.d.ts +29 -0
- package/dist/src/config/setup/setupKgStore.d.ts +18 -0
- package/dist/src/const/i18n/en.d.ts +278 -0
- package/dist/src/const/i18n/es_ES.d.ts +278 -0
- package/dist/src/const/i18n/fr_FR.d.ts +278 -0
- package/dist/src/const/i18n/index.d.ts +2 -0
- package/dist/src/const/i18n/km_KH.d.ts +278 -0
- package/dist/src/const/i18n/ko_KR.d.ts +278 -0
- package/dist/src/const/i18n/vi_VN.d.ts +278 -0
- package/dist/src/const/i18n/zh_CN.d.ts +278 -0
- package/dist/src/const/index.d.ts +3 -0
- package/dist/src/const/index.vm.d.ts +733 -0
- package/dist/src/const/injection-keys.const.d.ts +9 -0
- package/dist/src/helper/ant-design-vue.d.ts +347 -0
- package/dist/src/helper/tsx.helper.d.ts +23 -0
- package/dist/src/index.d.ts +11 -0
- package/dist/src/page/KgPageDda/KgPageDda.d.ts +8 -0
- package/dist/src/page/KgPageDda/components/KgPageDda.Create.Basic.SqlModal.d.ts +32 -0
- package/dist/src/page/KgPageDda/components/KgPageDda.Create.Basic.d.ts +7 -0
- package/dist/src/page/KgPageDda/components/KgPageDda.Create.Button.d.ts +7 -0
- package/dist/src/page/KgPageDda/components/KgPageDda.Create.Menu.d.ts +7 -0
- package/dist/src/page/KgPageDda/components/KgPageDda.Create.Search.d.ts +7 -0
- package/dist/src/page/KgPageDda/components/KgPageDda.Create.Submit.d.ts +7 -0
- package/dist/src/page/KgPageDda/components/KgPageDda.Create.Table.d.ts +7 -0
- package/dist/src/page/KgPageDda/components/KgPageDda.Create.d.ts +33 -0
- package/dist/src/page/KgPageDda/components/KgPageDda.Create.store.d.ts +1322 -0
- package/dist/src/page/KgPageDda/index.d.ts +5 -0
- package/dist/src/page/KgPageDda/index.vm.d.ts +12 -0
- package/dist/src/page/index.d.ts +8 -0
- package/dist/src/project/build/getConfigFileName.d.ts +5 -0
- package/dist/src/project/build/index.d.ts +1 -0
- package/dist/src/project/index.d.ts +3 -0
- package/dist/src/project/types/axios.d.ts +35 -0
- package/dist/src/project/types/config.d.ts +121 -0
- package/dist/src/project/types/index.d.ts +4 -0
- package/dist/src/project/types/store.d.ts +42 -0
- package/dist/src/project/types/utils.d.ts +4 -0
- package/dist/src/service/http-client.d.ts +93 -0
- package/dist/src/service/index.d.ts +1 -0
- package/dist/src/util/index.d.ts +4 -0
- package/dist/src/util/kg-auth.util.d.ts +26 -0
- package/dist/src/util/kg-route.util.d.ts +57 -0
- package/dist/src/util/kg-var.util.d.ts +76 -0
- package/dist/src/util/kg.util.d.ts +150 -0
- package/package.json +31 -20
- package/script/bump-to.luotao.smartfactory.product.wms.wms--dev-3.2.ts +3 -0
- package/script/bump-to.luotao.smartfactory.product.wms.wms-vue3--focus.ts +3 -0
- package/script/bump-to.ts +38 -0
- package/script/bump.ts +35 -0
- package/script/copy-to.luotao.smartfactory.product.wms.wms--dev-3.2.ts +3 -0
- package/script/copy-to.luotao.smartfactory.product.wms.wms-vue3--focus.ts +3 -0
- package/script/copy-to.luotao.smartfactory.tyre.haohua.gantry.was-java--main.ts +3 -0
- package/script/copy-to.ts +23 -0
- package/script/publish.ts +30 -0
@@ -0,0 +1,40 @@
|
|
1
|
+
import { KG__VAR_BUTTON__TYPE } from '../../../const';
|
2
|
+
declare const _default: import("vue").DefineComponent<{
|
3
|
+
kgButton: import("vue").PropType<import("../../..").VarButton>;
|
4
|
+
kgColor: import("vue").PropType<import("../../../const").KG__VAR_BUTTON__COLOR | null>;
|
5
|
+
kgDisabled: {
|
6
|
+
type: import("vue").PropType<boolean | null | undefined>;
|
7
|
+
default: undefined;
|
8
|
+
};
|
9
|
+
kgIcon: import("vue").PropType<string | null>;
|
10
|
+
kgLoading: import("vue").PropType<boolean>;
|
11
|
+
kgPrimary: {
|
12
|
+
type: import("vue").PropType<boolean | null | undefined>;
|
13
|
+
default: undefined;
|
14
|
+
};
|
15
|
+
kgText: import("vue").PropType<string | null>;
|
16
|
+
kgType: import("vue").PropType<KG__VAR_BUTTON__TYPE | null>;
|
17
|
+
kgVarName: import("vue").PropType<string | null>;
|
18
|
+
onKgClick: import("vue").PropType<(args?: any) => Promise<boolean>>;
|
19
|
+
}, () => JSX.Element, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
|
20
|
+
kgButton: import("vue").PropType<import("../../..").VarButton>;
|
21
|
+
kgColor: import("vue").PropType<import("../../../const").KG__VAR_BUTTON__COLOR | null>;
|
22
|
+
kgDisabled: {
|
23
|
+
type: import("vue").PropType<boolean | null | undefined>;
|
24
|
+
default: undefined;
|
25
|
+
};
|
26
|
+
kgIcon: import("vue").PropType<string | null>;
|
27
|
+
kgLoading: import("vue").PropType<boolean>;
|
28
|
+
kgPrimary: {
|
29
|
+
type: import("vue").PropType<boolean | null | undefined>;
|
30
|
+
default: undefined;
|
31
|
+
};
|
32
|
+
kgText: import("vue").PropType<string | null>;
|
33
|
+
kgType: import("vue").PropType<KG__VAR_BUTTON__TYPE | null>;
|
34
|
+
kgVarName: import("vue").PropType<string | null>;
|
35
|
+
onKgClick: import("vue").PropType<(args?: any) => Promise<boolean>>;
|
36
|
+
}>>, {
|
37
|
+
kgDisabled: boolean | null | undefined;
|
38
|
+
kgPrimary: boolean | null | undefined;
|
39
|
+
}>;
|
40
|
+
export default _default;
|
@@ -0,0 +1,62 @@
|
|
1
|
+
import { default as KgButtonItem } from './KgButton.Item';
|
2
|
+
declare const _default: {
|
3
|
+
new (...args: any[]): {
|
4
|
+
$: import("vue").ComponentInternalInstance;
|
5
|
+
$data: {};
|
6
|
+
$props: Partial<{}> & Omit<Readonly<import("vue").ExtractPropTypes<{
|
7
|
+
KgLoading: import("vue").PropType<(button: import("../..").VarButton) => boolean | undefined>;
|
8
|
+
kgDisabled: import("vue").PropType<(button: import("../..").VarButton) => boolean | undefined>;
|
9
|
+
}>> & import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, never>;
|
10
|
+
$attrs: {
|
11
|
+
[x: string]: unknown;
|
12
|
+
};
|
13
|
+
$refs: {
|
14
|
+
[x: string]: unknown;
|
15
|
+
};
|
16
|
+
$slots: Readonly<{
|
17
|
+
[name: string]: import("vue").Slot | undefined;
|
18
|
+
}>;
|
19
|
+
$root: import("vue").ComponentPublicInstance<{}, {}, {}, {}, {}, {}, {}, {}, false, import("vue").ComponentOptionsBase<any, any, any, any, any, any, any, any, any, {}, {}, string>, {}> | null;
|
20
|
+
$parent: import("vue").ComponentPublicInstance<{}, {}, {}, {}, {}, {}, {}, {}, false, import("vue").ComponentOptionsBase<any, any, any, any, any, any, any, any, any, {}, {}, string>, {}> | null;
|
21
|
+
$emit: (event: string, ...args: any[]) => void;
|
22
|
+
$el: any;
|
23
|
+
$options: import("vue").ComponentOptionsBase<Readonly<import("vue").ExtractPropTypes<{
|
24
|
+
KgLoading: import("vue").PropType<(button: import("../..").VarButton) => boolean | undefined>;
|
25
|
+
kgDisabled: import("vue").PropType<(button: import("../..").VarButton) => boolean | undefined>;
|
26
|
+
}>>, () => JSX.Element, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, {}, {}, string> & {
|
27
|
+
beforeCreate?: ((() => void) | (() => void)[]) | undefined;
|
28
|
+
created?: ((() => void) | (() => void)[]) | undefined;
|
29
|
+
beforeMount?: ((() => void) | (() => void)[]) | undefined;
|
30
|
+
mounted?: ((() => void) | (() => void)[]) | undefined;
|
31
|
+
beforeUpdate?: ((() => void) | (() => void)[]) | undefined;
|
32
|
+
updated?: ((() => void) | (() => void)[]) | undefined;
|
33
|
+
activated?: ((() => void) | (() => void)[]) | undefined;
|
34
|
+
deactivated?: ((() => void) | (() => void)[]) | undefined;
|
35
|
+
beforeDestroy?: ((() => void) | (() => void)[]) | undefined;
|
36
|
+
beforeUnmount?: ((() => void) | (() => void)[]) | undefined;
|
37
|
+
destroyed?: ((() => void) | (() => void)[]) | undefined;
|
38
|
+
unmounted?: ((() => void) | (() => void)[]) | undefined;
|
39
|
+
renderTracked?: (((e: import("vue").DebuggerEvent) => void) | ((e: import("vue").DebuggerEvent) => void)[]) | undefined;
|
40
|
+
renderTriggered?: (((e: import("vue").DebuggerEvent) => void) | ((e: import("vue").DebuggerEvent) => void)[]) | undefined;
|
41
|
+
errorCaptured?: (((err: unknown, instance: import("vue").ComponentPublicInstance<{}, {}, {}, {}, {}, {}, {}, {}, false, import("vue").ComponentOptionsBase<any, any, any, any, any, any, any, any, any, {}, {}, string>, {}> | null, info: string) => boolean | void) | ((err: unknown, instance: import("vue").ComponentPublicInstance<{}, {}, {}, {}, {}, {}, {}, {}, false, import("vue").ComponentOptionsBase<any, any, any, any, any, any, any, any, any, {}, {}, string>, {}> | null, info: string) => boolean | void)[]) | undefined;
|
42
|
+
};
|
43
|
+
$forceUpdate: () => void;
|
44
|
+
$nextTick: typeof import("vue").nextTick;
|
45
|
+
$watch<T extends string | ((...args: any) => any)>(source: T, cb: T extends (...args: any) => infer R ? (args_0: R, args_1: R) => any : (...args: any) => any, options?: import("vue").WatchOptions<boolean> | undefined): import("vue").WatchStopHandle;
|
46
|
+
} & Readonly<import("vue").ExtractPropTypes<{
|
47
|
+
KgLoading: import("vue").PropType<(button: import("../..").VarButton) => boolean | undefined>;
|
48
|
+
kgDisabled: import("vue").PropType<(button: import("../..").VarButton) => boolean | undefined>;
|
49
|
+
}>> & import("vue").ShallowUnwrapRef<() => JSX.Element> & {} & import("vue").ComponentCustomProperties & {};
|
50
|
+
__isFragment?: undefined;
|
51
|
+
__isTeleport?: undefined;
|
52
|
+
__isSuspense?: undefined;
|
53
|
+
} & import("vue").ComponentOptionsBase<Readonly<import("vue").ExtractPropTypes<{
|
54
|
+
KgLoading: import("vue").PropType<(button: import("../..").VarButton) => boolean | undefined>;
|
55
|
+
kgDisabled: import("vue").PropType<(button: import("../..").VarButton) => boolean | undefined>;
|
56
|
+
}>>, () => JSX.Element, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, {}, {}, string> & import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps & {
|
57
|
+
Item: typeof KgButtonItem;
|
58
|
+
};
|
59
|
+
export default _default;
|
60
|
+
export { type IKgButtonProps } from './KgButton';
|
61
|
+
export * from './index.hooks';
|
62
|
+
export * from './index.store';
|
@@ -0,0 +1,183 @@
|
|
1
|
+
import { ComputedRef } from 'vue';
|
2
|
+
import { IRemoveEventListenerHandler, KG__VAR_BUTTON__TYPE } from '../../const';
|
3
|
+
import { IKgButtonClickEventListener, IKgButtonImportOkEventListener, IKgButtonStore, IKgButtonSubmitCancelEventListener, IKgButtonSubmitSaveEventListener } from './index.store';
|
4
|
+
export interface IUseKgButton {
|
5
|
+
/**
|
6
|
+
* <p>手动点击某个按钮.</p>
|
7
|
+
* <p>调用此方法相当于手动触发某个按钮的点击事件.</p>
|
8
|
+
*
|
9
|
+
* @param param.type 按钮类型.
|
10
|
+
* @param param.varName 按钮变量名称.
|
11
|
+
*/
|
12
|
+
click(param: {
|
13
|
+
type?: KG__VAR_BUTTON__TYPE;
|
14
|
+
varName?: string;
|
15
|
+
}): void;
|
16
|
+
/**
|
17
|
+
* <p>「当前按钮」. 即当前提交表单所属的按钮.</p>
|
18
|
+
*/
|
19
|
+
currentButton: ComputedRef<ReturnType<IKgButtonStore['getCurrentButton']>>;
|
20
|
+
/**
|
21
|
+
* 界面标识.
|
22
|
+
*/
|
23
|
+
formID: string;
|
24
|
+
/**
|
25
|
+
* 获取某一个按钮的翻译.
|
26
|
+
*
|
27
|
+
* @param param.varName 按钮变量名称.
|
28
|
+
*/
|
29
|
+
getButtonDescription(param: {
|
30
|
+
varName: string | null | undefined;
|
31
|
+
}): string;
|
32
|
+
/**
|
33
|
+
* <p>判断某个按钮的 click 事件是否被拦截.</p>
|
34
|
+
* <p>用户调用 <code>kgVar.kgButton.onClick(listener)</code> 监听了 click 事件, 并且回调函数返回了 true, 表示该 click 事件被用户拦截了.</p>
|
35
|
+
* <p>被拦截之后, 该按钮的默认逻辑不会执行(例如打开提交弹窗, 加载各种数据等等), 后续由用户自行处理.</p>
|
36
|
+
*
|
37
|
+
* <ul>
|
38
|
+
* <li>
|
39
|
+
* <p>如果参数 {@link param.type} !== <code>undefined</code> && {@link param.type} !== {@link KG__VAR_BUTTON__TYPE.OTHER}, 则根据参数 {@link param.type} 获取按钮.</p>
|
40
|
+
* </li>
|
41
|
+
* <li>
|
42
|
+
* <p>如果参数 {@link param.type} === <code>undefined</code> || {@link param.type} === {@link KG__VAR_BUTTON__TYPE.OTHER}, 则参数 {@link param.varName} 必须传值, 否则报错.</p>
|
43
|
+
* <p>根据参数 {@link param.varName} 获取按钮.</p>
|
44
|
+
* </li>
|
45
|
+
* </ul>
|
46
|
+
*
|
47
|
+
* @param param.type <p>按钮的类型, 对应的是 {@link VarButton.typ} 属性, 取值请参考 {@link KG__VAR_BUTTON__TYPE}.</p>
|
48
|
+
* @param param.varName <p>按钮的变量名称, 对应的是 {@link VarButton.var_nam} 属性.</p>
|
49
|
+
*/
|
50
|
+
isClickIntercepted(param: {
|
51
|
+
type?: KG__VAR_BUTTON__TYPE;
|
52
|
+
varName?: string | null;
|
53
|
+
}): boolean;
|
54
|
+
/**
|
55
|
+
* <p>判断某个按钮是否是「当前按钮」.</p>
|
56
|
+
*
|
57
|
+
* <ul>
|
58
|
+
* <li>
|
59
|
+
* <p>如果参数 {@link param.type} !== <code>undefined</code> && {@link param.type} !== {@link KG__VAR_BUTTON__TYPE.OTHER}, 则根据参数 {@link param.type} 获取按钮.</p>
|
60
|
+
* </li>
|
61
|
+
* <li>
|
62
|
+
* <p>如果参数 {@link param.type} === <code>undefined</code> || {@link param.type} === {@link KG__VAR_BUTTON__TYPE.OTHER}, 则参数 {@link param.varName} 必须传值, 否则报错.</p>
|
63
|
+
* <p>根据参数 {@link param.varName} 获取按钮.</p>
|
64
|
+
* </li>
|
65
|
+
* </ul>
|
66
|
+
*
|
67
|
+
* @param param.type <p>按钮的类型, 对应的是 {@link VarButton.typ} 属性, 取值请参考 {@link KG__VAR_BUTTON__TYPE}.</p>
|
68
|
+
* @param param.varName <p>按钮的变量名称, 对应的是 {@link VarButton.var_nam} 属性.</p>
|
69
|
+
*/
|
70
|
+
isCurrentButton(param: {
|
71
|
+
type?: KG__VAR_BUTTON__TYPE;
|
72
|
+
varName?: string;
|
73
|
+
}): boolean;
|
74
|
+
/**
|
75
|
+
* <p>判断「当前按钮」的 click 事件是否被拦截.</p>
|
76
|
+
*/
|
77
|
+
isCurrentButtonClickIntercepted: ComputedRef<ReturnType<IKgButtonStore['isClickIntercepted']>>;
|
78
|
+
/**
|
79
|
+
* <p>判断「当前按钮」是否正在请求后端接口.</p>
|
80
|
+
*/
|
81
|
+
isCurrentButtonRequesting: ComputedRef<ReturnType<IKgButtonStore['isCurrentButtonRequesting']>>;
|
82
|
+
/**
|
83
|
+
* 监听事件: 点击按钮.
|
84
|
+
*
|
85
|
+
* @param listener 事件监听函数.
|
86
|
+
* @param isOnce 是否只会触发一次. 默认为 undefined.
|
87
|
+
*/
|
88
|
+
onClick(listener: IKgButtonClickEventListener, isOnce?: boolean): IRemoveEventListenerHandler;
|
89
|
+
/**
|
90
|
+
* 监听事件: 导入成功, 导入接口调用成功.
|
91
|
+
*
|
92
|
+
* @param listener 事件监听函数.
|
93
|
+
* @param isOnce 是否只会触发一次. 默认为 undefined.
|
94
|
+
*/
|
95
|
+
onImportOk(listener: IKgButtonImportOkEventListener, isOnce?: boolean): IRemoveEventListenerHandler;
|
96
|
+
/**
|
97
|
+
* 监听事件: 表格内编辑时, 点击取消按钮.
|
98
|
+
*
|
99
|
+
* @param listener 事件监听函数.
|
100
|
+
* @param isOnce 是否只会触发一次. 默认为 undefined.
|
101
|
+
*/
|
102
|
+
onSubmitCancel(listener: IKgButtonSubmitCancelEventListener, isOnce?: boolean): IRemoveEventListenerHandler;
|
103
|
+
/**
|
104
|
+
* 监听事件: 表格内编辑时, 点击保存按钮.
|
105
|
+
*
|
106
|
+
* @param listener 事件监听函数.
|
107
|
+
* @param isOnce 是否只会触发一次. 默认为 undefined.
|
108
|
+
*/
|
109
|
+
onSubmitSave(listener: IKgButtonSubmitSaveEventListener, isOnce?: boolean): IRemoveEventListenerHandler;
|
110
|
+
/**
|
111
|
+
* <p>「查询按钮」.</p>
|
112
|
+
*/
|
113
|
+
searchButton: ComputedRef<ReturnType<IKgButtonStore['getSearchButton']>>;
|
114
|
+
/**
|
115
|
+
* <p>设置「当前按钮」. 比如点击「创建」按钮, 则此时「创建」按钮就是「当前按钮」, 同一时间最多只会有一个按钮处于「正在执行」状态.</p>
|
116
|
+
*
|
117
|
+
* <ul>
|
118
|
+
* <li>
|
119
|
+
* <p>如果参数 {@link param} === null, 表示清空「当前按钮」.</p>
|
120
|
+
* </li>
|
121
|
+
* <li>
|
122
|
+
* <p>否则, 如果参数 {@link param.type} !== <code>undefined</code> && {@link param.type} !== {@link KG__VAR_BUTTON__TYPE.OTHER}, 则根据参数 {@link param.type} 获取按钮.</p>
|
123
|
+
* </li>
|
124
|
+
* <li>
|
125
|
+
* <p>否则, 如果参数 {@link param.type} === <code>undefined</code> || {@link param.type} === {@link KG__VAR_BUTTON__TYPE.OTHER}, 则参数 {@link param.varName} 必须传值, 否则报错.</p>
|
126
|
+
* <p>根据参数 {@link param.varName} 获取按钮.</p>
|
127
|
+
* </li>
|
128
|
+
* </ul>
|
129
|
+
*
|
130
|
+
* @param param.type <p>按钮的类型, 对应的是 {@link VarButton.typ} 属性, 取值请参考 {@link KG__VAR_BUTTON__TYPE}.</p>
|
131
|
+
* @param param.varName <p>按钮的变量名称, 对应的是 {@link VarButton.var_nam} 属性.</p>
|
132
|
+
*/
|
133
|
+
setCurrentButton(param: {
|
134
|
+
type?: KG__VAR_BUTTON__TYPE;
|
135
|
+
varName?: string | null;
|
136
|
+
} | null): Promise<void>;
|
137
|
+
/**
|
138
|
+
* <p>设置某个按钮的 click 事件是否被拦截.</p>
|
139
|
+
*
|
140
|
+
* <ul>
|
141
|
+
* <li>
|
142
|
+
* <p>如果参数 {@link param.type} !== <code>undefined</code> && {@link param.type} !== {@link KG__VAR_BUTTON__TYPE.OTHER}, 则根据参数 {@link param.type} 获取按钮.</p>
|
143
|
+
* </li>
|
144
|
+
* <li>
|
145
|
+
* <p>如果参数 {@link param.type} === <code>undefined</code> || {@link param.type} === {@link KG__VAR_BUTTON__TYPE.OTHER}, 则参数 {@link param.varName} 必须传值, 否则报错.</p>
|
146
|
+
* <p>根据参数 {@link param.varName} 获取按钮.</p>
|
147
|
+
* </li>
|
148
|
+
* </ul>
|
149
|
+
*
|
150
|
+
* @param param.isIntercepted 是否被拦截.
|
151
|
+
* @param param.type <p>按钮的类型, 对应的是 {@link VarButton.typ} 属性, 取值请参考 {@link KG__VAR_BUTTON__TYPE}.</p>
|
152
|
+
* @param param.varName <p>按钮的变量名称, 对应的是 {@link VarButton.var_nam} 属性.</p>
|
153
|
+
*/
|
154
|
+
setIsClickIntercepted(param: {
|
155
|
+
isIntercepted: boolean;
|
156
|
+
type?: KG__VAR_BUTTON__TYPE;
|
157
|
+
varName?: string | null;
|
158
|
+
}): void;
|
159
|
+
/**
|
160
|
+
* 设置「当前按钮」是否正在请求后端接口.
|
161
|
+
*
|
162
|
+
* @param param.isRequesting 「当前按钮」是否正在请求后端接口.
|
163
|
+
*/
|
164
|
+
setIsCurrentButtonRequesting(param: {
|
165
|
+
isRequesting: boolean;
|
166
|
+
}): void;
|
167
|
+
/**
|
168
|
+
* 状态数据.
|
169
|
+
*/
|
170
|
+
store: IKgButtonStore;
|
171
|
+
/**
|
172
|
+
* 按钮配置.
|
173
|
+
*/
|
174
|
+
varButtonConfig: ComputedRef<ReturnType<IKgButtonStore['getVarButtonConfig']>>;
|
175
|
+
/**
|
176
|
+
* 所有按钮.
|
177
|
+
*/
|
178
|
+
varButtons: ComputedRef<ReturnType<IKgButtonStore['getVarButtons']>>;
|
179
|
+
}
|
180
|
+
/**
|
181
|
+
* @param formID 界面标识.
|
182
|
+
*/
|
183
|
+
export declare function useKgButton(formID?: string | null): IUseKgButton;
|
@@ -0,0 +1,116 @@
|
|
1
|
+
import { StoreDefinition } from 'pinia';
|
2
|
+
import { VarButton, VarButtonConfig } from '../../api/WMS/models';
|
3
|
+
import { IKgEventListener, KG__VAR_BUTTON__TYPE } from '../../const';
|
4
|
+
/**
|
5
|
+
* 事件类型.
|
6
|
+
* 'click': 点击按钮
|
7
|
+
* 'importOk': 导入成功, 导入接口调用成功
|
8
|
+
* 'submitSave': 表格内编辑时, 点击保存按钮
|
9
|
+
* 'submitCancel': 表格内编辑时, 点击取消按钮
|
10
|
+
*/
|
11
|
+
export declare type IKgButtonEvent = 'click' | 'importOk' | 'submitSave' | 'submitCancel';
|
12
|
+
export declare type IKgButtonClickEventListenerParameter = {
|
13
|
+
/**
|
14
|
+
* 被点击的按钮.
|
15
|
+
*/
|
16
|
+
button: VarButton;
|
17
|
+
};
|
18
|
+
export declare type IKgButtonClickEventListener = ((param: IKgButtonClickEventListenerParameter) => Promise<boolean>) & IKgEventListener;
|
19
|
+
export declare type IKgButtonImportOkEventListenerParameter = {
|
20
|
+
button?: VarButton | null;
|
21
|
+
};
|
22
|
+
export declare type IKgButtonImportOkEventListener = ((param: IKgButtonImportOkEventListenerParameter) => Promise<boolean>) & IKgEventListener;
|
23
|
+
export declare type IKgButtonSubmitSaveEventListenerParameter = {};
|
24
|
+
export declare type IKgButtonSubmitSaveEventListener = ((param: IKgButtonSubmitSaveEventListenerParameter) => Promise<boolean>) & IKgEventListener;
|
25
|
+
export declare type IKgButtonSubmitCancelEventListenerParameter = {};
|
26
|
+
export declare type IKgButtonSubmitCancelEventListener = ((param: IKgButtonSubmitCancelEventListenerParameter) => Promise<boolean>) & IKgEventListener;
|
27
|
+
export declare type IKgButtonEventListenerParameter = IKgButtonClickEventListenerParameter | IKgButtonImportOkEventListenerParameter | IKgButtonSubmitSaveEventListenerParameter | IKgButtonSubmitCancelEventListenerParameter;
|
28
|
+
export declare type IKgButtonEventListener = IKgButtonClickEventListener | IKgButtonImportOkEventListener | IKgButtonSubmitSaveEventListener | IKgButtonSubmitCancelEventListener;
|
29
|
+
export interface IUseKgButtonStoreState {
|
30
|
+
clickEventListenerMap: Map<string, Array<IKgButtonClickEventListener>>;
|
31
|
+
/**
|
32
|
+
* <p>当前按钮.</p>
|
33
|
+
* <p>同一时间最多只会有一个按钮处于「正在执行」状态, 比如点击了创建按钮, 则当前按钮就是创建按钮.</p>
|
34
|
+
*/
|
35
|
+
currentButtonMap: Map<string, VarButton | null>;
|
36
|
+
importOkEventListenerMap: Map<string, Array<IKgButtonImportOkEventListener>>;
|
37
|
+
/**
|
38
|
+
* <p>按钮的 click 事件是否被拦截.</p>
|
39
|
+
* <p>用户调用 kgVar.kgButton.onClick(listener) 监听了 click 事件, 并且回调函数返回了 true, 表示该 click 事件被用户拦截了.</p>
|
40
|
+
* <p>被拦截之后, 该按钮的默认逻辑不会执行(例如打开提交弹窗, 加载各种数据等等), 后续由用户自行处理.</p>
|
41
|
+
*/
|
42
|
+
isClickInterceptedMap: Map<string, boolean>;
|
43
|
+
/**
|
44
|
+
* <p>当前按钮是否正在请求后端接口.</p>
|
45
|
+
* <p>比如点击了创建按钮, 打开了创建弹窗, 此时「当前按钮」指的就是创建按钮. 当点击弹窗中的保存按钮时, 表示正在请求后端接口.</p>
|
46
|
+
*/
|
47
|
+
isCurrentButtonRequestingMap: Map<string, boolean>;
|
48
|
+
submitCancelEventListenerMap: Map<string, Array<IKgButtonSubmitCancelEventListener>>;
|
49
|
+
submitSaveEventListenerMap: Map<string, Array<IKgButtonSubmitSaveEventListener>>;
|
50
|
+
}
|
51
|
+
export interface IUseKgButtonStoreGetters {
|
52
|
+
getButtonDescription(): (formID: string | null | undefined, param: {
|
53
|
+
varName: string | null | undefined;
|
54
|
+
}) => string;
|
55
|
+
getCurrentButton(): (formID: string | null | undefined) => VarButton | null;
|
56
|
+
getSearchButton(): (formID: string | null | undefined) => VarButton | null;
|
57
|
+
getVarButtonConfig(): (formID: string | null | undefined) => VarButtonConfig | null;
|
58
|
+
getVarButtons(): (formID: string | null | undefined) => Array<VarButton>;
|
59
|
+
isClickIntercepted(): (formID: string | undefined | null, param: {
|
60
|
+
type?: KG__VAR_BUTTON__TYPE;
|
61
|
+
varName?: string | null;
|
62
|
+
}) => boolean;
|
63
|
+
isCurrentButton(): (formID: string, param: {
|
64
|
+
varName?: string;
|
65
|
+
type?: KG__VAR_BUTTON__TYPE;
|
66
|
+
}) => boolean;
|
67
|
+
isCurrentButtonRequesting(): (formID: string | undefined | null) => boolean;
|
68
|
+
}
|
69
|
+
export interface IUseKgButtonStoreActions {
|
70
|
+
/**
|
71
|
+
* 注册事件监听.
|
72
|
+
* @param formID 界面标识.
|
73
|
+
* @param event 事件名称.
|
74
|
+
* @param listener 事件监听函数.
|
75
|
+
*/
|
76
|
+
addEventListener(formID: string, event: IKgButtonEvent, listener: any): void;
|
77
|
+
/**
|
78
|
+
* <p>手动点击某个按钮.</p>
|
79
|
+
* <p>调用此方法相当于手动触发某个按钮的点击事件.</p>
|
80
|
+
*
|
81
|
+
* @param formID 界面标识.
|
82
|
+
* @param type 按钮类型.
|
83
|
+
* @param varName 按钮变量名称.
|
84
|
+
*/
|
85
|
+
click(formID: string, type?: KG__VAR_BUTTON__TYPE, varName?: string): void;
|
86
|
+
dispose(formID: string | null | undefined): void;
|
87
|
+
/**
|
88
|
+
* 触发事件.
|
89
|
+
* @param formID 界面标识.
|
90
|
+
* @param event 事件名称.
|
91
|
+
* @param param 数据.
|
92
|
+
*/
|
93
|
+
emit<T = IKgButtonEventListenerParameter>(formID: string, event: IKgButtonEvent, param: T): Promise<boolean>;
|
94
|
+
/**
|
95
|
+
* 退订事件监听.
|
96
|
+
* @param formID 界面标识.
|
97
|
+
* @param event 事件名称.
|
98
|
+
* @param listener 事件监听函数.
|
99
|
+
*/
|
100
|
+
removeEventListener(formID: string, event: IKgButtonEvent, listener?: any): void;
|
101
|
+
setCurrentButton(formID: string, param: {
|
102
|
+
type?: KG__VAR_BUTTON__TYPE;
|
103
|
+
varName?: string | null;
|
104
|
+
} | null): Promise<void>;
|
105
|
+
setIsClickIntercepted(formID: string | undefined | null, param: {
|
106
|
+
isIntercepted: boolean;
|
107
|
+
type?: KG__VAR_BUTTON__TYPE;
|
108
|
+
varName?: string | null;
|
109
|
+
}): void;
|
110
|
+
setIsCurrentButtonRequesting(formID: string | undefined | null, param: {
|
111
|
+
isRequesting: boolean;
|
112
|
+
}): void;
|
113
|
+
}
|
114
|
+
export declare type IUseKgButtonStore = StoreDefinition<'KgButton', IUseKgButtonStoreState, IUseKgButtonStoreGetters, IUseKgButtonStoreActions>;
|
115
|
+
export declare type IKgButtonStore = ReturnType<IUseKgButtonStore>;
|
116
|
+
export declare const useKgButtonStore: IUseKgButtonStore;
|
@@ -0,0 +1,122 @@
|
|
1
|
+
import { ExtractPropTypes, PropType } from 'vue';
|
2
|
+
import './KgCanvas.css';
|
3
|
+
export declare const getProps: () => {
|
4
|
+
/**
|
5
|
+
* 是否启用网格背景.
|
6
|
+
*
|
7
|
+
* @default false
|
8
|
+
*/
|
9
|
+
kgIsGridBackground: {
|
10
|
+
type: PropType<boolean>;
|
11
|
+
default: boolean;
|
12
|
+
};
|
13
|
+
/**
|
14
|
+
* 是否启用预览面板.
|
15
|
+
*
|
16
|
+
* @default false
|
17
|
+
*/
|
18
|
+
kgIsEnableOverview: {
|
19
|
+
type: PropType<boolean>;
|
20
|
+
default: boolean;
|
21
|
+
};
|
22
|
+
/**
|
23
|
+
* 是否可以编辑.
|
24
|
+
*
|
25
|
+
* @default false
|
26
|
+
*/
|
27
|
+
kgIsEditable: {
|
28
|
+
type: PropType<boolean>;
|
29
|
+
default: boolean;
|
30
|
+
};
|
31
|
+
/**
|
32
|
+
* 是否支持拖动大小.
|
33
|
+
*
|
34
|
+
* @default false
|
35
|
+
*/
|
36
|
+
kgIsResizable: {
|
37
|
+
type: PropType<boolean>;
|
38
|
+
default: boolean;
|
39
|
+
};
|
40
|
+
};
|
41
|
+
export declare type KgCanvasProps = Partial<ExtractPropTypes<ReturnType<typeof getProps>>>;
|
42
|
+
declare const _default: import("vue").DefineComponent<{
|
43
|
+
/**
|
44
|
+
* 是否启用网格背景.
|
45
|
+
*
|
46
|
+
* @default false
|
47
|
+
*/
|
48
|
+
kgIsGridBackground: {
|
49
|
+
type: PropType<boolean>;
|
50
|
+
default: boolean;
|
51
|
+
};
|
52
|
+
/**
|
53
|
+
* 是否启用预览面板.
|
54
|
+
*
|
55
|
+
* @default false
|
56
|
+
*/
|
57
|
+
kgIsEnableOverview: {
|
58
|
+
type: PropType<boolean>;
|
59
|
+
default: boolean;
|
60
|
+
};
|
61
|
+
/**
|
62
|
+
* 是否可以编辑.
|
63
|
+
*
|
64
|
+
* @default false
|
65
|
+
*/
|
66
|
+
kgIsEditable: {
|
67
|
+
type: PropType<boolean>;
|
68
|
+
default: boolean;
|
69
|
+
};
|
70
|
+
/**
|
71
|
+
* 是否支持拖动大小.
|
72
|
+
*
|
73
|
+
* @default false
|
74
|
+
*/
|
75
|
+
kgIsResizable: {
|
76
|
+
type: PropType<boolean>;
|
77
|
+
default: boolean;
|
78
|
+
};
|
79
|
+
}, () => JSX.Element, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<ExtractPropTypes<{
|
80
|
+
/**
|
81
|
+
* 是否启用网格背景.
|
82
|
+
*
|
83
|
+
* @default false
|
84
|
+
*/
|
85
|
+
kgIsGridBackground: {
|
86
|
+
type: PropType<boolean>;
|
87
|
+
default: boolean;
|
88
|
+
};
|
89
|
+
/**
|
90
|
+
* 是否启用预览面板.
|
91
|
+
*
|
92
|
+
* @default false
|
93
|
+
*/
|
94
|
+
kgIsEnableOverview: {
|
95
|
+
type: PropType<boolean>;
|
96
|
+
default: boolean;
|
97
|
+
};
|
98
|
+
/**
|
99
|
+
* 是否可以编辑.
|
100
|
+
*
|
101
|
+
* @default false
|
102
|
+
*/
|
103
|
+
kgIsEditable: {
|
104
|
+
type: PropType<boolean>;
|
105
|
+
default: boolean;
|
106
|
+
};
|
107
|
+
/**
|
108
|
+
* 是否支持拖动大小.
|
109
|
+
*
|
110
|
+
* @default false
|
111
|
+
*/
|
112
|
+
kgIsResizable: {
|
113
|
+
type: PropType<boolean>;
|
114
|
+
default: boolean;
|
115
|
+
};
|
116
|
+
}>>, {
|
117
|
+
kgIsGridBackground: boolean;
|
118
|
+
kgIsEnableOverview: boolean;
|
119
|
+
kgIsEditable: boolean;
|
120
|
+
kgIsResizable: boolean;
|
121
|
+
}>;
|
122
|
+
export default _default;
|
@@ -0,0 +1,43 @@
|
|
1
|
+
import { Q } from '@thymine/xunee';
|
2
|
+
import { Ref } from 'vue';
|
3
|
+
import { IKgCanvasContextMenu, KgCanvasContextMenuProps } from './KgCanvasContextMenu';
|
4
|
+
/**
|
5
|
+
* 用户属性.
|
6
|
+
*/
|
7
|
+
export declare type IKgCanvasElementProperties = {
|
8
|
+
/**
|
9
|
+
* 编码, 全局唯一.
|
10
|
+
*/
|
11
|
+
key?: string;
|
12
|
+
/**
|
13
|
+
* 数据.
|
14
|
+
*/
|
15
|
+
data?: any;
|
16
|
+
/**
|
17
|
+
* 是否启用提示文本.
|
18
|
+
*/
|
19
|
+
isEnableTooltip?: boolean;
|
20
|
+
/**
|
21
|
+
* 样式.
|
22
|
+
*/
|
23
|
+
style?: {
|
24
|
+
/**
|
25
|
+
* 鼠标划过时的指针样式.
|
26
|
+
*/
|
27
|
+
hoverCursor?: 'pointer' | 'default';
|
28
|
+
};
|
29
|
+
[index: string]: any;
|
30
|
+
};
|
31
|
+
export declare type IUseGlobalContextMenus = {
|
32
|
+
globalContextMenus: Array<IKgCanvasContextMenu>;
|
33
|
+
};
|
34
|
+
export declare function _useGlobalContextMenus(param: {
|
35
|
+
eid: string;
|
36
|
+
}): IUseGlobalContextMenus;
|
37
|
+
export declare type IUseResizeObserver = {};
|
38
|
+
export declare function _useResizeObserver(param: {
|
39
|
+
eid: string;
|
40
|
+
graph: () => Q.Graph | null;
|
41
|
+
kgCanvasContextMenuProps: Ref<KgCanvasContextMenuProps>;
|
42
|
+
kgCanvasRef: Ref<HTMLDivElement | null>;
|
43
|
+
}): IUseResizeObserver;
|
@@ -0,0 +1,107 @@
|
|
1
|
+
import { Q } from '@thymine/xunee';
|
2
|
+
import { ExtractPropTypes, PropType } from 'vue';
|
3
|
+
import './KgCanvas.css';
|
4
|
+
/**
|
5
|
+
* 菜单属性.
|
6
|
+
*/
|
7
|
+
export declare type IKgCanvasContextMenu = {
|
8
|
+
/** 菜单编码. */
|
9
|
+
code?: string;
|
10
|
+
/** 菜单回调方法. */
|
11
|
+
handler?: (param: {
|
12
|
+
graph: Q.Graph;
|
13
|
+
element?: Q.Element;
|
14
|
+
elementUI?: Q.ElementUI;
|
15
|
+
ui?: Q.BaseUI;
|
16
|
+
}) => void;
|
17
|
+
/** 菜单图标. */
|
18
|
+
icon?: string;
|
19
|
+
/** 是否禁用. */
|
20
|
+
isDisabled?: boolean;
|
21
|
+
/** 是否是分割线. */
|
22
|
+
isDivider?: boolean;
|
23
|
+
/**
|
24
|
+
* 菜单标题.
|
25
|
+
*/
|
26
|
+
name?: string;
|
27
|
+
};
|
28
|
+
export declare const getProps: () => {
|
29
|
+
eid: PropType<string>;
|
30
|
+
kgElement: PropType<Q.Element<any>>;
|
31
|
+
kgElementUi: PropType<Q.ElementUI>;
|
32
|
+
kgGraph: PropType<Q.Graph>;
|
33
|
+
/**
|
34
|
+
* 是否显示.
|
35
|
+
*
|
36
|
+
* @default false
|
37
|
+
*/
|
38
|
+
kgIsVisible: {
|
39
|
+
type: PropType<boolean>;
|
40
|
+
default: boolean;
|
41
|
+
};
|
42
|
+
/**
|
43
|
+
* 菜单.
|
44
|
+
*/
|
45
|
+
kgMenus: PropType<IKgCanvasContextMenu[]>;
|
46
|
+
/**
|
47
|
+
* 鼠标事件对象.
|
48
|
+
*/
|
49
|
+
kgMouseEvent: PropType<MouseEvent>;
|
50
|
+
kgUi: PropType<Q.BaseUI>;
|
51
|
+
'onUpdate:kgIsVisible': PropType<(value: boolean) => void>;
|
52
|
+
};
|
53
|
+
export declare type KgCanvasContextMenuProps = Partial<ExtractPropTypes<ReturnType<typeof getProps>>>;
|
54
|
+
declare const _default: import("vue").DefineComponent<{
|
55
|
+
eid: PropType<string>;
|
56
|
+
kgElement: PropType<Q.Element<any>>;
|
57
|
+
kgElementUi: PropType<Q.ElementUI>;
|
58
|
+
kgGraph: PropType<Q.Graph>;
|
59
|
+
/**
|
60
|
+
* 是否显示.
|
61
|
+
*
|
62
|
+
* @default false
|
63
|
+
*/
|
64
|
+
kgIsVisible: {
|
65
|
+
type: PropType<boolean>;
|
66
|
+
default: boolean;
|
67
|
+
};
|
68
|
+
/**
|
69
|
+
* 菜单.
|
70
|
+
*/
|
71
|
+
kgMenus: PropType<IKgCanvasContextMenu[]>;
|
72
|
+
/**
|
73
|
+
* 鼠标事件对象.
|
74
|
+
*/
|
75
|
+
kgMouseEvent: PropType<MouseEvent>;
|
76
|
+
kgUi: PropType<Q.BaseUI>;
|
77
|
+
'onUpdate:kgIsVisible': PropType<(value: boolean) => void>;
|
78
|
+
}, () => JSX.Element, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, "update:kgIsVisible"[], "update:kgIsVisible", import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<ExtractPropTypes<{
|
79
|
+
eid: PropType<string>;
|
80
|
+
kgElement: PropType<Q.Element<any>>;
|
81
|
+
kgElementUi: PropType<Q.ElementUI>;
|
82
|
+
kgGraph: PropType<Q.Graph>;
|
83
|
+
/**
|
84
|
+
* 是否显示.
|
85
|
+
*
|
86
|
+
* @default false
|
87
|
+
*/
|
88
|
+
kgIsVisible: {
|
89
|
+
type: PropType<boolean>;
|
90
|
+
default: boolean;
|
91
|
+
};
|
92
|
+
/**
|
93
|
+
* 菜单.
|
94
|
+
*/
|
95
|
+
kgMenus: PropType<IKgCanvasContextMenu[]>;
|
96
|
+
/**
|
97
|
+
* 鼠标事件对象.
|
98
|
+
*/
|
99
|
+
kgMouseEvent: PropType<MouseEvent>;
|
100
|
+
kgUi: PropType<Q.BaseUI>;
|
101
|
+
'onUpdate:kgIsVisible': PropType<(value: boolean) => void>;
|
102
|
+
}>> & {
|
103
|
+
"onUpdate:kgIsVisible"?: ((...args: any[]) => any) | undefined;
|
104
|
+
}, {
|
105
|
+
kgIsVisible: boolean;
|
106
|
+
}>;
|
107
|
+
export default _default;
|