@porsche-design-system/components-react 3.0.0-rc.1 → 3.0.0-rc.3
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 +54 -0
- package/bin/patchRemixRunProcessBrowserGlobalIdentifier.js +35 -26
- package/esm/lib/components/icon.wrapper.js +1 -1
- package/esm/lib/components/scroller.wrapper.js +3 -3
- package/lib/components/accordion.wrapper.d.ts +2 -2
- package/lib/components/banner.wrapper.d.ts +2 -2
- package/lib/components/button-group.wrapper.d.ts +2 -2
- package/lib/components/button-pure.wrapper.d.ts +2 -2
- package/lib/components/button-tile.wrapper.d.ts +2 -2
- package/lib/components/button.wrapper.d.ts +2 -2
- package/lib/components/carousel.wrapper.d.ts +2 -2
- package/lib/components/checkbox-wrapper.wrapper.d.ts +2 -2
- package/lib/components/content-wrapper.wrapper.d.ts +2 -2
- package/lib/components/crest.wrapper.d.ts +2 -2
- package/lib/components/display.wrapper.d.ts +2 -2
- package/lib/components/divider.wrapper.d.ts +2 -2
- package/lib/components/fieldset-wrapper.wrapper.d.ts +2 -2
- package/lib/components/fieldset.wrapper.d.ts +2 -2
- package/lib/components/flex-item.wrapper.d.ts +2 -2
- package/lib/components/flex.wrapper.d.ts +2 -2
- package/lib/components/grid-item.wrapper.d.ts +2 -2
- package/lib/components/grid.wrapper.d.ts +2 -2
- package/lib/components/heading.wrapper.d.ts +2 -2
- package/lib/components/headline.wrapper.d.ts +2 -2
- package/lib/components/icon.wrapper.d.ts +2 -2
- package/lib/components/icon.wrapper.js +1 -1
- package/lib/components/inline-notification.wrapper.d.ts +2 -2
- package/lib/components/link-pure.wrapper.d.ts +2 -2
- package/lib/components/link-social.wrapper.d.ts +2 -2
- package/lib/components/link-tile-model-signature.wrapper.d.ts +2 -2
- package/lib/components/link-tile.wrapper.d.ts +2 -2
- package/lib/components/link.wrapper.d.ts +2 -2
- package/lib/components/marque.wrapper.d.ts +2 -2
- package/lib/components/modal.wrapper.d.ts +2 -2
- package/lib/components/model-signature.wrapper.d.ts +2 -2
- package/lib/components/pagination.wrapper.d.ts +2 -2
- package/lib/components/popover.wrapper.d.ts +2 -2
- package/lib/components/radio-button-wrapper.wrapper.d.ts +2 -2
- package/lib/components/scroller.wrapper.d.ts +17 -9
- package/lib/components/scroller.wrapper.js +3 -3
- package/lib/components/segmented-control-item.wrapper.d.ts +2 -2
- package/lib/components/segmented-control.wrapper.d.ts +2 -2
- package/lib/components/select-wrapper.wrapper.d.ts +2 -2
- package/lib/components/spinner.wrapper.d.ts +2 -2
- package/lib/components/stepper-horizontal-item.wrapper.d.ts +2 -2
- package/lib/components/stepper-horizontal.wrapper.d.ts +2 -2
- package/lib/components/switch.wrapper.d.ts +2 -2
- package/lib/components/table-body.wrapper.d.ts +2 -2
- package/lib/components/table-cell.wrapper.d.ts +2 -2
- package/lib/components/table-head-cell.wrapper.d.ts +2 -2
- package/lib/components/table-head-row.wrapper.d.ts +2 -2
- package/lib/components/table-head.wrapper.d.ts +2 -2
- package/lib/components/table-row.wrapper.d.ts +2 -2
- package/lib/components/table.wrapper.d.ts +2 -2
- package/lib/components/tabs-bar.wrapper.d.ts +2 -2
- package/lib/components/tabs-item.wrapper.d.ts +2 -2
- package/lib/components/tabs.wrapper.d.ts +2 -2
- package/lib/components/tag-dismissible.wrapper.d.ts +2 -2
- package/lib/components/tag.wrapper.d.ts +2 -2
- package/lib/components/text-field-wrapper.wrapper.d.ts +2 -2
- package/lib/components/text-list-item.wrapper.d.ts +2 -2
- package/lib/components/text-list.wrapper.d.ts +2 -2
- package/lib/components/text.wrapper.d.ts +2 -2
- package/lib/components/textarea-wrapper.wrapper.d.ts +2 -2
- package/lib/components/toast.wrapper.d.ts +2 -2
- package/lib/components/wordmark.wrapper.d.ts +2 -2
- package/lib/types.d.ts +210 -191
- package/package.json +2 -2
- package/ssr/components/dist/styles/esm/styles-entry.js +203 -88
- package/ssr/components/dist/utils/esm/utils-entry.js +45 -7
- package/ssr/components-react/projects/react-ssr-wrapper/src/lib/components/icon.wrapper.js +1 -1
- package/ssr/components-react/projects/react-ssr-wrapper/src/lib/components/scroller.wrapper.js +4 -4
- package/ssr/components-react/projects/react-ssr-wrapper/src/lib/components/select-wrapper-dropdown.wrapper.js +38 -0
- package/ssr/components-react/projects/react-ssr-wrapper/src/lib/components/stepper-horizontal.wrapper.js +0 -1
- package/ssr/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/accordion.js +1 -1
- package/ssr/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/scroller.js +2 -1
- package/ssr/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/select-wrapper-dropdown.js +34 -0
- package/ssr/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/select-wrapper.js +6 -3
- package/ssr/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/stepper-horizontal.js +1 -1
- package/ssr/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/tabs-bar.js +1 -1
- package/ssr/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/wordmark.js +1 -1
- package/ssr/esm/components/dist/styles/esm/styles-entry.js +203 -89
- package/ssr/esm/components/dist/utils/esm/utils-entry.js +40 -8
- package/ssr/esm/components-react/projects/react-ssr-wrapper/src/lib/components/icon.wrapper.js +1 -1
- package/ssr/esm/components-react/projects/react-ssr-wrapper/src/lib/components/scroller.wrapper.js +4 -4
- package/ssr/esm/components-react/projects/react-ssr-wrapper/src/lib/components/select-wrapper-dropdown.wrapper.js +36 -0
- package/ssr/esm/components-react/projects/react-ssr-wrapper/src/lib/components/stepper-horizontal.wrapper.js +0 -1
- package/ssr/esm/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/accordion.js +1 -1
- package/ssr/esm/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/scroller.js +3 -2
- package/ssr/esm/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/select-wrapper-dropdown.js +32 -0
- package/ssr/esm/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/select-wrapper.js +6 -3
- package/ssr/esm/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/stepper-horizontal.js +1 -1
- package/ssr/esm/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/tabs-bar.js +1 -1
- package/ssr/esm/components-react/projects/react-ssr-wrapper/src/lib/dsr-components/wordmark.js +1 -1
- package/ssr/lib/components/accordion.wrapper.d.ts +2 -2
- package/ssr/lib/components/banner.wrapper.d.ts +2 -2
- package/ssr/lib/components/button-group.wrapper.d.ts +2 -2
- package/ssr/lib/components/button-pure.wrapper.d.ts +2 -2
- package/ssr/lib/components/button-tile.wrapper.d.ts +2 -2
- package/ssr/lib/components/button.wrapper.d.ts +2 -2
- package/ssr/lib/components/carousel.wrapper.d.ts +2 -2
- package/ssr/lib/components/checkbox-wrapper.wrapper.d.ts +2 -2
- package/ssr/lib/components/content-wrapper.wrapper.d.ts +2 -2
- package/ssr/lib/components/crest.wrapper.d.ts +2 -2
- package/ssr/lib/components/display.wrapper.d.ts +2 -2
- package/ssr/lib/components/divider.wrapper.d.ts +2 -2
- package/ssr/lib/components/fieldset-wrapper.wrapper.d.ts +2 -2
- package/ssr/lib/components/fieldset.wrapper.d.ts +2 -2
- package/ssr/lib/components/flex-item.wrapper.d.ts +2 -2
- package/ssr/lib/components/flex.wrapper.d.ts +2 -2
- package/ssr/lib/components/grid-item.wrapper.d.ts +2 -2
- package/ssr/lib/components/grid.wrapper.d.ts +2 -2
- package/ssr/lib/components/heading.wrapper.d.ts +2 -2
- package/ssr/lib/components/headline.wrapper.d.ts +2 -2
- package/ssr/lib/components/icon.wrapper.d.ts +2 -2
- package/ssr/lib/components/inline-notification.wrapper.d.ts +2 -2
- package/ssr/lib/components/link-pure.wrapper.d.ts +2 -2
- package/ssr/lib/components/link-social.wrapper.d.ts +2 -2
- package/ssr/lib/components/link-tile-model-signature.wrapper.d.ts +2 -2
- package/ssr/lib/components/link-tile.wrapper.d.ts +2 -2
- package/ssr/lib/components/link.wrapper.d.ts +2 -2
- package/ssr/lib/components/marque.wrapper.d.ts +2 -2
- package/ssr/lib/components/modal.wrapper.d.ts +2 -2
- package/ssr/lib/components/model-signature.wrapper.d.ts +2 -2
- package/ssr/lib/components/pagination.wrapper.d.ts +2 -2
- package/ssr/lib/components/popover.wrapper.d.ts +2 -2
- package/ssr/lib/components/radio-button-wrapper.wrapper.d.ts +2 -2
- package/ssr/lib/components/scroller.wrapper.d.ts +17 -9
- package/ssr/lib/components/segmented-control-item.wrapper.d.ts +2 -2
- package/ssr/lib/components/segmented-control.wrapper.d.ts +2 -2
- package/ssr/lib/components/select-wrapper-dropdown.wrapper.d.ts +30 -0
- package/ssr/lib/components/select-wrapper.wrapper.d.ts +2 -2
- package/ssr/lib/components/spinner.wrapper.d.ts +2 -2
- package/ssr/lib/components/stepper-horizontal-item.wrapper.d.ts +2 -2
- package/ssr/lib/components/stepper-horizontal.wrapper.d.ts +2 -2
- package/ssr/lib/components/switch.wrapper.d.ts +2 -2
- package/ssr/lib/components/table-body.wrapper.d.ts +2 -2
- package/ssr/lib/components/table-cell.wrapper.d.ts +2 -2
- package/ssr/lib/components/table-head-cell.wrapper.d.ts +2 -2
- package/ssr/lib/components/table-head-row.wrapper.d.ts +2 -2
- package/ssr/lib/components/table-head.wrapper.d.ts +2 -2
- package/ssr/lib/components/table-row.wrapper.d.ts +2 -2
- package/ssr/lib/components/table.wrapper.d.ts +2 -2
- package/ssr/lib/components/tabs-bar.wrapper.d.ts +2 -2
- package/ssr/lib/components/tabs-item.wrapper.d.ts +2 -2
- package/ssr/lib/components/tabs.wrapper.d.ts +2 -2
- package/ssr/lib/components/tag-dismissible.wrapper.d.ts +2 -2
- package/ssr/lib/components/tag.wrapper.d.ts +2 -2
- package/ssr/lib/components/text-field-wrapper.wrapper.d.ts +2 -2
- package/ssr/lib/components/text-list-item.wrapper.d.ts +2 -2
- package/ssr/lib/components/text-list.wrapper.d.ts +2 -2
- package/ssr/lib/components/text.wrapper.d.ts +2 -2
- package/ssr/lib/components/textarea-wrapper.wrapper.d.ts +2 -2
- package/ssr/lib/components/toast.wrapper.d.ts +2 -2
- package/ssr/lib/components/wordmark.wrapper.d.ts +2 -2
- package/ssr/lib/dsr-components/select-wrapper.d.ts +0 -1
- package/ssr/lib/types.d.ts +210 -191
|
@@ -48,11 +48,11 @@ const borderWidthBase = '2px';
|
|
|
48
48
|
const _dropShadowBackgroundColor = 'rgba(0, 0, 0, 0.16)';
|
|
49
49
|
|
|
50
50
|
const dropShadowLowStyle = {
|
|
51
|
-
|
|
51
|
+
boxShadow: `0px 3px 8px ${_dropShadowBackgroundColor}`, // filter: drop-shadow() causes visual glitches in Firefox in combination with frostedGlassStyle
|
|
52
52
|
};
|
|
53
53
|
|
|
54
54
|
const dropShadowHighStyle = {
|
|
55
|
-
|
|
55
|
+
boxShadow: `0px 8px 40px ${_dropShadowBackgroundColor}`, // filter: drop-shadow() causes visual glitches in Firefox in combination with frostedGlassStyle
|
|
56
56
|
};
|
|
57
57
|
|
|
58
58
|
const themeLightStateFocus = '#1A44EA';
|
|
@@ -3226,6 +3226,10 @@ function jssNested() {
|
|
|
3226
3226
|
};
|
|
3227
3227
|
}
|
|
3228
3228
|
|
|
3229
|
+
function getDefaultExportFromCjs (x) {
|
|
3230
|
+
return x && x.__esModule && Object.prototype.hasOwnProperty.call(x, 'default') ? x['default'] : x;
|
|
3231
|
+
}
|
|
3232
|
+
|
|
3229
3233
|
function getAugmentedNamespace(n) {
|
|
3230
3234
|
if (n.__esModule) return n;
|
|
3231
3235
|
var f = n.default;
|
|
@@ -3287,7 +3291,7 @@ var _tslib$1 = {};
|
|
|
3287
3291
|
return t;
|
|
3288
3292
|
};
|
|
3289
3293
|
return exports.__assign.apply(this, arguments);
|
|
3290
|
-
};
|
|
3294
|
+
};
|
|
3291
3295
|
} (_tslib$1));
|
|
3292
3296
|
|
|
3293
3297
|
var require$$1 = /*@__PURE__*/getAugmentedNamespace(jss_esm);
|
|
@@ -3647,6 +3651,8 @@ function jssCombineAndSortMQ(options) {
|
|
|
3647
3651
|
|
|
3648
3652
|
var dist = jssCombineAndSortMQ;
|
|
3649
3653
|
|
|
3654
|
+
var jssPluginSortMediaQueries = /*@__PURE__*/getDefaultExportFromCjs(dist);
|
|
3655
|
+
|
|
3650
3656
|
/* Auto Generated Start */
|
|
3651
3657
|
const themeLight = {
|
|
3652
3658
|
primaryColor: '#010205',
|
|
@@ -3790,36 +3796,20 @@ const focusPseudoJssStyle = {
|
|
|
3790
3796
|
outline: 0,
|
|
3791
3797
|
},
|
|
3792
3798
|
};
|
|
3793
|
-
const getTextHiddenJssStyle = (isHidden) => isHidden
|
|
3794
|
-
? getScreenReaderOnlyJssStyle()
|
|
3795
|
-
: {
|
|
3796
|
-
position: 'static',
|
|
3797
|
-
width: 'auto',
|
|
3798
|
-
height: 'auto',
|
|
3799
|
-
margin: 0,
|
|
3800
|
-
overflow: 'visible',
|
|
3801
|
-
clip: 'auto',
|
|
3802
|
-
clipPath: 'none',
|
|
3803
|
-
whiteSpace: 'normal',
|
|
3804
|
-
};
|
|
3805
|
-
const getFormTextHiddenJssStyle = (isHidden) => (Object.assign(Object.assign({}, getTextHiddenJssStyle(isHidden)), { width: 'fit-content' }));
|
|
3806
|
-
const getFormCheckboxRadioHiddenJssStyle = (isHidden) => (Object.assign(Object.assign({}, getTextHiddenJssStyle(isHidden)), { width: 'auto', padding: `2px 0 0 ${spacingStaticSmall}` }));
|
|
3807
3799
|
/**
|
|
3808
|
-
*
|
|
3800
|
+
* Returns a JSS style object that can be used to visually hide text in the browser, while still allowing it to be accessed by screen readers.
|
|
3801
|
+
* @param {boolean} isHidden - A boolean value indicating whether the text should be hidden or not. Defaults to true.
|
|
3802
|
+
* @param {JssStyle} isShownJssStyle - Additional styles applied when isHidden = false
|
|
3803
|
+
* @returns {JssStyle} - A JSS style object containing styles depending on the value of isHidden and isShownJssStyle.
|
|
3809
3804
|
*/
|
|
3810
|
-
const
|
|
3811
|
-
|
|
3805
|
+
const getHiddenTextJssStyle = (isHidden = true, isShownJssStyle) => isHidden
|
|
3806
|
+
? {
|
|
3812
3807
|
position: 'absolute',
|
|
3808
|
+
width: 0,
|
|
3813
3809
|
height: '1px',
|
|
3814
|
-
|
|
3815
|
-
|
|
3816
|
-
|
|
3817
|
-
overflow: 'hidden',
|
|
3818
|
-
clip: 'rect(1px,1px,1px,1px)',
|
|
3819
|
-
clipPath: 'inset(50%)',
|
|
3820
|
-
whiteSpace: 'nowrap',
|
|
3821
|
-
};
|
|
3822
|
-
};
|
|
3810
|
+
textIndent: '-999999px',
|
|
3811
|
+
}
|
|
3812
|
+
: Object.assign({ position: 'static', width: 'auto', height: 'auto', textIndent: 0 }, isShownJssStyle);
|
|
3823
3813
|
const getBackfaceVisibilityJssStyle = () => ({
|
|
3824
3814
|
backfaceVisibility: 'hidden',
|
|
3825
3815
|
WebkitBackfaceVisibility: 'hidden',
|
|
@@ -3854,7 +3844,7 @@ const jss = createJss({
|
|
|
3854
3844
|
jssGlobal(),
|
|
3855
3845
|
jssNested(),
|
|
3856
3846
|
camelCase(),
|
|
3857
|
-
|
|
3847
|
+
jssPluginSortMediaQueries({ combineMediaQueries: true }),
|
|
3858
3848
|
],
|
|
3859
3849
|
});
|
|
3860
3850
|
const getCss = (jssStyles) => jss
|
|
@@ -3932,7 +3922,7 @@ const getComponentCss$Y = (size, compact, open, theme) => {
|
|
|
3932
3922
|
})), hostHiddenStyles)),
|
|
3933
3923
|
button: Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({ display: 'flex', position: 'relative', justifyContent: 'space-between', width: '100%', textDecoration: 'none', border: 0, outline: 0, gap: '24px', background: 'transparent', cursor: 'pointer', textAlign: 'left', color: primaryColor }, textSmallStyle), { fontWeight: fontWeightSemiBold }), buildResponsiveStyles(size, (s) => ({
|
|
3934
3924
|
fontSize: s === 'medium' ? fontSizeTextMedium : fontSizeTextSmall,
|
|
3935
|
-
padding: `${compact ? '4px' : s === 'medium' ? '20px' : '
|
|
3925
|
+
padding: `${compact ? '4px' : s === 'medium' ? '20px' : '15px'} 0`,
|
|
3936
3926
|
}))), mergeDeep({
|
|
3937
3927
|
'&::before': Object.assign({ content: '""', position: 'absolute', borderRadius: borderRadiusSmall, left: '-4px', right: '-4px' }, (compact
|
|
3938
3928
|
? {
|
|
@@ -3958,11 +3948,16 @@ const getComponentCss$Y = (size, compact, open, theme) => {
|
|
|
3958
3948
|
},
|
|
3959
3949
|
heading: {
|
|
3960
3950
|
margin: 0,
|
|
3961
|
-
|
|
3951
|
+
},
|
|
3952
|
+
'icon-container': {
|
|
3953
|
+
height: fontLineHeight,
|
|
3954
|
+
display: 'flex',
|
|
3955
|
+
alignItems: 'center',
|
|
3962
3956
|
},
|
|
3963
3957
|
icon: {
|
|
3964
3958
|
width: fontLineHeight,
|
|
3965
3959
|
height: fontLineHeight,
|
|
3960
|
+
fontSize: fontSizeTextXXSmall,
|
|
3966
3961
|
transform: open ? 'rotate3d(0)' : 'rotate3d(0,0,1,90deg)',
|
|
3967
3962
|
transition: getTransition('transform'),
|
|
3968
3963
|
},
|
|
@@ -4001,24 +3996,25 @@ const ANIMATION_DURATION$1 = 600;
|
|
|
4001
3996
|
const duration$1 = `var(${cssVariableAnimationDuration},${ANIMATION_DURATION$1}ms)`;
|
|
4002
3997
|
const easeInQuad$1 = 'cubic-bezier(0.45,0,0.55,1)';
|
|
4003
3998
|
const easeOutQuad$1 = 'cubic-bezier(0.5,1,0.89,1)';
|
|
3999
|
+
const topBottomFallback = '56px';
|
|
4004
4000
|
const getComponentCss$X = (isOpen) => {
|
|
4005
4001
|
return getCss({
|
|
4006
4002
|
'@global': {
|
|
4007
|
-
':host': addImportantToEachRule(Object.assign(Object.assign(Object.assign(Object.assign({
|
|
4003
|
+
':host': addImportantToEachRule(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({ position: 'fixed', bottom: `var(${cssVariableBottom},${topBottomFallback})`, left: gridExtendedOffsetBase, right: gridExtendedOffsetBase, margin: 0, padding: 0, width: 'auto', maxWidth: '100%', zIndex: `var(${cssVariableZIndex},${BANNER_Z_INDEX})` }, dropShadowHighStyle), { borderRadius: borderRadiusSmall }), (isOpen
|
|
4008
4004
|
? {
|
|
4009
4005
|
opacity: 1,
|
|
4010
4006
|
visibility: 'inherit',
|
|
4011
4007
|
transform: 'translate3d(0,0,0)',
|
|
4012
|
-
transition: `opacity ${duration$1} ${easeInQuad$1},
|
|
4008
|
+
transition: `opacity ${duration$1} ${easeInQuad$1},transform ${duration$1} ${easeInQuad$1}`,
|
|
4013
4009
|
}
|
|
4014
4010
|
: {
|
|
4015
4011
|
opacity: 0,
|
|
4016
4012
|
visibility: 'hidden',
|
|
4017
|
-
transform: `translate3d(0,calc(var(${cssVariableBottom}) + 100%),0)`,
|
|
4013
|
+
transform: `translate3d(0,calc(var(${cssVariableBottom},${topBottomFallback}) + 100%),0)`,
|
|
4018
4014
|
'&(.hydrated),&(.ssr)': {
|
|
4019
|
-
transition: `visibility 0s linear ${duration$1},
|
|
4015
|
+
transition: `visibility 0s linear ${duration$1},opacity ${duration$1} ${easeOutQuad$1},transform ${duration$1} ${easeOutQuad$1}`,
|
|
4020
4016
|
},
|
|
4021
|
-
})), { [getMediaQueryMin('s')]: Object.assign({ top: `var(${cssVariableTop})`, bottom: 'auto', left: gridExtendedOffsetS, right: gridExtendedOffsetS }, (!isOpen && { transform: `translate3d(0,calc(-100% - var(${cssVariableTop})),0)` })), [getMediaQueryMin('xxl')]: {
|
|
4017
|
+
})), { [getMediaQueryMin('s')]: Object.assign({ top: `var(${cssVariableTop},${topBottomFallback})`, bottom: 'auto', left: gridExtendedOffsetS, right: gridExtendedOffsetS }, (!isOpen && { transform: `translate3d(0,calc(-100% - var(${cssVariableTop},${topBottomFallback})),0)` })), [getMediaQueryMin('xxl')]: {
|
|
4022
4018
|
left: gridExtendedOffsetXXL,
|
|
4023
4019
|
right: gridExtendedOffsetXXL,
|
|
4024
4020
|
} }), hostHiddenStyles)),
|
|
@@ -4081,7 +4077,7 @@ const getLinkButtonPureStyles = (icon, iconSource, active, isDisabledOrLoading,
|
|
|
4081
4077
|
fontSize: getFontSizeText(sizeValue),
|
|
4082
4078
|
})))), { '&::before': Object.assign(Object.assign(Object.assign({ content: '""', position: 'absolute', top: offsetVertical, bottom: offsetVertical }, buildResponsiveStyles(hideLabel, (hideLabelValue) => ({
|
|
4083
4079
|
right: hideLabelValue ? offsetVertical : offsetHorizontal,
|
|
4084
|
-
left: hideLabelValue
|
|
4080
|
+
left: hideLabelValue ? offsetVertical : offsetHorizontal,
|
|
4085
4081
|
}))), { borderRadius: borderRadiusSmall, transition: getTransition('background-color') }), (active && Object.assign(Object.assign({}, frostedGlassStyle), { backgroundColor: hoverColor }))) }), (!isDisabledOrLoading &&
|
|
4086
4082
|
hoverMediaQuery({
|
|
4087
4083
|
'&:hover::before': Object.assign(Object.assign({}, frostedGlassStyle), { backgroundColor: hoverColor }),
|
|
@@ -4100,6 +4096,12 @@ const getLinkButtonPureStyles = (icon, iconSource, active, isDisabledOrLoading,
|
|
|
4100
4096
|
flexShrink: '0',
|
|
4101
4097
|
width: fontLineHeight,
|
|
4102
4098
|
height: fontLineHeight,
|
|
4099
|
+
// workaround for Safari to optimize vertical alignment of icons
|
|
4100
|
+
// TODO: check if this is still needed after optimized icons are included
|
|
4101
|
+
'@supports (width: round(down, 1px, 1px))': {
|
|
4102
|
+
width: `round(down, ${fontLineHeight}, 1px)`,
|
|
4103
|
+
height: `round(down, ${fontLineHeight}, 1px)`,
|
|
4104
|
+
},
|
|
4103
4105
|
},
|
|
4104
4106
|
label: mergeDeep(buildResponsiveStyles(hideLabel, getVisibilityJssStyle), buildResponsiveStyles(alignLabel, (alignLabelValue) => ({
|
|
4105
4107
|
order: alignLabelValue === 'left' ? -1 : 0,
|
|
@@ -4277,17 +4279,7 @@ const getLinkButtonStyles = (icon, iconSource, variant, hideLabel, isDisabledOrL
|
|
|
4277
4279
|
})), (!isDisabledOrLoading &&
|
|
4278
4280
|
hoverMediaQuery({
|
|
4279
4281
|
'&:hover': Object.assign({ backgroundColor: backgroundColorHover, borderColor: isHighContrastMode ? focusColor : borderColorHover }, (!isPrimary && frostedGlassStyle)),
|
|
4280
|
-
}))), label:
|
|
4281
|
-
? {
|
|
4282
|
-
width: 0,
|
|
4283
|
-
height: '1px',
|
|
4284
|
-
textIndent: '-999999px',
|
|
4285
|
-
}
|
|
4286
|
-
: {
|
|
4287
|
-
width: 'auto',
|
|
4288
|
-
height: 'auto',
|
|
4289
|
-
textIndent: 0,
|
|
4290
|
-
})) }, (hasIcon && {
|
|
4282
|
+
}))), label: buildResponsiveStyles(hideLabel, getHiddenTextJssStyle) }, (hasIcon && {
|
|
4291
4283
|
icon: {
|
|
4292
4284
|
width: fontLineHeight,
|
|
4293
4285
|
height: fontLineHeight,
|
|
@@ -4364,22 +4356,18 @@ const getComponentCss$S = (width, hasPagination, alignHeader, theme) => {
|
|
|
4364
4356
|
[mediaQueryS]: isHeaderAlignCenter
|
|
4365
4357
|
? {
|
|
4366
4358
|
gridColumn: 2,
|
|
4367
|
-
textAlign: 'center', // relevant when text becomes multiline
|
|
4368
4359
|
}
|
|
4369
4360
|
: {
|
|
4370
4361
|
gridColumn: '1 / 3',
|
|
4371
4362
|
},
|
|
4372
4363
|
}),
|
|
4373
|
-
}, header: {
|
|
4374
|
-
|
|
4375
|
-
|
|
4376
|
-
[mediaQueryS]: Object.assign(Object.assign({ fontFamily, fontSize: fontSizeTextSmall, columnGap: spacingStaticMedium, gridTemplateColumns: `${buttonGroupWidth} minmax(0px, 1fr) ${buttonGroupWidth}` }, (isHeaderAlignCenter && {
|
|
4364
|
+
}, header: Object.assign(Object.assign({ display: 'grid', padding: `0 ${spacingMap[width].base}` }, (isHeaderAlignCenter && {
|
|
4365
|
+
textAlign: 'center',
|
|
4366
|
+
})), { [mediaQueryS]: Object.assign(Object.assign({ fontFamily, fontSize: fontSizeTextSmall, columnGap: spacingStaticMedium, gridTemplateColumns: `${buttonGroupWidth} minmax(0px, 1fr) ${buttonGroupWidth}` }, (isHeaderAlignCenter && {
|
|
4377
4367
|
justifyItems: 'center', // relevant when max-width of heading or description is reached
|
|
4378
|
-
})), { padding: `0 ${spacingMap[width].s}` }),
|
|
4379
|
-
[mediaQueryXXL]: {
|
|
4368
|
+
})), { padding: `0 ${spacingMap[width].s}` }), [mediaQueryXXL]: {
|
|
4380
4369
|
padding: `0 ${spacingMap[width].xxl}`,
|
|
4381
|
-
},
|
|
4382
|
-
}, nav: {
|
|
4370
|
+
} }), nav: {
|
|
4383
4371
|
display: 'none',
|
|
4384
4372
|
[mediaQueryS]: {
|
|
4385
4373
|
display: 'flex',
|
|
@@ -4410,7 +4398,7 @@ const getComponentCss$S = (width, hasPagination, alignHeader, theme) => {
|
|
|
4410
4398
|
} }),
|
|
4411
4399
|
'&__list': Object.assign({ display: 'flex', height: '100%' }, getBackfaceVisibilityJssStyle()),
|
|
4412
4400
|
'&__slide': Object.assign(Object.assign({ position: 'relative', flexShrink: 0 }, getBackfaceVisibilityJssStyle()), { transform: 'translateZ(0)' }),
|
|
4413
|
-
'&__sr':
|
|
4401
|
+
'&__sr': getHiddenTextJssStyle(), // appears in the DOM when sliding
|
|
4414
4402
|
} }, (hasPagination && {
|
|
4415
4403
|
pagination: Object.assign(Object.assign({}, buildResponsiveStyles(hasPagination, (hasPaginationValue) => ({
|
|
4416
4404
|
display: hasPaginationValue ? 'flex' : 'none',
|
|
@@ -4509,7 +4497,7 @@ const getCheckboxRadioJssStyle = (hideLabel, state, isDisabled, isLoading, theme
|
|
|
4509
4497
|
display: 'flex',
|
|
4510
4498
|
alignItems: 'flex-start',
|
|
4511
4499
|
},
|
|
4512
|
-
}, text: Object.assign(Object.assign(Object.assign({ order: 1, cursor: disabledOrLoading ? 'default' : 'pointer' }, textSmallStyle), { color: disabledOrLoading ? disabledColor : primaryColor, transition: getTransition('color') }), buildResponsiveStyles(hideLabel,
|
|
4500
|
+
}, text: Object.assign(Object.assign(Object.assign({ order: 1, cursor: disabledOrLoading ? 'default' : 'pointer' }, textSmallStyle), { color: disabledOrLoading ? disabledColor : primaryColor, transition: getTransition('color') }), buildResponsiveStyles(hideLabel, (isHidden) => getHiddenTextJssStyle(isHidden, { padding: `2px 0 0 ${spacingStaticSmall}` }))) }, getFunctionalComponentRequiredStyles()), getFunctionalComponentStateMessageStyles(theme, state));
|
|
4513
4501
|
};
|
|
4514
4502
|
|
|
4515
4503
|
const getInlineSVGBackgroundImage = (path) => {
|
|
@@ -4922,12 +4910,12 @@ const getComponentCss$E = (color, size, theme) => {
|
|
|
4922
4910
|
const isSizeInherit = size === 'inherit';
|
|
4923
4911
|
const isDark = isThemeDark(theme);
|
|
4924
4912
|
return getCss({
|
|
4925
|
-
'@global': Object.assign({ ':host': Object.assign({ display: 'inline-block', verticalAlign: 'top' }, addImportantToEachRule(hostHiddenStyles)), img: Object.assign(Object.assign({ display: 'block', margin: 0, padding: 0 }, (!isColorInherit && Object.assign(Object.assign({ filter: filter[theme][color] }, (isHighContrastMode &&
|
|
4913
|
+
'@global': Object.assign({ ':host': Object.assign({ display: 'inline-block', verticalAlign: 'top' }, addImportantToEachRule(hostHiddenStyles)), img: Object.assign(Object.assign({ display: 'block', margin: 0, padding: 0, pointerEvents: 'none' }, (!isColorInherit && Object.assign(Object.assign({ filter: filter[theme][color] }, (isHighContrastMode &&
|
|
4926
4914
|
getSchemedHighContrastMediaQuery({
|
|
4927
4915
|
filter: filter.light[color],
|
|
4928
4916
|
}, {
|
|
4929
4917
|
filter: filter.dark[color],
|
|
4930
|
-
}))), { WebkitAnimation: `${isDark ? keyFramesDark : keyFramesLight} 1ms` }))), (isSizeInherit
|
|
4918
|
+
}))), { WebkitAnimation: `${isDark ? `${keyFramesDark}-${color}` : `${keyFramesLight}-${color}`} 1ms` }))), (isSizeInherit
|
|
4931
4919
|
? {
|
|
4932
4920
|
width: size,
|
|
4933
4921
|
height: size,
|
|
@@ -4937,7 +4925,7 @@ const getComponentCss$E = (color, size, theme) => {
|
|
|
4937
4925
|
height: fontLineHeight,
|
|
4938
4926
|
font: `${sizeMap$2[size]} ${fontFamily}`,
|
|
4939
4927
|
})) }, (!isColorInherit && {
|
|
4940
|
-
[`@keyframes ${isDark ? keyFramesDark : keyFramesLight}`]: forceRerenderAnimationStyle,
|
|
4928
|
+
[`@keyframes ${isDark ? `${keyFramesDark}-${color}` : `${keyFramesLight}-${color}`}`]: forceRerenderAnimationStyle,
|
|
4941
4929
|
})),
|
|
4942
4930
|
});
|
|
4943
4931
|
};
|
|
@@ -5000,7 +4988,6 @@ const getComponentCss$D = (state, hasAction, hasClose, theme) => {
|
|
|
5000
4988
|
|
|
5001
4989
|
const getComponentCss$C = (icon, iconSource, active, stretch, size, hideLabel, alignLabel, underline, hasSlottedAnchor, theme) => {
|
|
5002
4990
|
const { focusColor } = getThemedColors(theme);
|
|
5003
|
-
const hasIcon = hasVisibleIcon(icon, iconSource);
|
|
5004
4991
|
return getCss(mergeDeep(getLinkButtonPureStyles(icon, iconSource, active, false, stretch, size, hideLabel, alignLabel, hasSlottedAnchor, theme), Object.assign(Object.assign({}, (hasSlottedAnchor && {
|
|
5005
4992
|
'@global': addImportantToEachRule({
|
|
5006
4993
|
'::slotted': {
|
|
@@ -5010,7 +4997,7 @@ const getComponentCss$C = (icon, iconSource, active, stretch, size, hideLabel, a
|
|
|
5010
4997
|
// (https://bugs.webkit.org/show_bug.cgi?id=178237)
|
|
5011
4998
|
'&(a)::before': Object.assign({ content: '""', position: 'fixed', top: offsetVertical, bottom: offsetVertical, borderRadius: borderRadiusSmall }, buildResponsiveStyles(hideLabel, (hideLabelValue) => ({
|
|
5012
4999
|
right: hideLabelValue ? offsetVertical : offsetHorizontal,
|
|
5013
|
-
left: hideLabelValue
|
|
5000
|
+
left: hideLabelValue ? offsetVertical : offsetHorizontal,
|
|
5014
5001
|
}))),
|
|
5015
5002
|
'&(a:focus)::before': {
|
|
5016
5003
|
border: `${borderWidthBase} solid ${focusColor}`,
|
|
@@ -5053,6 +5040,7 @@ const getComponentCss$B = (icon, iconSource, variant, hideLabel, hasSlottedAncho
|
|
|
5053
5040
|
}) })))));
|
|
5054
5041
|
};
|
|
5055
5042
|
|
|
5043
|
+
// array is redefined instead of using the one from in model-signature
|
|
5056
5044
|
const LINK_TILE_MODEL_SIGNATURE_HEADING_TAGS = ['h2', 'h3', 'h4', 'h5', 'h6'];
|
|
5057
5045
|
|
|
5058
5046
|
const getComponentCss$A = (aspectRatio, weight, direction, hasDescription) => {
|
|
@@ -5104,7 +5092,7 @@ const getComponentCss$y = (size) => {
|
|
|
5104
5092
|
|
|
5105
5093
|
const mediaQueryXl = getMediaQueryMin('xl');
|
|
5106
5094
|
const { backgroundColor, primaryColor: lightThemePrimaryColor } = getThemedColors('light');
|
|
5107
|
-
const { primaryColor: darkThemePrimaryColor } = getThemedColors('dark');
|
|
5095
|
+
const { primaryColor: darkThemePrimaryColor, contrastHighColor: darkThemeContrastHighColor } = getThemedColors('dark');
|
|
5108
5096
|
const transitionTimingFunction = 'cubic-bezier(.16,1,.3,1)';
|
|
5109
5097
|
const stretchToFullModalWidthClassName = 'stretch-to-full-modal-width';
|
|
5110
5098
|
const getFullscreenJssStyles = (fullscreen) => {
|
|
@@ -5202,8 +5190,8 @@ const getComponentCss$x = (isOpen, isFullscreen, hasDismissButton, hasHeader) =>
|
|
|
5202
5190
|
})), (hasDismissButton && {
|
|
5203
5191
|
dismiss: Object.assign({ position: 'absolute', top: '8px', right: '8px', border: `2px solid ${backgroundColor}`, borderRadius: '4px', background: backgroundColor }, hoverMediaQuery({
|
|
5204
5192
|
'&:hover': {
|
|
5205
|
-
background:
|
|
5206
|
-
borderColor:
|
|
5193
|
+
background: darkThemeContrastHighColor,
|
|
5194
|
+
borderColor: darkThemeContrastHighColor,
|
|
5207
5195
|
},
|
|
5208
5196
|
})),
|
|
5209
5197
|
})));
|
|
@@ -5381,7 +5369,7 @@ const getComponentCss$u = (direction, theme) => {
|
|
|
5381
5369
|
borderColor: 'transparent',
|
|
5382
5370
|
} }),
|
|
5383
5371
|
},
|
|
5384
|
-
label:
|
|
5372
|
+
label: getHiddenTextJssStyle(),
|
|
5385
5373
|
icon: {
|
|
5386
5374
|
display: 'inline-block',
|
|
5387
5375
|
transform: 'translate3d(0,0,0)', // Fixes movement on hover in Safari
|
|
@@ -5586,6 +5574,7 @@ const getComponentCss$q = (maxWidth) => {
|
|
|
5586
5574
|
},
|
|
5587
5575
|
});
|
|
5588
5576
|
};
|
|
5577
|
+
|
|
5589
5578
|
const getBaseChildStyles = (child, state, theme, additionalDefaultJssStyle) => {
|
|
5590
5579
|
const { primaryColor, contrastLowColor, contrastMediumColor, disabledColor } = getThemedColors(theme);
|
|
5591
5580
|
const { formStateColor, formStateHoverColor } = getThemedFormStateColors(theme, state);
|
|
@@ -5619,7 +5608,7 @@ const getLabelStyles = (child, isDisabled, hideLabel, state, theme, counterOrUni
|
|
|
5619
5608
|
flexDirection: 'column',
|
|
5620
5609
|
gap: spacingStaticXSmall,
|
|
5621
5610
|
position: 'relative',
|
|
5622
|
-
'&__text': Object.assign(Object.assign(Object.assign(Object.assign({ display: 'block' }, buildResponsiveStyles(hideLabel,
|
|
5611
|
+
'&__text': Object.assign(Object.assign(Object.assign(Object.assign({ display: 'block' }, buildResponsiveStyles(hideLabel, (isHidden) => getHiddenTextJssStyle(isHidden, { width: 'fit-content' }))), textSmallStyle), { color: isDisabled ? disabledColor : primaryColor, transition: getTransition('color'), '&+&': Object.assign({ marginTop: `-${spacingStaticXSmall}`, fontSize: fontSizeTextXSmall }, (!isDisabled && {
|
|
5623
5612
|
color: contrastHighColor,
|
|
5624
5613
|
})) }), hoverMediaQuery({
|
|
5625
5614
|
'&:hover': {
|
|
@@ -5636,14 +5625,10 @@ const getLabelStyles = (child, isDisabled, hideLabel, state, theme, counterOrUni
|
|
|
5636
5625
|
})),
|
|
5637
5626
|
}));
|
|
5638
5627
|
};
|
|
5639
|
-
|
|
5640
|
-
const
|
|
5641
|
-
|
|
5642
|
-
|
|
5643
|
-
zIndex: 0,
|
|
5644
|
-
cursor: 'pointer',
|
|
5645
|
-
padding: `8px ${ICON_SPACE} 8px ${spacingStaticMedium}`,
|
|
5646
|
-
}))), root: {
|
|
5628
|
+
|
|
5629
|
+
const OPTION_HEIGHT = 40; // optgroups are higher and ignored
|
|
5630
|
+
const getComponentCss$p = (isDisabled, native, hideLabel, state, theme) => {
|
|
5631
|
+
return getCss(Object.assign(Object.assign(Object.assign({ '@global': addImportantToEachRule(Object.assign({ ':host': Object.assign({ display: 'block' }, hostHiddenStyles) }, getBaseChildStyles('select', state, theme, Object.assign({ position: 'static', zIndex: 0, cursor: 'pointer', padding: `8px calc(${fontLineHeight} + 10px + ${borderWidthBase} * 2 + ${spacingStaticSmall} * 2) 8px ${spacingStaticMedium}` }, (!native && !isDisabled && { borderColor: 'transparent' }))))), root: {
|
|
5647
5632
|
display: 'block',
|
|
5648
5633
|
position: 'relative',
|
|
5649
5634
|
} }, getLabelStyles('select', isDisabled, hideLabel, state, theme, {
|
|
@@ -5660,6 +5645,129 @@ const getComponentCss$p = (isDisabled, hideLabel, state, theme) => {
|
|
|
5660
5645
|
})), getFunctionalComponentRequiredStyles()), getFunctionalComponentStateMessageStyles(theme, state)));
|
|
5661
5646
|
};
|
|
5662
5647
|
|
|
5648
|
+
const dropdownPositionVar = '--p-internal-dropdown-position';
|
|
5649
|
+
const getButtonStyles = (direction, isOpen, state, theme) => {
|
|
5650
|
+
const { primaryColor, disabledColor, contrastMediumColor } = getThemedColors(theme);
|
|
5651
|
+
const { formStateHoverColor, formStateColor } = getThemedFormStateColors(theme, state);
|
|
5652
|
+
const isDirectionDown = direction === 'down';
|
|
5653
|
+
return {
|
|
5654
|
+
'@global': {
|
|
5655
|
+
button: Object.assign(Object.assign(Object.assign({ position: 'absolute', top: 0, height: `calc(${fontLineHeight} + 10px + ${borderWidthBase} * 2 + ${spacingStaticSmall} * 2)`, width: '100%', font: textSmallStyle.font.replace('ex', 'ex + 6px'), padding: 0, background: 'transparent', border: `${borderWidthBase} solid ${isOpen ? primaryColor : formStateColor || contrastMediumColor}`, borderRadius: borderRadiusSmall, outline: '0', cursor: 'pointer', transition: getTransition('border-color'), '&:focus, &:focus ~ ul': {
|
|
5656
|
+
borderColor: primaryColor,
|
|
5657
|
+
} }, hoverMediaQuery({
|
|
5658
|
+
'&:not(:disabled):not(:focus):hover': {
|
|
5659
|
+
borderColor: isOpen ? primaryColor : formStateHoverColor || primaryColor,
|
|
5660
|
+
},
|
|
5661
|
+
})), { '&:disabled': {
|
|
5662
|
+
cursor: 'not-allowed',
|
|
5663
|
+
borderColor: disabledColor,
|
|
5664
|
+
} }), (isOpen && {
|
|
5665
|
+
[isDirectionDown ? 'borderBottomLeftRadius' : 'borderTopLeftRadius']: 0,
|
|
5666
|
+
[isDirectionDown ? 'borderBottomRightRadius' : 'borderTopRightRadius']: 0,
|
|
5667
|
+
})),
|
|
5668
|
+
},
|
|
5669
|
+
};
|
|
5670
|
+
};
|
|
5671
|
+
const getFilterStyles = (direction, isOpen, state, disabled, theme) => {
|
|
5672
|
+
const { primaryColor, backgroundColor, disabledColor, contrastMediumColor } = getThemedColors(theme);
|
|
5673
|
+
const { formStateHoverColor, formStateColor } = getThemedFormStateColors(theme, state);
|
|
5674
|
+
const isDirectionDown = direction === 'down';
|
|
5675
|
+
const placeHolderJssStyle = {
|
|
5676
|
+
opacity: 1,
|
|
5677
|
+
color: disabled ? disabledColor : primaryColor,
|
|
5678
|
+
};
|
|
5679
|
+
return {
|
|
5680
|
+
'@global': {
|
|
5681
|
+
input: Object.assign(Object.assign(Object.assign(Object.assign({ display: 'block', position: 'absolute', zIndex: 1, bottom: '2px', left: '2px', width: `calc(100% - (${fontLineHeight} + 6px + ${borderWidthBase} * 2 + ${spacingStaticSmall} * 2))`, height: `calc(${fontLineHeight} + 6px + ${borderWidthBase} * 2 + ${spacingStaticSmall} * 2)`, font: textSmallStyle.font.replace('ex', 'ex + 6px'), padding: `13px ${spacingStaticMedium}`, outline: '0', appearance: 'none', boxSizing: 'border-box', border: '0', borderRadius: borderRadiusSmall, opacity: 0 }, textSmallStyle), { textIndent: 0, cursor: disabled ? 'not-allowed' : 'text', color: primaryColor, background: backgroundColor, '&::placeholder': placeHolderJssStyle, '&::-webkit-input-placeholder': placeHolderJssStyle, '&::-moz-placeholder': placeHolderJssStyle, '&:not(:disabled):focus': {
|
|
5682
|
+
opacity: 1,
|
|
5683
|
+
'&+span, &~ ul': {
|
|
5684
|
+
borderColor: primaryColor,
|
|
5685
|
+
},
|
|
5686
|
+
} }), hoverMediaQuery({
|
|
5687
|
+
'&:not(:disabled)': {
|
|
5688
|
+
'&+span:hover': {
|
|
5689
|
+
borderColor: isOpen ? primaryColor : formStateHoverColor || primaryColor,
|
|
5690
|
+
},
|
|
5691
|
+
'&:hover': {
|
|
5692
|
+
'&+span, &~ul': {
|
|
5693
|
+
borderColor: isOpen ? primaryColor : formStateHoverColor || primaryColor,
|
|
5694
|
+
},
|
|
5695
|
+
},
|
|
5696
|
+
},
|
|
5697
|
+
})), { '&+span': Object.assign(Object.assign(Object.assign({
|
|
5698
|
+
// for focus outline and clicking arrow since input ends left of the icon
|
|
5699
|
+
position: 'absolute' }, getInsetJssStyle()), { transition: getTransition('border-color'), pointerEvents: 'all', cursor: disabled ? 'not-allowed' : 'pointer', border: `${borderWidthBase} solid ${isOpen ? primaryColor : formStateColor || contrastMediumColor}`, borderRadius: borderRadiusSmall }), (isOpen && {
|
|
5700
|
+
[isDirectionDown ? 'borderBottomLeftRadius' : 'borderTopLeftRadius']: 0,
|
|
5701
|
+
[isDirectionDown ? 'borderBottomRightRadius' : 'borderTopRightRadius']: 0,
|
|
5702
|
+
})) }),
|
|
5703
|
+
},
|
|
5704
|
+
};
|
|
5705
|
+
};
|
|
5706
|
+
const getListStyles = (direction, theme) => {
|
|
5707
|
+
const isDirectionDown = direction === 'down';
|
|
5708
|
+
const { primaryColor, backgroundColor, contrastMediumColor, contrastHighColor, backgroundSurfaceColor, disabledColor, } = getThemedColors(theme);
|
|
5709
|
+
const { highlightColor } = getHighContrastColors();
|
|
5710
|
+
return {
|
|
5711
|
+
'@global': {
|
|
5712
|
+
ul: Object.assign(Object.assign(Object.assign(Object.assign({ display: 'flex', flexDirection: 'column', gap: spacingStaticSmall, position: `var(${dropdownPositionVar})`, padding: '6px', margin: 0, background: backgroundColor }, textSmallStyle), { zIndex: 10, left: 0, right: 0, [isDirectionDown ? 'top' : 'bottom']: 'calc(100% - 2px)', boxSizing: 'border-box', maxHeight: `${8.5 * (OPTION_HEIGHT + 8) + 6 + 2}px`, overflowY: 'auto', WebkitOverflowScrolling: 'touch', scrollBehavior: 'smooth', border: `2px solid ${primaryColor}`, [isDirectionDown ? 'borderTop' : 'borderBottom']: addImportantToRule(`1px solid ${contrastMediumColor}`) }), (isDirectionDown
|
|
5713
|
+
? ['borderBottomLeftRadius', 'borderBottomRightRadius']
|
|
5714
|
+
: ['borderTopLeftRadius', 'borderTopRightRadius']).reduce((result, curr) => (Object.assign(Object.assign({}, result), { [curr]: borderRadiusSmall })), {})), { scrollbarWidth: 'thin', scrollbarColor: 'auto', transition: getTransition('border-color'), transform: 'translate3d(0,0,0)' }),
|
|
5715
|
+
},
|
|
5716
|
+
option: Object.assign(Object.assign({ display: 'flex', justifyContent: 'space-between', gap: '12px', padding: `${spacingStaticSmall} 12px`, flex: `1 0 calc(${fontLineHeight} + ${spacingStaticSmall} * 2)`, color: contrastHighColor, cursor: 'pointer', textAlign: 'left', wordBreak: 'break-word', boxSizing: 'border-box', borderRadius: borderRadiusSmall, transition: ['background-color', 'color'].map(getTransition).join(), '&[role=status]': {
|
|
5717
|
+
cursor: 'not-allowed',
|
|
5718
|
+
}, '&__sr': getHiddenTextJssStyle() }, hoverMediaQuery({
|
|
5719
|
+
'&:not([aria-disabled]):not([role=status]):hover': {
|
|
5720
|
+
color: isHighContrastMode ? highlightColor : primaryColor,
|
|
5721
|
+
background: backgroundSurfaceColor,
|
|
5722
|
+
},
|
|
5723
|
+
})), { '&--highlighted, &--selected': {
|
|
5724
|
+
color: isHighContrastMode ? highlightColor : primaryColor,
|
|
5725
|
+
background: backgroundSurfaceColor,
|
|
5726
|
+
}, '&--selected': {
|
|
5727
|
+
cursor: 'default',
|
|
5728
|
+
pointerEvents: 'none',
|
|
5729
|
+
}, '&--disabled': {
|
|
5730
|
+
cursor: 'not-allowed',
|
|
5731
|
+
color: disabledColor,
|
|
5732
|
+
}, '&--hidden': {
|
|
5733
|
+
display: 'none',
|
|
5734
|
+
} }),
|
|
5735
|
+
optgroup: {
|
|
5736
|
+
display: 'block',
|
|
5737
|
+
padding: '3px 14px',
|
|
5738
|
+
fontWeight: fontWeightSemiBold,
|
|
5739
|
+
'&:not(:first-child)': {
|
|
5740
|
+
marginTop: spacingStaticSmall,
|
|
5741
|
+
},
|
|
5742
|
+
'&~$option': {
|
|
5743
|
+
paddingLeft: '24px',
|
|
5744
|
+
},
|
|
5745
|
+
},
|
|
5746
|
+
};
|
|
5747
|
+
};
|
|
5748
|
+
const getComponentCss$o = (direction, isOpen, state, disabled, filter, theme) => {
|
|
5749
|
+
const { primaryColor, contrastMediumColor, disabledColor } = getThemedColors(theme);
|
|
5750
|
+
const { formStateColor, formStateHoverColor } = getThemedFormStateColors(theme, state);
|
|
5751
|
+
return getCss(
|
|
5752
|
+
// merge because of global styles
|
|
5753
|
+
mergeDeep({
|
|
5754
|
+
'@global': {
|
|
5755
|
+
':host': Object.assign({ [dropdownPositionVar]: 'absolute', display: 'block', position: `var(${dropdownPositionVar})`, font: textSmallStyle.font.replace('ex', 'ex + 6px'), marginTop: `calc(-1 * (${fontLineHeight} + 10px + ${borderWidthBase} * 2 + ${spacingStaticSmall} * 2))`, paddingTop: `calc(${fontLineHeight} + 10px + ${borderWidthBase} * 2 + ${spacingStaticSmall} * 2)`, left: 0, right: 0, color: disabled ? disabledColor : formStateColor || contrastMediumColor }, (!disabled &&
|
|
5756
|
+
!isHighContrastMode &&
|
|
5757
|
+
hoverMediaQuery({
|
|
5758
|
+
'&(:hover)': {
|
|
5759
|
+
color: formStateHoverColor || primaryColor,
|
|
5760
|
+
},
|
|
5761
|
+
}))),
|
|
5762
|
+
},
|
|
5763
|
+
'sr-text': {
|
|
5764
|
+
display: 'none',
|
|
5765
|
+
},
|
|
5766
|
+
}, filter
|
|
5767
|
+
? getFilterStyles(direction, isOpen, state, disabled, theme)
|
|
5768
|
+
: getButtonStyles(direction, isOpen, state, theme), isOpen && getListStyles(direction, theme)));
|
|
5769
|
+
};
|
|
5770
|
+
|
|
5663
5771
|
const sizeSmall = '48px';
|
|
5664
5772
|
const sizeMedium = '72px';
|
|
5665
5773
|
const sizeLarge = '104px';
|
|
@@ -5722,7 +5830,7 @@ const getComponentCss$n = (size, theme) => {
|
|
|
5722
5830
|
},
|
|
5723
5831
|
},
|
|
5724
5832
|
root: Object.assign(Object.assign({ display: 'block' }, buildResponsiveStyles(size, (s) => sizeMap$1[s])), { margin: 0, padding: 0, boxSizing: 'border-box', strokeWidth: 1.5 }),
|
|
5725
|
-
'sr-only':
|
|
5833
|
+
'sr-only': getHiddenTextJssStyle(),
|
|
5726
5834
|
});
|
|
5727
5835
|
};
|
|
5728
5836
|
|
|
@@ -5785,7 +5893,7 @@ const getComponentCss$m = (state, disabled, theme) => {
|
|
|
5785
5893
|
height: fontLineHeight,
|
|
5786
5894
|
width: fontLineHeight,
|
|
5787
5895
|
},
|
|
5788
|
-
})), { 'sr-only':
|
|
5896
|
+
})), { 'sr-only': getHiddenTextJssStyle() }));
|
|
5789
5897
|
};
|
|
5790
5898
|
|
|
5791
5899
|
const getComponentCss$l = (size) => {
|
|
@@ -5875,7 +5983,7 @@ const getComponentCss$k = (alignLabel, hideLabel, stretch, checked, disabled, lo
|
|
|
5875
5983
|
},
|
|
5876
5984
|
})), { label: Object.assign(Object.assign(Object.assign({}, textSmallStyle), { paddingTop: '2px', minWidth: 0, minHeight: 0, color: textColor }), mergeDeep(buildResponsiveStyles(alignLabel, (alignLabelValue) => ({
|
|
5877
5985
|
order: alignLabelValue === 'left' ? -1 : 0,
|
|
5878
|
-
})), buildResponsiveStyles(hideLabel,
|
|
5986
|
+
})), buildResponsiveStyles(hideLabel, getHiddenTextJssStyle))) }));
|
|
5879
5987
|
};
|
|
5880
5988
|
|
|
5881
5989
|
const getComponentCss$j = () => {
|
|
@@ -5957,7 +6065,7 @@ const getComponentCss$g = (active, direction, hideLabel, multiline) => {
|
|
|
5957
6065
|
} }),
|
|
5958
6066
|
}
|
|
5959
6067
|
: hideLabel && {
|
|
5960
|
-
span: Object.assign(Object.assign({},
|
|
6068
|
+
span: Object.assign(Object.assign({}, getHiddenTextJssStyle()), { display: 'block', border: 0 }),
|
|
5961
6069
|
})) }, (sortable && {
|
|
5962
6070
|
icon: {
|
|
5963
6071
|
transition: getTransition('opacity'),
|
|
@@ -6027,9 +6135,9 @@ const getComponentCss$c = (size, weight, theme) => {
|
|
|
6027
6135
|
display: 'block',
|
|
6028
6136
|
position: 'absolute',
|
|
6029
6137
|
width: 0,
|
|
6030
|
-
height:
|
|
6138
|
+
height: '2px',
|
|
6031
6139
|
left: 0,
|
|
6032
|
-
bottom: isHighContrastMode ? '
|
|
6140
|
+
bottom: isHighContrastMode ? '0' : '-2px',
|
|
6033
6141
|
background: isHighContrastMode ? getHighContrastColors().canvasTextColor : primaryColor,
|
|
6034
6142
|
'&--enable-transition': {
|
|
6035
6143
|
willChange: 'width',
|
|
@@ -6108,7 +6216,7 @@ const getComponentCss$9 = (color, hasLabel, theme) => {
|
|
|
6108
6216
|
marginRight: '10px',
|
|
6109
6217
|
transition: getTransition('background-color'),
|
|
6110
6218
|
borderRadius: borderRadiusSmall,
|
|
6111
|
-
}, 'sr-only':
|
|
6219
|
+
}, 'sr-only': getHiddenTextJssStyle() }));
|
|
6112
6220
|
};
|
|
6113
6221
|
|
|
6114
6222
|
const getThemedBackgroundHoverColor = (tagColor, themedColors, theme) => {
|
|
@@ -6236,7 +6344,7 @@ const getComponentCss$7 = (isDisabled, hideLabel, state, hasUnitOrVisibleCounter
|
|
|
6236
6344
|
},
|
|
6237
6345
|
})), getFunctionalComponentRequiredStyles()), getFunctionalComponentStateMessageStyles(theme, state)), {
|
|
6238
6346
|
// TODO: could be made conditional if we had hasUnit
|
|
6239
|
-
'sr-only': Object.assign(Object.assign({},
|
|
6347
|
+
'sr-only': Object.assign(Object.assign({}, getHiddenTextJssStyle()), { padding: 0 }) }));
|
|
6240
6348
|
};
|
|
6241
6349
|
|
|
6242
6350
|
/** @deprecated */
|
|
@@ -6333,7 +6441,7 @@ const getComponentCss$3 = (isDisabled, hideLabel, state, hasCounter, theme) => {
|
|
|
6333
6441
|
color: contrastMediumColor,
|
|
6334
6442
|
},
|
|
6335
6443
|
})), getFunctionalComponentRequiredStyles()), getFunctionalComponentStateMessageStyles(theme, state)), (hasCounter && {
|
|
6336
|
-
'sr-only': Object.assign(Object.assign({},
|
|
6444
|
+
'sr-only': Object.assign(Object.assign({}, getHiddenTextJssStyle()), { padding: 0 }),
|
|
6337
6445
|
})));
|
|
6338
6446
|
};
|
|
6339
6447
|
|
|
@@ -6387,7 +6495,13 @@ const getComponentCss$1 = () => {
|
|
|
6387
6495
|
const getComponentCss = (size, theme) => {
|
|
6388
6496
|
return getCss({
|
|
6389
6497
|
'@global': {
|
|
6390
|
-
':host': Object.assign({ position: 'relative', display: 'inline-block', verticalAlign: 'top' }, addImportantToEachRule(Object.assign(Object.assign({ outline: 0, maxWidth: '100%', maxHeight: '100%', boxSizing: 'content-box' }, (
|
|
6498
|
+
':host': Object.assign({ position: 'relative', display: 'inline-block', verticalAlign: 'top' }, addImportantToEachRule(Object.assign(Object.assign({ outline: 0, maxWidth: '100%', maxHeight: '100%', boxSizing: 'content-box' }, (size !== 'inherit' && {
|
|
6499
|
+
height: 'clamp(0.63rem, 0.42vw + 0.5rem, 1rem)',
|
|
6500
|
+
// workaround for Safari to optimize image rendering
|
|
6501
|
+
'@supports (height: round(down, 1px, 1px))': {
|
|
6502
|
+
height: 'round(down, clamp(0.63rem, 0.42vw + 0.5rem, 1rem), 1px)',
|
|
6503
|
+
},
|
|
6504
|
+
})), hostHiddenStyles))),
|
|
6391
6505
|
'a, svg': {
|
|
6392
6506
|
display: 'block',
|
|
6393
6507
|
maxWidth: '100%',
|
|
@@ -6402,4 +6516,4 @@ const getComponentCss = (size, theme) => {
|
|
|
6402
6516
|
});
|
|
6403
6517
|
};
|
|
6404
6518
|
|
|
6405
|
-
export { getComponentCss$Y as getAccordionCss, getComponentCss$X as getBannerCss, getComponentCss$T as getButtonCss, getComponentCss$W as getButtonGroupCss, getComponentCss$V as getButtonPureCss, getComponentCss$U as getButtonTileCss, getComponentCss$S as getCarouselCss, getComponentCss$R as getCheckboxWrapperCss, getComponentCss$Q as getContentWrapperCss, getComponentCss$P as getCrestCss, getComponentCss$O as getDisplayCss, getComponentCss$N as getDividerCss, getComponentCss$L as getFieldsetCss, getComponentCss$M as getFieldsetWrapperCss, getComponentCss$J as getFlexCss, getComponentCss$K as getFlexItemCss, getFunctionalComponentRequiredStyles, getFunctionalComponentStateMessageStyles, getComponentCss$H as getGridCss, getComponentCss$I as getGridItemCss, getComponentCss$G as getHeadingCss, getComponentCss$F as getHeadlineCss, getComponentCss$E as getIconCss, getComponentCss$D as getInlineNotificationCss, getComponentCss$B as getLinkCss, getComponentCss$C as getLinkPureCss, getComponentCss$B as getLinkSocialCss, getComponentCss$z as getLinkTileCss, getComponentCss$A as getLinkTileModelSignatureCss, getComponentCss$y as getMarqueCss, getComponentCss$x as getModalCss, getComponentCss$w as getModelSignatureCss, getComponentCss$v as getPaginationCss, getComponentCss$u as getPopoverCss, getComponentCss$t as getRadioButtonWrapperCss, getComponentCss$s as getScrollerCss, getComponentCss$q as getSegmentedControlCss, getComponentCss$r as getSegmentedControlItemCss, getComponentCss$p as getSelectWrapperCss, getComponentCss$n as getSpinnerCss, getComponentCss$l as getStepperHorizontalCss, getComponentCss$m as getStepperHorizontalItemCss, getComponentCss$k as getSwitchCss, getComponentCss$j as getTableBodyCss, getComponentCss$i as getTableCellCss, getComponentCss$h as getTableCss, getComponentCss$g as getTableHeadCellCss, getComponentCss$e as getTableHeadCss, getComponentCss$f as getTableHeadRowCss, getComponentCss$d as getTableRowCss, getComponentCss$c as getTabsBarCss, getComponentCss$a as getTabsCss, getComponentCss$b as getTabsItemCss, getComponentCss$8 as getTagCss, getComponentCss$9 as getTagDismissibleCss, getComponentCss$4 as getTextCss, getComponentCss$7 as getTextFieldWrapperCss, getComponentCss$6 as getTextListCss, getComponentCss$5 as getTextListItemCss, getComponentCss$3 as getTextareaWrapperCss, getComponentCss$1 as getToastCss, getComponentCss as getWordmarkCss };
|
|
6519
|
+
export { getComponentCss$Y as getAccordionCss, getComponentCss$X as getBannerCss, getComponentCss$T as getButtonCss, getComponentCss$W as getButtonGroupCss, getComponentCss$V as getButtonPureCss, getComponentCss$U as getButtonTileCss, getComponentCss$S as getCarouselCss, getComponentCss$R as getCheckboxWrapperCss, getComponentCss$Q as getContentWrapperCss, getComponentCss$P as getCrestCss, getComponentCss$O as getDisplayCss, getComponentCss$N as getDividerCss, getComponentCss$L as getFieldsetCss, getComponentCss$M as getFieldsetWrapperCss, getComponentCss$J as getFlexCss, getComponentCss$K as getFlexItemCss, getFunctionalComponentRequiredStyles, getFunctionalComponentStateMessageStyles, getComponentCss$H as getGridCss, getComponentCss$I as getGridItemCss, getComponentCss$G as getHeadingCss, getComponentCss$F as getHeadlineCss, getComponentCss$E as getIconCss, getComponentCss$D as getInlineNotificationCss, getComponentCss$B as getLinkCss, getComponentCss$C as getLinkPureCss, getComponentCss$B as getLinkSocialCss, getComponentCss$z as getLinkTileCss, getComponentCss$A as getLinkTileModelSignatureCss, getComponentCss$y as getMarqueCss, getComponentCss$x as getModalCss, getComponentCss$w as getModelSignatureCss, getComponentCss$v as getPaginationCss, getComponentCss$u as getPopoverCss, getComponentCss$t as getRadioButtonWrapperCss, getComponentCss$s as getScrollerCss, getComponentCss$q as getSegmentedControlCss, getComponentCss$r as getSegmentedControlItemCss, getComponentCss$p as getSelectWrapperCss, getComponentCss$o as getSelectWrapperDropdownCss, getComponentCss$n as getSpinnerCss, getComponentCss$l as getStepperHorizontalCss, getComponentCss$m as getStepperHorizontalItemCss, getComponentCss$k as getSwitchCss, getComponentCss$j as getTableBodyCss, getComponentCss$i as getTableCellCss, getComponentCss$h as getTableCss, getComponentCss$g as getTableHeadCellCss, getComponentCss$e as getTableHeadCss, getComponentCss$f as getTableHeadRowCss, getComponentCss$d as getTableRowCss, getComponentCss$c as getTabsBarCss, getComponentCss$a as getTabsCss, getComponentCss$b as getTabsItemCss, getComponentCss$8 as getTagCss, getComponentCss$9 as getTagDismissibleCss, getComponentCss$4 as getTextCss, getComponentCss$7 as getTextFieldWrapperCss, getComponentCss$6 as getTextListCss, getComponentCss$5 as getTextListItemCss, getComponentCss$3 as getTextareaWrapperCss, getComponentCss$1 as getToastCss, getComponentCss as getWordmarkCss };
|