@porsche-design-system/components-react 4.0.0-alpha.0 → 4.0.0-beta.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 +187 -1
- package/bin/patchRemixRunProcessBrowserGlobalIdentifier.js +0 -0
- package/cjs/lib/components/canvas.wrapper.cjs +3 -3
- package/{styles → emotion}/cjs/index.cjs +3 -3
- package/emotion/esm/index.d.ts +1 -0
- package/emotion/esm/index.mjs +1 -0
- package/{styles → emotion}/package.json +0 -5
- package/esm/lib/components/canvas.wrapper.d.ts +9 -1
- package/esm/lib/components/canvas.wrapper.mjs +3 -3
- package/esm/lib/components/display.wrapper.d.ts +2 -2
- package/esm/lib/components/divider.wrapper.d.ts +2 -2
- package/esm/lib/components/heading.wrapper.d.ts +2 -2
- package/esm/lib/components/icon.wrapper.d.ts +2 -2
- package/esm/lib/components/radio-group-option.wrapper.d.ts +2 -0
- package/esm/lib/components/text.wrapper.d.ts +2 -2
- package/esm/lib/components/textarea.wrapper.d.ts +2 -2
- package/esm/lib/types.d.ts +8 -1
- package/global-styles/cn/font-face.css +1 -1
- package/global-styles/cn/index.css +264 -115
- package/global-styles/color-scheme.css +135 -0
- package/global-styles/font-face.css +1 -1
- package/global-styles/index.css +264 -115
- package/global-styles/variables.css +158 -144
- package/package.json +16 -14
- package/scss/_index.scss +1 -0
- package/ssr/cjs/components/dist/styles/esm/styles-entry.cjs +671 -600
- package/ssr/cjs/components/dist/utils/esm/utils-entry.cjs +37 -29
- package/ssr/cjs/components-react/projects/react-ssr-wrapper/src/lib/components/canvas.wrapper.cjs +4 -4
- package/ssr/cjs/components-react/projects/react-ssr-wrapper/src/lib/components/radio-group-option.wrapper.cjs +3 -2
- package/ssr/cjs/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/button-tile.cjs +5 -4
- package/ssr/cjs/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/canvas.cjs +2 -13
- package/ssr/cjs/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/checkbox.cjs +5 -3
- package/ssr/cjs/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/input-date.cjs +1 -0
- package/ssr/cjs/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/input-email.cjs +1 -0
- package/ssr/cjs/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/input-month.cjs +1 -0
- package/ssr/cjs/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/input-number.cjs +1 -0
- package/ssr/cjs/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/input-password.cjs +1 -0
- package/ssr/cjs/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/input-search.cjs +1 -0
- package/ssr/cjs/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/input-tel.cjs +1 -0
- package/ssr/cjs/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/input-text.cjs +1 -0
- package/ssr/cjs/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/input-time.cjs +1 -0
- package/ssr/cjs/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/input-url.cjs +1 -0
- package/ssr/cjs/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/input-week.cjs +1 -0
- package/ssr/cjs/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/label.cjs +4 -2
- package/ssr/cjs/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/link-tile.cjs +5 -4
- package/ssr/cjs/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/multi-select.cjs +3 -2
- package/ssr/cjs/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/pin-code.cjs +3 -2
- package/ssr/cjs/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/radio-group-option.cjs +11 -3
- package/ssr/cjs/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/radio-group.cjs +3 -4
- package/ssr/cjs/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/segmented-control.cjs +4 -2
- package/ssr/cjs/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/select.cjs +2 -1
- package/ssr/cjs/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/tag.cjs +1 -1
- package/ssr/cjs/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/textarea.cjs +1 -0
- package/ssr/esm/components/dist/styles/esm/styles-entry.mjs +671 -601
- package/ssr/esm/components/dist/utils/esm/utils-entry.mjs +37 -29
- package/ssr/esm/components-react/projects/react-ssr-wrapper/src/lib/components/canvas.wrapper.mjs +4 -4
- package/ssr/esm/components-react/projects/react-ssr-wrapper/src/lib/components/radio-group-option.wrapper.mjs +3 -2
- package/ssr/esm/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/button-tile.mjs +5 -4
- package/ssr/esm/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/canvas.mjs +2 -13
- package/ssr/esm/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/checkbox.mjs +5 -3
- package/ssr/esm/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/input-date.mjs +1 -0
- package/ssr/esm/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/input-email.mjs +1 -0
- package/ssr/esm/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/input-month.mjs +1 -0
- package/ssr/esm/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/input-number.mjs +1 -0
- package/ssr/esm/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/input-password.mjs +1 -0
- package/ssr/esm/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/input-search.mjs +1 -0
- package/ssr/esm/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/input-tel.mjs +1 -0
- package/ssr/esm/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/input-text.mjs +1 -0
- package/ssr/esm/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/input-time.mjs +1 -0
- package/ssr/esm/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/input-url.mjs +1 -0
- package/ssr/esm/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/input-week.mjs +1 -0
- package/ssr/esm/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/label.mjs +4 -2
- package/ssr/esm/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/link-tile.mjs +5 -4
- package/ssr/esm/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/multi-select.mjs +3 -2
- package/ssr/esm/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/pin-code.mjs +5 -4
- package/ssr/esm/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/radio-group-option.mjs +12 -4
- package/ssr/esm/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/radio-group.mjs +4 -5
- package/ssr/esm/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/segmented-control.mjs +4 -2
- package/ssr/esm/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/select.mjs +2 -1
- package/ssr/esm/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/tag.mjs +1 -1
- package/ssr/esm/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/textarea.mjs +1 -0
- package/ssr/esm/lib/components/canvas.wrapper.d.ts +9 -1
- package/ssr/esm/lib/components/display.wrapper.d.ts +2 -2
- package/ssr/esm/lib/components/divider.wrapper.d.ts +2 -2
- package/ssr/esm/lib/components/heading.wrapper.d.ts +2 -2
- package/ssr/esm/lib/components/icon.wrapper.d.ts +2 -2
- package/ssr/esm/lib/components/radio-group-option.wrapper.d.ts +2 -0
- package/ssr/esm/lib/components/text.wrapper.d.ts +2 -2
- package/ssr/esm/lib/components/textarea.wrapper.d.ts +2 -2
- package/ssr/esm/lib/dsr-components/canvas.d.ts +0 -3
- package/ssr/esm/lib/dsr-components/checkbox.d.ts +4 -2
- package/ssr/esm/lib/dsr-components/input-date.d.ts +1 -0
- package/ssr/esm/lib/dsr-components/input-email.d.ts +1 -0
- package/ssr/esm/lib/dsr-components/input-month.d.ts +1 -0
- package/ssr/esm/lib/dsr-components/input-number.d.ts +1 -0
- package/ssr/esm/lib/dsr-components/input-password.d.ts +1 -0
- package/ssr/esm/lib/dsr-components/input-search.d.ts +1 -0
- package/ssr/esm/lib/dsr-components/input-tel.d.ts +1 -0
- package/ssr/esm/lib/dsr-components/input-text.d.ts +1 -0
- package/ssr/esm/lib/dsr-components/input-time.d.ts +1 -0
- package/ssr/esm/lib/dsr-components/input-url.d.ts +1 -0
- package/ssr/esm/lib/dsr-components/input-week.d.ts +1 -0
- package/ssr/esm/lib/dsr-components/label.d.ts +1 -0
- package/ssr/esm/lib/dsr-components/multi-select.d.ts +2 -1
- package/ssr/esm/lib/dsr-components/pin-code.d.ts +2 -1
- package/ssr/esm/lib/dsr-components/radio-group-option.d.ts +4 -0
- package/ssr/esm/lib/dsr-components/radio-group.d.ts +2 -1
- package/ssr/esm/lib/dsr-components/segmented-control.d.ts +2 -1
- package/ssr/esm/lib/dsr-components/select.d.ts +2 -1
- package/ssr/esm/lib/dsr-components/textarea.d.ts +1 -0
- package/ssr/esm/lib/types.d.ts +8 -1
- package/tailwindcss/index.css +223 -135
- package/{styles/vanilla-extract → vanilla-extract}/cjs/index.cjs +1 -1
- package/vanilla-extract/esm/index.d.ts +1 -0
- package/vanilla-extract/esm/index.mjs +1 -0
- package/vanilla-extract/package.json +13 -0
- package/ssr/esm/lib/dsr-components/legacy-label.d.ts +0 -14
- package/styles/_index.scss +0 -1
- package/styles/esm/index.d.ts +0 -1
- package/styles/esm/index.mjs +0 -1
- package/styles/vanilla-extract/esm/index.d.ts +0 -1
- package/styles/vanilla-extract/esm/index.mjs +0 -1
|
@@ -1,63 +1,83 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
const
|
|
3
|
+
const blurFrosted = 'blur(32px)';
|
|
4
4
|
|
|
5
|
-
|
|
5
|
+
/** @deprecated since v4.0.0, will be removed with next major release. Use backdropFilter: blurFrosted instead */
|
|
6
|
+
const frostedGlassStyle = {
|
|
7
|
+
WebkitBackdropFilter: blurFrosted,
|
|
8
|
+
backdropFilter: blurFrosted,
|
|
9
|
+
};
|
|
6
10
|
|
|
7
|
-
|
|
11
|
+
/** @deprecated since v4.0.0, will be removed with next major release. Use 2px instead. */
|
|
12
|
+
const borderWidthBase = '2px';
|
|
8
13
|
|
|
9
|
-
|
|
14
|
+
/** @deprecated since v4.0.0, will be removed with next major release. Use 1px instead. */
|
|
15
|
+
const borderWidthThin = '1px';
|
|
10
16
|
|
|
11
|
-
const
|
|
17
|
+
const fontPorscheNext = "'Porsche Next','Arial Narrow',Arial,'Heiti SC',SimHei,sans-serif";
|
|
12
18
|
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
};
|
|
19
|
+
/** @deprecated since v4.0.0, will be removed with next major release. Use fontPorscheNext instead. */
|
|
20
|
+
const fontFamily = fontPorscheNext;
|
|
16
21
|
|
|
17
|
-
const
|
|
22
|
+
const leadingNormal = 'calc(6px + 2.125ex)';
|
|
18
23
|
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
24
|
+
/** @deprecated since v4.0.0, will be removed with next major release. Use leadingNormal instead */
|
|
25
|
+
const fontLineHeight = leadingNormal;
|
|
26
|
+
|
|
27
|
+
const fontSizeDisplayLarge = 'clamp(2.28rem, 5.2vw + 1.24rem, 7.48rem)';
|
|
22
28
|
|
|
23
|
-
const
|
|
29
|
+
const fontSizeDisplayMedium = 'clamp(2.03rem, 3.58vw + 1.31rem, 5.61rem)';
|
|
24
30
|
|
|
25
|
-
const
|
|
31
|
+
const fontSizeDisplaySmall = 'clamp(1.8rem, 2.41vw + 1.32rem, 4.21rem)';
|
|
26
32
|
|
|
27
|
-
const
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
33
|
+
const typescaleLg = 'clamp(1.27rem, 0.51vw + 1.16rem, 1.78rem)';
|
|
34
|
+
|
|
35
|
+
/** @deprecated since v4.0.0, will be removed with next major release. Use typescaleLg instead. */
|
|
36
|
+
const fontSizeHeadingLarge = typescaleLg;
|
|
37
|
+
|
|
38
|
+
const typescaleMd = 'clamp(1.13rem, 0.21vw + 1.08rem, 1.33rem)';
|
|
32
39
|
|
|
33
|
-
|
|
40
|
+
/** @deprecated since v4.0.0, will be removed with next major release. Use typescaleMd instead. */
|
|
41
|
+
const fontSizeHeadingMedium = typescaleMd;
|
|
34
42
|
|
|
35
|
-
const
|
|
43
|
+
const typescaleSm = '1rem';
|
|
36
44
|
|
|
37
|
-
|
|
45
|
+
/** @deprecated since v4.0.0, will be removed with next major release. Use typescaleSm instead. */
|
|
46
|
+
const fontSizeHeadingSmall = typescaleSm;
|
|
38
47
|
|
|
39
|
-
const
|
|
48
|
+
const typescaleXl = 'clamp(1.42rem, 0.94vw + 1.23rem, 2.37rem)';
|
|
40
49
|
|
|
41
|
-
|
|
50
|
+
/** @deprecated since v4.0.0, will be removed with next major release. Use typescaleXl instead. */
|
|
51
|
+
const fontSizeHeadingXLarge = typescaleXl;
|
|
42
52
|
|
|
43
|
-
const
|
|
53
|
+
const typescale2Xl = 'clamp(1.6rem, 1.56vw + 1.29rem, 3.16rem)';
|
|
44
54
|
|
|
45
|
-
|
|
55
|
+
/** @deprecated since v4.0.0, will be removed with next major release. Use typescale2Xl instead. */
|
|
56
|
+
const fontSizeHeadingXXLarge = typescale2Xl;
|
|
46
57
|
|
|
47
|
-
|
|
58
|
+
/** @deprecated since v4.0.0, will be removed with next major release. Use typescaleLg instead. */
|
|
59
|
+
const fontSizeTextLarge = typescaleLg;
|
|
48
60
|
|
|
49
|
-
|
|
61
|
+
/** @deprecated since v4.0.0, will be removed with next major release. Use typescaleMd instead. */
|
|
62
|
+
const fontSizeTextMedium = typescaleMd;
|
|
50
63
|
|
|
51
|
-
|
|
64
|
+
/** @deprecated since v4.0.0, will be removed with next major release. Use typescaleSm instead. */
|
|
65
|
+
const fontSizeTextSmall = typescaleSm;
|
|
52
66
|
|
|
53
|
-
|
|
67
|
+
/** @deprecated since v4.0.0, will be removed with next major release. Use typescaleXl instead. */
|
|
68
|
+
const fontSizeTextXLarge = typescaleXl;
|
|
54
69
|
|
|
55
|
-
const
|
|
70
|
+
const typescaleXs$1 = 'clamp(0.81rem, 0.23vw + 0.77rem, 0.88rem)';
|
|
56
71
|
|
|
57
|
-
|
|
72
|
+
/** @deprecated since v4.0.0, will be removed with next major release. Use typescaleXs instead. */
|
|
73
|
+
const fontSizeTextXSmall = typescaleXs$1;
|
|
58
74
|
|
|
59
|
-
const
|
|
75
|
+
const typescale2Xs = '.75rem';
|
|
60
76
|
|
|
77
|
+
/** @deprecated since v4.0.0, will be removed with next major release. Use typescale2Xs instead. */
|
|
78
|
+
const fontSizeTextXXSmall = typescale2Xs;
|
|
79
|
+
|
|
80
|
+
/** @deprecated since v4.0.0, will be removed with next major release. Use typescale variables instead. */
|
|
61
81
|
const fontSizeText = {
|
|
62
82
|
xxSmall: fontSizeTextXXSmall,
|
|
63
83
|
xSmall: fontSizeTextXSmall,
|
|
@@ -67,48 +87,33 @@ const fontSizeText = {
|
|
|
67
87
|
xLarge: fontSizeTextXLarge,
|
|
68
88
|
};
|
|
69
89
|
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
const fontSizeHeadingMedium = fontSizeMd;
|
|
73
|
-
|
|
74
|
-
const fontSizeHeadingLarge = fontSizeLg;
|
|
75
|
-
|
|
76
|
-
const fontSizeHeadingXLarge = fontSizeXl;
|
|
77
|
-
|
|
78
|
-
const fontSize2Xl = 'clamp(1.6rem, 1.56vw + 1.29rem, 3.16rem)';
|
|
79
|
-
|
|
80
|
-
const fontSizeHeadingXXLarge = fontSize2Xl;
|
|
81
|
-
|
|
82
|
-
const fontSizeDisplaySmall = 'clamp(1.8rem, 2.41vw + 1.32rem, 4.21rem)';
|
|
83
|
-
|
|
84
|
-
const fontSizeDisplayMedium = 'clamp(2.03rem, 3.58vw + 1.31rem, 5.61rem)';
|
|
90
|
+
/** @deprecated since v4.0.0, will be removed with next major release. Use 'normal' instead. */
|
|
91
|
+
const fontStyleNormal = 'normal';
|
|
85
92
|
|
|
86
|
-
|
|
93
|
+
/** @deprecated since v4.0.0, will be removed with next major release. Use 'normal' instead. */
|
|
94
|
+
const fontVariant = 'normal';
|
|
87
95
|
|
|
88
|
-
const
|
|
96
|
+
const fontWeightNormal = 400;
|
|
89
97
|
|
|
90
|
-
|
|
98
|
+
/** @deprecated since v4.0.0, will be removed with next major release. Use fontWeightNormal instead. */
|
|
99
|
+
const fontWeightRegular = fontWeightNormal;
|
|
91
100
|
|
|
92
|
-
const
|
|
101
|
+
const fontWeightSemibold = 600;
|
|
93
102
|
|
|
94
|
-
|
|
103
|
+
/** @deprecated since v4.0.0, will be removed with next major release. Use fontWeightSemibold instead. */
|
|
104
|
+
const fontWeightSemiBold = fontWeightSemibold;
|
|
95
105
|
|
|
96
106
|
const fontWeightBold$1 = 700;
|
|
97
107
|
|
|
98
108
|
const fontWeightBold = fontWeightBold$1;
|
|
99
109
|
|
|
100
|
-
const
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
const blurFrosted = 'blur(32px)';
|
|
105
|
-
|
|
106
|
-
const frostedGlassStyle = {
|
|
107
|
-
WebkitBackdropFilter: blurFrosted,
|
|
108
|
-
backdropFilter: blurFrosted,
|
|
110
|
+
const fontHyphenationStyle = {
|
|
111
|
+
overflowWrap: 'break-word',
|
|
112
|
+
// @ts-ignore
|
|
113
|
+
hyphens: 'var(--p-hyphens, auto)',
|
|
109
114
|
};
|
|
110
115
|
|
|
111
|
-
const
|
|
116
|
+
const gradientStopsFadeDark = 'hsla(0,0%,0%,.8) 0%,' +
|
|
112
117
|
'hsla(0,0%,0%,.8) 8.1%,' +
|
|
113
118
|
'hsla(0,0%,0%,.8) 15.5%,' +
|
|
114
119
|
'hsla(0,0%,0%,.8) 22.5%,' +
|
|
@@ -125,36 +130,38 @@ const gradientFade = 'hsla(0,0%,0%,.8) 0%,' +
|
|
|
125
130
|
'hsla(0,0%,0%,.011) 91.9%,' +
|
|
126
131
|
'hsla(0,0%,0%,0) 100%';
|
|
127
132
|
|
|
133
|
+
/** @deprecated since v4.0.0, will be removed with next major release. Use background: `linear-gradient(to bottom, ${gradientStopsFadeDark});` instead */
|
|
128
134
|
const gradientToBottomStyle = {
|
|
129
|
-
background: `linear-gradient(to bottom, ${
|
|
135
|
+
background: `linear-gradient(to bottom, ${gradientStopsFadeDark});`,
|
|
130
136
|
};
|
|
131
137
|
|
|
138
|
+
/** @deprecated since v4.0.0, will be removed with next major release. background: `linear-gradient(to top, ${gradientStopsFadeDark});` instead */
|
|
132
139
|
const gradientToTopStyle = {
|
|
133
|
-
background: `linear-gradient(to top, ${
|
|
140
|
+
background: `linear-gradient(to top, ${gradientStopsFadeDark});`,
|
|
134
141
|
};
|
|
135
142
|
|
|
136
143
|
const breakpointBase = 0;
|
|
137
144
|
|
|
138
|
-
const
|
|
139
|
-
|
|
140
|
-
const breakpointXS = breakpointXs;
|
|
141
|
-
|
|
142
|
-
const breakpointSm = 760;
|
|
145
|
+
const breakpointLg = 1300;
|
|
143
146
|
|
|
144
|
-
const
|
|
147
|
+
const breakpointL = breakpointLg;
|
|
145
148
|
|
|
146
149
|
const breakpointMd = 1000;
|
|
147
150
|
|
|
148
151
|
const breakpointM = breakpointMd;
|
|
149
152
|
|
|
150
|
-
const
|
|
153
|
+
const breakpointSm = 760;
|
|
151
154
|
|
|
152
|
-
const
|
|
155
|
+
const breakpointS = breakpointSm;
|
|
153
156
|
|
|
154
157
|
const breakpointXl = 1760;
|
|
155
158
|
|
|
156
159
|
const breakpointXL = breakpointXl;
|
|
157
160
|
|
|
161
|
+
const breakpointXs = 480;
|
|
162
|
+
|
|
163
|
+
const breakpointXS = breakpointXs;
|
|
164
|
+
|
|
158
165
|
const breakpoint2Xl = 1920;
|
|
159
166
|
|
|
160
167
|
const breakpointXXL = breakpoint2Xl;
|
|
@@ -175,6 +182,7 @@ function getMediaQueryMin(min) {
|
|
|
175
182
|
|
|
176
183
|
const spacingFluidMd = 'clamp(16px, 1.25vw + 12px, 36px)';
|
|
177
184
|
|
|
185
|
+
/** @deprecated since v4.0.0, will be removed with next major release. Use spacingFluidMd instead. */
|
|
178
186
|
const spacingFluidMedium = spacingFluidMd;
|
|
179
187
|
|
|
180
188
|
const gridGap = spacingFluidMedium;
|
|
@@ -196,6 +204,20 @@ const _gridPadding = `max(0px, 50vw - ${_gridWidthMax} / 2)`;
|
|
|
196
204
|
const _getGridOffsetS = (width) => `calc(${_gridSafeZoneS} + (${gridGap} + ${gridColumnWidthS}) * ${columnMap[width]})`;
|
|
197
205
|
const _getGridOffsetXXL = (width) => `calc(${_gridPadding} + ${_gridSafeZoneXXL} + (${gridGap} + ${gridColumnWidthXXL}) * ${columnMap[width]})`;
|
|
198
206
|
|
|
207
|
+
const gridFullOffset = _gridPadding;
|
|
208
|
+
|
|
209
|
+
const gridWideOffsetBase = _gridSafeZoneBase;
|
|
210
|
+
|
|
211
|
+
const gridWideOffsetS = _gridSafeZoneS;
|
|
212
|
+
|
|
213
|
+
const gridWideOffsetXXL = `calc(${_gridPadding} + ${_gridSafeZoneXXL})`;
|
|
214
|
+
|
|
215
|
+
const gridWideOffset = {
|
|
216
|
+
base: gridWideOffsetBase,
|
|
217
|
+
s: gridWideOffsetS,
|
|
218
|
+
xxl: gridWideOffsetXXL,
|
|
219
|
+
};
|
|
220
|
+
|
|
199
221
|
const gridExtendedOffsetBase = _gridSafeZoneBase;
|
|
200
222
|
|
|
201
223
|
const gridExtendedOffsetS = _getGridOffsetS('extended');
|
|
@@ -220,67 +242,97 @@ const gridBasicOffset = {
|
|
|
220
242
|
xxl: gridBasicOffsetXXL,
|
|
221
243
|
};
|
|
222
244
|
|
|
223
|
-
const motionDurationShort$1 = '.25s';
|
|
224
|
-
|
|
225
|
-
const motionDurationShort = motionDurationShort$1;
|
|
226
|
-
|
|
227
|
-
const motionEaseInOut = 'cubic-bezier(.25,.1,.25,1)';
|
|
228
|
-
|
|
229
|
-
const motionEasingBase = motionEaseInOut;
|
|
230
|
-
|
|
231
245
|
const breakpoints = ['base', 'xs', 's', 'm', 'l', 'xl', 'xxl'];
|
|
232
246
|
|
|
233
247
|
function getMediaQueryMax(max) {
|
|
234
248
|
return `@media(max-width:${breakpoint[max] - 1}px)`;
|
|
235
249
|
}
|
|
236
250
|
|
|
237
|
-
const
|
|
251
|
+
const durationLg = '.6s';
|
|
238
252
|
|
|
239
|
-
|
|
253
|
+
/** @deprecated since v4.0.0, will be removed with next major release. Use durationLg instead. */
|
|
254
|
+
const motionDurationLong = durationLg;
|
|
240
255
|
|
|
241
|
-
const
|
|
256
|
+
const durationMd = '.4s';
|
|
242
257
|
|
|
243
|
-
|
|
258
|
+
/** @deprecated since v4.0.0, will be removed with next major release. Use durationMd instead. */
|
|
259
|
+
const motionDurationModerate = durationMd;
|
|
244
260
|
|
|
245
|
-
const
|
|
261
|
+
const durationSm = '.25s';
|
|
246
262
|
|
|
247
|
-
|
|
263
|
+
/** @deprecated since v4.0.0, will be removed with next major release. Use durationSm instead. */
|
|
264
|
+
const motionDurationShort = durationSm;
|
|
248
265
|
|
|
249
|
-
const
|
|
266
|
+
const durationXl = '1.2s';
|
|
250
267
|
|
|
251
|
-
|
|
268
|
+
/** @deprecated since v4.0.0, will be removed with next major release. Use durationXl instead. */
|
|
269
|
+
const motionDurationVeryLong = durationXl;
|
|
252
270
|
|
|
253
|
-
const
|
|
271
|
+
const easeInOut = 'cubic-bezier(.25,.1,.25,1)';
|
|
254
272
|
|
|
255
|
-
|
|
273
|
+
/** @deprecated since v4.0.0, will be removed with next major release. Use easeInOut instead. */
|
|
274
|
+
const motionEasingBase = easeInOut;
|
|
256
275
|
|
|
257
|
-
const
|
|
276
|
+
const easeIn = 'cubic-bezier(0,0,.2,1)';
|
|
258
277
|
|
|
259
|
-
|
|
278
|
+
/** @deprecated since v4.0.0, will be removed with next major release. Use easeIn instead. */
|
|
279
|
+
const motionEasingIn = easeIn;
|
|
260
280
|
|
|
261
|
-
const
|
|
281
|
+
const easeOut = 'cubic-bezier(.4,0,.5,1)';
|
|
262
282
|
|
|
263
|
-
|
|
283
|
+
/** @deprecated since v4.0.0, will be removed with next major release. Use easeOut instead. */
|
|
284
|
+
const motionEasingOut = easeOut;
|
|
264
285
|
|
|
265
|
-
const
|
|
286
|
+
const shadowLg = '0px 8px 40px rgba(0,0,0,.16)';
|
|
266
287
|
|
|
267
|
-
|
|
288
|
+
/** @deprecated since v4.0.0, will be removed with next major release. Use boxShadow: shadowLg instead. */
|
|
289
|
+
const dropShadowHighStyle = {
|
|
290
|
+
boxShadow: shadowLg,
|
|
291
|
+
};
|
|
268
292
|
|
|
269
|
-
const
|
|
293
|
+
const shadowSm = '0px 3px 8px rgba(0,0,0,.16)';
|
|
270
294
|
|
|
271
|
-
|
|
295
|
+
/** @deprecated since v4.0.0, will be removed with next major release. Use boxShadow: shadowSm instead. */
|
|
296
|
+
const dropShadowLowStyle = {
|
|
297
|
+
boxShadow: shadowSm,
|
|
298
|
+
};
|
|
299
|
+
|
|
300
|
+
const spacingFluidLg = 'clamp(32px, 2.75vw + 23px, 76px)';
|
|
301
|
+
|
|
302
|
+
/** @deprecated since v4.0.0, will be removed with next major release. Use spacingFluidLg instead. */
|
|
303
|
+
const spacingFluidLarge = spacingFluidLg;
|
|
272
304
|
|
|
273
305
|
const spacingFluidSm = 'clamp(8px, 0.5vw + 6px, 16px)';
|
|
274
306
|
|
|
307
|
+
/** @deprecated since v4.0.0, will be removed with next major release. Use spacingFluidSm instead. */
|
|
275
308
|
const spacingFluidSmall = spacingFluidSm;
|
|
276
309
|
|
|
277
|
-
const
|
|
310
|
+
const spacingFluidXs = 'clamp(4px, 0.25vw + 3px, 8px)';
|
|
278
311
|
|
|
279
|
-
|
|
312
|
+
/** @deprecated since v4.0.0, will be removed with next major release. Use spacingFluidXs instead. */
|
|
313
|
+
const spacingFluidXSmall = spacingFluidXs;
|
|
314
|
+
|
|
315
|
+
const spacingStaticMd = '16px';
|
|
316
|
+
|
|
317
|
+
/** @deprecated since v4.0.0, will be removed with next major release. Use spacingStaticMd instead. */
|
|
318
|
+
const spacingStaticMedium = spacingStaticMd;
|
|
319
|
+
|
|
320
|
+
const spacingStaticSm$1 = '8px';
|
|
321
|
+
|
|
322
|
+
/** @deprecated since v4.0.0, will be removed with next major release. Use spacingStaticSm instead. */
|
|
323
|
+
const spacingStaticSmall = spacingStaticSm$1;
|
|
324
|
+
|
|
325
|
+
const spacingStaticXs$2 = '4px';
|
|
326
|
+
|
|
327
|
+
/** @deprecated since v4.0.0, will be removed with next major release. Use spacingStaticXs instead. */
|
|
328
|
+
const spacingStaticXSmall = spacingStaticXs$2;
|
|
329
|
+
|
|
330
|
+
const spacingStaticXs$1 = spacingStaticXs$2;
|
|
280
331
|
|
|
281
332
|
const _displayFontPartA = `${fontStyleNormal} ${fontVariant} ${fontWeightRegular} `;
|
|
282
333
|
const _displayFontPartB = `/${fontLineHeight} ${fontFamily}`;
|
|
283
334
|
|
|
335
|
+
/** @deprecated since v4.0.0, will be removed with next major release. Use proseDisplayLg instead. */
|
|
284
336
|
const displayLargeStyle = {
|
|
285
337
|
font: `${_displayFontPartA}${fontSizeDisplayLarge}${_displayFontPartB}`,
|
|
286
338
|
};
|
|
@@ -288,18 +340,22 @@ const displayLargeStyle = {
|
|
|
288
340
|
const _headingFontPartA = `${fontStyleNormal} ${fontVariant} ${fontWeightRegular} `;
|
|
289
341
|
const _headingFontPartB = `/${fontLineHeight} ${fontFamily}`;
|
|
290
342
|
|
|
343
|
+
/** @deprecated since v4.0.0, will be removed with next major release. Use proseHeadingSm instead. */
|
|
291
344
|
const headingSmallStyle = {
|
|
292
345
|
font: `${_headingFontPartA}${fontSizeHeadingSmall}${_headingFontPartB}`,
|
|
293
346
|
};
|
|
294
347
|
|
|
348
|
+
/** @deprecated since v4.0.0, will be removed with next major release. Use proseHeadingMd instead. */
|
|
295
349
|
const headingMediumStyle = {
|
|
296
350
|
font: `${_headingFontPartA}${fontSizeHeadingMedium}${_headingFontPartB}`,
|
|
297
351
|
};
|
|
298
352
|
|
|
353
|
+
/** @deprecated since v4.0.0, will be removed with next major release. Use proseHeadingXl instead. */
|
|
299
354
|
const headingXLargeStyle = {
|
|
300
355
|
font: `${_headingFontPartA}${fontSizeHeadingXLarge}${_headingFontPartB}`,
|
|
301
356
|
};
|
|
302
357
|
|
|
358
|
+
/** @deprecated since v4.0.0, will be removed with next major release. Use proseHeading2Xl instead. */
|
|
303
359
|
const headingXXLargeStyle = {
|
|
304
360
|
font: `${_headingFontPartA}${fontSizeHeadingXXLarge}${_headingFontPartB}`,
|
|
305
361
|
};
|
|
@@ -307,53 +363,108 @@ const headingXXLargeStyle = {
|
|
|
307
363
|
const _textFontPartA = `${fontStyleNormal} ${fontVariant} ${fontWeightRegular} `;
|
|
308
364
|
const _textFontPartB = `/${fontLineHeight} ${fontFamily}`;
|
|
309
365
|
|
|
366
|
+
/** @deprecated since v4.0.0, will be removed with next major release. Use proseText2Xs instead. */
|
|
310
367
|
const textXXSmallStyle = {
|
|
311
368
|
font: `${_textFontPartA}${fontSizeTextXXSmall}${_textFontPartB}`,
|
|
312
369
|
...fontHyphenationStyle,
|
|
313
370
|
};
|
|
314
371
|
|
|
372
|
+
/** @deprecated since v4.0.0, will be removed with next major release. Use proseTextXs instead. */
|
|
315
373
|
const textXSmallStyle = {
|
|
316
374
|
font: `${_textFontPartA}${fontSizeTextXSmall}${_textFontPartB}`,
|
|
317
375
|
...fontHyphenationStyle,
|
|
318
376
|
};
|
|
319
377
|
|
|
378
|
+
/** @deprecated since v4.0.0, will be removed with next major release. Use proseTextSm instead. */
|
|
320
379
|
const textSmallStyle = {
|
|
321
380
|
font: `${_textFontPartA}${fontSizeTextSmall}${_textFontPartB}`,
|
|
322
381
|
...fontHyphenationStyle,
|
|
323
382
|
};
|
|
324
383
|
|
|
384
|
+
/** @deprecated since v4.0.0, will be removed with next major release. Use proseTextMd instead. */
|
|
325
385
|
const textMediumStyle = {
|
|
326
386
|
font: `${_textFontPartA}${fontSizeTextMedium}${_textFontPartB}`,
|
|
327
387
|
...fontHyphenationStyle,
|
|
328
388
|
};
|
|
329
389
|
|
|
390
|
+
const proseTextSmStyle = {
|
|
391
|
+
font: `normal normal ${fontWeightNormal} ${typescaleSm} / ${leadingNormal} ${fontPorscheNext}`,
|
|
392
|
+
...fontHyphenationStyle,
|
|
393
|
+
};
|
|
394
|
+
|
|
330
395
|
const alphaDisabled = 0.4;
|
|
331
396
|
|
|
332
|
-
const
|
|
333
|
-
dark: {
|
|
334
|
-
grey: {
|
|
335
|
-
'950': 'hsl(240, 12.5%, 96.9%)',
|
|
336
|
-
'100a': 'hsla(240, 3.7%, 26.5%, 0.154)',
|
|
337
|
-
'200a': 'hsla(240, 2.2%, 44.1%, 0.228)'},
|
|
338
|
-
},
|
|
339
|
-
};
|
|
397
|
+
const legacyRadiusLarge = '--_p-legacy-radius-large';
|
|
340
398
|
|
|
341
|
-
const
|
|
399
|
+
const legacyRadiusMedium = '--_p-legacy-radius-medium';
|
|
342
400
|
|
|
343
|
-
const
|
|
401
|
+
const legacyRadiusSmall = '--_p-legacy-radius-small';
|
|
344
402
|
|
|
345
|
-
const
|
|
403
|
+
const radius2Xl = 'var(--p-radius-2xl)';
|
|
346
404
|
|
|
347
|
-
const
|
|
405
|
+
const radius3Xl = 'var(--p-radius-3xl)';
|
|
348
406
|
|
|
349
|
-
const
|
|
407
|
+
const radius4Xl = 'var(--p-radius-4xl)';
|
|
408
|
+
|
|
409
|
+
const radiusFull = 'var(--p-radius-full)';
|
|
410
|
+
|
|
411
|
+
const radiusLg = 'var(--p-radius-lg)';
|
|
412
|
+
|
|
413
|
+
const radiusMd = 'var(--p-radius-md)';
|
|
414
|
+
|
|
415
|
+
const radiusSm = 'var(--p-radius-sm)';
|
|
416
|
+
|
|
417
|
+
const radiusXl = 'var(--p-radius-xl)';
|
|
350
418
|
|
|
351
|
-
|
|
419
|
+
const colorFocus = 'var(--p-color-focus)';
|
|
352
420
|
|
|
353
|
-
|
|
354
|
-
var cssVariables = { "focusColor": "var(--p-color-focus)", "disabledColor": "var(--p-color-disabled)", "canvasColor": "var(--p-color-canvas)", "surfaceColor": "var(--p-color-surface)", "frostedColor": "var(--p-color-frosted)", "frostedSoftColor": "var(--p-color-frosted-soft)", "backdropColor": "var(--p-color-backdrop)", "contrastLowerColor": "var(--p-color-contrast-lower)", "contrastLowColor": "var(--p-color-contrast-low)", "contrastMediumColor": "var(--p-color-contrast-medium)", "contrastHighColor": "var(--p-color-contrast-high)", "primaryColor": "var(--p-color-primary)", "successColor": "var(--p-color-success)", "successLowColor": "var(--p-color-success-low)", "successFrostedColor": "var(--p-color-success-frosted)", "successFrostedSoftColor": "var(--p-color-success-frosted-soft)", "warningColor": "var(--p-color-warning)", "warningFrostedColor": "var(--p-color-warning-frosted)", "warningFrostedSoftColor": "var(--p-color-warning-frosted-soft)", "errorColor": "var(--p-color-error)", "errorLowColor": "var(--p-color-error-low)", "errorFrostedColor": "var(--p-color-error-frosted)", "errorFrostedSoftColor": "var(--p-color-error-frosted-soft)", "infoColor": "var(--p-color-info)", "infoFrostedColor": "var(--p-color-info-frosted)", "infoFrostedSoftColor": "var(--p-color-info-frosted-soft)"};
|
|
421
|
+
const colorBackdrop = 'var(--p-color-backdrop)';
|
|
355
422
|
|
|
356
|
-
const
|
|
423
|
+
const colorCanvas = 'var(--p-color-canvas)';
|
|
424
|
+
|
|
425
|
+
const colorFrosted = 'var(--p-color-frosted)';
|
|
426
|
+
|
|
427
|
+
const colorFrostedSoft = 'var(--p-color-frosted-soft)';
|
|
428
|
+
|
|
429
|
+
const colorFrostedStrong = 'var(--p-color-frosted-strong)';
|
|
430
|
+
|
|
431
|
+
const colorSurface = 'var(--p-color-surface)';
|
|
432
|
+
|
|
433
|
+
const colorContrastHigh = 'var(--p-color-contrast-high)';
|
|
434
|
+
|
|
435
|
+
const colorContrastLow = 'var(--p-color-contrast-low)';
|
|
436
|
+
|
|
437
|
+
const colorContrastLower = 'var(--p-color-contrast-lower)';
|
|
438
|
+
|
|
439
|
+
const colorContrastMedium = 'var(--p-color-contrast-medium)';
|
|
440
|
+
|
|
441
|
+
const colorPrimary = 'var(--p-color-primary)';
|
|
442
|
+
|
|
443
|
+
const colorError = 'var(--p-color-error)';
|
|
444
|
+
|
|
445
|
+
const colorErrorFrosted = 'var(--p-color-error-frosted)';
|
|
446
|
+
|
|
447
|
+
const colorErrorFrostedSoft = 'var(--p-color-error-frosted-soft)';
|
|
448
|
+
|
|
449
|
+
const colorInfo = 'var(--p-color-info)';
|
|
450
|
+
|
|
451
|
+
const colorInfoFrosted = 'var(--p-color-info-frosted)';
|
|
452
|
+
|
|
453
|
+
const colorInfoFrostedSoft = 'var(--p-color-info-frosted-soft)';
|
|
454
|
+
|
|
455
|
+
const colorSuccess = 'var(--p-color-success)';
|
|
456
|
+
|
|
457
|
+
const colorSuccessFrosted = 'var(--p-color-success-frosted)';
|
|
458
|
+
|
|
459
|
+
const colorSuccessFrostedSoft = 'var(--p-color-success-frosted-soft)';
|
|
460
|
+
|
|
461
|
+
const colorSuccessLow = 'var(--p-color-success-low)';
|
|
462
|
+
|
|
463
|
+
const colorWarning = 'var(--p-color-warning)';
|
|
464
|
+
|
|
465
|
+
const colorWarningFrosted = 'var(--p-color-warning-frosted)';
|
|
466
|
+
|
|
467
|
+
const colorWarningFrostedSoft = 'var(--p-color-warning-frosted-soft)';
|
|
357
468
|
|
|
358
469
|
const motionDurationMap = {
|
|
359
470
|
short: motionDurationShort,
|
|
@@ -388,10 +499,9 @@ const addImportantToEachRule = (input) => {
|
|
|
388
499
|
typeof value === 'object' ? addImportantToEachRule(value) : addImportantToRule(value)),
|
|
389
500
|
result), {});
|
|
390
501
|
};
|
|
391
|
-
const { focusColor } = colors;
|
|
392
502
|
const getFocusBaseStyles = () => {
|
|
393
503
|
return {
|
|
394
|
-
outline: `${borderWidthBase} solid ${
|
|
504
|
+
outline: `${borderWidthBase} solid ${colorFocus}`,
|
|
395
505
|
outlineOffset: '2px',
|
|
396
506
|
};
|
|
397
507
|
};
|
|
@@ -431,10 +541,6 @@ const getHiddenTextJssStyle = (isHidden = true, isShownJssStyle) => {
|
|
|
431
541
|
};
|
|
432
542
|
};
|
|
433
543
|
|
|
434
|
-
const colorSchemeStyles = {
|
|
435
|
-
colorScheme: 'light dark',
|
|
436
|
-
};
|
|
437
|
-
|
|
438
544
|
const hostHiddenStyles = {
|
|
439
545
|
'&([hidden])': {
|
|
440
546
|
display: 'none',
|
|
@@ -3776,7 +3882,7 @@ const OPTION_LIST_SAFE_ZONE = 6;
|
|
|
3776
3882
|
|
|
3777
3883
|
const getCDNBaseURL = () => global.PORSCHE_DESIGN_SYSTEM_CDN_URL + "/porsche-design-system";
|
|
3778
3884
|
|
|
3779
|
-
const prefix = `[Porsche Design System v${"4.0.0-
|
|
3885
|
+
const prefix = `[Porsche Design System v${"4.0.0-beta.0"}]` // this part isn't covered by unit tests
|
|
3780
3886
|
;
|
|
3781
3887
|
const consoleError = (...messages) => {
|
|
3782
3888
|
console.error(prefix, ...messages);
|
|
@@ -3885,31 +3991,8 @@ const breakpointCustomizableTemplate = `value, ${internalValidateProps
|
|
|
3885
3991
|
.formatObjectOutput(breakpoints.reduce((prev, key) => ({ ...prev, [key + (key !== 'base' ? '?' : '')]: 'value' }), {}))
|
|
3886
3992
|
.replace(/"/g, '')}`;
|
|
3887
3993
|
|
|
3888
|
-
const legacyRadiusLarge = '--_p-legacy-radius-large';
|
|
3889
|
-
|
|
3890
|
-
const legacyRadiusMedium = '--_p-legacy-radius-medium';
|
|
3891
|
-
|
|
3892
|
-
const legacyRadiusSmall = '--_p-legacy-radius-small';
|
|
3893
|
-
|
|
3894
|
-
const radius2Xl = 'var(--p-radius-2xl)';
|
|
3895
|
-
|
|
3896
|
-
const radius3Xl = 'var(--p-radius-3xl)';
|
|
3897
|
-
|
|
3898
|
-
const radius4Xl = 'var(--p-radius-4xl)';
|
|
3899
|
-
|
|
3900
|
-
const radiusFull = 'var(--p-radius-full)';
|
|
3901
|
-
|
|
3902
|
-
const radiusLg = 'var(--p-radius-lg)';
|
|
3903
|
-
|
|
3904
|
-
const radiusMd = 'var(--p-radius-md)';
|
|
3905
|
-
|
|
3906
|
-
const radiusSm = 'var(--p-radius-sm)';
|
|
3907
|
-
|
|
3908
|
-
const radiusXl = 'var(--p-radius-xl)';
|
|
3909
|
-
|
|
3910
3994
|
const cssVariablePositionStickyTop = '--p-accordion-position-sticky-top';
|
|
3911
3995
|
const positionStickyTopFallback = '0';
|
|
3912
|
-
const { contrastLowColor: contrastLowColor$8, primaryColor: primaryColor$B, frostedSoftColor: frostedSoftColor$6, canvasColor: canvasColor$a } = colors;
|
|
3913
3996
|
// CSS Variable defined in fontHyphenationStyle
|
|
3914
3997
|
/**
|
|
3915
3998
|
* @css-variable {"name": "--p-hyphens", "description": "Sets the CSS `hyphens` property for text elements, controlling whether words can break and hyphenate automatically.", "defaultValue": "auto"}
|
|
@@ -3923,10 +4006,9 @@ const getComponentCss$19 = (size, compact, open, sticky) => {
|
|
|
3923
4006
|
...(compact
|
|
3924
4007
|
? { transform: 'translate3d(0,0,0)' } // relevant for custom click-area in compact variant
|
|
3925
4008
|
: {
|
|
3926
|
-
borderBottom: `1px solid ${
|
|
4009
|
+
borderBottom: `1px solid ${colorContrastLower}`,
|
|
3927
4010
|
}),
|
|
3928
4011
|
'&(:only-of-type)': { borderBottom: 0 },
|
|
3929
|
-
...colorSchemeStyles,
|
|
3930
4012
|
...hostHiddenStyles,
|
|
3931
4013
|
}),
|
|
3932
4014
|
},
|
|
@@ -3941,7 +4023,7 @@ const getComponentCss$19 = (size, compact, open, sticky) => {
|
|
|
3941
4023
|
gap: '24px',
|
|
3942
4024
|
cursor: 'pointer',
|
|
3943
4025
|
zIndex: 0,
|
|
3944
|
-
color:
|
|
4026
|
+
color: colorPrimary,
|
|
3945
4027
|
...textSmallStyle,
|
|
3946
4028
|
fontWeight: fontWeightSemiBold,
|
|
3947
4029
|
...buildResponsiveStyles(size, (s) => ({
|
|
@@ -3972,7 +4054,7 @@ const getComponentCss$19 = (size, compact, open, sticky) => {
|
|
|
3972
4054
|
},
|
|
3973
4055
|
'&:hover::before': {
|
|
3974
4056
|
...frostedGlassStyle,
|
|
3975
|
-
background:
|
|
4057
|
+
background: colorFrostedSoft,
|
|
3976
4058
|
},
|
|
3977
4059
|
})),
|
|
3978
4060
|
'&:focus-visible::before': getFocusBaseStyles(),
|
|
@@ -3984,7 +4066,7 @@ const getComponentCss$19 = (size, compact, open, sticky) => {
|
|
|
3984
4066
|
position: 'sticky',
|
|
3985
4067
|
top: `var(${cssVariablePositionStickyTop}, ${positionStickyTopFallback})`,
|
|
3986
4068
|
zIndex: 1, // to be on top of the collapsible
|
|
3987
|
-
background:
|
|
4069
|
+
background: colorCanvas,
|
|
3988
4070
|
}),
|
|
3989
4071
|
},
|
|
3990
4072
|
'icon-container': {
|
|
@@ -4000,7 +4082,7 @@ const getComponentCss$19 = (size, compact, open, sticky) => {
|
|
|
4000
4082
|
transition: getTransition('transform'),
|
|
4001
4083
|
},
|
|
4002
4084
|
collapsible: {
|
|
4003
|
-
color:
|
|
4085
|
+
color: colorPrimary, // enables color inheritance for slotted content
|
|
4004
4086
|
display: 'grid',
|
|
4005
4087
|
...(sticky && {
|
|
4006
4088
|
position: 'relative',
|
|
@@ -4106,7 +4188,6 @@ const getComponentCss$18 = (isOpen) => {
|
|
|
4106
4188
|
[getMediaQueryMin('xxl')]: {
|
|
4107
4189
|
insetInline: gridExtendedOffsetXXL,
|
|
4108
4190
|
},
|
|
4109
|
-
...colorSchemeStyles,
|
|
4110
4191
|
...hostHiddenStyles,
|
|
4111
4192
|
}),
|
|
4112
4193
|
},
|
|
@@ -4144,7 +4225,6 @@ const getVisibilityJssStyle = (hideLabel) => {
|
|
|
4144
4225
|
};
|
|
4145
4226
|
const offsetVertical = '-2px';
|
|
4146
4227
|
const offsetHorizontal = '-4px';
|
|
4147
|
-
const { primaryColor: primaryColor$A, frostedColor: frostedColor$a } = colors;
|
|
4148
4228
|
const getLinkButtonPureStyles = (icon, iconSource, active, isDisabledOrLoading, stretch, size, hideLabel, alignLabel, underline, hasSlottedAnchor) => {
|
|
4149
4229
|
const hasIcon = hasVisibleIcon(icon, iconSource);
|
|
4150
4230
|
return {
|
|
@@ -4152,7 +4232,6 @@ const getLinkButtonPureStyles = (icon, iconSource, active, isDisabledOrLoading,
|
|
|
4152
4232
|
':host': {
|
|
4153
4233
|
...addImportantToEachRule({
|
|
4154
4234
|
transform: 'translate3d(0,0,0)', // creates new stacking context
|
|
4155
|
-
...colorSchemeStyles,
|
|
4156
4235
|
...hostHiddenStyles,
|
|
4157
4236
|
}),
|
|
4158
4237
|
...buildResponsiveStyles(stretch, (responsiveStretch) => ({
|
|
@@ -4168,7 +4247,7 @@ const getLinkButtonPureStyles = (icon, iconSource, active, isDisabledOrLoading,
|
|
|
4168
4247
|
display: 'flex',
|
|
4169
4248
|
width: '100%',
|
|
4170
4249
|
cursor: 'pointer',
|
|
4171
|
-
color:
|
|
4250
|
+
color: colorPrimary,
|
|
4172
4251
|
textDecoration: underline ? 'underline' : 'none',
|
|
4173
4252
|
...textSmallStyle,
|
|
4174
4253
|
...mergeDeep(buildResponsiveStyles(hideLabel, (hidelabelValue) => ({
|
|
@@ -4192,14 +4271,14 @@ const getLinkButtonPureStyles = (icon, iconSource, active, isDisabledOrLoading,
|
|
|
4192
4271
|
transition: getTransition('background-color'),
|
|
4193
4272
|
...(active && {
|
|
4194
4273
|
...frostedGlassStyle,
|
|
4195
|
-
backgroundColor:
|
|
4274
|
+
backgroundColor: colorFrosted,
|
|
4196
4275
|
}),
|
|
4197
4276
|
},
|
|
4198
4277
|
...(!isDisabledOrLoading &&
|
|
4199
4278
|
hoverMediaQuery({
|
|
4200
4279
|
'&:hover::before': {
|
|
4201
4280
|
...frostedGlassStyle,
|
|
4202
|
-
backgroundColor:
|
|
4281
|
+
backgroundColor: colorFrostedStrong,
|
|
4203
4282
|
},
|
|
4204
4283
|
})),
|
|
4205
4284
|
...(!hasSlottedAnchor && {
|
|
@@ -4249,7 +4328,7 @@ const getComponentCss$17 = (icon, iconSource, active, isDisabled, isLoading, isD
|
|
|
4249
4328
|
return getCss(mergeDeep(getLinkButtonPureStyles(icon, iconSource, active, isDisabledOrLoading, stretch, size, hideLabel, alignLabel, underline, false), {
|
|
4250
4329
|
root: {
|
|
4251
4330
|
...(isDisabled && {
|
|
4252
|
-
color:
|
|
4331
|
+
color: colorContrastLow,
|
|
4253
4332
|
}),
|
|
4254
4333
|
...(isDisabledOrLoading && {
|
|
4255
4334
|
cursor: 'not-allowed',
|
|
@@ -4286,7 +4365,6 @@ const getFontWeight = (weight) => {
|
|
|
4286
4365
|
/**
|
|
4287
4366
|
* @css-variable {"name": "--p-hyphens", "description": "Sets the CSS `hyphens` property for text elements, controlling whether words can break and hyphenate automatically.", "defaultValue": "auto"}
|
|
4288
4367
|
*/
|
|
4289
|
-
const { canvasColor: canvasColor$9, primaryColor: primaryColor$z } = colors;
|
|
4290
4368
|
const getComponentCss$16 = (isDisabledOrLoading, aspectRatio, size, weight, align, compact, hasGradient, hasFooterSlot, isDisabled) => {
|
|
4291
4369
|
const isTopAligned = align === 'top';
|
|
4292
4370
|
return getCss({
|
|
@@ -4294,13 +4372,13 @@ const getComponentCss$16 = (isDisabledOrLoading, aspectRatio, size, weight, alig
|
|
|
4294
4372
|
':host': {
|
|
4295
4373
|
display: 'flex',
|
|
4296
4374
|
alignItems: 'stretch',
|
|
4375
|
+
colorScheme: 'dark', // dark is used in 99% of the cases (it can still be overridden by the user via `color-scheme`)
|
|
4297
4376
|
// Safari workaround to scale the tile properly
|
|
4298
4377
|
'@supports (-webkit-hyphens: auto)': {
|
|
4299
4378
|
alignItems: 'baseline',
|
|
4300
4379
|
},
|
|
4301
4380
|
hyphens: 'auto', // TODO: shouldn't we expose a CSS variable instead?
|
|
4302
4381
|
...addImportantToEachRule({
|
|
4303
|
-
...colorSchemeStyles,
|
|
4304
4382
|
...hostHiddenStyles,
|
|
4305
4383
|
}),
|
|
4306
4384
|
},
|
|
@@ -4339,7 +4417,7 @@ const getComponentCss$16 = (isDisabledOrLoading, aspectRatio, size, weight, alig
|
|
|
4339
4417
|
zIndex: 3,
|
|
4340
4418
|
maxWidth: '34.375rem',
|
|
4341
4419
|
...textMediumStyle,
|
|
4342
|
-
color:
|
|
4420
|
+
color: colorPrimary,
|
|
4343
4421
|
hyphens: 'inherit',
|
|
4344
4422
|
...mergeDeep(buildResponsiveStyles(size, (sizeValue) => ({
|
|
4345
4423
|
fontSize: getFontSizeText(sizeValue),
|
|
@@ -4368,14 +4446,14 @@ const getComponentCss$16 = (isDisabledOrLoading, aspectRatio, size, weight, alig
|
|
|
4368
4446
|
...(isTopAligned
|
|
4369
4447
|
? {
|
|
4370
4448
|
gridArea: '1/1/3/-1',
|
|
4371
|
-
background: gradientToBottomStyle.background.replaceAll('0,0%,0%,', `from ${
|
|
4449
|
+
background: gradientToBottomStyle.background.replaceAll('0,0%,0%,', `from ${colorCanvas} h s l / `),
|
|
4372
4450
|
marginBottom: `calc(${spacingFluidLarge} * -1)`, // to increase the gradient area without reserving additional layout space
|
|
4373
4451
|
borderStartStartRadius: 'inherit',
|
|
4374
4452
|
borderStartEndRadius: 'inherit',
|
|
4375
4453
|
}
|
|
4376
4454
|
: {
|
|
4377
4455
|
gridArea: '4/1/6/-1',
|
|
4378
|
-
background: gradientToTopStyle.background.replaceAll('0,0%,0%,', `from ${
|
|
4456
|
+
background: gradientToTopStyle.background.replaceAll('0,0%,0%,', `from ${colorCanvas} h s l / `),
|
|
4379
4457
|
marginTop: `calc(${spacingFluidLarge} * -1)`, // to increase the gradient area without reserving additional layout space
|
|
4380
4458
|
borderEndStartRadius: 'inherit',
|
|
4381
4459
|
borderEndEndRadius: 'inherit',
|
|
@@ -4413,8 +4491,8 @@ const getComponentCss$16 = (isDisabledOrLoading, aspectRatio, size, weight, alig
|
|
|
4413
4491
|
'link-or-button-pure': {
|
|
4414
4492
|
zIndex: 5,
|
|
4415
4493
|
gridColumn: 2,
|
|
4416
|
-
gridRow: hasFooterSlot
|
|
4417
|
-
alignSelf: '
|
|
4494
|
+
gridRow: `1/${hasFooterSlot ? 3 : 2}`,
|
|
4495
|
+
alignSelf: isTopAligned ? 'flex-start' : 'flex-end',
|
|
4418
4496
|
...buildResponsiveStyles(compact, (compactValue) => ({
|
|
4419
4497
|
display: compactValue ? 'inline-block' : 'none',
|
|
4420
4498
|
})),
|
|
@@ -4430,18 +4508,17 @@ const getComponentCss$16 = (isDisabledOrLoading, aspectRatio, size, weight, alig
|
|
|
4430
4508
|
});
|
|
4431
4509
|
};
|
|
4432
4510
|
|
|
4433
|
-
const { primaryColor: primaryColor$y, canvasColor: canvasColor$8, contrastHighColor: contrastHighColor$9, frostedColor: frostedColor$9, frostedSoftColor: frostedSoftColor$5 } = colors;
|
|
4434
4511
|
const getVariantColors = (variant) => {
|
|
4435
4512
|
const colors = {
|
|
4436
4513
|
primary: {
|
|
4437
|
-
textColor:
|
|
4438
|
-
backgroundColor:
|
|
4439
|
-
backgroundColorHover:
|
|
4514
|
+
textColor: colorCanvas,
|
|
4515
|
+
backgroundColor: colorPrimary,
|
|
4516
|
+
backgroundColorHover: colorContrastHigh,
|
|
4440
4517
|
},
|
|
4441
4518
|
secondary: {
|
|
4442
|
-
textColor:
|
|
4443
|
-
backgroundColor:
|
|
4444
|
-
backgroundColorHover:
|
|
4519
|
+
textColor: colorPrimary,
|
|
4520
|
+
backgroundColor: colorFrostedStrong,
|
|
4521
|
+
backgroundColorHover: colorFrosted,
|
|
4445
4522
|
},
|
|
4446
4523
|
};
|
|
4447
4524
|
return colors[variant];
|
|
@@ -4467,7 +4544,6 @@ const getLinkButtonStyles = (icon, iconSource, variant, hideLabel, isDisabledOrL
|
|
|
4467
4544
|
}),
|
|
4468
4545
|
}))),
|
|
4469
4546
|
...addImportantToEachRule({
|
|
4470
|
-
...colorSchemeStyles,
|
|
4471
4547
|
...hostHiddenStyles,
|
|
4472
4548
|
}),
|
|
4473
4549
|
},
|
|
@@ -4516,7 +4592,6 @@ const getLinkButtonStyles = (icon, iconSource, variant, hideLabel, isDisabledOrL
|
|
|
4516
4592
|
};
|
|
4517
4593
|
|
|
4518
4594
|
const cssVariableInternalButtonScaling = '--p-internal-button-scaling';
|
|
4519
|
-
const { frostedSoftColor: frostedSoftColor$4, contrastLowColor: contrastLowColor$7 } = colors;
|
|
4520
4595
|
// CSS Variable defined in fontHyphenationStyle
|
|
4521
4596
|
/**
|
|
4522
4597
|
* @css-variable {"name": "--p-hyphens", "description": "Sets the CSS `hyphens` property for text elements, controlling whether words can break and hyphenate automatically.", "defaultValue": "auto"}
|
|
@@ -4527,9 +4602,9 @@ const getComponentCss$15 = (icon, iconSource, variant, hideLabel, isDisabled, is
|
|
|
4527
4602
|
root: {
|
|
4528
4603
|
...(disabledOrLoading && {
|
|
4529
4604
|
cursor: 'not-allowed',
|
|
4530
|
-
backgroundColor:
|
|
4531
|
-
borderColor:
|
|
4532
|
-
color:
|
|
4605
|
+
backgroundColor: colorFrostedSoft,
|
|
4606
|
+
borderColor: colorFrostedSoft,
|
|
4607
|
+
color: colorContrastLow,
|
|
4533
4608
|
}),
|
|
4534
4609
|
},
|
|
4535
4610
|
...(isLoading && {
|
|
@@ -4560,126 +4635,143 @@ const getComponentCss$15 = (icon, iconSource, variant, hideLabel, isDisabled, is
|
|
|
4560
4635
|
}));
|
|
4561
4636
|
};
|
|
4562
4637
|
|
|
4563
|
-
|
|
4564
|
-
|
|
4565
|
-
|
|
4638
|
+
const palette = {
|
|
4639
|
+
dark: {
|
|
4640
|
+
grey: {
|
|
4641
|
+
'950': 'hsl(225, 100%, 99%)',
|
|
4642
|
+
'100a': 'hsla(240, 3.7%, 26.5%, 0.154)',
|
|
4643
|
+
'200a': 'hsla(240, 2%, 43%, 0.228)'},
|
|
4644
|
+
},
|
|
4645
|
+
};
|
|
4646
|
+
|
|
4647
|
+
const colorFrostedDark = palette.dark.grey['200a'];
|
|
4648
|
+
|
|
4649
|
+
const colorFrostedSoftDark = palette.dark.grey['100a'];
|
|
4650
|
+
|
|
4651
|
+
const colorPrimaryDark = palette.dark.grey["950"];
|
|
4652
|
+
|
|
4653
|
+
const typescaleXs = 'clamp(0.81rem, 0.23vw + 0.77rem, 0.88rem)';
|
|
4654
|
+
|
|
4655
|
+
const spacingStaticSm = '8px';
|
|
4656
|
+
|
|
4657
|
+
const spacingStaticXs = '4px';
|
|
4658
|
+
|
|
4659
|
+
/**
|
|
4660
|
+
* @css-variable {"name": "--p-canvas-sidebar-start-width", "description": "Width of the sidebar start.", "defaultValue": "320px"}
|
|
4661
|
+
*/
|
|
4566
4662
|
const cssVarSidebarStartWidth = '--p-canvas-sidebar-start-width';
|
|
4663
|
+
/**
|
|
4664
|
+
* @css-variable {"name": "--p-canvas-sidebar-end-width", "description": "Width of the sidebar end.", "defaultValue": "320px"}
|
|
4665
|
+
*/
|
|
4567
4666
|
const cssVarSidebarEndWidth = '--p-canvas-sidebar-end-width';
|
|
4667
|
+
// public css classes
|
|
4668
|
+
const cssClassGrid = '-p-canvas-grid';
|
|
4568
4669
|
// default values for public css variables
|
|
4569
|
-
const
|
|
4570
|
-
const
|
|
4571
|
-
|
|
4572
|
-
const
|
|
4573
|
-
const
|
|
4670
|
+
const minWidth = '320px';
|
|
4671
|
+
const sidebarStartWidthMobile = `min(100vw,var(${cssVarSidebarStartWidth},${minWidth}))`;
|
|
4672
|
+
const sidebarEndWidthMobile = `min(100vw,var(${cssVarSidebarEndWidth},${minWidth}))`;
|
|
4673
|
+
const sidebarStartWidthDesktop = `min(calc(100vw - ${minWidth}),var(${cssVarSidebarStartWidth},${minWidth}))`;
|
|
4674
|
+
const sidebarEndWidthDesktop = `min(calc(100vw - ${minWidth}),var(${cssVarSidebarEndWidth},${minWidth}))`;
|
|
4574
4675
|
// media queries
|
|
4575
|
-
const
|
|
4576
|
-
const
|
|
4676
|
+
const mediaQueryMinM = getMediaQueryMin('m');
|
|
4677
|
+
const mediaQueryMaxM = getMediaQueryMax('m');
|
|
4577
4678
|
// others
|
|
4578
4679
|
const spacingBase = gridGap.replace('36px', '24px');
|
|
4579
|
-
const
|
|
4580
|
-
const
|
|
4680
|
+
const getComponentCss$14 = (isSidebarStartOpen, isSidebarEndOpen, background) => {
|
|
4681
|
+
const isBackgroundSurface = background === 'surface';
|
|
4682
|
+
const primaryBackgroundColor = isBackgroundSurface ? colorSurface : colorCanvas;
|
|
4683
|
+
const secondaryBackgroundColor = isBackgroundSurface ? colorCanvas : colorSurface;
|
|
4581
4684
|
return getCss({
|
|
4582
4685
|
'@global': {
|
|
4583
4686
|
':host': {
|
|
4584
4687
|
display: 'block',
|
|
4585
4688
|
...addImportantToEachRule({
|
|
4586
|
-
|
|
4689
|
+
// prevents horizontal scroll due to sidebar transform. `overflow: clip` clips content like hidden but doesn't
|
|
4690
|
+
// establish a scrolling context, so sticky positioning still works.
|
|
4691
|
+
overflowX: 'clip',
|
|
4587
4692
|
...hostHiddenStyles,
|
|
4588
4693
|
}),
|
|
4589
4694
|
},
|
|
4590
4695
|
...preventFoucOfNestedElementsStyles,
|
|
4591
4696
|
slot: {
|
|
4592
4697
|
'&:not([name]),&[name="footer"]': {
|
|
4593
|
-
[`&::slotted(.${cssClassGrid})`]: {
|
|
4698
|
+
[`&::slotted(.${cssClassGrid})`]: addImportantToEachRule({
|
|
4594
4699
|
display: 'grid',
|
|
4595
4700
|
gridTemplateColumns: 'repeat(12,minmax(0,1fr))',
|
|
4596
4701
|
columnGap: spacingBase,
|
|
4597
4702
|
marginInline: 'auto',
|
|
4598
4703
|
containerType: 'inline-size',
|
|
4599
|
-
},
|
|
4600
|
-
},
|
|
4601
|
-
'&[name="title"]::slotted': {
|
|
4602
|
-
'&(a)': {
|
|
4603
|
-
textDecoration: 'none',
|
|
4604
|
-
color: 'inherit',
|
|
4605
|
-
borderRadius: `var(${legacyRadiusSmall}, ${radiusSm})`,
|
|
4606
|
-
},
|
|
4607
|
-
'&(a:focus-visible)': getFocusBaseStyles(),
|
|
4704
|
+
}),
|
|
4608
4705
|
},
|
|
4609
4706
|
'&[name="sidebar-end-header"]': {
|
|
4610
4707
|
display: 'block', // ensures header section of sidebar-end area is aligned correctly
|
|
4611
4708
|
},
|
|
4612
4709
|
'&[name="background"]': {
|
|
4613
|
-
zIndex:
|
|
4710
|
+
zIndex: 1,
|
|
4614
4711
|
display: 'block',
|
|
4615
|
-
gridArea: '1/
|
|
4712
|
+
gridArea: '1/2/-1/3',
|
|
4616
4713
|
position: 'sticky',
|
|
4617
4714
|
top: 0,
|
|
4618
|
-
height: '
|
|
4715
|
+
height: '100lvh', // viewport when Safari's UI is completely hidden (maximum space)
|
|
4619
4716
|
pointerEvents: 'none',
|
|
4620
4717
|
overflow: 'hidden',
|
|
4621
4718
|
transform: 'translate3d(0,0,0)', // needed for Safari to force GPU acceleration
|
|
4622
|
-
|
|
4623
|
-
gridColumn: '2/3',
|
|
4624
|
-
},
|
|
4625
|
-
'&::slotted(video),&::slotted(img)': {
|
|
4719
|
+
'&::slotted(video),&::slotted(img)': addImportantToEachRule({
|
|
4626
4720
|
width: '100%',
|
|
4627
4721
|
height: '100%',
|
|
4628
4722
|
objectFit: 'cover',
|
|
4629
|
-
|
|
4630
|
-
pointerEvents: 'none',
|
|
4631
|
-
},
|
|
4723
|
+
}),
|
|
4632
4724
|
},
|
|
4725
|
+
'&[name="title"]::slotted': addImportantToEachRule({
|
|
4726
|
+
'&(a)': {
|
|
4727
|
+
all: 'unset',
|
|
4728
|
+
cursor: 'pointer',
|
|
4729
|
+
color: 'inherit',
|
|
4730
|
+
borderRadius: `var(${legacyRadiusSmall}, ${radiusSm})`,
|
|
4731
|
+
},
|
|
4732
|
+
'&(a:focus-visible)': getFocusBaseStyles(),
|
|
4733
|
+
}),
|
|
4633
4734
|
},
|
|
4634
4735
|
h2: {
|
|
4736
|
+
all: 'unset',
|
|
4737
|
+
padding: spacingStaticXs, // preserve enough spacing for focus state
|
|
4635
4738
|
font: textXSmallStyle.font,
|
|
4739
|
+
color: colorPrimary,
|
|
4636
4740
|
textOverflow: 'ellipsis',
|
|
4637
4741
|
overflow: 'hidden',
|
|
4638
4742
|
whiteSpace: 'nowrap',
|
|
4639
|
-
margin: 0,
|
|
4640
|
-
padding: '4px', // preserve enough spacing for focus state
|
|
4641
4743
|
textTransform: 'uppercase',
|
|
4642
4744
|
letterSpacing: '2px',
|
|
4643
4745
|
},
|
|
4644
4746
|
},
|
|
4645
4747
|
root: {
|
|
4646
|
-
[cssVarTemplateSidebarStartWidth]: isSidebarStartOpen ? sidebarStartWidth : '0px',
|
|
4647
|
-
[cssVarTemplateSidebarEndWidth]: isSidebarEndOpen ? sidebarEndWidth : '0px',
|
|
4648
4748
|
display: 'grid',
|
|
4649
|
-
|
|
4650
|
-
gridTemplateAreas: '"header" "main" "footer"',
|
|
4651
|
-
|
|
4652
|
-
|
|
4653
|
-
|
|
4654
|
-
|
|
4655
|
-
|
|
4656
|
-
|
|
4657
|
-
[mediaQueryS$1]: {
|
|
4658
|
-
gridTemplateColumns: `var(${cssVarTemplateSidebarStartWidth}) minmax(0,1fr)`,
|
|
4659
|
-
gridTemplateAreas: '"sidebar-start header" "sidebar-start main" "sidebar-start footer"',
|
|
4660
|
-
},
|
|
4661
|
-
[mediaQueryM]: {
|
|
4662
|
-
gridTemplateColumns: `var(${cssVarTemplateSidebarStartWidth}) minmax(0,1fr) var(${cssVarTemplateSidebarEndWidth})`,
|
|
4663
|
-
gridTemplateAreas: '"sidebar-start header sidebar-end" "sidebar-start main sidebar-end" "sidebar-start footer sidebar-end"',
|
|
4664
|
-
},
|
|
4665
|
-
'&::after': {
|
|
4666
|
-
[mediaQueryM]: {
|
|
4667
|
-
content: '""',
|
|
4668
|
-
zIndex: 2,
|
|
4669
|
-
gridArea: '1/2/-1/3',
|
|
4670
|
-
boxShadow: `1px 0 0 0 ${contrastLowerColor$3}`,
|
|
4671
|
-
background: canvasColor$7,
|
|
4672
|
-
pointerEvents: 'none',
|
|
4749
|
+
gridTemplate: `auto minmax(0,1fr) auto / ${sidebarStartWidthMobile} 100vw ${sidebarEndWidthMobile}`,
|
|
4750
|
+
gridTemplateAreas: '"sidebar-start header sidebar-end" "sidebar-start main sidebar-end" "sidebar-start footer sidebar-end"',
|
|
4751
|
+
minHeight: '100lvh', // viewport when Safari's UI is completely hidden (maximum space)
|
|
4752
|
+
[mediaQueryMaxM]: {
|
|
4753
|
+
transition: getTransition('transform'),
|
|
4754
|
+
transform: `translate3d(${isSidebarEndOpen ? `calc(-1 * ${sidebarStartWidthMobile} - ${sidebarEndWidthMobile})` : isSidebarStartOpen ? '0' : `calc(-1 * ${sidebarStartWidthMobile})`},0,0)`,
|
|
4755
|
+
'&:dir(rtl)': {
|
|
4756
|
+
transform: `translate3d(${isSidebarEndOpen ? `calc(${sidebarStartWidthMobile} + ${sidebarEndWidthMobile})` : isSidebarStartOpen ? '0' : sidebarEndWidthMobile},0,0)`,
|
|
4673
4757
|
},
|
|
4674
4758
|
},
|
|
4675
|
-
|
|
4676
|
-
|
|
4677
|
-
|
|
4678
|
-
|
|
4759
|
+
[mediaQueryMinM]: {
|
|
4760
|
+
transition: getTransition('grid-template-columns'),
|
|
4761
|
+
gridTemplateColumns: `${isSidebarStartOpen ? sidebarStartWidthDesktop : '0px'} minmax(${minWidth},1fr) ${isSidebarEndOpen ? sidebarEndWidthDesktop : '0px'}`,
|
|
4762
|
+
},
|
|
4763
|
+
'&::before': {
|
|
4764
|
+
content: '""',
|
|
4765
|
+
zIndex: 0,
|
|
4766
|
+
gridArea: '1/2/-1/3',
|
|
4767
|
+
background: primaryBackgroundColor,
|
|
4768
|
+
pointerEvents: 'none',
|
|
4769
|
+
borderEndStartRadius: isSidebarStartOpen ? radius3Xl : 0,
|
|
4770
|
+
transition: getTransition('border-radius'),
|
|
4679
4771
|
},
|
|
4680
4772
|
},
|
|
4681
4773
|
header: {
|
|
4682
|
-
zIndex:
|
|
4774
|
+
zIndex: 4,
|
|
4683
4775
|
gridArea: 'header',
|
|
4684
4776
|
containerType: 'inline-size',
|
|
4685
4777
|
position: 'sticky',
|
|
@@ -4690,8 +4782,10 @@ const getComponentCss$14 = (isSidebarStartOpen, isSidebarEndOpen) => {
|
|
|
4690
4782
|
gridTemplateColumns: 'minmax(0,1fr) auto minmax(0,1fr)',
|
|
4691
4783
|
gap: spacingBase,
|
|
4692
4784
|
alignItems: 'center',
|
|
4693
|
-
|
|
4694
|
-
|
|
4785
|
+
padding: `${spacingStaticSmall} ${spacingBase}`,
|
|
4786
|
+
'&:focus-visible': {
|
|
4787
|
+
outline: 'none',
|
|
4788
|
+
},
|
|
4695
4789
|
'&__area': {
|
|
4696
4790
|
display: 'flex',
|
|
4697
4791
|
gap: spacingStaticSmall,
|
|
@@ -4714,9 +4808,6 @@ const getComponentCss$14 = (isSidebarStartOpen, isSidebarEndOpen) => {
|
|
|
4714
4808
|
display: 'none',
|
|
4715
4809
|
},
|
|
4716
4810
|
},
|
|
4717
|
-
'&:focus': {
|
|
4718
|
-
outline: 'none',
|
|
4719
|
-
},
|
|
4720
4811
|
},
|
|
4721
4812
|
blur: {
|
|
4722
4813
|
zIndex: -1,
|
|
@@ -4728,64 +4819,67 @@ const getComponentCss$14 = (isSidebarStartOpen, isSidebarEndOpen) => {
|
|
|
4728
4819
|
inset: 0,
|
|
4729
4820
|
},
|
|
4730
4821
|
'& > div:nth-of-type(1)': {
|
|
4731
|
-
zIndex: 1,
|
|
4732
4822
|
WebkitBackdropFilter: 'blur(64px)',
|
|
4733
4823
|
backdropFilter: 'blur(64px)',
|
|
4734
4824
|
WebkitMaskImage: 'linear-gradient(to bottom,rgba(0,0,0,100%) 0%,rgba(0,0,0,1) 12.5%,rgba(0,0,0,1) 25%,rgba(0,0,0,0) 37.5%)',
|
|
4735
4825
|
maskImage: 'linear-gradient(to bottom,rgba(0,0,0,100%) 0%,rgba(0,0,0,1) 12.5%,rgba(0,0,0,1) 25%,rgba(0,0,0,0) 37.5%)',
|
|
4736
4826
|
},
|
|
4737
4827
|
'& > div:nth-of-type(2)': {
|
|
4738
|
-
zIndex: 2,
|
|
4739
4828
|
WebkitBackdropFilter: 'blur(32px)',
|
|
4740
4829
|
backdropFilter: 'blur(32px)',
|
|
4741
4830
|
WebkitMaskImage: 'linear-gradient(to bottom,rgba(0,0,0,0) 12.5%,rgba(0,0,0,1) 25%,rgba(0,0,0,1) 37.5%,rgba(0,0,0,0) 50%)',
|
|
4742
4831
|
maskImage: 'linear-gradient(to bottom,rgba(0,0,0,0) 12.5%,rgba(0,0,0,1) 25%,rgba(0,0,0,1) 37.5%,rgba(0,0,0,0) 50%)',
|
|
4743
4832
|
},
|
|
4744
4833
|
'& > div:nth-of-type(3)': {
|
|
4745
|
-
zIndex: 3,
|
|
4746
4834
|
WebkitBackdropFilter: 'blur(16px)',
|
|
4747
4835
|
backdropFilter: 'blur(16px)',
|
|
4748
4836
|
WebkitMaskImage: 'linear-gradient(to bottom,rgba(0,0,0,0) 25%,rgba(0,0,0,1) 37.5%,rgba(0,0,0,1) 50%,rgba(0,0,0,0) 62.5%)',
|
|
4749
4837
|
maskImage: 'linear-gradient(to bottom,rgba(0,0,0,0) 25%,rgba(0,0,0,1) 37.5%,rgba(0,0,0,1) 50%,rgba(0,0,0,0) 62.5%)',
|
|
4750
4838
|
},
|
|
4751
4839
|
'& > div:nth-of-type(4)': {
|
|
4752
|
-
zIndex: 4,
|
|
4753
4840
|
WebkitBackdropFilter: 'blur(8px)',
|
|
4754
4841
|
backdropFilter: 'blur(8px)',
|
|
4755
4842
|
WebkitMaskImage: 'linear-gradient(to bottom,rgba(0,0,0,0) 37.5%,rgba(0,0,0,1) 50%,rgba(0,0,0,1) 62.5%,rgba(0,0,0,0) 75%)',
|
|
4756
4843
|
maskImage: 'linear-gradient(to bottom,rgba(0,0,0,0) 37.5%,rgba(0,0,0,1) 50%,rgba(0,0,0,1) 62.5%,rgba(0,0,0,0) 75%)',
|
|
4757
4844
|
},
|
|
4758
4845
|
'& > div:nth-of-type(5)': {
|
|
4759
|
-
zIndex: 5,
|
|
4760
4846
|
WebkitBackdropFilter: 'blur(4px)',
|
|
4761
4847
|
backdropFilter: 'blur(4px)',
|
|
4762
4848
|
WebkitMaskImage: 'linear-gradient(to bottom,rgba(0,0,0,0) 50%,rgba(0,0,0,1) 62.5%,rgba(0,0,0,1) 75%,rgba(0,0,0,0) 87.5%)',
|
|
4763
4849
|
maskImage: 'linear-gradient(to bottom,rgba(0,0,0,0) 50%,rgba(0,0,0,1) 62.5%,rgba(0,0,0,1) 75%,rgba(0,0,0,0) 87.5%)',
|
|
4764
4850
|
},
|
|
4765
4851
|
'& > div:nth-of-type(6)': {
|
|
4766
|
-
zIndex: 6,
|
|
4767
4852
|
WebkitBackdropFilter: 'blur(2px)',
|
|
4768
4853
|
backdropFilter: 'blur(2px)',
|
|
4769
4854
|
WebkitMaskImage: 'linear-gradient(to bottom,rgba(0,0,0,0) 62.5%,rgba(0,0,0,1) 75%,rgba(0,0,0,1) 87.5%,rgba(0,0,0,0) 100%)',
|
|
4770
4855
|
maskImage: 'linear-gradient(to bottom,rgba(0,0,0,0) 62.5%,rgba(0,0,0,1) 75%,rgba(0,0,0,1) 87.5%,rgba(0,0,0,0) 100%)',
|
|
4771
4856
|
},
|
|
4772
4857
|
'& > div:nth-of-type(7)': {
|
|
4773
|
-
zIndex: 7,
|
|
4774
4858
|
WebkitBackdropFilter: 'blur(1px)',
|
|
4775
4859
|
backdropFilter: 'blur(1px)',
|
|
4776
4860
|
WebkitMaskImage: 'linear-gradient(to bottom,rgba(0,0,0,0) 75%,rgba(0,0,0,1) 87.5%,rgba(0,0,0,1) 100%)',
|
|
4777
4861
|
maskImage: 'linear-gradient(to bottom,rgba(0,0,0,0) 75%,rgba(0,0,0,1) 87.5%,rgba(0,0,0,1) 100%)',
|
|
4778
4862
|
},
|
|
4779
4863
|
'& > div:nth-of-type(8)': {
|
|
4780
|
-
zIndex: 8,
|
|
4781
4864
|
WebkitBackdropFilter: 'blur(.5px)',
|
|
4782
4865
|
backdropFilter: 'blur(.5px)',
|
|
4783
4866
|
WebkitMaskImage: 'linear-gradient(to bottom,rgba(0,0,0,0) 87.5%,rgba(0,0,0,1) 100%)',
|
|
4784
4867
|
maskImage: 'linear-gradient(to bottom,rgba(0,0,0,0) 87.5%,rgba(0,0,0,1) 100%)',
|
|
4785
4868
|
},
|
|
4869
|
+
'&::after': {
|
|
4870
|
+
content: '""',
|
|
4871
|
+
position: 'absolute',
|
|
4872
|
+
top: 0,
|
|
4873
|
+
insetInlineStart: 0,
|
|
4874
|
+
width: radius3Xl,
|
|
4875
|
+
height: `calc(2 * ${radius3Xl})`,
|
|
4876
|
+
borderStartStartRadius: isSidebarStartOpen ? radius3Xl : 0,
|
|
4877
|
+
boxShadow: `0 calc(-1 * ${radius3Xl}) 0 0 ${secondaryBackgroundColor}`,
|
|
4878
|
+
transition: getTransition('border-radius'),
|
|
4879
|
+
},
|
|
4786
4880
|
},
|
|
4787
4881
|
main: {
|
|
4788
|
-
zIndex:
|
|
4882
|
+
zIndex: 3,
|
|
4789
4883
|
gridArea: 'main',
|
|
4790
4884
|
padding: spacingBase,
|
|
4791
4885
|
},
|
|
@@ -4801,67 +4895,63 @@ const getComponentCss$14 = (isSidebarStartOpen, isSidebarEndOpen) => {
|
|
|
4801
4895
|
position: 'absolute',
|
|
4802
4896
|
inset: '-140px 0 0',
|
|
4803
4897
|
pointerEvents: 'none',
|
|
4804
|
-
background: `linear-gradient(to bottom,hsl(from ${
|
|
4898
|
+
background: `linear-gradient(to bottom,hsl(from ${primaryBackgroundColor} h s l / 0) 0%,hsl(from ${primaryBackgroundColor} h s l / 0.013) 8.1%,hsl(from ${primaryBackgroundColor} h s l / 0.049) 15.5%,hsl(from ${primaryBackgroundColor} h s l / 0.104) 22.5%,hsl(from ${primaryBackgroundColor} h s l / 0.175) 29%,hsl(from ${primaryBackgroundColor} h s l / 0.259) 35.3%,hsl(from ${primaryBackgroundColor} h s l / 0.352) 41.2%,hsl(from ${primaryBackgroundColor} h s l / 0.45) 47.1%,hsl(from ${primaryBackgroundColor} h s l / 0.55) 52.9%,hsl(from ${primaryBackgroundColor} h s l / 0.648) 58.8%,hsl(from ${primaryBackgroundColor} h s l / 0.741) 64.7%,hsl(from ${primaryBackgroundColor} h s l / 0.825) 71%,hsl(from ${primaryBackgroundColor} h s l / 0.896) 77.5%,hsl(from ${primaryBackgroundColor} h s l / 0.951) 84.5%,hsl(from ${primaryBackgroundColor} h s l / 0.987) 91.9%,${primaryBackgroundColor} 100%)`,
|
|
4899
|
+
borderEndStartRadius: isSidebarStartOpen ? radius3Xl : 0,
|
|
4900
|
+
transition: getTransition('border-radius'),
|
|
4805
4901
|
},
|
|
4806
4902
|
},
|
|
4807
4903
|
sidebar: {
|
|
4904
|
+
zIndex: 2,
|
|
4808
4905
|
position: 'sticky',
|
|
4809
4906
|
top: 0,
|
|
4810
|
-
height: '100dvh',
|
|
4907
|
+
height: '100dvh', // transitions between svh (viewport when Safari's address bar and bottom bar are visible (~60-90px less)) and lvh (viewport when Safari's UI is completely hidden (maximum space)) as you scroll (causes reflows)
|
|
4908
|
+
padding: spacingBase,
|
|
4909
|
+
boxSizing: 'border-box',
|
|
4910
|
+
overflow: 'hidden auto',
|
|
4911
|
+
overscrollBehaviorY: 'contain',
|
|
4912
|
+
'&:focus-visible': {
|
|
4913
|
+
outline: 'none',
|
|
4914
|
+
},
|
|
4811
4915
|
'&--start': {
|
|
4812
|
-
zIndex: 7,
|
|
4813
4916
|
gridArea: 'sidebar-start',
|
|
4814
4917
|
justifySelf: 'flex-end',
|
|
4815
|
-
|
|
4816
|
-
|
|
4817
|
-
|
|
4818
|
-
|
|
4819
|
-
zIndex: -1,
|
|
4820
|
-
position: 'absolute',
|
|
4821
|
-
canvasColor: 'transparent',
|
|
4822
|
-
right: '-16px',
|
|
4823
|
-
height: '32px',
|
|
4824
|
-
width: '16px',
|
|
4825
|
-
pointerEvents: 'none',
|
|
4826
|
-
top: 0,
|
|
4827
|
-
borderTopLeftRadius: '16px',
|
|
4828
|
-
boxShadow: `0 -16px 0 0 ${surfaceColor$3}`,
|
|
4918
|
+
background: secondaryBackgroundColor,
|
|
4919
|
+
width: sidebarStartWidthMobile,
|
|
4920
|
+
[mediaQueryMinM]: {
|
|
4921
|
+
width: sidebarStartWidthDesktop,
|
|
4829
4922
|
},
|
|
4830
4923
|
},
|
|
4831
4924
|
'&--end': {
|
|
4832
|
-
zIndex: 1,
|
|
4833
4925
|
gridArea: 'sidebar-end',
|
|
4834
|
-
justifySelf: 'flex-
|
|
4835
|
-
|
|
4836
|
-
background:
|
|
4837
|
-
|
|
4838
|
-
|
|
4839
|
-
|
|
4840
|
-
|
|
4841
|
-
overflow: 'hidden auto',
|
|
4842
|
-
overscrollBehaviorY: 'contain',
|
|
4843
|
-
background: 'inherit', // ensures correct scrollbar coloring in light / dark mode
|
|
4926
|
+
justifySelf: 'flex-start',
|
|
4927
|
+
borderInlineStart: `1px solid ${colorContrastLower}`,
|
|
4928
|
+
background: primaryBackgroundColor,
|
|
4929
|
+
width: sidebarEndWidthMobile,
|
|
4930
|
+
[mediaQueryMinM]: {
|
|
4931
|
+
width: sidebarEndWidthDesktop,
|
|
4932
|
+
},
|
|
4844
4933
|
},
|
|
4845
4934
|
'&__header': {
|
|
4846
|
-
zIndex:
|
|
4935
|
+
zIndex: 9999999,
|
|
4847
4936
|
display: 'flex',
|
|
4848
4937
|
gap: spacingStaticSmall,
|
|
4849
4938
|
alignItems: 'center',
|
|
4850
4939
|
position: 'sticky',
|
|
4851
|
-
top:
|
|
4940
|
+
top: `calc(-1 * ${spacingBase})`,
|
|
4941
|
+
margin: `calc(-1 * ${spacingBase}) calc(-1 * ${spacingBase}) ${spacingBase}`,
|
|
4852
4942
|
padding: `${spacingStaticSmall} ${spacingBase}`,
|
|
4853
4943
|
minHeight: '56px',
|
|
4854
4944
|
boxSizing: 'border-box',
|
|
4855
4945
|
'&--start': {
|
|
4856
4946
|
justifyContent: 'flex-start',
|
|
4857
4947
|
'&::before': {
|
|
4858
|
-
background: `linear-gradient(180deg,${
|
|
4948
|
+
background: `linear-gradient(180deg,${secondaryBackgroundColor} 0%,${secondaryBackgroundColor} 65%,transparent 100%)`,
|
|
4859
4949
|
},
|
|
4860
4950
|
},
|
|
4861
4951
|
'&--end': {
|
|
4862
4952
|
justifyContent: 'space-between',
|
|
4863
4953
|
'&::before': {
|
|
4864
|
-
background: `linear-gradient(180deg,${
|
|
4954
|
+
background: `linear-gradient(180deg,${primaryBackgroundColor} 0%,${primaryBackgroundColor} 65%,transparent 100%)`,
|
|
4865
4955
|
},
|
|
4866
4956
|
},
|
|
4867
4957
|
'&::before': {
|
|
@@ -4872,27 +4962,22 @@ const getComponentCss$14 = (isSidebarStartOpen, isSidebarEndOpen) => {
|
|
|
4872
4962
|
pointerEvents: 'none',
|
|
4873
4963
|
},
|
|
4874
4964
|
},
|
|
4875
|
-
'&__content': {
|
|
4876
|
-
position: 'relative', // needed for z-index to work
|
|
4877
|
-
zIndex: 0, // ensures slotted dom nodes can't be on top of sidebar header
|
|
4878
|
-
display: 'block',
|
|
4879
|
-
padding: spacingBase,
|
|
4880
|
-
},
|
|
4881
|
-
'&:focus': {
|
|
4882
|
-
outline: 'none',
|
|
4883
|
-
},
|
|
4884
|
-
},
|
|
4885
|
-
'flyout-start': {
|
|
4886
|
-
'--p-flyout-width': '100dvw',
|
|
4887
|
-
'--p-flyout-max-width': sidebarStartWidth,
|
|
4888
|
-
},
|
|
4889
|
-
'flyout-end': {
|
|
4890
|
-
'--p-flyout-width': '100dvw',
|
|
4891
|
-
'--p-flyout-max-width': sidebarEndWidth,
|
|
4892
4965
|
},
|
|
4893
4966
|
});
|
|
4894
4967
|
};
|
|
4895
4968
|
|
|
4969
|
+
/**
|
|
4970
|
+
* @css-variable {"name": "--p-carousel-px", "description": "Defines the logical inline start and end padding of the carousel, the extra space is used to show parts of the next/previous slide. When used then the prop `width` has no effect anymore.", "defaultValue": ""}
|
|
4971
|
+
*/
|
|
4972
|
+
const cssVarPaddingInline = '--p-carousel-px';
|
|
4973
|
+
/**
|
|
4974
|
+
* @css-variable {"name": "--p-carousel-ps", "description": "Defines the logical inline start padding of the carousel, the extra space is used to show parts of the next/previous slide. Needs to be used in combination with `--p-carousel-px` or `--p-carousel-pe`. When used then the prop `width` has no effect anymore.", "defaultValue": ""}
|
|
4975
|
+
*/
|
|
4976
|
+
const cssVarPaddingInlineStart = '--p-carousel-ps';
|
|
4977
|
+
/**
|
|
4978
|
+
* @css-variable {"name": "--p-carousel-pe", "description": "Defines the logical inline end padding of the carousel, the extra space is used to show parts of the next/previous slide. Needs to be used in combination with `--p-carousel-px` or `--p-carousel-ps`. When used then the prop `width` has no effect anymore.", "defaultValue": ""}
|
|
4979
|
+
*/
|
|
4980
|
+
const cssVarPaddingInlineEnd = '--p-carousel-pe';
|
|
4896
4981
|
const cssVariableGradientColorWidth = '--p-gradient-color-width';
|
|
4897
4982
|
const carouselTransitionDuration = motionDurationModerate;
|
|
4898
4983
|
const paginationInfiniteStartCaseClass = 'pagination--infinite';
|
|
@@ -4916,12 +5001,17 @@ const mediaQueryPointerCoarse = '@media (pointer: coarse)';
|
|
|
4916
5001
|
const spacingMap = {
|
|
4917
5002
|
basic: gridBasicOffset,
|
|
4918
5003
|
extended: gridExtendedOffset,
|
|
5004
|
+
wide: gridWideOffset,
|
|
5005
|
+
full: {
|
|
5006
|
+
base: gridFullOffset,
|
|
5007
|
+
s: gridFullOffset,
|
|
5008
|
+
xxl: gridFullOffset,
|
|
5009
|
+
},
|
|
4919
5010
|
};
|
|
4920
5011
|
const backfaceVisibilityJssStyle = {
|
|
4921
5012
|
backfaceVisibility: 'hidden',
|
|
4922
5013
|
WebkitBackfaceVisibility: 'hidden',
|
|
4923
5014
|
};
|
|
4924
|
-
const { primaryColor: primaryColor$w, contrastMediumColor: contrastMediumColor$a } = colors;
|
|
4925
5015
|
const gradientMask = `linear-gradient(90deg,transparent 20%,#000 var(${cssVariableGradientColorWidth},33%) calc(100% - var(${cssVariableGradientColorWidth},33%)),transparent 80%)`;
|
|
4926
5016
|
// CSS Variable defined in fontHyphenationStyle
|
|
4927
5017
|
/**
|
|
@@ -4937,7 +5027,6 @@ const getComponentCss$13 = (gradient, hasHeading, hasDescription, hasControlsSlo
|
|
|
4937
5027
|
gap: spacingFluidMedium, // TODO: maybe it's better to style by margin on .splide, then styles would be part of shadow dom
|
|
4938
5028
|
flexDirection: 'column',
|
|
4939
5029
|
boxSizing: 'content-box', // ensures padding is added to host instead of subtracted
|
|
4940
|
-
...colorSchemeStyles,
|
|
4941
5030
|
...hostHiddenStyles,
|
|
4942
5031
|
}),
|
|
4943
5032
|
},
|
|
@@ -4966,7 +5055,7 @@ const getComponentCss$13 = (gradient, hasHeading, hasDescription, hasControlsSlo
|
|
|
4966
5055
|
...((hasHeading || hasDescription) && {
|
|
4967
5056
|
[`${selectorHeading},${selectorDescription}`]: {
|
|
4968
5057
|
gridColumn: '1/-1',
|
|
4969
|
-
color:
|
|
5058
|
+
color: colorPrimary,
|
|
4970
5059
|
...(isHeaderAlignCenter && {
|
|
4971
5060
|
textAlign: 'center', // relevant in case heading or description becomes multiline
|
|
4972
5061
|
justifySelf: 'center', // relevant for horizontal alignment of heading and description in case max-width applies
|
|
@@ -4996,14 +5085,17 @@ const getComponentCss$13 = (gradient, hasHeading, hasDescription, hasControlsSlo
|
|
|
4996
5085
|
},
|
|
4997
5086
|
header: {
|
|
4998
5087
|
display: 'grid',
|
|
4999
|
-
|
|
5088
|
+
paddingInlineStart: `var(${cssVarPaddingInlineStart},var(${cssVarPaddingInline},${spacingMap[width].base}))`,
|
|
5089
|
+
paddingInlineEnd: `var(${cssVarPaddingInlineEnd},var(${cssVarPaddingInline},${spacingMap[width].base}))`,
|
|
5000
5090
|
[mediaQueryS]: {
|
|
5001
|
-
gridTemplateColumns: 'minmax(0px,
|
|
5002
|
-
|
|
5091
|
+
gridTemplateColumns: 'minmax(0px,1fr) auto',
|
|
5092
|
+
paddingInlineStart: `var(${cssVarPaddingInlineStart},var(${cssVarPaddingInline},${spacingMap[width].s}))`,
|
|
5093
|
+
paddingInlineEnd: `var(${cssVarPaddingInlineEnd},var(${cssVarPaddingInline},${spacingMap[width].s}))`,
|
|
5003
5094
|
...(hasNavigation && { columnGap: spacingStaticMedium }),
|
|
5004
5095
|
},
|
|
5005
5096
|
[mediaQueryXXL]: {
|
|
5006
|
-
|
|
5097
|
+
paddingInlineStart: `var(${cssVarPaddingInlineStart},var(${cssVarPaddingInline},${spacingMap[width].xxl}))`,
|
|
5098
|
+
paddingInlineEnd: `var(${cssVarPaddingInlineEnd},var(${cssVarPaddingInline},${spacingMap[width].xxl}))`,
|
|
5007
5099
|
},
|
|
5008
5100
|
},
|
|
5009
5101
|
nav: {
|
|
@@ -5038,12 +5130,16 @@ const getComponentCss$13 = (gradient, hasHeading, hasDescription, hasControlsSlo
|
|
|
5038
5130
|
}),
|
|
5039
5131
|
// !important is necessary to override inline styles set by splide library
|
|
5040
5132
|
...addImportantToEachRule({
|
|
5041
|
-
|
|
5133
|
+
paddingBlock: '0px',
|
|
5134
|
+
paddingInlineStart: `var(${cssVarPaddingInlineStart},var(${cssVarPaddingInline},${spacingMap[width].base}))`,
|
|
5135
|
+
paddingInlineEnd: `var(${cssVarPaddingInlineEnd},var(${cssVarPaddingInline},${spacingMap[width].base}))`,
|
|
5042
5136
|
[mediaQueryS]: {
|
|
5043
|
-
|
|
5137
|
+
paddingInlineStart: `var(${cssVarPaddingInlineStart},var(${cssVarPaddingInline},${spacingMap[width].s}))`,
|
|
5138
|
+
paddingInlineEnd: `var(${cssVarPaddingInlineEnd},var(${cssVarPaddingInline},${spacingMap[width].s}))`,
|
|
5044
5139
|
},
|
|
5045
5140
|
[mediaQueryXXL]: {
|
|
5046
|
-
|
|
5141
|
+
paddingInlineStart: `var(${cssVarPaddingInlineStart},var(${cssVarPaddingInline},${spacingMap[width].xxl}))`,
|
|
5142
|
+
paddingInlineEnd: `var(${cssVarPaddingInlineEnd},var(${cssVarPaddingInline},${spacingMap[width].xxl}))`,
|
|
5047
5143
|
},
|
|
5048
5144
|
}),
|
|
5049
5145
|
'&--draggable': {
|
|
@@ -5112,7 +5208,7 @@ const getComponentCss$13 = (gradient, hasHeading, hasDescription, hasControlsSlo
|
|
|
5112
5208
|
position: 'relative',
|
|
5113
5209
|
},
|
|
5114
5210
|
borderRadius: radiusFull,
|
|
5115
|
-
background:
|
|
5211
|
+
background: colorContrastMedium,
|
|
5116
5212
|
...(isInfinitePagination
|
|
5117
5213
|
? {
|
|
5118
5214
|
width: '0px',
|
|
@@ -5152,7 +5248,7 @@ const getComponentCss$13 = (gradient, hasHeading, hasDescription, hasControlsSlo
|
|
|
5152
5248
|
},
|
|
5153
5249
|
}),
|
|
5154
5250
|
[bulletActiveClass]: {
|
|
5155
|
-
background:
|
|
5251
|
+
background: colorPrimary,
|
|
5156
5252
|
height: paginationBulletSize,
|
|
5157
5253
|
width: addImportantToRule(paginationActiveBulletSize),
|
|
5158
5254
|
...(isInfinitePagination && {
|
|
@@ -5170,25 +5266,24 @@ const getComponentCss$13 = (gradient, hasHeading, hasDescription, hasControlsSlo
|
|
|
5170
5266
|
});
|
|
5171
5267
|
};
|
|
5172
5268
|
|
|
5173
|
-
const { successColor: successColor$3, errorColor: errorColor$2, primaryColor: primaryColor$v, successLowColor: successLowColor$1, errorLowColor, contrastLowerColor: contrastLowerColor$2, successFrostedSoftColor: successFrostedSoftColor$2, errorFrostedSoftColor: errorFrostedSoftColor$1, frostedSoftColor: frostedSoftColor$3, } = colors;
|
|
5174
5269
|
const colorBackgroundMap$1 = {
|
|
5175
|
-
success:
|
|
5176
|
-
error:
|
|
5177
|
-
none:
|
|
5270
|
+
success: colorSuccessFrostedSoft,
|
|
5271
|
+
error: colorErrorFrostedSoft,
|
|
5272
|
+
none: colorFrosted,
|
|
5178
5273
|
};
|
|
5179
5274
|
const colorBorderMap = {
|
|
5180
|
-
success:
|
|
5181
|
-
error:
|
|
5182
|
-
none:
|
|
5275
|
+
success: colorSuccess,
|
|
5276
|
+
error: colorError,
|
|
5277
|
+
none: colorContrastLower,
|
|
5183
5278
|
};
|
|
5184
5279
|
const colorBorderHoverMap = {
|
|
5185
|
-
success:
|
|
5186
|
-
error:
|
|
5187
|
-
none:
|
|
5280
|
+
success: colorSuccess,
|
|
5281
|
+
error: colorError,
|
|
5282
|
+
none: colorPrimary,
|
|
5188
5283
|
};
|
|
5189
5284
|
const colorMap$4 = {
|
|
5190
|
-
success:
|
|
5191
|
-
error:
|
|
5285
|
+
success: colorSuccess,
|
|
5286
|
+
error: colorError,
|
|
5192
5287
|
none: undefined,
|
|
5193
5288
|
};
|
|
5194
5289
|
const getThemedFormStateColors = (state) => {
|
|
@@ -5200,7 +5295,17 @@ const getThemedFormStateColors = (state) => {
|
|
|
5200
5295
|
};
|
|
5201
5296
|
};
|
|
5202
5297
|
|
|
5203
|
-
|
|
5298
|
+
/**
|
|
5299
|
+
* External CSS variables
|
|
5300
|
+
*/
|
|
5301
|
+
const cssVarCheckboxBorderColor = '--p-checkbox-border-color';
|
|
5302
|
+
const cssVarCheckboxBackgroundColor = '--p-checkbox-background-color';
|
|
5303
|
+
const cssVarCheckboxIconColor = '--p-checkbox-icon-color';
|
|
5304
|
+
/**
|
|
5305
|
+
* Internal CSS variables
|
|
5306
|
+
*/
|
|
5307
|
+
const cssVarInternalCheckboxScaling = '--__p-checkbox-scaling';
|
|
5308
|
+
|
|
5204
5309
|
const getCheckboxBaseStyles = (isDisabled, isLoading, isCompact, state) => {
|
|
5205
5310
|
const { formStateBackgroundColor, formStateBorderColor } = getThemedFormStateColors(state);
|
|
5206
5311
|
const disabledOrLoading = isDisabledOrLoading(isDisabled, isLoading);
|
|
@@ -5216,9 +5321,9 @@ const getCheckboxBaseStyles = (isDisabled, isLoading, isCompact, state) => {
|
|
|
5216
5321
|
marginBlock: checkboxMarginBlock,
|
|
5217
5322
|
boxSizing: 'border-box',
|
|
5218
5323
|
font: `${fontSizeTextSmall} ${fontFamily}`, // needed for correct width and height definition based on ex-unit
|
|
5219
|
-
background: formStateBackgroundColor
|
|
5324
|
+
background: `var(${cssVarCheckboxBackgroundColor},${formStateBackgroundColor})`,
|
|
5220
5325
|
transition: `${getTransition('background-color')}, ${getTransition('border-color')}`,
|
|
5221
|
-
border: `${checkboxBorderWidth} solid ${formStateBorderColor}`,
|
|
5326
|
+
border: `${checkboxBorderWidth} solid var(${cssVarCheckboxBorderColor},${formStateBorderColor})`,
|
|
5222
5327
|
borderRadius: `var(${legacyRadiusSmall}, ${isCompact ? radiusMd : radiusLg})`,
|
|
5223
5328
|
...(disabledOrLoading && {
|
|
5224
5329
|
pointerEvents: 'none', // to prevent form element becomes clickable/toggleable
|
|
@@ -5242,9 +5347,9 @@ const getInlineSVGBackgroundImage = (path) => {
|
|
|
5242
5347
|
return `url('data:image/svg+xml;charset=UTF-8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24">${path}</svg>')`;
|
|
5243
5348
|
};
|
|
5244
5349
|
|
|
5245
|
-
const { primaryColor: primaryColor$u } = colors;
|
|
5246
5350
|
const checkedIcon$1 = getInlineSVGBackgroundImage(`<path d="m20.22,7.47l-1.47-1.42-9.26,9.02-4.24-4.15-1.47,1.42,5.71,5.6,10.73-10.47Z"/>`);
|
|
5247
|
-
const getCheckboxCheckedBaseStyles = (isLoading) => {
|
|
5351
|
+
const getCheckboxCheckedBaseStyles = (isLoading, state) => {
|
|
5352
|
+
const { formStateBorderColor } = getThemedFormStateColors(state);
|
|
5248
5353
|
if (isLoading) {
|
|
5249
5354
|
return {};
|
|
5250
5355
|
}
|
|
@@ -5252,14 +5357,14 @@ const getCheckboxCheckedBaseStyles = (isLoading) => {
|
|
|
5252
5357
|
'&::before': {
|
|
5253
5358
|
WebkitMask: `${checkedIcon$1} center/contain no-repeat`, // necessary for Sogou browser support :-)
|
|
5254
5359
|
mask: `${checkedIcon$1} center/contain no-repeat`,
|
|
5255
|
-
backgroundColor:
|
|
5360
|
+
backgroundColor: `var(${cssVarCheckboxIconColor}, ${state === 'none' ? colorPrimary : formStateBorderColor})`,
|
|
5256
5361
|
},
|
|
5257
5362
|
};
|
|
5258
5363
|
};
|
|
5259
5364
|
|
|
5260
|
-
const { primaryColor: primaryColor$t } = colors;
|
|
5261
5365
|
const indeterminateIcon = getInlineSVGBackgroundImage(`<path d="m20,11v2H4v-2h16Z"/>`);
|
|
5262
|
-
const getCheckboxIndeterminateBaseStyles = (isLoading) => {
|
|
5366
|
+
const getCheckboxIndeterminateBaseStyles = (isLoading, state) => {
|
|
5367
|
+
const { formStateBorderColor } = getThemedFormStateColors(state);
|
|
5263
5368
|
if (isLoading) {
|
|
5264
5369
|
return {};
|
|
5265
5370
|
}
|
|
@@ -5267,7 +5372,7 @@ const getCheckboxIndeterminateBaseStyles = (isLoading) => {
|
|
|
5267
5372
|
'&::before': {
|
|
5268
5373
|
WebkitMask: `${indeterminateIcon} center/contain no-repeat`,
|
|
5269
5374
|
mask: `${indeterminateIcon} center/contain no-repeat`,
|
|
5270
|
-
backgroundColor:
|
|
5375
|
+
backgroundColor: state === 'none' ? colorPrimary : formStateBorderColor,
|
|
5271
5376
|
},
|
|
5272
5377
|
};
|
|
5273
5378
|
};
|
|
@@ -5280,27 +5385,46 @@ const getFunctionalComponentRequiredStyles = () => {
|
|
|
5280
5385
|
};
|
|
5281
5386
|
};
|
|
5282
5387
|
|
|
5283
|
-
const
|
|
5284
|
-
const getFunctionalComponentLabelStyles = (isDisabledOrLoading, hideLabel, additionalDefaultJssStyle, additionalIsShownJssStyle) => {
|
|
5388
|
+
const getFunctionalComponentLabelAfterStyles = (isDisabledOrLoading, additionalIsDisabledJssStyle) => {
|
|
5285
5389
|
return {
|
|
5390
|
+
'slot[name="label-after"]': {
|
|
5391
|
+
display: 'inline-block',
|
|
5392
|
+
verticalAlign: 'top',
|
|
5393
|
+
...(isDisabledOrLoading && {
|
|
5394
|
+
pointerEvents: 'none',
|
|
5395
|
+
...additionalIsDisabledJssStyle,
|
|
5396
|
+
}),
|
|
5397
|
+
},
|
|
5398
|
+
};
|
|
5399
|
+
};
|
|
5400
|
+
const getFunctionalComponentLabelStyles = (isDisabledOrLoading, hideLabel, additionalDefaultJssStyle, additionalLabelWrapperJssStyle, additionalIsShownJssStyle) => {
|
|
5401
|
+
return {
|
|
5402
|
+
'label-wrapper': {
|
|
5403
|
+
...buildResponsiveStyles(hideLabel, (isHidden) => ({
|
|
5404
|
+
...(!isHidden && { minWidth: 'fit-content' }), // ensures label contents don't shrink to zero in grid containers
|
|
5405
|
+
...getHiddenTextJssStyle(isHidden, additionalIsShownJssStyle),
|
|
5406
|
+
})),
|
|
5407
|
+
...additionalLabelWrapperJssStyle,
|
|
5408
|
+
},
|
|
5286
5409
|
label: {
|
|
5287
|
-
...
|
|
5410
|
+
...proseTextSmStyle,
|
|
5288
5411
|
cursor: isDisabledOrLoading ? 'not-allowed' : 'pointer',
|
|
5289
5412
|
...(isDisabledOrLoading && {
|
|
5290
5413
|
pointerEvents: 'none', // prevents label interaction when disabled or loading
|
|
5291
5414
|
}),
|
|
5292
|
-
|
|
5293
|
-
color: primaryColor$s,
|
|
5415
|
+
color: colorPrimary,
|
|
5294
5416
|
transition: getTransition('color'), // for smooth transitions between e.g. disabled state
|
|
5295
|
-
|
|
5417
|
+
display: 'inline',
|
|
5296
5418
|
'&:empty': {
|
|
5297
5419
|
display: 'none', // prevents outer spacing caused by parents grid gap, in case no label value is defined (although it has to be set to be a11y compliant)
|
|
5298
5420
|
},
|
|
5299
|
-
|
|
5421
|
+
// styling for the description
|
|
5422
|
+
'&:is(span)': {
|
|
5300
5423
|
cursor: 'unset',
|
|
5301
|
-
|
|
5302
|
-
|
|
5303
|
-
|
|
5424
|
+
fontSize: typescaleXs,
|
|
5425
|
+
color: colorContrastHigh,
|
|
5426
|
+
...buildResponsiveStyles(hideLabel, (isHidden) => getHiddenTextJssStyle(isHidden, { marginTop: `-${spacingStaticXs$1}` })),
|
|
5427
|
+
marginTop: `-${spacingStaticXs$1}`,
|
|
5304
5428
|
},
|
|
5305
5429
|
...additionalDefaultJssStyle,
|
|
5306
5430
|
},
|
|
@@ -5330,6 +5454,12 @@ const getFunctionalComponentStateMessageStyles = (state, additionalDefaultJssSty
|
|
|
5330
5454
|
/**
|
|
5331
5455
|
* @css-variable {"name": "--p-hyphens", "description": "Sets the CSS `hyphens` property for text elements, controlling whether words can break and hyphenate automatically.", "defaultValue": "auto"}
|
|
5332
5456
|
*/
|
|
5457
|
+
// CSS Variables defined in checkbox-css-vars.ts
|
|
5458
|
+
/**
|
|
5459
|
+
* @css-variable {"name": "--p-checkbox-border-color", "description": "🧪Experimental: Border colors of Checkbox. Should be used to override the default border color in different states (e.g., hover, focus, error), e.g. when the Checkbox is wrapped inside a custom label."}
|
|
5460
|
+
* @css-variable {"name": "--p-checkbox-background-color", "description": "🧪Experimental: Background color of Checkbox."}
|
|
5461
|
+
* @css-variable {"name": "--p-checkbox-icon-color", "description": "🧪Experimental: Checkmark icon color of Checkbox."}
|
|
5462
|
+
*/
|
|
5333
5463
|
const getComponentCss$12 = (hideLabel, state, isDisabled, isLoading, isCompact) => {
|
|
5334
5464
|
const { formStateBorderHoverColor } = getThemedFormStateColors(state);
|
|
5335
5465
|
const disabledOrLoading = isDisabledOrLoading(isDisabled, isLoading);
|
|
@@ -5341,35 +5471,39 @@ const getComponentCss$12 = (hideLabel, state, isDisabled, isLoading, isCompact)
|
|
|
5341
5471
|
':host': {
|
|
5342
5472
|
display: 'block',
|
|
5343
5473
|
...addImportantToEachRule({
|
|
5344
|
-
...colorSchemeStyles,
|
|
5345
5474
|
...hostHiddenStyles,
|
|
5346
5475
|
...(isDisabled && getDisabledBaseStyles()),
|
|
5347
5476
|
}),
|
|
5348
5477
|
[`${cssVarInternalCheckboxScaling}`]: isCompact ? 0.64285714 : 1,
|
|
5349
5478
|
},
|
|
5479
|
+
...getFunctionalComponentLabelAfterStyles(disabledOrLoading),
|
|
5350
5480
|
...preventFoucOfNestedElementsStyles,
|
|
5351
5481
|
input: {
|
|
5352
5482
|
...getCheckboxBaseStyles(isDisabled, isLoading, isCompact, state),
|
|
5353
|
-
'&:checked': getCheckboxCheckedBaseStyles(isLoading),
|
|
5354
|
-
'&:indeterminate': getCheckboxIndeterminateBaseStyles(isLoading),
|
|
5483
|
+
'&:checked': getCheckboxCheckedBaseStyles(isLoading, state),
|
|
5484
|
+
'&:indeterminate': getCheckboxIndeterminateBaseStyles(isLoading, state),
|
|
5355
5485
|
'&:focus-visible': getFocusBaseStyles(),
|
|
5356
5486
|
...(!disabledOrLoading &&
|
|
5357
5487
|
hoverMediaQuery({
|
|
5358
|
-
'&:hover
|
|
5359
|
-
borderColor: formStateBorderHoverColor
|
|
5488
|
+
'&:hover': {
|
|
5489
|
+
borderColor: `var(${cssVarCheckboxBorderColor}, ${formStateBorderHoverColor})`,
|
|
5360
5490
|
},
|
|
5361
5491
|
})),
|
|
5362
5492
|
},
|
|
5363
5493
|
},
|
|
5364
5494
|
root: {
|
|
5365
5495
|
display: 'grid',
|
|
5366
|
-
gridTemplateColumns: 'auto minmax(0, 1fr)',
|
|
5367
5496
|
rowGap: spacingStaticXSmall,
|
|
5368
5497
|
},
|
|
5369
5498
|
wrapper: {
|
|
5370
5499
|
position: 'relative',
|
|
5371
|
-
display: '
|
|
5500
|
+
display: 'grid',
|
|
5501
|
+
gridTemplateColumns: 'auto minmax(0, 1fr)',
|
|
5502
|
+
},
|
|
5503
|
+
'input-wrapper': {
|
|
5504
|
+
position: 'relative',
|
|
5372
5505
|
alignItems: 'center',
|
|
5506
|
+
display: 'grid',
|
|
5373
5507
|
alignSelf: 'flex-start',
|
|
5374
5508
|
minHeight: fontLineHeight, // necessary for compact mode
|
|
5375
5509
|
cursor: disabledOrLoading ? 'not-allowed' : 'pointer',
|
|
@@ -5387,15 +5521,13 @@ const getComponentCss$12 = (hideLabel, state, isDisabled, isLoading, isCompact)
|
|
|
5387
5521
|
}),
|
|
5388
5522
|
// .label / .required
|
|
5389
5523
|
...getFunctionalComponentLabelStyles(isDisabled || isLoading, hideLabel, {
|
|
5390
|
-
|
|
5391
|
-
}, {
|
|
5524
|
+
cursor: disabledOrLoading ? 'not-allowed' : 'pointer',
|
|
5525
|
+
}, null, {
|
|
5392
5526
|
paddingTop: labelPaddingTop,
|
|
5393
5527
|
paddingInlineStart: labelPaddingInlineStart,
|
|
5394
5528
|
}),
|
|
5395
5529
|
// .message
|
|
5396
|
-
...getFunctionalComponentStateMessageStyles(state,
|
|
5397
|
-
gridColumn: '1/-1',
|
|
5398
|
-
}),
|
|
5530
|
+
...getFunctionalComponentStateMessageStyles(state),
|
|
5399
5531
|
// .loading
|
|
5400
5532
|
...getFunctionalComponentLoadingMessageStyles(),
|
|
5401
5533
|
});
|
|
@@ -5410,7 +5542,6 @@ const cssVarButtonPurePadding = '--ref-p-input-slotted-padding';
|
|
|
5410
5542
|
*/
|
|
5411
5543
|
const cssVarButtonPureMargin = '--ref-p-input-slotted-margin';
|
|
5412
5544
|
const cssVarInternalInputBaseScaling = '--p-internal-input-base-scaling';
|
|
5413
|
-
const { primaryColor: primaryColor$r, contrastMediumColor: contrastMediumColor$9, frostedColor: frostedColor$8 } = colors;
|
|
5414
5545
|
const getFunctionalComponentInputBaseStyles = (isDisabled, isLoading, hideLabel, state, isCompact, readOnly, additionalInputJssStyle) => {
|
|
5415
5546
|
const wrapperBorderWidth = borderWidthThin;
|
|
5416
5547
|
const wrapperHeight = `calc(var(${cssVarInternalInputBaseScaling}) * 3.5rem)`;
|
|
@@ -5427,11 +5558,11 @@ const getFunctionalComponentInputBaseStyles = (isDisabled, isLoading, hideLabel,
|
|
|
5427
5558
|
...addImportantToEachRule({
|
|
5428
5559
|
[`${cssVarButtonPurePadding}`]: buttonPadding,
|
|
5429
5560
|
[`${cssVarButtonPureMargin}`]: buttonMargin,
|
|
5430
|
-
...colorSchemeStyles,
|
|
5431
5561
|
...hostHiddenStyles,
|
|
5432
5562
|
...(isDisabled && getDisabledBaseStyles()),
|
|
5433
5563
|
}),
|
|
5434
5564
|
},
|
|
5565
|
+
...getFunctionalComponentLabelAfterStyles(isDisabled),
|
|
5435
5566
|
...preventFoucOfNestedElementsStyles,
|
|
5436
5567
|
input: {
|
|
5437
5568
|
all: 'unset',
|
|
@@ -5457,13 +5588,13 @@ const getFunctionalComponentInputBaseStyles = (isDisabled, isLoading, hideLabel,
|
|
|
5457
5588
|
border: `${wrapperBorderWidth} solid ${formStateBorderColor}`,
|
|
5458
5589
|
borderRadius: `var(${legacyRadiusSmall}, ${isCompact ? radiusLg : radiusXl})`,
|
|
5459
5590
|
background: formStateBackgroundColor,
|
|
5460
|
-
color:
|
|
5591
|
+
color: colorPrimary,
|
|
5461
5592
|
cursor: isDisabled ? 'not-allowed' : 'text',
|
|
5462
5593
|
transition: `${getTransition('background-color')}, ${getTransition('border-color')}`,
|
|
5463
5594
|
...(readOnly && {
|
|
5464
5595
|
borderColor: 'transparent',
|
|
5465
|
-
background:
|
|
5466
|
-
color:
|
|
5596
|
+
background: colorFrosted,
|
|
5597
|
+
color: colorContrastMedium,
|
|
5467
5598
|
}),
|
|
5468
5599
|
'&:focus-within': {
|
|
5469
5600
|
borderColor: formStateBorderHoverColor,
|
|
@@ -5472,7 +5603,7 @@ const getFunctionalComponentInputBaseStyles = (isDisabled, isLoading, hideLabel,
|
|
|
5472
5603
|
!readOnly &&
|
|
5473
5604
|
!isLoading &&
|
|
5474
5605
|
hoverMediaQuery({
|
|
5475
|
-
'&:hover:not(.button:hover)
|
|
5606
|
+
'&:hover:not(.button:hover),.label-wrapper:hover~&': {
|
|
5476
5607
|
borderColor: formStateBorderHoverColor,
|
|
5477
5608
|
},
|
|
5478
5609
|
})),
|
|
@@ -5493,7 +5624,6 @@ const getFunctionalComponentInputBaseStyles = (isDisabled, isLoading, hideLabel,
|
|
|
5493
5624
|
};
|
|
5494
5625
|
};
|
|
5495
5626
|
|
|
5496
|
-
const { primaryColor: primaryColor$q } = colors;
|
|
5497
5627
|
const getButtonJssStyle = (componentName, isOpen, isDisabled, state, isCompact, cssVarScalingName) => {
|
|
5498
5628
|
const cssVarBackgroundColor = `--p-${componentName}-background-color`;
|
|
5499
5629
|
const cssVarTextColor = `--p-${componentName}-text-color`;
|
|
@@ -5516,7 +5646,7 @@ const getButtonJssStyle = (componentName, isOpen, isDisabled, state, isCompact,
|
|
|
5516
5646
|
borderRadius: `var(${legacyRadiusSmall}, ${isCompact ? radiusLg : radiusXl})`,
|
|
5517
5647
|
background: `var(${cssVarBackgroundColor}, ${formStateBackgroundColor})`,
|
|
5518
5648
|
font: textSmallStyle.font,
|
|
5519
|
-
color: `var(${cssVarTextColor}, ${
|
|
5649
|
+
color: `var(${cssVarTextColor}, ${colorPrimary})`,
|
|
5520
5650
|
cursor: isDisabled ? 'not-allowed' : 'pointer',
|
|
5521
5651
|
transition: `${getTransition('background-color')}, ${getTransition('border-color')}, ${getTransition('color')}`, // for smooth transitions between e.g. disabled states
|
|
5522
5652
|
...(!isDisabled && {
|
|
@@ -5544,7 +5674,6 @@ const getButtonLabelJssStyle = {
|
|
|
5544
5674
|
whiteSpace: 'nowrap',
|
|
5545
5675
|
};
|
|
5546
5676
|
|
|
5547
|
-
const { canvasColor: canvasColor$6 } = colors;
|
|
5548
5677
|
const getFilterJssStyle = (scalingVarName) => {
|
|
5549
5678
|
const padding = `calc(11.2px * (var(${scalingVarName}) - 0.64285714) + 4px)`;
|
|
5550
5679
|
const margin = `calc(${padding} * -1)`;
|
|
@@ -5554,7 +5683,7 @@ const getFilterJssStyle = (scalingVarName) => {
|
|
|
5554
5683
|
top,
|
|
5555
5684
|
padding,
|
|
5556
5685
|
margin,
|
|
5557
|
-
background:
|
|
5686
|
+
background: colorCanvas,
|
|
5558
5687
|
zIndex: 1,
|
|
5559
5688
|
};
|
|
5560
5689
|
};
|
|
@@ -5568,7 +5697,6 @@ const getIconJssStyle = (isOpen) => {
|
|
|
5568
5697
|
};
|
|
5569
5698
|
};
|
|
5570
5699
|
|
|
5571
|
-
const { primaryColor: primaryColor$p, frostedSoftColor: frostedSoftColor$2, contrastHighColor: contrastHighColor$7 } = colors;
|
|
5572
5700
|
const getOptionJssStyle = (componentName, cssVarScalingName) => {
|
|
5573
5701
|
const gap = `calc(11.2px * (var(${cssVarScalingName}) - 0.64285714) + 4px)`;
|
|
5574
5702
|
const paddingBlock = `calc(11.2px * (var(${cssVarScalingName}) - 0.64285714) + 4px)`;
|
|
@@ -5580,7 +5708,7 @@ const getOptionJssStyle = (componentName, cssVarScalingName) => {
|
|
|
5580
5708
|
paddingInline,
|
|
5581
5709
|
minHeight: fontLineHeight, // preserves height for empty option
|
|
5582
5710
|
...textSmallStyle,
|
|
5583
|
-
color:
|
|
5711
|
+
color: colorContrastHigh,
|
|
5584
5712
|
cursor: 'pointer',
|
|
5585
5713
|
textAlign: 'start',
|
|
5586
5714
|
wordBreak: 'break-word',
|
|
@@ -5588,10 +5716,10 @@ const getOptionJssStyle = (componentName, cssVarScalingName) => {
|
|
|
5588
5716
|
borderRadius: `var(${legacyRadiusSmall}, ${radiusSm})`,
|
|
5589
5717
|
transition: `${getTransition('background-color')}, ${getTransition('color')}`,
|
|
5590
5718
|
'&--highlighted': {
|
|
5591
|
-
background:
|
|
5719
|
+
background: colorFrosted,
|
|
5592
5720
|
},
|
|
5593
5721
|
'&--highlighted, &--selected': {
|
|
5594
|
-
color:
|
|
5722
|
+
color: colorPrimary,
|
|
5595
5723
|
},
|
|
5596
5724
|
'&--disabled': {
|
|
5597
5725
|
cursor: 'not-allowed',
|
|
@@ -5622,7 +5750,6 @@ const getPopoverKeyframesStyles = {
|
|
|
5622
5750
|
},
|
|
5623
5751
|
},
|
|
5624
5752
|
};
|
|
5625
|
-
const { contrastLowColor: contrastLowColor$6, canvasColor: canvasColor$5 } = colors;
|
|
5626
5753
|
const getPopoverJssStyle = (isOpen, cssVarScalingName, optionHeight) => {
|
|
5627
5754
|
const minHeightOptionList = `calc(${4.5 * (optionHeight + 8) + 6 + 2}px)`; // 4.5 options * option height + 8px gap + additional spacing (6px = padding, 2px = border)
|
|
5628
5755
|
const padding = `calc(11.2px * (var(${cssVarScalingName}) - 0.64285714) + 4px)`;
|
|
@@ -5642,8 +5769,8 @@ const getPopoverJssStyle = (isOpen, cssVarScalingName, optionHeight) => {
|
|
|
5642
5769
|
scrollbarColor: 'auto', // firefox
|
|
5643
5770
|
animation: `var(${cssVariableAnimationDuration}, ${motionDurationShort}) ${keyframesName} ${motionEasingBase} forwards`,
|
|
5644
5771
|
filter: 'drop-shadow(0 0 8px rgba(0,0,0,0.15))',
|
|
5645
|
-
background:
|
|
5646
|
-
border: `1px solid ${
|
|
5772
|
+
background: colorCanvas,
|
|
5773
|
+
border: `1px solid ${colorContrastLow}`,
|
|
5647
5774
|
borderRadius: `var(${legacyRadiusMedium}, ${radiusXl})`,
|
|
5648
5775
|
'&:not(:popover-open)': {
|
|
5649
5776
|
display: 'none',
|
|
@@ -5658,7 +5785,6 @@ const getSelectedSlotJssStyle = {
|
|
|
5658
5785
|
overflow: 'hidden',
|
|
5659
5786
|
};
|
|
5660
5787
|
|
|
5661
|
-
const { contrastMediumColor: contrastMediumColor$8 } = colors;
|
|
5662
5788
|
const getFunctionalComponentNoResultsOptionStyles = (componentName, cssVarScalingName) => {
|
|
5663
5789
|
return {
|
|
5664
5790
|
'no-results': {
|
|
@@ -5666,7 +5792,7 @@ const getFunctionalComponentNoResultsOptionStyles = (componentName, cssVarScalin
|
|
|
5666
5792
|
'&[role=option]': {
|
|
5667
5793
|
cursor: 'not-allowed',
|
|
5668
5794
|
},
|
|
5669
|
-
color:
|
|
5795
|
+
color: colorContrastMedium,
|
|
5670
5796
|
},
|
|
5671
5797
|
'sr-only': getHiddenTextJssStyle(),
|
|
5672
5798
|
};
|
|
@@ -5700,7 +5826,6 @@ const getComponentCss$11 = () => {
|
|
|
5700
5826
|
...addImportantToEachRule({
|
|
5701
5827
|
boxSizing: 'content-box', // needed for correct height calculation when padding is set on host (e.g. custom click area)
|
|
5702
5828
|
...getDimensionStyle,
|
|
5703
|
-
...colorSchemeStyles,
|
|
5704
5829
|
...hostHiddenStyles,
|
|
5705
5830
|
}),
|
|
5706
5831
|
},
|
|
@@ -5732,16 +5857,15 @@ const getComponentCss$11 = () => {
|
|
|
5732
5857
|
});
|
|
5733
5858
|
};
|
|
5734
5859
|
|
|
5735
|
-
const { primaryColor: primaryColor$o, contrastLowColor: contrastLowColor$5, contrastMediumColor: contrastMediumColor$7, contrastHighColor: contrastHighColor$6, successColor: successColor$2, warningColor: warningColor$1, errorColor: errorColor$1, infoColor: infoColor$1, } = colors;
|
|
5736
5860
|
const colorMap$3 = {
|
|
5737
|
-
primary:
|
|
5738
|
-
'contrast-high':
|
|
5739
|
-
'contrast-medium':
|
|
5740
|
-
'contrast-low':
|
|
5741
|
-
success:
|
|
5742
|
-
warning:
|
|
5743
|
-
error:
|
|
5744
|
-
info:
|
|
5861
|
+
primary: colorPrimary,
|
|
5862
|
+
'contrast-high': colorContrastHigh,
|
|
5863
|
+
'contrast-medium': colorContrastMedium,
|
|
5864
|
+
'contrast-low': colorContrastLow,
|
|
5865
|
+
success: colorSuccess,
|
|
5866
|
+
warning: colorWarning,
|
|
5867
|
+
error: colorError,
|
|
5868
|
+
info: colorInfo,
|
|
5745
5869
|
inherit: 'currentColor',
|
|
5746
5870
|
};
|
|
5747
5871
|
const getThemedTypographyColor = (textColor) => {
|
|
@@ -5788,7 +5912,6 @@ const getComponentCss$10 = (size, align, color, ellipsis) => {
|
|
|
5788
5912
|
':host': {
|
|
5789
5913
|
display: 'block',
|
|
5790
5914
|
...addImportantToEachRule({
|
|
5791
|
-
...colorSchemeStyles,
|
|
5792
5915
|
...hostHiddenStyles,
|
|
5793
5916
|
}),
|
|
5794
5917
|
},
|
|
@@ -5800,12 +5923,11 @@ const getComponentCss$10 = (size, align, color, ellipsis) => {
|
|
|
5800
5923
|
});
|
|
5801
5924
|
};
|
|
5802
5925
|
|
|
5803
|
-
const { contrastLowerColor: contrastLowerColor$1, contrastLowColor: contrastLowColor$4, contrastMediumColor: contrastMediumColor$6, contrastHighColor: contrastHighColor$5 } = colors;
|
|
5804
5926
|
const colorMap$2 = {
|
|
5805
|
-
'contrast-lower':
|
|
5806
|
-
'contrast-low':
|
|
5807
|
-
'contrast-medium':
|
|
5808
|
-
'contrast-high':
|
|
5927
|
+
'contrast-lower': colorContrastLower,
|
|
5928
|
+
'contrast-low': colorContrastLow,
|
|
5929
|
+
'contrast-medium': colorContrastMedium,
|
|
5930
|
+
'contrast-high': colorContrastHigh,
|
|
5809
5931
|
};
|
|
5810
5932
|
const getComponentCss$$ = (color, orientation) => {
|
|
5811
5933
|
return getCss({
|
|
@@ -5813,7 +5935,6 @@ const getComponentCss$$ = (color, orientation) => {
|
|
|
5813
5935
|
':host': {
|
|
5814
5936
|
display: 'block',
|
|
5815
5937
|
...addImportantToEachRule({
|
|
5816
|
-
...colorSchemeStyles,
|
|
5817
5938
|
...hostHiddenStyles,
|
|
5818
5939
|
}),
|
|
5819
5940
|
},
|
|
@@ -5845,7 +5966,6 @@ const easingOpen = 'in';
|
|
|
5845
5966
|
const dialogDurationClose = 'short';
|
|
5846
5967
|
const backdropDurationClose = 'moderate';
|
|
5847
5968
|
const easingClose = 'out';
|
|
5848
|
-
const { primaryColor: primaryColor$n, canvasColor: canvasColor$4, surfaceColor: surfaceColor$2, backdropColor: backdropColor$1 } = colors;
|
|
5849
5969
|
const getComponentCss$_ = (isOpen, isPrimary, isSecondaryScrollerVisible) => {
|
|
5850
5970
|
return getCss({
|
|
5851
5971
|
'@global': {
|
|
@@ -5863,13 +5983,12 @@ const getComponentCss$_ = (isOpen, isPrimary, isSecondaryScrollerVisible) => {
|
|
|
5863
5983
|
':host': {
|
|
5864
5984
|
display: 'block',
|
|
5865
5985
|
...addImportantToEachRule({
|
|
5866
|
-
[cssVarColorPrimary]:
|
|
5867
|
-
[cssVarColorBackgroundBase]:
|
|
5868
|
-
[cssVarColorBackgroundSurface]:
|
|
5869
|
-
[cssVarColorBackgroundShading]:
|
|
5986
|
+
[cssVarColorPrimary]: colorPrimary,
|
|
5987
|
+
[cssVarColorBackgroundBase]: colorCanvas,
|
|
5988
|
+
[cssVarColorBackgroundSurface]: colorSurface,
|
|
5989
|
+
[cssVarColorBackgroundShading]: colorBackdrop,
|
|
5870
5990
|
// [cssVarColorBackgroundScroller]: theme === 'dark' ? 'rgba(0,0,0,.01)' : 'rgba(255,255,255,.01)', // ensures that the scrollbar color is mostly set correctly
|
|
5871
5991
|
[cssVarColorBackgroundScroller]: 'rgba(255,255,255,.01)', // ensures that the scrollbar color is mostly set correctly
|
|
5872
|
-
...colorSchemeStyles,
|
|
5873
5992
|
...hostHiddenStyles,
|
|
5874
5993
|
}),
|
|
5875
5994
|
},
|
|
@@ -6105,7 +6224,6 @@ const getComponentCss$Z = (isPrimary, isSecondary, isCascade) => {
|
|
|
6105
6224
|
':host': {
|
|
6106
6225
|
display: 'contents',
|
|
6107
6226
|
...addImportantToEachRule({
|
|
6108
|
-
...colorSchemeStyles,
|
|
6109
6227
|
...hostHiddenStyles,
|
|
6110
6228
|
}),
|
|
6111
6229
|
},
|
|
@@ -6339,7 +6457,6 @@ const getComponentCss$Y = (hasSlottedAnchor, isActive) => {
|
|
|
6339
6457
|
':host': {
|
|
6340
6458
|
display: 'grid',
|
|
6341
6459
|
...addImportantToEachRule({
|
|
6342
|
-
...colorSchemeStyles,
|
|
6343
6460
|
...hostHiddenStyles,
|
|
6344
6461
|
}),
|
|
6345
6462
|
},
|
|
@@ -6367,14 +6484,12 @@ const getComponentCss$Y = (hasSlottedAnchor, isActive) => {
|
|
|
6367
6484
|
});
|
|
6368
6485
|
};
|
|
6369
6486
|
|
|
6370
|
-
const { primaryColor: primaryColor$m } = colors;
|
|
6371
6487
|
const getComponentCss$X = (state, labelSize, hasLabel) => {
|
|
6372
6488
|
return getCss({
|
|
6373
6489
|
'@global': {
|
|
6374
6490
|
':host': {
|
|
6375
6491
|
display: 'block',
|
|
6376
6492
|
...addImportantToEachRule({
|
|
6377
|
-
...colorSchemeStyles,
|
|
6378
6493
|
...hostHiddenStyles,
|
|
6379
6494
|
}),
|
|
6380
6495
|
},
|
|
@@ -6387,7 +6502,7 @@ const getComponentCss$X = (state, labelSize, hasLabel) => {
|
|
|
6387
6502
|
legend: {
|
|
6388
6503
|
all: 'unset',
|
|
6389
6504
|
marginBottom: spacingStaticMedium,
|
|
6390
|
-
color:
|
|
6505
|
+
color: colorPrimary,
|
|
6391
6506
|
...(labelSize === 'small' ? headingSmallStyle : headingMediumStyle),
|
|
6392
6507
|
},
|
|
6393
6508
|
}),
|
|
@@ -6416,7 +6531,6 @@ const getComponentCss$W = (size) => {
|
|
|
6416
6531
|
display: 'inline-block',
|
|
6417
6532
|
verticalAlign: 'top',
|
|
6418
6533
|
...addImportantToEachRule({
|
|
6419
|
-
...colorSchemeStyles,
|
|
6420
6534
|
...hostHiddenStyles,
|
|
6421
6535
|
}),
|
|
6422
6536
|
},
|
|
@@ -6441,7 +6555,6 @@ const getComponentCss$W = (size) => {
|
|
|
6441
6555
|
});
|
|
6442
6556
|
};
|
|
6443
6557
|
|
|
6444
|
-
const { backdropColor, primaryColor: primaryColor$l, canvasColor: canvasColor$3, surfaceColor: surfaceColor$1, frostedColor: frostedColor$7 } = colors;
|
|
6445
6558
|
const cssVarBackgroundColor = '--_a';
|
|
6446
6559
|
const dialogHostJssStyle = (background) => {
|
|
6447
6560
|
return {
|
|
@@ -6449,7 +6562,7 @@ const dialogHostJssStyle = (background) => {
|
|
|
6449
6562
|
'--pds-internal-grid-margin': `calc(${spacingFluidLarge} * -1)`,
|
|
6450
6563
|
'--pds-internal-grid-width-min': 'auto',
|
|
6451
6564
|
'--pds-internal-grid-width-max': 'none',
|
|
6452
|
-
[cssVarBackgroundColor]: background === 'surface' ?
|
|
6565
|
+
[cssVarBackgroundColor]: background === 'surface' ? colorSurface : colorCanvas,
|
|
6453
6566
|
};
|
|
6454
6567
|
};
|
|
6455
6568
|
const getDialogJssStyle = (isVisible, backdrop = 'blur') => {
|
|
@@ -6487,7 +6600,7 @@ const getDialogBackdropTransitionJssStyle = (isVisible, backdrop = 'blur') => {
|
|
|
6487
6600
|
? {
|
|
6488
6601
|
visibility: 'inherit',
|
|
6489
6602
|
pointerEvents: 'auto',
|
|
6490
|
-
background:
|
|
6603
|
+
background: colorBackdrop,
|
|
6491
6604
|
...(isBackdropBlur && frostedGlassStyle),
|
|
6492
6605
|
}
|
|
6493
6606
|
: {
|
|
@@ -6543,7 +6656,7 @@ const dialogGridJssStyle = () => {
|
|
|
6543
6656
|
};
|
|
6544
6657
|
const getDialogColorJssStyle = () => {
|
|
6545
6658
|
return {
|
|
6546
|
-
color:
|
|
6659
|
+
color: colorPrimary, // enables color inheritance for slots
|
|
6547
6660
|
background: `var(${cssVarBackgroundColor})`,
|
|
6548
6661
|
};
|
|
6549
6662
|
};
|
|
@@ -6632,7 +6745,7 @@ const getSlotFooterJssStyle = () => {
|
|
|
6632
6745
|
zIndex: -1,
|
|
6633
6746
|
position: 'absolute',
|
|
6634
6747
|
inset: `calc(${paddingBlock} - ${offset}) calc(${dialogPaddingInline} - ${offset})`,
|
|
6635
|
-
background:
|
|
6748
|
+
background: colorFrosted,
|
|
6636
6749
|
borderRadius: radius3Xl,
|
|
6637
6750
|
...frostedGlassStyle,
|
|
6638
6751
|
},
|
|
@@ -6675,7 +6788,6 @@ const getComponentCss$V = (isOpen, background, backdrop, position, hasHeader, ha
|
|
|
6675
6788
|
[`${cssVarRefPaddingBottom$2}`]: dialogPaddingBottom,
|
|
6676
6789
|
[`${cssVarRefPaddingInline$2}`]: dialogPaddingInline,
|
|
6677
6790
|
...dialogHostJssStyle(background),
|
|
6678
|
-
...colorSchemeStyles,
|
|
6679
6791
|
...hostHiddenStyles,
|
|
6680
6792
|
}),
|
|
6681
6793
|
},
|
|
@@ -6750,7 +6862,6 @@ const getComponentCss$U = (size, align, color, ellipsis) => {
|
|
|
6750
6862
|
':host': {
|
|
6751
6863
|
display: 'block',
|
|
6752
6864
|
...addImportantToEachRule({
|
|
6753
|
-
...colorSchemeStyles,
|
|
6754
6865
|
...hostHiddenStyles,
|
|
6755
6866
|
}),
|
|
6756
6867
|
},
|
|
@@ -6758,7 +6869,7 @@ const getComponentCss$U = (size, align, color, ellipsis) => {
|
|
|
6758
6869
|
},
|
|
6759
6870
|
root: getTypographyRootJssStyle(headingXXLargeStyle, buildResponsiveStyles(size, (sizeValue) => ({
|
|
6760
6871
|
fontSize: sizeValue === 'inherit' ? sizeValue : sizeMap$3[sizeValue],
|
|
6761
|
-
fontWeight: sizeValue === 'small' ? fontWeightSemiBold : fontWeightRegular
|
|
6872
|
+
fontWeight: sizeValue === 'small' ? fontWeightSemiBold : fontWeightRegular,
|
|
6762
6873
|
})), align, color, ellipsis),
|
|
6763
6874
|
});
|
|
6764
6875
|
};
|
|
@@ -6779,16 +6890,15 @@ const buildIconUrl = (iconNameOrSource = DEFAULT_ICON_NAME) => {
|
|
|
6779
6890
|
return buildIconUrl(DEFAULT_ICON_NAME);
|
|
6780
6891
|
};
|
|
6781
6892
|
|
|
6782
|
-
const { primaryColor: primaryColor$k, contrastLowColor: contrastLowColor$3, contrastMediumColor: contrastMediumColor$5, contrastHighColor: contrastHighColor$4, successColor: successColor$1, errorColor, warningColor, infoColor, } = colors;
|
|
6783
6893
|
const colorMap$1 = {
|
|
6784
|
-
primary:
|
|
6785
|
-
'contrast-high':
|
|
6786
|
-
'contrast-medium':
|
|
6787
|
-
'contrast-low':
|
|
6788
|
-
success:
|
|
6789
|
-
warning:
|
|
6790
|
-
error:
|
|
6791
|
-
info:
|
|
6894
|
+
primary: colorPrimary,
|
|
6895
|
+
'contrast-high': colorContrastHigh,
|
|
6896
|
+
'contrast-medium': colorContrastMedium,
|
|
6897
|
+
'contrast-low': colorContrastLow,
|
|
6898
|
+
success: colorSuccess,
|
|
6899
|
+
warning: colorWarning,
|
|
6900
|
+
error: colorError,
|
|
6901
|
+
info: colorInfo,
|
|
6792
6902
|
inherit: 'inherit',
|
|
6793
6903
|
};
|
|
6794
6904
|
const sizeMap$2 = {
|
|
@@ -6836,16 +6946,15 @@ const getComponentCss$T = (name, source, color, size) => {
|
|
|
6836
6946
|
font: `${isSizeInherit ? sizeMap$2.small : sizeMap$2[size]} ${fontFamily}`,
|
|
6837
6947
|
color: colorMap$1[color],
|
|
6838
6948
|
...addImportantToEachRule({
|
|
6839
|
-
WebkitMask: `url(${buildIconUrl(source || name)}) center/contain no-repeat`, // necessary for Sogou browser support :-)
|
|
6840
|
-
mask: `url(${buildIconUrl(source || name)}) center/contain no-repeat`,
|
|
6949
|
+
WebkitMask: `url("${buildIconUrl(source || name)}") center/contain no-repeat`, // necessary for Sogou browser support :-)
|
|
6950
|
+
mask: `url("${buildIconUrl(source || name)}") center/contain no-repeat`,
|
|
6841
6951
|
aspectRatio: '1/1',
|
|
6842
6952
|
background: 'currentcolor', // necessary for proper color inheritance
|
|
6843
6953
|
...(isFlippableIcon(name, source) && {
|
|
6844
|
-
'
|
|
6954
|
+
'&(:dir(rtl))': {
|
|
6845
6955
|
transform: 'scaleX(-1)',
|
|
6846
6956
|
},
|
|
6847
6957
|
}),
|
|
6848
|
-
...colorSchemeStyles,
|
|
6849
6958
|
...hostHiddenStyles,
|
|
6850
6959
|
}),
|
|
6851
6960
|
},
|
|
@@ -6864,13 +6973,12 @@ const getComponentCss$T = (name, source, color, size) => {
|
|
|
6864
6973
|
|
|
6865
6974
|
const mediaQueryMinS$1 = getMediaQueryMin('s');
|
|
6866
6975
|
const mediaQueryMaxS$2 = getMediaQueryMax('s');
|
|
6867
|
-
const { infoFrostedColor: infoFrostedColor$1, successFrostedColor: successFrostedColor$1, errorFrostedColor: errorFrostedColor$1, warningFrostedColor: warningFrostedColor$1 } = colors;
|
|
6868
6976
|
const getBackgroundColor = (state) => {
|
|
6869
6977
|
const colorMap = {
|
|
6870
|
-
info:
|
|
6871
|
-
warning:
|
|
6872
|
-
success:
|
|
6873
|
-
error:
|
|
6978
|
+
info: colorInfoFrosted,
|
|
6979
|
+
warning: colorWarningFrosted,
|
|
6980
|
+
success: colorSuccessFrosted,
|
|
6981
|
+
error: colorErrorFrosted,
|
|
6874
6982
|
};
|
|
6875
6983
|
return colorMap[state];
|
|
6876
6984
|
};
|
|
@@ -6907,10 +7015,9 @@ const getNotificationContentJssStyle = () => ({
|
|
|
6907
7015
|
});
|
|
6908
7016
|
|
|
6909
7017
|
const mediaQueryMaxS$1 = getMediaQueryMax('s');
|
|
6910
|
-
const { primaryColor: primaryColor$j } = colors;
|
|
6911
7018
|
const getTextJssStyle = {
|
|
6912
7019
|
margin: 0,
|
|
6913
|
-
color:
|
|
7020
|
+
color: colorPrimary,
|
|
6914
7021
|
};
|
|
6915
7022
|
const getHeadingJssStyle = {
|
|
6916
7023
|
...headingSmallStyle,
|
|
@@ -6927,7 +7034,6 @@ const getComponentCss$S = (state, hasAction, hasClose) => {
|
|
|
6927
7034
|
display: 'grid',
|
|
6928
7035
|
...addImportantToEachRule({
|
|
6929
7036
|
...getNotificationRootJssStyle(state, hasAction, hasClose),
|
|
6930
|
-
...colorSchemeStyles,
|
|
6931
7037
|
...hostHiddenStyles,
|
|
6932
7038
|
}),
|
|
6933
7039
|
},
|
|
@@ -7114,7 +7220,6 @@ const getComponentCss$L = (disabled, loading, hideLabel, state, compact, readOnl
|
|
|
7114
7220
|
return getCss(getFunctionalComponentInputBaseStyles(disabled, loading, hideLabel, state, compact, readOnly));
|
|
7115
7221
|
};
|
|
7116
7222
|
|
|
7117
|
-
const { contrastMediumColor: contrastMediumColor$4 } = colors;
|
|
7118
7223
|
const formElementLayeredGap = '9px'; // to have same distance vertically and horizontally for e.g. button/icon within form element
|
|
7119
7224
|
// TODO: basic button/icon padding can already be set within style function instead of on component style level
|
|
7120
7225
|
const formButtonOrIconPadding = spacingStaticXSmall;
|
|
@@ -7137,7 +7242,7 @@ const getUnitCounterJssStyle = () => {
|
|
|
7137
7242
|
overflow: 'hidden',
|
|
7138
7243
|
textOverflow: 'ellipsis',
|
|
7139
7244
|
font: textSmallStyle.font,
|
|
7140
|
-
color:
|
|
7245
|
+
color: colorContrastHigh,
|
|
7141
7246
|
};
|
|
7142
7247
|
};
|
|
7143
7248
|
|
|
@@ -7274,7 +7379,6 @@ const getMultilineEllipsis = (lineClamp) => {
|
|
|
7274
7379
|
/**
|
|
7275
7380
|
* @css-variable {"name": "--p-hyphens", "description": "Sets the CSS `hyphens` property for text elements, controlling whether words can break and hyphenate automatically.", "defaultValue": "auto"}
|
|
7276
7381
|
*/
|
|
7277
|
-
const { primaryColor: primaryColor$i, contrastHighColor: contrastHighColor$3, contrastMediumColor: contrastMediumColor$3, surfaceColor } = colors;
|
|
7278
7382
|
const getComponentCss$F = (hasLikeButton, hasSlottedAnchor, hasPriceOriginal, hasDescription, aspectRatio) => {
|
|
7279
7383
|
return getCss({
|
|
7280
7384
|
'@global': {
|
|
@@ -7282,7 +7386,6 @@ const getComponentCss$F = (hasLikeButton, hasSlottedAnchor, hasPriceOriginal, ha
|
|
|
7282
7386
|
display: 'block',
|
|
7283
7387
|
position: 'relative', // needed for ::slotted(a) to overlay correctly
|
|
7284
7388
|
...addImportantToEachRule({
|
|
7285
|
-
...colorSchemeStyles,
|
|
7286
7389
|
...hostHiddenStyles,
|
|
7287
7390
|
}),
|
|
7288
7391
|
},
|
|
@@ -7316,7 +7419,7 @@ const getComponentCss$F = (hasLikeButton, hasSlottedAnchor, hasPriceOriginal, ha
|
|
|
7316
7419
|
}),
|
|
7317
7420
|
...(hasPriceOriginal && {
|
|
7318
7421
|
s: {
|
|
7319
|
-
color:
|
|
7422
|
+
color: colorContrastMedium,
|
|
7320
7423
|
},
|
|
7321
7424
|
}),
|
|
7322
7425
|
},
|
|
@@ -7328,8 +7431,8 @@ const getComponentCss$F = (hasLikeButton, hasSlottedAnchor, hasPriceOriginal, ha
|
|
|
7328
7431
|
boxSizing: 'border-box',
|
|
7329
7432
|
borderRadius: `var(${legacyRadiusLarge}, ${radius4Xl})`,
|
|
7330
7433
|
padding: spacingFluidSmall,
|
|
7331
|
-
color:
|
|
7332
|
-
backgroundColor:
|
|
7434
|
+
color: colorPrimary,
|
|
7435
|
+
backgroundColor: colorSurface,
|
|
7333
7436
|
...buildResponsiveStyles(aspectRatio, (ratio) => ({
|
|
7334
7437
|
aspectRatio: ratio,
|
|
7335
7438
|
})),
|
|
@@ -7393,7 +7496,7 @@ const getComponentCss$F = (hasLikeButton, hasSlottedAnchor, hasPriceOriginal, ha
|
|
|
7393
7496
|
margin: 0, // ua-style reset
|
|
7394
7497
|
...textXXSmallStyle,
|
|
7395
7498
|
...getMultilineEllipsis(2),
|
|
7396
|
-
color:
|
|
7499
|
+
color: colorContrastHigh,
|
|
7397
7500
|
},
|
|
7398
7501
|
}),
|
|
7399
7502
|
...(hasPriceOriginal && {
|
|
@@ -7406,7 +7509,6 @@ const getComponentCss$F = (hasLikeButton, hasSlottedAnchor, hasPriceOriginal, ha
|
|
|
7406
7509
|
/**
|
|
7407
7510
|
* @css-variable {"name": "--p-hyphens", "description": "Sets the CSS `hyphens` property for text elements, controlling whether words can break and hyphenate automatically.", "defaultValue": "auto"}
|
|
7408
7511
|
*/
|
|
7409
|
-
const { canvasColor: canvasColor$2, primaryColor: primaryColor$h } = colors;
|
|
7410
7512
|
const getComponentCss$E = (aspectRatio, size, weight, align, compact, hasGradient, hasFooterSlot, isDisabled) => {
|
|
7411
7513
|
const isTopAligned = align === 'top';
|
|
7412
7514
|
return getCss({
|
|
@@ -7414,13 +7516,13 @@ const getComponentCss$E = (aspectRatio, size, weight, align, compact, hasGradien
|
|
|
7414
7516
|
':host': {
|
|
7415
7517
|
display: 'flex',
|
|
7416
7518
|
alignItems: 'stretch',
|
|
7519
|
+
colorScheme: 'dark', // dark is used in 99% of the cases (it can still be overridden by the user via `color-scheme`)
|
|
7417
7520
|
// Safari workaround to scale the tile properly
|
|
7418
7521
|
'@supports (-webkit-hyphens: auto)': {
|
|
7419
7522
|
alignItems: 'baseline',
|
|
7420
7523
|
},
|
|
7421
7524
|
hyphens: 'auto', // TODO: shouldn't we expose a CSS variable instead?
|
|
7422
7525
|
...addImportantToEachRule({
|
|
7423
|
-
...colorSchemeStyles,
|
|
7424
7526
|
...hostHiddenStyles,
|
|
7425
7527
|
}),
|
|
7426
7528
|
},
|
|
@@ -7459,7 +7561,7 @@ const getComponentCss$E = (aspectRatio, size, weight, align, compact, hasGradien
|
|
|
7459
7561
|
zIndex: 3,
|
|
7460
7562
|
maxWidth: '34.375rem',
|
|
7461
7563
|
...textMediumStyle,
|
|
7462
|
-
color:
|
|
7564
|
+
color: colorPrimary,
|
|
7463
7565
|
hyphens: 'inherit',
|
|
7464
7566
|
...mergeDeep(buildResponsiveStyles(size, (sizeValue) => ({
|
|
7465
7567
|
fontSize: getFontSizeText(sizeValue),
|
|
@@ -7487,14 +7589,14 @@ const getComponentCss$E = (aspectRatio, size, weight, align, compact, hasGradien
|
|
|
7487
7589
|
...(isTopAligned
|
|
7488
7590
|
? {
|
|
7489
7591
|
gridArea: '1/1/3/-1',
|
|
7490
|
-
background: gradientToBottomStyle.background.replaceAll('0,0%,0%,', `from ${
|
|
7592
|
+
background: gradientToBottomStyle.background.replaceAll('0,0%,0%,', `from ${colorCanvas} h s l / `),
|
|
7491
7593
|
marginBottom: `calc(${spacingFluidLarge} * -1)`, // to increase the gradient area without reserving additional layout space
|
|
7492
7594
|
borderStartStartRadius: 'inherit',
|
|
7493
7595
|
borderStartEndRadius: 'inherit',
|
|
7494
7596
|
}
|
|
7495
7597
|
: {
|
|
7496
7598
|
gridArea: '4/1/6/-1',
|
|
7497
|
-
background: gradientToTopStyle.background.replaceAll('0,0%,0%,', `from ${
|
|
7599
|
+
background: gradientToTopStyle.background.replaceAll('0,0%,0%,', `from ${colorCanvas} h s l / `),
|
|
7498
7600
|
marginTop: `calc(${spacingFluidLarge} * -1)`, // to increase the gradient area without reserving additional layout space
|
|
7499
7601
|
borderEndStartRadius: 'inherit',
|
|
7500
7602
|
borderEndEndRadius: 'inherit',
|
|
@@ -7531,8 +7633,8 @@ const getComponentCss$E = (aspectRatio, size, weight, align, compact, hasGradien
|
|
|
7531
7633
|
'link-or-button-pure': {
|
|
7532
7634
|
zIndex: 5,
|
|
7533
7635
|
gridColumn: 2,
|
|
7534
|
-
gridRow: hasFooterSlot
|
|
7535
|
-
alignSelf: '
|
|
7636
|
+
gridRow: `1/${hasFooterSlot ? 3 : 2}`,
|
|
7637
|
+
alignSelf: isTopAligned ? 'flex-start' : 'flex-end',
|
|
7536
7638
|
...buildResponsiveStyles(compact, (compactValue) => ({
|
|
7537
7639
|
display: compactValue ? 'inline-block' : 'none',
|
|
7538
7640
|
})),
|
|
@@ -7612,7 +7714,6 @@ const getComponentCss$C = (isOpen, background, backdrop, fullscreen, hasDismissB
|
|
|
7612
7714
|
[`${cssVarRefPaddingBottom$1}`]: dialogPaddingBottom,
|
|
7613
7715
|
[`${cssVarRefPaddingInline$1}`]: dialogPaddingInline,
|
|
7614
7716
|
...dialogHostJssStyle(background),
|
|
7615
|
-
...colorSchemeStyles,
|
|
7616
7717
|
...hostHiddenStyles,
|
|
7617
7718
|
}),
|
|
7618
7719
|
},
|
|
@@ -7668,12 +7769,11 @@ const getSvgUrl = (model) => {
|
|
|
7668
7769
|
const cssVariableWidth = '--p-model-signature-width';
|
|
7669
7770
|
const cssVariableHeight = '--p-model-signature-height';
|
|
7670
7771
|
const cssVariableColor = '--p-model-signature-color';
|
|
7671
|
-
const { primaryColor: primaryColor$g, contrastLowColor: contrastLowColor$2, contrastMediumColor: contrastMediumColor$2, contrastHighColor: contrastHighColor$2 } = colors;
|
|
7672
7772
|
const colorMap = {
|
|
7673
|
-
primary:
|
|
7674
|
-
'contrast-low':
|
|
7675
|
-
'contrast-medium':
|
|
7676
|
-
'contrast-high':
|
|
7773
|
+
primary: colorPrimary,
|
|
7774
|
+
'contrast-low': colorContrastLow,
|
|
7775
|
+
'contrast-medium': colorContrastMedium,
|
|
7776
|
+
'contrast-high': colorContrastHigh,
|
|
7677
7777
|
inherit: 'inherit',
|
|
7678
7778
|
};
|
|
7679
7779
|
const getComponentCss$B = (model, safeZone, size, color) => {
|
|
@@ -7694,7 +7794,6 @@ const getComponentCss$B = (model, safeZone, size, color) => {
|
|
|
7694
7794
|
mask: `url(${getSvgUrl(model)}) no-repeat left top / contain`,
|
|
7695
7795
|
aspectRatio: `${width} / ${safeZone ? 36 : height}`, // 36px is the max-height for SVG model signature creation
|
|
7696
7796
|
background: 'currentcolor', // necessary for proper color inheritance
|
|
7697
|
-
...colorSchemeStyles,
|
|
7698
7797
|
...hostHiddenStyles,
|
|
7699
7798
|
}),
|
|
7700
7799
|
},
|
|
@@ -7741,7 +7840,7 @@ const getComponentCss$A = (isDisabled, selected) => {
|
|
|
7741
7840
|
},
|
|
7742
7841
|
},
|
|
7743
7842
|
option: getOptionJssStyle('multi-select-option', cssVarInternalMultiSelectOptionScaling),
|
|
7744
|
-
checkbox: mergeDeep(getCheckboxBaseStyles(isDisabled, false, true, 'none'), selected ? getCheckboxCheckedBaseStyles(false) : {}),
|
|
7843
|
+
checkbox: mergeDeep(getCheckboxBaseStyles(isDisabled, false, true, 'none'), selected ? getCheckboxCheckedBaseStyles(false, 'none') : {}),
|
|
7745
7844
|
});
|
|
7746
7845
|
};
|
|
7747
7846
|
|
|
@@ -7750,12 +7849,10 @@ const paddingBlock = `calc(11.2px * (var(${cssVarInternalOptgroupScaling}) - 0.6
|
|
|
7750
7849
|
const paddingInline = `calc(16.8px * (var(${cssVarInternalOptgroupScaling}) - 0.64285714) + 6px)`;
|
|
7751
7850
|
const gap = `calc(11.2px * (var(${cssVarInternalOptgroupScaling}) - 0.64285714) + 4px)`;
|
|
7752
7851
|
const paddingSlottedInlineStart = `calc(44.8px * (var(${cssVarInternalOptgroupScaling}) - 0.64285714) + 12px)`;
|
|
7753
|
-
const { primaryColor: primaryColor$f } = colors;
|
|
7754
7852
|
const getComponentCss$z = (isDisabled) => {
|
|
7755
7853
|
return getCss({
|
|
7756
7854
|
'@global': {
|
|
7757
7855
|
':host': addImportantToEachRule({
|
|
7758
|
-
...colorSchemeStyles,
|
|
7759
7856
|
...hostHiddenStyles,
|
|
7760
7857
|
...(isDisabled && getDisabledBaseStyles()),
|
|
7761
7858
|
}),
|
|
@@ -7772,7 +7869,7 @@ const getComponentCss$z = (isDisabled) => {
|
|
|
7772
7869
|
paddingBlock,
|
|
7773
7870
|
paddingInline,
|
|
7774
7871
|
font: textXSmallStyle.font.replace(' 400 ', ` ${fontWeightSemiBold} `),
|
|
7775
|
-
color:
|
|
7872
|
+
color: colorPrimary,
|
|
7776
7873
|
},
|
|
7777
7874
|
},
|
|
7778
7875
|
});
|
|
@@ -7794,11 +7891,11 @@ const getComponentCss$y = (isOpen, isDisabled, hideLabel, state, isCompact) => {
|
|
|
7794
7891
|
[`${cssVarInternalMultiSelectScaling}`]: isCompact ? 0.64285714 : 1,
|
|
7795
7892
|
[`${cssVarInternalMultiSelectOptionScaling}`]: isCompact ? 0.64285714 : 1,
|
|
7796
7893
|
[`${cssVarInternalOptgroupScaling}`]: isCompact ? 0.64285714 : 1,
|
|
7797
|
-
...colorSchemeStyles,
|
|
7798
7894
|
...hostHiddenStyles,
|
|
7799
7895
|
...(isDisabled && getDisabledBaseStyles()),
|
|
7800
7896
|
}),
|
|
7801
7897
|
},
|
|
7898
|
+
...getFunctionalComponentLabelAfterStyles(isDisabled),
|
|
7802
7899
|
...preventFoucOfNestedElementsStyles,
|
|
7803
7900
|
button: {
|
|
7804
7901
|
...getButtonJssStyle('multi-select', isOpen, isDisabled, state, isCompact, cssVarInternalMultiSelectScaling),
|
|
@@ -7837,13 +7934,11 @@ const disabledCursorStyle = {
|
|
|
7837
7934
|
};
|
|
7838
7935
|
const hiddenStyle = { display: 'none' };
|
|
7839
7936
|
const getComponentCss$x = (activePage, pageTotal, showLastPage) => {
|
|
7840
|
-
const { primaryColor, disabledColor, frostedColor } = colors;
|
|
7841
7937
|
return getCss({
|
|
7842
7938
|
'@global': {
|
|
7843
7939
|
':host': {
|
|
7844
7940
|
display: 'block',
|
|
7845
7941
|
...addImportantToEachRule({
|
|
7846
|
-
...colorSchemeStyles,
|
|
7847
7942
|
...hostHiddenStyles,
|
|
7848
7943
|
}),
|
|
7849
7944
|
},
|
|
@@ -7915,24 +8010,24 @@ const getComponentCss$x = (activePage, pageTotal, showLastPage) => {
|
|
|
7915
8010
|
...textSmallStyle,
|
|
7916
8011
|
whiteSpace: 'nowrap',
|
|
7917
8012
|
cursor: 'pointer',
|
|
7918
|
-
color:
|
|
8013
|
+
color: colorPrimary,
|
|
7919
8014
|
borderRadius: `var(${legacyRadiusSmall}, ${radiusSm})`,
|
|
7920
8015
|
borderColor: 'transparent', // default value is needed for smooth transition
|
|
7921
8016
|
outline: 0, // TODO: only relevant for VRT testing with forced states - prevents :focus style
|
|
7922
8017
|
...hoverMediaQuery({
|
|
7923
8018
|
'&:not([aria-disabled]):not(.ellipsis):hover': {
|
|
7924
8019
|
...frostedGlassStyle,
|
|
7925
|
-
background:
|
|
8020
|
+
background: colorFrosted,
|
|
7926
8021
|
},
|
|
7927
8022
|
}),
|
|
7928
8023
|
'&[aria-current]': {
|
|
7929
8024
|
...disabledCursorStyle,
|
|
7930
|
-
color:
|
|
7931
|
-
border: `${borderWidthBase} solid ${
|
|
8025
|
+
color: colorPrimary,
|
|
8026
|
+
border: `${borderWidthBase} solid ${colorPrimary}`,
|
|
7932
8027
|
},
|
|
7933
8028
|
'&[aria-disabled]': {
|
|
8029
|
+
...getDisabledBaseStyles(),
|
|
7934
8030
|
...disabledCursorStyle,
|
|
7935
|
-
color: disabledColor,
|
|
7936
8031
|
},
|
|
7937
8032
|
// TODO :not(.ellipsis) is only needed for VRT states tests to work properly
|
|
7938
8033
|
'&:not(.ellipsis):focus-visible': getFocusBaseStyles(),
|
|
@@ -7948,7 +8043,6 @@ const getComponentCss$x = (activePage, pageTotal, showLastPage) => {
|
|
|
7948
8043
|
};
|
|
7949
8044
|
|
|
7950
8045
|
const cssVarInternalPinCodeScaling = '--p-internal-pin-code-scaling';
|
|
7951
|
-
const { primaryColor: primaryColor$e } = colors;
|
|
7952
8046
|
// CSS Variable defined in fontHyphenationStyle
|
|
7953
8047
|
/**
|
|
7954
8048
|
* @css-variable {"name": "--p-hyphens", "description": "Sets the CSS `hyphens` property for text elements, controlling whether words can break and hyphenate automatically.", "defaultValue": "auto"}
|
|
@@ -7966,11 +8060,11 @@ const getComponentCss$w = (hideLabel, state, isDisabled, isLoading, length, isCo
|
|
|
7966
8060
|
display: 'block',
|
|
7967
8061
|
[`${cssVarInternalPinCodeScaling}`]: isCompact ? 0.64285714 : 1,
|
|
7968
8062
|
...addImportantToEachRule({
|
|
7969
|
-
...colorSchemeStyles,
|
|
7970
8063
|
...hostHiddenStyles,
|
|
7971
8064
|
...(isDisabled && getDisabledBaseStyles()),
|
|
7972
8065
|
}),
|
|
7973
8066
|
},
|
|
8067
|
+
...getFunctionalComponentLabelAfterStyles(isDisabled),
|
|
7974
8068
|
...preventFoucOfNestedElementsStyles,
|
|
7975
8069
|
input: {
|
|
7976
8070
|
all: 'unset',
|
|
@@ -7985,28 +8079,26 @@ const getComponentCss$w = (hideLabel, state, isDisabled, isLoading, length, isCo
|
|
|
7985
8079
|
borderRadius: `var(${legacyRadiusSmall}, ${isCompact ? radiusLg : radiusXl})`,
|
|
7986
8080
|
background: formStateBackgroundColor,
|
|
7987
8081
|
font: textSmallStyle.font.replace('ex', 'ex + 6px'), // a minimum line-height is needed for input, otherwise value is scrollable in Chrome, +6px is aligned with how Safari visualize date/time input highlighting
|
|
7988
|
-
color:
|
|
8082
|
+
color: colorPrimary,
|
|
7989
8083
|
transition: `${getTransition('background-color')}, ${getTransition('border-color')}`,
|
|
7990
8084
|
textOverflow: 'ellipsis',
|
|
7991
|
-
cursor: isDisabled ? 'not-allowed' : 'text',
|
|
8085
|
+
cursor: isDisabled || isLoading ? 'not-allowed' : 'text',
|
|
7992
8086
|
textAlign: 'center',
|
|
7993
|
-
...(isLoading &&
|
|
7994
|
-
opacity: 0.2, // TODO: not in sync with e.g. checkbox/radio-button loading style
|
|
7995
|
-
cursor: 'not-allowed',
|
|
7996
|
-
}),
|
|
8087
|
+
...(isLoading && getDisabledBaseStyles()),
|
|
7997
8088
|
'&:focus-visible': {
|
|
7998
8089
|
borderColor: formStateBorderHoverColor,
|
|
7999
8090
|
},
|
|
8000
8091
|
...(!isLoading &&
|
|
8001
8092
|
!isDisabled &&
|
|
8002
8093
|
hoverMediaQuery({
|
|
8003
|
-
'&:hover
|
|
8094
|
+
'&:hover': {
|
|
8004
8095
|
borderColor: formStateBorderHoverColor,
|
|
8005
8096
|
},
|
|
8006
8097
|
})),
|
|
8007
8098
|
},
|
|
8008
8099
|
},
|
|
8009
8100
|
root: {
|
|
8101
|
+
all: 'unset',
|
|
8010
8102
|
display: 'grid',
|
|
8011
8103
|
gap: spacingStaticXSmall,
|
|
8012
8104
|
},
|
|
@@ -8044,7 +8136,6 @@ const POPOVER_SAFE_ZONE = 8;
|
|
|
8044
8136
|
* @css-variable {"name": "--p-hyphens", "description": "Sets the CSS `hyphens` property for text elements, controlling whether words can break and hyphenate automatically.", "defaultValue": "auto"}
|
|
8045
8137
|
*/
|
|
8046
8138
|
const getComponentCss$v = () => {
|
|
8047
|
-
const { frostedSoftColor, frostedColor, canvasColor, primaryColor } = colors;
|
|
8048
8139
|
const shadowColor = 'rgba(0,0,0,0.3)';
|
|
8049
8140
|
return getCss({
|
|
8050
8141
|
'@global': {
|
|
@@ -8061,7 +8152,6 @@ const getComponentCss$v = () => {
|
|
|
8061
8152
|
display: 'inline-block',
|
|
8062
8153
|
verticalAlign: 'top',
|
|
8063
8154
|
...addImportantToEachRule({
|
|
8064
|
-
...colorSchemeStyles,
|
|
8065
8155
|
...hostHiddenStyles,
|
|
8066
8156
|
}),
|
|
8067
8157
|
},
|
|
@@ -8081,12 +8171,12 @@ const getComponentCss$v = () => {
|
|
|
8081
8171
|
height: fontLineHeight, // height needed to improve ssr support
|
|
8082
8172
|
borderRadius: radiusFull,
|
|
8083
8173
|
cursor: 'pointer',
|
|
8084
|
-
backgroundColor:
|
|
8174
|
+
backgroundColor: colorFrosted,
|
|
8085
8175
|
transition: getTransition('background-color'),
|
|
8086
8176
|
...frostedGlassStyle,
|
|
8087
8177
|
...hoverMediaQuery({
|
|
8088
8178
|
'&:hover': {
|
|
8089
|
-
backgroundColor:
|
|
8179
|
+
backgroundColor: colorFrostedSoft,
|
|
8090
8180
|
},
|
|
8091
8181
|
}),
|
|
8092
8182
|
'&:focus-visible': getFocusBaseStyles(),
|
|
@@ -8112,7 +8202,7 @@ const getComponentCss$v = () => {
|
|
|
8112
8202
|
width: '24px',
|
|
8113
8203
|
height: '12px',
|
|
8114
8204
|
clipPath: 'polygon(50% 0, 100% 110%, 0 110%)',
|
|
8115
|
-
background:
|
|
8205
|
+
background: colorCanvas,
|
|
8116
8206
|
},
|
|
8117
8207
|
content: {
|
|
8118
8208
|
maxWidth: `min(calc(100dvw - ${POPOVER_SAFE_ZONE * 2}px), 48ch)`,
|
|
@@ -8122,15 +8212,14 @@ const getComponentCss$v = () => {
|
|
|
8122
8212
|
pointerEvents: 'auto',
|
|
8123
8213
|
borderRadius: `var(${legacyRadiusSmall}, ${radiusLg})`,
|
|
8124
8214
|
...textSmallStyle,
|
|
8125
|
-
background:
|
|
8126
|
-
color:
|
|
8215
|
+
background: colorCanvas,
|
|
8216
|
+
color: colorPrimary,
|
|
8127
8217
|
},
|
|
8128
8218
|
});
|
|
8129
8219
|
};
|
|
8130
8220
|
|
|
8131
8221
|
const cssVarInternalRadioGroupOptionScaling = '--p-internal-radio-group-option-scaling';
|
|
8132
8222
|
const checkedIcon = getInlineSVGBackgroundImage(`<circle cx="12" cy="12" r="6"/>`);
|
|
8133
|
-
const { primaryColor: primaryColor$d } = colors;
|
|
8134
8223
|
// CSS Variable defined in fontHyphenationStyle
|
|
8135
8224
|
/**
|
|
8136
8225
|
* @css-variable {"name": "--p-hyphens", "description": "Sets the CSS `hyphens` property for text elements, controlling whether words can break and hyphenate automatically.", "defaultValue": "auto"}
|
|
@@ -8149,11 +8238,11 @@ const getComponentCss$u = (disabled, loading, state) => {
|
|
|
8149
8238
|
':host': {
|
|
8150
8239
|
display: 'block',
|
|
8151
8240
|
...addImportantToEachRule({
|
|
8152
|
-
...colorSchemeStyles,
|
|
8153
8241
|
...hostHiddenStyles,
|
|
8154
|
-
...(
|
|
8242
|
+
...(disabledOrLoading && getDisabledBaseStyles()),
|
|
8155
8243
|
}),
|
|
8156
8244
|
},
|
|
8245
|
+
...getFunctionalComponentLabelAfterStyles(disabledOrLoading),
|
|
8157
8246
|
...preventFoucOfNestedElementsStyles,
|
|
8158
8247
|
input: {
|
|
8159
8248
|
all: 'unset',
|
|
@@ -8173,7 +8262,7 @@ const getComponentCss$u = (disabled, loading, state) => {
|
|
|
8173
8262
|
'&:focus-visible': getFocusBaseStyles(),
|
|
8174
8263
|
...(!disabledOrLoading &&
|
|
8175
8264
|
hoverMediaQuery({
|
|
8176
|
-
'&:hover
|
|
8265
|
+
'&:hover': {
|
|
8177
8266
|
borderColor: formStateBorderHoverColor,
|
|
8178
8267
|
},
|
|
8179
8268
|
})),
|
|
@@ -8185,7 +8274,7 @@ const getComponentCss$u = (disabled, loading, state) => {
|
|
|
8185
8274
|
'&:checked::before': {
|
|
8186
8275
|
WebkitMask: `${checkedIcon} center/contain no-repeat`, // necessary for Sogou browser support :-)
|
|
8187
8276
|
mask: `${checkedIcon} center/contain no-repeat`,
|
|
8188
|
-
backgroundColor:
|
|
8277
|
+
backgroundColor: state === 'none' ? colorPrimary : formStateBorderColor,
|
|
8189
8278
|
},
|
|
8190
8279
|
'&::after': {
|
|
8191
8280
|
// Ensures the touch target is at least 24px, even if the checkbox is smaller than the minimum touch target size.
|
|
@@ -8221,9 +8310,7 @@ const getComponentCss$u = (disabled, loading, state) => {
|
|
|
8221
8310
|
},
|
|
8222
8311
|
}),
|
|
8223
8312
|
// .label / .required
|
|
8224
|
-
...getFunctionalComponentLabelStyles(disabled || loading, false, {
|
|
8225
|
-
gridArea: '1/2',
|
|
8226
|
-
}, {
|
|
8313
|
+
...getFunctionalComponentLabelStyles(disabled || loading, false, null, {
|
|
8227
8314
|
paddingTop: labelPaddingTop,
|
|
8228
8315
|
paddingInlineStart: labelPaddingInlineStart,
|
|
8229
8316
|
}),
|
|
@@ -8258,15 +8345,17 @@ const getComponentCss$t = (isDisabled, isLoading, hideLabel, state, isCompact, d
|
|
|
8258
8345
|
'@global': {
|
|
8259
8346
|
':host': {
|
|
8260
8347
|
...addImportantToEachRule({
|
|
8261
|
-
...colorSchemeStyles,
|
|
8262
8348
|
...hostHiddenStyles,
|
|
8263
8349
|
}),
|
|
8264
8350
|
[`${cssVarInternalRadioGroupScaling}`]: isCompact ? 0.64285714 : 1,
|
|
8265
8351
|
[`${cssVarInternalRadioGroupOptionScaling}`]: isCompact ? 0.64285714 : 1,
|
|
8266
8352
|
},
|
|
8267
|
-
|
|
8268
|
-
|
|
8269
|
-
|
|
8353
|
+
...getFunctionalComponentLabelAfterStyles(isDisabled, getDisabledBaseStyles()),
|
|
8354
|
+
...(isLoading && {
|
|
8355
|
+
'::slotted(*:not([slot]))': {
|
|
8356
|
+
...addImportantToEachRule(getDisabledBaseStyles()),
|
|
8357
|
+
},
|
|
8358
|
+
}),
|
|
8270
8359
|
...preventFoucOfNestedElementsStyles,
|
|
8271
8360
|
},
|
|
8272
8361
|
root: {
|
|
@@ -8296,10 +8385,7 @@ const getComponentCss$t = (isDisabled, isLoading, hideLabel, state, isCompact, d
|
|
|
8296
8385
|
}),
|
|
8297
8386
|
// .label / .required
|
|
8298
8387
|
...getFunctionalComponentLabelStyles(isDisabled, hideLabel, {
|
|
8299
|
-
cursor: 'inherit',
|
|
8300
|
-
'&:is(legend)': {
|
|
8301
|
-
marginBottom: spacingStaticXSmall, // this fixes a known layout bug of the legend element (in all browsers) when the parent fieldset is a flex or grid container
|
|
8302
|
-
},
|
|
8388
|
+
...(isDisabled ? getDisabledBaseStyles() : { cursor: 'inherit' }), // the label is not clickable
|
|
8303
8389
|
}),
|
|
8304
8390
|
// .message
|
|
8305
8391
|
...getFunctionalComponentStateMessageStyles(state),
|
|
@@ -8327,7 +8413,6 @@ const getComponentCss$s = (isNextHidden, isPrevHidden, alignScrollIndicator, has
|
|
|
8327
8413
|
display: 'block',
|
|
8328
8414
|
...addImportantToEachRule({
|
|
8329
8415
|
height: 'inherit',
|
|
8330
|
-
...colorSchemeStyles,
|
|
8331
8416
|
...hostHiddenStyles,
|
|
8332
8417
|
}),
|
|
8333
8418
|
},
|
|
@@ -8427,7 +8512,6 @@ const ICON_OFFSET = '4px';
|
|
|
8427
8512
|
const { font: BUTTON_FONT } = textSmallStyle;
|
|
8428
8513
|
const ICON_SIZE = '1.5rem';
|
|
8429
8514
|
const ICON_MARGIN = '.25rem';
|
|
8430
|
-
const { primaryColor: primaryColor$c, contrastMediumColor: contrastMediumColor$1 } = colors;
|
|
8431
8515
|
const getScalableItemStyles = (hasIconAndSlottedContent, compact) => {
|
|
8432
8516
|
const scalingVar = getScalingVar(compact);
|
|
8433
8517
|
const verticalPadding = `max(2px, ${formElementPaddingVertical} * ${scalingVar})`;
|
|
@@ -8467,7 +8551,7 @@ const getComponentCss$r = (isCompact, isDisabled, isSelected, state, hasIcon, ha
|
|
|
8467
8551
|
border: `${borderWidthThin} solid ${isSelected ? formStateBorderHoverColor : formStateBorderColor}`,
|
|
8468
8552
|
borderRadius: `var(${legacyRadiusSmall}, ${isCompact ? radiusLg : radiusXl})`,
|
|
8469
8553
|
background: formStateBackgroundColor,
|
|
8470
|
-
color:
|
|
8554
|
+
color: colorPrimary,
|
|
8471
8555
|
...textSmallStyle,
|
|
8472
8556
|
...(isDisabled
|
|
8473
8557
|
? {
|
|
@@ -8490,7 +8574,7 @@ const getComponentCss$r = (isCompact, isDisabled, isSelected, state, hasIcon, ha
|
|
|
8490
8574
|
display: 'block',
|
|
8491
8575
|
...textXSmallStyle,
|
|
8492
8576
|
overflowWrap: 'normal',
|
|
8493
|
-
color:
|
|
8577
|
+
color: colorContrastMedium,
|
|
8494
8578
|
},
|
|
8495
8579
|
},
|
|
8496
8580
|
...(hasIcon && {
|
|
@@ -8509,12 +8593,15 @@ const getComponentCss$q = (minWidth, maxWidth, columns, disabled, hideLabel, sta
|
|
|
8509
8593
|
'@global': {
|
|
8510
8594
|
':host': {
|
|
8511
8595
|
...addImportantToEachRule({
|
|
8512
|
-
...(disabled && getDisabledBaseStyles()),
|
|
8513
|
-
...colorSchemeStyles,
|
|
8514
8596
|
...hostHiddenStyles,
|
|
8515
8597
|
}),
|
|
8516
8598
|
},
|
|
8599
|
+
...getFunctionalComponentLabelAfterStyles(disabled),
|
|
8517
8600
|
...preventFoucOfNestedElementsStyles,
|
|
8601
|
+
...getFunctionalComponentLabelAfterStyles(disabled, getDisabledBaseStyles()),
|
|
8602
|
+
...(disabled && {
|
|
8603
|
+
'::slotted(*:not([slot]))': addImportantToEachRule(getDisabledBaseStyles()),
|
|
8604
|
+
}),
|
|
8518
8605
|
'slot:not([name])': {
|
|
8519
8606
|
display: 'grid',
|
|
8520
8607
|
gridAutoRows: '1fr', // for equal height
|
|
@@ -8533,10 +8620,7 @@ const getComponentCss$q = (minWidth, maxWidth, columns, disabled, hideLabel, sta
|
|
|
8533
8620
|
},
|
|
8534
8621
|
// .label / .required
|
|
8535
8622
|
...getFunctionalComponentLabelStyles(disabled, hideLabel, {
|
|
8536
|
-
cursor: 'inherit',
|
|
8537
|
-
'&:is(legend)': {
|
|
8538
|
-
marginBottom: spacingStaticXSmall, // this fixes a known layout bug of the legend element (in all browsers) when the parent fieldset is a flex or grid container
|
|
8539
|
-
},
|
|
8623
|
+
...(disabled ? getDisabledBaseStyles() : { cursor: 'inherit' }), // the label is not clickable
|
|
8540
8624
|
}),
|
|
8541
8625
|
// .message
|
|
8542
8626
|
...getFunctionalComponentStateMessageStyles(state),
|
|
@@ -8588,10 +8672,11 @@ const getComponentCss$o = (isOpen, isDisabled, hideLabel, state, isCompact) => {
|
|
|
8588
8672
|
[`${cssVarInternalSelectScaling}`]: isCompact ? 0.64285714 : 1,
|
|
8589
8673
|
[`${cssVarInternalSelectOptionScaling}`]: isCompact ? 0.64285714 : 1,
|
|
8590
8674
|
[`${cssVarInternalOptgroupScaling}`]: isCompact ? 0.64285714 : 1,
|
|
8591
|
-
...colorSchemeStyles,
|
|
8592
8675
|
...hostHiddenStyles,
|
|
8593
8676
|
}),
|
|
8677
|
+
...(isDisabled && getDisabledBaseStyles()),
|
|
8594
8678
|
},
|
|
8679
|
+
...getFunctionalComponentLabelAfterStyles(isDisabled),
|
|
8595
8680
|
...preventFoucOfNestedElementsStyles,
|
|
8596
8681
|
button: {
|
|
8597
8682
|
...getButtonJssStyle('select', isOpen, isDisabled, state, isCompact, cssVarInternalSelectScaling),
|
|
@@ -8642,7 +8727,6 @@ const getComponentCss$n = (isOpen, background, hasDismissButton) => {
|
|
|
8642
8727
|
[`${cssVarRefPaddingBottom}`]: dialogPaddingBottom,
|
|
8643
8728
|
[`${cssVarRefPaddingInline}`]: dialogPaddingInline,
|
|
8644
8729
|
...dialogHostJssStyle(background),
|
|
8645
|
-
...colorSchemeStyles,
|
|
8646
8730
|
...hostHiddenStyles,
|
|
8647
8731
|
}),
|
|
8648
8732
|
},
|
|
@@ -8683,7 +8767,6 @@ const sizeMap$1 = {
|
|
|
8683
8767
|
large: { height: sizeLarge, width: sizeLarge },
|
|
8684
8768
|
inherit: { height: 'inherit', width: 'inherit' },
|
|
8685
8769
|
};
|
|
8686
|
-
const { primaryColor: primaryColor$b, contrastLowerColor } = colors;
|
|
8687
8770
|
const getComponentCss$m = (size) => {
|
|
8688
8771
|
const strokeDasharray = '57'; // C = 2πR
|
|
8689
8772
|
const animationDuration = `var(${cssVariableAnimationDuration}, ${motionDurationVeryLong})`;
|
|
@@ -8715,7 +8798,6 @@ const getComponentCss$m = (size) => {
|
|
|
8715
8798
|
display: 'inline-flex',
|
|
8716
8799
|
...addImportantToEachRule({
|
|
8717
8800
|
verticalAlign: 'top',
|
|
8718
|
-
...colorSchemeStyles,
|
|
8719
8801
|
...hostHiddenStyles,
|
|
8720
8802
|
}),
|
|
8721
8803
|
},
|
|
@@ -8726,11 +8808,11 @@ const getComponentCss$m = (size) => {
|
|
|
8726
8808
|
},
|
|
8727
8809
|
circle: {
|
|
8728
8810
|
'&:first-child': {
|
|
8729
|
-
stroke:
|
|
8811
|
+
stroke: colorContrastLower,
|
|
8730
8812
|
},
|
|
8731
8813
|
'&:last-child': {
|
|
8732
8814
|
animation: `$dash ${animationDuration} steps(50) infinite`,
|
|
8733
|
-
stroke:
|
|
8815
|
+
stroke: colorPrimary,
|
|
8734
8816
|
strokeDasharray: strokeDasharray
|
|
8735
8817
|
,
|
|
8736
8818
|
strokeLinecap: 'round',
|
|
@@ -8757,7 +8839,6 @@ const svgNumber = [
|
|
|
8757
8839
|
'<path d="m10.47 11.94c-.65-.33-1.13-.92-1.13-2.01 0-1.53.85-2.47 2.66-2.47s2.66.94 2.66 2.47c0 1.08-.47 1.68-1.15 2.01.92.35 1.34 1.07 1.34 2.11 0 1.73-.99 2.49-2.86 2.49s-2.86-.76-2.86-2.49c0-1.04.41-1.76 1.33-2.11zm1.53 3.78c1.27 0 1.85-.51 1.85-1.69 0-1.1-.58-1.61-1.85-1.61s-1.85.52-1.85 1.61c0 1.18.58 1.69 1.85 1.69zm1.65-5.76c0-1.1-.56-1.56-1.65-1.56s-1.65.47-1.65 1.56c0 1 .46 1.6 1.65 1.6s1.65-.6 1.65-1.6z"/>',
|
|
8758
8840
|
'<path d="m9.16 10.33c0-2.03 1.02-2.86 2.83-2.86s2.82.81 2.82 2.85c0 1.11-.3 1.82-.81 2.64l-2.18 3.44h-1.1l2.18-3.37c-.31.14-.65.2-1.01.2-1.82 0-2.74-.99-2.74-2.9zm4.65 0c0-1.23-.47-1.92-1.81-1.92s-1.81.69-1.81 1.92c0 1.37.49 2.05 1.81 2.05s1.81-.68 1.81-2.05z"/>',
|
|
8759
8841
|
];
|
|
8760
|
-
const { primaryColor: primaryColor$a, canvasColor: canvasColor$1, frostedColor: frostedColor$6 } = colors;
|
|
8761
8842
|
// CSS Variable defined in fontHyphenationStyle
|
|
8762
8843
|
/**
|
|
8763
8844
|
* @css-variable {"name": "--p-hyphens", "description": "Sets the CSS `hyphens` property for text elements, controlling whether words can break and hyphenate automatically.", "defaultValue": "auto"}
|
|
@@ -8784,7 +8865,7 @@ const getComponentCss$l = (state, disabled) => {
|
|
|
8784
8865
|
display: 'grid',
|
|
8785
8866
|
gridTemplateColumns: 'auto minmax(0,1fr)',
|
|
8786
8867
|
gap: spacingStaticXs,
|
|
8787
|
-
color:
|
|
8868
|
+
color: colorPrimary,
|
|
8788
8869
|
paddingInline: `${spacingStaticSm} 12px`,
|
|
8789
8870
|
paddingBlock: '6px',
|
|
8790
8871
|
width: 'max-content',
|
|
@@ -8794,14 +8875,14 @@ const getComponentCss$l = (state, disabled) => {
|
|
|
8794
8875
|
borderRadius: `var(${legacyRadiusSmall}, ${radiusFull})`,
|
|
8795
8876
|
...(isStateCurrent && {
|
|
8796
8877
|
...frostedGlassStyle,
|
|
8797
|
-
background:
|
|
8878
|
+
background: colorFrosted,
|
|
8798
8879
|
}),
|
|
8799
8880
|
...(!isDisabled &&
|
|
8800
8881
|
hoverMediaQuery({
|
|
8801
8882
|
transition: getTransition('background-color'),
|
|
8802
8883
|
'&:hover': {
|
|
8803
8884
|
...frostedGlassStyle,
|
|
8804
|
-
background:
|
|
8885
|
+
background: colorFrosted,
|
|
8805
8886
|
},
|
|
8806
8887
|
})),
|
|
8807
8888
|
'&:focus-visible': getFocusBaseStyles(),
|
|
@@ -8814,7 +8895,7 @@ const getComponentCss$l = (state, disabled) => {
|
|
|
8814
8895
|
height: fontLineHeight,
|
|
8815
8896
|
...(isStateCurrentOrUndefined && {
|
|
8816
8897
|
display: 'grid',
|
|
8817
|
-
backgroundImage: `radial-gradient(circle, ${
|
|
8898
|
+
backgroundImage: `radial-gradient(circle, ${colorPrimary} 60%, transparent 62%)`,
|
|
8818
8899
|
'&::before': {
|
|
8819
8900
|
content: '""',
|
|
8820
8901
|
...Array.from(new Array(9)).reduce((result, _, i) => ({
|
|
@@ -8822,7 +8903,7 @@ const getComponentCss$l = (state, disabled) => {
|
|
|
8822
8903
|
[`:host(:nth-of-type(${i + 1})) &`]: {
|
|
8823
8904
|
WebkitMask: `${getInlineSVGBackgroundImage(svgNumber[i])} center/contain no-repeat`, // necessary for Sogou browser support :-)
|
|
8824
8905
|
mask: `${getInlineSVGBackgroundImage(svgNumber[i])} center/contain no-repeat`,
|
|
8825
|
-
backgroundColor:
|
|
8906
|
+
backgroundColor: colorCanvas,
|
|
8826
8907
|
},
|
|
8827
8908
|
}), {}),
|
|
8828
8909
|
},
|
|
@@ -8838,7 +8919,6 @@ const getComponentCss$k = (size) => {
|
|
|
8838
8919
|
':host': {
|
|
8839
8920
|
display: 'block',
|
|
8840
8921
|
...addImportantToEachRule({
|
|
8841
|
-
...colorSchemeStyles,
|
|
8842
8922
|
...hostHiddenStyles,
|
|
8843
8923
|
}),
|
|
8844
8924
|
},
|
|
@@ -8852,14 +8932,13 @@ const getComponentCss$k = (size) => {
|
|
|
8852
8932
|
};
|
|
8853
8933
|
|
|
8854
8934
|
const cssVarInternalSwitchScaling = '--p-internal-switch-scaling';
|
|
8855
|
-
const { primaryColor: primaryColor$9, contrastLowColor: contrastLowColor$1, successColor, frostedSoftColor: frostedSoftColor$1, successFrostedSoftColor: successFrostedSoftColor$1, successLowColor } = colors;
|
|
8856
8935
|
const getColors$1 = (checked, loading) => {
|
|
8857
8936
|
return {
|
|
8858
|
-
buttonBorderColor: checked ?
|
|
8859
|
-
buttonBorderColorHover: checked ?
|
|
8860
|
-
buttonBackgroundColor: checked ?
|
|
8861
|
-
toggleBackgroundColor: loading ? 'transparent' : checked ?
|
|
8862
|
-
textColor:
|
|
8937
|
+
buttonBorderColor: checked ? colorSuccessLow : colorContrastLow,
|
|
8938
|
+
buttonBorderColorHover: checked ? colorSuccess : colorPrimary,
|
|
8939
|
+
buttonBackgroundColor: checked ? colorSuccessFrostedSoft : colorFrostedSoft,
|
|
8940
|
+
toggleBackgroundColor: loading ? 'transparent' : checked ? colorSuccess : colorPrimary,
|
|
8941
|
+
textColor: colorPrimary,
|
|
8863
8942
|
};
|
|
8864
8943
|
};
|
|
8865
8944
|
// CSS Variable defined in fontHyphenationStyle
|
|
@@ -8890,7 +8969,6 @@ const getComponentCss$j = (alignLabel, hideLabel, isStretched, isChecked, isDisa
|
|
|
8890
8969
|
outline: 0, // custom element is able to delegate the focus
|
|
8891
8970
|
font: `${fontSizeTextSmall} ${fontFamily}`, // needed for correct gap definition based on ex-unit
|
|
8892
8971
|
gap,
|
|
8893
|
-
...colorSchemeStyles,
|
|
8894
8972
|
...hostHiddenStyles,
|
|
8895
8973
|
...buildResponsiveStyles(isStretched, (stretchValue) => ({
|
|
8896
8974
|
justifyContent: stretchValue ? 'space-between' : 'flex-start',
|
|
@@ -8984,20 +9062,18 @@ const cssVariableTablePadding = '--_a';
|
|
|
8984
9062
|
const cssVariableTableHoverColor = '--_b';
|
|
8985
9063
|
const cssVariableTableBorderColor = '--_c';
|
|
8986
9064
|
const cssVariableTableBorderWidth = '--_d';
|
|
8987
|
-
const { primaryColor: primaryColor$8, frostedColor: frostedColor$5, contrastLowColor } = colors;
|
|
8988
9065
|
const getComponentCss$h = (compact, layout) => {
|
|
8989
9066
|
return getCss({
|
|
8990
9067
|
'@global': {
|
|
8991
9068
|
':host': {
|
|
8992
9069
|
display: 'block',
|
|
8993
9070
|
...addImportantToEachRule({
|
|
8994
|
-
[cssVariableTableHoverColor]:
|
|
8995
|
-
[cssVariableTableBorderColor]:
|
|
9071
|
+
[cssVariableTableHoverColor]: colorFrosted,
|
|
9072
|
+
[cssVariableTableBorderColor]: colorContrastLow,
|
|
8996
9073
|
...(compact && { [cssVariableTablePadding]: spacingStaticSmall }),
|
|
8997
|
-
...colorSchemeStyles,
|
|
8998
9074
|
...hostHiddenStyles,
|
|
8999
9075
|
...textSmallStyle,
|
|
9000
|
-
color:
|
|
9076
|
+
color: colorPrimary,
|
|
9001
9077
|
textAlign: 'start',
|
|
9002
9078
|
}),
|
|
9003
9079
|
},
|
|
@@ -9044,7 +9120,6 @@ const isSortable = (active, direction) => {
|
|
|
9044
9120
|
return active !== undefined && direction !== undefined;
|
|
9045
9121
|
};
|
|
9046
9122
|
|
|
9047
|
-
const { frostedColor: frostedColor$4 } = colors;
|
|
9048
9123
|
const buttonBeforeOffsetVertical = '-2px';
|
|
9049
9124
|
const buttonBeforeOffsetHorizontal = '-4px';
|
|
9050
9125
|
const getComponentCss$f = (active, direction, hideLabel, multiline) => {
|
|
@@ -9097,7 +9172,7 @@ const getComponentCss$f = (active, direction, hideLabel, multiline) => {
|
|
|
9097
9172
|
},
|
|
9098
9173
|
'&:hover::before': {
|
|
9099
9174
|
...frostedGlassStyle,
|
|
9100
|
-
backgroundColor:
|
|
9175
|
+
backgroundColor: colorFrosted,
|
|
9101
9176
|
},
|
|
9102
9177
|
}),
|
|
9103
9178
|
'&:focus-visible::before': getFocusBaseStyles(),
|
|
@@ -9178,12 +9253,11 @@ const getComponentCss$c = () => {
|
|
|
9178
9253
|
const scrollerAnimatedCssClass = 'scroller--animated';
|
|
9179
9254
|
const targetSelectors = ['a', 'button'];
|
|
9180
9255
|
const transformSelector = (selector) => targetSelectors.map((tag) => selector.replace(/\[role]/g, tag)).join();
|
|
9181
|
-
const { primaryColor: primaryColor$7, frostedColor: frostedColor$3 } = colors;
|
|
9182
9256
|
const barJssStyle = {
|
|
9183
9257
|
position: 'absolute',
|
|
9184
9258
|
height: '2px',
|
|
9185
9259
|
left: 0,
|
|
9186
|
-
background:
|
|
9260
|
+
background: colorPrimary,
|
|
9187
9261
|
};
|
|
9188
9262
|
const getComponentCss$b = (size, weight) => {
|
|
9189
9263
|
return getCss({
|
|
@@ -9192,7 +9266,6 @@ const getComponentCss$b = (size, weight) => {
|
|
|
9192
9266
|
display: 'block',
|
|
9193
9267
|
...addImportantToEachRule({
|
|
9194
9268
|
position: 'relative',
|
|
9195
|
-
...colorSchemeStyles,
|
|
9196
9269
|
...hostHiddenStyles,
|
|
9197
9270
|
}),
|
|
9198
9271
|
},
|
|
@@ -9211,7 +9284,7 @@ const getComponentCss$b = (size, weight) => {
|
|
|
9211
9284
|
whiteSpace: 'nowrap',
|
|
9212
9285
|
boxSizing: 'border-box',
|
|
9213
9286
|
textAlign: 'start',
|
|
9214
|
-
color:
|
|
9287
|
+
color: colorPrimary,
|
|
9215
9288
|
cursor: 'pointer',
|
|
9216
9289
|
borderRadius: `var(${legacyRadiusSmall}, ${radiusSm})`,
|
|
9217
9290
|
zIndex: 0, // needed for ::before pseudo-element to be visible
|
|
@@ -9229,7 +9302,7 @@ const getComponentCss$b = (size, weight) => {
|
|
|
9229
9302
|
...hoverMediaQuery({
|
|
9230
9303
|
[transformSelector('::slotted([role]:hover)::before')]: {
|
|
9231
9304
|
...frostedGlassStyle,
|
|
9232
|
-
background:
|
|
9305
|
+
background: colorFrosted,
|
|
9233
9306
|
},
|
|
9234
9307
|
}),
|
|
9235
9308
|
// basic invisible bar, that will be delayed via transition: visibility
|
|
@@ -9277,14 +9350,13 @@ const getComponentCss$b = (size, weight) => {
|
|
|
9277
9350
|
});
|
|
9278
9351
|
};
|
|
9279
9352
|
|
|
9280
|
-
const { primaryColor: primaryColor$6 } = colors;
|
|
9281
9353
|
const getComponentCss$a = () => {
|
|
9282
9354
|
return getCss({
|
|
9283
9355
|
'@global': {
|
|
9284
9356
|
':host': {
|
|
9285
9357
|
display: 'block',
|
|
9286
9358
|
...addImportantToEachRule({
|
|
9287
|
-
color:
|
|
9359
|
+
color: colorPrimary, // enables color inheritance for e.g. slotted anchor
|
|
9288
9360
|
borderRadius: '2px',
|
|
9289
9361
|
...hostHiddenStyles,
|
|
9290
9362
|
'&(:focus-visible)': getFocusBaseStyles(),
|
|
@@ -9300,7 +9372,6 @@ const getComponentCss$9 = () => {
|
|
|
9300
9372
|
':host': {
|
|
9301
9373
|
display: 'block',
|
|
9302
9374
|
...addImportantToEachRule({
|
|
9303
|
-
...colorSchemeStyles,
|
|
9304
9375
|
...hostHiddenStyles,
|
|
9305
9376
|
}),
|
|
9306
9377
|
},
|
|
@@ -9312,7 +9383,6 @@ const getComponentCss$9 = () => {
|
|
|
9312
9383
|
});
|
|
9313
9384
|
};
|
|
9314
9385
|
|
|
9315
|
-
const { primaryColor: primaryColor$5, frostedColor: frostedColor$2, contrastHighColor: contrastHighColor$1 } = colors;
|
|
9316
9386
|
const cssVarInternalTagDismissibleScaling = '--p-internal-tag-dismissible-scaling';
|
|
9317
9387
|
// CSS Variable defined in fontHyphenationStyle
|
|
9318
9388
|
/**
|
|
@@ -9333,7 +9403,6 @@ const getComponentCss$8 = (hasLabel, isCompact) => {
|
|
|
9333
9403
|
display: 'inline-block',
|
|
9334
9404
|
verticalAlign: 'top',
|
|
9335
9405
|
...addImportantToEachRule({
|
|
9336
|
-
...colorSchemeStyles,
|
|
9337
9406
|
...hostHiddenStyles,
|
|
9338
9407
|
}),
|
|
9339
9408
|
},
|
|
@@ -9347,13 +9416,13 @@ const getComponentCss$8 = (hasLabel, isCompact) => {
|
|
|
9347
9416
|
padding: `${buttonPaddingBlock} ${buttonPaddingInline}`,
|
|
9348
9417
|
borderRadius: `var(${legacyRadiusSmall}, ${isCompact ? radiusLg : radiusXl})`,
|
|
9349
9418
|
cursor: 'pointer',
|
|
9350
|
-
background:
|
|
9351
|
-
color:
|
|
9419
|
+
background: colorFrosted,
|
|
9420
|
+
color: colorPrimary,
|
|
9352
9421
|
textAlign: 'start',
|
|
9353
9422
|
...textSmallStyle,
|
|
9354
9423
|
...hoverMediaQuery({
|
|
9355
9424
|
'&:hover > .icon': {
|
|
9356
|
-
backgroundColor:
|
|
9425
|
+
backgroundColor: colorFrosted,
|
|
9357
9426
|
},
|
|
9358
9427
|
}),
|
|
9359
9428
|
'&:focus-visible': getFocusBaseStyles(),
|
|
@@ -9363,7 +9432,7 @@ const getComponentCss$8 = (hasLabel, isCompact) => {
|
|
|
9363
9432
|
label: {
|
|
9364
9433
|
display: 'block',
|
|
9365
9434
|
marginBottom: '-4px',
|
|
9366
|
-
color:
|
|
9435
|
+
color: colorContrastHigh,
|
|
9367
9436
|
fontSize: fontSizeTextXSmall,
|
|
9368
9437
|
},
|
|
9369
9438
|
}),
|
|
@@ -9377,30 +9446,29 @@ const getComponentCss$8 = (hasLabel, isCompact) => {
|
|
|
9377
9446
|
});
|
|
9378
9447
|
};
|
|
9379
9448
|
|
|
9380
|
-
const { canvasColor, frostedColor: frostedColor$1, frostedSoftColor, primaryColor: primaryColor$4, infoFrostedColor, contrastHighColor, infoFrostedSoftColor, successFrostedColor, successFrostedSoftColor, errorFrostedColor, errorFrostedSoftColor, warningFrostedColor, warningFrostedSoftColor, } = colors;
|
|
9381
9449
|
const colorTextMap = {
|
|
9382
|
-
primary:
|
|
9383
|
-
secondary:
|
|
9384
|
-
info:
|
|
9385
|
-
success:
|
|
9386
|
-
warning:
|
|
9387
|
-
error:
|
|
9450
|
+
primary: colorCanvas,
|
|
9451
|
+
secondary: colorPrimary,
|
|
9452
|
+
info: colorPrimary,
|
|
9453
|
+
success: colorPrimary,
|
|
9454
|
+
warning: colorPrimary,
|
|
9455
|
+
error: colorPrimary,
|
|
9388
9456
|
};
|
|
9389
9457
|
const colorBackgroundMap = {
|
|
9390
|
-
primary:
|
|
9391
|
-
secondary:
|
|
9392
|
-
info:
|
|
9393
|
-
success:
|
|
9394
|
-
warning:
|
|
9395
|
-
error:
|
|
9458
|
+
primary: colorPrimary,
|
|
9459
|
+
secondary: colorFrostedStrong,
|
|
9460
|
+
info: colorInfoFrosted,
|
|
9461
|
+
success: colorSuccessFrosted,
|
|
9462
|
+
warning: colorWarningFrosted,
|
|
9463
|
+
error: colorErrorFrosted,
|
|
9396
9464
|
};
|
|
9397
9465
|
const colorBackgroundHoverMap = {
|
|
9398
|
-
primary:
|
|
9399
|
-
secondary:
|
|
9400
|
-
info:
|
|
9401
|
-
success:
|
|
9402
|
-
warning:
|
|
9403
|
-
error:
|
|
9466
|
+
primary: colorContrastHigh,
|
|
9467
|
+
secondary: colorFrosted,
|
|
9468
|
+
info: colorInfoFrostedSoft,
|
|
9469
|
+
success: colorSuccessFrostedSoft,
|
|
9470
|
+
warning: colorWarningFrostedSoft,
|
|
9471
|
+
error: colorErrorFrostedSoft,
|
|
9404
9472
|
};
|
|
9405
9473
|
const getColors = (variant) => {
|
|
9406
9474
|
return {
|
|
@@ -9418,7 +9486,6 @@ const getComponentCss$7 = (variant, compact, isFocusable, hasIcon) => {
|
|
|
9418
9486
|
verticalAlign: 'top', // TODO: should we set this CSS style at all?
|
|
9419
9487
|
whiteSpace: 'nowrap', // TODO: should either be exposed by a controlled CSS variable or a component prop or whitelist as supported custom styles
|
|
9420
9488
|
...addImportantToEachRule({
|
|
9421
|
-
...colorSchemeStyles,
|
|
9422
9489
|
...hostHiddenStyles,
|
|
9423
9490
|
}),
|
|
9424
9491
|
},
|
|
@@ -9484,7 +9551,6 @@ const cssVariableUnorderedPseudoContent = '--p-internal-text-list-unordered-pseu
|
|
|
9484
9551
|
const cssVariableOrderedGridColumn = '--p-internal-text-list-ordered-grid-column';
|
|
9485
9552
|
const cssVariableOrderedPseudoSuffix = '--p-internal-text-list-ordered-pseudo-suffix';
|
|
9486
9553
|
const counter = 'p-text-list-counter';
|
|
9487
|
-
const { primaryColor: primaryColor$3 } = colors;
|
|
9488
9554
|
const getComponentCss$6 = (type) => {
|
|
9489
9555
|
const isOrderedList = isListTypeOrdered(type);
|
|
9490
9556
|
return getCss({
|
|
@@ -9493,7 +9559,6 @@ const getComponentCss$6 = (type) => {
|
|
|
9493
9559
|
display: 'block',
|
|
9494
9560
|
...addImportantToEachRule({
|
|
9495
9561
|
counterReset: counter,
|
|
9496
|
-
...colorSchemeStyles,
|
|
9497
9562
|
...hostHiddenStyles,
|
|
9498
9563
|
}),
|
|
9499
9564
|
},
|
|
@@ -9502,7 +9567,7 @@ const getComponentCss$6 = (type) => {
|
|
|
9502
9567
|
margin: 0,
|
|
9503
9568
|
padding: `var(${cssVariablePaddingTop},0) 0 var(${cssVariablePaddingBottom},0) 0`,
|
|
9504
9569
|
listStyleType: 'none',
|
|
9505
|
-
color:
|
|
9570
|
+
color: colorPrimary,
|
|
9506
9571
|
},
|
|
9507
9572
|
// css selector for text-list-item
|
|
9508
9573
|
'::slotted(*)': addImportantToEachRule({
|
|
@@ -9577,7 +9642,6 @@ const getComponentCss$4 = (size, weight, align, color, ellipsis) => {
|
|
|
9577
9642
|
':host': {
|
|
9578
9643
|
display: 'block',
|
|
9579
9644
|
...addImportantToEachRule({
|
|
9580
|
-
...colorSchemeStyles,
|
|
9581
9645
|
...hostHiddenStyles,
|
|
9582
9646
|
}),
|
|
9583
9647
|
},
|
|
@@ -9590,11 +9654,15 @@ const getComponentCss$4 = (size, weight, align, color, ellipsis) => {
|
|
|
9590
9654
|
});
|
|
9591
9655
|
};
|
|
9592
9656
|
|
|
9593
|
-
const { primaryColor: primaryColor$2, contrastMediumColor, frostedColor } = colors;
|
|
9594
9657
|
const cssVarInternalTextareaScaling = '--p-internal-textarea-scaling';
|
|
9595
9658
|
// CSS Variable defined in fontHyphenationStyle
|
|
9596
9659
|
/**
|
|
9597
9660
|
* @css-variable {"name": "--p-hyphens", "description": "Sets the CSS `hyphens` property for text elements, controlling whether words can break and hyphenate automatically.", "defaultValue": "auto"}
|
|
9661
|
+
* @css-variable {"name":"--p-textarea-field-sizing","description":"Controls CSS `field-sizing` for textarea.","defaultValue":"unset"}
|
|
9662
|
+
* @css-variable {"name":"--p-textarea-min-width","description":"Minimum width of the textarea.","defaultValue":"52px"}
|
|
9663
|
+
* @css-variable {"name":"--p-textarea-max-width","description":"Maximum width of the textarea.","defaultValue":"unset"}
|
|
9664
|
+
* @css-variable {"name":"--p-textarea-min-height","description":"Minimum height of the textarea.","defaultValue":"unset"}
|
|
9665
|
+
* @css-variable {"name":"--p-textarea-max-height","description":"Maximum height of the textarea.","defaultValue":"unset"}
|
|
9598
9666
|
*/
|
|
9599
9667
|
const getComponentCss$3 = (isDisabled, isReadonly, hideLabel, state, isCompact, hasCounter, resize) => {
|
|
9600
9668
|
const textareaMinHeight = `calc(var(${cssVarInternalTextareaScaling}) * 3.5rem)`;
|
|
@@ -9609,24 +9677,27 @@ const getComponentCss$3 = (isDisabled, isReadonly, hideLabel, state, isCompact,
|
|
|
9609
9677
|
display: 'block',
|
|
9610
9678
|
[`${cssVarInternalTextareaScaling}`]: isCompact ? 0.64285714 : 1,
|
|
9611
9679
|
...addImportantToEachRule({
|
|
9612
|
-
...colorSchemeStyles,
|
|
9613
9680
|
...hostHiddenStyles,
|
|
9614
9681
|
...(isDisabled && getDisabledBaseStyles()),
|
|
9615
9682
|
}),
|
|
9616
9683
|
},
|
|
9684
|
+
...getFunctionalComponentLabelAfterStyles(isDisabled),
|
|
9617
9685
|
...preventFoucOfNestedElementsStyles,
|
|
9618
9686
|
textarea: {
|
|
9619
9687
|
all: 'unset',
|
|
9620
9688
|
gridArea: '1/1',
|
|
9621
9689
|
display: 'block',
|
|
9622
9690
|
resize,
|
|
9691
|
+
fieldSizing: 'var(--p-textarea-field-sizing, unset)',
|
|
9692
|
+
minWidth: `var(--p-textarea-min-width, 2ch)`, // to show at least 2 characters in very narrow containers
|
|
9693
|
+
maxWidth: 'var(--p-textarea-max-width, unset)',
|
|
9694
|
+
minHeight: `var(--p-textarea-min-height, ${textareaMinHeight})`,
|
|
9695
|
+
maxHeight: 'var(--p-textarea-max-height, unset)',
|
|
9623
9696
|
border: `${borderWidthThin} solid ${formStateBorderColor}`,
|
|
9624
9697
|
borderRadius: `var(${legacyRadiusSmall}, ${isCompact ? radiusLg : radiusXl})`,
|
|
9625
9698
|
background: formStateBackgroundColor,
|
|
9626
|
-
color:
|
|
9699
|
+
color: colorPrimary,
|
|
9627
9700
|
// min width is needed for showing at least 1 character in very narrow containers. The "1rem" value is the minimum safe zone to show at least 1 character.
|
|
9628
|
-
minWidth: '2ch', // to show at least 2 characters in very narrow containers
|
|
9629
|
-
minHeight: textareaMinHeight,
|
|
9630
9701
|
boxSizing: 'border-box',
|
|
9631
9702
|
transition: `${getTransition('background-color')}, ${getTransition('border-color')}`,
|
|
9632
9703
|
font: textSmallStyle.font,
|
|
@@ -9639,13 +9710,13 @@ const getComponentCss$3 = (isDisabled, isReadonly, hideLabel, state, isCompact,
|
|
|
9639
9710
|
cursor: isDisabled ? 'not-allowed' : 'text',
|
|
9640
9711
|
...(isReadonly && {
|
|
9641
9712
|
borderColor: 'transparent',
|
|
9642
|
-
background:
|
|
9643
|
-
color:
|
|
9713
|
+
background: colorFrosted,
|
|
9714
|
+
color: colorContrastMedium,
|
|
9644
9715
|
}),
|
|
9645
9716
|
...(!isDisabled &&
|
|
9646
9717
|
!isReadonly &&
|
|
9647
9718
|
hoverMediaQuery({
|
|
9648
|
-
'&:hover
|
|
9719
|
+
'&:hover,.label-wrapper:hover~&': {
|
|
9649
9720
|
borderColor: formStateBorderHoverColor,
|
|
9650
9721
|
},
|
|
9651
9722
|
})),
|
|
@@ -9718,7 +9789,6 @@ const getComponentCss$1 = () => {
|
|
|
9718
9789
|
inset: `auto auto var(${cssVariablePositionBottomInternal}) 64px`,
|
|
9719
9790
|
maxWidth: 'min(42rem, calc(100vw - 64px * 2))',
|
|
9720
9791
|
},
|
|
9721
|
-
...colorSchemeStyles,
|
|
9722
9792
|
...hostHiddenStyles,
|
|
9723
9793
|
}),
|
|
9724
9794
|
...preventFoucOfNestedElementsStyles,
|
|
@@ -9734,8 +9804,13 @@ const getComponentCss$1 = () => {
|
|
|
9734
9804
|
});
|
|
9735
9805
|
};
|
|
9736
9806
|
|
|
9737
|
-
const { primaryColor } = colors;
|
|
9738
9807
|
const getComponentCss = (size) => {
|
|
9808
|
+
const sizingStyles = {
|
|
9809
|
+
display: 'block',
|
|
9810
|
+
maxWidth: '100%',
|
|
9811
|
+
maxHeight: '100%',
|
|
9812
|
+
height: 'inherit',
|
|
9813
|
+
};
|
|
9739
9814
|
return getCss({
|
|
9740
9815
|
'@global': {
|
|
9741
9816
|
':host': {
|
|
@@ -9753,18 +9828,12 @@ const getComponentCss = (size) => {
|
|
|
9753
9828
|
height: 'round(down, clamp(0.63rem, 0.42vw + 0.5rem, 1rem), 1px)',
|
|
9754
9829
|
},
|
|
9755
9830
|
}),
|
|
9756
|
-
...colorSchemeStyles,
|
|
9757
9831
|
...hostHiddenStyles,
|
|
9758
9832
|
}),
|
|
9759
9833
|
},
|
|
9760
|
-
'a, svg': {
|
|
9761
|
-
display: 'block',
|
|
9762
|
-
maxWidth: '100%',
|
|
9763
|
-
maxHeight: '100%',
|
|
9764
|
-
height: 'inherit',
|
|
9765
|
-
},
|
|
9766
9834
|
a: {
|
|
9767
9835
|
all: 'unset',
|
|
9836
|
+
...sizingStyles,
|
|
9768
9837
|
cursor: 'pointer',
|
|
9769
9838
|
'&::before': {
|
|
9770
9839
|
// needs to be defined always to have correct custom click area
|
|
@@ -9776,7 +9845,8 @@ const getComponentCss = (size) => {
|
|
|
9776
9845
|
'&:focus-visible::before': getFocusBaseStyles(),
|
|
9777
9846
|
},
|
|
9778
9847
|
svg: {
|
|
9779
|
-
|
|
9848
|
+
...sizingStyles,
|
|
9849
|
+
fill: colorPrimary,
|
|
9780
9850
|
},
|
|
9781
9851
|
},
|
|
9782
9852
|
});
|
|
@@ -9803,6 +9873,7 @@ exports.getFieldsetCss = getComponentCss$X;
|
|
|
9803
9873
|
exports.getFlagCss = getComponentCss$W;
|
|
9804
9874
|
exports.getFlyoutCss = getComponentCss$V;
|
|
9805
9875
|
exports.getFunctionalComponentInputBaseStyles = getFunctionalComponentInputBaseStyles;
|
|
9876
|
+
exports.getFunctionalComponentLabelAfterStyles = getFunctionalComponentLabelAfterStyles;
|
|
9806
9877
|
exports.getFunctionalComponentLabelStyles = getFunctionalComponentLabelStyles;
|
|
9807
9878
|
exports.getFunctionalComponentLoadingMessageStyles = getFunctionalComponentLoadingMessageStyles;
|
|
9808
9879
|
exports.getFunctionalComponentNoResultsOptionStyles = getFunctionalComponentNoResultsOptionStyles;
|