@caipira/tamandua 0.0.13 → 0.0.15

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 (121) hide show
  1. package/README.md +3 -1
  2. package/dist/Avatar.js +2 -2
  3. package/dist/{Avatar.vue_vue_type_script_setup_true_lang-DshMIzMM.js → Avatar.vue_vue_type_script_setup_true_lang-BZy_UetF.js} +1 -1
  4. package/dist/{Button-BVshp51o.js → Button-zA2axPFA.js} +3 -3
  5. package/dist/Button.css +1 -1
  6. package/dist/Button.js +2 -2
  7. package/dist/Button.vue_vue_type_style_index_0_scoped_39c3f26a_lang-tn6M5dNB.js +156 -0
  8. package/dist/ButtonCopy.js +2 -2
  9. package/dist/{ButtonCopy.vue_vue_type_script_setup_true_lang-CZsqPE-4.js → ButtonCopy.vue_vue_type_script_setup_true_lang-hBqHMiGU.js} +1 -1
  10. package/dist/ChartTreemap.js +2 -2
  11. package/dist/{ChartTreemap.vue_vue_type_script_setup_true_lang-BSKB-UTM.js → ChartTreemap.vue_vue_type_script_setup_true_lang-CG5aK3KH.js} +1 -1
  12. package/dist/Dropdown.js +2 -2
  13. package/dist/Dropdown.vue_vue_type_script_setup_true_lang-DRsd_7yO.js +153 -0
  14. package/dist/Form.js +2 -2
  15. package/dist/{Form.vue_vue_type_script_setup_true_lang-DIh6jDi0.js → Form.vue_vue_type_script_setup_true_lang-GWUrHIHW.js} +10 -10
  16. package/dist/GraphyPrice.js +2 -2
  17. package/dist/{GraphyPrice.vue_vue_type_script_setup_true_lang-BxKdnVzF.js → GraphyPrice.vue_vue_type_script_setup_true_lang-GY5TUNz8.js} +1 -1
  18. package/dist/Icon.js +2 -2
  19. package/dist/{Icon.vue_vue_type_script_setup_true_lang-DiRGfOxc.js → Icon.vue_vue_type_script_setup_true_lang-CqJ-D4BM.js} +26 -23
  20. package/dist/IconButton.js +2 -2
  21. package/dist/IconButton.vue_vue_type_script_setup_true_lang-CfILJjtd.js +91 -0
  22. package/dist/InputPassword.js +2 -2
  23. package/dist/{InputPassword.vue_vue_type_script_setup_true_lang-kknXv5I-.js → InputPassword.vue_vue_type_script_setup_true_lang-DvHndXqE.js} +1 -1
  24. package/dist/InputSelect.js +2 -2
  25. package/dist/InputSelect.vue_vue_type_script_setup_true_lang-B93CKCR3.js +227 -0
  26. package/dist/Link.js +6 -0
  27. package/dist/Link.vue_vue_type_script_setup_true_lang-BJVsokc1.js +50 -0
  28. package/dist/ModalForm.js +2 -2
  29. package/dist/{ModalForm.vue_vue_type_script_setup_true_lang-CUk3DI3O.js → ModalForm.vue_vue_type_script_setup_true_lang-CZBGpJCs.js} +2 -2
  30. package/dist/Popconfirm.js +2 -2
  31. package/dist/Popconfirm.vue_vue_type_script_setup_true_lang-CGs37-Nn.js +63 -0
  32. package/dist/Popover.js +2 -2
  33. package/dist/{Popover.vue_vue_type_script_setup_true_lang-Dhcy-iL3.js → Popover.vue_vue_type_script_setup_true_lang-B1brEdFx.js} +319 -321
  34. package/dist/{ProgressLine-CfZKbUcx.js → ProgressLine-1ZHGvPsm.js} +16 -16
  35. package/dist/ProgressLine.css +1 -1
  36. package/dist/ProgressLine.js +2 -2
  37. package/dist/Tag.js +2 -2
  38. package/dist/Tag.vue_vue_type_script_setup_true_lang-BohgPbhp.js +70 -0
  39. package/dist/Toast.js +2 -2
  40. package/dist/{Toast.vue_vue_type_script_setup_true_lang-BAsJNxU_.js → Toast.vue_vue_type_script_setup_true_lang-a5tU5-sA.js} +1 -1
  41. package/dist/alert-octagon-BIUtdQBd.js +5 -0
  42. package/dist/close-circle-Bvyw4JKW.js +5 -0
  43. package/dist/components.js +41 -39
  44. package/dist/enums.js +7 -6
  45. package/dist/{plugin-DLUdf4JV.js → plugin-BAUSOmg1.js} +1 -1
  46. package/dist/{plugin-Cp-YlP7M.js → plugin-BJT9iz31.js} +1 -1
  47. package/dist/{plugin-DYnmuOWz.js → plugin-BRY5cGCc.js} +1 -1
  48. package/dist/{plugin-Bj5VaUuH.js → plugin-BibUAa04.js} +1 -1
  49. package/dist/{plugin-7M6YmkX3.js → plugin-BkWUeqrs.js} +1 -1
  50. package/dist/plugin-C8V0p_Rv.js +10 -0
  51. package/dist/{plugin-CIK2QwfI.js → plugin-CCH1Q2cN.js} +1 -1
  52. package/dist/{plugin-BLdCHEGS.js → plugin-CQQde2zY.js} +1 -1
  53. package/dist/{plugin-D9vhvf_z.js → plugin-CX1WsfRO.js} +1 -1
  54. package/dist/{plugin-DAoreRkB.js → plugin-CqcekUXz.js} +1 -1
  55. package/dist/{plugin-A7Ru6-Ae.js → plugin-D3RtcfcX.js} +1 -1
  56. package/dist/{plugin-Ce0OhiOa.js → plugin-D9DcbHK3.js} +1 -1
  57. package/dist/{plugin-DGx9kLvd.js → plugin-DXEt6BIK.js} +1 -1
  58. package/dist/{plugin-CNoSZVuJ.js → plugin-DmfiHplR.js} +1 -1
  59. package/dist/{plugin-BURDNZOq.js → plugin-Duvcbc38.js} +1 -1
  60. package/dist/{plugin-AFgt8nH4.js → plugin-DyiLV5Qf.js} +1 -1
  61. package/dist/{plugin-c1rFpmlH.js → plugin-JgFOdNjC.js} +1 -1
  62. package/dist/{plugin-DmkLbCIU.js → plugin-zLwlm_b-.js} +1 -1
  63. package/dist/plugins-DZGnWkJf.js +112 -0
  64. package/dist/plugins.js +100 -97
  65. package/dist/tamandua.js +1 -1
  66. package/dist/types/components/Avatar/Avatar.story.d.ts +18 -5
  67. package/dist/types/components/Button/Button.story.d.ts +15 -44
  68. package/dist/types/components/Button/Button.vue.d.ts +5 -5
  69. package/dist/types/components/Button/types.d.ts +2 -2
  70. package/dist/types/components/ChartLine/ChartLine.story.d.ts +18 -12
  71. package/dist/types/components/ChartTreemap/ChartTreemap.story.d.ts +16 -2
  72. package/dist/types/components/ChartTreemap/types.d.ts +8 -2
  73. package/dist/types/components/Dropdown/types.d.ts +1 -1
  74. package/dist/types/components/Form/Form.vue.d.ts +4 -4
  75. package/dist/types/components/Form/types.d.ts +2 -2
  76. package/dist/types/components/GraphyPrice/GraphyPrice.story.d.ts +24 -2
  77. package/dist/types/components/Icon/Icon.story.d.ts +26 -0
  78. package/dist/types/components/Icon/types.d.ts +1 -1
  79. package/dist/types/components/IconButton/IconButton.vue.d.ts +5 -45
  80. package/dist/types/components/IconButton/types.d.ts +1 -7
  81. package/dist/types/components/InputDate/InputDate.story.d.ts +9 -2
  82. package/dist/types/components/InputMultiplier/input-multiplier.story.d.ts +8 -3
  83. package/dist/types/components/InputRadio/InputRadioGroup.story.d.ts +6 -2
  84. package/dist/types/components/InputSelect/InputSelect.story.d.ts +37 -4
  85. package/dist/types/components/InputSelect/InputSelect.vue.d.ts +1 -1
  86. package/dist/types/components/InputSelect/types.d.ts +0 -1
  87. package/dist/types/components/InputSwitch/InputSwitch.story.d.ts +10 -18
  88. package/dist/types/components/Link/Link.story.d.ts +20 -0
  89. package/dist/types/components/Link/Link.vue.d.ts +46 -0
  90. package/dist/types/components/Link/index.d.ts +5 -0
  91. package/dist/types/components/Link/plugin.d.ts +4 -0
  92. package/dist/types/components/Link/types.d.ts +11 -0
  93. package/dist/types/components/Pagination/Pagination.story.d.ts +6 -1
  94. package/dist/types/components/Popconfirm/Popconfirm.vue.d.ts +1 -3
  95. package/dist/types/components/Popconfirm/types.d.ts +1 -1
  96. package/dist/types/components/Popover/Popover.vue.d.ts +0 -3
  97. package/dist/types/components/Popover/types.d.ts +0 -1
  98. package/dist/types/components/ProgressCircle/ProgressCircle.story.d.ts +13 -3
  99. package/dist/types/components/ProgressLine/ProgressLine.story.d.ts +12 -3
  100. package/dist/types/components/Table/Table.story.d.ts +16 -3
  101. package/dist/types/components/Tag/Tag.story.d.ts +29 -0
  102. package/dist/types/components/index.d.ts +3 -2
  103. package/dist/types/components/plugins.d.ts +2 -1
  104. package/dist/types/enums/index.d.ts +2 -2
  105. package/dist/types/enums/ui.d.ts +13 -4
  106. package/dist/types/i18n.d.ts +6 -0
  107. package/dist/types/types/form.d.ts +1 -1
  108. package/dist/types/types/ui.d.ts +2 -2
  109. package/dist/ui-D3dPdT4S.js +13 -0
  110. package/package.json +1 -2
  111. package/volar.d.ts +1 -0
  112. package/dist/Button.vue_vue_type_style_index_0_scoped_8639b950_lang-C9uKZk0F.js +0 -143
  113. package/dist/Dropdown.vue_vue_type_script_setup_true_lang-BUcFKrav.js +0 -135
  114. package/dist/IconButton.vue_vue_type_script_setup_true_lang-DEL6iIAu.js +0 -106
  115. package/dist/InputSelect.vue_vue_type_script_setup_true_lang-ByRPZrIg.js +0 -216
  116. package/dist/Popconfirm.vue_vue_type_script_setup_true_lang-DWMW-u7V.js +0 -65
  117. package/dist/Tag.vue_vue_type_script_setup_true_lang-vLIykMPS.js +0 -63
  118. package/dist/alert-octagon-D8wznooU.js +0 -4
  119. package/dist/close-circle-Bsf9_pUR.js +0 -4
  120. package/dist/plugins-DNNQp3qM.js +0 -109
  121. package/dist/ui-DtSy-y9T.js +0 -11
