@floegence/floe-webapp-core 0.14.2 → 0.14.3

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 (2) hide show
  1. package/dist/index24.js +27 -23
  2. package/package.json +1 -1
package/dist/index24.js CHANGED
@@ -1,9 +1,9 @@
1
- import { delegateEvents as j, setAttribute as I, insert as m, createComponent as d, Portal as B, effect as E, className as S, setStyleProperty as _, template as C, memo as A, use as L } from "solid-js/web";
2
- import { createSignal as O, createEffect as D, onCleanup as N, Show as y, For as W } from "solid-js";
1
+ import { delegateEvents as D, setAttribute as O, insert as m, createComponent as d, Portal as B, effect as E, className as S, setStyleProperty as _, template as C, memo as A, use as I } from "solid-js/web";
2
+ import { createSignal as L, createEffect as F, onCleanup as N, Show as y, Index as W } from "solid-js";
3
3
  import { cn as p } from "./index110.js";
4
4
  import { deferNonBlocking as z } from "./index111.js";
5
5
  import { ChevronDown as G, Check as V, ChevronRight as J } from "./index40.js";
6
- var q = /* @__PURE__ */ C("<div role=menu>"), K = /* @__PURE__ */ C("<div><div class=cursor-pointer>"), F = /* @__PURE__ */ C('<div class="my-1 h-px bg-border"role=separator>'), Q = /* @__PURE__ */ C("<div>"), U = /* @__PURE__ */ C('<button type=button role=menuitem><span class="w-3.5 h-3.5 flex items-center justify-center"></span><span class="flex-1 text-left">'), X = /* @__PURE__ */ C("<div class=relative>"), Y = /* @__PURE__ */ C('<span class="w-3.5 h-3.5 flex items-center justify-center">'), Z = /* @__PURE__ */ C("<button type=button><span>");
6
+ var q = /* @__PURE__ */ C("<div role=menu>"), K = /* @__PURE__ */ C("<div><div class=cursor-pointer>"), H = /* @__PURE__ */ C('<div class="my-1 h-px bg-border"role=separator>'), Q = /* @__PURE__ */ C("<div>"), U = /* @__PURE__ */ C('<button type=button role=menuitem><span class="w-3.5 h-3.5 flex items-center justify-center"></span><span class="flex-1 text-left">'), X = /* @__PURE__ */ C("<div class=relative>"), Y = /* @__PURE__ */ C('<span class="w-3.5 h-3.5 flex items-center justify-center">'), Z = /* @__PURE__ */ C("<button type=button><span>");
7
7
  const h = 8;
8
8
  let R = 0;
9
9
  function ee(e, r, c) {
@@ -42,7 +42,7 @@ function te(e, r) {
42
42
  };
43
43
  }
