@bug-on/m3-expressive 1.2.7 → 1.3.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/CHANGELOG.md +6 -0
- package/dist/buttons.d.mts +3 -3
- package/dist/buttons.d.ts +3 -3
- package/dist/buttons.js +10 -10
- package/dist/buttons.js.map +1 -1
- package/dist/buttons.mjs +10 -10
- package/dist/buttons.mjs.map +1 -1
- package/dist/{core-D4048_K5.d.mts → core-CAU8g2HY.d.mts} +1 -1
- package/dist/{core-Bc5Wj_pc.d.ts → core-DRrLnsnJ.d.ts} +1 -1
- package/dist/core.d.mts +2 -2
- package/dist/core.d.ts +2 -2
- package/dist/core.js +3 -3
- package/dist/core.js.map +1 -1
- package/dist/core.mjs +3 -3
- package/dist/core.mjs.map +1 -1
- package/dist/feedback.d.mts +8 -6
- package/dist/feedback.d.ts +8 -6
- package/dist/feedback.js +5 -5
- package/dist/feedback.js.map +1 -1
- package/dist/feedback.mjs +5 -5
- package/dist/feedback.mjs.map +1 -1
- package/dist/{icon-button-CSsDmuQC.d.mts → icon-button-CqdQBsRe.d.ts} +11 -5
- package/dist/{icon-button-CSsDmuQC.d.ts → icon-button-USJo7AqO.d.mts} +11 -5
- package/dist/index.d.mts +6 -6
- package/dist/index.d.ts +6 -6
- package/dist/index.js +291 -163
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +291 -164
- package/dist/index.mjs.map +1 -1
- package/dist/layout.d.mts +1 -1
- package/dist/layout.d.ts +1 -1
- package/dist/layout.js +1 -33
- package/dist/layout.js.map +1 -1
- package/dist/layout.mjs +1 -33
- package/dist/layout.mjs.map +1 -1
- package/dist/{md3-Dty-Qcad.d.mts → md3-D0_Z7IXj.d.mts} +9 -1
- package/dist/{md3-Dty-Qcad.d.ts → md3-D0_Z7IXj.d.ts} +9 -1
- package/dist/navigation.d.mts +103 -33
- package/dist/navigation.d.ts +103 -33
- package/dist/navigation.js +287 -127
- package/dist/navigation.js.map +1 -1
- package/dist/navigation.mjs +288 -129
- package/dist/navigation.mjs.map +1 -1
- package/dist/overlays.js +3 -3
- package/dist/overlays.js.map +1 -1
- package/dist/overlays.mjs +3 -3
- package/dist/overlays.mjs.map +1 -1
- package/dist/pickers.js +3 -3
- package/dist/pickers.js.map +1 -1
- package/dist/pickers.mjs +3 -3
- package/dist/pickers.mjs.map +1 -1
- package/dist/{split-button-trailing-uncheckable-DPJL3bO6.d.mts → split-button-trailing-uncheckable-26qlZvKT.d.mts} +10 -7
- package/dist/{split-button-trailing-uncheckable--BhNTEJw.d.ts → split-button-trailing-uncheckable-CXUVrH64.d.ts} +10 -7
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -6,8 +6,8 @@ var materialColorUtilities = require('@material/material-color-utilities');
|
|
|
6
6
|
var jsxRuntime = require('react/jsx-runtime');
|
|
7
7
|
var clsx = require('clsx');
|
|
8
8
|
var tailwindMerge = require('tailwind-merge');
|
|
9
|
-
var RxContextMenu = require('@radix-ui/react-context-menu');
|
|
10
9
|
var react = require('motion/react');
|
|
10
|
+
var RxContextMenu = require('@radix-ui/react-context-menu');
|
|
11
11
|
var m3Tokens = require('@bug-on/m3-tokens');
|
|
12
12
|
var DropdownMenu = require('@radix-ui/react-dropdown-menu');
|
|
13
13
|
var reactSlot = require('@radix-ui/react-slot');
|
|
@@ -2855,6 +2855,52 @@ function interpolatePath(morph, progress, width, height) {
|
|
|
2855
2855
|
function fmt(v) {
|
|
2856
2856
|
return Number(v.toFixed(4)).toString();
|
|
2857
2857
|
}
|
|
2858
|
+
function getMaskGradient(direction) {
|
|
2859
|
+
switch (direction) {
|
|
2860
|
+
case "bottom":
|
|
2861
|
+
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%)";
|
|
2862
|
+
case "both":
|
|
2863
|
+
return "linear-gradient(to bottom, rgba(0, 0, 0, 0) 0%, rgba(0, 0, 0, 0.7) 20%, rgba(0, 0, 0, 1) 40%, rgba(0, 0, 0, 1) 60%, rgba(0, 0, 0, 0.7) 80%, rgba(0, 0, 0, 0) 100%)";
|
|
2864
|
+
default:
|
|
2865
|
+
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%)";
|
|
2866
|
+
}
|
|
2867
|
+
}
|
|
2868
|
+
function FadingBlurMask({
|
|
2869
|
+
direction = "top",
|
|
2870
|
+
blurIntensity = 12,
|
|
2871
|
+
blurHeight = "100%",
|
|
2872
|
+
color = "var(--md-sys-color-surface)",
|
|
2873
|
+
className,
|
|
2874
|
+
style,
|
|
2875
|
+
children
|
|
2876
|
+
}) {
|
|
2877
|
+
const shouldReduceMotion = react.useReducedMotion();
|
|
2878
|
+
const activeBlur = shouldReduceMotion ? 0 : blurIntensity;
|
|
2879
|
+
const maskGradient = getMaskGradient(direction);
|
|
2880
|
+
const maskStyle = __spreadValues({
|
|
2881
|
+
position: "absolute",
|
|
2882
|
+
inset: 0,
|
|
2883
|
+
pointerEvents: "none",
|
|
2884
|
+
height: typeof blurHeight === "number" ? `${blurHeight}px` : blurHeight,
|
|
2885
|
+
backdropFilter: activeBlur > 0 ? `blur(${activeBlur}px)` : void 0,
|
|
2886
|
+
WebkitBackdropFilter: activeBlur > 0 ? `blur(${activeBlur}px)` : void 0,
|
|
2887
|
+
maskImage: maskGradient,
|
|
2888
|
+
WebkitMaskImage: maskGradient,
|
|
2889
|
+
backgroundColor: color
|
|
2890
|
+
}, style);
|
|
2891
|
+
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
2892
|
+
"div",
|
|
2893
|
+
{
|
|
2894
|
+
"aria-hidden": "true",
|
|
2895
|
+
className: cn(
|
|
2896
|
+
"absolute inset-0 pointer-events-none z-0 rounded-[inherit]",
|
|
2897
|
+
className
|
|
2898
|
+
),
|
|
2899
|
+
style: maskStyle,
|
|
2900
|
+
children
|
|
2901
|
+
}
|
|
2902
|
+
);
|
|
2903
|
+
}
|
|
2858
2904
|
|
|
2859
2905
|
// src/ui/shared/motion-tokens.ts
|
|
2860
2906
|
var FAST_SPATIAL_SPRING = {
|
|
@@ -4615,7 +4661,10 @@ function BottomAppBar({
|
|
|
4615
4661
|
floatingActionButton,
|
|
4616
4662
|
scrollBehavior = "visible",
|
|
4617
4663
|
scrollElement,
|
|
4618
|
-
className
|
|
4664
|
+
className,
|
|
4665
|
+
enableFadingBlur,
|
|
4666
|
+
blurIntensity,
|
|
4667
|
+
blurHeight
|
|
4619
4668
|
}) {
|
|
4620
4669
|
const shouldReduceMotion = react.useReducedMotion();
|
|
4621
4670
|
const { isHidden } = useAppBarScroll({
|
|
@@ -4630,9 +4679,9 @@ function BottomAppBar({
|
|
|
4630
4679
|
role: "navigation",
|
|
4631
4680
|
"aria-label": "Bottom app bar",
|
|
4632
4681
|
className: cn(
|
|
4633
|
-
"fixed bottom-0 inset-x-0 z-50",
|
|
4682
|
+
"fixed bottom-0 inset-x-0 z-50 overflow-hidden rounded-[inherit]",
|
|
4634
4683
|
"flex items-center",
|
|
4635
|
-
"bg-m3-surface-container",
|
|
4684
|
+
!enableFadingBlur && "bg-m3-surface-container",
|
|
4636
4685
|
"px-2",
|
|
4637
4686
|
// minimal horizontal padding, icon buttons provide spacing
|
|
4638
4687
|
"elevation-2",
|
|
@@ -4645,8 +4694,19 @@ function BottomAppBar({
|
|
|
4645
4694
|
animate: { y: translateY },
|
|
4646
4695
|
transition: hideTransition,
|
|
4647
4696
|
children: [
|
|
4648
|
-
|
|
4649
|
-
|
|
4697
|
+
enableFadingBlur && /* @__PURE__ */ jsxRuntime.jsx(
|
|
4698
|
+
FadingBlurMask,
|
|
4699
|
+
{
|
|
4700
|
+
direction: "bottom",
|
|
4701
|
+
blurIntensity,
|
|
4702
|
+
blurHeight,
|
|
4703
|
+
color: "var(--md-sys-color-surface-container)"
|
|
4704
|
+
}
|
|
4705
|
+
),
|
|
4706
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "relative z-10 flex items-center w-full h-full", children: [
|
|
4707
|
+
actions && /* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex items-center flex-1", children: actions }),
|
|
4708
|
+
floatingActionButton && /* @__PURE__ */ jsxRuntime.jsx("div", { className: "shrink-0 ml-auto mr-2", children: floatingActionButton })
|
|
4709
|
+
] })
|
|
4650
4710
|
]
|
|
4651
4711
|
}
|
|
4652
4712
|
);
|
|
@@ -4754,7 +4814,10 @@ function LargeFlexibleAppBar({
|
|
|
4754
4814
|
headerContent,
|
|
4755
4815
|
collapsedHeight = AppBarTokens.heights.flexibleCollapsed,
|
|
4756
4816
|
expandedHeight,
|
|
4757
|
-
className
|
|
4817
|
+
className,
|
|
4818
|
+
enableFadingBlur,
|
|
4819
|
+
blurIntensity,
|
|
4820
|
+
blurHeight
|
|
4758
4821
|
}) {
|
|
4759
4822
|
var _a, _b, _c;
|
|
4760
4823
|
const resolvedExpandedHeight = expandedHeight != null ? expandedHeight : subtitle ? AppBarTokens.heights.largeFlexWithSubtitleExpanded : AppBarTokens.heights.largeFlexExpanded;
|
|
@@ -4784,15 +4847,28 @@ function LargeFlexibleAppBar({
|
|
|
4784
4847
|
{
|
|
4785
4848
|
role: "banner",
|
|
4786
4849
|
className: cn(
|
|
4787
|
-
"fixed top-0 inset-x-0 z-50 flex flex-col overflow-hidden",
|
|
4850
|
+
"fixed top-0 inset-x-0 z-50 flex flex-col overflow-hidden rounded-[inherit]",
|
|
4788
4851
|
className
|
|
4789
4852
|
),
|
|
4790
|
-
style: {
|
|
4853
|
+
style: {
|
|
4854
|
+
height,
|
|
4855
|
+
backgroundColor: enableFadingBlur ? "transparent" : currentBg,
|
|
4856
|
+
transition: cssTransition
|
|
4857
|
+
},
|
|
4791
4858
|
children: [
|
|
4859
|
+
enableFadingBlur && /* @__PURE__ */ jsxRuntime.jsx(
|
|
4860
|
+
FadingBlurMask,
|
|
4861
|
+
{
|
|
4862
|
+
direction: "top",
|
|
4863
|
+
blurIntensity,
|
|
4864
|
+
blurHeight,
|
|
4865
|
+
color: currentBg
|
|
4866
|
+
}
|
|
4867
|
+
),
|
|
4792
4868
|
/* @__PURE__ */ jsxRuntime.jsxs(
|
|
4793
4869
|
"div",
|
|
4794
4870
|
{
|
|
4795
|
-
className: "flex items-center px-1 shrink-0",
|
|
4871
|
+
className: "relative z-10 flex items-center px-1 shrink-0",
|
|
4796
4872
|
style: { height: collapsedHeight },
|
|
4797
4873
|
children: [
|
|
4798
4874
|
navigationIcon && /* @__PURE__ */ jsxRuntime.jsx(
|
|
@@ -4834,7 +4910,7 @@ function LargeFlexibleAppBar({
|
|
|
4834
4910
|
"div",
|
|
4835
4911
|
{
|
|
4836
4912
|
className: cn(
|
|
4837
|
-
"flex flex-col flex-1 px-4 pb-
|
|
4913
|
+
"relative z-10 flex flex-col flex-1 px-4 pb-3 justify-end",
|
|
4838
4914
|
isCentered ? "items-center" : "items-start"
|
|
4839
4915
|
),
|
|
4840
4916
|
children: [
|
|
@@ -4887,7 +4963,10 @@ function MediumFlexibleAppBar({
|
|
|
4887
4963
|
headerContent,
|
|
4888
4964
|
collapsedHeight = AppBarTokens.heights.flexibleCollapsed,
|
|
4889
4965
|
expandedHeight,
|
|
4890
|
-
className
|
|
4966
|
+
className,
|
|
4967
|
+
enableFadingBlur,
|
|
4968
|
+
blurIntensity,
|
|
4969
|
+
blurHeight
|
|
4891
4970
|
}) {
|
|
4892
4971
|
var _a, _b, _c;
|
|
4893
4972
|
const resolvedExpandedHeight = expandedHeight != null ? expandedHeight : subtitle ? AppBarTokens.heights.mediumFlexWithSubtitleExpanded : AppBarTokens.heights.mediumFlexExpanded;
|
|
@@ -4917,15 +4996,28 @@ function MediumFlexibleAppBar({
|
|
|
4917
4996
|
{
|
|
4918
4997
|
role: "banner",
|
|
4919
4998
|
className: cn(
|
|
4920
|
-
"fixed top-0 inset-x-0 z-50 flex flex-col overflow-hidden",
|
|
4999
|
+
"fixed top-0 inset-x-0 z-50 flex flex-col overflow-hidden rounded-[inherit]",
|
|
4921
5000
|
className
|
|
4922
5001
|
),
|
|
4923
|
-
style: {
|
|
5002
|
+
style: {
|
|
5003
|
+
height,
|
|
5004
|
+
backgroundColor: enableFadingBlur ? "transparent" : currentBg,
|
|
5005
|
+
transition: cssTransition
|
|
5006
|
+
},
|
|
4924
5007
|
children: [
|
|
5008
|
+
enableFadingBlur && /* @__PURE__ */ jsxRuntime.jsx(
|
|
5009
|
+
FadingBlurMask,
|
|
5010
|
+
{
|
|
5011
|
+
direction: "top",
|
|
5012
|
+
blurIntensity,
|
|
5013
|
+
blurHeight,
|
|
5014
|
+
color: currentBg
|
|
5015
|
+
}
|
|
5016
|
+
),
|
|
4925
5017
|
/* @__PURE__ */ jsxRuntime.jsxs(
|
|
4926
5018
|
"div",
|
|
4927
5019
|
{
|
|
4928
|
-
className: "flex items-center px-1 shrink-0",
|
|
5020
|
+
className: "relative z-10 flex items-center px-1 shrink-0",
|
|
4929
5021
|
style: { height: collapsedHeight },
|
|
4930
5022
|
children: [
|
|
4931
5023
|
navigationIcon && /* @__PURE__ */ jsxRuntime.jsx(
|
|
@@ -4967,7 +5059,7 @@ function MediumFlexibleAppBar({
|
|
|
4967
5059
|
"div",
|
|
4968
5060
|
{
|
|
4969
5061
|
className: cn(
|
|
4970
|
-
"flex flex-col flex-1 px-4 pb-3 justify-end",
|
|
5062
|
+
"relative z-10 flex flex-col flex-1 px-4 pb-3 justify-end",
|
|
4971
5063
|
isCentered ? "items-center" : "items-start"
|
|
4972
5064
|
),
|
|
4973
5065
|
children: [
|
|
@@ -5014,7 +5106,7 @@ function SearchIcon({ className }) {
|
|
|
5014
5106
|
"span",
|
|
5015
5107
|
{
|
|
5016
5108
|
className: cn(
|
|
5017
|
-
"material-symbols-rounded text-[20px] leading-none select-none",
|
|
5109
|
+
"material-symbols-rounded text-[20px] leading-none select-none flex items-center justify-center",
|
|
5018
5110
|
className
|
|
5019
5111
|
),
|
|
5020
5112
|
"aria-hidden": "true",
|
|
@@ -5034,7 +5126,12 @@ function SearchAppBar({
|
|
|
5034
5126
|
scrollBehavior = "pinned",
|
|
5035
5127
|
scrollElement,
|
|
5036
5128
|
searchBarId = "search-bar",
|
|
5037
|
-
|
|
5129
|
+
searchBarVariant = "filled",
|
|
5130
|
+
searchBarHeight = 56,
|
|
5131
|
+
className,
|
|
5132
|
+
enableFadingBlur,
|
|
5133
|
+
blurIntensity,
|
|
5134
|
+
blurHeight
|
|
5038
5135
|
}) {
|
|
5039
5136
|
var _a, _b;
|
|
5040
5137
|
const shouldReduceMotion = react.useReducedMotion();
|
|
@@ -5057,65 +5154,92 @@ function SearchAppBar({
|
|
|
5057
5154
|
handleSearchClick();
|
|
5058
5155
|
}
|
|
5059
5156
|
};
|
|
5157
|
+
const searchBarBg = isScrolled ? "var(--md-sys-color-surface-container-highest)" : APP_BAR_COLORS.searchBarBg;
|
|
5158
|
+
const isOutlined = searchBarVariant === "outlined";
|
|
5060
5159
|
return /* @__PURE__ */ jsxRuntime.jsxs(
|
|
5061
5160
|
react.m.header,
|
|
5062
5161
|
{
|
|
5063
5162
|
role: "banner",
|
|
5064
5163
|
className: cn(
|
|
5065
|
-
"fixed top-0 inset-x-0 z-50 flex items-center gap-2 px-4",
|
|
5164
|
+
"fixed top-0 inset-x-0 z-50 flex items-center gap-2 px-4 overflow-hidden rounded-[inherit]",
|
|
5066
5165
|
className
|
|
5067
5166
|
),
|
|
5068
5167
|
style: {
|
|
5069
5168
|
height: AppBarTokens.heights.small,
|
|
5070
|
-
backgroundColor: currentBg,
|
|
5169
|
+
backgroundColor: enableFadingBlur ? "transparent" : currentBg,
|
|
5071
5170
|
transition: cssTransition
|
|
5072
5171
|
},
|
|
5073
5172
|
children: [
|
|
5074
|
-
|
|
5075
|
-
|
|
5173
|
+
enableFadingBlur && /* @__PURE__ */ jsxRuntime.jsx(
|
|
5174
|
+
FadingBlurMask,
|
|
5076
5175
|
{
|
|
5077
|
-
|
|
5078
|
-
|
|
5079
|
-
|
|
5080
|
-
|
|
5081
|
-
},
|
|
5082
|
-
children: navigationIcon
|
|
5176
|
+
direction: "top",
|
|
5177
|
+
blurIntensity,
|
|
5178
|
+
blurHeight,
|
|
5179
|
+
color: currentBg
|
|
5083
5180
|
}
|
|
5084
5181
|
),
|
|
5085
|
-
/* @__PURE__ */ jsxRuntime.jsxs(
|
|
5086
|
-
|
|
5087
|
-
|
|
5088
|
-
|
|
5089
|
-
|
|
5090
|
-
|
|
5091
|
-
|
|
5092
|
-
|
|
5093
|
-
|
|
5094
|
-
|
|
5095
|
-
|
|
5096
|
-
|
|
5097
|
-
|
|
5098
|
-
|
|
5099
|
-
|
|
5100
|
-
|
|
5101
|
-
|
|
5102
|
-
|
|
5103
|
-
|
|
5104
|
-
|
|
5105
|
-
|
|
5106
|
-
|
|
5107
|
-
"
|
|
5108
|
-
|
|
5109
|
-
className: "flex-1 text-[16px] leading-6 truncate select-none",
|
|
5110
|
-
style: { color: APP_BAR_COLORS.searchBarContent },
|
|
5111
|
-
children: searchValue != null ? searchValue : searchPlaceholder
|
|
5112
|
-
}
|
|
5182
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "relative z-10 flex items-center gap-2 w-full h-full", children: [
|
|
5183
|
+
navigationIcon && /* @__PURE__ */ jsxRuntime.jsx(
|
|
5184
|
+
"div",
|
|
5185
|
+
{
|
|
5186
|
+
className: "shrink-0 flex items-center justify-center",
|
|
5187
|
+
style: {
|
|
5188
|
+
width: AppBarTokens.iconButtonTouchTarget,
|
|
5189
|
+
height: AppBarTokens.iconButtonTouchTarget
|
|
5190
|
+
},
|
|
5191
|
+
children: navigationIcon
|
|
5192
|
+
}
|
|
5193
|
+
),
|
|
5194
|
+
/* @__PURE__ */ jsxRuntime.jsxs(
|
|
5195
|
+
react.m.div,
|
|
5196
|
+
{
|
|
5197
|
+
layoutId: shouldReduceMotion ? void 0 : searchBarId,
|
|
5198
|
+
role: "search",
|
|
5199
|
+
"aria-label": searchPlaceholder,
|
|
5200
|
+
"aria-expanded": isSearchOpen,
|
|
5201
|
+
tabIndex: 0,
|
|
5202
|
+
className: cn(
|
|
5203
|
+
"relative flex flex-1 items-center gap-2 rounded-full cursor-text px-4",
|
|
5204
|
+
"focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-offset-2",
|
|
5205
|
+
isOutlined && "border border-(--md-sys-color-outline)"
|
|
5113
5206
|
),
|
|
5114
|
-
|
|
5115
|
-
|
|
5116
|
-
|
|
5117
|
-
|
|
5118
|
-
|
|
5207
|
+
style: { height: searchBarHeight },
|
|
5208
|
+
onClick: handleSearchClick,
|
|
5209
|
+
onKeyDown: handleKeyDown,
|
|
5210
|
+
children: [
|
|
5211
|
+
!isOutlined && /* @__PURE__ */ jsxRuntime.jsx(
|
|
5212
|
+
"div",
|
|
5213
|
+
{
|
|
5214
|
+
className: "absolute inset-0 rounded-full -z-10 transition-colors",
|
|
5215
|
+
style: {
|
|
5216
|
+
backgroundColor: searchBarBg,
|
|
5217
|
+
transition: cssTransition
|
|
5218
|
+
}
|
|
5219
|
+
}
|
|
5220
|
+
),
|
|
5221
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
5222
|
+
"span",
|
|
5223
|
+
{
|
|
5224
|
+
className: "shrink-0 flex items-center justify-center h-full",
|
|
5225
|
+
style: { color: APP_BAR_COLORS.searchBarContent },
|
|
5226
|
+
children: leadingSearchIcon != null ? leadingSearchIcon : /* @__PURE__ */ jsxRuntime.jsx(SearchIcon, {})
|
|
5227
|
+
}
|
|
5228
|
+
),
|
|
5229
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
5230
|
+
"span",
|
|
5231
|
+
{
|
|
5232
|
+
className: "flex-1 text-[16px] leading-6 truncate select-none",
|
|
5233
|
+
style: { color: APP_BAR_COLORS.searchBarContent },
|
|
5234
|
+
children: searchValue != null ? searchValue : searchPlaceholder
|
|
5235
|
+
}
|
|
5236
|
+
),
|
|
5237
|
+
trailingSearchActions && /* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex items-center shrink-0", children: trailingSearchActions })
|
|
5238
|
+
]
|
|
5239
|
+
}
|
|
5240
|
+
),
|
|
5241
|
+
externalActions && /* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex items-center shrink-0", children: externalActions })
|
|
5242
|
+
] })
|
|
5119
5243
|
]
|
|
5120
5244
|
}
|
|
5121
5245
|
);
|
|
@@ -5288,9 +5412,11 @@ function SmallAppBarInner({
|
|
|
5288
5412
|
navigationIcon,
|
|
5289
5413
|
actions,
|
|
5290
5414
|
colors,
|
|
5291
|
-
className,
|
|
5292
5415
|
currentBg,
|
|
5293
|
-
cssTransition
|
|
5416
|
+
cssTransition,
|
|
5417
|
+
enableFadingBlur,
|
|
5418
|
+
blurIntensity,
|
|
5419
|
+
blurHeight
|
|
5294
5420
|
}) {
|
|
5295
5421
|
var _a, _b;
|
|
5296
5422
|
const isCentered = titleAlignment === "center";
|
|
@@ -5298,57 +5424,81 @@ function SmallAppBarInner({
|
|
|
5298
5424
|
react.m.header,
|
|
5299
5425
|
{
|
|
5300
5426
|
role: "banner",
|
|
5301
|
-
className:
|
|
5302
|
-
style: {
|
|
5427
|
+
className: "relative flex items-center px-1 h-full w-full overflow-hidden rounded-[inherit]",
|
|
5428
|
+
style: {
|
|
5429
|
+
backgroundColor: enableFadingBlur ? "transparent" : currentBg,
|
|
5430
|
+
transition: cssTransition
|
|
5431
|
+
},
|
|
5303
5432
|
children: [
|
|
5304
|
-
|
|
5305
|
-
|
|
5433
|
+
enableFadingBlur && /* @__PURE__ */ jsxRuntime.jsx(
|
|
5434
|
+
FadingBlurMask,
|
|
5306
5435
|
{
|
|
5307
|
-
|
|
5308
|
-
|
|
5309
|
-
|
|
5310
|
-
|
|
5311
|
-
},
|
|
5312
|
-
children: navigationIcon
|
|
5436
|
+
direction: "top",
|
|
5437
|
+
blurIntensity,
|
|
5438
|
+
blurHeight,
|
|
5439
|
+
color: currentBg
|
|
5313
5440
|
}
|
|
5314
5441
|
),
|
|
5315
|
-
/* @__PURE__ */ jsxRuntime.jsxs(
|
|
5316
|
-
|
|
5317
|
-
|
|
5318
|
-
|
|
5319
|
-
"
|
|
5320
|
-
|
|
5321
|
-
|
|
5322
|
-
|
|
5323
|
-
|
|
5324
|
-
|
|
5325
|
-
|
|
5326
|
-
|
|
5327
|
-
|
|
5328
|
-
|
|
5329
|
-
|
|
5330
|
-
|
|
5331
|
-
|
|
5332
|
-
|
|
5333
|
-
|
|
5334
|
-
}
|
|
5442
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "relative z-10 flex items-center w-full h-full", children: [
|
|
5443
|
+
navigationIcon && /* @__PURE__ */ jsxRuntime.jsx(
|
|
5444
|
+
"div",
|
|
5445
|
+
{
|
|
5446
|
+
className: "shrink-0 flex items-center justify-center",
|
|
5447
|
+
style: {
|
|
5448
|
+
width: AppBarTokens.iconButtonTouchTarget,
|
|
5449
|
+
height: AppBarTokens.iconButtonTouchTarget
|
|
5450
|
+
},
|
|
5451
|
+
children: navigationIcon
|
|
5452
|
+
}
|
|
5453
|
+
),
|
|
5454
|
+
/* @__PURE__ */ jsxRuntime.jsxs(
|
|
5455
|
+
"div",
|
|
5456
|
+
{
|
|
5457
|
+
className: cn(
|
|
5458
|
+
"flex-1 flex flex-col justify-center min-w-0",
|
|
5459
|
+
isCentered ? "items-center" : "items-start",
|
|
5460
|
+
!navigationIcon && !isCentered && "pl-4"
|
|
5335
5461
|
),
|
|
5336
|
-
|
|
5337
|
-
|
|
5338
|
-
|
|
5339
|
-
|
|
5340
|
-
|
|
5341
|
-
|
|
5342
|
-
|
|
5343
|
-
|
|
5344
|
-
|
|
5345
|
-
|
|
5346
|
-
|
|
5347
|
-
|
|
5348
|
-
|
|
5349
|
-
|
|
5350
|
-
|
|
5351
|
-
|
|
5462
|
+
children: [
|
|
5463
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
5464
|
+
"span",
|
|
5465
|
+
{
|
|
5466
|
+
className: cn(
|
|
5467
|
+
appBarTypography.titleLarge,
|
|
5468
|
+
"truncate w-full",
|
|
5469
|
+
isCentered && "text-center"
|
|
5470
|
+
),
|
|
5471
|
+
style: { color: (_a = colors == null ? void 0 : colors.titleColor) != null ? _a : APP_BAR_COLORS.title },
|
|
5472
|
+
children: title
|
|
5473
|
+
}
|
|
5474
|
+
),
|
|
5475
|
+
subtitle && /* @__PURE__ */ jsxRuntime.jsx(
|
|
5476
|
+
"span",
|
|
5477
|
+
{
|
|
5478
|
+
className: cn(
|
|
5479
|
+
appBarTypography.labelMedium,
|
|
5480
|
+
"truncate w-full",
|
|
5481
|
+
isCentered && "text-center"
|
|
5482
|
+
),
|
|
5483
|
+
style: {
|
|
5484
|
+
color: (_b = colors == null ? void 0 : colors.subtitleColor) != null ? _b : APP_BAR_COLORS.subtitle
|
|
5485
|
+
},
|
|
5486
|
+
children: subtitle
|
|
5487
|
+
}
|
|
5488
|
+
)
|
|
5489
|
+
]
|
|
5490
|
+
}
|
|
5491
|
+
),
|
|
5492
|
+
isCentered && !actions && navigationIcon && /* @__PURE__ */ jsxRuntime.jsx(
|
|
5493
|
+
"div",
|
|
5494
|
+
{
|
|
5495
|
+
"aria-hidden": "true",
|
|
5496
|
+
style: { width: AppBarTokens.iconButtonTouchTarget },
|
|
5497
|
+
className: "shrink-0"
|
|
5498
|
+
}
|
|
5499
|
+
),
|
|
5500
|
+
actions && /* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex items-center shrink-0", children: actions })
|
|
5501
|
+
] })
|
|
5352
5502
|
]
|
|
5353
5503
|
}
|
|
5354
5504
|
);
|
|
@@ -5362,7 +5512,10 @@ function SmallAppBar({
|
|
|
5362
5512
|
colors,
|
|
5363
5513
|
scrollBehavior = "pinned",
|
|
5364
5514
|
scrollElement,
|
|
5365
|
-
className
|
|
5515
|
+
className,
|
|
5516
|
+
enableFadingBlur,
|
|
5517
|
+
blurIntensity,
|
|
5518
|
+
blurHeight
|
|
5366
5519
|
}) {
|
|
5367
5520
|
var _a, _b;
|
|
5368
5521
|
const shouldReduceMotion = react.useReducedMotion();
|
|
@@ -5382,14 +5535,17 @@ function SmallAppBar({
|
|
|
5382
5535
|
actions,
|
|
5383
5536
|
colors,
|
|
5384
5537
|
currentBg,
|
|
5385
|
-
cssTransition
|
|
5538
|
+
cssTransition,
|
|
5539
|
+
enableFadingBlur,
|
|
5540
|
+
blurIntensity,
|
|
5541
|
+
blurHeight
|
|
5386
5542
|
};
|
|
5387
5543
|
const barHeight = AppBarTokens.heights.small;
|
|
5388
5544
|
if (scrollBehavior !== "enterAlways") {
|
|
5389
5545
|
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
5390
5546
|
"div",
|
|
5391
5547
|
{
|
|
5392
|
-
className: cn("fixed top-0 inset-x-0 z-50", className),
|
|
5548
|
+
className: cn("fixed top-0 inset-x-0 z-50 overflow-hidden", className),
|
|
5393
5549
|
style: { height: barHeight },
|
|
5394
5550
|
children: /* @__PURE__ */ jsxRuntime.jsx(SmallAppBarInner, __spreadValues({}, innerProps))
|
|
5395
5551
|
}
|
|
@@ -5402,7 +5558,10 @@ function SmallAppBar({
|
|
|
5402
5558
|
animate: { y: 0 },
|
|
5403
5559
|
exit: { y: "-100%" },
|
|
5404
5560
|
transition: shouldReduceMotion ? { duration: 0 } : APP_BAR_ENTER_ALWAYS_SPRING,
|
|
5405
|
-
className: cn(
|
|
5561
|
+
className: cn(
|
|
5562
|
+
"fixed top-0 inset-x-0 z-50 overflow-hidden",
|
|
5563
|
+
className
|
|
5564
|
+
),
|
|
5406
5565
|
style: { height: barHeight },
|
|
5407
5566
|
children: /* @__PURE__ */ jsxRuntime.jsx(SmallAppBarInner, __spreadValues({}, innerProps))
|
|
5408
5567
|
},
|
|
@@ -5484,9 +5643,9 @@ function BadgedBox({
|
|
|
5484
5643
|
badge,
|
|
5485
5644
|
children,
|
|
5486
5645
|
className,
|
|
5487
|
-
|
|
5646
|
+
size
|
|
5488
5647
|
}) {
|
|
5489
|
-
const isLarge =
|
|
5648
|
+
const isLarge = size ? size === "lg" : detectBadgeHasContent(badge);
|
|
5490
5649
|
const badgePositionClass = isLarge ? "translate-x-[35%] -translate-y-[35%]" : "translate-x-[50%] -translate-y-[50%]";
|
|
5491
5650
|
return /* @__PURE__ */ jsxRuntime.jsxs("span", { className: cn("relative inline-flex", className), children: [
|
|
5492
5651
|
children,
|
|
@@ -8412,9 +8571,9 @@ var TOGGLE_FAB_COLORS = {
|
|
|
8412
8571
|
}
|
|
8413
8572
|
};
|
|
8414
8573
|
var TOGGLE_FAB_SIZES = {
|
|
8415
|
-
|
|
8416
|
-
|
|
8417
|
-
|
|
8574
|
+
sm: { sizeClass: "h-14 w-14", initialRadius: 16, finalRadius: 28 },
|
|
8575
|
+
md: { sizeClass: "h-20 w-20", initialRadius: 20, finalRadius: 40 },
|
|
8576
|
+
lg: { sizeClass: "h-24 w-24", initialRadius: 28, finalRadius: 48 }
|
|
8418
8577
|
};
|
|
8419
8578
|
var MENU_ITEM_STYLES = {
|
|
8420
8579
|
padding: "ps-4 pe-6",
|
|
@@ -8501,7 +8660,7 @@ var ToggleFABComponent = React62__namespace.forwardRef(
|
|
|
8501
8660
|
onToggle,
|
|
8502
8661
|
icon,
|
|
8503
8662
|
colorVariant = "primary",
|
|
8504
|
-
|
|
8663
|
+
size = "sm",
|
|
8505
8664
|
className,
|
|
8506
8665
|
id,
|
|
8507
8666
|
"aria-label": ariaLabel,
|
|
@@ -8510,7 +8669,7 @@ var ToggleFABComponent = React62__namespace.forwardRef(
|
|
|
8510
8669
|
var _a, _b;
|
|
8511
8670
|
const prefersReduced = react.useReducedMotion();
|
|
8512
8671
|
const colors = (_a = TOGGLE_FAB_COLORS[colorVariant]) != null ? _a : TOGGLE_FAB_COLORS.primary;
|
|
8513
|
-
const sizeTokens = (_b = TOGGLE_FAB_SIZES[
|
|
8672
|
+
const sizeTokens = (_b = TOGGLE_FAB_SIZES[size]) != null ? _b : TOGGLE_FAB_SIZES.sm;
|
|
8514
8673
|
const springConfig = prefersReduced ? SPRING_REDUCED : SPRING_NORMAL;
|
|
8515
8674
|
const checkedProgress = react.useSpring(expanded ? 1 : 0, springConfig);
|
|
8516
8675
|
React62__namespace.useEffect(() => {
|
|
@@ -8680,7 +8839,7 @@ function FABMenu({
|
|
|
8680
8839
|
onToggle,
|
|
8681
8840
|
items,
|
|
8682
8841
|
colorVariant = "primary",
|
|
8683
|
-
|
|
8842
|
+
size = "sm",
|
|
8684
8843
|
alignment = "end",
|
|
8685
8844
|
className,
|
|
8686
8845
|
closeOnBackdropClick = true,
|
|
@@ -8831,7 +8990,7 @@ function FABMenu({
|
|
|
8831
8990
|
expanded,
|
|
8832
8991
|
onToggle,
|
|
8833
8992
|
colorVariant,
|
|
8834
|
-
|
|
8993
|
+
size,
|
|
8835
8994
|
"aria-label": ariaLabel != null ? ariaLabel : expanded ? "Close actions menu" : "Open actions menu",
|
|
8836
8995
|
"aria-controls": menuId,
|
|
8837
8996
|
icon: defaultFabIcon
|
|
@@ -8975,7 +9134,7 @@ var IconButtonComponent = React62__namespace.forwardRef(
|
|
|
8975
9134
|
variant = "default",
|
|
8976
9135
|
colorStyle = "standard",
|
|
8977
9136
|
size = "sm",
|
|
8978
|
-
|
|
9137
|
+
width = "default",
|
|
8979
9138
|
shape = "round",
|
|
8980
9139
|
selected,
|
|
8981
9140
|
selectedIcon,
|
|
@@ -8993,7 +9152,7 @@ var IconButtonComponent = React62__namespace.forwardRef(
|
|
|
8993
9152
|
"variant",
|
|
8994
9153
|
"colorStyle",
|
|
8995
9154
|
"size",
|
|
8996
|
-
"
|
|
9155
|
+
"width",
|
|
8997
9156
|
"shape",
|
|
8998
9157
|
"selected",
|
|
8999
9158
|
"selectedIcon",
|
|
@@ -9038,7 +9197,7 @@ var IconButtonComponent = React62__namespace.forwardRef(
|
|
|
9038
9197
|
const iconPx = iconSize != null ? iconSize : defaultIconPx;
|
|
9039
9198
|
const isCustomSize = iconSize != null && iconSize !== "inherit";
|
|
9040
9199
|
const heightClass = (_c = SIZE_HEIGHT_STYLES[size]) != null ? _c : SIZE_HEIGHT_STYLES.sm;
|
|
9041
|
-
const widthClass = (_e = ((_d = WIDTH_SIZE_STYLES[size]) != null ? _d : WIDTH_SIZE_STYLES.sm)[
|
|
9200
|
+
const widthClass = (_e = ((_d = WIDTH_SIZE_STYLES[size]) != null ? _d : WIDTH_SIZE_STYLES.sm)[width]) != null ? _e : WIDTH_SIZE_STYLES.sm.default;
|
|
9042
9201
|
const needsTouchTarget = size === "xs" || size === "sm";
|
|
9043
9202
|
const { ripples, onPointerDown, removeRipple } = useRippleState({
|
|
9044
9203
|
disabled: loading
|
|
@@ -22924,39 +23083,7 @@ var typographyVariants = classVarianceAuthority.cva("m-0 p-0 text-m3-on-surface"
|
|
|
22924
23083
|
"label-sm": "text-[11px] leading-[16px] font-medium tracking-[0.5px]",
|
|
22925
23084
|
"body-lg": "text-[16px] leading-[24px] font-normal tracking-[0.5px]",
|
|
22926
23085
|
"body-md": "text-[14px] leading-[20px] font-normal tracking-[0.25px]",
|
|
22927
|
-
"body-sm": "text-[12px] leading-[16px] font-normal tracking-[0.4px]"
|
|
22928
|
-
// Full hyphenated aliases
|
|
22929
|
-
"display-large": "text-[57px] leading-[64px] font-normal tracking-[-0.25px]",
|
|
22930
|
-
"display-medium": "text-[45px] leading-[52px] font-normal tracking-[0px]",
|
|
22931
|
-
"display-small": "text-[36px] leading-[44px] font-normal tracking-[0px]",
|
|
22932
|
-
"headline-large": "text-[32px] leading-[40px] font-normal tracking-[0px]",
|
|
22933
|
-
"headline-medium": "text-[28px] leading-[36px] font-normal tracking-[0px]",
|
|
22934
|
-
"headline-small": "text-[24px] leading-[32px] font-normal tracking-[0px]",
|
|
22935
|
-
"title-large": "text-[22px] leading-[28px] font-normal tracking-[0px]",
|
|
22936
|
-
"title-medium": "text-[16px] leading-[24px] font-medium tracking-[0.15px]",
|
|
22937
|
-
"title-small": "text-[14px] leading-[20px] font-medium tracking-[0.1px]",
|
|
22938
|
-
"label-large": "text-[14px] leading-[20px] font-medium tracking-[0.1px]",
|
|
22939
|
-
"label-medium": "text-[12px] leading-[16px] font-medium tracking-[0.5px]",
|
|
22940
|
-
"label-small": "text-[11px] leading-[16px] font-medium tracking-[0.5px]",
|
|
22941
|
-
"body-large": "text-[16px] leading-[24px] font-normal tracking-[0.5px]",
|
|
22942
|
-
"body-medium": "text-[14px] leading-[20px] font-normal tracking-[0.25px]",
|
|
22943
|
-
"body-small": "text-[12px] leading-[16px] font-normal tracking-[0.4px]",
|
|
22944
|
-
// CamelCase aliases
|
|
22945
|
-
displayLarge: "text-[57px] leading-[64px] font-normal tracking-[-0.25px]",
|
|
22946
|
-
displayMedium: "text-[45px] leading-[52px] font-normal tracking-[0px]",
|
|
22947
|
-
displaySmall: "text-[36px] leading-[44px] font-normal tracking-[0px]",
|
|
22948
|
-
headlineLarge: "text-[32px] leading-[40px] font-normal tracking-[0px]",
|
|
22949
|
-
headlineMedium: "text-[28px] leading-[36px] font-normal tracking-[0px]",
|
|
22950
|
-
headlineSmall: "text-[24px] leading-[32px] font-normal tracking-[0px]",
|
|
22951
|
-
titleLarge: "text-[22px] leading-[28px] font-normal tracking-[0px]",
|
|
22952
|
-
titleMedium: "text-[16px] leading-[24px] font-medium tracking-[0.15px]",
|
|
22953
|
-
titleSmall: "text-[14px] leading-[20px] font-medium tracking-[0.1px]",
|
|
22954
|
-
labelLarge: "text-[14px] leading-[20px] font-medium tracking-[0.1px]",
|
|
22955
|
-
labelMedium: "text-[12px] leading-[16px] font-medium tracking-[0.5px]",
|
|
22956
|
-
labelSmall: "text-[11px] leading-[16px] font-medium tracking-[0.5px]",
|
|
22957
|
-
bodyLarge: "text-[16px] leading-[24px] font-normal tracking-[0.5px]",
|
|
22958
|
-
bodyMedium: "text-[14px] leading-[20px] font-normal tracking-[0.25px]",
|
|
22959
|
-
bodySmall: "text-[12px] leading-[16px] font-normal tracking-[0.4px]"
|
|
23086
|
+
"body-sm": "text-[12px] leading-[16px] font-normal tracking-[0.4px]"
|
|
22960
23087
|
}
|
|
22961
23088
|
},
|
|
22962
23089
|
defaultVariants: {
|
|
@@ -24334,7 +24461,7 @@ var FloatingToolbarWithFabBase = React62__namespace.forwardRef(
|
|
|
24334
24461
|
fabPosition = orientation === "horizontal" ? "end" : "bottom",
|
|
24335
24462
|
animationDuration = 0.3,
|
|
24336
24463
|
scrollBehavior,
|
|
24337
|
-
fabSize = "
|
|
24464
|
+
fabSize = "sm",
|
|
24338
24465
|
className,
|
|
24339
24466
|
style
|
|
24340
24467
|
} = _b, props = __objRest(_b, [
|
|
@@ -24354,7 +24481,7 @@ var FloatingToolbarWithFabBase = React62__namespace.forwardRef(
|
|
|
24354
24481
|
const isHorizontal = orientation === "horizontal";
|
|
24355
24482
|
const effectiveExpanded = expanded && (!scrollBehavior || scrollBehavior.isExpanded);
|
|
24356
24483
|
const isFabBefore = fabPosition === "start" || fabPosition === "top";
|
|
24357
|
-
const resolvedFabSize = fabSize === "
|
|
24484
|
+
const resolvedFabSize = fabSize === "md" ? FabBaselineTokens.MediumContainerHeight : FabBaselineTokens.ContainerHeight;
|
|
24358
24485
|
const transitionSpec = __spreadProps(__spreadValues({}, SPRING_TRANSITION), {
|
|
24359
24486
|
duration: animationDuration
|
|
24360
24487
|
});
|
|
@@ -24493,7 +24620,7 @@ var ToolbarIconButton = React62__namespace.forwardRef(
|
|
|
24493
24620
|
(_a, ref) => {
|
|
24494
24621
|
var _b = _a, {
|
|
24495
24622
|
emphasis = "standard",
|
|
24496
|
-
|
|
24623
|
+
width = "default",
|
|
24497
24624
|
selected,
|
|
24498
24625
|
asChild,
|
|
24499
24626
|
className,
|
|
@@ -24501,7 +24628,7 @@ var ToolbarIconButton = React62__namespace.forwardRef(
|
|
|
24501
24628
|
whileTap
|
|
24502
24629
|
} = _b, props = __objRest(_b, [
|
|
24503
24630
|
"emphasis",
|
|
24504
|
-
"
|
|
24631
|
+
"width",
|
|
24505
24632
|
"selected",
|
|
24506
24633
|
"asChild",
|
|
24507
24634
|
"className",
|
|
@@ -24509,7 +24636,7 @@ var ToolbarIconButton = React62__namespace.forwardRef(
|
|
|
24509
24636
|
"whileTap"
|
|
24510
24637
|
]);
|
|
24511
24638
|
const context = useToolbarContext();
|
|
24512
|
-
const widthClass = TOOLBAR_ICON_BUTTON_WIDTH[
|
|
24639
|
+
const widthClass = TOOLBAR_ICON_BUTTON_WIDTH[width];
|
|
24513
24640
|
const colorStyle = VARIANT_TO_COLOR_STYLE[emphasis];
|
|
24514
24641
|
const iconButtonProps = selected !== void 0 ? {
|
|
24515
24642
|
variant: "toggle",
|
|
@@ -25495,6 +25622,7 @@ exports.FABPosition = FABPosition;
|
|
|
25495
25622
|
exports.FAST_EFFECTS_TRANSITION = FAST_EFFECTS_TRANSITION;
|
|
25496
25623
|
exports.FAST_SPATIAL_SPRING = FAST_SPATIAL_SPRING;
|
|
25497
25624
|
exports.FLOAT_PI = FLOAT_PI;
|
|
25625
|
+
exports.FadingBlurMask = FadingBlurMask;
|
|
25498
25626
|
exports.FilledSplitButtonLeading = FilledSplitButtonLeading;
|
|
25499
25627
|
exports.FilledSplitButtonTrailing = FilledSplitButtonTrailing;
|
|
25500
25628
|
exports.FilledSplitButtonTrailingUncheckable = FilledSplitButtonTrailingUncheckable;
|