bkui-vue 0.0.1-beta.47 → 0.0.1-beta.48

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/dist/index.esm.js CHANGED
@@ -8828,7 +8828,7 @@ const checkboxGroupProps = {
8828
8828
  modelValue: PropTypes.array,
8829
8829
  disabled: PropTypes.bool
8830
8830
  };
8831
- var CheckboxGroup = defineComponent({
8831
+ var BkCheckboxGroup = defineComponent({
8832
8832
  name: "CheckboxGroup",
8833
8833
  props: checkboxGroupProps,
8834
8834
  emits: ["change", "update:modelValue"],
@@ -8877,7 +8877,7 @@ var CheckboxGroup = defineComponent({
8877
8877
  }, [(_a = this.$slots) == null ? void 0 : _a.default()]);
8878
8878
  }
8879
8879
  });
8880
- const BkCheckbox = withInstallProps(Component$o, { Group: CheckboxGroup });
8880
+ const BkCheckbox = withInstallProps(Component$o, { Group: BkCheckboxGroup });
8881
8881
  var Component$n = defineComponent({
8882
8882
  name: "Collapse",
8883
8883
  props: {
@@ -9097,7 +9097,7 @@ var Component$m = defineComponent({
9097
9097
  }
9098
9098
  });
9099
9099
  const BkModal = withInstallProps(Component$m, { propsMixin: propsMixin$1 }, true);
9100
- function _isSlot$3(s2) {
9100
+ function _isSlot$4(s2) {
9101
9101
  return typeof s2 === "function" || Object.prototype.toString.call(s2) === "[object Object]" && !isVNode(s2);
9102
9102
  }
9103
9103
  var Component$l = defineComponent({
@@ -9232,7 +9232,7 @@ var Component$l = defineComponent({
9232
9232
  const className = `bk-dialog-wrapper ${this.scrollable ? "scroll-able" : ""}`;
9233
9233
  return createVNode(BkModal, mergeProps(this.$props, {
9234
9234
  "class": className
9235
- }), _isSlot$3(dialogSlot) ? dialogSlot : {
9235
+ }), _isSlot$4(dialogSlot) ? dialogSlot : {
9236
9236
  default: () => [dialogSlot]
9237
9237
  });
9238
9238
  }
@@ -9863,7 +9863,7 @@ const Line = (_2, {
9863
9863
  "style": titleStyle
9864
9864
  }, [showDefault()])])]), showDefault(false)]);
9865
9865
  };
