@wikicasa-dev/components 2.1.9 → 2.1.10

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,19 +1,19 @@
1
- import { defineComponent as O, mergeModels as V, useModel as A, computed as s, createElementBlock as o, openBlock as r, createCommentVNode as k, createElementVNode as P, createBlock as c, resolveDynamicComponent as m, mergeProps as h, withCtx as f, createVNode as M, unref as $, toDisplayString as d, Fragment as w, createTextVNode as g, renderList as j } from "vue";
1
+ import { defineComponent as O, mergeModels as V, useModel as A, computed as s, createElementBlock as o, openBlock as r, createCommentVNode as k, createElementVNode as x, createBlock as c, resolveDynamicComponent as m, mergeProps as h, withCtx as f, createVNode as M, unref as $, toDisplayString as d, Fragment as w, createTextVNode as g, renderList as j } from "vue";
2
2
  import { ArrowIcon as B } from "../../../../node_modules/.pnpm/@wikicasa-dev_svg-icons@1.2.11_typescript@5.8.3/node_modules/@wikicasa-dev/svg-icons/dist/ArrowIcon.js";
3
3
  import "../../../../node_modules/.pnpm/@wikicasa-dev_svg-icons@1.2.11_typescript@5.8.3/node_modules/@wikicasa-dev/svg-icons/dist/PharmacyIcon.js";
