@agrotools1/at-components 0.5.0-5 → 0.5.0-7

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.
Files changed (40) hide show
  1. package/dist/Checkbox/Checkbox.vue.js +1 -1
  2. package/dist/Dropdown/Checklist/Dropdown.Checklist.d.ts +2 -0
  3. package/dist/Dropdown/Dropdown.core.d.ts +22 -3
  4. package/dist/Dropdown/Dropdown.core.vue.js +23 -20
  5. package/dist/Dropdown/Dropdown.core.vue2.js +62 -26
  6. package/dist/Dropdown/Dropdown.core.vue3.js +2 -2
  7. package/dist/Dropdown/Dropdown.types.d.ts +2 -0
  8. package/dist/Filter/components/Filter.types.d.ts +2 -0
  9. package/dist/Filter/components/Filter.vue.js +64 -62
  10. package/dist/Filter/components/Filter.vue2.js +57 -52
  11. package/dist/Input/Input.core.d.ts +9 -0
  12. package/dist/Input/Input.core.vue.js +25 -19
  13. package/dist/Input/Input.core.vue2.js +9 -5
  14. package/dist/Input/index.d.ts +9 -0
  15. package/dist/List/components/List.d.ts +18 -0
  16. package/dist/List/components/List.types.d.ts +2 -0
  17. package/dist/List/components/List.vue.js +33 -30
  18. package/dist/List/components/List.vue2.js +20 -12
  19. package/dist/Search/Search.d.ts +15 -7
  20. package/dist/Search/Search.vue.js +36 -25
  21. package/dist/Search/Search.vue2.js +21 -17
  22. package/dist/Select/Multiple/Select.multiple.d.ts +11 -0
  23. package/dist/Select/Multiple/Select.multiple.vue.js +10 -9
  24. package/dist/Select/Multiple/Select.multiple.vue2.js +7 -2
  25. package/dist/Select/Select.core.d.ts +11 -0
  26. package/dist/Select/Select.core.vue.js +8 -7
  27. package/dist/Select/Select.core.vue2.js +8 -3
  28. package/dist/Select/Single/Select.single.d.ts +11 -0
  29. package/dist/Select/Single/Select.single.vue.js +13 -12
  30. package/dist/Select/Single/Select.single.vue2.js +14 -9
  31. package/dist/Select/index.d.ts +22 -0
  32. package/dist/Stepper/Stepper.vue.js +10 -10
  33. package/dist/TableConfig/TableConfig.d.ts +9 -0
  34. package/dist/TableConfig/TableConfig.vue.js +7 -6
  35. package/dist/TableConfig/TableConfig.vue2.js +10 -6
  36. package/dist/Tabs/Tabs.d.ts +13 -0
  37. package/dist/Tabs/Tabs.vue.js +21 -17
  38. package/dist/Tabs/Tabs.vue2.js +31 -22
  39. package/dist/style.css +1 -1
  40. package/package.json +1 -1
@@ -1,21 +1,21 @@
1
- import { defineComponent as O, ref as n, computed as P, toRaw as V } from "vue";
1
+ import { defineComponent as P, ref as n, computed as V, toRaw as q } from "vue";
2
2
  import { AtCloseSolidIcon as T } from "../../node_modules/.pnpm/agrotools-icons@0.2.6/node_modules/agrotools-icons/dist/AtCloseSolidIcon/index.js";
