@plurix/ecom-components 1.14.0-loyalty.2 → 1.14.1-loyalty

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,38 +1,39 @@
1
- import { jsxs as o, Fragment as h, jsx as e } from "react/jsx-runtime";
2
- import { useRef as f, useState as v, useEffect as b } from "react";
3
- import { Title as S } from "../components/Title.js";
1
+ import { jsxs as l, Fragment as f, jsx as e } from "react/jsx-runtime";
2
+ import { useRef as v, useState as S, useEffect as u } from "react";
3
+ import { Title as b } from "../components/Title.js";
4
4
  import { PickupPoint as w } from "../components/PickupPoint.js";
5
- import { GlassIcon as x } from "../../../assets/svgs/GlassIcon.js";
6
- import { SetViewButton as N } from "../components/SetViewButton.js";
7
- import { ArrowIcon as u } from "../../../assets/svgs/ArrowIcon.js";
8
- import { useRegionalizationContext as C } from "../context/RegionalizationContext.js";
9
- const E = () => {
10
- const { pickup: r, pickupPoints: l, textBackButton: m } = C(), a = f(null), [n, s] = v(l), d = l.length > 0 ? l : [];
11
- b(() => {
12
- s(d);
13
- }, [l]);
5
+ import { GlassIcon as g } from "../../../assets/svgs/GlassIcon.js";
6
+ import { SetViewButton as x } from "../components/SetViewButton.js";
7
+ import { ArrowIcon as F } from "../../../assets/svgs/ArrowIcon.js";
8
+ import { useRegionalizationContext as N } from "../context/RegionalizationContext.js";
9
+ const z = () => {
10
+ const { pickup: r, pickupPoints: t, textBackButton: d } = N(), n = v(null), [s, a] = S(t), m = t.length > 0 ? t : [];
11
+ u(() => {
12
+ console.log("pickupPoints", t), a(m);
13
+ }, [t]);
14
14
  const i = () => {
15
- s(
16
- l == null ? void 0 : l.filter(
17
- ({ name: t }) => {
15
+ var o;
16
+ console.log("handleFilterStores", t), console.log("handleFilterStores", (o = n.current) == null ? void 0 : o.value.toLowerCase()), a(
17
+ t == null ? void 0 : t.filter(
18
+ ({ name: h }) => {
18
19
  var c;
19
- return t.toLowerCase().includes(((c = a.current) == null ? void 0 : c.value.toLowerCase()) || "");
20
+ return h.toLowerCase().includes(((c = n.current) == null ? void 0 : c.value.toLowerCase()) || "");
20
21
  }
21
22
  )
22
23
  );
23
24
  };
24
- return /* @__PURE__ */ o(h, { children: [
25
- /* @__PURE__ */ e(S, { title: r == null ? void 0 : r.title }),
26
- /* @__PURE__ */ o("div", { className: "stores-filter", children: [
25
+ return /* @__PURE__ */ l(f, { children: [
26
+ /* @__PURE__ */ e(b, { title: r == null ? void 0 : r.title }),
27
+ /* @__PURE__ */ l("div", { className: "stores-filter", children: [
27
28
  /* @__PURE__ */ e("p", { children: r == null ? void 0 : r.labelFilter }),
28
- /* @__PURE__ */ o("div", { children: [
29
+ /* @__PURE__ */ l("div", { children: [
29
30
  /* @__PURE__ */ e(
30
31
  "input",
31
32
  {
32
33
  type: "text",
33
34
  placeholder: "Loja",
34
- ref: a,
35
- onKeyDown: (t) => t.key === "Enter" && i()
35
+ ref: n,
36
+ onKeyDown: (o) => o.key === "Enter" && i()
36
37
  }
37
38
  ),
38
39
  /* @__PURE__ */ e(
@@ -40,34 +41,34 @@ const E = () => {
40
41
  {
41
42
  className: "filter-ico-container",
42
43
  onClick: () => i(),
43
- children: /* @__PURE__ */ e(x, {})
44
+ children: /* @__PURE__ */ e(g, {})
44
45
  }
45
46
  )
46
47
  ] }),
47
48
  /* @__PURE__ */ e("div", { className: "divider", children: /* @__PURE__ */ e("span", { children: r == null ? void 0 : r.divider }) })
48
49
  ] }),
49
50
  /* @__PURE__ */ e("p", { className: "stores-label", children: r == null ? void 0 : r.labelStores }),
50
- /* @__PURE__ */ e("div", { className: "stores-container", children: n == null ? void 0 : n.map((t) => /* @__PURE__ */ e(
51
+ /* @__PURE__ */ e("div", { className: "stores-container", children: s == null ? void 0 : s.map((o) => /* @__PURE__ */ e(
51
52
  w,
52
53
  {
53
- pickupPointInfos: t
54
+ pickupPointInfos: o
54
55
  },
55
- t == null ? void 0 : t.id
56
+ o == null ? void 0 : o.id
56
57
  )) }),
57
58
  /* @__PURE__ */ e("br", {}),
58
- /* @__PURE__ */ o(
59
- N,
59
+ /* @__PURE__ */ l(
60
+ x,
60
61
  {
61
62
  view: "PickupPointInfoScreen",
62
63
  className: "back-button-all-store",
63
64
  children: [
64
- /* @__PURE__ */ e("span", { children: /* @__PURE__ */ e(u, { color: "var(--color-main)" }) }),
65
- m
65
+ /* @__PURE__ */ e("span", { children: /* @__PURE__ */ e(F, { color: "var(--color-main)" }) }),
66
+ d
66
67
  ]
67
68
  }
68
69
  )
69
70
  ] });
70
71
  };
71
72
  export {
72
- E as AllStoresScreen
73
+ z as AllStoresScreen
73
74
  };
package/package.json CHANGED
@@ -2,7 +2,7 @@
2
2
  "name": "@plurix/ecom-components",
3
3
  "author": "Plurix",
4
4
  "private": false,
5
- "version": "1.14.0-loyalty.2",
5
+ "version": "1.14.1-loyalty",
6
6
  "type": "module",
7
7
  "main": "dist/main.js",
8
8
  "types": "dist/main.d.ts",