@ryuzaki13/react-foundation-ui 3.4.3 → 3.5.0
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/dist/badge/index.js +65 -2
- package/dist/badge/index.js.map +1 -0
- package/dist/barcode-scanner/index.js +18 -18
- package/dist/base-table/index.js +2 -2
- package/dist/button/index.js +1 -1
- package/dist/check-box/index.js +1 -1
- package/dist/chunks/{CalendarView-Dm55k0bN.js → CalendarView-CwbPJG2Y.js} +86 -86
- package/dist/chunks/{CalendarView-Dm55k0bN.js.map → CalendarView-CwbPJG2Y.js.map} +1 -1
- package/dist/chunks/{ImageViewerRuntime-HGBWp9NM.js → ImageViewerRuntime-DZpgxzF1.js} +25 -25
- package/dist/chunks/{ImageViewerRuntime-HGBWp9NM.js.map → ImageViewerRuntime-DZpgxzF1.js.map} +1 -1
- package/dist/chunks/{TextEditorLexicalClient-C8nSoz85.js → TextEditorLexicalClient-BRp8jHId.js} +354 -354
- package/dist/chunks/{TextEditorLexicalClient-C8nSoz85.js.map → TextEditorLexicalClient-BRp8jHId.js.map} +1 -1
- package/dist/chunks/{base-table-BWvKfI2W.js → base-table-BHmboNzl.js} +138 -138
- package/dist/chunks/{base-table-BWvKfI2W.js.map → base-table-BHmboNzl.js.map} +1 -1
- package/dist/chunks/{button-DF21yxVp.js → button-D7GAU2Wa.js} +20 -20
- package/dist/chunks/{button-DF21yxVp.js.map → button-D7GAU2Wa.js.map} +1 -1
- package/dist/chunks/{check-box-CZyhzmR0.js → check-box-D_Y6iIWv.js} +19 -19
- package/dist/chunks/{check-box-CZyhzmR0.js.map → check-box-D_Y6iIWv.js.map} +1 -1
- package/dist/chunks/{context-menu-DgvXGCuI.js → context-menu-BQePxRpu.js} +159 -159
- package/dist/chunks/{context-menu-DgvXGCuI.js.map → context-menu-BQePxRpu.js.map} +1 -1
- package/dist/chunks/{date-input-D7aBsPJc.js → date-input-Crijdmmq.js} +67 -67
- package/dist/chunks/{date-input-D7aBsPJc.js.map → date-input-Crijdmmq.js.map} +1 -1
- package/dist/chunks/{date-range-preset-select-BLnY47cv.js → date-range-preset-select-CyzGMvVp.js} +6 -6
- package/dist/chunks/{date-range-preset-select-BLnY47cv.js.map → date-range-preset-select-CyzGMvVp.js.map} +1 -1
- package/dist/chunks/{dialog-1Z1zCNCe.js → dialog-BcQGVNbu.js} +13 -13
- package/dist/chunks/{dialog-1Z1zCNCe.js.map → dialog-BcQGVNbu.js.map} +1 -1
- package/dist/chunks/{flex-C7njxZ74.js → flex-DtXK7OM4.js} +29 -29
- package/dist/chunks/{flex-C7njxZ74.js.map → flex-DtXK7OM4.js.map} +1 -1
- package/dist/chunks/{floating-arrow-DPKwJfww.js → floating-arrow-DKUKx2ZQ.js} +7 -7
- package/dist/chunks/{floating-arrow-DPKwJfww.js.map → floating-arrow-DKUKx2ZQ.js.map} +1 -1
- package/dist/chunks/{input-DSPKgiCK.js → input-CuRK9Vbz.js} +78 -78
- package/dist/chunks/{input-DSPKgiCK.js.map → input-CuRK9Vbz.js.map} +1 -1
- package/dist/chunks/{input-files-tIS17-zX.js → input-files-B8j6Pb_M.js} +31 -31
- package/dist/chunks/{input-files-tIS17-zX.js.map → input-files-B8j6Pb_M.js.map} +1 -1
- package/dist/chunks/{misc-DeGboAt-.js → misc-CGQOXXCy.js} +110 -110
- package/dist/chunks/{misc-DeGboAt-.js.map → misc-CGQOXXCy.js.map} +1 -1
- package/dist/chunks/{modal-dplfAaER.js → modal-febBsMyR.js} +58 -58
- package/dist/chunks/{modal-dplfAaER.js.map → modal-febBsMyR.js.map} +1 -1
- package/dist/chunks/{picker-lvm82d0A.js → picker-BA6okKnz.js} +91 -91
- package/dist/chunks/{picker-lvm82d0A.js.map → picker-BA6okKnz.js.map} +1 -1
- package/dist/chunks/popover-yl5DVe06.js +245 -0
- package/dist/chunks/{popover-Bne-Ljbs.js.map → popover-yl5DVe06.js.map} +1 -1
- package/dist/chunks/radio-group-CW-K1n9c.js +125 -0
- package/dist/chunks/{radio-group-sSnlYjAX.js.map → radio-group-CW-K1n9c.js.map} +1 -1
- package/dist/chunks/select-DblNSc5H.js +363 -0
- package/dist/chunks/{select-aTGupQan.js.map → select-DblNSc5H.js.map} +1 -1
- package/dist/chunks/{separator-B72Aq-6a.js → separator-CIqnk2z9.js} +2 -2
- package/dist/chunks/{separator-B72Aq-6a.js.map → separator-CIqnk2z9.js.map} +1 -1
- package/dist/chunks/{sortable-BKIwlqhI.js → sortable-CQmMHAF8.js} +38 -38
- package/dist/chunks/{sortable-BKIwlqhI.js.map → sortable-CQmMHAF8.js.map} +1 -1
- package/dist/chunks/{table-DxoSOvQK.js → table-BnvjPaE1.js} +18 -18
- package/dist/chunks/{table-DxoSOvQK.js.map → table-BnvjPaE1.js.map} +1 -1
- package/dist/chunks/{table-column-interactions-DzEvVuXe.js → table-column-interactions-Do8LFtiv.js} +20 -20
- package/dist/chunks/{table-column-interactions-DzEvVuXe.js.map → table-column-interactions-Do8LFtiv.js.map} +1 -1
- package/dist/chunks/{types-D9Wj9wrg.js → types-CxXyru6U.js} +21 -21
- package/dist/chunks/{types-D9Wj9wrg.js.map → types-CxXyru6U.js.map} +1 -1
- package/dist/chunks/{useODataSelectBase-DR4PrY1j.js → useODataSelectBase-DwR4Lfv-.js} +5 -5
- package/dist/chunks/{useODataSelectBase-DR4PrY1j.js.map → useODataSelectBase-DwR4Lfv-.js.map} +1 -1
- package/dist/chunks/{wheel-picker-FS58cRsQ.js → wheel-picker-DUHGy7wE.js} +23 -23
- package/dist/chunks/{wheel-picker-FS58cRsQ.js.map → wheel-picker-DUHGy7wE.js.map} +1 -1
- package/dist/context-menu/index.js +1 -1
- package/dist/date-input/index.js +2 -2
- package/dist/date-range-preset-select/index.js +1 -1
- package/dist/date-time-input/index.js +122 -122
- package/dist/date-time-input/index.js.map +1 -1
- package/dist/detail/index.js +22 -22
- package/dist/dialog/index.js +1 -1
- package/dist/disclosure/index.js +9 -9
- package/dist/drop-zone/index.js +21 -21
- package/dist/errors/index.js +50 -50
- package/dist/expandable-action-panel/index.js +24 -24
- package/dist/flex/index.js +1 -1
- package/dist/flex/useFlexClasses.d.ts +1 -1
- package/dist/floating-arrow/index.js +1 -1
- package/dist/fullscreen-portal/index.js +8 -8
- package/dist/image/index.js +119 -119
- package/dist/input/index.js +1 -1
- package/dist/input-date-time/index.js +55 -55
- package/dist/input-file/index.js +16 -16
- package/dist/input-files/index.js +1 -1
- package/dist/input-image/index.js +17 -17
- package/dist/input-search/index.js +30 -2
- package/dist/input-search/index.js.map +1 -0
- package/dist/layout-picker/index.js +93 -93
- package/dist/layout-picker/index.js.map +1 -1
- package/dist/list/index.js +39 -39
- package/dist/listbox/index.js +33 -33
- package/dist/misc/index.js +1 -1
- package/dist/modal/index.js +1 -1
- package/dist/multi-select/index.js +466 -2
- package/dist/multi-select/index.js.map +1 -0
- package/dist/notifications/index.js +45 -45
- package/dist/option/index.js +30 -30
- package/dist/period-select/index.js +7 -7
- package/dist/picker/index.js +1 -1
- package/dist/popover/index.js +1 -1
- package/dist/preset-range-date-input/index.js +10 -10
- package/dist/preset-select/index.js +1 -1
- package/dist/radio-button/index.js +9 -9
- package/dist/radio-group/index.js +1 -1
- package/dist/select/index.js +1 -1
- package/dist/separator/index.js +1 -1
- package/dist/simple-table/index.js +5 -5
- package/dist/slider/index.js +82 -82
- package/dist/slider/index.js.map +1 -1
- package/dist/sortable/index.js +1 -1
- package/dist/splitter/index.js +55 -55
- package/dist/state-select/index.js +17 -17
- package/dist/styles.css +1 -1
- package/dist/switch/index.js +18 -18
- package/dist/table/index.js +1 -1
- package/dist/table-column-interactions/index.js +1 -1
- package/dist/table-editor/index.js +99 -99
- package/dist/table-sorting/index.js +13 -13
- package/dist/tabs/index.js +83 -83
- package/dist/tag-input/index.js +58 -58
- package/dist/tag-input/index.js.map +1 -1
- package/dist/text/index.js +18 -18
- package/dist/text-editor/index.js +3 -3
- package/dist/textarea/index.js +1 -1
- package/dist/three-scene/index.js +7 -7
- package/dist/toggle/index.js +20 -20
- package/dist/toolbar/index.js +16 -16
- package/dist/tree/index.js +24 -24
- package/dist/tree-select/index.js +189 -189
- package/dist/tree-select/index.js.map +1 -1
- package/dist/tree-table/index.js +33 -33
- package/dist/tree-table/index.js.map +1 -1
- package/dist/wheel-picker/index.js +1 -1
- package/package.json +1 -5
- package/storybook-static/project.json +1 -1
- package/dist/advanced-search/index.d.ts +0 -3
- package/dist/advanced-search/index.d.ts.map +0 -1
- package/dist/advanced-search/index.js +0 -399
- package/dist/advanced-search/index.js.map +0 -1
- package/dist/advanced-search/lib/index.d.ts +0 -2
- package/dist/advanced-search/lib/index.d.ts.map +0 -1
- package/dist/advanced-search/lib/searchParts.d.ts +0 -3
- package/dist/advanced-search/lib/searchParts.d.ts.map +0 -1
- package/dist/advanced-search/model/index.d.ts +0 -5
- package/dist/advanced-search/model/index.d.ts.map +0 -1
- package/dist/advanced-search/model/types.d.ts +0 -55
- package/dist/advanced-search/model/types.d.ts.map +0 -1
- package/dist/advanced-search/model/useAdvancedSearch.d.ts +0 -11
- package/dist/advanced-search/model/useAdvancedSearch.d.ts.map +0 -1
- package/dist/advanced-search/model/useAdvancedSearchInitialSelected.d.ts +0 -6
- package/dist/advanced-search/model/useAdvancedSearchInitialSelected.d.ts.map +0 -1
- package/dist/advanced-search/model/useAdvancedSearchSelection.d.ts +0 -13
- package/dist/advanced-search/model/useAdvancedSearchSelection.d.ts.map +0 -1
- package/dist/advanced-search/ui/AdvancedSearchModal.d.ts +0 -23
- package/dist/advanced-search/ui/AdvancedSearchModal.d.ts.map +0 -1
- package/dist/advanced-search/ui/AdvancedSearchModalSession.d.ts +0 -16
- package/dist/advanced-search/ui/AdvancedSearchModalSession.d.ts.map +0 -1
- package/dist/advanced-search/ui/AdvancedSearchSelect.d.ts +0 -9
- package/dist/advanced-search/ui/AdvancedSearchSelect.d.ts.map +0 -1
- package/dist/advanced-search/ui/AdvancedSearchSelectUI.d.ts +0 -9
- package/dist/advanced-search/ui/AdvancedSearchSelectUI.d.ts.map +0 -1
- package/dist/advanced-search/ui/index.d.ts +0 -2
- package/dist/advanced-search/ui/index.d.ts.map +0 -1
- package/dist/chunks/badge-6mXO9BWP.js +0 -65
- package/dist/chunks/badge-6mXO9BWP.js.map +0 -1
- package/dist/chunks/input-search-Cat4c7SM.js +0 -30
- package/dist/chunks/input-search-Cat4c7SM.js.map +0 -1
- package/dist/chunks/multi-select-BZ9N6Dal.js +0 -466
- package/dist/chunks/multi-select-BZ9N6Dal.js.map +0 -1
- package/dist/chunks/popover-Bne-Ljbs.js +0 -245
- package/dist/chunks/radio-group-sSnlYjAX.js +0 -125
- package/dist/chunks/select-aTGupQan.js +0 -363
package/dist/slider/index.js
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import { n as e, r as t } from "../chunks/popover-
|
|
1
|
+
import { n as e, r as t } from "../chunks/popover-yl5DVe06.js";
|
|
2
2
|
import { t as n } from "../chunks/ui.module-oRwY3Zli.js";
|
|
3
|
-
import { c as r, d as i, i as a, s as o } from "../chunks/input-
|
|
4
|
-
import { l as s } from "../chunks/picker-
|
|
5
|
-
import {
|
|
6
|
-
import {
|
|
7
|
-
import {
|
|
3
|
+
import { c as r, d as i, i as a, s as o } from "../chunks/input-CuRK9Vbz.js";
|
|
4
|
+
import { l as s } from "../chunks/picker-BA6okKnz.js";
|
|
5
|
+
import { cn as c } from "@ryuzaki13/react-foundation-lib/utils";
|
|
6
|
+
import { Fragment as ee, jsx as l, jsxs as u } from "react/jsx-runtime";
|
|
7
|
+
import { useCallback as d, useEffect as f, useMemo as p, useRef as m, useState as h } from "react";
|
|
8
8
|
import { toFiniteNumber as g } from "@ryuzaki13/react-foundation-lib/formatters";
|
|
9
9
|
import { findClosestNumberScaleMark as _, findClosestNumberScaleMarkByPercent as v, getNumberScaleMarkPercent as y, offsetNumberScaleValue as b, percentToNumberScaleValue as x, prepareNumberScaleMarks as S, resolveNumberScaleBounds as C, snapNumberScaleValue as w, snapNumberScaleValueToStep as T, valueToNumberScalePercent as E } from "@ryuzaki13/react-foundation-lib/number-scale";
|
|
10
10
|
import "@ryuzaki13/react-foundation-lib/range-output";
|
|
@@ -175,13 +175,13 @@ function re(e, t) {
|
|
|
175
175
|
return t.find((t) => t.value === e)?.label ?? String(e);
|
|
176
176
|
}
|
|
177
177
|
function ie(e) {
|
|
178
|
-
return typeof e == "string" || typeof e == "number" ? /* @__PURE__ */
|
|
178
|
+
return typeof e == "string" || typeof e == "number" ? /* @__PURE__ */ l("span", {
|
|
179
179
|
className: "textNoWrap",
|
|
180
180
|
children: e
|
|
181
181
|
}) : e;
|
|
182
182
|
}
|
|
183
183
|
function ae({ position: e, children: t }) {
|
|
184
|
-
return /* @__PURE__ */
|
|
184
|
+
return /* @__PURE__ */ l("span", {
|
|
185
185
|
"data-slot": "slider-tooltip-reference",
|
|
186
186
|
className: H.tooltipReference,
|
|
187
187
|
style: { left: `${e}%` },
|
|
@@ -189,23 +189,23 @@ function ae({ position: e, children: t }) {
|
|
|
189
189
|
});
|
|
190
190
|
}
|
|
191
191
|
function G(t) {
|
|
192
|
-
let { min: n, max: a, step: o, marks: s, marksPosition:
|
|
192
|
+
let { min: n, max: a, step: o, marks: s, marksPosition: ee = "value", marksDisplay: d = "compact", className: g, error: _, onClearError: v, label: y, description: S, disabled: w, size: T } = t, { min: E, max: j } = p(() => C(n, a), [n, a]), N = p(() => D(s, E, j), [
|
|
193
193
|
s,
|
|
194
194
|
E,
|
|
195
195
|
j
|
|
196
|
-
]), P =
|
|
196
|
+
]), P = p(() => ({
|
|
197
197
|
min: E,
|
|
198
198
|
max: j,
|
|
199
199
|
step: o,
|
|
200
200
|
marks: N,
|
|
201
|
-
marksPosition:
|
|
201
|
+
marksPosition: ee
|
|
202
202
|
}), [
|
|
203
203
|
E,
|
|
204
204
|
j,
|
|
205
205
|
o,
|
|
206
206
|
N,
|
|
207
|
-
|
|
208
|
-
]), F = t.mode === "range", I = F ? void 0 : M(t.value, P), R = F ? L(t.value, P) : void 0, G = F ? z(t.value, P) : void 0, oe = F ? G : [I], K = te(F ? G : I, P), se =
|
|
207
|
+
ee
|
|
208
|
+
]), F = t.mode === "range", I = F ? void 0 : M(t.value, P), R = F ? L(t.value, P) : void 0, G = F ? z(t.value, P) : void 0, oe = F ? G : [I], K = te(F ? G : I, P), se = m(null), q = m([]), J = m(null), Y = m(null), [X, Z] = h(null), { controlId: ce, labelId: Q, descriptionId: le, errorId: ue, describedBy: de } = i({
|
|
209
209
|
hasLabel: y != null,
|
|
210
210
|
hasDescription: !!S,
|
|
211
211
|
hasError: !!_
|
|
@@ -227,10 +227,10 @@ function G(t) {
|
|
|
227
227
|
if (!t) return E;
|
|
228
228
|
let n = (e - t.left) / t.width * 100;
|
|
229
229
|
return (N.length > 0 ? A(n, P) : void 0)?.value ?? x(n, E, j);
|
|
230
|
-
}, he =
|
|
231
|
-
|
|
230
|
+
}, he = m($), ge = m(me);
|
|
231
|
+
f(() => {
|
|
232
232
|
he.current = $, ge.current = me;
|
|
233
|
-
}),
|
|
233
|
+
}), f(() => {
|
|
234
234
|
let e = (e) => {
|
|
235
235
|
Y.current !== null && e && e.pointerId !== Y.current || (Y.current = null, J.current = null, Z(null));
|
|
236
236
|
}, t = (e) => {
|
|
@@ -275,7 +275,7 @@ function G(t) {
|
|
|
275
275
|
}
|
|
276
276
|
return re(e, N);
|
|
277
277
|
};
|
|
278
|
-
return /* @__PURE__ */
|
|
278
|
+
return /* @__PURE__ */ l(r, {
|
|
279
279
|
label: y,
|
|
280
280
|
description: S,
|
|
281
281
|
disabled: w,
|
|
@@ -286,21 +286,21 @@ function G(t) {
|
|
|
286
286
|
labelId: Q,
|
|
287
287
|
descriptionId: le,
|
|
288
288
|
errorId: ue,
|
|
289
|
-
children: /* @__PURE__ */
|
|
289
|
+
children: /* @__PURE__ */ u("div", {
|
|
290
290
|
id: ce,
|
|
291
|
-
className:
|
|
291
|
+
className: c(H.slider, d === "compact" && H.sliderCompact),
|
|
292
292
|
"data-disabled": w || void 0,
|
|
293
|
-
children: [/* @__PURE__ */
|
|
293
|
+
children: [/* @__PURE__ */ l("div", {
|
|
294
294
|
className: H.trackShell,
|
|
295
|
-
children: /* @__PURE__ */
|
|
295
|
+
children: /* @__PURE__ */ u("div", {
|
|
296
296
|
ref: se,
|
|
297
297
|
"data-slot": "track",
|
|
298
298
|
className: H.track,
|
|
299
299
|
role: "presentation",
|
|
300
300
|
onPointerDown: ve,
|
|
301
301
|
children: [
|
|
302
|
-
/* @__PURE__ */
|
|
303
|
-
/* @__PURE__ */
|
|
302
|
+
/* @__PURE__ */ l("div", { className: H.rail }),
|
|
303
|
+
/* @__PURE__ */ l("div", {
|
|
304
304
|
"data-slot": "fill",
|
|
305
305
|
className: H.fill,
|
|
306
306
|
style: {
|
|
@@ -308,15 +308,15 @@ function G(t) {
|
|
|
308
308
|
width: `${K.endPercent - K.startPercent}%`
|
|
309
309
|
}
|
|
310
310
|
}),
|
|
311
|
-
|
|
311
|
+
d === "compact" && N.map((t) => {
|
|
312
312
|
let n = O(t, N, P), r = F ? t.value >= G[0] && t.value <= G[1] : t.value <= I;
|
|
313
|
-
return /* @__PURE__ */
|
|
313
|
+
return /* @__PURE__ */ l(ae, {
|
|
314
314
|
position: n,
|
|
315
|
-
children: /* @__PURE__ */
|
|
315
|
+
children: /* @__PURE__ */ l(e, {
|
|
316
316
|
tooltip: !0,
|
|
317
317
|
placement: "top",
|
|
318
318
|
content: ie(t.label),
|
|
319
|
-
children: /* @__PURE__ */
|
|
319
|
+
children: /* @__PURE__ */ l("button", {
|
|
320
320
|
type: "button",
|
|
321
321
|
"data-slot": "mark",
|
|
322
322
|
"data-active": r ? "" : void 0,
|
|
@@ -324,7 +324,7 @@ function G(t) {
|
|
|
324
324
|
"aria-label": t.ariaLabel,
|
|
325
325
|
disabled: w,
|
|
326
326
|
onClick: () => xe(t.value),
|
|
327
|
-
children: /* @__PURE__ */
|
|
327
|
+
children: /* @__PURE__ */ l("span", {
|
|
328
328
|
className: H.markDot,
|
|
329
329
|
"aria-hidden": "true"
|
|
330
330
|
})
|
|
@@ -334,16 +334,16 @@ function G(t) {
|
|
|
334
334
|
}),
|
|
335
335
|
oe.map((t, n) => {
|
|
336
336
|
let r = Se(t, n);
|
|
337
|
-
return /* @__PURE__ */
|
|
337
|
+
return /* @__PURE__ */ l(ae, {
|
|
338
338
|
position: k(t, P),
|
|
339
|
-
children: /* @__PURE__ */
|
|
339
|
+
children: /* @__PURE__ */ l(e, {
|
|
340
340
|
tooltip: !0,
|
|
341
341
|
placement: "top",
|
|
342
342
|
content: ie(r),
|
|
343
343
|
openDelay: 0,
|
|
344
344
|
closeDelay: 100,
|
|
345
345
|
positionUpdateKey: t,
|
|
346
|
-
children: /* @__PURE__ */
|
|
346
|
+
children: /* @__PURE__ */ l("button", {
|
|
347
347
|
ref: (e) => {
|
|
348
348
|
q.current[n] = e;
|
|
349
349
|
},
|
|
@@ -371,11 +371,11 @@ function G(t) {
|
|
|
371
371
|
})
|
|
372
372
|
]
|
|
373
373
|
})
|
|
374
|
-
}),
|
|
374
|
+
}), d === "full" && N.length > 0 && /* @__PURE__ */ l("div", {
|
|
375
375
|
className: H.marks,
|
|
376
376
|
children: N.map((e) => {
|
|
377
377
|
let t = F ? e.value >= G[0] && e.value <= G[1] : e.value <= I;
|
|
378
|
-
return /* @__PURE__ */
|
|
378
|
+
return /* @__PURE__ */ u("button", {
|
|
379
379
|
type: "button",
|
|
380
380
|
"data-slot": "mark",
|
|
381
381
|
"data-active": t ? "" : void 0,
|
|
@@ -384,10 +384,10 @@ function G(t) {
|
|
|
384
384
|
"aria-label": e.ariaLabel,
|
|
385
385
|
disabled: w,
|
|
386
386
|
onClick: () => xe(e.value),
|
|
387
|
-
children: [/* @__PURE__ */
|
|
387
|
+
children: [/* @__PURE__ */ l("span", {
|
|
388
388
|
className: H.markDot,
|
|
389
389
|
"aria-hidden": "true"
|
|
390
|
-
}), /* @__PURE__ */
|
|
390
|
+
}), /* @__PURE__ */ l("span", {
|
|
391
391
|
className: H.markLabel,
|
|
392
392
|
children: e.label
|
|
393
393
|
})]
|
|
@@ -398,14 +398,14 @@ function G(t) {
|
|
|
398
398
|
});
|
|
399
399
|
}
|
|
400
400
|
function oe(e) {
|
|
401
|
-
return /* @__PURE__ */
|
|
401
|
+
return /* @__PURE__ */ l(G, {
|
|
402
402
|
...e,
|
|
403
403
|
mode: "single",
|
|
404
404
|
marksDisplay: "compact"
|
|
405
405
|
});
|
|
406
406
|
}
|
|
407
407
|
function K(e) {
|
|
408
|
-
return /* @__PURE__ */
|
|
408
|
+
return /* @__PURE__ */ l(G, {
|
|
409
409
|
...e,
|
|
410
410
|
mode: "range",
|
|
411
411
|
marksDisplay: "compact"
|
|
@@ -414,9 +414,9 @@ function K(e) {
|
|
|
414
414
|
//#endregion
|
|
415
415
|
//#region src/slider/SliderInput.tsx
|
|
416
416
|
function se({ open: e, disabled: n, setOpen: r }) {
|
|
417
|
-
return /* @__PURE__ */
|
|
417
|
+
return /* @__PURE__ */ l(t.Trigger, {
|
|
418
418
|
passive: !0,
|
|
419
|
-
children: /* @__PURE__ */
|
|
419
|
+
children: /* @__PURE__ */ l("div", { children: /* @__PURE__ */ l(s, {
|
|
420
420
|
open: e,
|
|
421
421
|
disabled: n,
|
|
422
422
|
openAriaLabel: "Открыть слайдер",
|
|
@@ -451,24 +451,24 @@ function ce(e, t, n) {
|
|
|
451
451
|
let [r, i] = e, a = r === null, o = i === null;
|
|
452
452
|
return a && o ? n ?? "" : a ? `Меньше ${Z(i, t, "end")}` : o ? `Больше ${Z(r, t, "start")}` : r === i ? `Равно ${Z(r, t, "start")}` : `От ${Z(r, t, "start")} до ${Z(i, t, "end")}`;
|
|
453
453
|
}
|
|
454
|
-
function Q({ value: e, onChange: n, min: r, max: i, step: a, marks: s, marksPosition:
|
|
455
|
-
let { min: S, max: w } =
|
|
454
|
+
function Q({ value: e, onChange: n, min: r, max: i, step: a, marks: s, marksPosition: c = "value", className: ee, error: f, onClearError: m, label: _, description: v, placeholder: y, disabled: b, size: x }) {
|
|
455
|
+
let { min: S, max: w } = p(() => C(r, i), [r, i]), T = p(() => D(s, S, w), [
|
|
456
456
|
s,
|
|
457
457
|
S,
|
|
458
458
|
w
|
|
459
|
-
]), E =
|
|
459
|
+
]), E = p(() => ({
|
|
460
460
|
min: S,
|
|
461
461
|
max: w,
|
|
462
462
|
step: a,
|
|
463
463
|
marks: T,
|
|
464
|
-
marksPosition:
|
|
464
|
+
marksPosition: c
|
|
465
465
|
}), [
|
|
466
466
|
S,
|
|
467
467
|
w,
|
|
468
468
|
a,
|
|
469
469
|
T,
|
|
470
|
-
|
|
471
|
-
]), O = M(e, E), [k, A] =
|
|
470
|
+
c
|
|
471
|
+
]), O = M(e, E), [k, A] = h(!1), [j, N] = h(() => ({
|
|
472
472
|
sourceValue: O,
|
|
473
473
|
value: String(O)
|
|
474
474
|
})), P = j.sourceValue === O ? j.value : String(O), F = (e) => {
|
|
@@ -476,7 +476,7 @@ function Q({ value: e, onChange: n, min: r, max: i, step: a, marks: s, marksPosi
|
|
|
476
476
|
sourceValue: O,
|
|
477
477
|
value: e
|
|
478
478
|
});
|
|
479
|
-
}, I =
|
|
479
|
+
}, I = d(() => {
|
|
480
480
|
if (b) {
|
|
481
481
|
N({
|
|
482
482
|
sourceValue: O,
|
|
@@ -493,7 +493,7 @@ function Q({ value: e, onChange: n, min: r, max: i, step: a, marks: s, marksPosi
|
|
|
493
493
|
return;
|
|
494
494
|
}
|
|
495
495
|
let r = M(t, E);
|
|
496
|
-
e !== r && (n(r),
|
|
496
|
+
e !== r && (n(r), m?.()), N({
|
|
497
497
|
sourceValue: r,
|
|
498
498
|
value: String(r)
|
|
499
499
|
});
|
|
@@ -502,21 +502,21 @@ function Q({ value: e, onChange: n, min: r, max: i, step: a, marks: s, marksPosi
|
|
|
502
502
|
P,
|
|
503
503
|
O,
|
|
504
504
|
n,
|
|
505
|
-
|
|
505
|
+
m,
|
|
506
506
|
E,
|
|
507
507
|
e
|
|
508
508
|
]);
|
|
509
|
-
return /* @__PURE__ */
|
|
509
|
+
return /* @__PURE__ */ u(t, {
|
|
510
510
|
open: k,
|
|
511
511
|
onOpenChange: A,
|
|
512
|
-
children: [/* @__PURE__ */
|
|
512
|
+
children: [/* @__PURE__ */ l(o, {
|
|
513
513
|
label: _,
|
|
514
514
|
description: v,
|
|
515
515
|
placeholder: y,
|
|
516
516
|
disabled: b,
|
|
517
517
|
size: x,
|
|
518
|
-
className:
|
|
519
|
-
error:
|
|
518
|
+
className: ee,
|
|
519
|
+
error: f,
|
|
520
520
|
value: P,
|
|
521
521
|
onChange: F,
|
|
522
522
|
onBlur: I,
|
|
@@ -529,24 +529,24 @@ function Q({ value: e, onChange: n, min: r, max: i, step: a, marks: s, marksPosi
|
|
|
529
529
|
disabled: b,
|
|
530
530
|
setOpen: A
|
|
531
531
|
})
|
|
532
|
-
}), /* @__PURE__ */
|
|
532
|
+
}), /* @__PURE__ */ l(t.Content, {
|
|
533
533
|
background: "primary",
|
|
534
|
-
children: /* @__PURE__ */
|
|
534
|
+
children: /* @__PURE__ */ l("div", {
|
|
535
535
|
className: H.popoverContent,
|
|
536
|
-
children: /* @__PURE__ */
|
|
536
|
+
children: /* @__PURE__ */ l(G, {
|
|
537
537
|
mode: "single",
|
|
538
538
|
min: S,
|
|
539
539
|
max: w,
|
|
540
540
|
step: a,
|
|
541
541
|
marks: T,
|
|
542
|
-
marksPosition:
|
|
542
|
+
marksPosition: c,
|
|
543
543
|
marksDisplay: "full",
|
|
544
544
|
value: e,
|
|
545
545
|
onChange: (e) => {
|
|
546
546
|
n(e), N({
|
|
547
547
|
sourceValue: e,
|
|
548
548
|
value: String(e)
|
|
549
|
-
}),
|
|
549
|
+
}), m?.();
|
|
550
550
|
},
|
|
551
551
|
disabled: b
|
|
552
552
|
})
|
|
@@ -554,28 +554,28 @@ function Q({ value: e, onChange: n, min: r, max: i, step: a, marks: s, marksPosi
|
|
|
554
554
|
})]
|
|
555
555
|
});
|
|
556
556
|
}
|
|
557
|
-
function le({ value: e, onChange: o, min: s, max:
|
|
558
|
-
let { min: k, max: A } =
|
|
557
|
+
function le({ value: e, onChange: o, min: s, max: f, step: m, marks: g, marksPosition: _ = "value", className: v, error: y, onClearError: b, label: x, description: S, readonlyValueText: w, placeholder: T, disabled: E, size: O }) {
|
|
558
|
+
let { min: k, max: A } = p(() => C(s, f), [s, f]), j = p(() => D(g, k, A), [
|
|
559
559
|
g,
|
|
560
560
|
k,
|
|
561
561
|
A
|
|
562
|
-
]), M =
|
|
562
|
+
]), M = p(() => ({
|
|
563
563
|
min: k,
|
|
564
564
|
max: A,
|
|
565
|
-
step:
|
|
565
|
+
step: m,
|
|
566
566
|
marks: j,
|
|
567
567
|
marksPosition: _
|
|
568
568
|
}), [
|
|
569
569
|
k,
|
|
570
570
|
A,
|
|
571
|
-
|
|
571
|
+
m,
|
|
572
572
|
j,
|
|
573
573
|
_
|
|
574
|
-
]), N =
|
|
574
|
+
]), N = p(() => L(e, M), [M, e]), P = p(() => q(N, M), [N, M]), [F, I] = h(!1), [R, z] = h(() => ({
|
|
575
575
|
sourceValue: N,
|
|
576
576
|
start: P.start,
|
|
577
577
|
end: P.end
|
|
578
|
-
})), [B, V] =
|
|
578
|
+
})), [B, V] = h(N), te = F || ue(R.sourceValue, N), U = te ? R.start : P.start, W = te ? R.end : P.end, ne = (e) => {
|
|
579
579
|
z({
|
|
580
580
|
sourceValue: N,
|
|
581
581
|
start: e,
|
|
@@ -591,7 +591,7 @@ function le({ value: e, onChange: o, min: s, max: l, step: d, marks: g, marksPos
|
|
|
591
591
|
hasLabel: x != null,
|
|
592
592
|
hasDescription: !!S,
|
|
593
593
|
hasError: !!y
|
|
594
|
-
}), X =
|
|
594
|
+
}), X = d(() => {
|
|
595
595
|
z({
|
|
596
596
|
sourceValue: N,
|
|
597
597
|
start: P.start,
|
|
@@ -601,7 +601,7 @@ function le({ value: e, onChange: o, min: s, max: l, step: d, marks: g, marksPos
|
|
|
601
601
|
P.end,
|
|
602
602
|
P.start,
|
|
603
603
|
N
|
|
604
|
-
]), Z =
|
|
604
|
+
]), Z = d(() => {
|
|
605
605
|
if (E) {
|
|
606
606
|
X();
|
|
607
607
|
return;
|
|
@@ -628,7 +628,7 @@ function le({ value: e, onChange: o, min: s, max: l, step: d, marks: g, marksPos
|
|
|
628
628
|
b,
|
|
629
629
|
X,
|
|
630
630
|
M
|
|
631
|
-
]), Q =
|
|
631
|
+
]), Q = d((e) => {
|
|
632
632
|
let t = L(e, M);
|
|
633
633
|
ue(N, t) || (o(t), b?.());
|
|
634
634
|
let n = q(t, M);
|
|
@@ -660,10 +660,10 @@ function le({ value: e, onChange: o, min: s, max: l, step: d, marks: g, marksPos
|
|
|
660
660
|
end: n.end
|
|
661
661
|
});
|
|
662
662
|
}, pe = w ? ce(F ? B : N, j, T) : void 0;
|
|
663
|
-
return /* @__PURE__ */
|
|
663
|
+
return /* @__PURE__ */ u(t, {
|
|
664
664
|
open: F,
|
|
665
665
|
onOpenChange: le,
|
|
666
|
-
children: [/* @__PURE__ */
|
|
666
|
+
children: [/* @__PURE__ */ l(r, {
|
|
667
667
|
label: x,
|
|
668
668
|
description: S,
|
|
669
669
|
disabled: E,
|
|
@@ -674,7 +674,7 @@ function le({ value: e, onChange: o, min: s, max: l, step: d, marks: g, marksPos
|
|
|
674
674
|
labelId: ae,
|
|
675
675
|
descriptionId: oe,
|
|
676
676
|
errorId: K,
|
|
677
|
-
children: /* @__PURE__ */
|
|
677
|
+
children: /* @__PURE__ */ l(a, {
|
|
678
678
|
endAdornmentWidth: "var(--control-height)",
|
|
679
679
|
endAdornment: se({
|
|
680
680
|
open: F,
|
|
@@ -683,9 +683,9 @@ function le({ value: e, onChange: o, min: s, max: l, step: d, marks: g, marksPos
|
|
|
683
683
|
le(typeof e == "function" ? e(F) : e);
|
|
684
684
|
}
|
|
685
685
|
}),
|
|
686
|
-
children: ({ controlClassName: e }) => /* @__PURE__ */
|
|
686
|
+
children: ({ controlClassName: e }) => /* @__PURE__ */ l("div", {
|
|
687
687
|
id: ie,
|
|
688
|
-
className:
|
|
688
|
+
className: c(n.uiInputControlFake, H.rangeInputControl, e),
|
|
689
689
|
"data-invalid": y ? "" : void 0,
|
|
690
690
|
"data-disabled": E || void 0,
|
|
691
691
|
role: "group",
|
|
@@ -693,11 +693,11 @@ function le({ value: e, onChange: o, min: s, max: l, step: d, marks: g, marksPos
|
|
|
693
693
|
"aria-label": typeof x == "string" ? x : "Диапазон",
|
|
694
694
|
"aria-labelledby": typeof x == "string" ? void 0 : ae,
|
|
695
695
|
"aria-describedby": Y,
|
|
696
|
-
children: w ? /* @__PURE__ */
|
|
697
|
-
className:
|
|
696
|
+
children: w ? /* @__PURE__ */ l("span", {
|
|
697
|
+
className: c("flexEllipsis", !pe && n.uiPlaceholder),
|
|
698
698
|
children: pe || T
|
|
699
|
-
}) : /* @__PURE__ */
|
|
700
|
-
/* @__PURE__ */
|
|
699
|
+
}) : /* @__PURE__ */ u(ee, { children: [
|
|
700
|
+
/* @__PURE__ */ l("input", {
|
|
701
701
|
type: "text",
|
|
702
702
|
inputMode: "decimal",
|
|
703
703
|
className: H.rangeSegmentInput,
|
|
@@ -708,12 +708,12 @@ function le({ value: e, onChange: o, min: s, max: l, step: d, marks: g, marksPos
|
|
|
708
708
|
onBlur: Z,
|
|
709
709
|
onKeyDown: de
|
|
710
710
|
}),
|
|
711
|
-
/* @__PURE__ */
|
|
711
|
+
/* @__PURE__ */ l("span", {
|
|
712
712
|
className: H.rangeSeparator,
|
|
713
713
|
"data-disabled": E || void 0,
|
|
714
714
|
children: "-"
|
|
715
715
|
}),
|
|
716
|
-
/* @__PURE__ */
|
|
716
|
+
/* @__PURE__ */ l("input", {
|
|
717
717
|
type: "text",
|
|
718
718
|
inputMode: "decimal",
|
|
719
719
|
className: H.rangeSegmentInput,
|
|
@@ -727,15 +727,15 @@ function le({ value: e, onChange: o, min: s, max: l, step: d, marks: g, marksPos
|
|
|
727
727
|
] })
|
|
728
728
|
})
|
|
729
729
|
})
|
|
730
|
-
}), /* @__PURE__ */
|
|
730
|
+
}), /* @__PURE__ */ l(t.Content, {
|
|
731
731
|
background: "primary",
|
|
732
|
-
children: /* @__PURE__ */
|
|
732
|
+
children: /* @__PURE__ */ l("div", {
|
|
733
733
|
className: H.popoverContent,
|
|
734
|
-
children: /* @__PURE__ */
|
|
734
|
+
children: /* @__PURE__ */ l(G, {
|
|
735
735
|
mode: "range",
|
|
736
736
|
min: k,
|
|
737
737
|
max: A,
|
|
738
|
-
step:
|
|
738
|
+
step: m,
|
|
739
739
|
marks: j,
|
|
740
740
|
marksPosition: _,
|
|
741
741
|
marksDisplay: "full",
|