@agrotools1/at-components 2.0.5 → 2.0.6

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.
@@ -1 +1 @@
1
- {"version":3,"file":"ComboboxInput.vue.d.ts","sourceRoot":"","sources":["../../src/combobox/ComboboxInput.vue"],"names":[],"mappings":"AAqGA,OAAO,KAAK,EAAsB,kBAAkB,EAAE,MAAM,SAAS,CAAA;AAErE,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,KAAK,CAAA;AAQzC,KAAK,WAAW,GAAG,kBAAkB,GAAG;IAClC,KAAK,CAAC,EAAE,cAAc,CAAC,OAAO,CAAC,CAAA;IAC/B,QAAQ,CAAC,EAAE,OAAO,CAAA;IAClB,eAAe,CAAC,EAAE,OAAO,CAAA;CAC1B,CAAC;AAkCN,iBAAS,cAAc;WA4GT,OAAO,IAA6B;;yBAVpB,GAAG;;;;EAehC;AAkBD,KAAK,oBAAoB,GAAG,UAAU,CAAC,OAAO,cAAc,CAAC,CAAC;AAC9D,QAAA,MAAM,eAAe;;;;;qBAvKG,OAAO;6EA+K7B,CAAC;wBACkB,uBAAuB,CAAC,OAAO,eAAe,EAAE,oBAAoB,CAAC,OAAO,CAAC,CAAC;AAAnG,wBAAoG;AAapG,KAAK,uBAAuB,CAAC,CAAC,EAAE,CAAC,IAAI,CAAC,GAAG;IACxC,QAAO;QACN,MAAM,EAAE,CAAC,CAAC;KAEV,CAAA;CACD,CAAC"}
1
+ {"version":3,"file":"ComboboxInput.vue.d.ts","sourceRoot":"","sources":["../../src/combobox/ComboboxInput.vue"],"names":[],"mappings":"AAmGA,OAAO,KAAK,EAAuC,kBAAkB,EAAE,MAAM,SAAS,CAAA;AAEtF,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,KAAK,CAAA;AASzC,KAAK,WAAW,GAAG,kBAAkB,GAAG;IAClC,KAAK,CAAC,EAAE,cAAc,CAAC,OAAO,CAAC,CAAA;IAC/B,QAAQ,CAAC,EAAE,OAAO,CAAA;IAClB,eAAe,CAAC,EAAE,OAAO,CAAA;CAC1B,CAAC;AAqCN,iBAAS,cAAc;WAsGT,OAAO,IAA6B;;yBAVpB,GAAG;;;;EAehC;AAmBD,KAAK,oBAAoB,GAAG,UAAU,CAAC,OAAO,cAAc,CAAC,CAAC;AAC9D,QAAA,MAAM,eAAe;;;;;qBArKG,OAAO;6EA6K7B,CAAC;wBACkB,uBAAuB,CAAC,OAAO,eAAe,EAAE,oBAAoB,CAAC,OAAO,CAAC,CAAC;AAAnG,wBAAoG;AAapG,KAAK,uBAAuB,CAAC,CAAC,EAAE,CAAC,IAAI,CAAC,GAAG;IACxC,QAAO;QACN,MAAM,EAAE,CAAC,CAAC;KAEV,CAAA;CACD,CAAC"}
package/dist/index.js CHANGED
@@ -22366,11 +22366,16 @@ const xC = /* @__PURE__ */ _({
22366
22366
  },
22367
22367
  emits: ["update:modelValue"],
22368
22368
  setup(e, { emit: t }) {
22369
- const a = e, n = t, o = Ut(), l = W(a, "class", "withIcon"), s = ue(l, n);
22370
- function i(u) {
22371
- u.stopPropagation(), u.preventDefault(), o.multiple.value ? o.modelValue.value = [] : o.modelValue.value = null;
22369
+ const a = e, n = t, o = Ut(), l = W(a, "class", "withIcon"), s = ue(l, n), i = P(() => {
22370
+ const d = o.modelValue.value;
22371
+ return Array.isArray(d) ? d.length > 0 : d != null && d !== "";
22372
+ });
22373
+ function u(d) {
22374
+ d.stopPropagation(), d.preventDefault();
22375
+ const c = o.multiple.value ? [] : void 0;
22376
+ o.modelValue.value = c;
22372
22377
  }
22373
- return (u, d) => (h(), R("div", {
22378
+ return (d, c) => (h(), R("div", {
22374
22379
  "data-slot": "command-input-wrapper",
22375
22380
  class: Q(
22376
22381
  r(I)(
@@ -22381,7 +22386,7 @@ const xC = /* @__PURE__ */ _({
22381
22386
  )
22382
22387
  )
22383
22388
  }, [
22384
- u.withIcon ? (h(), b(r(O0), {
22389
+ d.withIcon ? (h(), b(r(O0), {
22385
22390
  key: 0,
22386
22391
  class: "size-4 shrink-0 opacity-50"
22387
22392
  })) : Me("", !0),
@@ -22391,17 +22396,17 @@ const xC = /* @__PURE__ */ _({
22391
22396
  "placeholder:text-muted-foreground flex h-full w-full bg-transparent text-sm text-gray-800 outline-hidden disabled:cursor-not-allowed disabled:opacity-50 md:text-sm",
22392
22397
  a.class
22393
22398
  )
22394
- }, { ...u.$attrs, ...r(s) }), {
22399
+ }, { ...d.$attrs, ...r(s) }), {
22395
22400
  default: m(() => [
22396
- w(u.$slots, "default")
22401
+ w(d.$slots, "default")
22397
22402
  ]),
22398
22403
  _: 3
22399
22404
  }, 16, ["class"]),
22400
- u.withClearButton && r(o).modelValue.value && (Array.isArray(r(o).modelValue.value) ? r(o).modelValue.value.length > 0 : r(o).modelValue.value !== "") ? (h(), R("button", {
22405
+ d.withClearButton && i.value ? (h(), R("button", {
22401
22406
  key: 1,
22402
22407
  type: "button",
22403
22408
  class: "text-muted-foreground hover:text-foreground cursor-pointer transition-colors",
22404
- onClick: i
22409
+ onClick: u
22405
22410
  }, [
22406
22411
  F(r(Fa), { class: "size-4" })
22407
22412
  ])) : Me("", !0),
@@ -22409,7 +22414,7 @@ const xC = /* @__PURE__ */ _({
22409
22414
  class: Q(["text-muted-foreground hover:text-foreground cursor-pointer transition-transform", {
22410
22415
  "rotate-180": r(o).open.value
22411
22416
  }]),
22412
- onClick: d[0] || (d[0] = (c) => r(o).onOpenChange(!r(o).open.value))
22417
+ onClick: c[0] || (c[0] = (p) => r(o).onOpenChange(!r(o).open.value))
22413
22418
  }, [
22414
22419
  F(r(qa), { class: "size-4" })
22415
22420
  ], 2)
@@ -27969,10 +27974,14 @@ const fx = /* @__PURE__ */ _({
27969
27974
  },
27970
27975
  setup(e) {
27971
27976
  const t = e, a = W(t, "class"), n = ce(a), o = ya();
27972
- function l(s) {
27973
- s.stopPropagation(), s.preventDefault(), o.multiple.value ? o.modelValue.value = [] : o.modelValue.value = null;
27977
+ function l(i) {
27978
+ i.stopPropagation(), i.preventDefault(), o.multiple.value ? o.modelValue.value = [] : o.modelValue.value = void 0;
27974
27979
  }
27975
- return (s, i) => (h(), b(r(Ef), A({ "data-slot": "select-trigger" }, r(n), {
27980
+ const s = P(() => {
27981
+ const i = o.modelValue.value;
27982
+ return Array.isArray(i) ? i.length > 0 : i != null && i !== "";
27983
+ });
27984
+ return (i, u) => (h(), b(r(Ef), A({ "data-slot": "select-trigger" }, r(n), {
27976
27985
  class: r(I)(
27977
27986
  // eslint-disable-next-line prettier/prettier
27978
27987
  "border-input data-[placeholder]:text-muted-foreground [&_svg:not([class*='text-'])]:text-muted-foreground focus-visible:ring-ring/50 aria-invalid:ring-destructive/20 aria-invalid:border-destructive flex w-fit items-center justify-between gap-2 rounded-xl border bg-transparent p-2.5 text-sm whitespace-nowrap shadow-xs transition-[color,box-shadow] outline-none focus-visible:ring-[3px] disabled:cursor-not-allowed disabled:border-neutral-200 disabled:bg-gray-100 *:data-[slot=select-value]:line-clamp-1 *:data-[slot=select-value]:flex *:data-[slot=select-value]:items-center *:data-[slot=select-value]:gap-2 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4",
@@ -27980,13 +27989,13 @@ const fx = /* @__PURE__ */ _({
27980
27989
  )
27981
27990
  }), {
27982
27991
  default: m(() => [
27983
- w(s.$slots, "default"),
27992
+ w(i.$slots, "default"),
27984
27993
  J("div", mb, [
27985
- s.withClearButton && r(o).modelValue.value && (Array.isArray(r(o).modelValue.value) ? r(o).modelValue.value.length > 0 : r(o).modelValue.value !== "") ? (h(), R("div", {
27994
+ i.withClearButton && s.value ? (h(), R("div", {
27986
27995
  key: 0,
27987
27996
  role: "button",
27988
27997
  class: "text-muted-foreground hover:text-foreground z-10 cursor-pointer transition-colors",
27989
- onPointerdown: i[0] || (i[0] = ke(() => {
27998
+ onPointerdown: u[0] || (u[0] = ke(() => {
27990
27999
  }, ["stop"])),
27991
28000
  onClick: l
27992
28001
  }, [
@@ -1 +1 @@
1
- {"version":3,"file":"SelectTrigger.vue.d.ts","sourceRoot":"","sources":["../../src/select/SelectTrigger.vue"],"names":[],"mappings":"AA0EA,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,SAAS,CAAA;AAEjD,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,KAAK,CAAA;AAEzC,KAAK,WAAW,GAAG,kBAAkB,GAAG;IAAE,KAAK,CAAC,EAAE,cAAc,CAAC,OAAO,CAAC,CAAC;IAAC,eAAe,CAAC,EAAE,OAAO,CAAA;CAAE,CAAC;AA6BvG,iBAAS,cAAc;WA+FT,OAAO,IAA6B;;yBAVrB,GAAG;;;;EAe/B;AAiBD,KAAK,oBAAoB,GAAG,UAAU,CAAC,OAAO,cAAc,CAAC,CAAC;AAC9D,QAAA,MAAM,eAAe;qBAnJwE,OAAO;6EA2JlG,CAAC;wBACkB,uBAAuB,CAAC,OAAO,eAAe,EAAE,oBAAoB,CAAC,OAAO,CAAC,CAAC;AAAnG,wBAAoG;AAapG,KAAK,uBAAuB,CAAC,CAAC,EAAE,CAAC,IAAI,CAAC,GAAG;IACxC,QAAO;QACN,MAAM,EAAE,CAAC,CAAC;KAEV,CAAA;CACD,CAAC"}
1
+ {"version":3,"file":"SelectTrigger.vue.d.ts","sourceRoot":"","sources":["../../src/select/SelectTrigger.vue"],"names":[],"mappings":"AA4EA,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,SAAS,CAAA;AAEjD,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,KAAK,CAAA;AAGzC,KAAK,WAAW,GAAG,kBAAkB,GAAG;IAAE,KAAK,CAAC,EAAE,cAAc,CAAC,OAAO,CAAC,CAAC;IAAC,eAAe,CAAC,EAAE,OAAO,CAAA;CAAE,CAAC;AAoCvG,iBAAS,cAAc;WAyFT,OAAO,IAA6B;;yBAVrB,GAAG;;;;EAe/B;AAiBD,KAAK,oBAAoB,GAAG,UAAU,CAAC,OAAO,cAAc,CAAC,CAAC;AAC9D,QAAA,MAAM,eAAe;qBApJwE,OAAO;6EA4JlG,CAAC;wBACkB,uBAAuB,CAAC,OAAO,eAAe,EAAE,oBAAoB,CAAC,OAAO,CAAC,CAAC;AAAnG,wBAAoG;AAapG,KAAK,uBAAuB,CAAC,CAAC,EAAE,CAAC,IAAI,CAAC,GAAG;IACxC,QAAO;QACN,MAAM,EAAE,CAAC,CAAC;KAEV,CAAA;CACD,CAAC"}
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@agrotools1/at-components",
3
3
  "type": "module",
4
- "version": "2.0.5",
4
+ "version": "2.0.6",
5
5
  "private": false,
6
6
  "description": "Componentes da Agrotools - Versão 2 (com re-export da V1)",
7
7
  "author": "Agrotools",