@@ -0,0 +1,91 @@
1
+ import { defineComponent as D, getCurrentInstance as B, ref as g, computed as l, resolveComponent as k, openBlock as r, createBlock as E, resolveDynamicComponent as T, normalizeClass as N, unref as u, withCtx as U, createVNode as L, createElementBlock as z, createCommentVNode as w } from "vue";
2
+ import { c as t, a as R, b as s } from "./ui-D3dPdT4S.js";
3
+ import { u as S } from "./useDomHelpers-5CFMo6bx.js";
4
+ const x = ["multiple"], K = /* @__PURE__ */ D({
5
+ name: "TIconButton",
6
+ __name: "IconButton",
7
+ props: {
8
+ to: {},
9
+ icon: {},
10
+ href: { default: "" },
11
+ type: { default: t.BUTTON },
12
+ size: { default: R.DEFAULT },
13
+ label: { default: "" },
14
+ shape: { default: s.ROUNDED },
15
+ target: { default: void 0 },
16
+ multiple: { type: Boolean, default: !1 },
17
+ isDisabled: { type: Boolean, default: !1 }
18
+ },
19
+ emits: ["upload"],
20
+ setup(c, { emit: p }) {
21
+ const e = c, f = p, a = B(), i = g(), { isPopoverActivator: d, onPopoverActivatorClick: m } = S(), h = l(() => e.href ? e.href : void 0), v = l(() => {
22
+ switch (e.type) {
23
+ case t.LINK:
24
+ return;
25
+ case t.FILE:
26
+ return "button";
27
+ default:
28
+ return e.type;
29
+ }
30
+ }), y = l(() => e.type === t.SUBMIT ? e.label : void 0), _ = l(() => {
31
+ switch (e.type) {
32
+ case t.SUBMIT:
33
+ return "input";
34
+ case t.LINK:
35
+ return "a";
36
+ case t.ROUTER_LINK:
37
+ return "router-link";
38
+ default:
39
+ return "button";
40
+ }
41
+ }), I = (n) => {
42
+ a && d(a) && m(n, a), e.type === t.SUBMIT && n.preventDefault(), e.type === t.FILE && i.value?.click();
43
+ }, b = (n) => {
44
+ n.stopPropagation();
45
+ const o = n.target.files;
46
+ !o || !o.length || f("upload", o);
47
+ };
48
+ return (n, C) => {
49
+ const o = k("t-icon");
50
+ return r(), E(T(_.value), {
51
+ type: v.value,
52
+ href: h.value,
53
+ value: y.value,
54
+ to: e.to,
55
+ disabled: e.isDisabled,
56
+ target: e.target,
57
+ class: N([{
58
+ "opacity-50": e.isDisabled,
59
+ // Shape
60
+ "rounded-full": e.shape === u(s).CIRCLE,
61
+ "input-roundness": e.shape === u(s).ROUNDED,
62
+ // Cursor
63
+ "cursor-pointer": !e.isDisabled,
64
+ "cursor-not-allowed": e.isDisabled
65
+ }, "input-outline flex items-center"]),
66
+ role: "button",
67
+ onClick: I
68
+ }, {
69
+ default: U(() => [
70
+ L(o, {
71
+ size: e.size,
72
+ icon: e.icon
73
+ }, null, 8, ["size", "icon"]),
74
+ e.type === "file" ? (r(), z("input", {
75
+ key: 0,
76
+ multiple: e.multiple,
77
+ onChange: b,
78
+ type: "file",
79
+ ref_key: "fileInput",
80
+ ref: i,
81
+ class: "hidden"
82
+ }, null, 40, x)) : w("", !0)
83
+ ]),
84
+ _: 1
85
+ }, 8, ["type", "href", "value", "to", "disabled", "target", "class"]);
86
+ };
87
+ }
88
+ });
89
+ export {
90
+ K as _
91
+ };
@@ -1,5 +1,5 @@
1
- import { _ as s } from "./InputPassword.vue_vue_type_script_setup_true_lang-kknXv5I-.js";
2
- import { p as a } from "./plugin-BURDNZOq.js";
1
+ import { _ as s } from "./InputPassword.vue_vue_type_script_setup_true_lang-DvHndXqE.js";
2
+ import { p as a } from "./plugin-Duvcbc38.js";
3
3
  export {
4
4
  s as InputPassword,
5
5
  a as InputPasswordPlugin
@@ -1,5 +1,5 @@
1
1
  import { defineComponent as ee, ref as S, inject as te, watch as ne, resolveComponent as O, openBlock as k, createElementBlock as L, normalizeClass as T, unref as U, createElementVNode as P, createVNode as q, createCommentVNode as N, withKeys as le, createBlock as se, toDisplayString as oe } from "vue";
2
- import { _ as ae } from "./ButtonCopy.vue_vue_type_script_setup_true_lang-CZsqPE-4.js";
2
+ import { _ as ae } from "./ButtonCopy.vue_vue_type_script_setup_true_lang-hBqHMiGU.js";
3
3
  import { f as re } from "./index-CjvqeRf7.js";
4
4
  const ie = (s) => {
5
5
  let e = 0, r = 0, l = 0, i = 0, o = 0, u = 0, m = 0, p = 0, f = 0, I = 0, c = 0, x = 0, y = 0, b = 0, M = 0, _ = 0, n = 0, d = 0, A = 2, V = 2, R = 2, g = 2, E = 3, K = 3, D = 3, W = 4, Z = 4, G = 6, B = "", $ = "", j = "", C = "Too Short";
@@ -1,5 +1,5 @@
1
- import { _ as p } from "./InputSelect.vue_vue_type_script_setup_true_lang-ByRPZrIg.js";
2
- import { p as r } from "./plugin-CNoSZVuJ.js";
1
+ import { _ as p } from "./InputSelect.vue_vue_type_script_setup_true_lang-B93CKCR3.js";
2
+ import { p as r } from "./plugin-DmfiHplR.js";
3
3
  export {
4
4
  p as InputSelect,
5
5
  r as InputSelectPlugin
@@ -0,0 +1,227 @@
1
+ import { defineComponent as ue, ref as p, inject as re, computed as $, onBeforeMount as ce, onBeforeUnmount as pe, watch as A, resolveComponent as b, openBlock as i, createElementBlock as c, normalizeClass as V, unref as M, createElementVNode as de, withKeys as fe, renderSlot as h, normalizeProps as k, mergeProps as D, Fragment as _, renderList as U, guardReactiveProps as H, createBlock as I, toDisplayString as me, createCommentVNode as N, withDirectives as ve, vModelText as ye, createVNode as P, withCtx as q, createSlots as be, nextTick as he } from "vue";
2
+ import { u as ke } from "./useDomHelpers-5CFMo6bx.js";
3
+ import { a as we, E as ge } from "./ui-D3dPdT4S.js";
4
+ const Ve = { key: 1 }, _e = ["placeholder", "disabled", "readonly"], Se = {
5
+ key: 0,
6
+ class: "inline-flex w-full justify-between items-center"
7
+ }, xe = {
8
+ key: 1,
9
+ class: "inline-flex items-center"
10
+ };
11
+ let Ce = 0;
12
+ const $e = /* @__PURE__ */ ue({
13
+ name: "TInputSelect",
14
+ __name: "InputSelect",
15
+ props: {
16
+ size: { default: we.DEFAULT },
17
+ options: { default: () => [] },
18
+ mapper: { type: Function, default: (f) => ({ value: f.id ?? f.uuid, label: f }) },
19
+ filter: { type: Function, default: (f, S) => S.label.toLowerCase().indexOf(f.toLowerCase()) >= 0 },
20
+ tooltip: { default: "" },
21
+ disabled: { type: Boolean },
22
+ resource: {},
23
+ multiple: { type: Boolean, default: !1 },
24
+ modelValue: {},
25
+ placeholder: { default: "" },
26
+ initialValue: {},
27
+ disableStyle: { type: Boolean, default: !1 },
28
+ isSearchable: { type: Boolean, default: !1 },
29
+ dropdownPlacement: { default: ge.BOTTOM }
30
+ },
31
+ emits: ["update:model-value"],
32
+ setup(f, { emit: S }) {
33
+ const l = f;
34
+ let x = !1, w, T = "";
35
+ const G = S, J = `checkbox_${++Ce}`, r = p(""), o = p([]), L = p(null), O = re("formStyle", { label: "", input: "" }), C = p(null), n = p(!1), z = p(null), a = p([]), B = p(!1), { wasClickOutsideOfContainer: Q } = ke(), d = p(null), E = $(() => a.value.length > 0), F = $(() => l.isSearchable && n.value), v = $(() => typeof l.resource == "function"), W = (e) => !l.multiple || !l.modelValue || !Array.isArray(l.modelValue) ? !1 : l.modelValue.includes(e.value), X = (e = l.modelValue) => !(e === void 0 || e === "" || Array.isArray(e) && e.length === 0), Y = (e) => {
36
+ G("update:model-value", e);
37
+ }, m = (e = l.modelValue) => {
38
+ if (X(e))
39
+ if (l.multiple)
40
+ Array.isArray(e) && (a.value = e.map(
41
+ (t) => R(t)
42
+ ).filter((t) => t > -1));
43
+ else {
44
+ const t = R(e);
45
+ ~t && (a.value = [t]);
46
+ }
47
+ }, K = (e) => {
48
+ n.value = !n.value, n.value && F.value && he(() => {
49
+ L.value?.focus();
50
+ }), e.stopPropagation();
51
+ }, R = (e) => o.value.findIndex(
52
+ (t) => t.value === e
53
+ ), j = (e) => {
54
+ C.value && Q(e, C.value) && (n.value = !1);
55
+ }, g = async (e = !1) => {
56
+ if (!l.resource)
57
+ return;
58
+ B.value = !0;
59
+ const t = {
60
+ t: r.value,
61
+ r: "option"
62
+ };
63
+ e && d.value && d.value.pages > d.value.page ? t.page = d.value.page + 1 : e = !1, !r.value && l.modelValue && (t.i = l.modelValue);
64
+ const u = await l.resource(t);
65
+ e ? o.value.push(...u.items.map(l.mapper)) : o.value = u.items.map(l.mapper), d.value = u.pagination, !v.value && r.value && m(r.value), B.value = !1;
66
+ }, Z = () => {
67
+ !r.value || T === r.value || (w && (clearTimeout(w), w = null), w = setTimeout(() => {
68
+ T = r.value, v.value ? (n.value || (n.value = !0), g()) : l.isSearchable && (o.value = l.options.filter(
69
+ (e) => l.filter(r.value, e)
70
+ ));
71
+ }, 500));
72
+ }, ee = () => {
73
+ n.value = !1;
74
+ }, le = (e) => {
75
+ n.value = !1, e.stopPropagation();
76
+ }, te = ({
77
+ index: e,
78
+ hold: t
79
+ }) => {
80
+ if (x = !0, l.multiple) {
81
+ const u = a.value.findIndex(
82
+ (y) => y === e
83
+ );
84
+ ~u ? a.value.splice(u, 1) : a.value.push(e);
85
+ } else
86
+ a.value = [e];
87
+ (!l.multiple || !t) && (n.value = !1);
88
+ }, ae = () => {
89
+ v.value && d.value && d.value.pages > d.value.page && g(!0);
90
+ }, oe = async (e) => {
91
+ switch (e.key) {
92
+ case "ArrowDown":
93
+ z.value?.move(e);
94
+ break;
95
+ }
96
+ };
97
+ return ce(async () => {
98
+ v.value ? (await g(), m()) : l.options.length > 0 && (o.value = l.options), !l.modelValue && l.initialValue ? m(l.initialValue) : m(l.modelValue), document.addEventListener("click", j);
99
+ }), pe(() => {
100
+ document.removeEventListener("click", j);
101
+ }), A(
102
+ () => l.modelValue,
103
+ async (e) => {
104
+ e && (R(e) < 0 && v.value && await g(), m(e));
105
+ }
106
+ ), A(
107
+ a,
108
+ (e) => {
109
+ const t = l.multiple ? o.value.filter(
110
+ (u, y) => a.value.includes(y)
111
+ ).map((u) => u.value) : o.value[a.value[0]].value;
112
+ x && (x = !1, Y(t));
113
+ },
114
+ { deep: !0 }
115
+ ), A(
116
+ () => l.options,
117
+ (e) => {
118
+ e.length > 0 && (o.value = e, l.modelValue && a.value.length === 0 && m(l.modelValue));
119
+ }
120
+ ), (e, t) => {
121
+ const u = b("t-tag"), y = b("t-icon-button"), ne = b("t-icon"), se = b("t-dropdown"), ie = b("t-popover");
122
+ return i(), c("div", {
123
+ class: V({ [M(O).input]: !l.disableStyle })
124
+ }, [
125
+ de("div", {
126
+ ref_key: "wrapperRef",
127
+ ref: C,
128
+ class: V([{
129
+ "h-9": !l.disableStyle && !l.multiple,
130
+ "min-h-9": !l.disableStyle && l.multiple,
131
+ "text-left select-none input-bg-color input-text-color border input-border input-roundness": !l.disableStyle,
132
+ [M(O).input]: !l.disableStyle
133
+ }, "inline-flex justify-between items-center w-full text-left"]),
134
+ role: "button",
135
+ onClick: K,
136
+ onBlur: ee,
137
+ onKeyup: fe(le, ["esc"])
138
+ }, [
139
+ F.value ? ve((i(), c("input", {
140
+ key: 1,
141
+ "onUpdate:modelValue": t[0] || (t[0] = (s) => r.value = s),
142
+ type: "text",
143
+ ref_key: "inputRef",
144
+ ref: L,
145
+ placeholder: l.placeholder,
146
+ disabled: l.disabled,
147
+ readonly: !l.isSearchable,
148
+ class: V([{ "cursor-pointer": !l.isSearchable }, "w-full h-9 bg-transparent input-padding input-roundness input-outline"]),
149
+ onClick: t[1] || (t[1] = (s) => s.stopPropagation()),
150
+ onInput: Z,
151
+ onKeydown: oe
152
+ }, null, 42, _e)), [
153
+ [ye, r.value]
154
+ ]) : (i(), c("div", {
155
+ key: 0,
156
+ class: V(["flex items-center ml-2", {
157
+ "overflow-hidden whitespace-nowrap": !l.multiple,
158
+ "flex-wrap gap-2 py-1": l.multiple
159
+ }])
160
+ }, [
161
+ e.$slots.selection && E.value ? h(e.$slots, "selection", k(D({ key: 0 }, o.value[a.value[0]].label))) : e.$slots.default && E.value ? (i(), c(_, { key: 1 }, [
162
+ l.multiple ? (i(!0), c(_, { key: 0 }, U(a.value, (s) => h(e.$slots, "default", k(H(o.value[s].label)))), 256)) : h(e.$slots, "default", k(D({ key: 1 }, o.value[a.value[0]].label)))
163
+ ], 64)) : E.value ? (i(), c(_, { key: 2 }, [
164
+ l.multiple ? (i(!0), c(_, { key: 0 }, U(a.value, (s) => (i(), I(u, {
165
+ key: s,
166
+ text: o.value[s].label,
167
+ color: "#6e6e6e"
168
+ }, null, 8, ["text"]))), 128)) : (i(), c("span", Ve, me(o.value[a.value[0]]?.label), 1))
169
+ ], 64)) : N("", !0)
170
+ ], 2)),
171
+ P(y, {
172
+ "disable-style": !0,
173
+ class: "h-9",
174
+ icon: n.value === !0 ? "chevron-up" : "chevron-down",
175
+ onClick: K
176
+ }, null, 8, ["icon"])
177
+ ], 34),
178
+ P(ie, {
179
+ placement: l.dropdownPlacement,
180
+ "is-visible": n.value
181
+ }, {
182
+ content: q(() => [
183
+ P(se, {
184
+ ref_key: "dropdownRef",
185
+ ref: z,
186
+ owner: J,
187
+ items: o.value,
188
+ "is-visible": n.value,
189
+ multiple: l.multiple,
190
+ loading: B.value,
191
+ class: "fixed",
192
+ "aria-describedby": "tooltip",
193
+ onChange: te,
194
+ onEndReached: ae
195
+ }, be({ _: 2 }, [
196
+ e.$slots.default || l.multiple ? {
197
+ name: "default",
198
+ fn: q((s) => [
199
+ l.multiple ? (i(), c("div", Se, [
200
+ e.$slots.default ? h(e.$slots, "default", k(D({ key: 0 }, s.label))) : (i(), I(u, {
201
+ key: 1,
202
+ text: s.label,
203
+ class: "m-1"
204
+ }, null, 8, ["text"])),
205
+ W(s) ? (i(), I(ne, {
206
+ key: 2,
207
+ icon: "check",
208
+ size: "sm",
209
+ class: "float-right ml-2"
210
+ })) : N("", !0)
211
+ ])) : (i(), c("div", xe, [
212
+ h(e.$slots, "default", k(H(s.label)))
213
+ ]))
214
+ ]),
215
+ key: "0"
216
+ } : void 0
217
+ ]), 1032, ["items", "is-visible", "multiple", "loading"])
218
+ ]),
219
+ _: 3
220
+ }, 8, ["placement", "is-visible"])
221
+ ], 2);
222
+ };
223
+ }
224
+ });
225
+ export {
226
+ $e as _
227
+ };
package/dist/Link.js ADDED
@@ -0,0 +1,6 @@
1
+ import { _ as i } from "./Link.vue_vue_type_script_setup_true_lang-BJVsokc1.js";
2
+ import { p } from "./plugin-C8V0p_Rv.js";
3
+ export {
4
+ i as Link,
5
+ p as LinkPlugin
6
+ };
@@ -0,0 +1,50 @@
1
+ import { defineComponent as s, computed as d, resolveComponent as c, openBlock as o, createBlock as n, resolveDynamicComponent as m, withCtx as u, renderSlot as p, createElementBlock as f, Fragment as _, createTextVNode as k, toDisplayString as y, createCommentVNode as b } from "vue";
2
+ import { L as l } from "./ui-D3dPdT4S.js";
3
+ const B = /* @__PURE__ */ s({
4
+ name: "TLink",
5
+ __name: "Link",
6
+ props: {
7
+ to: {},
8
+ href: {},
9
+ type: { default: l.Default },
10
+ label: { default: "" },
11
+ target: { default: "_self" },
12
+ disabled: { type: Boolean, default: !1 }
13
+ },
14
+ setup(r, { emit: v }) {
15
+ const e = r, t = d(() => {
16
+ switch (e.type) {
17
+ case l.Router:
18
+ return "router-link";
19
+ default:
20
+ return "a";
21
+ }
22
+ });
23
+ return (a, g) => {
24
+ const i = c("t-icon");
25
+ return o(), n(m(t.value), {
26
+ href: t.value === "a" ? e.href : void 0,
27
+ to: t.value === "router-link" ? e.to : void 0,
28
+ disabled: e.disabled,
29
+ target: e.target,
30
+ class: "color-caipira-primary-inverted underline font-bold inline-flex items-baseline"
31
+ }, {
32
+ default: u(() => [
33
+ a.$slots.default ? p(a.$slots, "default", { key: 0 }) : (o(), f(_, { key: 1 }, [
34
+ k(y(e.label), 1)
35
+ ], 64)),
36
+ e.target === "_blank" ? (o(), n(i, {
37
+ key: 2,
38
+ size: 15,
39
+ class: "ml-1",
40
+ icon: "open-in-new"
41
+ })) : b("", !0)
42
+ ]),
43
+ _: 3
44
+ }, 8, ["href", "to", "disabled", "target"]);
45
+ };
46
+ }
47
+ });
48
+ export {
49
+ B as _
50
+ };
package/dist/ModalForm.js CHANGED
@@ -1,5 +1,5 @@
1
- import { _ as a } from "./ModalForm.vue_vue_type_script_setup_true_lang-CUk3DI3O.js";
2
- import { p as l } from "./plugin-CIK2QwfI.js";
1
+ import { _ as a } from "./ModalForm.vue_vue_type_script_setup_true_lang-CZBGpJCs.js";
2
+ import { p as l } from "./plugin-CCH1Q2cN.js";
3
3
  export {
4
4
  a as ModalForm,
5
5
  l as ModalFormPlugin
@@ -59,7 +59,7 @@ const $ = {
59
59
  })
60
60
  ])) : (l(), a(B, {
61
61
  key: 1,
62
- title: `Are you sure you want to delete this ${s.value?.title}?`,
62
+ message: `Are you sure you want to delete this ${s.value?.title}?`,
63
63
  onConfirm: t[2] || (t[2] = () => e.value?.delete())
64
64
  }, {
65
65
  default: n(() => [
@@ -74,7 +74,7 @@ const $ = {
74
74
  }, null, 8, ["is-disabled"])) : d("", !0)
75
75
  ]),
76
76
  _: 1
77
- }, 8, ["title"])),
77
+ }, 8, ["message"])),
78
78
  c(_, {
79
79
  variant: "success",
80
80
  icon: "save",
@@ -1,5 +1,5 @@
1
- import { _ as p } from "./Popconfirm.vue_vue_type_script_setup_true_lang-DWMW-u7V.js";
2
- import { p as m } from "./plugin-D9vhvf_z.js";
1
+ import { _ as p } from "./Popconfirm.vue_vue_type_script_setup_true_lang-CGs37-Nn.js";
2
+ import { p as m } from "./plugin-CX1WsfRO.js";
3
3
  export {
4
4
  p as Popconfirm,
5
5
  m as PopconfirmPlugin
@@ -0,0 +1,63 @@
1
+ import { defineComponent as b, ref as g, resolveComponent as t, openBlock as k, createBlock as y, withCtx as r, createElementVNode as o, createVNode as n, toDisplayString as P, renderSlot as w } from "vue";
2
+ import { E as h } from "./ui-D3dPdT4S.js";
3
+ const z = { class: "text-sm mb-6 inline-flex items-center" }, B = { class: "color-text" }, E = { class: "flex justify-end gap-2" }, O = /* @__PURE__ */ b({
4
+ name: "TPopconfirm",
5
+ __name: "Popconfirm",
6
+ props: {
7
+ message: { default: "" },
8
+ placement: { default: h.BOTTOM }
9
+ },
10
+ emits: ["confirm"],
11
+ setup(m, { emit: p }) {
12
+ const s = m, f = p, c = g(), _ = (e) => (c.value = e, e), d = () => {
13
+ c.value.visible = !1;
14
+ }, u = (e) => {
15
+ f("confirm"), e(!1);
16
+ };
17
+ return (e, l) => {
18
+ const v = t("t-icon"), i = t("t-button"), C = t("t-popover");
19
+ return k(), y(C, {
20
+ placement: s.placement,
21
+ "slot-wrapper-classes": "rounded",
22
+ ref: _
23
+ }, {
24
+ content: r(({ onTogglePopover: x }) => [
25
+ o("div", {
26
+ class: "mx-2 my-3 select-none",
27
+ onClick: l[0] || (l[0] = (a) => a.stopPropagation())
28
+ }, [
29
+ o("p", z, [
30
+ n(v, {
31
+ icon: "info-outline",
32
+ class: "color-caipira-yellow mr-1",
33
+ size: "sm"
34
+ }),
35
+ o("span", B, P(s.message), 1)
36
+ ]),
37
+ o("div", E, [
38
+ n(i, {
39
+ variant: "warning",
40
+ label: "Cancel",
41
+ size: "sm",
42
+ onClick: d
43
+ }),
44
+ n(i, {
45
+ variant: "primary",
46
+ label: "Confirm",
47
+ size: "sm",
48
+ onClick: (a) => u(x)
49
+ }, null, 8, ["onClick"])
50
+ ])
51
+ ])
52
+ ]),
53
+ default: r(() => [
54
+ w(e.$slots, "default")
55
+ ]),
56
+ _: 3
57
+ }, 8, ["placement"]);
58
+ };
59
+ }
60
+ });
61
+ export {
62
+ O as _
63
+ };
package/dist/Popover.js CHANGED
@@ -1,5 +1,5 @@
1
- import { _ as p } from "./Popover.vue_vue_type_script_setup_true_lang-Dhcy-iL3.js";
2
- import { p as P } from "./plugin-c1rFpmlH.js";
1
+ import { _ as p } from "./Popover.vue_vue_type_script_setup_true_lang-B1brEdFx.js";
2
+ import { p as P } from "./plugin-JgFOdNjC.js";
3
3
  export {
4
4
  p as Popover,
5
5
  P as PopoverPlugin