@lucian-seo/lucian-ui 0.1.1 → 0.1.2

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.
package/README.md CHANGED
@@ -30,7 +30,7 @@ GitHub Actions는 브라우저 실행 없이 타입, Gallery/library build와
30
30
  위 React·화면 조작 검증은 과거 기록이며 현재 CI가 매번 수행하는 검사는 아닙니다.
31
31
  UI 검증은 지정한 Windows Chrome runner에서 별도로 진행합니다.
32
32
 
33
- `@lucian-seo/lucian-ui`는 npmjs.com 공개 배포를 준비 중입니다. 첫 배포 후에는 누구나
33
+ `@lucian-seo/lucian-ui`는 npmjs.com에 MIT 라이선스로 공개되어 있습니다. 현재 버전은 `0.1.1`이며 누구나
34
34
  별도 token이나 private registry 설정 없이 설치할 수 있습니다. 기존 프로젝트에 GitHub/GitLab
35
35
  scope registry 설정이 있다면 제거하거나 npmjs.com으로 바꾸세요.
36
36
 
@@ -38,7 +38,7 @@ scope registry 설정이 있다면 제거하거나 npmjs.com으로 바꾸세요.
38
38
  npm install @lucian-seo/lucian-ui
39
39
  ```
40
40
 
41
- 실제 npm 계정의 scope 권한과 라이선스는 아직 확인 중입니다. 첫 등록과 이후 자동 배포 절차는
41
+ npm 계정 `lucian-seo`로 첫 등록을 완료했습니다. 이후 자동 배포 연결 절차는
42
42
  [공개 npm 배포 가이드](docs/NPM-PUBLISH.md)를 참고하세요. GitHub 저장소의 공개 여부와 npm
43
43
  패키지의 공개 여부는 별도로 설정합니다.
44
44
 
@@ -515,7 +515,7 @@ function ee({ options: e, value: t, onValueChange: n, label: o, placeholder: l,
515
515
  }, J = (e) => {
516
516
  n(t.filter((t) => t !== e)), N.current?.focus();
517
517
  }, Y = (e) => {
518
- if (!v && !e.nativeEvent.isComposing) {
518
+ if (!v && !(e.nativeEvent.isComposing || e.nativeEvent.keyCode === 229)) {
519
519
  if (e.key === "Backspace" && I === "" && t.length > 0) {
520
520
  e.preventDefault(), n(t.slice(0, -1));
521
521
  return;
@@ -877,8 +877,18 @@ function ie({ children: e, as: t = "div", columns: n, min: r, gap: i = 4, classN
877
877
  function $(e, t, n) {
878
878
  return n === t ? 0 : Math.min(1, Math.max(0, (e - t) / (n - t)));
879
879
  }
880
- function ae({ value: e, onValueChange: t, min: n = 0, max: r = 100, step: i = 1, label: a, size: o = "md", disabled: l, invalid: u, name: d, marks: f, formatValue: p, id: m, className: h, required: g, "aria-labelledby": _, "aria-describedby": v, ...y }) {
881
- let b = p ? p(e) : String(e), x = $(e, n, r);
880
+ function ae(e, t, n, r) {
881
+ if (n <= t) return t;
882
+ let i = Math.min(n, Math.max(t, e)), a = Number.isFinite(r) && r > 0 ? r : 1, o = (i - t) / a, s = (n - t) / a;
883
+ if (!Number.isFinite(o) || !Number.isFinite(s)) return i;
884
+ let c = (e) => 2 ** -52 * Math.max(1, Math.abs(e)) * 4, l = t + Math.min(Math.round(o + c(o)), Math.floor(s + c(s))) * a, u = (e) => {
885
+ let [t, n = "0"] = String(e).toLowerCase().split("e");
886
+ return Math.max(0, (t.split(".")[1] ?? "").length - Number(n));
887
+ }, d = Math.max(u(t), u(a));
888
+ return d > 100 ? l : Number(l.toFixed(d));
889
+ }
890
+ function oe({ value: e, onValueChange: t, min: n = 0, max: r = 100, step: i = 1, label: a, size: o = "md", disabled: l, invalid: u, name: d, marks: f, formatValue: p, id: m, className: h, required: g, "aria-labelledby": _, "aria-describedby": v, ...y }) {
891
+ let b = ae(e, n, r, i), x = p ? p(b) : String(b), S = $(b, n, r);
882
892
  return /* @__PURE__ */ c("span", {
883
893
  "data-size": o,
884
894
  "data-disabled": l ? "" : void 0,
@@ -896,14 +906,14 @@ function ae({ value: e, onValueChange: t, min: n = 0, max: r = 100, step: i = 1,
896
906
  /* @__PURE__ */ s("span", {
897
907
  className: "slider__fill",
898
908
  "aria-hidden": "true",
899
- style: { "--slider-fill": x }
909
+ style: { "--slider-fill": S }
900
910
  }),
901
- f?.map((t) => /* @__PURE__ */ s("span", {
911
+ f?.map((e) => /* @__PURE__ */ s("span", {
902
912
  className: "slider__tick",
903
913
  "aria-hidden": "true",
904
- "data-passed": t.value <= e ? "" : void 0,
905
- style: { "--slider-mark": $(t.value, n, r) }
906
- }, t.value)),
914
+ "data-passed": e.value <= b ? "" : void 0,
915
+ style: { "--slider-mark": $(e.value, n, r) }
916
+ }, e.value)),
907
917
  /* @__PURE__ */ s("input", {
908
918
  "data-part": "control",
909
919
  ...y,
@@ -914,14 +924,14 @@ function ae({ value: e, onValueChange: t, min: n = 0, max: r = 100, step: i = 1,
914
924
  min: n,
915
925
  max: r,
916
926
  step: i,
917
- value: e,
927
+ value: b,
918
928
  disabled: l,
919
929
  "aria-label": _ ? void 0 : a,
920
930
  "aria-labelledby": _,
921
931
  "aria-describedby": v,
922
932
  "aria-required": g || void 0,
923
933
  "aria-invalid": u || void 0,
924
- "aria-valuetext": b,
934
+ "aria-valuetext": x,
925
935
  onChange: (e) => t(Number(e.target.value))
926
936
  })
927
937
  ]
@@ -929,7 +939,7 @@ function ae({ value: e, onValueChange: t, min: n = 0, max: r = 100, step: i = 1,
929
939
  /* @__PURE__ */ s("span", {
930
940
  className: "slider__readout",
931
941
  "aria-hidden": "true",
932
- children: b
942
+ children: x
933
943
  }),
934
944
  f?.some((e) => e.label !== void 0) ? /* @__PURE__ */ s("span", {
935
945
  className: "slider__marks",
@@ -945,7 +955,7 @@ function ae({ value: e, onValueChange: t, min: n = 0, max: r = 100, step: i = 1,
945
955
  }
946
956
  //#endregion
947
957
  //#region src/components/common/Space/Space.tsx
948
- function oe({ size: e = 4, axis: t = "block", as: n = "div", className: r, ...i }) {
958
+ function se({ size: e = 4, axis: t = "block", as: n = "div", className: r, ...i }) {
949
959
  return /* @__PURE__ */ s(n, {
950
960
  "data-size": e,
951
961
  "data-axis": t,
@@ -956,7 +966,7 @@ function oe({ size: e = 4, axis: t = "block", as: n = "div", className: r, ...i
956
966
  }
957
967
  //#endregion
958
968
  //#region src/components/common/Stack/Stack.tsx
959
- function se({ children: e, gap: t = 4, align: n = "stretch", justify: r = "start", as: i = "div", className: a, ...o }) {
969
+ function ce({ children: e, gap: t = 4, align: n = "stretch", justify: r = "start", as: i = "div", className: a, ...o }) {
960
970
  return /* @__PURE__ */ s(i, {
961
971
  "data-gap": t,
962
972
  "data-align": n,
@@ -968,7 +978,7 @@ function se({ children: e, gap: t = 4, align: n = "stretch", justify: r = "start
968
978
  }
969
979
  //#endregion
970
980
  //#region src/components/common/Switch/Switch.tsx
971
- function ce({ children: e, size: t = "md", disabled: n, className: r, ...i }) {
981
+ function le({ children: e, size: t = "md", disabled: n, className: r, ...i }) {
972
982
  return /* @__PURE__ */ c("label", {
973
983
  className: `switch ${r ?? ""}`.trim(),
974
984
  "data-size": t,
@@ -994,6 +1004,6 @@ function ce({ children: e, size: t = "md", disabled: n, className: r, ...i }) {
994
1004
  });
995
1005
  }
996
1006
  //#endregion
997
- export { x as A, N as C, k as D, A as E, O, I as S, j as T, H as _, ie as a, R as b, te as c, Y as d, J as f, U as g, W as h, ae as i, S as k, ee as l, K as m, se as n, re as o, q as p, oe as r, ne as s, ce as t, X as u, V as v, M as w, L as x, B as y };
1007
+ export { x as A, N as C, k as D, A as E, O, I as S, j as T, H as _, ie as a, R as b, te as c, Y as d, J as f, U as g, W as h, oe as i, S as k, ee as l, K as m, ce as n, re as o, q as p, se as r, ne as s, le as t, X as u, V as v, M as w, L as x, B as y };
998
1008
 
999
- //# sourceMappingURL=Switch-BkMnC02l.js.map
1009
+ //# sourceMappingURL=Switch-CMllJkGp.js.map