3
- import { AtFilterSolidIcon as q } from "../../node_modules/.pnpm/agrotools-icons@0.2.6/node_modules/agrotools-icons/dist/AtFilterSolidIcon/index.js";
4
- import B from "../../Button/Button.vue.js";
5
- import E from "../../Checkbox/Checkbox.vue.js";
6
- import M from "../../Dropdown/Dropdown.core.vue.js";
7
- import { AtTipograph as R } from "../../Tipograph/index.js";
8
- const _ = {
3
+ import { AtFilterSolidIcon as B } from "../../node_modules/.pnpm/agrotools-icons@0.2.6/node_modules/agrotools-icons/dist/AtFilterSolidIcon/index.js";
4
+ import E from "../../Button/Button.vue.js";
5
+ import M from "../../Checkbox/Checkbox.vue.js";
6
+ import R from "../../Dropdown/Dropdown.core.vue.js";
7
+ import { AtTipograph as _ } from "../../Tipograph/index.js";
8
+ const $ = {
9
9
  AtCloseSolidIcon: T,
10
- AtFilterSolidIcon: q
11
- }, Q = O({
10
+ AtFilterSolidIcon: B
11
+ }, U = P({
12
12
  name: "AtFilter",
13
13
  components: {
14
- AtDropDown: M,
15
- AtParagraph: R.Paragraph,
16
- AtButton: B,
17
- AtCheckbox: E,
18
- ..._
14
+ AtDropDown: R,
15
+ AtParagraph: _.Paragraph,
16
+ AtButton: E,
17
+ AtCheckbox: M,
18
+ ...$
19
19
  },
20
20
  props: {
21
21
  dropDownList: {
@@ -25,74 +25,79 @@ const _ = {
25
25
  options: {
26
26
  type: Object,
27
27
  required: !1
28
+ },
29
+ id: {
30
+ type: String,
31
+ required: !1
28
32
  }
29
33
  },
30
34
  emits: ["update:isOpen", "onSave"],
31
- setup(c, { emit: x }) {
35
+ setup(i, { emit: k, attrs: d }) {
32
36
  const C = (e) => {
33
37
  if (typeof e.text == "string")
34
38
  return e.text;
35
- }, i = n(!1), w = () => {
36
- i.value = !i.value;
37
- }, D = P(() => i.value || u.value > 0 ? "primary" : "secondary"), d = n(!1), p = n([]), h = () => {
38
- p.value = c.dropDownList.map(
39
- (e) => structuredClone(V(e))
39
+ }, c = n(!1), w = () => {
40
+ c.value = !c.value;
41
+ }, D = V(() => c.value || u.value > 0 ? "primary" : "secondary"), h = n(!1), p = n([]), g = () => {
42
+ p.value = i.dropDownList.map(
43
+ (e) => structuredClone(q(e))
40
44
  );
41
45
  };
42
- h();
43
- const r = n(), l = n(), A = () => {
44
- r.value = [], l.value = [], p.value.some((e) => "key" in e) ? r.value = p.value : l.value = p.value;
46
+ g();
47
+ const a = n(), l = n(), A = () => {
48
+ a.value = [], l.value = [], p.value.some((e) => "key" in e) ? a.value = p.value : l.value = p.value;
45
49
  };
46
50
  A();
47
- const g = (e) => {
51
+ const x = (e) => {
48
52
  var t, o;
49
- (t = r.value) == null || t.map(
50
- (s) => s.value.map((a) => a.value = e)
51
- ), (o = l.value) == null || o.map((s) => s.value = e);
52
- }, v = () => i.value = !1, L = (e = !0) => {
53
- d.value = !1, g(!1), k(), y(), e && setTimeout(v, 1);
53
+ (t = a.value) == null || t.map(
54
+ (r) => r.value.map((s) => s.value = e)
55
+ ), (o = l.value) == null || o.map((r) => r.value = e);
56
+ }, v = () => c.value = !1, L = (e = !0) => {
57
+ h.value = !1, x(!1), I(), y(), e && setTimeout(v, 1);
54
58
  }, S = () => {
55
- var o, s;
56
- const e = (o = r.value) == null ? void 0 : o.reduce(
57
- (a, { key: b, value: m }) => {
58
- const F = m == null ? void 0 : m.filter((f) => f.value).map((f) => f.text);
59
- return a[b] = F, a;
59
+ var o, r;
60
+ const e = (o = a.value) == null ? void 0 : o.reduce(
61
+ (s, { key: F, value: f }) => {
62
+ const O = f == null ? void 0 : f.filter((m) => m.value).map((m) => m.text);
63
+ return s[F] = O, s;
60
64
  },
61
65
  {}
62
- ), t = (s = l.value) == null ? void 0 : s.filter((a) => a.value).map((a) => a.text);
66
+ ), t = (r = l.value) == null ? void 0 : r.filter((s) => s.value).map((s) => s.text);
63
67
  return t != null && t.length ? t : e;
64
68
  }, y = () => {
65
69
  var t, o;
66
70
  const e = (t = l.value) != null && t.length ? l.value : (
67
71
  // .filter((item) => item.value)
68
- r.value
72
+ a.value
69
73
  );
70
- k(), v(), x(
74
+ I(), v(), k(
71
75
  "onSave",
72
- (o = c.options) != null && o.returnOnlyChecked && (e != null && e.length) ? S() : e
76
+ (o = i.options) != null && o.returnOnlyChecked && (e != null && e.length) ? S() : e
73
77
  );
74
- }, u = n(0), k = () => {
78
+ }, u = n(0), I = () => {
75
79
  var e, t;
76
- u.value = 0, u.value += ((e = l.value) == null ? void 0 : e.filter((o) => o.value).length) ?? 0, (t = r.value) == null || t.forEach(
80
+ u.value = 0, u.value += ((e = l.value) == null ? void 0 : e.filter((o) => o.value).length) ?? 0, (t = a.value) == null || t.forEach(
77
81
  (o) => o.value.forEach(
78
- (s) => s.value ? u.value++ : u
82
+ (r) => r.value ? u.value++ : u
79
83
  )
80
84
  );
81
- }, I = n(0);
85
+ }, b = n(0);
82
86
  return {
83
- props: c,
87
+ props: i,
84
88
  list: p,
85
- listSeparator: r,
89
+ listSeparator: a,
86
90
  listArray: l,
87
- checkAllModel: d,
88
- isOpen: i,
91
+ checkAllModel: h,
92
+ isOpen: c,
89
93
  getButtonColor: D,
90
94
  count: u,
91
- keyValue: I,
92
- resetList: h,
95
+ keyValue: b,
96
+ getItemId: (e) => d.id ? `${d.id}-${e.text}` : e.text,
97
+ resetList: g,
93
98
  setListProps: A,
94
99
  toggleDropdown: w,
95
- setAllCheckboxValues: g,
100
+ setAllCheckboxValues: x,
96
101
  clear: L,
97
102
  getItemText: C,
98
103
  closeDialog: v,
@@ -100,8 +105,8 @@ const _ = {
100
105
  };
101
106
  },
102
107
  watch: {
103
- checkAllModel(c) {
104
- this.setAllCheckboxValues(c);
108
+ checkAllModel(i) {
109
+ this.setAllCheckboxValues(i);
105
110
  },
106
111
  dropDownList() {
107
112
  this.resetList(), this.clear(!1), this.setListProps(), this.keyValue++;
@@ -109,5 +114,5 @@ const _ = {
109
114
  }
110
115
  });
111
116
  export {
112
- Q as default
117
+ U as default
113
118
  };
@@ -54,6 +54,10 @@ declare const _default: import("vue").DefineComponent<{
54
54
  type: BooleanConstructor;
55
55
  default: boolean;
56
56
  };
57
+ required: {
58
+ type: BooleanConstructor;
59
+ default: boolean;
60
+ };
57
61
  readonly: {
58
62
  type: BooleanConstructor;
59
63
  default: boolean;
@@ -4686,6 +4690,10 @@ declare const _default: import("vue").DefineComponent<{
4686
4690
  type: BooleanConstructor;
4687
4691
  default: boolean;
4688
4692
  };
4693
+ required: {
4694
+ type: BooleanConstructor;
4695
+ default: boolean;
4696
+ };
4689
4697
  readonly: {
4690
4698
  type: BooleanConstructor;
4691
4699
  default: boolean;
@@ -4742,6 +4750,7 @@ declare const _default: import("vue").DefineComponent<{
4742
4750
  onClearInput?: ((...args: any[]) => any) | undefined;
4743
4751
  }, {
4744
4752
  type: string;
4753
+ required: boolean;
4745
4754
  label: string;
4746
4755
  error: {
4747
4756
  value: boolean;
@@ -1,16 +1,19 @@
1
- import p from "./Input.core.vue2.js";
2
- import { resolveComponent as m, openBlock as n, createElementBlock as l, createElementVNode as r, toDisplayString as i, Fragment as I, renderList as v, createCommentVNode as d, mergeProps as C, normalizeClass as k, createBlock as u, resolveDynamicComponent as y, createTextVNode as T } from "vue";
1
+ import m from "./Input.core.vue2.js";
2
+ import { resolveComponent as I, openBlock as n, createElementBlock as l, createElementVNode as r, createTextVNode as u, toDisplayString as i, createCommentVNode as d, Fragment as v, renderList as k, mergeProps as C, normalizeClass as T, createBlock as a, resolveDynamicComponent as y } from "vue";
3
3
  import "./Input.core.vue3.js";
4
4
  import f from "../_virtual/_plugin-vue_export-helper.js";
5
- const h = ["data-mode", "disabled"], F = ["for"], O = ["title"], $ = { class: "AT-INPUT_item_slot" }, b = ["onClick"], A = {
5
+ const h = ["data-mode", "disabled"], b = ["for"], $ = {
6
+ key: 0,
7
+ class: "AT-INPUT_required"
8
+ }, A = ["title"], F = { class: "AT-INPUT_item_slot" }, N = ["onClick"], O = {
6
9
  key: 0,
7
10
  class: "AT-INPUT_items_length"
8
- }, N = ["id", "disabled", "readonly", "type", "placeholder", "name", "value"], g = {
11
+ }, g = ["id", "disabled", "readonly", "type", "placeholder", "name", "value"], P = {
9
12
  key: 0,
10
13
  class: "AT-INPUT_error-message"
11
14
  }, M = ["src"];
12
- function P(e, s, U, B, E, z) {
13
- const a = m("AtCircleXMarkSolidIcon");
15
+ function U(e, s, c, B, E, z) {
16
+ const p = I("AtCircleXMarkSolidIcon");
14
17
  return n(), l("div", null, [
15
18
  r("div", {
16
19
  ref: "wrapperEl",
@@ -23,21 +26,24 @@ function P(e, s, U, B, E, z) {
23
26
  r("label", {
24
27
  for: e.id,
25
28
  onClick: s[0] || (s[0] = (...o) => e.handleOnFocus && e.handleOnFocus(...o))
26
- }, i(e.label), 9, F),
29
+ }, [
30
+ u(i(e.label) + " ", 1),
31
+ e.$props.required ? (n(), l("span", $, "*")) : d("", !0)
32
+ ], 8, b),
27
33
  e.separator ? (n(), l("div", {
28
34
  key: 0,
29
35
  ref: "containerItemsEl",
30
36
  class: "AT-INPUT_items",
31
37
  onClick: s[1] || (s[1] = (...o) => e.handleOnFocus && e.handleOnFocus(...o))
32
38
  }, [
33
- (n(!0), l(I, null, v(e.selectedItemsController.itemsToRender, (o) => (n(), l("span", {
39
+ (n(!0), l(v, null, k(e.selectedItemsController.itemsToRender, (o) => (n(), l("span", {
34
40
  key: o.value,
35
41
  ref_for: !0,
36
42
  ref: "selectedItemsEl",
37
43
  title: o.text,
38
44
  class: "AT-INPUT_item"
39
45
  }, [
40
- r("span", $, i(o.text), 1),
46
+ r("span", F, i(o.text), 1),
41
47
  r("span", {
42
48
  class: "AT-INPUT_item_slot_x",
43
49
  style: { padding: "1px 5px" },
@@ -45,9 +51,9 @@ function P(e, s, U, B, E, z) {
45
51
  var t;
46
52
  (t = e.onSelectedItemClick) == null || t.call(e, o == null ? void 0 : o.value);
47
53
  }
48
- }, "x", 8, b)
49
- ], 8, O))), 128)),
50
- e.selectedItems.length > e.selectedItemsController.supportedItems ? (n(), l("span", A, "+ " + i(e.selectedItems.length - e.selectedItemsController.supportedItems), 1)) : d("", !0)
54
+ }, "x", 8, N)
55
+ ], 8, A))), 128)),
56
+ e.selectedItems.length > e.selectedItemsController.supportedItems ? (n(), l("span", O, "+ " + i(e.selectedItems.length - e.selectedItemsController.supportedItems), 1)) : d("", !0)
51
57
  ], 512)) : (n(), l("input", C({ key: 1 }, e.$attrs, {
52
58
  id: e.id,
53
59
  ref: "inputEl",
@@ -61,32 +67,32 @@ function P(e, s, U, B, E, z) {
61
67
  onInput: s[2] || (s[2] = (...o) => e.onInput && e.onInput(...o)),
62
68
  onFocus: s[3] || (s[3] = (...o) => e.handleOnFocus && e.handleOnFocus(...o)),
63
69
  onFocusout: s[4] || (s[4] = (...o) => e.handleOnFocusOut && e.handleOnFocusOut(...o))
64
- }), null, 16, N)),
70
+ }), null, 16, g)),
65
71
  e.$props.icon ? (n(), l("div", {
66
72
  key: 2,
67
- class: k(["AT_INPUT_icon_slot", { clickable: e.useClearButton && e.isFocused }]),
73
+ class: T(["AT_INPUT_icon_slot", { clickable: e.useClearButton && e.isFocused }]),
68
74
  onClick: s[5] || (s[5] = (o) => e.showClearButton ? e.clearInput() : null)
69
75
  }, [
70
- e.showClearButton ? (n(), u(a, {
76
+ e.showClearButton ? (n(), a(p, {
71
77
  key: 0,
72
78
  size: "20"
73
- })) : (n(), u(y(e.icons[e.$props.icon.name]), {
79
+ })) : (n(), a(y(e.icons[e.$props.icon.name]), {
74
80
  key: 1,
75
81
  size: e.$props.icon.size || "20",
76
82
  color: e.iconColor
77
83
  }, null, 8, ["size", "color"]))
78
84
  ], 2)) : d("", !0)
79
85
  ], 40, h),
80
- e.error.value ? (n(), l("span", g, [
86
+ e.error.value ? (n(), l("span", P, [
81
87
  r("img", {
82
88
  src: e.icons.error,
83
89
  alt: "error icon"
84
90
  }, null, 8, M),
85
- T(" " + i(e.error.message), 1)
91
+ u(" " + i(e.error.message), 1)
86
92
  ])) : d("", !0)
87
93
  ]);
88
94
  }
89
- const D = /* @__PURE__ */ f(p, [["render", P], ["__scopeId", "data-v-0bd09748"]]);
95
+ const D = /* @__PURE__ */ f(m, [["render", U], ["__scopeId", "data-v-bc1b9b88"]]);
90
96
  export {
91
97
  D as default
92
98
  };
@@ -37,6 +37,10 @@ const Y = j({
37
37
  type: Boolean,
38
38
  default: !1
39
39
  },
40
+ required: {
41
+ type: Boolean,
42
+ default: !1
43
+ },
40
44
  readonly: {
41
45
  type: Boolean,
42
46
  default: !1
@@ -100,9 +104,9 @@ const Y = j({
100
104
  supportedItems: e.selectedItems.length,
101
105
  isCounterActive: !1,
102
106
  itemsToRender: e.selectedItems
103
- }), F = Math.random().toString(36).substring(2), o = a(!1), M = () => {
107
+ }), q = Math.random().toString(36).substring(2), o = a(!1), F = () => {
104
108
  o.value = !0;
105
- }, q = () => {
109
+ }, M = () => {
106
110
  o.value = !1;
107
111
  }, g = () => {
108
112
  u.value = !0;
@@ -182,7 +186,7 @@ const Y = j({
182
186
  wrapperEl: b,
183
187
  inputEl: V,
184
188
  inputError: A,
185
- inputId: e.id ?? F,
189
+ inputId: e.id ?? q,
186
190
  handleOnFocus: g,
187
191
  handleOnFocusOut: m,
188
192
  icons: {
@@ -196,8 +200,8 @@ const Y = j({
196
200
  onInput: L,
197
201
  iconColor: x,
198
202
  isFocused: u,
199
- handleMouseOver: M,
200
- handleMouseLeave: q,
203
+ handleMouseOver: F,
204
+ handleMouseLeave: M,
201
205
  isHovered: o,
202
206
  inputComputedValue: W,
203
207
  currentMode: R,
@@ -35,6 +35,10 @@ export declare const AtInput: {
35
35
  type: BooleanConstructor;
36
36
  default: boolean;
37
37
  };
38
+ required: {
39
+ type: BooleanConstructor;
40
+ default: boolean;
41
+ };
38
42
  readonly: {
39
43
  type: BooleanConstructor;
40
44
  default: boolean;
@@ -4673,6 +4677,10 @@ export declare const AtInput: {
4673
4677
  type: BooleanConstructor;
4674
4678
  default: boolean;
4675
4679
  };
4680
+ required: {
4681
+ type: BooleanConstructor;
4682
+ default: boolean;
4683
+ };
4676
4684
  readonly: {
4677
4685
  type: BooleanConstructor;
4678
4686
  default: boolean;
@@ -4735,6 +4743,7 @@ export declare const AtInput: {
4735
4743
  onClearInput?: ((...args: any[]) => any) | undefined;
4736
4744
  }, {
4737
4745
  type: string;
4746
+ required: boolean;
4738
4747
  label: string;
4739
4748
  error: {
4740
4749
  value: boolean;
@@ -27,6 +27,14 @@ declare const _default: import("vue").DefineComponent<{
27
27
  type: ObjectConstructor;
28
28
  default: () => void;
29
29
  };
30
+ fullSize: {
31
+ type: PropType<boolean | undefined>;
32
+ default: boolean;
33
+ };
34
+ id: {
35
+ type: PropType<string | undefined>;
36
+ default: string;
37
+ };
30
38
  }, {
31
39
  listItems: import("vue").Ref<{
32
40
  value: boolean | string[];
@@ -77,13 +85,23 @@ declare const _default: import("vue").DefineComponent<{
77
85
  type: ObjectConstructor;
78
86
  default: () => void;
79
87
  };
88
+ fullSize: {
89
+ type: PropType<boolean | undefined>;
90
+ default: boolean;
91
+ };
92
+ id: {
93
+ type: PropType<string | undefined>;
94
+ default: string;
95
+ };
80
96
  }>> & {
81
97
  "onUpdate:isOpen"?: ((...args: any[]) => any) | undefined;
82
98
  onOnSave?: ((...args: any[]) => any) | undefined;
83
99
  onItemClicked?: ((...args: any[]) => any) | undefined;
84
100
  }, {
85
101
  isOpen: boolean;
102
+ id: string | undefined;
86
103
  position: "left" | "right" | undefined;
104
+ fullSize: boolean | undefined;
87
105
  trigger: Record<string, any>;
88
106
  dropDownList: DropdownListItem[];
89
107
  isMultiple: boolean | undefined;
@@ -9,4 +9,6 @@ export interface AtDpListProps {
9
9
  isMultiple?: boolean;
10
10
  position?: "left" | "right";
11
11
  showNoResultMessage: boolean;
12
+ fullSize?: boolean;
13
+ id?: string;
12
14
  }
@@ -1,81 +1,84 @@
1
1
  import h from "./List.vue2.js";
2
- import { resolveComponent as i, openBlock as t, createBlock as n, withCtx as s, resolveDynamicComponent as a, createElementBlock as l, createVNode as d, createTextVNode as u, createCommentVNode as r, Fragment as k, renderList as y, normalizeStyle as m, createElementVNode as C, toDisplayString as _ } from "vue";
2
+ import { resolveComponent as r, openBlock as t, createBlock as n, withCtx as l, renderSlot as k, resolveDynamicComponent as a, createElementBlock as s, createVNode as p, createTextVNode as u, createCommentVNode as i, Fragment as y, renderList as C, normalizeStyle as f, createElementVNode as v, toDisplayString as z } from "vue";
3
3
  import "./List.vue3.js";
4
4
  import V from "../../_virtual/_plugin-vue_export-helper.js";
5
- const v = {
5
+ const I = {
6
6
  key: 0,
7
7
  class: "noResult"
8
- }, I = ["onClick"], A = ["for"];
9
- function N(e, z, b, D, L, R) {
10
- const c = i("AtParagraph"), f = i("AtCheckbox"), g = i("AtDropdown");
8
+ }, A = ["onClick"], N = ["for"];
9
+ function _(e, $, b, D, L, R) {
10
+ const c = r("AtParagraph"), m = r("AtCheckbox"), g = r("AtDropdown");
11
11
  return t(), n(g, {
12
+ id: e.id,
12
13
  "is-open": e.isOpen,
13
14
  position: e.position,
15
+ "full-size": e.fullSize,
14
16
  "onUpdate:isOpen": e.handleIsOpen
15
17
  }, {
16
- trigger: s(() => [
18
+ trigger: l(() => [
19
+ k(e.$slots, "default", {}, void 0, !0),
17
20
  (t(), n(a(e.trigger)))
18
21
  ]),
19
- default: s(() => [
20
- (t(), l("div", {
22
+ default: l(() => [
23
+ (t(), s("div", {
21
24
  key: e.keyValue,
22
25
  class: "list"
23
26
  }, [
24
- e.showNoResult ? (t(), l("section", v, [
25
- d(c, { size: "p2" }, {
26
- default: s(() => [
27
+ e.showNoResult ? (t(), s("section", I, [
28
+ p(c, { size: "p2" }, {
29
+ default: l(() => [
27
30
  u(" Dado não encontrado ")
28
31
  ]),
29
32
  _: 1
30
33
  })
31
- ])) : r("", !0),
32
- (t(!0), l(k, null, y(e.listItems, (o) => (t(), l("div", {
34
+ ])) : i("", !0),
35
+ (t(!0), s(y, null, C(e.listItems, (o) => (t(), s("div", {
33
36
  key: o.text,
34
37
  class: "item",
35
- onClick: (p) => e.selectItem(o)
38
+ onClick: (d) => e.selectItem(o)
36
39
  }, [
37
- e.isMultiple ? (t(), n(f, {
40
+ e.isMultiple ? (t(), n(m, {
38
41
  key: 0,
39
42
  id: o.text,
40
43
  modelValue: o.value,
41
- "onUpdate:modelValue": (p) => o.value = p,
44
+ "onUpdate:modelValue": (d) => o.value = d,
42
45
  class: "item-check",
43
46
  size: "12"
44
- }, null, 8, ["id", "modelValue", "onUpdate:modelValue"])) : r("", !0),
47
+ }, null, 8, ["id", "modelValue", "onUpdate:modelValue"])) : i("", !0),
45
48
  o.iconLeft ? (t(), n(a(e.icons[e.getIconName(o.iconLeft)]), {
46
49
  key: 1,
47
50
  size: "16",
48
51
  class: "icon-left",
49
- style: m({ color: e.getIconColor(o.iconLeft) })
50
- }, null, 8, ["style"])) : r("", !0),
51
- C("label", {
52
+ style: f({ color: e.getIconColor(o.iconLeft) })
53
+ }, null, 8, ["style"])) : i("", !0),
54
+ v("label", {
52
55
  for: o.text,
53
56
  class: "item-label"
54
57
  }, [
55
- d(c, { size: "p2" }, {
56
- default: s(() => [
57
- u(_(o.text), 1)
58
+ p(c, { size: "p2" }, {
59
+ default: l(() => [
60
+ u(z(o.text), 1)
58
61
  ]),
59
62
  _: 2
60
63
  }, 1024)
61
- ], 8, A),
64
+ ], 8, N),
62
65
  o.iconRight ? (t(), n(a(e.icons[e.getIconName(o.iconRight)]), {
63
66
  key: 2,
64
67
  class: "icon-right",
65
- style: m({
68
+ style: f({
66
69
  color: e.getIconColor(o.iconRight),
67
70
  position: "abosulte",
68
71
  right: "16px"
69
72
  }),
70
73
  size: "16"
71
- }, null, 8, ["style"])) : r("", !0)
72
- ], 8, I))), 128))
74
+ }, null, 8, ["style"])) : i("", !0)
75
+ ], 8, A))), 128))
73
76
  ]))
74
77
  ]),
75
- _: 1
76
- }, 8, ["is-open", "position", "onUpdate:isOpen"]);
78
+ _: 3
79
+ }, 8, ["id", "is-open", "position", "full-size", "onUpdate:isOpen"]);
77
80
  }
78
- const B = /* @__PURE__ */ V(h, [["render", N], ["__scopeId", "data-v-01658f6d"]]);
81
+ const B = /* @__PURE__ */ V(h, [["render", _], ["__scopeId", "data-v-f2acaa9c"]]);
79
82
  export {
80
83
  B as default
81
84
  };
@@ -1,11 +1,11 @@
1
1
  import * as g from "../../node_modules/.pnpm/agrotools-icons@0.2.6/node_modules/agrotools-icons/dist/index.js";
2
- import { defineComponent as h, ref as l, computed as v } from "vue";
3
- import y from "../../Checkbox/Checkbox.vue.js";
2
+ import { defineComponent as h, ref as l, computed as y } from "vue";
3
+ import v from "../../Checkbox/Checkbox.vue.js";
4
4
  import I from "../../Dropdown/Dropdown.core.vue.js";
5
5
  import { AtTipograph as O } from "../../Tipograph/index.js";
6
6
  const D = h({
7
7
  name: "AtList",
8
- components: { AtDropdown: I, AtParagraph: O.Paragraph, AtCheckbox: y },
8
+ components: { AtDropdown: I, AtParagraph: O.Paragraph, AtCheckbox: v },
9
9
  props: {
10
10
  isOpen: {
11
11
  type: Boolean,
@@ -21,7 +21,7 @@ const D = h({
21
21
  },
22
22
  position: {
23
23
  type: String,
24
- default: "bottom"
24
+ default: "left"
25
25
  },
26
26
  showNoResultMessage: {
27
27
  type: Boolean,
@@ -31,24 +31,32 @@ const D = h({
31
31
  type: Object,
32
32
  default: () => {
33
33
  }
34
+ },
35
+ fullSize: {
36
+ type: Boolean,
37
+ default: !1
38
+ },
39
+ id: {
40
+ type: String,
41
+ default: ""
34
42
  }
35
43
  },
36
44
  emits: ["update:isOpen", "onSave", "itemClicked"],
37
45
  setup(t, { emit: o }) {
38
46
  const a = l(
39
47
  Object.assign([], t.dropDownList)
40
- ), s = l(), r = () => o("update:isOpen", !1), p = ({ text: e, value: n }) => {
48
+ ), s = l(), r = () => o("update:isOpen", !1), i = ({ text: e, value: n }) => {
41
49
  s.value = { text: e, value: n }, o("onSave", s.value);
42
- }, i = () => {
50
+ }, p = () => {
43
51
  s.value = a.value.filter((e) => e.value).map(({ text: e, value: n }) => ({ text: e, value: n })), o("onSave", s.value);
44
52
  }, u = (e) => {
45
53
  if (e.onClick && (e.onClick(e), o("itemClicked", e)), t.isMultiple)
46
- return i();
47
- p(e), r();
48
- }, c = (e) => typeof e == "string" ? e : e.name, f = (e) => {
54
+ return p();
55
+ i(e), r();
56
+ }, f = (e) => typeof e == "string" ? e : e.name, c = (e) => {
49
57
  if (typeof e != "string")
50
58
  return e.color;
51
- }, d = v(
59
+ }, d = y(
52
60
  () => {
53
61
  var e;
54
62
  return !((e = a.value) != null && e.length) && t.showNoResultMessage;
@@ -64,8 +72,8 @@ const D = h({
64
72
  o("update:isOpen", e);
65
73
  },
66
74
  selectItem: u,
67
- getIconName: c,
68
- getIconColor: f
75
+ getIconName: f,
76
+ getIconColor: c
69
77
  };
70
78
  },
71
79
  watch: {
@@ -4,10 +4,10 @@ export interface SearchProps {
4
4
  label: string;
5
5
  modelValue: string;
6
6
  autoCompleteList: DropdownListItem[];
7
- withIcon: boolean | true;
8
- hasAutoComplete: boolean | true;
9
- hasFilterOption: boolean | true;
10
- isDisabled: boolean | false;
7
+ withIcon?: boolean | true;
8
+ hasAutoComplete?: boolean | true;
9
+ hasFilterOption?: boolean | true;
10
+ isDisabled?: boolean | false;
11
11
  }
12
12
  declare const _default: import("vue").DefineComponent<{
13
13
  label: {
@@ -39,9 +39,13 @@ declare const _default: import("vue").DefineComponent<{
39
39
  default: boolean;
40
40
  };
41
41
  isDisabled: {
42
- type: PropType<boolean>;
42
+ type: PropType<boolean | undefined>;
43
43
  default: boolean;
44
44
  };
45
+ id: {
46
+ type: StringConstructor;
47
+ required: false;
48
+ };
45
49
  }, {
46
50
  atSearch: import("vue").Ref<HTMLDivElement | null>;
47
51
  autocompleteListIsOpen: ComputedRef<boolean>;
@@ -85,9 +89,13 @@ declare const _default: import("vue").DefineComponent<{
85
89
  default: boolean;
86
90
  };
87
91
  isDisabled: {
88
- type: PropType<boolean>;
92
+ type: PropType<boolean | undefined>;
89
93
  default: boolean;
90
94
  };
95
+ id: {
96
+ type: StringConstructor;
97
+ required: false;
98
+ };
91
99
  }>> & {
92
100
  "onUpdate:modelValue"?: ((...args: any[]) => any) | undefined;
93
101
  onOnSelectedItem?: ((...args: any[]) => any) | undefined;
@@ -96,7 +104,7 @@ declare const _default: import("vue").DefineComponent<{
96
104
  withIcon: boolean;
97
105
  modelValue: string;
98
106
  autoCompleteList: DropdownListItem[];
99
- isDisabled: boolean;
107
+ isDisabled: boolean | undefined;
100
108
  hasAutoComplete: boolean;
101
109
  hasFilterOption: boolean;
102
110
  }, {}>;