@umami/react-zen 0.39.0 → 0.41.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/index.css +113 -25
- package/dist/index.d.ts +9 -16
- package/dist/index.js +124 -127
- package/dist/index.mjs +124 -127
- package/package.json +2 -2
- package/styles.css +113 -25
package/dist/index.mjs
CHANGED
|
@@ -25987,6 +25987,9 @@ var CSS_MAP = {
|
|
|
25987
25987
|
marginRight: "margin-right",
|
|
25988
25988
|
marginBottom: "margin-bottom",
|
|
25989
25989
|
marginLeft: "margin-left",
|
|
25990
|
+
overflow: "overflow",
|
|
25991
|
+
overflowX: "overflow-x",
|
|
25992
|
+
overflowY: "overflow-y",
|
|
25990
25993
|
width: "width",
|
|
25991
25994
|
height: "height",
|
|
25992
25995
|
minHeight: "min-height",
|
|
@@ -26103,6 +26106,9 @@ function Box({
|
|
|
26103
26106
|
marginRight,
|
|
26104
26107
|
marginBottom,
|
|
26105
26108
|
marginLeft,
|
|
26109
|
+
overflow,
|
|
26110
|
+
overflowX,
|
|
26111
|
+
overflowY,
|
|
26106
26112
|
width,
|
|
26107
26113
|
minWidth,
|
|
26108
26114
|
maxWidth,
|
|
@@ -26151,6 +26157,9 @@ function Box({
|
|
|
26151
26157
|
marginRight,
|
|
26152
26158
|
marginBottom,
|
|
26153
26159
|
marginLeft,
|
|
26160
|
+
overflow,
|
|
26161
|
+
overflowX,
|
|
26162
|
+
overflowY,
|
|
26154
26163
|
width,
|
|
26155
26164
|
minWidth,
|
|
26156
26165
|
maxWidth,
|
|
@@ -30312,17 +30321,24 @@ var import_classnames14 = __toESM(require_classnames());
|
|
|
30312
30321
|
var import_classnames13 = __toESM(require_classnames());
|
|
30313
30322
|
|
|
30314
30323
|
// css-modules:/Users/mikecao/Development/umami-software/react-zen/src/components/Dialog.module.css
|
|
30315
|
-
var Dialog_default = { "dialog": "
|
|
30324
|
+
var Dialog_default = { "dialog": "Dialog_dialog__OTEwM", "title": "Dialog_title__MTE4N", "sheet": "Dialog_sheet__MWQ0Z" };
|
|
30316
30325
|
|
|
30317
30326
|
// src/components/Dialog.tsx
|
|
30318
30327
|
import { Fragment as Fragment2, jsx as jsx20, jsxs as jsxs10 } from "react/jsx-runtime";
|
|
30319
|
-
function Dialog({ title, children, className, ...props }) {
|
|
30320
|
-
return /* @__PURE__ */ jsx20(
|
|
30321
|
-
|
|
30322
|
-
|
|
30323
|
-
|
|
30324
|
-
|
|
30325
|
-
|
|
30328
|
+
function Dialog({ title, variant, children, className, ...props }) {
|
|
30329
|
+
return /* @__PURE__ */ jsx20(
|
|
30330
|
+
$de32f1b87079253c$export$3ddf2d174ce01153,
|
|
30331
|
+
{
|
|
30332
|
+
...props,
|
|
30333
|
+
className: (0, import_classnames13.default)(Dialog_default.dialog, variant && Dialog_default[variant], className),
|
|
30334
|
+
children: (dialogProps) => {
|
|
30335
|
+
return /* @__PURE__ */ jsxs10(Fragment2, { children: [
|
|
30336
|
+
title && /* @__PURE__ */ jsx20("div", { className: Dialog_default.title, children: title }),
|
|
30337
|
+
typeof children === "function" ? children(dialogProps) : children
|
|
30338
|
+
] });
|
|
30339
|
+
}
|
|
30340
|
+
}
|
|
30341
|
+
);
|
|
30326
30342
|
}
|
|
30327
30343
|
|
|
30328
30344
|
// src/components/Row.tsx
|
|
@@ -31074,40 +31090,22 @@ function Menu({ items, className, children, ...props }) {
|
|
|
31074
31090
|
var import_classnames36 = __toESM(require_classnames());
|
|
31075
31091
|
|
|
31076
31092
|
// css-modules:/Users/mikecao/Development/umami-software/react-zen/src/components/Modal.module.css
|
|
31077
|
-
var Modal_default = { "overlay": "
|
|
31093
|
+
var Modal_default = { "overlay": "Modal_overlay__MzYwN", "modal-fade-in": "Modal_modal-fade-in__MDBkZ", "modal": "Modal_modal__ZTRjZ", "left": "Modal_left__NWIxM", "right": "Modal_right__MGNkY", "top": "Modal_top__ZmViY", "bottom": "Modal_bottom__Zjg4M", "fullscreen": "Modal_fullscreen__NmZiM", "center": "Modal_center__ZWFmO", "modal-zoom": "Modal_modal-zoom__MmU0M", "modal-left": "Modal_modal-left__MWY5M", "modal-right": "Modal_modal-right__OWVlM", "modal-top": "Modal_modal-top__NDc4M", "modal-bottom": "Modal_modal-bottom__YTE1Z" };
|
|
31078
31094
|
|
|
31079
31095
|
// src/components/Modal.tsx
|
|
31080
31096
|
import { jsx as jsx47 } from "react/jsx-runtime";
|
|
31081
|
-
function Modal({
|
|
31082
|
-
|
|
31083
|
-
|
|
31084
|
-
|
|
31085
|
-
|
|
31086
|
-
|
|
31087
|
-
|
|
31088
|
-
|
|
31089
|
-
|
|
31090
|
-
|
|
31091
|
-
}
|
|
31092
|
-
|
|
31093
|
-
// css-modules:/Users/mikecao/Development/umami-software/react-zen/src/components/MobileMenuButton.module.css
|
|
31094
|
-
var MobileMenuButton_default = { "modal": "MobileMenuButton_modal__YjAxN", "dialog": "MobileMenuButton_dialog__Mzc5Y", "content": "MobileMenuButton_content__MjQ3N" };
|
|
31095
|
-
|
|
31096
|
-
// src/components/MobileMenuButton.tsx
|
|
31097
|
-
import { jsx as jsx48, jsxs as jsxs26 } from "react/jsx-runtime";
|
|
31098
|
-
function MobileMenuButton({ title, children, ...props }) {
|
|
31099
|
-
return /* @__PURE__ */ jsxs26($de32f1b87079253c$export$2e1e1122cf0cba88, { children: [
|
|
31100
|
-
/* @__PURE__ */ jsx48(Button, { variant: "quiet", children: /* @__PURE__ */ jsx48(Icon, { children: /* @__PURE__ */ jsx48(Icons.Menu, {}) }) }),
|
|
31101
|
-
/* @__PURE__ */ jsx48(Modal, { className: MobileMenuButton_default.modal, children: /* @__PURE__ */ jsx48(Dialog, { className: MobileMenuButton_default.dialog, children: ({ close }) => {
|
|
31102
|
-
return /* @__PURE__ */ jsxs26(Grid, { rows: "auto 1fr", height: "100%", width: "100%", children: [
|
|
31103
|
-
/* @__PURE__ */ jsxs26(Row, { justifyContent: "space-between", alignItems: "center", children: [
|
|
31104
|
-
/* @__PURE__ */ jsx48(Text, { size: "3", weight: "bold", children: title }),
|
|
31105
|
-
/* @__PURE__ */ jsx48(Button, { onPress: () => close(), variant: "quiet", children: /* @__PURE__ */ jsx48(Icon, { children: /* @__PURE__ */ jsx48(Icons.Close, {}) }) })
|
|
31106
|
-
] }),
|
|
31107
|
-
/* @__PURE__ */ jsx48(Box, { className: MobileMenuButton_default.content, children })
|
|
31108
|
-
] });
|
|
31109
|
-
} }) })
|
|
31110
|
-
] });
|
|
31097
|
+
function Modal({
|
|
31098
|
+
position = "center",
|
|
31099
|
+
offset,
|
|
31100
|
+
children,
|
|
31101
|
+
className,
|
|
31102
|
+
style = {},
|
|
31103
|
+
...props
|
|
31104
|
+
}) {
|
|
31105
|
+
if (offset) {
|
|
31106
|
+
style[`--modal-offset`] = offset;
|
|
31107
|
+
}
|
|
31108
|
+
return /* @__PURE__ */ jsx47($f3f84453ead64de5$export$8948f78d83984c69, { ...props, className: Modal_default.overlay, style, isDismissable: true, children: /* @__PURE__ */ jsx47($f3f84453ead64de5$export$2b77a92f1a5ad772, { className: (0, import_classnames36.default)(Modal_default.modal, position && Modal_default[position], className), children }) });
|
|
31111
31109
|
}
|
|
31112
31110
|
|
|
31113
31111
|
// src/components/NavigationMenu.tsx
|
|
@@ -31125,14 +31123,14 @@ var useNavigationMenu = store3;
|
|
|
31125
31123
|
var NavigationMenu_default = { "nav": "NavigationMenu_nav__MzRiY", "item": "NavigationMenu_item__YTI0N", "icon": "NavigationMenu_icon__ZDczY" };
|
|
31126
31124
|
|
|
31127
31125
|
// src/components/NavigationMenu.tsx
|
|
31128
|
-
import { jsx as
|
|
31126
|
+
import { jsx as jsx48, jsxs as jsxs26 } from "react/jsx-runtime";
|
|
31129
31127
|
function NavigationMenu({
|
|
31130
31128
|
showArrow = true,
|
|
31131
31129
|
className,
|
|
31132
31130
|
children,
|
|
31133
31131
|
...props
|
|
31134
31132
|
}) {
|
|
31135
|
-
return /* @__PURE__ */
|
|
31133
|
+
return /* @__PURE__ */ jsx48("div", { ...props, className: (0, import_classnames37.default)(NavigationMenu_default.nav, className), children });
|
|
31136
31134
|
}
|
|
31137
31135
|
function NavigationMenuItem({
|
|
31138
31136
|
label,
|
|
@@ -31142,15 +31140,15 @@ function NavigationMenuItem({
|
|
|
31142
31140
|
}) {
|
|
31143
31141
|
const { activeMenu } = useNavigationMenu();
|
|
31144
31142
|
if (label) {
|
|
31145
|
-
return /* @__PURE__ */
|
|
31146
|
-
/* @__PURE__ */
|
|
31147
|
-
/* @__PURE__ */
|
|
31148
|
-
/* @__PURE__ */
|
|
31143
|
+
return /* @__PURE__ */ jsxs26(HoverTrigger, { isOpen: activeMenu === label, onHoverStart: () => setActiveMenu(label), children: [
|
|
31144
|
+
/* @__PURE__ */ jsxs26("div", { ...props, className: (0, import_classnames37.default)(NavigationMenu_default.item, className), children: [
|
|
31145
|
+
/* @__PURE__ */ jsx48(Text, { children: label }),
|
|
31146
|
+
/* @__PURE__ */ jsx48(Icon, { rotate: 90, size: "xs", className: NavigationMenu_default.icon, children: /* @__PURE__ */ jsx48(Icons.Chevron, {}) })
|
|
31149
31147
|
] }),
|
|
31150
31148
|
children
|
|
31151
31149
|
] });
|
|
31152
31150
|
}
|
|
31153
|
-
return /* @__PURE__ */
|
|
31151
|
+
return /* @__PURE__ */ jsx48("div", { ...props, className: (0, import_classnames37.default)(NavigationMenu_default.item, className), children });
|
|
31154
31152
|
}
|
|
31155
31153
|
|
|
31156
31154
|
// src/components/PasswordField.tsx
|
|
@@ -31161,17 +31159,17 @@ var import_classnames38 = __toESM(require_classnames());
|
|
|
31161
31159
|
var PasswordField_default = { "icon": "PasswordField_icon__NDMyZ" };
|
|
31162
31160
|
|
|
31163
31161
|
// src/components/PasswordField.tsx
|
|
31164
|
-
import { jsx as
|
|
31162
|
+
import { jsx as jsx49, jsxs as jsxs27 } from "react/jsx-runtime";
|
|
31165
31163
|
var PasswordField = forwardRef6(
|
|
31166
31164
|
({ label, className, ...props }, ref) => {
|
|
31167
31165
|
const [show, setShow] = useState13(false);
|
|
31168
31166
|
const type = show ? "text" : "password";
|
|
31169
31167
|
const handleShowPassword = () => setShow((state) => !state);
|
|
31170
|
-
return /* @__PURE__ */
|
|
31171
|
-
label && /* @__PURE__ */
|
|
31172
|
-
/* @__PURE__ */
|
|
31173
|
-
/* @__PURE__ */
|
|
31174
|
-
/* @__PURE__ */
|
|
31168
|
+
return /* @__PURE__ */ jsxs27($bcdf0525bf22703d$export$2c73285ae9390cec, { ...props, ref, className: (0, import_classnames38.default)(input_default.field, className), children: [
|
|
31169
|
+
label && /* @__PURE__ */ jsx49(Label, { children: label }),
|
|
31170
|
+
/* @__PURE__ */ jsxs27("div", { className: input_default.row, children: [
|
|
31171
|
+
/* @__PURE__ */ jsx49($3985021b0ad6602f$export$f5b8910cec6cf069, { type, className: input_default.input }),
|
|
31172
|
+
/* @__PURE__ */ jsx49(Icon, { onClick: handleShowPassword, className: (0, import_classnames38.default)(PasswordField_default.icon, input_default.icon), children: show ? /* @__PURE__ */ jsx49(Icons.EyeSlash, {}) : /* @__PURE__ */ jsx49(Icons.Eye, {}) })
|
|
31175
31173
|
] })
|
|
31176
31174
|
] });
|
|
31177
31175
|
}
|
|
@@ -31184,12 +31182,12 @@ var import_classnames39 = __toESM(require_classnames());
|
|
|
31184
31182
|
var ProgressBar_default = { "progressbar": "ProgressBar_progressbar__MTQwN", "track": "ProgressBar_track__YTM0O", "fill": "ProgressBar_fill__ZTkyN", "value": "ProgressBar_value__YTU3N" };
|
|
31185
31183
|
|
|
31186
31184
|
// src/components/ProgressBar.tsx
|
|
31187
|
-
import { Fragment as Fragment6, jsx as
|
|
31185
|
+
import { Fragment as Fragment6, jsx as jsx50, jsxs as jsxs28 } from "react/jsx-runtime";
|
|
31188
31186
|
function ProgressBar({ className, showValue, ...props }) {
|
|
31189
|
-
return /* @__PURE__ */
|
|
31190
|
-
return /* @__PURE__ */
|
|
31191
|
-
/* @__PURE__ */
|
|
31192
|
-
showValue && /* @__PURE__ */
|
|
31187
|
+
return /* @__PURE__ */ jsx50($0393f8ab869a0f1a$export$c17561cb55d4db30, { ...props, className: (0, import_classnames39.default)(ProgressBar_default.progressbar, className), children: ({ percentage = 0, valueText }) => {
|
|
31188
|
+
return /* @__PURE__ */ jsxs28(Fragment6, { children: [
|
|
31189
|
+
/* @__PURE__ */ jsx50("div", { className: ProgressBar_default.track, children: /* @__PURE__ */ jsx50("div", { className: ProgressBar_default.fill, style: { width: `${percentage}%` } }) }),
|
|
31190
|
+
showValue && /* @__PURE__ */ jsx50("div", { className: ProgressBar_default.value, children: valueText })
|
|
31193
31191
|
] });
|
|
31194
31192
|
} });
|
|
31195
31193
|
}
|
|
@@ -31201,16 +31199,16 @@ var import_classnames40 = __toESM(require_classnames());
|
|
|
31201
31199
|
var ProgressCircle_default = { "progresscircle": "ProgressCircle_progresscircle__NTQ3N", "track": "ProgressCircle_track__Mjk3Y", "fill": "ProgressCircle_fill__OWJlY", "value": "ProgressCircle_value__NzQ5Y" };
|
|
31202
31200
|
|
|
31203
31201
|
// src/components/ProgressCircle.tsx
|
|
31204
|
-
import { Fragment as Fragment7, jsx as
|
|
31202
|
+
import { Fragment as Fragment7, jsx as jsx51, jsxs as jsxs29 } from "react/jsx-runtime";
|
|
31205
31203
|
function ProgressCircle({ className, showValue, ...props }) {
|
|
31206
|
-
return /* @__PURE__ */
|
|
31204
|
+
return /* @__PURE__ */ jsx51($0393f8ab869a0f1a$export$c17561cb55d4db30, { ...props, className: (0, import_classnames40.default)(ProgressCircle_default.progresscircle, className), children: ({ percentage = 0, valueText }) => {
|
|
31207
31205
|
const radius = 45;
|
|
31208
31206
|
const circumference = radius * 2 * Math.PI;
|
|
31209
31207
|
const offset = circumference - percentage / 100 * circumference;
|
|
31210
|
-
return /* @__PURE__ */
|
|
31211
|
-
/* @__PURE__ */
|
|
31212
|
-
/* @__PURE__ */
|
|
31213
|
-
/* @__PURE__ */
|
|
31208
|
+
return /* @__PURE__ */ jsxs29(Fragment7, { children: [
|
|
31209
|
+
/* @__PURE__ */ jsxs29("svg", { viewBox: "0 0 100 100", xmlns: "http://www.w3.org/2000/svg", children: [
|
|
31210
|
+
/* @__PURE__ */ jsx51("circle", { className: ProgressCircle_default.track, cx: "50", cy: "50", r: "45" }),
|
|
31211
|
+
/* @__PURE__ */ jsx51(
|
|
31214
31212
|
"circle",
|
|
31215
31213
|
{
|
|
31216
31214
|
className: ProgressCircle_default.fill,
|
|
@@ -31222,7 +31220,7 @@ function ProgressCircle({ className, showValue, ...props }) {
|
|
|
31222
31220
|
}
|
|
31223
31221
|
)
|
|
31224
31222
|
] }),
|
|
31225
|
-
showValue && /* @__PURE__ */
|
|
31223
|
+
showValue && /* @__PURE__ */ jsx51("label", { className: ProgressCircle_default.value, children: valueText })
|
|
31226
31224
|
] });
|
|
31227
31225
|
} });
|
|
31228
31226
|
}
|
|
@@ -31235,17 +31233,17 @@ var import_classnames41 = __toESM(require_classnames());
|
|
|
31235
31233
|
var RadioGroup_default = { "radiogroup": "RadioGroup_radiogroup__M2FmO", "radio": "RadioGroup_radio__NjdlY" };
|
|
31236
31234
|
|
|
31237
31235
|
// src/components/RadioGroup.tsx
|
|
31238
|
-
import { jsx as
|
|
31236
|
+
import { jsx as jsx52, jsxs as jsxs30 } from "react/jsx-runtime";
|
|
31239
31237
|
var RadioGroup = forwardRef7(
|
|
31240
31238
|
({ label, children, className, ...props }, ref) => {
|
|
31241
|
-
return /* @__PURE__ */
|
|
31242
|
-
label && /* @__PURE__ */
|
|
31239
|
+
return /* @__PURE__ */ jsxs30($b6c3ddc6086f204d$export$a98f0dcb43a68a25, { ...props, ref, className: (0, import_classnames41.default)(RadioGroup_default.radiogroup, className), children: [
|
|
31240
|
+
label && /* @__PURE__ */ jsx52(Label, { children: label }),
|
|
31243
31241
|
children
|
|
31244
31242
|
] });
|
|
31245
31243
|
}
|
|
31246
31244
|
);
|
|
31247
31245
|
function Radio({ children, className, ...props }) {
|
|
31248
|
-
return /* @__PURE__ */
|
|
31246
|
+
return /* @__PURE__ */ jsx52($b6c3ddc6086f204d$export$d7b12c4107be0d61, { ...props, className: (0, import_classnames41.default)(RadioGroup_default.radio, className), children });
|
|
31249
31247
|
}
|
|
31250
31248
|
|
|
31251
31249
|
// src/components/SearchField.tsx
|
|
@@ -31256,7 +31254,7 @@ var import_classnames42 = __toESM(require_classnames());
|
|
|
31256
31254
|
var SearchField_default = { "search": "SearchField_search__MmNlZ", "input": "SearchField_input__NTAwN", "close": "SearchField_close__NzZiM" };
|
|
31257
31255
|
|
|
31258
31256
|
// src/components/SearchField.tsx
|
|
31259
|
-
import { Fragment as Fragment8, jsx as
|
|
31257
|
+
import { Fragment as Fragment8, jsx as jsx53, jsxs as jsxs31 } from "react/jsx-runtime";
|
|
31260
31258
|
var SearchField = forwardRef8(
|
|
31261
31259
|
({ label, value, delay = 0, onSearch, className, ...props }, ref) => {
|
|
31262
31260
|
const [search, setSearch] = useState14(value ?? "");
|
|
@@ -31277,24 +31275,24 @@ var SearchField = forwardRef8(
|
|
|
31277
31275
|
onSearch?.(searchValue);
|
|
31278
31276
|
}
|
|
31279
31277
|
}, [searchValue, delay, onSearch]);
|
|
31280
|
-
return /* @__PURE__ */
|
|
31281
|
-
return /* @__PURE__ */
|
|
31282
|
-
label && /* @__PURE__ */
|
|
31283
|
-
/* @__PURE__ */
|
|
31284
|
-
/* @__PURE__ */
|
|
31285
|
-
/* @__PURE__ */
|
|
31278
|
+
return /* @__PURE__ */ jsx53($440f4836bcb56932$export$b94867ecbd698f21, { ...props, ref, className: (0, import_classnames42.default)(input_default.field, className), children: ({ state }) => {
|
|
31279
|
+
return /* @__PURE__ */ jsxs31(Fragment8, { children: [
|
|
31280
|
+
label && /* @__PURE__ */ jsx53(Label, { children: label }),
|
|
31281
|
+
/* @__PURE__ */ jsxs31("div", { className: input_default.row, children: [
|
|
31282
|
+
/* @__PURE__ */ jsx53(Icons.MagnifyingGlass, { className: (0, import_classnames42.default)(SearchField_default.search, input_default.icon) }),
|
|
31283
|
+
/* @__PURE__ */ jsx53(
|
|
31286
31284
|
$3985021b0ad6602f$export$f5b8910cec6cf069,
|
|
31287
31285
|
{
|
|
31288
31286
|
className: (0, import_classnames42.default)(SearchField_default.input, input_default.input),
|
|
31289
31287
|
onChange: handleChange
|
|
31290
31288
|
}
|
|
31291
31289
|
),
|
|
31292
|
-
state.value && /* @__PURE__ */
|
|
31290
|
+
state.value && /* @__PURE__ */ jsx53(
|
|
31293
31291
|
$d2b4bc8c273e7be6$export$353f5b6fc5456de1,
|
|
31294
31292
|
{
|
|
31295
31293
|
className: (0, import_classnames42.default)(SearchField_default.close, input_default.icon),
|
|
31296
31294
|
onPress: resetSearch,
|
|
31297
|
-
children: /* @__PURE__ */
|
|
31295
|
+
children: /* @__PURE__ */ jsx53(Icon, { children: /* @__PURE__ */ jsx53(Icons.Close, {}) })
|
|
31298
31296
|
}
|
|
31299
31297
|
)
|
|
31300
31298
|
] })
|
|
@@ -31311,7 +31309,7 @@ import { forwardRef as forwardRef9 } from "react";
|
|
|
31311
31309
|
var Select_default = { "button": "Select_button__YTM3Z", "list": "Select_list__MjJiN", "icon": "Select_icon__NzlhY" };
|
|
31312
31310
|
|
|
31313
31311
|
// src/components/Select.tsx
|
|
31314
|
-
import { jsx as
|
|
31312
|
+
import { jsx as jsx54, jsxs as jsxs32 } from "react/jsx-runtime";
|
|
31315
31313
|
var Select = forwardRef9(
|
|
31316
31314
|
({
|
|
31317
31315
|
children,
|
|
@@ -31327,7 +31325,7 @@ var Select = forwardRef9(
|
|
|
31327
31325
|
onSelectionChange?.(e);
|
|
31328
31326
|
onChange?.(e);
|
|
31329
31327
|
};
|
|
31330
|
-
return /* @__PURE__ */
|
|
31328
|
+
return /* @__PURE__ */ jsxs32(
|
|
31331
31329
|
$82d7e5349645de74$export$ef9b1a59e592288f,
|
|
31332
31330
|
{
|
|
31333
31331
|
...props,
|
|
@@ -31335,12 +31333,12 @@ var Select = forwardRef9(
|
|
|
31335
31333
|
className: (0, import_classnames43.default)(input_default.field, className),
|
|
31336
31334
|
onSelectionChange: handleChange,
|
|
31337
31335
|
children: [
|
|
31338
|
-
label && /* @__PURE__ */
|
|
31339
|
-
/* @__PURE__ */
|
|
31340
|
-
/* @__PURE__ */
|
|
31341
|
-
/* @__PURE__ */
|
|
31336
|
+
label && /* @__PURE__ */ jsx54(Label, { children: label }),
|
|
31337
|
+
/* @__PURE__ */ jsx54($d2b4bc8c273e7be6$export$353f5b6fc5456de1, { className: (0, import_classnames43.default)(input_default.input, className), children: /* @__PURE__ */ jsxs32(Row, { justifyContent: "space-between", gap: "3", children: [
|
|
31338
|
+
/* @__PURE__ */ jsx54($82d7e5349645de74$export$e288731fd71264f0, {}),
|
|
31339
|
+
/* @__PURE__ */ jsx54("span", { "aria-hidden": "true", children: /* @__PURE__ */ jsx54(Icon, { rotate: 90, size: "xs", className: input_default.icon, children: /* @__PURE__ */ jsx54(Icons.Chevron, {}) }) })
|
|
31342
31340
|
] }) }),
|
|
31343
|
-
/* @__PURE__ */
|
|
31341
|
+
/* @__PURE__ */ jsx54(Popover, { children: /* @__PURE__ */ jsx54(List, { items, className: Select_default.list, children }) })
|
|
31344
31342
|
]
|
|
31345
31343
|
}
|
|
31346
31344
|
);
|
|
@@ -31355,18 +31353,18 @@ var import_classnames44 = __toESM(require_classnames());
|
|
|
31355
31353
|
var Slider_default = { "slider": "Slider_slider__ODQ1M", "header": "Slider_header__NmYzN", "track": "Slider_track__Y2M4O", "fill": "Slider_fill__MWM4N", "thumb": "Slider_thumb__NGU2Z" };
|
|
31356
31354
|
|
|
31357
31355
|
// src/components/Slider.tsx
|
|
31358
|
-
import { Fragment as Fragment9, jsx as
|
|
31356
|
+
import { Fragment as Fragment9, jsx as jsx55, jsxs as jsxs33 } from "react/jsx-runtime";
|
|
31359
31357
|
var Slider = forwardRef10(
|
|
31360
31358
|
({ className, showValue = true, label, ...props }, ref) => {
|
|
31361
|
-
return /* @__PURE__ */
|
|
31362
|
-
/* @__PURE__ */
|
|
31363
|
-
label && /* @__PURE__ */
|
|
31364
|
-
showValue && /* @__PURE__ */
|
|
31359
|
+
return /* @__PURE__ */ jsxs33($6f909507e6374d18$export$472062a354075cee, { ...props, ref, className: (0, import_classnames44.default)(Slider_default.slider, className), children: [
|
|
31360
|
+
/* @__PURE__ */ jsxs33("div", { className: Slider_default.header, children: [
|
|
31361
|
+
label && /* @__PURE__ */ jsx55(Label, { className: Slider_default.label, children: label }),
|
|
31362
|
+
showValue && /* @__PURE__ */ jsx55($6f909507e6374d18$export$a590f758a961cb5b, { className: Slider_default.output })
|
|
31365
31363
|
] }),
|
|
31366
|
-
/* @__PURE__ */
|
|
31364
|
+
/* @__PURE__ */ jsx55($6f909507e6374d18$export$105594979f116971, { className: Slider_default.track, children: ({ state }) => {
|
|
31367
31365
|
const isHorizontal = state.orientation === "horizontal";
|
|
31368
|
-
return /* @__PURE__ */
|
|
31369
|
-
/* @__PURE__ */
|
|
31366
|
+
return /* @__PURE__ */ jsxs33(Fragment9, { children: [
|
|
31367
|
+
/* @__PURE__ */ jsx55(
|
|
31370
31368
|
"div",
|
|
31371
31369
|
{
|
|
31372
31370
|
className: Slider_default.fill,
|
|
@@ -31375,7 +31373,7 @@ var Slider = forwardRef10(
|
|
|
31375
31373
|
}
|
|
31376
31374
|
}
|
|
31377
31375
|
),
|
|
31378
|
-
/* @__PURE__ */
|
|
31376
|
+
/* @__PURE__ */ jsx55($6f909507e6374d18$export$2c1b491743890dec, { className: Slider_default.thumb })
|
|
31379
31377
|
] });
|
|
31380
31378
|
} })
|
|
31381
31379
|
] });
|
|
@@ -31389,11 +31387,11 @@ var import_classnames45 = __toESM(require_classnames());
|
|
|
31389
31387
|
var StatusLight_default = { "statuslight": "StatusLight_statuslight__NGIzM", "status": "StatusLight_status__NjQ5O", "bg": "StatusLight_bg__MDIxM", "success": "StatusLight_success__NGRjZ", "warning": "StatusLight_warning__MTFhZ", "error": "StatusLight_error__NzBjO", "active": "StatusLight_active__YTJhM", "inactive": "StatusLight_inactive__ZDZmN" };
|
|
31390
31388
|
|
|
31391
31389
|
// src/components/StatusLight.tsx
|
|
31392
|
-
import { jsx as
|
|
31390
|
+
import { jsx as jsx56, jsxs as jsxs34 } from "react/jsx-runtime";
|
|
31393
31391
|
function StatusLight(props) {
|
|
31394
31392
|
const { color, variant = "inactive", children, className, ...domProps } = props;
|
|
31395
|
-
return /* @__PURE__ */
|
|
31396
|
-
/* @__PURE__ */
|
|
31393
|
+
return /* @__PURE__ */ jsxs34("div", { ...domProps, className: (0, import_classnames45.default)(StatusLight_default.statuslight, className), children: [
|
|
31394
|
+
/* @__PURE__ */ jsx56("div", { className: StatusLight_default.bg, children: /* @__PURE__ */ jsx56(
|
|
31397
31395
|
"div",
|
|
31398
31396
|
{
|
|
31399
31397
|
className: (0, import_classnames45.default)(StatusLight_default.status, StatusLight_default[variant]),
|
|
@@ -31412,13 +31410,13 @@ var import_classnames46 = __toESM(require_classnames());
|
|
|
31412
31410
|
var Switch_default = { "switch": "Switch_switch__YzA5O", "track": "Switch_track__MTM0M", "knob": "Switch_knob__OWM5N" };
|
|
31413
31411
|
|
|
31414
31412
|
// src/components/Switch.tsx
|
|
31415
|
-
import { Fragment as Fragment10, jsx as
|
|
31413
|
+
import { Fragment as Fragment10, jsx as jsx57, jsxs as jsxs35 } from "react/jsx-runtime";
|
|
31416
31414
|
var Switch = forwardRef11(
|
|
31417
31415
|
({ label, children, className, ...props }, ref) => {
|
|
31418
31416
|
const isSelected = typeof props.value !== "undefined" ? !!props.value : void 0;
|
|
31419
|
-
return /* @__PURE__ */
|
|
31420
|
-
label && /* @__PURE__ */
|
|
31421
|
-
/* @__PURE__ */
|
|
31417
|
+
return /* @__PURE__ */ jsxs35(Fragment10, { children: [
|
|
31418
|
+
label && /* @__PURE__ */ jsx57(Label, { children: label }),
|
|
31419
|
+
/* @__PURE__ */ jsxs35(
|
|
31422
31420
|
$8e59e948500a8fe1$export$b5d5cf8927ab7262,
|
|
31423
31421
|
{
|
|
31424
31422
|
...props,
|
|
@@ -31426,7 +31424,7 @@ var Switch = forwardRef11(
|
|
|
31426
31424
|
ref,
|
|
31427
31425
|
className: (0, import_classnames46.default)(Switch_default.switch, className),
|
|
31428
31426
|
children: [
|
|
31429
|
-
/* @__PURE__ */
|
|
31427
|
+
/* @__PURE__ */ jsx57("div", { className: Switch_default.track, children: /* @__PURE__ */ jsx57("div", { className: Switch_default.knob }) }),
|
|
31430
31428
|
children
|
|
31431
31429
|
]
|
|
31432
31430
|
}
|
|
@@ -31439,18 +31437,18 @@ var Switch = forwardRef11(
|
|
|
31439
31437
|
var Tabs_default = { "tabs": "Tabs_tabs__ZmM4Z", "list": "Tabs_list__MGM4O", "quiet": "Tabs_quiet__YmI3N", "tab": "Tabs_tab__NWEyN" };
|
|
31440
31438
|
|
|
31441
31439
|
// src/components/Tabs.tsx
|
|
31442
|
-
import { jsx as
|
|
31440
|
+
import { jsx as jsx58 } from "react/jsx-runtime";
|
|
31443
31441
|
function Tabs({ children, ...props }) {
|
|
31444
|
-
return /* @__PURE__ */
|
|
31442
|
+
return /* @__PURE__ */ jsx58($5e8ad37a45e1c704$export$b2539bed5023c21c, { ...props, className: Tabs_default.tabs, children });
|
|
31445
31443
|
}
|
|
31446
31444
|
function TabList({ children, ...props }) {
|
|
31447
|
-
return /* @__PURE__ */
|
|
31445
|
+
return /* @__PURE__ */ jsx58($5e8ad37a45e1c704$export$e51a686c67fdaa2d, { ...props, className: Tabs_default.list, children });
|
|
31448
31446
|
}
|
|
31449
31447
|
function Tab({ children, ...props }) {
|
|
31450
|
-
return /* @__PURE__ */
|
|
31448
|
+
return /* @__PURE__ */ jsx58($5e8ad37a45e1c704$export$3e41faf802a29e71, { ...props, className: Tabs_default.tab, children });
|
|
31451
31449
|
}
|
|
31452
31450
|
function TabPanel({ children, ...props }) {
|
|
31453
|
-
return /* @__PURE__ */
|
|
31451
|
+
return /* @__PURE__ */ jsx58($5e8ad37a45e1c704$export$3d96ec278d3efce4, { ...props, className: Tabs_default.panel, children });
|
|
31454
31452
|
}
|
|
31455
31453
|
|
|
31456
31454
|
// src/components/TextArea.tsx
|
|
@@ -31461,17 +31459,17 @@ import { forwardRef as forwardRef12 } from "react";
|
|
|
31461
31459
|
var TextArea_default = { "textarea": "TextArea_textarea__YzRiM", "resize-none": "TextArea_resize-none__ZTljZ", "resize-horizontal": "TextArea_resize-horizontal__NzgyN", "resize-vertical": "TextArea_resize-vertical__MTIxZ" };
|
|
31462
31460
|
|
|
31463
31461
|
// src/components/TextArea.tsx
|
|
31464
|
-
import { jsx as
|
|
31462
|
+
import { jsx as jsx59 } from "react/jsx-runtime";
|
|
31465
31463
|
var TextArea = forwardRef12(
|
|
31466
31464
|
({ rows, cols, resize, className, style, children, ...props }, ref) => {
|
|
31467
|
-
return /* @__PURE__ */
|
|
31465
|
+
return /* @__PURE__ */ jsx59(
|
|
31468
31466
|
TextField,
|
|
31469
31467
|
{
|
|
31470
31468
|
...props,
|
|
31471
31469
|
ref,
|
|
31472
31470
|
className: (0, import_classnames47.default)(resize && TextArea_default[`resize-${resize}`]),
|
|
31473
31471
|
asChild: true,
|
|
31474
|
-
children: /* @__PURE__ */
|
|
31472
|
+
children: /* @__PURE__ */ jsx59($216918bed6669f72$export$f5c9f3c2c4054eec, { rows, cols, style: { ...style }, children })
|
|
31475
31473
|
}
|
|
31476
31474
|
);
|
|
31477
31475
|
}
|
|
@@ -31484,7 +31482,7 @@ var import_classnames48 = __toESM(require_classnames());
|
|
|
31484
31482
|
var ThemeButton_default = { "button": "ThemeButton_button__OWVmZ" };
|
|
31485
31483
|
|
|
31486
31484
|
// src/components/ThemeButton.tsx
|
|
31487
|
-
import { jsx as
|
|
31485
|
+
import { jsx as jsx60, jsxs as jsxs36 } from "react/jsx-runtime";
|
|
31488
31486
|
function ThemeButton({ className, variant = "quiet", ...props }) {
|
|
31489
31487
|
const { theme, setTheme: setTheme2 } = useTheme();
|
|
31490
31488
|
const transitions = useTransition(theme, {
|
|
@@ -31502,7 +31500,7 @@ function ThemeButton({ className, variant = "quiet", ...props }) {
|
|
|
31502
31500
|
function handleClick() {
|
|
31503
31501
|
setTheme2(theme === "light" ? "dark" : "light");
|
|
31504
31502
|
}
|
|
31505
|
-
return /* @__PURE__ */
|
|
31503
|
+
return /* @__PURE__ */ jsxs36(
|
|
31506
31504
|
Button,
|
|
31507
31505
|
{
|
|
31508
31506
|
...props,
|
|
@@ -31512,7 +31510,7 @@ function ThemeButton({ className, variant = "quiet", ...props }) {
|
|
|
31512
31510
|
children: [
|
|
31513
31511
|
transitions((style, item) => (
|
|
31514
31512
|
// @ts-ignore
|
|
31515
|
-
/* @__PURE__ */
|
|
31513
|
+
/* @__PURE__ */ jsx60(animated.div, { style, children: /* @__PURE__ */ jsx60(Icon, { size: "sm", children: item === "light" ? /* @__PURE__ */ jsx60(Icons.Sun, {}) : /* @__PURE__ */ jsx60(Icons.Moon, {}) }) }, item)
|
|
31516
31514
|
)),
|
|
31517
31515
|
"\xA0"
|
|
31518
31516
|
]
|
|
@@ -31528,13 +31526,13 @@ var import_classnames49 = __toESM(require_classnames());
|
|
|
31528
31526
|
var Toggle_default = { "toggle": "Toggle_toggle__NGNlM" };
|
|
31529
31527
|
|
|
31530
31528
|
// src/components/Toggle.tsx
|
|
31531
|
-
import { Fragment as Fragment11, jsx as
|
|
31529
|
+
import { Fragment as Fragment11, jsx as jsx61, jsxs as jsxs37 } from "react/jsx-runtime";
|
|
31532
31530
|
var Toggle = forwardRef13(
|
|
31533
31531
|
({ label, children, className, ...props }, ref) => {
|
|
31534
31532
|
const isSelected = typeof props.value !== "undefined" ? !!props.value : void 0;
|
|
31535
|
-
return /* @__PURE__ */
|
|
31536
|
-
label && /* @__PURE__ */
|
|
31537
|
-
/* @__PURE__ */
|
|
31533
|
+
return /* @__PURE__ */ jsxs37(Fragment11, { children: [
|
|
31534
|
+
label && /* @__PURE__ */ jsx61(Label, { children: label }),
|
|
31535
|
+
/* @__PURE__ */ jsx61(
|
|
31538
31536
|
$efde0372d7a700fe$export$d2b052e7b4be1756,
|
|
31539
31537
|
{
|
|
31540
31538
|
...props,
|
|
@@ -31555,15 +31553,15 @@ var import_classnames50 = __toESM(require_classnames());
|
|
|
31555
31553
|
var ToggleGroup_default = { "group": "ToggleGroup_group__NDAzY", "list": "ToggleGroup_list__ZDEwO", "item": "ToggleGroup_item__N2ZmN" };
|
|
31556
31554
|
|
|
31557
31555
|
// src/components/ToggleGroup.tsx
|
|
31558
|
-
import { jsx as
|
|
31556
|
+
import { jsx as jsx62, jsxs as jsxs38 } from "react/jsx-runtime";
|
|
31559
31557
|
function ToggleGroup({ label, className, children, ...props }) {
|
|
31560
|
-
return /* @__PURE__ */
|
|
31561
|
-
label && /* @__PURE__ */
|
|
31562
|
-
/* @__PURE__ */
|
|
31558
|
+
return /* @__PURE__ */ jsxs38($eaf9e70818b436db$export$67ea30858aaf75e3, { ...props, className: (0, import_classnames50.default)(ToggleGroup_default.group, className), selectionBehavior: "toggle", children: [
|
|
31559
|
+
label && /* @__PURE__ */ jsx62(Label, { children: label }),
|
|
31560
|
+
/* @__PURE__ */ jsx62($eaf9e70818b436db$export$f9fef0f55402315b, { className: ToggleGroup_default.list, children })
|
|
31563
31561
|
] });
|
|
31564
31562
|
}
|
|
31565
31563
|
function ToggleGroupItem({ className, children, ...props }) {
|
|
31566
|
-
return /* @__PURE__ */
|
|
31564
|
+
return /* @__PURE__ */ jsx62($eaf9e70818b436db$export$3288d34c523a1192, { ...props, className: (0, import_classnames50.default)(ToggleGroup_default.item, className), children });
|
|
31567
31565
|
}
|
|
31568
31566
|
|
|
31569
31567
|
// src/components/Tooltip.tsx
|
|
@@ -31573,19 +31571,19 @@ var import_classnames51 = __toESM(require_classnames());
|
|
|
31573
31571
|
var Tooltip_default = { "tooltip": "Tooltip_tooltip__Y2Y2N", "arrow": "Tooltip_arrow__NzgwN", "slide": "Tooltip_slide__ODJjZ" };
|
|
31574
31572
|
|
|
31575
31573
|
// src/components/Tooltip.tsx
|
|
31576
|
-
import { jsx as
|
|
31574
|
+
import { jsx as jsx63, jsxs as jsxs39 } from "react/jsx-runtime";
|
|
31577
31575
|
function Tooltip({ children, className, ...props }) {
|
|
31578
|
-
return /* @__PURE__ */
|
|
31579
|
-
/* @__PURE__ */
|
|
31576
|
+
return /* @__PURE__ */ jsxs39($4e3b923658d69c60$export$28c660c63b792dea, { ...props, className: (0, import_classnames51.default)(Tooltip_default.tooltip, className), children: [
|
|
31577
|
+
/* @__PURE__ */ jsx63($44f671af83e7d9e0$export$746d02f47f4d381, { className: Tooltip_default.arrow, children: /* @__PURE__ */ jsx63("svg", { width: 8, height: 8, viewBox: "0 0 8 8", children: /* @__PURE__ */ jsx63("path", { d: "M0 0 L4 4 L8 0" }) }) }),
|
|
31580
31578
|
children
|
|
31581
31579
|
] });
|
|
31582
31580
|
}
|
|
31583
31581
|
|
|
31584
31582
|
// src/components/ZenProvider.tsx
|
|
31585
|
-
import { jsx as
|
|
31583
|
+
import { jsx as jsx64 } from "react/jsx-runtime";
|
|
31586
31584
|
function ZenProvider({ children, ...props }) {
|
|
31587
31585
|
const { toast } = props;
|
|
31588
|
-
return /* @__PURE__ */
|
|
31586
|
+
return /* @__PURE__ */ jsx64(ToastProvider, { ...toast, children });
|
|
31589
31587
|
}
|
|
31590
31588
|
export {
|
|
31591
31589
|
Accordion,
|
|
@@ -31631,7 +31629,6 @@ export {
|
|
|
31631
31629
|
Menu,
|
|
31632
31630
|
MenuItem2 as MenuItem,
|
|
31633
31631
|
$3674c52c6b3c5bce$export$27d2ad3c5815583e as MenuTrigger,
|
|
31634
|
-
MobileMenuButton,
|
|
31635
31632
|
Modal,
|
|
31636
31633
|
NavigationMenu,
|
|
31637
31634
|
NavigationMenuItem,
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@umami/react-zen",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.41.0",
|
|
4
4
|
"description": "React components built by Umami",
|
|
5
5
|
"author": "Umami <hello@umami.is>",
|
|
6
6
|
"license": "MIT",
|
|
@@ -49,7 +49,7 @@
|
|
|
49
49
|
"@fontsource/jetbrains-mono": "^5.0.18",
|
|
50
50
|
"@react-spring/web": "^9.7.5",
|
|
51
51
|
"@umami/esbuild-plugin-css-modules": "0.2.0",
|
|
52
|
-
"@umami/shiso": "^0.
|
|
52
|
+
"@umami/shiso": "^0.26.0",
|
|
53
53
|
"classnames": "^2.5.1",
|
|
54
54
|
"dts-bundle": "^0.7.3",
|
|
55
55
|
"glob": "^10.3.10",
|