44
44
  function ne(e) {
45
- const [r, c] = O(!1), [i, a] = O({
45
+ const [r, c] = L(!1), [i, a] = L({
46
46
  x: -9999,
47
47
  y: -9999
48
48
  });
@@ -52,7 +52,7 @@ function ne(e) {
52
52
  const f = n.getBoundingClientRect(), v = l.getBoundingClientRect(), b = ee(f, v, e.align ?? "start");
53
53
  a(b);
54
54
  };
55
- D(() => {
55
+ F(() => {
56
56
  if (!r()) {
57
57
  a({
58
58
  x: -9999,
@@ -76,9 +76,9 @@ function ne(e) {
76
76
  };
77
77
  return (() => {
78
78
  var f = K(), v = f.firstChild;
79
- I(f, "data-floe-dropdown", s), v.$$click = () => c((o) => !o);
79
+ O(f, "data-floe-dropdown", s), v.$$click = () => c((o) => !o);
80
80
  var b = n;
81
- return typeof b == "function" ? L(b, v) : n = v, m(v, () => e.trigger), m(f, d(y, {
81
+ return typeof b == "function" ? I(b, v) : n = v, m(v, () => e.trigger), m(f, d(y, {
82
82
  get when() {
83
83
  return r();
84
84
  },
@@ -86,22 +86,24 @@ function ne(e) {
86
86
  return d(B, {
87
87
  get children() {
88
88
  var o = q(), x = l;
89
- return typeof x == "function" ? L(x, o) : l = o, I(o, "data-floe-dropdown", s), m(o, d(W, {
89
+ return typeof x == "function" ? I(x, o) : l = o, O(o, "data-floe-dropdown", s), m(o, d(W, {
90
90
  get each() {
91
91
  return e.items;
92
92
  },
93
93
  children: (t) => d(y, {
94
94
  get when() {
95
- return !t.separator;
95
+ return !t().separator;
96
96
  },
97
97
  get fallback() {
98
- return F();
98
+ return H();
99
99
  },
100
100
  get children() {
101
- return d(H, {
102
- item: t,
101
+ return d(j, {
102
+ get item() {
103
+ return t();
104
+ },
103
105
  get selected() {
104
- return e.value === t.id;
106
+ return e.value === t().id;
105
107
  },
106
108
  onSelect: P,
107
109
  onCloseMenu: () => c(!1),
@@ -123,8 +125,8 @@ function ne(e) {
123
125
  }), null), E(() => S(f, p("relative inline-block", e.class))), f;
124
126
  })();
125
127
  }
126
- function H(e) {
127
- const [r, c] = O(!1), [i, a] = O({
128
+ function j(e) {
129
+ const [r, c] = L(!1), [i, a] = L({
128
130
  x: -9999,
129
131
  y: -9999
130
132
  });
@@ -154,7 +156,7 @@ function H(e) {
154
156
  var o = X();
155
157
  o.addEventListener("mouseleave", v), o.addEventListener("mouseenter", f);
156
158
  var x = n;
157
- return typeof x == "function" ? L(x, o) : n = o, m(o, d(y, {
159
+ return typeof x == "function" ? I(x, o) : n = o, m(o, d(y, {
158
160
  get when() {
159
161
  return e.item.content;
160
162
  },
@@ -215,20 +217,22 @@ function H(e) {
215
217
  clearTimeout(s);
216
218
  });
217
219
  var $ = l;
218
- return typeof $ == "function" ? L($, t) : l = t, m(t, d(W, {
220
+ return typeof $ == "function" ? I($, t) : l = t, m(t, d(W, {
219
221
  get each() {
220
222
  return e.item.children;
221
223
  },
222
224
  children: (u) => d(y, {
223
225
  get when() {
224
- return !u.separator;
226
+ return !u().separator;
225
227
  },
226
228
  get fallback() {
227
- return F();
229
+ return H();
228
230
  },
229
231
  get children() {
230
- return d(H, {
231
- item: u,
232
+ return d(j, {
233
+ get item() {
234
+ return u();
235
+ },
232
236
  selected: !1,
233
237
  get onSelect() {
234
238
  return e.onSelect;
@@ -244,7 +248,7 @@ function H(e) {
244
248
  })
245
249
  })), E((u) => {
246
250
  var w = p("fixed z-50 min-w-36 py-0.5", "bg-popover text-popover-foreground", "rounded border border-border shadow-md", "animate-in fade-in slide-in-from-left-1"), k = e.dropdownId, M = `${i().x}px`, T = `${i().y}px`;
247
- return w !== u.e && S(t, u.e = w), k !== u.t && I(t, "data-floe-dropdown", u.t = k), M !== u.a && _(t, "left", u.a = M), T !== u.o && _(t, "top", u.o = T), u;
251
+ return w !== u.e && S(t, u.e = w), k !== u.t && O(t, "data-floe-dropdown", u.t = k), M !== u.a && _(t, "left", u.a = M), T !== u.o && _(t, "top", u.o = T), u;
248
252
  }, {
249
253
  e: void 0,
250
254
  t: void 0,
@@ -289,7 +293,7 @@ function ae(e) {
289
293
  }
290
294
  });
291
295
  }
292
- j(["click"]);
296
+ D(["click"]);
293
297
  export {
294
298
  ne as Dropdown,
295
299
  ae as Select
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@floegence/floe-webapp-core",
3
- "version": "0.14.2",
3
+ "version": "0.14.3",
4
4
  "type": "module",
5
5
  "main": "./dist/index.js",
6
6
  "module": "./dist/index.js",