@weni/unnnic-system 3.1.0 → 3.1.1

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/CHANGELOG.md CHANGED
@@ -5,6 +5,13 @@ All notable changes to this project will be documented in this file.
5
5
  The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/),
6
6
  and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
7
7
 
8
+ ## 3.1.1 (2025-08-29)
9
+
10
+ ### Added
11
+
12
+ - **SelectSmart**: Added `multipleLimit` props to limit items selection
13
+ - **SelectSmart**: Added `disableRemove` option attribute to disable remove selected items
14
+
8
15
  ## 3.1.0 (2025-08-29)
9
16
 
10
17
  ### Added
@@ -64,6 +64,10 @@ declare const _default: import('vue').DefineComponent<import('vue').ExtractPropT
64
64
  type: BooleanConstructor;
65
65
  default: boolean;
66
66
  };
67
+ multipleLimit: {
68
+ type: (NumberConstructor | null)[];
69
+ default: null;
70
+ };
67
71
  }>, {}, {
68
72
  active: boolean;
69
73
  status: string;
@@ -173,6 +177,10 @@ declare const _default: import('vue').DefineComponent<import('vue').ExtractPropT
173
177
  type: BooleanConstructor;
174
178
  default: boolean;
175
179
  };
180
+ multipleLimit: {
181
+ type: (NumberConstructor | null)[];
182
+ default: null;
183
+ };
176
184
  }>> & Readonly<{
177
185
  "onUpdate:modelValue"?: ((...args: any[]) => any) | undefined;
178
186
  onOnChange?: ((...args: any[]) => any) | undefined;
@@ -193,6 +201,7 @@ declare const _default: import('vue').DefineComponent<import('vue').ExtractPropT
193
201
  selectFirst: boolean;
194
202
  isLoading: boolean;
195
203
  enableSearchByValue: boolean;
204
+ multipleLimit: number | null;
196
205
  }, {}, {
197
206
  TextInput: import('vue').DefineComponent<import('vue').ExtractPropTypes<{
198
207
  placeholder: {
@@ -498,6 +507,10 @@ declare const _default: import('vue').DefineComponent<import('vue').ExtractPropT
498
507
  type: BooleanConstructor;
499
508
  default: null;
500
509
  };
510
+ disabled: {
511
+ type: BooleanConstructor;
512
+ default: boolean;
513
+ };
501
514
  allowCheckbox: {
502
515
  type: BooleanConstructor;
503
516
  default: boolean;
@@ -537,6 +550,10 @@ declare const _default: import('vue').DefineComponent<import('vue').ExtractPropT
537
550
  type: BooleanConstructor;
538
551
  default: null;
539
552
  };
553
+ disabled: {
554
+ type: BooleanConstructor;
555
+ default: boolean;
556
+ };
540
557
  allowCheckbox: {
541
558
  type: BooleanConstructor;
542
559
  default: boolean;
@@ -550,6 +567,7 @@ declare const _default: import('vue').DefineComponent<import('vue').ExtractPropT
550
567
  }>> & Readonly<{}>, {
551
568
  label: string;
552
569
  size: string;
570
+ disabled: boolean;
553
571
  description: string;
554
572
  active: boolean;
555
573
  isMultiple: boolean;
@@ -1 +1 @@
1
- {"version":3,"file":"SelectSmart.vue.d.ts","sourceRoot":"","sources":["../../../src/components/SelectSmart/SelectSmart.vue"],"names":[],"mappings":"AA0GA;"}
1
+ {"version":3,"file":"SelectSmart.vue.d.ts","sourceRoot":"","sources":["../../../src/components/SelectSmart/SelectSmart.vue"],"names":[],"mappings":"AA2GA;"}
@@ -26,6 +26,10 @@ declare const _default: import('vue').DefineComponent<import('vue').ExtractPropT
26
26
  type: BooleanConstructor;
27
27
  default: null;
28
28
  };
29
+ disabled: {
30
+ type: BooleanConstructor;
31
+ default: boolean;
32
+ };
29
33
  allowCheckbox: {
30
34
  type: BooleanConstructor;
31
35
  default: boolean;
@@ -65,6 +69,10 @@ declare const _default: import('vue').DefineComponent<import('vue').ExtractPropT
65
69
  type: BooleanConstructor;
66
70
  default: null;
67
71
  };
72
+ disabled: {
73
+ type: BooleanConstructor;
74
+ default: boolean;
75
+ };
68
76
  allowCheckbox: {
69
77
  type: BooleanConstructor;
70
78
  default: boolean;
@@ -78,6 +86,7 @@ declare const _default: import('vue').DefineComponent<import('vue').ExtractPropT
78
86
  }>> & Readonly<{}>, {
79
87
  label: string;
80
88
  size: string;
89
+ disabled: boolean;
81
90
  description: string;
82
91
  active: boolean;
83
92
  isMultiple: boolean;
@@ -1 +1 @@
1
- {"version":3,"file":"SelectSmartOption.vue.d.ts","sourceRoot":"","sources":["../../../src/components/SelectSmart/SelectSmartOption.vue"],"names":[],"mappings":"AA4CA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8BAgL8B,sBAAsB"}
1
+ {"version":3,"file":"SelectSmartOption.vue.d.ts","sourceRoot":"","sources":["../../../src/components/SelectSmart/SelectSmartOption.vue"],"names":[],"mappings":"AA6CA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8BAqL8B,sBAAsB"}
@@ -1,4 +1,4 @@
1
- import { h as n } from "./index-a9c4dc3e.mjs";
1
+ import { h as n } from "./index-d6c4fffb.mjs";
2
2
  import "vue";
3
3
  //! moment.js locale configuration
4
4
  //! locale : Spanish [es]
@@ -20679,6 +20679,10 @@ const yU = {
20679
20679
  type: Boolean,
20680
20680
  default: null
20681
20681
  },
20682
+ disabled: {
20683
+ type: Boolean,
20684
+ default: !1
20685
+ },
20682
20686
  allowCheckbox: {
20683
20687
  type: Boolean,
20684
20688
  default: !1
@@ -20716,8 +20720,9 @@ function wU(e, n, i, a, o, r) {
20716
20720
  ref: "checkbox",
20717
20721
  "data-testid": "checkbox",
20718
20722
  modelValue: i.active,
20719
- size: i.size
20720
- }, null, 8, ["modelValue", "size"])) : N("", !0),
20723
+ size: i.size,
20724
+ disabled: i.disabled
20725
+ }, null, 8, ["modelValue", "size", "disabled"])) : N("", !0),
20721
20726
  u("div", null, [
20722
20727
  u("span", {
20723
20728
  class: B([
@@ -20800,16 +20805,16 @@ function AU(e, n, i, a, o, r) {
20800
20805
  key: f.value,
20801
20806
  class: "unnnic-select-smart__options__multiple__selecteds__option",
20802
20807
  text: f.label,
20803
- hasCloseIcon: "",
20808
+ hasCloseIcon: !f.disableRemove,
20804
20809
  onClose: (m) => r.unselectOption(f)
20805
- }, null, 8, ["text", "onClose"]))), 128)),
20810
+ }, null, 8, ["text", "hasCloseIcon", "onClose"]))), 128)),
20806
20811
  i.selectedOptions.length > o.multipleSelectedsTags ? (c(), p("p", MU, " +" + T(i.selectedOptions.length - o.multipleSelectedsTags), 1)) : N("", !0)
