baseui
Version:
A React Component library implementing the Base design language
51 lines (48 loc) • 1.77 kB
JavaScript
;
Object.defineProperty(exports, "__esModule", {
value: true
});
exports.StyledRoot = exports.StyledMaxLabel = exports.StyledDropdownContainer = void 0;
var _styles = require("../styles");
/*
Copyright (c) Uber Technologies, Inc.
This source code is licensed under the MIT license found in the
LICENSE file in the root directory of this source tree.
*/
const StyledRoot = exports.StyledRoot = (0, _styles.styled)('div', ({
$theme
}) => ({
display: 'flex',
alignItems: 'center',
color: $theme.colors.backgroundInversePrimary,
...$theme.typography.font350
}));
StyledRoot.displayName = "StyledRoot";
StyledRoot.displayName = 'StyledRoot';
const StyledMaxLabel = exports.StyledMaxLabel = (0, _styles.styled)('span', ({
$theme
}) => {
const marginStartDir = $theme.direction === 'rtl' ? 'marginRight' : 'marginLeft';
const marginEndDir = $theme.direction === 'rtl' ? 'marginLeft' : 'marginRight';
return {
[marginStartDir]: $theme.sizing.scale300,
[marginEndDir]: $theme.sizing.scale600
};
});
StyledMaxLabel.displayName = "StyledMaxLabel";
StyledMaxLabel.displayName = 'StyledMaxLabel';
const StyledDropdownContainer = exports.StyledDropdownContainer = (0, _styles.styled)('div', ({
$theme,
$isFocusVisible
}) => {
const marginStartDir = $theme.direction === 'rtl' ? 'marginRight' : 'marginLeft';
const marginEndDir = $theme.direction === 'rtl' ? 'marginLeft' : 'marginRight';
return {
position: 'relative',
outline: $isFocusVisible ? `3px solid ${$theme.colors.borderAccent}` : 'none',
[marginStartDir]: $theme.sizing.scale600,
[marginEndDir]: $theme.sizing.scale300
};
});
StyledDropdownContainer.displayName = "StyledDropdownContainer";
StyledDropdownContainer.displayName = 'StyledDropdownContainer';