@gx-design-vue/pro-table 0.2.0-alpha.12 → 0.2.0-alpha.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.
@@ -1,5 +1,5 @@
1
1
  import { createVNode, defineComponent } from "vue";
2
- import { DownOutlined, UpOutlined } from "@antdv-next/icons";
2
+ import { GIcon } from "@gx-design-vue/icon";
3
3
  //#region src/components/SearchForm/CollapseToggle.tsx
4
4
  const CollapseToggle = /* @__PURE__ */ defineComponent({
5
5
  name: "ProTableCollapseToggle",
@@ -39,7 +39,7 @@ const CollapseToggle = /* @__PURE__ */ defineComponent({
39
39
  return createVNode("span", {
40
40
  "class": `${props.prefixCls}-search-control-text`,
41
41
  "onClick": () => props.onToggle(!props.collapsed)
42
- }, [props.collapsed ? "展开" : "收起", props.collapsed ? createVNode(DownOutlined, null, null) : createVNode(UpOutlined, null, null)]);
42
+ }, [props.collapsed ? "展开" : "收起", props.collapsed ? createVNode(GIcon, { "type": "DownOutlined" }, null) : createVNode(GIcon, { "type": "UpOutlined" }, null)]);
43
43
  };
44
44
  }
45
45
  });
@@ -67,9 +67,9 @@ declare const FormItemContainer: _$vue.DefineComponent<_$vue.ExtractPropTypes<{
67
67
  default: any;
68
68
  };
69
69
  }>> & Readonly<{}>, {
70
- onSubmit: () => void;
71
70
  loading: boolean;
72
71
  autoRequest: boolean;
72
+ onSubmit: () => void;
73
73
  }, {}, {}, {}, string, _$vue.ComponentProvideOptions, true, {}, any>;
74
74
  //#endregion
75
75
  export { FormItemContainer };
@@ -111,7 +111,6 @@ declare const ProTableSearchForm: _$vue.DefineComponent<_$vue.ExtractPropTypes<{
111
111
  default: any;
112
112
  };