20807
20812
  ])
20808
20813
  ])) : N("", !0),
20809
20814
  i.selectedOptions[0] ? N("", !0) : (c(), p("p", DU, T(i.withoutSelectsMessage || e.i18n("without_multiple_selected")), 1))
20810
20815
  ]);
20811
20816
  }
20812
- const LU = /* @__PURE__ */ k(CU, [["render", AU], ["__scopeId", "data-v-bcf6f5c9"]]);
20817
+ const LU = /* @__PURE__ */ k(CU, [["render", AU], ["__scopeId", "data-v-44c8e22c"]]);
20813
20818
  const TU = {
20814
20819
  props: {
20815
20820
  type: {
@@ -20916,6 +20921,10 @@ const NU = {
20916
20921
  {
20917
20922
  value: "option1",
20918
20923
  label: "Option1"
20924
+ },
20925
+ {
20926
+ value: "option2",
20927
+ label: "Option2"
20919
20928
  }
20920
20929
  ]
20921
20930
  },
@@ -20977,6 +20986,10 @@ const NU = {
20977
20986
  enableSearchByValue: {
20978
20987
  type: Boolean,
20979
20988
  default: !1
20989
+ },
20990
+ multipleLimit: {
20991
+ type: [Number, null],
20992
+ default: null
20980
20993
  }
20981
20994
  },
20982
20995
  emits: ["update:searchValue", "onChange", "update:modelValue"],
@@ -21062,10 +21075,12 @@ const NU = {
21062
21075
  },
21063
21076
  handleSelect(e) {
21064
21077
  if (e) {
21065
- if (this.multiple && this.optionIsSelected(e)) {
21078
+ if (this.multiple && this.optionIsSelected(e) && !e.disableRemove) {
21066
21079
  this.unselectOption(e);
21067
21080
  return;
21068
21081
  }
21082
+ if (this.multiple && e.disableRemove && this.optionIsSelected(e) || this.multipleLimit && this.modelValue.length >= this.multipleLimit)
21083
+ return;
21069
21084
  this.selectOption(e);
21070
21085
  }
21071
21086
  },
@@ -21228,11 +21243,12 @@ function IU(e, n, i, a, o, r) {
21228
21243
  tabindex: E,
21229
21244
  size: i.size,
21230
21245
  active: M.value === i.modelValue || r.optionIsSelected(M),
21246
+ disabled: r.optionIsSelected(M) && M.disableRemove,
21231
21247
  focused: o.focusedOption && o.focusedOption.value === M.value,
21232
21248
  allowCheckbox: !!i.multiple,
21233
21249
  activeColor: i.type === "secondary" ? "secondary" : "primary",
21234
21250
  onClick: (O) => r.handleSelect(M)
21235
- }, null, 8, ["label", "description", "tabindex", "size", "active", "focused", "allowCheckbox", "activeColor", "onClick"]))), 128)),
21251
+ }, null, 8, ["label", "description", "tabindex", "size", "active", "disabled", "focused", "allowCheckbox", "activeColor", "onClick"]))), 128)),
21236
21252
  r.filterOptions(i.options).length === 0 && !i.isLoading ? (c(), p("p", zU, T(e.i18n("without_results")), 1)) : N("", !0)
21237
21253
  ], 2)
21238
21254
  ])
@@ -24223,8 +24239,8 @@ function LW(e, n, i, a, o, r) {
24223
24239
  });
24224
24240
  }
24225
24241
  const TW = /* @__PURE__ */ k(AW, [["render", LW], ["__scopeId", "data-v-9b793da0"]]);
24226
- import("./es-8ee8b336.mjs");
24227
- import("./pt-br-1b500883.mjs");
24242
+ import("./es-b95265ef.mjs");
24243
+ import("./pt-br-80b6b07a.mjs");
24228
24244
  const Qo = {
24229
24245
  name: "ChatsContact",
24230
24246
  components: {
@@ -1,4 +1,4 @@
1
- import { h as e } from "./index-a9c4dc3e.mjs";
1
+ import { h as e } from "./index-d6c4fffb.mjs";
2
2
  import "vue";
3
3
  //! moment.js locale configuration
4
4
  //! locale : Portuguese (Brazil) [pt-br]