@hitachivantara/uikit-styles
Version:
UI Kit styling solution.
82 lines (81 loc) • 2.1 kB
JavaScript
import { theme } from "./theme.js";
//#region src/CssBaseline.ts
var baseline = {
"input[type=\"search\"]::-webkit-search-decoration": { display: "none" },
"input[type=\"search\"]::-webkit-search-cancel-button": { display: "none" },
"input[type=\"search\"]::-webkit-search-results-button": { display: "none" },
"input[type=\"search\"]::-webkit-search-results-decoration": { display: "none" },
"*, ::before, ::after": {
boxSizing: "border-box",
borderWidth: "0",
borderStyle: "solid"
},
"*": { margin: 0 },
":where(h1, h2, h3, h4, h5, h6)": {
fontSize: "inherit",
fontWeight: "inherit"
},
"p, h1, h2, h3, h4, h5, h6": { overflowWrap: "break-word" },
"img, picture, video, canvas, svg": {
display: "block",
maxWidth: "100%"
},
"button, input, textarea, select, optgroup": {
fontFamily: "inherit",
fontSize: "100%"
},
select: {
width: "100%",
height: "100%",
cursor: "pointer",
background: "transparent"
},
"button:focus-visible": {
outline: "#52A8EC solid 0px",
outlineOffset: "-1px"
},
fieldset: {
margin: 0,
padding: 0
},
":where(ol, ul)": {
margin: 0,
padding: 0
},
a: {
backgroundColor: "transparent",
color: "inherit",
textDecoration: "inherit"
},
".uikit-root-element": {
backgroundColor: theme.colors.bgPage,
accentColor: theme.colors.text,
color: theme.colors.text,
fontSize: theme.typography.body.fontSize,
fontWeight: theme.typography.body.fontWeight,
lineHeight: theme.typography.body.lineHeight,
letterSpacing: theme.typography.body.letterSpacing,
fontFamily: theme.fontFamily.body
}
};
var CssScopedBaseline = {
height: "100%",
fontFamily: "inherit",
lineHeight: "inherit",
WebkitFontSmoothing: "antialiased",
MozOsxFontSmoothing: "grayscale",
...baseline
};
var CssBaseline = {
"html, body": { height: "100%" },
html: { fontFamily: "'Open Sans','Inter', Arial, Helvetica, sans-serif" },
body: {
fontFamily: "inherit",
lineHeight: "inherit",
WebkitFontSmoothing: "antialiased",
MozOsxFontSmoothing: "grayscale"
},
...baseline
};
//#endregion
export { CssBaseline, CssScopedBaseline };