@qin-ui/antd-vue-pro 2.1.10 → 2.1.12

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.js CHANGED
@@ -1,11 +1,10 @@
1
1
  import "./antd-vue-pro.css";
2
2
  import _sfc_main from "./form/index.js";
3
- import { BaseField, BaseFormItem, ContainerFragment, FORM_ITEM_SLOT_KEYS, SlotComponent, TeleportComponentNamePrefix, componentMap, getInitProps, useFields, useForm, useFormRef } from "./form/index.js";
3
+ import { ContainerFragment, SlotComponent, useFields, useForm, useFormRef } from "./form/index.js";
4
4
  import BaseTable from "./table/index.js";
5
5
  import { useTable } from "./table/index.js";
6
- import _sfc_main$1 from "./component-provider/index.js";
7
- import { INJECT_COMPONENTS, INJECT_CONFIG, ensureInjectConfig, getInjectConfig } from "./component-provider/index.js";
8
- import { I, a, e } from "./core/index-C98RSrpN.js";
6
+ import { _ as _sfc_main$1 } from "./component-provider/index-Dmz32tSB.js";
7
+ import { e } from "./core/index-ghYuQ3Sy.js";
9
8
  const withInstall = (comp) => {
10
9
  comp.install = (app) => {
11
10
  app.component(comp.name, comp);
@@ -17,6 +16,21 @@ const ProTable = withInstall(BaseTable);
17
16
  const ProComponentProvider = withInstall(_sfc_main$1);
18
17
  const components = [ProForm, ProTable, ProComponentProvider];
19
18
  const index = {
19
+ /**
20
+ * @qin-ui/antd-vue-pro 安装方法
21
+ * @description 全局注册所有组件(ProForm、ProTable、ProComponentProvider)
22
+ *
23
+ * @param {App} app - Vue 应用实例
24
+ *
25
+ * @example
26
+ * ```ts
27
+ * import { createApp } from 'vue'
28
+ * import QinUI from '@qin-ui/antd-vue-pro'
29
+ *
30
+ * const app = createApp(App)
31
+ * app.use(QinUI) // 全局注册所有组件
32
+ * ```
33
+ */
20
34
  install(app) {
21
35
  components.forEach((component) => {
22
36
  app.component(component.name, component);
@@ -24,25 +38,12 @@ const index = {
24
38
  }
25
39
  };
26
40
  export {
27
- BaseField,
28
- _sfc_main as BaseForm,
29
- BaseFormItem,
30
41
  ContainerFragment,
31
- FORM_ITEM_SLOT_KEYS,
32
- INJECT_COMPONENTS,
33
- INJECT_CONFIG,
34
- I as InjectionFormKey,
35
- a as InjectionPathKey,
36
42
  ProComponentProvider,
37
43
  ProForm,
38
44
  ProTable,
39
45
  SlotComponent,
40
- TeleportComponentNamePrefix,
41
- componentMap,
42
46
  index as default,
43
- ensureInjectConfig,
44
- getInitProps,
45
- getInjectConfig,
46
47
  useFields,
47
48
  useForm,
48
49
  e as useFormData,
package/es/table/index.js CHANGED
@@ -1,9 +1,9 @@
1
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";
2
- import { INJECT_CONFIG } from "../component-provider/index.js";
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";
5
5
  import { p as pick } from "../vendor/utils/lodash-es-p6jau26B.js";
6
- import { g as getObject, c as camelizeProperties, f as useTable$1 } from "../core/index-C98RSrpN.js";
6
+ import { g as getObject, c as camelizeProperties, f as useTable$1 } from "../core/index-ghYuQ3Sy.js";
7
7
  import { useConfigContextInject } from "ant-design-vue/es/config-provider/context";
8
8
  import { tableProps } from "ant-design-vue/es/table";
9
9
  const _export_sfc = (sfc, props) => {
@@ -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;
@@ -225,7 +226,7 @@ const _sfc_main$7 = /* @__PURE__ */ defineComponent({
225
226
  };
226
227
  }
227
228
  });
228
- const SearchForm = /* @__PURE__ */ _export_sfc(_sfc_main$7, [["__scopeId", "data-v-fffc2a28"]]);
229
+ const SearchForm = /* @__PURE__ */ _export_sfc(_sfc_main$7, [["__scopeId", "data-v-b6a08ff0"]]);
229
230
  const _sfc_main$6 = /* @__PURE__ */ defineComponent({
230
231
  __name: "DefaultSearchFormContainer",
231
232
  setup(__props) {
@@ -690,7 +691,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
690
691
  };
691
692
  }
692
693
  });
693
- const BaseTable = /* @__PURE__ */ _export_sfc(_sfc_main, [["__scopeId", "data-v-f18ecc37"]]);
694
+ const BaseTable = /* @__PURE__ */ _export_sfc(_sfc_main, [["__scopeId", "data-v-c4d455c8"]]);
694
695
  const useTable = useTable$1;
695
696
  export {
696
697
  BaseTable as default,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@qin-ui/antd-vue-pro",
3
- "version": "2.1.10",
3
+ "version": "2.1.12",
4
4
  "description": "二次封装antd vue组件",
5
5
  "type": "module",
6
6
  "module": "es/index.js",
@@ -15,7 +15,9 @@
15
15
  "files": [
16
16
  "es",
17
17
  "README.md",
18
- "LICENSE"
18
+ "LICENSE",
19
+ "api.json",
20
+ "AI-CONTEXT.md"
19
21
  ],
20
22
  "homepage": "https://dufan3715.github.io/pro-components/",
21
23
  "repository": {
@@ -23,6 +25,7 @@
23
25
  "url": "git+https://github.com/dufan3715/pro-components.git"
24
26
  },
25
27
  "scripts": {
28
+ "prebuild": "tsx ../../scripts/generate-api-json.ts antd-vue-pro",
26
29
  "build": "vue-tsc && vite build"
27
30
  },
28
31
  "author": "dufan3715",