@qin-ui/antd-vue-pro 1.0.3 → 1.0.4

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/form/index.js CHANGED
@@ -1,5 +1,5 @@
1
1
  import { inject, ref, h as h$1, getCurrentInstance, nextTick, reactive, defineComponent, createVNode, shallowRef, watch, unref, provide, watchEffect, onBeforeUnmount, computed, isRef, Fragment, Comment, Text, onMounted, cloneVNode, Transition, withDirectives, TransitionGroup, vShow, toRaw, resolveComponent, openBlock, createBlock, mergeProps, withCtx, createElementBlock, renderList, resolveDynamicComponent, normalizeProps, createSlots, createTextVNode, createCommentVNode, useAttrs, isVNode, renderSlot, toDisplayString, shallowReactive } from "vue";
2
- import { Input, Textarea, InputSearch, InputPassword, InputNumber, Select, Cascader, DatePicker as DatePicker$1, TimePicker as TimePicker$1, CheckboxGroup, RadioGroup, Switch, Slider, TreeSelect, Transfer, Row as Row$1, Col as Col$1, FormItem as FormItem$1, message, Form as Form$2 } from "ant-design-vue";
2
+ import { Input, Textarea, InputSearch, InputPassword, InputNumber, Select, Cascader, DatePicker as DatePicker$1, RangePicker, TimePicker as TimePicker$1, CheckboxGroup, RadioGroup, Switch, Slider, TreeSelect, Transfer, Row as Row$1, Col as Col$1, FormItem as FormItem$1, message, Form as Form$2 } from "ant-design-vue";
3
3
  var freeGlobal = typeof global == "object" && global && global.Object === Object && global;
4
4
  const freeGlobal$1 = freeGlobal;
5
5
  var freeSelf = typeof self == "object" && self && self.Object === Object && self;