9866
- function _isSlot$2(s2) {
9866
+ function _isSlot$3(s2) {
9867
9867
  return typeof s2 === "function" || Object.prototype.toString.call(s2) === "[object Object]" && !isVNode(s2);
9868
9868
  }
9869
9869
  var Component$f = defineComponent({
@@ -9928,11 +9928,11 @@ var Component$f = defineComponent({
9928
9928
  const $props = __spreadProps(__spreadValues({}, this.$props), {
9929
9929
  percent: this.validPercent(this.percent)
9930
9930
  });
9931
- let progress2 = createVNode(Line, $props, _isSlot$2(progressInfo) ? progressInfo : {
9931
+ let progress2 = createVNode(Line, $props, _isSlot$3(progressInfo) ? progressInfo : {
9932
9932
  default: () => [progressInfo]
9933
9933
  });
9934
9934
  if (this.type === "circle" || this.type === "dashboard") {
9935
- progress2 = createVNode(Circle, $props, _isSlot$2(progressInfo) ? progressInfo : {
9935
+ progress2 = createVNode(Circle, $props, _isSlot$3(progressInfo) ? progressInfo : {
9936
9936
  default: () => [progressInfo]
9937
9937
  });
9938
9938
  }
@@ -11560,7 +11560,7 @@ var Component$a = defineComponent({
11560
11560
  }
11561
11561
  });
11562
11562
  const BkSelect = withInstallProps(Component$a, { Option: BkOption, Group: OptionGroup });
11563
- function _isSlot$1(s2) {
11563
+ function _isSlot$2(s2) {
11564
11564
  return typeof s2 === "function" || Object.prototype.toString.call(s2) === "[object Object]" && !isVNode(s2);
11565
11565
  }
11566
11566
  const {
@@ -11621,7 +11621,7 @@ var Component$9 = defineComponent({
11621
11621
  return createVNode(BkModal, mergeProps(this.$props, {
11622
11622
  "class": className,
11623
11623
  "style": `${this.direction}: 0`
11624
- }), _isSlot$1(dialogSlot) ? dialogSlot : {
11624
+ }), _isSlot$2(dialogSlot) ? dialogSlot : {
11625
11625
  default: () => [dialogSlot]
11626
11626
  });
11627
11627
  }
@@ -12163,7 +12163,7 @@ const tableProps = {
12163
12163
  pagination: PropTypes.oneOfType([PropTypes.bool.def(false), PropTypes.object.def({})]).def(false),
12164
12164
  remotePagination: PropTypes.bool.def(false)
12165
12165
  };
12166
- function _isSlot(s2) {
12166
+ function _isSlot$1(s2) {
12167
12167
  return typeof s2 === "function" || Object.prototype.toString.call(s2) === "[object Object]" && !isVNode(s2);
12168
12168
  }
12169
12169
  var useLimit = () => {
@@ -12208,7 +12208,7 @@ var useLimit = () => {
12208
12208
  "modelValue": localLimit.value,
12209
12209
  "onChange": handleLimitChange,
12210
12210
  "disabled": proxy.disabled
12211
- }, _isSlot(_slot = proxy.limitList.map((num, index) => createVNode(BkOption, {
12211
+ }, _isSlot$1(_slot = proxy.limitList.map((num, index) => createVNode(BkOption, {
12212
12212
  "value": num,
12213
12213
  "label": num,
12214
12214
  "key": `${index}_${num}`
@@ -12758,6 +12758,9 @@ const getRowText = (row, key, column) => {
12758
12758
  }
12759
12759
  return row[key];
12760
12760
  };
12761
+ function _isSlot(s2) {
12762
+ return typeof s2 === "function" || Object.prototype.toString.call(s2) === "[object Object]" && !isVNode(s2);
12763
+ }
12761
12764
  var HeadFilter = defineComponent({
12762
12765
  name: "HeadFilter",
12763
12766
  props: {
@@ -12796,23 +12799,11 @@ var HeadFilter = defineComponent({
12796
12799
  }
12797
12800
  }];
12798
12801
  const theme = `light ${resolveClassName("table-head-filter")}`;
12799
- const handleItemChecked = (value, item) => {
12800
- const isChecked = !!value;
12801
- if (isChecked) {
12802
- state.checked.push(item.value);
12803
- } else {
12804
- const index = state.checked.findIndex((val) => val === item.value);
12805
- if (index >= 0) {
12806
- state.checked.splice(index, 1);
12807
- }
12808
- }
12809
- };
12810
- let localData = reactive([]);
12811
- watchEffect(() => {
12802
+ const localData = computed(() => {
12812
12803
  const {
12813
12804
  list = []
12814
12805
  } = column.filter;
12815
- localData = list.map((item) => __spreadProps(__spreadValues({}, item), {
12806
+ return list.map((item) => __spreadProps(__spreadValues({}, item), {
12816
12807
  checked: state.checked.includes(item.value)
12817
12808
  }));
12818
12809
  });
@@ -12824,8 +12815,6 @@ var HeadFilter = defineComponent({
12824
12815
  const handleBtnResetClick = () => {
12825
12816
  if (state.checked.length) {
12826
12817
  state.checked.splice(0, state.checked.length);
12827
- emit("change", state.checked, filterFn);
12828
- isShow.value = false;
12829
12818
  }
12830
12819
  };
12831
12820
  return () => createVNode(BkPopover, mergeProps({
@@ -12846,27 +12835,34 @@ var HeadFilter = defineComponent({
12846
12835
  "class": headClass.value,
12847
12836
  "onClick": () => isShow.value = true
12848
12837
  }, null),
12849
- content: () => createVNode("div", {
12850
- "class": headFilterContentClass
12851
- }, [createVNode("div", {
12852
- "class": "content-list"
12853
- }, [localData.map((item) => createVNode("div", {
12854
- "class": "list-item"
12855
- }, [createVNode(BkCheckbox, {
12856
- "label": item.text,
12857
- "checked": item.checked,
12858
- "onChange": (val) => handleItemChecked(val, item)
12859
- }, null)]))]), createVNode("div", {
12860
- "class": "content-footer"
12861
- }, [createVNode("span", {
12862
- "class": "btn-filter-save",
12863
- "onClick": handleBtnSaveClick
12864
- }, [createTextVNode("\u786E\u5B9A")]), createVNode("span", {
12865
- "class": "btn-filter-split"
12866
- }, null), createVNode("span", {
12867
- "class": ["btn-filter-reset", state.checked.length ? "" : "disable"],
12868
- "onClick": handleBtnResetClick
12869
- }, [createTextVNode("\u91CD\u7F6E")])])])
12838
+ content: () => {
12839
+ let _slot;
12840
+ return createVNode("div", {
12841
+ "class": headFilterContentClass
12842
+ }, [createVNode(BkCheckboxGroup, {
12843
+ "class": "content-list",
12844
+ "modelValue": state.checked,
12845
+ "onUpdate:modelValue": ($event) => state.checked = $event
12846
+ }, _isSlot(_slot = localData.value.map((item) => createVNode("div", {
12847
+ "class": "list-item"
12848
+ }, [createVNode(BkCheckbox, {
12849
+ "label": item.value
12850
+ }, {
12851
+ default: () => [item.text]
12852
+ })]))) ? _slot : {
12853
+ default: () => [_slot]
12854
+ }), createVNode("div", {
12855
+ "class": "content-footer"
12856
+ }, [createVNode("span", {
12857
+ "class": "btn-filter-save",
12858
+ "onClick": handleBtnSaveClick
12859
+ }, [createTextVNode("\u786E\u5B9A")]), createVNode("span", {
12860
+ "class": "btn-filter-split"
12861
+ }, null), createVNode("span", {
12862
+ "class": ["btn-filter-reset", state.checked.length ? "" : "disable"],
12863
+ "onClick": handleBtnResetClick
12864
+ }, [createTextVNode("\u91CD\u7F6E")])])]);
12865
+ }
12870
12866
  });
12871
12867
  }
12872
12868
  });
@@ -20766,7 +20762,7 @@ var components = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProp
20766
20762
  ButtonGroup,
20767
20763
  Card: BkCard,
20768
20764
  Checkbox: BkCheckbox,
20769
- CheckboxGroup,
20765
+ CheckboxGroup: BkCheckboxGroup,
20770
20766
  Collapse: BkCollaspe,
20771
20767
  Dialog: BkDialog,
20772
20768
  Exception: BkException,
@@ -20825,4 +20821,4 @@ var preset = {
20825
20821
  install: createInstall(),
20826
20822
  version: "0.0.1"
20827
20823
  };
20828
- export { BkAlert as Alert, BkAnimateNumber as AnimateNumber, BkBacktop as Backtop, BkBadge as Badge, BkOption, OptionGroup as BkOptionGroup, BkBreadcrumb as Breadcrumb, BreadcrumbItem, BkButton as Button, ButtonGroup, BkCard as Card, BkCheckbox as Checkbox, CheckboxGroup, BkCollaspe as Collapse, BkDatePicker as DatePicker, BkDialog as Dialog, BkDivider as Divider, BkDropdown as Dropdown, DropdownItem, DropdownMenu, BkException as Exception, BkFixedNavbar as FixedNavbar, BkForm as Form, FormItem, BkInput as Input, BkLink as Link, BkLoading as Loading, BkMenu as Menu, Message, BkModal as Modal, Navigation, Notify, BkPagination as Pagination, BkPopover as Popover, BkProgress as Progress, BkRadio as Radio, RadioButton, RadioGroup, BkRate as Rate, BkSelect as Select, BkSideslider as Sideslider, BkSteps as Steps, BkSwiper as Swiper, BkSwitcher as Switcher, BkTab as Tab, TabPanel, BkTable as Table, BkTag as Tag, TagInput, Transfer, BkTree as Tree, BkVirtualRender as VirtualRender, tooltips as bkTooltips, ClickOutside as clickoutside, preset as default, mousewheel };
20824
+ export { BkAlert as Alert, BkAnimateNumber as AnimateNumber, BkBacktop as Backtop, BkBadge as Badge, BkOption, OptionGroup as BkOptionGroup, BkBreadcrumb as Breadcrumb, BreadcrumbItem, BkButton as Button, ButtonGroup, BkCard as Card, BkCheckbox as Checkbox, BkCheckboxGroup as CheckboxGroup, BkCollaspe as Collapse, BkDatePicker as DatePicker, BkDialog as Dialog, BkDivider as Divider, BkDropdown as Dropdown, DropdownItem, DropdownMenu, BkException as Exception, BkFixedNavbar as FixedNavbar, BkForm as Form, FormItem, BkInput as Input, BkLink as Link, BkLoading as Loading, BkMenu as Menu, Message, BkModal as Modal, Navigation, Notify, BkPagination as Pagination, BkPopover as Popover, BkProgress as Progress, BkRadio as Radio, RadioButton, RadioGroup, BkRate as Rate, BkSelect as Select, BkSideslider as Sideslider, BkSteps as Steps, BkSwiper as Swiper, BkSwitcher as Switcher, BkTab as Tab, TabPanel, BkTable as Table, BkTag as Tag, TagInput, Transfer, BkTree as Tree, BkVirtualRender as VirtualRender, tooltips as bkTooltips, ClickOutside as clickoutside, preset as default, mousewheel };