113
113
  }>> & Readonly<{}>, {
114
- onReset: (params: Record<string, any>) => void;
115
114
  formColumns: ProSearchMap<"text", string>[];
116
115
  formConfig: FormConfig;
117
116
  formAutoRequest: boolean;
@@ -125,6 +124,7 @@ declare const ProTableSearchForm: _$vue.DefineComponent<_$vue.ExtractPropTypes<{
125
124
  cardBordered: boolean;
126
125
  proClasses: Record<string, string>;
127
126
  proStyles: Record<string, any>;
127
+ onReset: (params: Record<string, any>) => void;
128
128
  }, {}, {}, {}, string, _$vue.ComponentProvideOptions, true, {}, any>;
129
129
  //#endregion
130
130
  export { ProTableSearchForm as default };
@@ -1,6 +1,6 @@
1
1
  import { createVNode, defineComponent } from "vue";
2
2
  import { Tooltip } from "antdv-next";
3
- import { FullscreenExitOutlined, FullscreenOutlined } from "@antdv-next/icons";
3
+ import { GIcon } from "@gx-design-vue/icon";
4
4
  //#region src/components/Toolbar/FullscreenIcon.tsx
5
5
  const FullscreenIcon = /* @__PURE__ */ defineComponent({
6
6
  name: "ProTableFullscreenIcon",
@@ -15,7 +15,7 @@ const FullscreenIcon = /* @__PURE__ */ defineComponent({
15
15
  }
16
16
  },
17
17
  setup(props) {
18
- return () => createVNode(Tooltip, { "title": props.isFullscreen ? "退出全屏" : "全屏" }, { default: () => [createVNode("span", { "onClick": props.onToggle }, [props.isFullscreen ? createVNode(FullscreenExitOutlined, null, null) : createVNode(FullscreenOutlined, null, null)])] });
18
+ return () => createVNode(Tooltip, { "title": props.isFullscreen ? "退出全屏" : "全屏" }, { default: () => [createVNode("span", { "onClick": props.onToggle }, [props.isFullscreen ? createVNode(GIcon, { "type": "FullscreenExitOutlined" }, null) : createVNode(GIcon, { "type": "FullscreenOutlined" }, null)])] });
19
19
  }
20
20
  });
21
21
  //#endregion
@@ -1,6 +1,6 @@
1
1
  import { computed, createVNode, defineComponent, isVNode } from "vue";
2
2
  import { Tooltip } from "antdv-next";
3
- import { InfoCircleOutlined } from "@antdv-next/icons";
3
+ import { GIcon } from "@gx-design-vue/icon";
4
4
  //#region src/components/Toolbar/ListToolBar.tsx
5
5
  function renderSettingItem(setting) {
6
6
  if (isVNode(setting)) return setting;
@@ -76,7 +76,7 @@ const ListToolBar = /* @__PURE__ */ defineComponent({
76
76
  }, [hasTitle.value && createVNode("div", {
77
77
  "class": [`${prefix}-list-toolbar-title`, props.proClasses.toolbarTitle],
78
78
  "style": props.proStyles.toolbarTitle
79
- }, [props.headerTitle, props.headerTitleTip && createVNode(Tooltip, { "title": props.titleTipText }, { default: () => [typeof props.headerTitleTip === "boolean" ? createVNode(InfoCircleOutlined, null, null) : props.headerTitleTip] })]), leftActions.value.length > 0 && createVNode("div", { "class": `${prefix}-list-toolbar-actions` }, [leftActions.value])]) : hasRight.value ? createVNode("div", {
79
+ }, [props.headerTitle, props.headerTitleTip && createVNode(Tooltip, { "title": props.titleTipText }, { default: () => [typeof props.headerTitleTip === "boolean" ? createVNode(GIcon, { "type": "InfoCircleOutlined" }, null) : props.headerTitleTip] })]), leftActions.value.length > 0 && createVNode("div", { "class": `${prefix}-list-toolbar-actions` }, [leftActions.value])]) : hasRight.value ? createVNode("div", {
80
80
  "class": `${prefix}-list-toolbar-left`,
81
81
  "style": props.proStyles.toolbarLeft
82
82
  }, null) : null;
@@ -3,7 +3,7 @@ import { FullscreenIcon } from "./FullscreenIcon.js";
3
3
  import { ListToolBar } from "./ListToolBar.js";
4
4
  import { computed, createVNode, defineComponent, unref } from "vue";
5
5
  import { Tooltip } from "antdv-next";
6
- import { ReloadOutlined } from "@antdv-next/icons";
6
+ import { GIcon } from "@gx-design-vue/icon";
7
7
  //#region src/components/Toolbar/index.tsx
8
8
  function isObject(val) {
9
9
  return val !== null && typeof val === "object";
@@ -66,7 +66,7 @@ const Toolbar = /* @__PURE__ */ defineComponent({
66
66
  } else result.push(createVNode(Tooltip, {
67
67
  "title": "刷新",
68
68
  "key": "reload"
69
- }, { default: () => [createVNode("span", { "onClick": reloadAction }, [createVNode(ReloadOutlined, null, null)])] }));
69
+ }, { default: () => [createVNode("span", { "onClick": reloadAction }, [createVNode(GIcon, { "type": "ReloadOutlined" }, null)])] }));
70
70
  }
71
71
  if (options.fullScreen !== false) {
72
72
  const toggleAction = () => ctx?.toggleFullscreen?.();
@@ -3,7 +3,10 @@ import { merge } from "@gx-design-vue/pro-utils";
3
3
  //#region src/hooks/useTable.ts
4
4
  const EMPTY_ARRAY = [];
5
5
  function useTable(tableRef, options) {
6
- const tableState = reactive({});
6
+ const tableState = reactive({
7
+ params: {},
8
+ searchMap: []
9
+ });
7
10
  const syncedStateKeys = /* @__PURE__ */ new Set();
8
11
  function syncTableState(state = {}) {
9
12
  const nextState = merge({}, state);