@bug-on/m3-expressive 1.3.3 → 1.3.5
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/CHANGELOG.md +21 -0
- package/README.md +31 -7
- package/dist/assets/material-symbols-cdn.css +17 -23
- package/dist/buttons.js +129 -35
- package/dist/buttons.js.map +1 -1
- package/dist/buttons.mjs +129 -35
- package/dist/buttons.mjs.map +1 -1
- package/dist/{core-DyEy8H9Z.d.ts → core-Cckt8qEm.d.ts} +11 -8
- package/dist/{core-D8FdHY6I.d.mts → core-DDfG4pym.d.mts} +11 -8
- package/dist/core.d.mts +2 -3
- package/dist/core.d.ts +2 -3
- package/dist/core.js +7 -7
- package/dist/core.js.map +1 -1
- package/dist/core.mjs +8 -7
- package/dist/core.mjs.map +1 -1
- package/dist/fading-blur-mask--uZbBKLj.d.mts +77 -0
- package/dist/fading-blur-mask--uZbBKLj.d.ts +77 -0
- package/dist/feedback.js +1 -1
- package/dist/feedback.js.map +1 -1
- package/dist/feedback.mjs +1 -1
- package/dist/feedback.mjs.map +1 -1
- package/dist/forms.js +1 -1
- package/dist/forms.js.map +1 -1
- package/dist/forms.mjs +1 -1
- package/dist/forms.mjs.map +1 -1
- package/dist/index.d.mts +5 -5
- package/dist/index.d.ts +5 -5
- package/dist/index.js +270 -127
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +271 -127
- package/dist/index.mjs.map +1 -1
- package/dist/layout.d.mts +5 -3
- package/dist/layout.d.ts +5 -3
- package/dist/layout.js +61 -6
- package/dist/layout.js.map +1 -1
- package/dist/layout.mjs +61 -7
- package/dist/layout.mjs.map +1 -1
- package/dist/material-symbols-cdn.css +17 -23
- package/dist/navigation.d.mts +25 -83
- package/dist/navigation.d.ts +25 -83
- package/dist/navigation.js +22 -9
- package/dist/navigation.js.map +1 -1
- package/dist/navigation.mjs +22 -9
- package/dist/navigation.mjs.map +1 -1
- package/dist/overlays.js +1 -1
- package/dist/overlays.js.map +1 -1
- package/dist/overlays.mjs +1 -1
- package/dist/overlays.mjs.map +1 -1
- package/dist/pickers.d.mts +12 -0
- package/dist/pickers.d.ts +12 -0
- package/dist/pickers.js +98 -65
- package/dist/pickers.js.map +1 -1
- package/dist/pickers.mjs +98 -65
- package/dist/pickers.mjs.map +1 -1
- package/dist/{typography-339RV6v7.d.mts → typography-CKTjvlZ4.d.mts} +25 -0
- package/dist/{typography-339RV6v7.d.ts → typography-CKTjvlZ4.d.ts} +25 -0
- package/dist/typography.css +1 -1
- package/llms-full.txt +17 -13
- package/llms.txt +11 -6
- package/package.json +18 -18
package/dist/index.mjs
CHANGED
|
@@ -3,9 +3,9 @@ import * as React67 from 'react';
|
|
|
3
3
|
import { createContext, forwardRef, useState, useRef, useCallback, useMemo, useEffect, useLayoutEffect, useReducer, useContext, useId, cloneElement, createElement } from 'react';
|
|
4
4
|
import { hexFromArgb, Hct, SchemeExpressive, SchemeNeutral, SchemeMonochrome, SchemeContent, SchemeFidelity, SchemeVibrant, SchemeTonalSpot } from '@material/material-color-utilities';
|
|
5
5
|
import { jsxs, jsx, Fragment } from 'react/jsx-runtime';
|
|
6
|
+
import { AnimatePresence, m, LazyMotion, domMax, useReducedMotion, useMotionValue, animate, useAnimationFrame, useSpring, useTransform, LayoutGroup, useScroll, useMotionValueEvent } from 'motion/react';
|
|
6
7
|
import { clsx } from 'clsx';
|
|
7
8
|
import { twMerge } from 'tailwind-merge';
|
|
8
|
-
import { AnimatePresence, m, LazyMotion, domMax, useReducedMotion, useMotionValue, animate, useAnimationFrame, useSpring, useTransform, LayoutGroup, useScroll, useMotionValueEvent } from 'motion/react';
|
|
9
9
|
import * as RxContextMenu from '@radix-ui/react-context-menu';
|
|
10
10
|
import * as RadixScrollArea from '@radix-ui/react-scroll-area';
|
|
11
11
|
import { cornerRadius } from '@bug-on/m3-tokens';
|
|
@@ -256,7 +256,8 @@ function schemeToCssVariables(scheme) {
|
|
|
256
256
|
return result;
|
|
257
257
|
}
|
|
258
258
|
function MaterialSymbolsPreconnect({
|
|
259
|
-
variants = ["
|
|
259
|
+
variants = ["rounded"],
|
|
260
|
+
display = "block"
|
|
260
261
|
}) {
|
|
261
262
|
return /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
262
263
|
/* @__PURE__ */ jsx("link", { rel: "preconnect", href: "https://fonts.googleapis.com" }),
|
|
@@ -271,7 +272,7 @@ function MaterialSymbolsPreconnect({
|
|
|
271
272
|
variants.includes("outlined") && /* @__PURE__ */ jsx(
|
|
272
273
|
"link",
|
|
273
274
|
{
|
|
274
|
-
href:
|
|
275
|
+
href: `https://fonts.googleapis.com/css2?family=Material+Symbols+Outlined:opsz,wght,FILL,GRAD@20..48,100..700,0..1,-50..200&display=${display}`,
|
|
275
276
|
rel: "stylesheet",
|
|
276
277
|
precedence: "default"
|
|
277
278
|
}
|
|
@@ -279,7 +280,7 @@ function MaterialSymbolsPreconnect({
|
|
|
279
280
|
variants.includes("rounded") && /* @__PURE__ */ jsx(
|
|
280
281
|
"link",
|
|
281
282
|
{
|
|
282
|
-
href:
|
|
283
|
+
href: `https://fonts.googleapis.com/css2?family=Material+Symbols+Rounded:opsz,wght,FILL,GRAD@20..48,100..700,0..1,-50..200&display=${display}`,
|
|
283
284
|
rel: "stylesheet",
|
|
284
285
|
precedence: "default"
|
|
285
286
|
}
|
|
@@ -287,16 +288,13 @@ function MaterialSymbolsPreconnect({
|
|
|
287
288
|
variants.includes("sharp") && /* @__PURE__ */ jsx(
|
|
288
289
|
"link",
|
|
289
290
|
{
|
|
290
|
-
href:
|
|
291
|
+
href: `https://fonts.googleapis.com/css2?family=Material+Symbols+Sharp:opsz,wght,FILL,GRAD@20..48,100..700,0..1,-50..200&display=${display}`,
|
|
291
292
|
rel: "stylesheet",
|
|
292
293
|
precedence: "default"
|
|
293
294
|
}
|
|
294
295
|
)
|
|
295
296
|
] });
|
|
296
297
|
}
|
|
297
|
-
function cn(...inputs) {
|
|
298
|
-
return twMerge(clsx(inputs));
|
|
299
|
-
}
|
|
300
298
|
|
|
301
299
|
// src/shapes/core/features.ts
|
|
302
300
|
function cornerFeature(cubics, convex2) {
|
|
@@ -2830,12 +2828,15 @@ function interpolatePath(morph, progress, width, height) {
|
|
|
2830
2828
|
function fmt(v) {
|
|
2831
2829
|
return Number(v.toFixed(4)).toString();
|
|
2832
2830
|
}
|
|
2831
|
+
function cn(...inputs) {
|
|
2832
|
+
return twMerge(clsx(inputs));
|
|
2833
|
+
}
|
|
2833
2834
|
function getMaskGradient(direction) {
|
|
2834
2835
|
switch (direction) {
|
|
2835
2836
|
case "bottom":
|
|
2836
2837
|
return "linear-gradient(to top, rgba(0, 0, 0, 1) 0%, rgba(0, 0, 0, 1) 45%, rgba(0, 0, 0, 0.7) 75%, rgba(0, 0, 0, 0) 100%)";
|
|
2837
2838
|
case "both":
|
|
2838
|
-
return "linear-gradient(to bottom, rgba(0, 0, 0,
|
|
2839
|
+
return "linear-gradient(to bottom, rgba(0, 0, 0, 1) 0%, rgba(0, 0, 0, 0.7) 15%, rgba(0, 0, 0, 0) 30%, rgba(0, 0, 0, 0) 70%, rgba(0, 0, 0, 0.7) 85%, rgba(0, 0, 0, 1) 100%)";
|
|
2839
2840
|
default:
|
|
2840
2841
|
return "linear-gradient(to bottom, rgba(0, 0, 0, 1) 0%, rgba(0, 0, 0, 1) 45%, rgba(0, 0, 0, 0.7) 75%, rgba(0, 0, 0, 0) 100%)";
|
|
2841
2842
|
}
|
|
@@ -2852,11 +2853,16 @@ function FadingBlurMask({
|
|
|
2852
2853
|
const shouldReduceMotion = useReducedMotion();
|
|
2853
2854
|
const activeBlur = shouldReduceMotion ? 0 : blurIntensity;
|
|
2854
2855
|
const maskGradient = getMaskGradient(direction);
|
|
2856
|
+
const isFullHeight = direction === "both" || blurHeight === "100%";
|
|
2857
|
+
const computedHeight = isFullHeight ? "100%" : typeof blurHeight === "number" ? `${blurHeight}px` : blurHeight;
|
|
2855
2858
|
const maskStyle = __spreadValues({
|
|
2856
2859
|
position: "absolute",
|
|
2857
|
-
|
|
2860
|
+
top: direction === "bottom" && !isFullHeight ? "auto" : 0,
|
|
2861
|
+
bottom: direction === "top" && !isFullHeight ? "auto" : 0,
|
|
2862
|
+
left: 0,
|
|
2863
|
+
right: 0,
|
|
2858
2864
|
pointerEvents: "none",
|
|
2859
|
-
height:
|
|
2865
|
+
height: computedHeight,
|
|
2860
2866
|
backdropFilter: activeBlur > 0 ? `blur(${activeBlur}px)` : void 0,
|
|
2861
2867
|
WebkitBackdropFilter: activeBlur > 0 ? `blur(${activeBlur}px)` : void 0,
|
|
2862
2868
|
maskImage: maskGradient,
|
|
@@ -2868,7 +2874,7 @@ function FadingBlurMask({
|
|
|
2868
2874
|
{
|
|
2869
2875
|
"aria-hidden": "true",
|
|
2870
2876
|
className: cn(
|
|
2871
|
-
"absolute
|
|
2877
|
+
"absolute pointer-events-none z-10 rounded-[inherit]",
|
|
2872
2878
|
className
|
|
2873
2879
|
),
|
|
2874
2880
|
style: maskStyle,
|
|
@@ -3996,7 +4002,7 @@ var IconComponent = React67.forwardRef(
|
|
|
3996
4002
|
(_a, ref) => {
|
|
3997
4003
|
var _b = _a, {
|
|
3998
4004
|
name,
|
|
3999
|
-
variant = "
|
|
4005
|
+
variant = "rounded",
|
|
4000
4006
|
fill = 0,
|
|
4001
4007
|
weight = 400,
|
|
4002
4008
|
grade = 0,
|
|
@@ -8331,6 +8337,7 @@ var ExtendedFABComponent = React67.forwardRef(
|
|
|
8331
8337
|
onClick,
|
|
8332
8338
|
onKeyDown,
|
|
8333
8339
|
layoutId,
|
|
8340
|
+
layout,
|
|
8334
8341
|
"aria-label": ariaLabel
|
|
8335
8342
|
} = _b, restProps = __objRest(_b, [
|
|
8336
8343
|
"className",
|
|
@@ -8352,6 +8359,7 @@ var ExtendedFABComponent = React67.forwardRef(
|
|
|
8352
8359
|
"onClick",
|
|
8353
8360
|
"onKeyDown",
|
|
8354
8361
|
"layoutId",
|
|
8362
|
+
"layout",
|
|
8355
8363
|
"aria-label"
|
|
8356
8364
|
]);
|
|
8357
8365
|
var _a2, _b2, _c, _d;
|
|
@@ -8376,6 +8384,13 @@ var ExtendedFABComponent = React67.forwardRef(
|
|
|
8376
8384
|
const colors = (_a2 = COLOR_CLASSES[colorStyle]) != null ? _a2 : COLOR_CLASSES.primary;
|
|
8377
8385
|
const radiusConfig = (_b2 = MORPH_RADIUS[size]) != null ? _b2 : MORPH_RADIUS.sm;
|
|
8378
8386
|
const sizeIcon = (_c = SIZE_ICON[size]) != null ? _c : SIZE_ICON.sm;
|
|
8387
|
+
const motionRadius = useMotionValue(radiusConfig.default);
|
|
8388
|
+
React67.useEffect(() => {
|
|
8389
|
+
const controls = animate(motionRadius, radiusConfig.default, __spreadProps(__spreadValues({}, SPRING_TRANSITION), {
|
|
8390
|
+
type: "spring"
|
|
8391
|
+
}));
|
|
8392
|
+
return () => controls.stop();
|
|
8393
|
+
}, [radiusConfig.default, motionRadius]);
|
|
8379
8394
|
const { ripples, onPointerDown, removeRipple } = useRippleState({
|
|
8380
8395
|
disabled: loading
|
|
8381
8396
|
});
|
|
@@ -8470,13 +8485,25 @@ var ExtendedFABComponent = React67.forwardRef(
|
|
|
8470
8485
|
{
|
|
8471
8486
|
layout: "position",
|
|
8472
8487
|
initial: { opacity: 0, width: 0 },
|
|
8473
|
-
animate: {
|
|
8474
|
-
|
|
8475
|
-
|
|
8476
|
-
|
|
8477
|
-
|
|
8488
|
+
animate: {
|
|
8489
|
+
opacity: 1,
|
|
8490
|
+
width: "auto",
|
|
8491
|
+
transition: {
|
|
8492
|
+
width: SPRING_TRANSITION,
|
|
8493
|
+
opacity: { delay: 0.08, duration: 0.15, ease: "easeIn" },
|
|
8494
|
+
layout: SPRING_TRANSITION
|
|
8495
|
+
}
|
|
8496
|
+
},
|
|
8497
|
+
exit: {
|
|
8498
|
+
opacity: 0,
|
|
8499
|
+
width: 0,
|
|
8500
|
+
transition: {
|
|
8501
|
+
opacity: { duration: 0.1, ease: "linear" },
|
|
8502
|
+
width: __spreadProps(__spreadValues({}, SPRING_TRANSITION), { delay: 0.03 }),
|
|
8503
|
+
layout: SPRING_TRANSITION
|
|
8504
|
+
}
|
|
8478
8505
|
},
|
|
8479
|
-
className: "overflow-hidden whitespace-nowrap",
|
|
8506
|
+
className: "overflow-hidden whitespace-nowrap shrink-0 inline-block",
|
|
8480
8507
|
children: label
|
|
8481
8508
|
},
|
|
8482
8509
|
"label"
|
|
@@ -8507,7 +8534,7 @@ var ExtendedFABComponent = React67.forwardRef(
|
|
|
8507
8534
|
__spreadProps(__spreadValues({
|
|
8508
8535
|
ref: localRef,
|
|
8509
8536
|
type: "button",
|
|
8510
|
-
layout:
|
|
8537
|
+
layout: layout !== void 0 ? layout : "position",
|
|
8511
8538
|
layoutId,
|
|
8512
8539
|
"aria-label": ariaLabel || label,
|
|
8513
8540
|
"aria-busy": loading || void 0,
|
|
@@ -8515,21 +8542,23 @@ var ExtendedFABComponent = React67.forwardRef(
|
|
|
8515
8542
|
onClick: handleClick,
|
|
8516
8543
|
onPointerDown,
|
|
8517
8544
|
onKeyDown: handleKeyDown,
|
|
8518
|
-
style,
|
|
8545
|
+
style: __spreadProps(__spreadValues({}, style), {
|
|
8546
|
+
borderRadius: motionRadius
|
|
8547
|
+
}),
|
|
8519
8548
|
initial: {
|
|
8520
8549
|
scale: 0.6,
|
|
8521
|
-
opacity: 0
|
|
8522
|
-
borderRadius: radiusConfig.default
|
|
8550
|
+
opacity: 0
|
|
8523
8551
|
},
|
|
8524
8552
|
animate: {
|
|
8525
8553
|
scale: 1,
|
|
8526
|
-
opacity: 1
|
|
8527
|
-
borderRadius: radiusConfig.default
|
|
8554
|
+
opacity: 1
|
|
8528
8555
|
},
|
|
8529
8556
|
exit: { scale: 0.6, opacity: 0 },
|
|
8530
|
-
whileTap: {
|
|
8557
|
+
whileTap: {
|
|
8558
|
+
borderRadius: radiusConfig.pressed,
|
|
8559
|
+
transition: { borderRadius: SPRING_TRANSITION_FAST }
|
|
8560
|
+
},
|
|
8531
8561
|
transition: {
|
|
8532
|
-
borderRadius: { type: "spring", stiffness: 500, damping: 30 },
|
|
8533
8562
|
scale: SPRING_TRANSITION,
|
|
8534
8563
|
opacity: { duration: 0.2, ease: "linear" },
|
|
8535
8564
|
layout: SPRING_TRANSITION
|
|
@@ -8561,6 +8590,18 @@ var SIZE_TEXT_CLASS = {
|
|
|
8561
8590
|
lg: "text-xl font-semibold",
|
|
8562
8591
|
xl: "text-2xl font-semibold"
|
|
8563
8592
|
};
|
|
8593
|
+
var SIZE_PADDING_COLLAPSED = {
|
|
8594
|
+
sm: "px-2",
|
|
8595
|
+
md: "px-4",
|
|
8596
|
+
lg: "px-8",
|
|
8597
|
+
xl: "px-12"
|
|
8598
|
+
};
|
|
8599
|
+
var SIZE_PADDING_EXTENDED = {
|
|
8600
|
+
sm: "pl-2 pr-4",
|
|
8601
|
+
md: "pl-4 pr-6",
|
|
8602
|
+
lg: "pl-8 pr-8",
|
|
8603
|
+
xl: "pl-12 pr-10"
|
|
8604
|
+
};
|
|
8564
8605
|
var MORPH_RADIUS2 = {
|
|
8565
8606
|
sm: { default: 12, pressed: 8, extended: 12, extended_pressed: 8 },
|
|
8566
8607
|
md: { default: 16, pressed: 10, extended: 16, extended_pressed: 10 },
|
|
@@ -8652,7 +8693,7 @@ var FABComponent = React67.forwardRef(
|
|
|
8652
8693
|
"layout",
|
|
8653
8694
|
"layoutId"
|
|
8654
8695
|
]);
|
|
8655
|
-
var _a2, _b2, _c, _d;
|
|
8696
|
+
var _a2, _b2, _c, _d, _e, _f;
|
|
8656
8697
|
const colors = (_a2 = COLOR_CLASSES2[colorStyle]) != null ? _a2 : COLOR_CLASSES2.primary;
|
|
8657
8698
|
const radiusConfig = (_b2 = MORPH_RADIUS2[size]) != null ? _b2 : MORPH_RADIUS2.md;
|
|
8658
8699
|
const animateRadius = extended ? radiusConfig.extended : radiusConfig.default;
|
|
@@ -8737,22 +8778,37 @@ var FABComponent = React67.forwardRef(
|
|
|
8737
8778
|
m.span,
|
|
8738
8779
|
{
|
|
8739
8780
|
layout: "position",
|
|
8740
|
-
initial: { width: 0, opacity: 0 },
|
|
8741
|
-
animate: {
|
|
8742
|
-
|
|
8743
|
-
|
|
8744
|
-
|
|
8745
|
-
|
|
8746
|
-
|
|
8781
|
+
initial: { width: 0, opacity: 0, marginLeft: 0 },
|
|
8782
|
+
animate: {
|
|
8783
|
+
width: "auto",
|
|
8784
|
+
opacity: 1,
|
|
8785
|
+
marginLeft: 12,
|
|
8786
|
+
transition: {
|
|
8787
|
+
width: SPRING_TRANSITION,
|
|
8788
|
+
marginLeft: SPRING_TRANSITION,
|
|
8789
|
+
opacity: { delay: 0.08, duration: 0.15, ease: "easeIn" },
|
|
8790
|
+
layout: SPRING_TRANSITION
|
|
8791
|
+
}
|
|
8747
8792
|
},
|
|
8748
|
-
|
|
8793
|
+
exit: {
|
|
8794
|
+
width: 0,
|
|
8795
|
+
opacity: 0,
|
|
8796
|
+
marginLeft: 0,
|
|
8797
|
+
transition: {
|
|
8798
|
+
opacity: { duration: 0.1, ease: "linear" },
|
|
8799
|
+
width: __spreadProps(__spreadValues({}, SPRING_TRANSITION), { delay: 0.03 }),
|
|
8800
|
+
marginLeft: __spreadProps(__spreadValues({}, SPRING_TRANSITION), { delay: 0.03 }),
|
|
8801
|
+
layout: SPRING_TRANSITION
|
|
8802
|
+
}
|
|
8803
|
+
},
|
|
8804
|
+
className: "overflow-hidden whitespace-nowrap shrink-0 inline-block",
|
|
8749
8805
|
children: labelContent
|
|
8750
8806
|
},
|
|
8751
8807
|
"label"
|
|
8752
8808
|
) })
|
|
8753
8809
|
] });
|
|
8754
8810
|
const containerClassName = cn(
|
|
8755
|
-
"relative shrink-0 inline-flex items-center justify-
|
|
8811
|
+
"relative shrink-0 inline-flex items-center justify-start",
|
|
8756
8812
|
"select-none cursor-pointer overflow-hidden",
|
|
8757
8813
|
"transition-[box-shadow,opacity,filter] duration-200",
|
|
8758
8814
|
"focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-m3-primary focus-visible:ring-offset-2",
|
|
@@ -8761,21 +8817,62 @@ var FABComponent = React67.forwardRef(
|
|
|
8761
8817
|
colors.text,
|
|
8762
8818
|
lowered ? "shadow-sm" : colors.shadow,
|
|
8763
8819
|
(_d = SIZE_STYLES[size]) != null ? _d : "h-14 w-14",
|
|
8764
|
-
extended
|
|
8820
|
+
extended ? cn("w-auto", (_e = SIZE_PADDING_EXTENDED[size]) != null ? _e : "pl-4 pr-6") : (_f = SIZE_PADDING_COLLAPSED[size]) != null ? _f : "px-4",
|
|
8765
8821
|
SIZE_TEXT_CLASS[size],
|
|
8766
8822
|
loading && "pointer-events-none opacity-75 cursor-not-allowed",
|
|
8767
8823
|
className
|
|
8768
8824
|
);
|
|
8825
|
+
const motionRadius = useMotionValue(animateRadius);
|
|
8826
|
+
const asChildRef = React67.useRef(null);
|
|
8827
|
+
const mergedRef = React67.useCallback(
|
|
8828
|
+
(node) => {
|
|
8829
|
+
asChildRef.current = node;
|
|
8830
|
+
if (typeof ref === "function") ref(node);
|
|
8831
|
+
else if (ref)
|
|
8832
|
+
ref.current = node;
|
|
8833
|
+
},
|
|
8834
|
+
[ref]
|
|
8835
|
+
);
|
|
8836
|
+
React67.useEffect(() => {
|
|
8837
|
+
if (!asChild) return;
|
|
8838
|
+
return motionRadius.on("change", (v) => {
|
|
8839
|
+
if (asChildRef.current)
|
|
8840
|
+
asChildRef.current.style.borderRadius = `${v}px`;
|
|
8841
|
+
});
|
|
8842
|
+
}, [motionRadius, asChild]);
|
|
8843
|
+
React67.useEffect(() => {
|
|
8844
|
+
const controls = animate(motionRadius, animateRadius, __spreadProps(__spreadValues({}, SPRING_TRANSITION), {
|
|
8845
|
+
type: "spring"
|
|
8846
|
+
}));
|
|
8847
|
+
return () => controls.stop();
|
|
8848
|
+
}, [animateRadius, motionRadius]);
|
|
8849
|
+
const handleAsChildPointerDown = React67.useCallback(
|
|
8850
|
+
(e) => {
|
|
8851
|
+
onPointerDown(e);
|
|
8852
|
+
animate(motionRadius, pressedRadius, __spreadProps(__spreadValues({}, SPRING_TRANSITION_FAST), {
|
|
8853
|
+
type: "spring"
|
|
8854
|
+
}));
|
|
8855
|
+
},
|
|
8856
|
+
[onPointerDown, motionRadius, pressedRadius]
|
|
8857
|
+
);
|
|
8858
|
+
const handleAsChildPointerUp = React67.useCallback(() => {
|
|
8859
|
+
animate(motionRadius, animateRadius, __spreadProps(__spreadValues({}, SPRING_TRANSITION_FAST), {
|
|
8860
|
+
type: "spring"
|
|
8861
|
+
}));
|
|
8862
|
+
}, [motionRadius, animateRadius]);
|
|
8769
8863
|
const computedAriaLabel = ariaLabel || (typeof children === "string" ? children : void 0);
|
|
8770
8864
|
return /* @__PURE__ */ jsx(LazyMotion, { features: domMax, strict: true, children: /* @__PURE__ */ jsx(AnimatePresence, { children: visible && (asChild ? /* @__PURE__ */ jsx(
|
|
8771
8865
|
Slot,
|
|
8772
8866
|
__spreadProps(__spreadValues({
|
|
8773
|
-
ref,
|
|
8867
|
+
ref: mergedRef,
|
|
8774
8868
|
"aria-label": computedAriaLabel,
|
|
8775
8869
|
"aria-busy": loading || void 0,
|
|
8776
8870
|
"aria-disabled": loading || restProps.disabled,
|
|
8777
8871
|
onClick: handleClick,
|
|
8778
|
-
onPointerDown,
|
|
8872
|
+
onPointerDown: handleAsChildPointerDown,
|
|
8873
|
+
onPointerUp: handleAsChildPointerUp,
|
|
8874
|
+
onPointerLeave: handleAsChildPointerUp,
|
|
8875
|
+
onPointerCancel: handleAsChildPointerUp,
|
|
8779
8876
|
onKeyDown: handleKeyDown,
|
|
8780
8877
|
style: __spreadProps(__spreadValues({}, style), {
|
|
8781
8878
|
borderRadius: `${animateRadius}px`
|
|
@@ -8792,7 +8889,7 @@ var FABComponent = React67.forwardRef(
|
|
|
8792
8889
|
__spreadProps(__spreadValues({
|
|
8793
8890
|
ref,
|
|
8794
8891
|
type: "button",
|
|
8795
|
-
layout: layout !== void 0 ? layout :
|
|
8892
|
+
layout: layout !== void 0 ? layout : "position",
|
|
8796
8893
|
layoutId,
|
|
8797
8894
|
"aria-label": computedAriaLabel,
|
|
8798
8895
|
"aria-busy": loading || void 0,
|
|
@@ -8800,17 +8897,20 @@ var FABComponent = React67.forwardRef(
|
|
|
8800
8897
|
onClick: handleClick,
|
|
8801
8898
|
onPointerDown,
|
|
8802
8899
|
onKeyDown: handleKeyDown,
|
|
8803
|
-
style,
|
|
8900
|
+
style: __spreadProps(__spreadValues({}, style), {
|
|
8901
|
+
borderRadius: motionRadius
|
|
8902
|
+
}),
|
|
8804
8903
|
initial: {
|
|
8805
8904
|
scale: 0.5,
|
|
8806
|
-
opacity: 0
|
|
8807
|
-
borderRadius: animateRadius
|
|
8905
|
+
opacity: 0
|
|
8808
8906
|
},
|
|
8809
|
-
animate: { scale: 1, opacity: 1
|
|
8907
|
+
animate: { scale: 1, opacity: 1 },
|
|
8810
8908
|
exit: { scale: 0.5, opacity: 0 },
|
|
8811
|
-
whileTap: {
|
|
8909
|
+
whileTap: {
|
|
8910
|
+
borderRadius: pressedRadius,
|
|
8911
|
+
transition: { borderRadius: SPRING_TRANSITION_FAST }
|
|
8912
|
+
},
|
|
8812
8913
|
transition: {
|
|
8813
|
-
borderRadius: SPRING_TRANSITION_FAST,
|
|
8814
8914
|
scale: SPRING_TRANSITION,
|
|
8815
8915
|
opacity: { duration: 0.25, ease: "easeOut" },
|
|
8816
8916
|
layout: SPRING_TRANSITION
|
|
@@ -13287,7 +13387,7 @@ var CalendarGrid = ({
|
|
|
13287
13387
|
] });
|
|
13288
13388
|
};
|
|
13289
13389
|
CalendarGrid.displayName = "CalendarGrid";
|
|
13290
|
-
var selectorClassName = "flex items-center gap-1 rounded-m3-full px-2 py-1 text-[length:var(--md-typescale-title-small-size,14px)] font-[number:var(--md-typescale-title-small-weight,500)] text-m3-on-surface transition-m3-fast-effects hover:bg-m3-on-surface/8 focus-visible:outline-2 focus-visible:outline-m3-primary";
|
|
13390
|
+
var selectorClassName = "flex items-center gap-1 rounded-m3-full px-2 py-1 text-[length:var(--md-typescale-title-small-size,14px)] font-[number:var(--md-typescale-title-small-weight,500)] text-m3-on-surface transition-m3-fast-effects hover:bg-m3-on-surface/8 focus-visible:outline-2 focus-visible:outline-m3-primary whitespace-nowrap select-none min-w-0";
|
|
13291
13391
|
var CalendarHeader = ({
|
|
13292
13392
|
displayedMonthMs,
|
|
13293
13393
|
activeSelector,
|
|
@@ -13313,57 +13413,70 @@ var CalendarHeader = ({
|
|
|
13313
13413
|
timeZone: "UTC"
|
|
13314
13414
|
}).format(date);
|
|
13315
13415
|
const yearLabel = String(date.getUTCFullYear());
|
|
13316
|
-
return /* @__PURE__ */ jsxs("div", { className: "flex flex-col gap-1 px-6 pb-
|
|
13317
|
-
/* @__PURE__ */ jsx("div", { className: "text-(length:--md-typescale-label-large-size,14px) font-(--md-typescale-label-large-weight,500) text-m3-on-surface-variant", children: title }),
|
|
13318
|
-
/* @__PURE__ */ jsx(
|
|
13319
|
-
|
|
13320
|
-
|
|
13321
|
-
|
|
13322
|
-
|
|
13323
|
-
|
|
13324
|
-
|
|
13325
|
-
|
|
13326
|
-
|
|
13327
|
-
|
|
13328
|
-
|
|
13329
|
-
|
|
13330
|
-
|
|
13331
|
-
|
|
13332
|
-
|
|
13333
|
-
|
|
13334
|
-
|
|
13335
|
-
|
|
13336
|
-
|
|
13337
|
-
|
|
13338
|
-
|
|
13339
|
-
|
|
13340
|
-
|
|
13341
|
-
|
|
13342
|
-
|
|
13343
|
-
|
|
13344
|
-
|
|
13345
|
-
|
|
13346
|
-
|
|
13347
|
-
|
|
13348
|
-
|
|
13349
|
-
|
|
13350
|
-
|
|
13351
|
-
|
|
13352
|
-
|
|
13353
|
-
|
|
13354
|
-
|
|
13355
|
-
|
|
13356
|
-
|
|
13357
|
-
|
|
13358
|
-
|
|
13359
|
-
|
|
13360
|
-
|
|
13361
|
-
|
|
13362
|
-
|
|
13363
|
-
|
|
13364
|
-
|
|
13365
|
-
|
|
13366
|
-
|
|
13416
|
+
return /* @__PURE__ */ jsxs("div", { className: "flex flex-col gap-1 px-4 sm:px-6 pb-3 pt-5 w-full", children: [
|
|
13417
|
+
/* @__PURE__ */ jsx("div", { className: "text-(length:--md-typescale-label-large-size,14px) font-(--md-typescale-label-large-weight,500) text-m3-on-surface-variant truncate", children: title }),
|
|
13418
|
+
/* @__PURE__ */ jsx(
|
|
13419
|
+
"div",
|
|
13420
|
+
{
|
|
13421
|
+
className: "mb-2 leading-tight text-[26px] sm:text-[32px] font-(--md-typescale-headline-large-weight,400) text-m3-on-surface-variant truncate",
|
|
13422
|
+
title: typeof headline === "string" ? headline : void 0,
|
|
13423
|
+
children: headline
|
|
13424
|
+
}
|
|
13425
|
+
),
|
|
13426
|
+
displayMode === "picker" && /* @__PURE__ */ jsxs("div", { className: "flex min-h-10 items-center justify-between gap-0.5 w-full overflow-hidden", children: [
|
|
13427
|
+
/* @__PURE__ */ jsxs("div", { className: "flex items-center gap-0.5 min-w-0 shrink", children: [
|
|
13428
|
+
activeSelector === null && /* @__PURE__ */ jsx(
|
|
13429
|
+
IconButton,
|
|
13430
|
+
{
|
|
13431
|
+
onClick: onPrev,
|
|
13432
|
+
"aria-label": "Previous month",
|
|
13433
|
+
disabled: !canNavigatePrev,
|
|
13434
|
+
size: "xs",
|
|
13435
|
+
className: "shrink-0",
|
|
13436
|
+
children: /* @__PURE__ */ jsx(Icon, { name: "chevron_left" })
|
|
13437
|
+
}
|
|
13438
|
+
),
|
|
13439
|
+
/* @__PURE__ */ jsxs(
|
|
13440
|
+
"button",
|
|
13441
|
+
{
|
|
13442
|
+
type: "button",
|
|
13443
|
+
onClick: () => onToggleSelector("month"),
|
|
13444
|
+
"aria-expanded": activeSelector === "month",
|
|
13445
|
+
"aria-controls": "date-picker-selection",
|
|
13446
|
+
className: cn(
|
|
13447
|
+
selectorClassName,
|
|
13448
|
+
"min-w-0 max-w-[125px] shrink",
|
|
13449
|
+
activeSelector === "month" && "bg-m3-on-surface/8"
|
|
13450
|
+
),
|
|
13451
|
+
title: monthLabel,
|
|
13452
|
+
children: [
|
|
13453
|
+
/* @__PURE__ */ jsx("span", { className: "truncate", children: monthLabel }),
|
|
13454
|
+
/* @__PURE__ */ jsx(
|
|
13455
|
+
Icon,
|
|
13456
|
+
{
|
|
13457
|
+
name: "arrow_drop_down",
|
|
13458
|
+
className: cn(
|
|
13459
|
+
"text-[20px] shrink-0 transition-transform duration-200",
|
|
13460
|
+
activeSelector === "month" && "rotate-180"
|
|
13461
|
+
)
|
|
13462
|
+
}
|
|
13463
|
+
)
|
|
13464
|
+
]
|
|
13465
|
+
}
|
|
13466
|
+
),
|
|
13467
|
+
activeSelector === null && /* @__PURE__ */ jsx(
|
|
13468
|
+
IconButton,
|
|
13469
|
+
{
|
|
13470
|
+
onClick: onNext,
|
|
13471
|
+
"aria-label": "Next month",
|
|
13472
|
+
disabled: !canNavigateNext,
|
|
13473
|
+
size: "xs",
|
|
13474
|
+
className: "shrink-0",
|
|
13475
|
+
children: /* @__PURE__ */ jsx(Icon, { name: "chevron_right" })
|
|
13476
|
+
}
|
|
13477
|
+
)
|
|
13478
|
+
] }),
|
|
13479
|
+
/* @__PURE__ */ jsxs("div", { className: "ml-auto flex items-center gap-0.5 shrink-0", children: [
|
|
13367
13480
|
activeSelector === null && /* @__PURE__ */ jsx(
|
|
13368
13481
|
IconButton,
|
|
13369
13482
|
{
|
|
@@ -13371,6 +13484,7 @@ var CalendarHeader = ({
|
|
|
13371
13484
|
"aria-label": "Previous year",
|
|
13372
13485
|
disabled: !canNavigatePreviousYear,
|
|
13373
13486
|
size: "xs",
|
|
13487
|
+
className: "shrink-0",
|
|
13374
13488
|
children: /* @__PURE__ */ jsx(Icon, { name: "chevron_left" })
|
|
13375
13489
|
}
|
|
13376
13490
|
),
|
|
@@ -13383,16 +13497,18 @@ var CalendarHeader = ({
|
|
|
13383
13497
|
"aria-controls": "date-picker-selection",
|
|
13384
13498
|
className: cn(
|
|
13385
13499
|
selectorClassName,
|
|
13500
|
+
"shrink-0",
|
|
13386
13501
|
activeSelector === "year" && "bg-m3-on-surface/8"
|
|
13387
13502
|
),
|
|
13503
|
+
title: yearLabel,
|
|
13388
13504
|
children: [
|
|
13389
|
-
yearLabel,
|
|
13505
|
+
/* @__PURE__ */ jsx("span", { children: yearLabel }),
|
|
13390
13506
|
/* @__PURE__ */ jsx(
|
|
13391
13507
|
Icon,
|
|
13392
13508
|
{
|
|
13393
13509
|
name: "arrow_drop_down",
|
|
13394
13510
|
className: cn(
|
|
13395
|
-
"text-[20px] transition-transform duration-200",
|
|
13511
|
+
"text-[20px] shrink-0 transition-transform duration-200",
|
|
13396
13512
|
activeSelector === "year" && "rotate-180"
|
|
13397
13513
|
)
|
|
13398
13514
|
}
|
|
@@ -13407,6 +13523,7 @@ var CalendarHeader = ({
|
|
|
13407
13523
|
"aria-label": "Next year",
|
|
13408
13524
|
disabled: !canNavigateNextYear,
|
|
13409
13525
|
size: "xs",
|
|
13526
|
+
className: "shrink-0",
|
|
13410
13527
|
children: /* @__PURE__ */ jsx(Icon, { name: "chevron_right" })
|
|
13411
13528
|
}
|
|
13412
13529
|
),
|
|
@@ -13416,6 +13533,7 @@ var CalendarHeader = ({
|
|
|
13416
13533
|
onClick: onToggleMode,
|
|
13417
13534
|
"aria-label": "Switch to text input",
|
|
13418
13535
|
size: "xs",
|
|
13536
|
+
className: "shrink-0",
|
|
13419
13537
|
children: /* @__PURE__ */ jsx(Icon, { name: "keyboard" })
|
|
13420
13538
|
}
|
|
13421
13539
|
)
|
|
@@ -13427,7 +13545,7 @@ var CalendarHeader = ({
|
|
|
13427
13545
|
onClick: onToggleMode,
|
|
13428
13546
|
"aria-label": "Switch to calendar",
|
|
13429
13547
|
size: "xs",
|
|
13430
|
-
className: "self-end",
|
|
13548
|
+
className: "self-end shrink-0",
|
|
13431
13549
|
children: /* @__PURE__ */ jsx(Icon, { name: "calendar_month" })
|
|
13432
13550
|
}
|
|
13433
13551
|
),
|
|
@@ -13474,14 +13592,14 @@ var MonthPickerList = ({
|
|
|
13474
13592
|
onClick: () => onMonthSelect(month),
|
|
13475
13593
|
className: cn(
|
|
13476
13594
|
"flex min-h-12 w-full items-center gap-4 px-6 text-left",
|
|
13477
|
-
"text-
|
|
13595
|
+
"text-(length:--md-typescale-body-large-size,16px)",
|
|
13478
13596
|
"text-m3-on-surface transition-m3-fast-effects",
|
|
13479
13597
|
"hover:bg-m3-on-surface/8 focus-visible:outline-2 focus-visible:outline-m3-primary",
|
|
13480
13598
|
isSelected && "bg-m3-secondary-container text-m3-on-secondary-container"
|
|
13481
13599
|
),
|
|
13482
13600
|
children: [
|
|
13483
|
-
/* @__PURE__ */ jsx("span", { className: "w-6", "aria-hidden": true, children: isSelected && /* @__PURE__ */ jsx(Icon, { name: "check", className: "text-[20px]" }) }),
|
|
13484
|
-
getMonthLabel(month, locale.locale)
|
|
13601
|
+
/* @__PURE__ */ jsx("span", { className: "w-6 shrink-0", "aria-hidden": true, children: isSelected && /* @__PURE__ */ jsx(Icon, { name: "check", className: "text-[20px]" }) }),
|
|
13602
|
+
/* @__PURE__ */ jsx("span", { className: "truncate", children: getMonthLabel(month, locale.locale) })
|
|
13485
13603
|
]
|
|
13486
13604
|
},
|
|
13487
13605
|
month
|
|
@@ -13559,7 +13677,9 @@ var DatePicker = ({
|
|
|
13559
13677
|
showModeToggle = true,
|
|
13560
13678
|
title,
|
|
13561
13679
|
headline,
|
|
13562
|
-
className
|
|
13680
|
+
className,
|
|
13681
|
+
width,
|
|
13682
|
+
maxWidth
|
|
13563
13683
|
}) => {
|
|
13564
13684
|
const {
|
|
13565
13685
|
selectedDateMs,
|
|
@@ -13640,7 +13760,10 @@ var DatePicker = ({
|
|
|
13640
13760
|
"fieldset",
|
|
13641
13761
|
{
|
|
13642
13762
|
className: cn("flex flex-col select-none", className),
|
|
13643
|
-
style: {
|
|
13763
|
+
style: {
|
|
13764
|
+
width: typeof width === "number" ? `${width}px` : width != null ? width : "min(100%, 360px)",
|
|
13765
|
+
maxWidth: typeof maxWidth === "number" ? `${maxWidth}px` : maxWidth
|
|
13766
|
+
},
|
|
13644
13767
|
"aria-label": computedAriaLabel,
|
|
13645
13768
|
children: [
|
|
13646
13769
|
/* @__PURE__ */ jsx("legend", { className: "sr-only", children: computedAriaLabel }),
|
|
@@ -14081,7 +14204,9 @@ var DatePickerDialog = ({
|
|
|
14081
14204
|
dismissButton,
|
|
14082
14205
|
children,
|
|
14083
14206
|
className,
|
|
14084
|
-
title = "Select date"
|
|
14207
|
+
title = "Select date",
|
|
14208
|
+
width,
|
|
14209
|
+
maxWidth
|
|
14085
14210
|
}) => {
|
|
14086
14211
|
return /* @__PURE__ */ jsx(Dialog, { open, onOpenChange: (v) => !v && onDismiss(), children: /* @__PURE__ */ jsxs(DialogPortal, { open, children: [
|
|
14087
14212
|
/* @__PURE__ */ jsx(RadixDialog.Overlay, { asChild: true, forceMount: true, children: /* @__PURE__ */ jsx(
|
|
@@ -14117,7 +14242,10 @@ var DatePickerDialog = ({
|
|
|
14117
14242
|
"elevation-3",
|
|
14118
14243
|
className
|
|
14119
14244
|
),
|
|
14120
|
-
style: {
|
|
14245
|
+
style: {
|
|
14246
|
+
width: typeof width === "number" ? `${width}px` : width != null ? width : "min(calc(100vw - 32px), 360px)",
|
|
14247
|
+
maxWidth: typeof maxWidth === "number" ? `${maxWidth}px` : maxWidth
|
|
14248
|
+
},
|
|
14121
14249
|
initial: PICKER_CONTENT_ANIM.initial,
|
|
14122
14250
|
animate: PICKER_CONTENT_ANIM.animate,
|
|
14123
14251
|
exit: PICKER_CONTENT_ANIM.exit,
|
|
@@ -14141,7 +14269,9 @@ var DateRangePicker = ({
|
|
|
14141
14269
|
state,
|
|
14142
14270
|
showModeToggle = false,
|
|
14143
14271
|
title,
|
|
14144
|
-
className
|
|
14272
|
+
className,
|
|
14273
|
+
width,
|
|
14274
|
+
maxWidth
|
|
14145
14275
|
}) => {
|
|
14146
14276
|
const {
|
|
14147
14277
|
selectedStartMs,
|
|
@@ -14213,7 +14343,10 @@ var DateRangePicker = ({
|
|
|
14213
14343
|
"fieldset",
|
|
14214
14344
|
{
|
|
14215
14345
|
className: cn("flex flex-col select-none", className),
|
|
14216
|
-
style: {
|
|
14346
|
+
style: {
|
|
14347
|
+
width: typeof width === "number" ? `${width}px` : width != null ? width : "min(100%, 360px)",
|
|
14348
|
+
maxWidth: typeof maxWidth === "number" ? `${maxWidth}px` : maxWidth
|
|
14349
|
+
},
|
|
14217
14350
|
"aria-label": computedAriaLabel,
|
|
14218
14351
|
children: [
|
|
14219
14352
|
/* @__PURE__ */ jsx("legend", { className: "sr-only", children: computedAriaLabel }),
|
|
@@ -15560,13 +15693,16 @@ var useTimePickerState = (options) => {
|
|
|
15560
15693
|
};
|
|
15561
15694
|
function buildWavePath(startX, endX, amplitude = 2, wavelength = 32, yCenter = 4) {
|
|
15562
15695
|
if (startX >= endX) return "";
|
|
15696
|
+
const totalWidth = endX - startX;
|
|
15563
15697
|
const halfCycle = wavelength / 2;
|
|
15564
|
-
const numHalfCycles = Math.
|
|
15565
|
-
const
|
|
15698
|
+
const numHalfCycles = Math.max(1, Math.round(totalWidth / halfCycle));
|
|
15699
|
+
const actualHalfCycle = totalWidth / numHalfCycles;
|
|
15700
|
+
const scale = Math.min(1, actualHalfCycle / halfCycle);
|
|
15701
|
+
const cpDistanceY = amplitude * (4 / 3) * scale;
|
|
15566
15702
|
let d = `M ${startX},${yCenter}`;
|
|
15567
15703
|
for (let i = 0; i < numHalfCycles; i++) {
|
|
15568
|
-
const x0 = startX + i *
|
|
15569
|
-
const x1 =
|
|
15704
|
+
const x0 = startX + i * actualHalfCycle;
|
|
15705
|
+
const x1 = i === numHalfCycles - 1 ? endX : startX + (i + 1) * actualHalfCycle;
|
|
15570
15706
|
const peak = i % 2 === 0 ? yCenter - cpDistanceY : yCenter + cpDistanceY;
|
|
15571
15707
|
const segLen = x1 - x0;
|
|
15572
15708
|
const cp1x = x0 + segLen / 3;
|
|
@@ -15584,7 +15720,7 @@ var DividerImpl = React67.forwardRef(
|
|
|
15584
15720
|
insetStart = "standard",
|
|
15585
15721
|
waveConfig,
|
|
15586
15722
|
decorative = false,
|
|
15587
|
-
animate:
|
|
15723
|
+
animate: animate7 = true,
|
|
15588
15724
|
className,
|
|
15589
15725
|
style
|
|
15590
15726
|
} = _b, props = __objRest(_b, [
|
|
@@ -15600,7 +15736,7 @@ var DividerImpl = React67.forwardRef(
|
|
|
15600
15736
|
]);
|
|
15601
15737
|
var _a2, _b2, _c;
|
|
15602
15738
|
const reducedMotion = useReducedMotion();
|
|
15603
|
-
const shouldAnimate =
|
|
15739
|
+
const shouldAnimate = animate7 && !reducedMotion;
|
|
15604
15740
|
const effectiveShape = shape === "wavy" && orientation === "vertical" ? "flat" : shape;
|
|
15605
15741
|
if (shape === "wavy" && orientation === "vertical") {
|
|
15606
15742
|
console.warn(
|
|
@@ -17341,7 +17477,7 @@ var ListItemImpl = React67.forwardRef(
|
|
|
17341
17477
|
"cursor-grab active:cursor-grabbing text-m3-on-surface-variant p-2 -mr-2"
|
|
17342
17478
|
)
|
|
17343
17479
|
}, attributes), listeners), {
|
|
17344
|
-
children: /* @__PURE__ */ jsx("span", { className: "material-symbols-
|
|
17480
|
+
children: /* @__PURE__ */ jsx("span", { className: "material-symbols-rounded text-[24px]", children: "drag_handle" })
|
|
17345
17481
|
})
|
|
17346
17482
|
);
|
|
17347
17483
|
}
|
|
@@ -18694,6 +18830,7 @@ var NavigationRailComponent = React67.forwardRef(
|
|
|
18694
18830
|
m.div,
|
|
18695
18831
|
{
|
|
18696
18832
|
layout: true,
|
|
18833
|
+
transition: SPRING_TRANSITION,
|
|
18697
18834
|
className: cn(
|
|
18698
18835
|
"flex w-full flex-col justify-start shrink-0 empty:hidden",
|
|
18699
18836
|
isExpanded ? "items-start px-3" : "items-center",
|
|
@@ -19000,6 +19137,7 @@ function SearchBar({
|
|
|
19000
19137
|
onSearch,
|
|
19001
19138
|
active,
|
|
19002
19139
|
onActiveChange,
|
|
19140
|
+
showLeadingIcon = true,
|
|
19003
19141
|
leadingIcon,
|
|
19004
19142
|
trailingIcon,
|
|
19005
19143
|
avatar,
|
|
@@ -19062,7 +19200,7 @@ function SearchBar({
|
|
|
19062
19200
|
layoutId: shouldReduceMotion ? void 0 : searchId,
|
|
19063
19201
|
transition: shouldReduceMotion ? void 0 : SEARCH_BAR_EXPAND_SPRING,
|
|
19064
19202
|
className: cn(
|
|
19065
|
-
"relative group select-none",
|
|
19203
|
+
"relative group select-none rounded-full",
|
|
19066
19204
|
SEARCH_ELEVATION.level3,
|
|
19067
19205
|
className
|
|
19068
19206
|
),
|
|
@@ -19102,7 +19240,7 @@ function SearchBar({
|
|
|
19102
19240
|
"aria-label": ariaLabel,
|
|
19103
19241
|
className: "relative flex h-full items-center gap-2 rounded-full px-4",
|
|
19104
19242
|
children: /* @__PURE__ */ jsxs("form", { className: "contents", onSubmit: handleFormSubmit, children: [
|
|
19105
|
-
/* @__PURE__ */ jsx(
|
|
19243
|
+
showLeadingIcon && /* @__PURE__ */ jsx(
|
|
19106
19244
|
"span",
|
|
19107
19245
|
{
|
|
19108
19246
|
className: "flex shrink-0 items-center justify-center",
|
|
@@ -19309,6 +19447,7 @@ function SearchViewDocked({
|
|
|
19309
19447
|
onSearch,
|
|
19310
19448
|
active,
|
|
19311
19449
|
onActiveChange,
|
|
19450
|
+
showLeadingIcon = true,
|
|
19312
19451
|
leadingIcon,
|
|
19313
19452
|
trailingIcon,
|
|
19314
19453
|
avatar,
|
|
@@ -19365,7 +19504,7 @@ function SearchViewDocked({
|
|
|
19365
19504
|
className: "flex items-center gap-2 px-4",
|
|
19366
19505
|
style: { height: SearchTokens.heights.dockedHeader },
|
|
19367
19506
|
children: /* @__PURE__ */ jsxs("form", { className: "contents", onSubmit: handleFormSubmit, children: [
|
|
19368
|
-
/* @__PURE__ */ jsx(
|
|
19507
|
+
showLeadingIcon && /* @__PURE__ */ jsx(
|
|
19369
19508
|
"span",
|
|
19370
19509
|
{
|
|
19371
19510
|
className: "flex shrink-0 items-center justify-center",
|
|
@@ -19460,6 +19599,7 @@ function SearchViewFullScreen({
|
|
|
19460
19599
|
onSearch,
|
|
19461
19600
|
active,
|
|
19462
19601
|
onActiveChange,
|
|
19602
|
+
showCloseButton = true,
|
|
19463
19603
|
leadingIcon,
|
|
19464
19604
|
trailingIcon,
|
|
19465
19605
|
avatar,
|
|
@@ -19526,7 +19666,7 @@ function SearchViewFullScreen({
|
|
|
19526
19666
|
className: "flex shrink-0 items-center gap-2 px-4",
|
|
19527
19667
|
style: { height: SearchTokens.heights.fullScreenHeader },
|
|
19528
19668
|
children: /* @__PURE__ */ jsxs("form", { className: "contents", onSubmit: handleFormSubmit, children: [
|
|
19529
|
-
/* @__PURE__ */ jsx(
|
|
19669
|
+
showCloseButton && /* @__PURE__ */ jsx(
|
|
19530
19670
|
IconButton,
|
|
19531
19671
|
{
|
|
19532
19672
|
size: "sm",
|
|
@@ -19627,6 +19767,8 @@ function SearchComponent({
|
|
|
19627
19767
|
variant = "docked",
|
|
19628
19768
|
styleType = "contained",
|
|
19629
19769
|
hasGap = false,
|
|
19770
|
+
showLeadingIcon = true,
|
|
19771
|
+
showCloseButton = true,
|
|
19630
19772
|
leadingIcon,
|
|
19631
19773
|
trailingIcon,
|
|
19632
19774
|
avatar,
|
|
@@ -19655,6 +19797,7 @@ function SearchComponent({
|
|
|
19655
19797
|
onSearch,
|
|
19656
19798
|
active,
|
|
19657
19799
|
onActiveChange,
|
|
19800
|
+
showLeadingIcon,
|
|
19658
19801
|
leadingIcon,
|
|
19659
19802
|
trailingIcon,
|
|
19660
19803
|
avatar,
|
|
@@ -19671,6 +19814,7 @@ function SearchComponent({
|
|
|
19671
19814
|
variant === "fullscreen" ? /* @__PURE__ */ jsx(
|
|
19672
19815
|
SearchViewFullScreen,
|
|
19673
19816
|
__spreadProps(__spreadValues({}, sharedProps), {
|
|
19817
|
+
showCloseButton,
|
|
19674
19818
|
styleType,
|
|
19675
19819
|
viewClassName,
|
|
19676
19820
|
children
|
|
@@ -20966,7 +21110,7 @@ function useShapeMorph({
|
|
|
20966
21110
|
currentProgressRef.current = p;
|
|
20967
21111
|
setClipPath(interpolatePath(morph, p, width, height));
|
|
20968
21112
|
}, [scrollProgress, morphOn, morph, width, height]);
|
|
20969
|
-
const
|
|
21113
|
+
const animate7 = useCallback(
|
|
20970
21114
|
(timestamp) => {
|
|
20971
21115
|
if (!morph) return;
|
|
20972
21116
|
const elapsed = timestamp - startTimeRef.current;
|
|
@@ -20977,7 +21121,7 @@ function useShapeMorph({
|
|
|
20977
21121
|
currentProgressRef.current = progress;
|
|
20978
21122
|
setClipPath(interpolatePath(morph, progress, width, height));
|
|
20979
21123
|
if (rawT < 1) {
|
|
20980
|
-
animRef.current = requestAnimationFrame(
|
|
21124
|
+
animRef.current = requestAnimationFrame(animate7);
|
|
20981
21125
|
} else {
|
|
20982
21126
|
animRef.current = null;
|
|
20983
21127
|
}
|
|
@@ -20996,9 +21140,9 @@ function useShapeMorph({
|
|
|
20996
21140
|
startProgressRef.current = currentProgressRef.current;
|
|
20997
21141
|
targetProgressRef.current = toProgress;
|
|
20998
21142
|
startTimeRef.current = performance.now();
|
|
20999
|
-
animRef.current = requestAnimationFrame(
|
|
21143
|
+
animRef.current = requestAnimationFrame(animate7);
|
|
21000
21144
|
},
|
|
21001
|
-
[morph,
|
|
21145
|
+
[morph, animate7, width, height]
|
|
21002
21146
|
);
|
|
21003
21147
|
useEffect(() => {
|
|
21004
21148
|
return () => {
|
|
@@ -27272,6 +27416,6 @@ function TooltipBox({
|
|
|
27272
27416
|
] });
|
|
27273
27417
|
}
|
|
27274
27418
|
|
|
27275
|
-
export { ANGLE_EPSILON, APP_BAR_BOTTOM_SPRING, APP_BAR_COLORS, APP_BAR_COLOR_TRANSITION, APP_BAR_ENTER_ALWAYS_SPRING, APP_BAR_TITLE_FADE, AppBarColumn, AppBarOverflowIndicator, AppBarRow, AppBarTokens, BUTTON_COLOR_TOKENS, BUTTON_SIZE_TOKENS, Badge, BadgedBox, BottomAppBar, BottomDockedToolbar, BottomSheet, BottomSheetModal, Button, ButtonDistribute, ButtonGroup, CHECK_ICON_VARIANTS, Card, CardContent, CardFooter, CardHeader, CardMedia, Carousel, CarouselGrid, CarouselItem, CarouselScrollClient, CarouselTokens, Checkbox, Chip, CodeBlock, ContextMenu, ContextMenuContent, ContextMenuTrigger, Cubic, DISTANCE_EPSILON, DIVIDER_COLOR, DIVIDER_PADDING, DP_CLASSES, DP_COLORS, DP_SHAPE, DP_SIZE, DatePicker, DatePickerDialog, DatePickerInput, DateRangePicker, Dialog, DialogBody, DialogClose, DialogContent, DialogDescription, DialogFooter, DialogFullScreenContent, DialogHeader, DialogIcon, DialogOverlay, DialogPortal, DialogTitle, DialogTrigger, Divider, DockedToolbar, DragHandle, Drawer, DrawerClose, DrawerContent, DrawerDescription, DrawerFooter, DrawerHeader, DrawerOverlay, DrawerPortal, DrawerTitle, DrawerTrigger, ElevatedSplitButtonLeading, ElevatedSplitButtonTrailing, ElevatedSplitButtonTrailingUncheckable, ExtendedFAB, FAB, FABMenu, FABMenuItem, FABPosition, FAST_EFFECTS_TRANSITION, FAST_SPATIAL_SPRING, FLOAT_PI, FadingBlurMask, FilledSplitButtonLeading, FilledSplitButtonTrailing, FilledSplitButtonTrailingUncheckable, GROUP_SHAPES, HorizontalFloatingToolbar, HorizontalFloatingToolbarWithFab, ITEM_SHAPE_CLASSES, Icon, IconButton, LIST_TOKENS, LargeFlexibleAppBar, List, ListContext, ListDivider, ListItem, LoadingIndicator, MD3CornerRadius, MD3Shapes, MD3ThemeProvider, MD3_EXPRESSIVE_FONT_VARIATION, MENU_CHECK_ICON_SIZE, MENU_CONTAINER_VARIANTS, MENU_GROUP_GAP, MENU_ICON_SIZE, MENU_ITEM_MIN_HEIGHT, MENU_MAX_WIDTH, MENU_MIN_WIDTH, MaterialSymbolsPreconnect, MeasuredPolygon, MediumFlexibleAppBar, Menu, MenuContent, MenuDivider, MenuGroup, MenuItem, MenuProvider, MenuTrigger, Morph, MutableCubic, NavigationBar, NavigationBarItem, NavigationRail, NavigationRailItem, OutlinedSplitButtonLeading, OutlinedSplitButtonTrailing, OutlinedSplitButtonTrailingUncheckable, PlainTooltip, ProgressIndicator, RadioButton, RadioGroup, RangeSlider, RichTooltip, Ripple, RoundedPolygon, SEARCH_BAR_EXPAND_SPRING, SEARCH_COLORS, SEARCH_DOCKED_REVEAL_SPRING, SEARCH_FULLSCREEN_SPRING, SEARCH_TYPOGRAPHY, SEARCH_VIEW_SPRING, STANDARD_COLORS, SUBMENU_CONTAINER_VARIANTS, Scrim, ScrollArea, ScrollAreaScrollbar, Search, SearchAppBar, SearchBar, SearchTokens, SearchView, SearchViewContainer, SearchViewDocked, SearchViewFullScreen, Select, ShapeIcon, ShapeMedia, ShapeMediaServer, ShapeSvg, SideSheet, SideSheetModal, Slider, SliderColors, SliderTokens, SmallAppBar, Snackbar, SnackbarContext, SnackbarHost, SnackbarProvider, SplitButtonLayout, SplitButtonLeading, SplitButtonTrailing, SplitButtonTrailingUncheckable, SubMenu, Switch, SwitchColors, SwitchTokens, TP_CLASSES, TP_COLORS, TP_SHAPE, TP_SIZE, Tab, TableOfContents, Tabs, TabsColors, TabsContent, TabsList, TabsTokens, Text, TextField, TimeInput, TimePicker, TimePickerDialog, ToggleFAB, TonalSplitButtonLeading, TonalSplitButtonTrailing, TonalSplitButtonTrailingUncheckable, ToolbarDivider, ToolbarDividerTokens, ToolbarIconButton, ToolbarIconButtonTokens, ToolbarToggleButton, ToolbarToggleButtonTokens, TooltipBox, TooltipCaretShape, TooltipTokens, TriStateCheckbox, TypeScaleTokens, Typography, TypographyContext, TypographyKeyTokens, TypographyProvider, TypographyTokens, UNROUNDED, VIBRANT_COLORS, VerticalFloatingToolbar, VerticalFloatingToolbarWithFab, VerticalMenu, VerticalMenuContent, VerticalMenuDivider, VerticalMenuGroup, addPoints, appBarTypography, applyTheme, buildWavePath, cardVariants, circle, clockwise,
|
|
27419
|
+
export { ANGLE_EPSILON, APP_BAR_BOTTOM_SPRING, APP_BAR_COLORS, APP_BAR_COLOR_TRANSITION, APP_BAR_ENTER_ALWAYS_SPRING, APP_BAR_TITLE_FADE, AppBarColumn, AppBarOverflowIndicator, AppBarRow, AppBarTokens, BUTTON_COLOR_TOKENS, BUTTON_SIZE_TOKENS, Badge, BadgedBox, BottomAppBar, BottomDockedToolbar, BottomSheet, BottomSheetModal, Button, ButtonDistribute, ButtonGroup, CHECK_ICON_VARIANTS, Card, CardContent, CardFooter, CardHeader, CardMedia, Carousel, CarouselGrid, CarouselItem, CarouselScrollClient, CarouselTokens, Checkbox, Chip, CodeBlock, ContextMenu, ContextMenuContent, ContextMenuTrigger, Cubic, DISTANCE_EPSILON, DIVIDER_COLOR, DIVIDER_PADDING, DP_CLASSES, DP_COLORS, DP_SHAPE, DP_SIZE, DatePicker, DatePickerDialog, DatePickerInput, DateRangePicker, Dialog, DialogBody, DialogClose, DialogContent, DialogDescription, DialogFooter, DialogFullScreenContent, DialogHeader, DialogIcon, DialogOverlay, DialogPortal, DialogTitle, DialogTrigger, Divider, DockedToolbar, DragHandle, Drawer, DrawerClose, DrawerContent, DrawerDescription, DrawerFooter, DrawerHeader, DrawerOverlay, DrawerPortal, DrawerTitle, DrawerTrigger, ElevatedSplitButtonLeading, ElevatedSplitButtonTrailing, ElevatedSplitButtonTrailingUncheckable, ExtendedFAB, FAB, FABMenu, FABMenuItem, FABPosition, FAST_EFFECTS_TRANSITION, FAST_SPATIAL_SPRING, FLOAT_PI, FadingBlurMask, FilledSplitButtonLeading, FilledSplitButtonTrailing, FilledSplitButtonTrailingUncheckable, GROUP_SHAPES, HorizontalFloatingToolbar, HorizontalFloatingToolbarWithFab, ITEM_SHAPE_CLASSES, Icon, IconButton, LIST_TOKENS, LargeFlexibleAppBar, List, ListContext, ListDivider, ListItem, LoadingIndicator, MD3CornerRadius, MD3Shapes, MD3ThemeProvider, MD3_EXPRESSIVE_FONT_VARIATION, MENU_CHECK_ICON_SIZE, MENU_CONTAINER_VARIANTS, MENU_GROUP_GAP, MENU_ICON_SIZE, MENU_ITEM_MIN_HEIGHT, MENU_MAX_WIDTH, MENU_MIN_WIDTH, MaterialSymbolsPreconnect, MeasuredPolygon, MediumFlexibleAppBar, Menu, MenuContent, MenuDivider, MenuGroup, MenuItem, MenuProvider, MenuTrigger, Morph, MutableCubic, NavigationBar, NavigationBarItem, NavigationRail, NavigationRailItem, OutlinedSplitButtonLeading, OutlinedSplitButtonTrailing, OutlinedSplitButtonTrailingUncheckable, PlainTooltip, ProgressIndicator, RadioButton, RadioGroup, RangeSlider, RichTooltip, Ripple, RoundedPolygon, SEARCH_BAR_EXPAND_SPRING, SEARCH_COLORS, SEARCH_DOCKED_REVEAL_SPRING, SEARCH_FULLSCREEN_SPRING, SEARCH_TYPOGRAPHY, SEARCH_VIEW_SPRING, STANDARD_COLORS, SUBMENU_CONTAINER_VARIANTS, Scrim, ScrollArea, ScrollAreaScrollbar, Search, SearchAppBar, SearchBar, SearchTokens, SearchView, SearchViewContainer, SearchViewDocked, SearchViewFullScreen, Select, ShapeIcon, ShapeMedia, ShapeMediaServer, ShapeSvg, SideSheet, SideSheetModal, Slider, SliderColors, SliderTokens, SmallAppBar, Snackbar, SnackbarContext, SnackbarHost, SnackbarProvider, SplitButtonLayout, SplitButtonLeading, SplitButtonTrailing, SplitButtonTrailingUncheckable, SubMenu, Switch, SwitchColors, SwitchTokens, TP_CLASSES, TP_COLORS, TP_SHAPE, TP_SIZE, Tab, TableOfContents, Tabs, TabsColors, TabsContent, TabsList, TabsTokens, Text, TextField, TimeInput, TimePicker, TimePickerDialog, ToggleFAB, TonalSplitButtonLeading, TonalSplitButtonTrailing, TonalSplitButtonTrailingUncheckable, ToolbarDivider, ToolbarDividerTokens, ToolbarIconButton, ToolbarIconButtonTokens, ToolbarToggleButton, ToolbarToggleButtonTokens, TooltipBox, TooltipCaretShape, TooltipTokens, TriStateCheckbox, TypeScaleTokens, Typography, TypographyContext, TypographyKeyTokens, TypographyProvider, TypographyTokens, UNROUNDED, VIBRANT_COLORS, VerticalFloatingToolbar, VerticalFloatingToolbarWithFab, VerticalMenu, VerticalMenuContent, VerticalMenuDivider, VerticalMenuGroup, addPoints, appBarTypography, applyTheme, buildWavePath, cardVariants, circle, clockwise, convex, cornerFeature, cornerRounding, createDoubleMapper, createMd3ExpressiveTheme, directionVector, distance, distanceSquared, dividePoint, dotProduct, edgeFeature, featureMapper, generateM3Theme, getDirection, getDistance, getDistanceSquared, getExpressiveShape, getListItemHeight, getToolbarColors, interpolate, interpolatePath, lerpPoint, pill, pillStar, point, positiveModulo, radialToCartesian, rectangle, resolveMode, rotate90, scalePoint, shouldTopAlign, square, standardFloatingToolbarColors, star, subtractPoints, surfaceContainerHighFloatingToolbarColors, surfaceContainerHighestFloatingToolbarColors, tertiaryContainerFloatingToolbarColors, toClipPath, toSvgPath, transformFeature, transformPoint, useAppBarScroll, useBottomSheet, useCarouselA11y, useCarouselKeylines, useRipple as useDOMRipple, useDatePickerState, useDateRangePickerState, useFloatingToolbarScrollBehavior, useListContext, useMediaQuery, useMenuContext, useRipple2 as useRipple, useRippleState, useSearchKeyboard, useShapeMorph, useSnackbar, useSnackbarState, useTheme, useThemeMode, useTimePickerState, useTooltipPosition, useTooltipState, useTypography, vibrantFloatingToolbarColors, xrFloatingToolbarColors };
|
|
27276
27420
|
//# sourceMappingURL=index.mjs.map
|
|
27277
27421
|
//# sourceMappingURL=index.mjs.map
|