4
- const E = {
4
+ const Q = {
5
5
  "aria-label": "Page navigation",
6
6
  class: "uikit-overflow-auto"
7
- }, Q = {
7
+ }, E = {
8
8
  key: 0,
9
9
  class: "uikit-text-14 uikit-m-0 uikit-flex uikit-list-none uikit-content-center uikit-gap-4 uikit-p-0 uikit-pl-0 uikit-font-semibold sm:uikit-gap-5"
10
- }, R = ["data-cy"], G = {
10
+ }, R = ["data-cy"], q = {
11
11
  key: 0,
12
12
  class: "uikit-mx-10px uikit-select-none"
13
- }, q = {
13
+ }, z = {
14
14
  key: 1,
15
15
  class: "font-weight-bold uikit-flex uikit-h-30px uikit-min-w-[30px] uikit-cursor-pointer uikit-select-none uikit-items-center uikit-justify-center uikit-rounded-circle uikit-p-5px hover:uikit-bg-w-primary hover:uikit-text-white"
16
- }, z = ["onClick"], H = ["onClick"], J = {
16
+ }, G = ["onClick"], H = ["onClick"], J = {
17
17
  key: 0,
18
18
  class: "uikit-flex uikit-h-30px uikit-min-w-[30px] uikit-cursor-pointer uikit-select-none uikit-items-center uikit-justify-center uikit-rounded-circle uikit-p-5px hover:uikit-bg-w-primary hover:uikit-text-white"
19
19
  }, K = ["data-cy"], W = {
@@ -43,7 +43,7 @@ const E = {
43
43
  }),
44
44
  emits: ["update:pageNumber"],
45
45
  setup(l) {
46
- const u = A(l, "pageNumber"), y = s(() => (u.value || 1) + 1), b = s(() => (u.value || 1) - 1), v = s(() => l.baseUrl ? l.linkTag : "span"), a = s(() => Math.ceil((l.count + l.additionalCount) / l.limit)), D = (e = 1) => e < 1, S = (e = 1) => e === a.value, x = s(() => (u.value || 0) > l.siblings + 2), C = s(
46
+ const u = A(l, "pageNumber"), y = s(() => (u.value || 1) + 1), b = s(() => (u.value || 1) - 1), v = s(() => l.baseUrl ? l.linkTag : "span"), a = s(() => Math.ceil((l.count + l.additionalCount) / l.limit)), D = (e = 1) => e < 1, S = (e = 1) => e === a.value, P = s(() => (u.value || 0) > l.siblings + 2), C = s(
47
47
  () => (u.value || 0) < a.value - l.siblings - 1
48
48
  ), N = s(() => {
49
49
  let i = u.value || 0, t = 0;
@@ -67,7 +67,7 @@ const E = {
67
67
  }), T = s(() => {
68
68
  const e = L.value + /* Filling with the remaining left siblings */
69
69
  Math.abs(N.value - l.siblings) + /* If there is no suspension points on the left, let's fill it */
70
- new Number(!x.value).valueOf() + /* If the pageNumber is the same of the firstPage, let's fill it */
70
+ new Number(!P.value).valueOf() + /* If the pageNumber is the same of the firstPage, let's fill it */
71
71
  new Number(u.value === 1).valueOf();
72
72
  let i = Math.min(u.value || 0, a.value - 1);
73
73
  const t = [];
@@ -75,7 +75,7 @@ const E = {
75
75
  t.push(i + 1);
76
76
  return t;
77
77
  }), p = (e) => {
78
- console.log("DEBUG:selectPage", { _pageIdx: e }), !(e < 1 || e > a.value) && setTimeout(() => {
78
+ e < 1 || e > a.value || setTimeout(() => {
79
79
  u.value = e;
80
80
  });
81
81
  }, n = (e = 1) => {
@@ -88,16 +88,16 @@ const E = {
88
88
  return;
89
89
  }
90
90
  };
91
- return (e, i) => (r(), o("nav", E, [
92
- e.count > 0 ? (r(), o("ul", Q, [
93
- P("li", {
91
+ return (e, i) => (r(), o("nav", Q, [
92
+ e.count > 0 ? (r(), o("ul", E, [
93
+ x("li", {
94
94
  "data-cy": e.prevDataCy,
95
95
  onClick: i[0] || (i[0] = (t) => p(b.value))
96
96
  }, [
97
97
  (r(), c(m(D(b.value) ? "span" : v.value), h({
98
98
  href: n(b.value),
99
99
  to: n(b.value),
100
- class: ["arrow-button prev-page uikit-h-30px uikit-flex uikit-min-w-[30px] uikit-items-center uikit-justify-center uikit-rounded-circle uikit-p-5px", {
100
+ class: ["arrow-button prev-page uikit-flex uikit-h-30px uikit-min-w-[30px] uikit-items-center uikit-justify-center uikit-rounded-circle uikit-p-5px", {
101
101
  "uikit-cursor-pointer hover:uikit-bg-w-primary [&_svg]:hover:uikit-brightness-0 [&_svg]:hover:uikit-invert": u.value !== 1,
102
102
  "hover:uikit-text-white": e.small && u.value !== 1,
103
103
  "uikit-rounded-xs": e.small && e.prevLabel
@@ -110,7 +110,7 @@ const E = {
110
110
  "stroke-color": u.value === 1 ? "#8996A9" : e.arrowColor,
111
111
  class: "uikit-inline-block uikit-rotate-90"
112
112
  }, null, 8, ["stroke-color"]),
113
- e.small && e.prevLabel ? (r(), o("span", G, d(e.prevLabel), 1)) : k("", !0)
113
+ e.small && e.prevLabel ? (r(), o("span", q, d(e.prevLabel), 1)) : k("", !0)
114
114
  ]),
115
115
  _: 1
116
116
  }, 16, ["href", "to", "class"]))
@@ -131,7 +131,7 @@ const E = {
131
131
  _: 1
132
132
  }, 16, ["href", "to"]))
133
133
  ])) : k("", !0),
134
- x.value ? (r(), o("li", q, " ... ")) : k("", !0),
134
+ P.value ? (r(), o("li", z, " ... ")) : k("", !0),
135
135
  (r(!0), o(w, null, j(U.value, (t) => (r(), o("li", {
136
136
  key: t,
137
137
  onClick: (F) => p(t)
@@ -147,9 +147,9 @@ const E = {
147
147
  ]),
148
148
  _: 2
149
149
  }, 1040, ["href", "to"]))
150
- ], 8, z))), 128))
150
+ ], 8, G))), 128))
151
151
  ], 64)),
152
- P("li", null, [
152
+ x("li", null, [
153
153
  (r(), c(m(v.value), h({
154
154
  href: n(u.value),
155
155
  to: n(u.value),
@@ -171,7 +171,7 @@ const E = {
171
171
  (r(), c(m(v.value), h({
172
172
  href: n(t),
173
173
  to: n(t),
174
- class: "uikit-flex uikit-h-30px uikit-min-w-[30px] uikit-text-w-black uikit-cursor-pointer uikit-select-none uikit-items-center uikit-justify-center uikit-rounded-circle uikit-p-5px uikit-no-underline hover:uikit-bg-w-primary hover:uikit-text-white",
174
+ class: "uikit-flex uikit-h-30px uikit-min-w-[30px] uikit-cursor-pointer uikit-select-none uikit-items-center uikit-justify-center uikit-rounded-circle uikit-p-5px uikit-text-w-black uikit-no-underline hover:uikit-bg-w-primary hover:uikit-text-white",
175
175
  ref_for: !0
176
176
  }, e.linkProps), {
177
177
  default: f(() => [
@@ -197,7 +197,7 @@ const E = {
197
197
  }, 16, ["href", "to"]))
198
198
  ])) : k("", !0)
199
199
  ], 64)),
200
- P("li", {
200
+ x("li", {
201
201
  "data-cy": e.nextDataCy,
202
202
  onClick: i[3] || (i[3] = (t) => p(y.value))
203
203
  }, [
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@wikicasa-dev/components",
3
- "version": "2.1.9",
3
+ "version": "2.1.10",
4
4
  "description": "Wikicasa frontend components",
5
5
  "type": "module",
6
6
  "main": "./dist/index.js",