@@ -10882,6 +10882,7 @@ const COMPONENT_MAP = /* @__PURE__ */ new Map([
10882
10882
  ["select", Select],
10883
10883
  ["cascader", Cascader],
10884
10884
  ["date-picker", DatePicker$1],
10885
+ ["range-picker", RangePicker],
10885
10886
  ["time-picker", TimePicker$1],
10886
10887
  ["checkbox-group", CheckboxGroup],
10887
10888
  ["radio-group", RadioGroup],
@@ -11631,20 +11632,22 @@ const _sfc_main$3 = /* @__PURE__ */ defineComponent({
11631
11632
  class: [unref(attrs).componentClassName, "field-component"],
11632
11633
  style: unref(attrs).componentStyle,
11633
11634
  path: _ctx.path
11634
- }), createSlots({ _: 2 }, [
11635
- renderList(_ctx.$slots, (slot, name) => {
11636
- return {
11637
- name,
11638
- fn: withCtx(() => [
11639
- renderSlot(_ctx.$slots, name, {}, void 0, true)
11640
- ])
11641
- };
11642
- }),
11635
+ }), createSlots({
11636
+ default: withCtx(() => [
11637
+ unref(COMPONENT_MAP).has(_ctx.component) ? (openBlock(true), createElementBlock(Fragment, { key: 0 }, renderList(_ctx.$slots, (slot, name) => {
11638
+ return renderSlot(_ctx.$slots, name, { key: name }, void 0, true);
11639
+ }), 128)) : createCommentVNode("", true)
11640
+ ]),
11641
+ _: 2
11642
+ }, [
11643
11643
  renderList(unref(attrs).slots, (slot, name) => {
11644
11644
  return {
11645
11645
  name,
11646
- fn: withCtx(() => [
11647
- !unref(FORM_ITEM_SLOT_KEYS).includes(name) ? (openBlock(), createBlock(unref(_sfc_main$1), mergeProps({ key: 0 }, { path: _ctx.path }, { component: slot }), null, 16, ["component"])) : createCommentVNode("", true)
11646
+ fn: withCtx((scoped) => [
11647
+ !unref(FORM_ITEM_SLOT_KEYS).includes(name) ? (openBlock(), createBlock(unref(_sfc_main$1), mergeProps({
11648
+ key: 0,
11649
+ path: _ctx.path
11650
+ }, scoped, { component: slot }), null, 16, ["path", "component"])) : createCommentVNode("", true)
11648
11651
  ])
11649
11652
  };
11650
11653
  })
@@ -11655,7 +11658,7 @@ const _sfc_main$3 = /* @__PURE__ */ defineComponent({
11655
11658
  };
11656
11659
  }
11657
11660
  });
11658
- const index_vue_vue_type_style_index_0_scoped_f5aa6c8e_lang = "";
11661
+ const index_vue_vue_type_style_index_0_scoped_02f40823_lang = "";
11659
11662
  const _export_sfc = (sfc, props) => {
11660
11663
  const target = sfc.__vccOpts || sfc;
11661
11664
  for (const [key, val] of props) {
@@ -11663,7 +11666,7 @@ const _export_sfc = (sfc, props) => {
11663
11666
  }
11664
11667
  return target;
11665
11668
  };
11666
- const BaseField = /* @__PURE__ */ _export_sfc(_sfc_main$3, [["__scopeId", "data-v-f5aa6c8e"]]);
11669
+ const BaseField = /* @__PURE__ */ _export_sfc(_sfc_main$3, [["__scopeId", "data-v-02f40823"]]);
11667
11670
  const _sfc_main$2 = /* @__PURE__ */ defineComponent({
11668
11671
  ...{
11669
11672
  name: "ContainerFragment"
@@ -11688,13 +11691,17 @@ const _sfc_main$2 = /* @__PURE__ */ defineComponent({
11688
11691
  }
11689
11692
  });
11690
11693
  const _sfc_main$1 = /* @__PURE__ */ defineComponent({
11694
+ ...{
11695
+ name: "SlotComponent",
11696
+ inheritAttrs: false
11697
+ },
11691
11698
  __name: "index",
11692
11699
  props: {
11693
11700
  component: {}
11694
11701
  },
11695
11702
  setup(__props) {
11696
11703
  return (_ctx, _cache) => {
11697
- return isVNode(_ctx.component) || typeof _ctx.component === "function" ? (openBlock(), createBlock(resolveDynamicComponent(_ctx.component), { key: 0 })) : (openBlock(), createElementBlock(Fragment, { key: 1 }, [
11704
+ return isVNode(_ctx.component) || typeof _ctx.component === "function" ? (openBlock(), createBlock(resolveDynamicComponent(_ctx.component), normalizeProps(mergeProps({ key: 0 }, _ctx.$attrs)), null, 16)) : (openBlock(), createElementBlock(Fragment, { key: 1 }, [
11698
11705
  createTextVNode(toDisplayString(_ctx.component), 1)
11699
11706
  ], 64));
11700
11707
  };
package/es/index.d.ts CHANGED
@@ -31,6 +31,7 @@ import { nextTick } from 'vue';
31
31
  import { Plugin as Plugin_2 } from 'vue';
32
32
  import { PropType } from 'vue';
33
33
  import type { RadioGroupProps } from 'ant-design-vue';
34
+ import { RangePickerProps } from 'ant-design-vue/es/date-picker';
34
35
  import { Ref } from 'vue';
35
36
  import { RendererElement } from 'vue';
36
37
  import { RendererNode } from 'vue';
@@ -678,8 +679,8 @@ export declare type FieldType = {
678
679
  /** 日期选择器-范围 */
679
680
  'range-picker': {
680
681
  component: 'range-picker';
681
- slots?: DatePickerSlots;
682
- } & DatePickerProps;
682
+ slots?: RangePickerSlots;
683
+ } & RangePickerProps;
683
684
  /** 时间选择器 */
684
685
  'time-picker': {
685
686
  component: 'time-picker';
@@ -1718,6 +1719,8 @@ export declare const ProForm: SFCWithInstall<{
1718
1719
 
1719
1720
  export declare type ProFormInstance = InstanceType<typeof _default_2>;
1720
1721
 
1722
+ declare type RangePickerSlots = FieldSlot<'dateRender' | 'renderExtraFooter' | 'separator'>;
1723
+
1721
1724
  export declare type Refs = {
1722
1725
  formItemRefs: Record<string, any>;
1723
1726
  fieldRefs: Record<string, any>;
package/es/style.css CHANGED
@@ -1,4 +1,4 @@
1
- .field-component[data-v-f5aa6c8e] {
1
+ .field-component[data-v-02f40823] {
2
2
  width: 100%;
3
3
  min-width: 120px;
4
4
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@qin-ui/antd-vue-pro",
3
- "version": "1.0.3",
3
+ "version": "1.0.4",
4
4
  "description": "二次封装antd vue组件",
5
5
  "type": "module",
6
6
  "main": "",