@qin-ui/antd-vue-pro 2.1.11 → 2.1.13

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/api.json CHANGED
@@ -1,5 +1,5 @@
1
1
  {
2
- "generatedAt": "2026-05-26T08:14:28.580Z",
2
+ "generatedAt": "2026-06-08T06:46:32.287Z",
3
3
  "name": "@qin-ui/antd-vue-pro",
4
4
  "api": [
5
5
  {
@@ -1,13 +1,13 @@
1
- .pro-table_search-form[data-v-fffc2a28] [class*='-form-item'] {
1
+ .pro-table_search-form[data-v-a2af360f] [class*='-form-item'] {
2
2
  margin: 0;
3
3
  }
4
- .pro-table_search-form_expand-toggle-button[data-v-fffc2a28] {
4
+ .pro-table_search-form_expand-toggle-button[data-v-a2af360f] {
5
5
  display: flex;
6
6
  align-items: center;
7
7
  padding: 0;
8
8
  padding-left: 4px;
9
9
  }
10
- .pro-table_search-form .transition[data-v-fffc2a28] {
10
+ .pro-table_search-form .transition[data-v-a2af360f] {
11
11
  transition: all 0.25s;
12
12
  }
13
13
  .pro-table_search-form-container[data-v-c385cd54] {
package/es/index.d.ts CHANGED
@@ -1155,9 +1155,11 @@ declare type SearchFormProps = {
1155
1155
  form: Form;
1156
1156
  layout?: 'grid' | 'inline';
1157
1157
  expand?: boolean | Expand;
1158
- searchButton?: Component<ButtonProps> | DefineComponent<ButtonProps>;
1159
- resetButton?: Component<ButtonProps> | DefineComponent<ButtonProps>;
1160
- expandButton?: Component<ExpandButtonProps> | DefineComponent<ExpandButtonProps>;
1158
+ searchButton?: Component<ButtonProps> | DefineComponent<ButtonProps> | false;
1159
+ resetButton?: Component<ButtonProps> | DefineComponent<ButtonProps> | false;
1160
+ expandButton?: Component<ExpandButtonProps> | DefineComponent<ExpandButtonProps> | false;
1161
+ rowGap?: number;
1162
+ columnGap?: number;
1161
1163
  } & /* @vue-ignore */ _FormProps & AllowedComponentProps;
1162
1164
 
1163
1165
  declare type SetColumn<T extends Data = Data, C extends BaseColumn<T> = BaseColumn<T>> = (key: Path<T>, column: C | ((pre: Readonly<C>) => C), options?: {
package/es/table/index.js CHANGED
@@ -1,4 +1,4 @@
1
- import { createElementBlock, openBlock, createElementVNode, defineComponent, ref, computed, watch, watchEffect, createBlock, unref, mergeProps, withCtx, createVNode, renderSlot, resolveDynamicComponent, createTextVNode, createCommentVNode, Fragment, toDisplayString, normalizeStyle, useModel, renderList, withModifiers, mergeModels, inject, useAttrs, useSlots, onMounted, normalizeClass, createSlots, normalizeProps, guardReactiveProps, nextTick } from "vue";
1
+ import { createElementBlock, openBlock, createElementVNode, defineComponent, ref, computed, watch, watchEffect, createBlock, unref, mergeProps, withCtx, createVNode, renderSlot, createCommentVNode, Fragment, resolveDynamicComponent, createTextVNode, toDisplayString, normalizeStyle, useModel, renderList, withModifiers, mergeModels, inject, useAttrs, useSlots, onMounted, normalizeClass, createSlots, normalizeProps, guardReactiveProps, nextTick } from "vue";
2
2
  import { I as INJECT_CONFIG } from "../component-provider/index-Dmz32tSB.js";
3
3
  import _sfc_main$9, { ContainerFragment as _sfc_main$a } from "../form/index.js";
4
4
  import { Space, Button, theme, Dropdown, Menu, MenuItem, Checkbox, MenuDivider, Table } from "ant-design-vue";
@@ -36,9 +36,11 @@ const _sfc_main$7 = /* @__PURE__ */ defineComponent({
36
36
  form: {},
37
37
  layout: { default: "grid" },
38
38
  expand: { type: [Boolean, Object], default: true },
39
- searchButton: { type: [Object, Function], default: void 0 },
40
- resetButton: { type: [Object, Function], default: void 0 },
41
- expandButton: { type: [Object, Function], default: void 0 },
39
+ searchButton: { type: [Object, Function, Boolean], default: void 0 },
40
+ resetButton: { type: [Object, Function, Boolean], default: void 0 },
41
+ expandButton: { type: [Object, Function, Boolean], default: void 0 },
42
+ rowGap: { default: 16 },
43
+ columnGap: { default: 24 },
42
44
  class: {},
43
45
  style: {}
44
46
  },
@@ -48,8 +50,6 @@ const _sfc_main$7 = /* @__PURE__ */ defineComponent({
48
50
  const proFormHeight = ref("unset");
49
51
  const collapseHeight = ref(0);
50
52
  let rowHeight = 32;
51
- const rowGap = 16;
52
- const columnGap = 24;
53
53
  const computedExpand = computed(() => {
54
54
  if (!__props.expand) return false;
55
55
  if (__props.expand === true) return { minExpandRows: 2, expandStatus: false };
@@ -96,11 +96,12 @@ const _sfc_main$7 = /* @__PURE__ */ defineComponent({
96
96
  var _a, _b, _c;
97
97
  return (_c = (_b = (_a = __props.form) == null ? void 0 : _a.fields.value) == null ? void 0 : _b.filter((f) => !f.hidden)) == null ? void 0 : _c.length;
98
98
  },
99
- () => formRef.value
99
+ () => formRef.value,
100
+ () => __props.expand
100
101
  ],
101
102
  () => {
102
103
  var _a, _b, _c, _d, _e;
103
- if (!expandStatus.value || !formRef.value) return;
104
+ if (!__props.expand || !expandStatus.value || !formRef.value) return;
104
105
  const proFormEl = (_a = formRef.value) == null ? void 0 : _a.$el;
105
106
  const { height = 0 } = ((_b = proFormEl == null ? void 0 : proFormEl.getBoundingClientRect) == null ? void 0 : _b.call(proFormEl)) || {};
106
107
  proFormHeight.value = height;
@@ -114,7 +115,7 @@ const _sfc_main$7 = /* @__PURE__ */ defineComponent({
114
115
  if (__props.layout === "grid" && computedExpand.value) {
115
116
  const { minExpandRows } = computedExpand.value;
116
117
  collapseHeight.value = Math.min(
117
- minExpandRows * rowHeight + (minExpandRows - 1) * rowGap,
118
+ minExpandRows * rowHeight + (minExpandRows - 1) * __props.rowGap,
118
119
  +proFormHeight.value
119
120
  );
120
121
  showExpandToggle.value = +proFormHeight.value - collapseHeight.value > 1;
@@ -130,7 +131,7 @@ const _sfc_main$7 = /* @__PURE__ */ defineComponent({
130
131
  const layoutProps = computed(
131
132
  () => __props.layout === "grid" ? {
132
133
  grid: {
133
- gutter: [columnGap, rowGap],
134
+ gutter: [__props.columnGap, __props.rowGap],
134
135
  style: { flex: 1, marginRight: "12px" }
135
136
  },
136
137
  style: {
@@ -140,7 +141,7 @@ const _sfc_main$7 = /* @__PURE__ */ defineComponent({
140
141
  }
141
142
  } : {
142
143
  layout: "inline",
143
- style: { gap: `${rowGap}px ${columnGap}px` },
144
+ style: { gap: `${__props.rowGap}px ${__props.columnGap}px` },
144
145
  grid: false
145
146
  }
146
147
  );
@@ -162,39 +163,43 @@ const _sfc_main$7 = /* @__PURE__ */ defineComponent({
162
163
  }, {
163
164
  default: withCtx(() => [
164
165
  renderSlot(_ctx.$slots, "reset-button", { onClick: onReset }, () => [
165
- __props.resetButton ? (openBlock(), createBlock(resolveDynamicComponent(__props.resetButton), {
166
- key: 0,
167
- onClick: onReset
168
- })) : (openBlock(), createBlock(unref(Button), {
169
- key: 1,
170
- class: "pro-table_search-form_reset-button",
171
- onClick: onReset
172
- }, {
173
- default: withCtx(() => [..._cache[0] || (_cache[0] = [
174
- createTextVNode("重置", -1)
175
- ])]),
176
- _: 1
177
- }))
166
+ __props.resetButton !== false ? (openBlock(), createElementBlock(Fragment, { key: 0 }, [
167
+ __props.resetButton ? (openBlock(), createBlock(resolveDynamicComponent(__props.resetButton), {
168
+ key: 0,
169
+ onClick: onReset
170
+ })) : (openBlock(), createBlock(unref(Button), {
171
+ key: 1,
172
+ class: "pro-table_search-form_reset-button",
173
+ onClick: onReset
174
+ }, {
175
+ default: withCtx(() => [..._cache[0] || (_cache[0] = [
176
+ createTextVNode("重置", -1)
177
+ ])]),
178
+ _: 1
179
+ }))
180
+ ], 64)) : createCommentVNode("", true)
178
181
  ], true),
179
182
  renderSlot(_ctx.$slots, "search-button", { onClick: onSearch }, () => [
180
- __props.searchButton ? (openBlock(), createBlock(resolveDynamicComponent(__props.searchButton), {
181
- key: 0,
182
- onClick: onSearch
183
- })) : (openBlock(), createBlock(unref(Button), {
184
- key: 1,
185
- class: "pro-table_search-form_search-button",
186
- type: "primary",
187
- "html-type": "submit",
188
- onClick: onSearch
189
- }, {
190
- default: withCtx(() => [..._cache[1] || (_cache[1] = [
191
- createTextVNode("查询 ", -1)
192
- ])]),
193
- _: 1
194
- }))
183
+ __props.searchButton !== false ? (openBlock(), createElementBlock(Fragment, { key: 0 }, [
184
+ __props.searchButton ? (openBlock(), createBlock(resolveDynamicComponent(__props.searchButton), {
185
+ key: 0,
186
+ onClick: onSearch
187
+ })) : (openBlock(), createBlock(unref(Button), {
188
+ key: 1,
189
+ class: "pro-table_search-form_search-button",
190
+ type: "primary",
191
+ "html-type": "submit",
192
+ onClick: onSearch
193
+ }, {
194
+ default: withCtx(() => [..._cache[1] || (_cache[1] = [
195
+ createTextVNode("查询 ", -1)
196
+ ])]),
197
+ _: 1
198
+ }))
199
+ ], 64)) : createCommentVNode("", true)
195
200
  ], true),
196
201
  renderSlot(_ctx.$slots, "expand-button", { onClick: changeExpandStatus }, () => [
197
- showExpandToggle.value ? (openBlock(), createElementBlock(Fragment, { key: 0 }, [
202
+ __props.expandButton !== false && showExpandToggle.value ? (openBlock(), createElementBlock(Fragment, { key: 0 }, [
198
203
  __props.expandButton ? (openBlock(), createBlock(resolveDynamicComponent(__props.expandButton), {
199
204
  key: 0,
200
205
  "expand-status": expandStatus.value,
@@ -225,7 +230,7 @@ const _sfc_main$7 = /* @__PURE__ */ defineComponent({
225
230
  };
226
231
  }
227
232
  });
228
- const SearchForm = /* @__PURE__ */ _export_sfc(_sfc_main$7, [["__scopeId", "data-v-fffc2a28"]]);
233
+ const SearchForm = /* @__PURE__ */ _export_sfc(_sfc_main$7, [["__scopeId", "data-v-a2af360f"]]);
229
234
  const _sfc_main$6 = /* @__PURE__ */ defineComponent({
230
235
  __name: "DefaultSearchFormContainer",
231
236
  setup(__props) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@qin-ui/antd-vue-pro",
3
- "version": "2.1.11",
3
+ "version": "2.1.13",
4
4
  "description": "二次封装antd vue组件",
5
5
  "type": "module",
6
6
  "module": "es/index.js",
@@ -24,6 +24,10 @@
24
24
  "type": "git",
25
25
  "url": "git+https://github.com/dufan3715/pro-components.git"
26
26
  },
27
+ "scripts": {
28
+ "prebuild": "tsx ../../scripts/generate-api-json.ts antd-vue-pro",
29
+ "build": "vue-tsc && vite build"
30
+ },
27
31
  "author": "dufan3715",
28
32
  "bugs": {
29
33
  "url": "https://github.com/dufan3715/pro-components/issues"
@@ -38,11 +42,11 @@
38
42
  "vue-component-type-helpers": "^3.2.5"
39
43
  },
40
44
  "devDependencies": {
45
+ "@qin-ui/core": "workspace:^",
41
46
  "@types/lodash-es": "^4.17.12",
42
47
  "ant-design-vue": "^4",
43
48
  "lodash-es": "^4.17.21",
44
- "scroll-into-view-if-needed": "^3.1.0",
45
- "@qin-ui/core": "^1.0.0"
49
+ "scroll-into-view-if-needed": "^3.1.0"
46
50
  },
47
51
  "sideEffects": false,
48
52
  "publishConfig": {
@@ -63,9 +67,5 @@
63
67
  "table",
64
68
  "pro-form",
65
69
  "pro-table"
66
- ],
67
- "scripts": {
68
- "prebuild": "tsx ../../scripts/generate-api-json.ts antd-vue-pro",
69
- "build": "vue-tsc && vite build"
70
- }
71
- }
70
+ ]
71
+ }
package/LICENSE DELETED
@@ -1,9 +0,0 @@
1
- MIT License
2
-
3
- Copyright (c) 2023-present pro-components
4
-
5
- Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
6
-
7
- The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
8
-
9
- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.