@navinc/base-react-components
Version:
Nav's Pattern Library
388 lines (337 loc) • 6.2 kB
JavaScript
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.GlobalStyles = void 0;
const styled_components_1 = require("styled-components");
exports.GlobalStyles = (0, styled_components_1.createGlobalStyle) `
@font-face {
font-family: Inter;
font-style: normal;
font-weight: 400;
src:
url('https://nav-design-assets.s3.us-west-2.amazonaws.com/fonts/Inter-Regular.ttf') format('truetype'),
}
@font-face {
font-family: Inter;
font-style: normal;
font-weight: 500;
src:
url('https://nav-design-assets.s3.us-west-2.amazonaws.com/fonts/Inter-Medium.ttf') format('truetype'),
}
@font-face {
font-family: Inter;
font-style: normal;
font-weight: 600;
src:
url('https://nav-design-assets.s3.us-west-2.amazonaws.com/fonts/Inter-SemiBold.ttf') format('truetype'),
}
@font-face {
font-family: Inter;
font-style: normal;
font-weight: 700;
src:
url('https://nav-design-assets.s3.us-west-2.amazonaws.com/fonts/Inter-Bold.ttf') format('truetype'),
}
@font-face {
font-family: Manrope;
font-style: normal;
font-weight: normal;
src: url('https://nav-design-assets.s3.us-west-2.amazonaws.com/fonts/Manrope-Regular.woff2') format('woff2');
}
@font-face {
font-family: Manrope;
font-style: normal;
font-weight: 600;
src: url('https://nav-design-assets.s3.us-west-2.amazonaws.com/fonts/Manrope-Semibold.woff2') format('woff2');
}
@font-face {
font-family: Manrope;
font-style: normal;
font-weight: bold;
src: url('https://nav-design-assets.s3.us-west-2.amazonaws.com/fonts/Manrope-Bold.woff2') format('woff2');
}
*,
*::before,
*::after {
box-sizing: border-box;
}
html {
height: 100%;
width: 100%;
width: 100vw; /* stylelint-disable-line declaration-block-no-duplicate-properties */
overflow-x: hidden;
box-sizing: border-box;
text-size-adjust: 100%;
-ms-text-size-adjust: 100%;
-webkit-text-size-adjust: 100%;
-webkit-tap-highlight-color: rgb(0 0 0 / 0%);
}
body,
p {
font-family: ${({ theme }) => theme.fontPrimary};
font-size: 16px;
}
a {
text-decoration: none;
color: ${({ theme }) => theme.navPrimary};
background: transparent;
cursor: pointer;
}
html,
body,
div,
span,
iframe,
img,
figure,
figcaption,
h1,
h2,
h3,
h4,
h5,
h6,
p,
a,
blockquote,
code,
strong,
dl,
dt,
dd,
ol,
ul,
li,
fieldset,
form,
label,
input,
table,
tbody,
tfoot,
thead,
tr,
th,
td,
article,
aside,
canvas,
details,
summary,
embed,
footer,
header,
menu,
nav,
output,
ruby,
section,
mark,
audio,
video {
margin: 0;
padding: 0;
border: none;
outline: none;
}
article,
aside,
details,
figcaption,
figure,
footer,
header,
menu,
nav,
section {
display: block;
}
ol,
ul {
list-style: none;
}
body {
height: 100%;
margin: 0;
background: ${({ theme }) => theme.navNeutral};
background-color: ${({ theme }) => theme.navNeutral};
cursor: default;
}
html,
html a {
text-shadow: 1px 1px 1px rgb(0 0 0 / 0.4%);
-webkit-font-smoothing: subpixel-antialiased;
}
body,
input {
color: ${({ theme }) => theme.navNeutralDark};
font-family: ${({ theme }) => theme.fontPrimary};
font-weight: 400;
}
#root {
height: 100%;
}
@keyframes hide {
0% {
opacity: 0;
}
100% {
opacity: 0;
}
}
@keyframes fade-in {
0% {
opacity: 0;
}
100% {
opacity: 1;
}
}
@keyframes slide-in {
0% {
transform: translateX(100%);
}
100% {
transform: translateX(0);
}
}
aside,
footer,
header,
main,
nav,
section {
display: block;
}
[hidden] {
display: none;
}
a:hover,
a:active {
outline: 0;
}
a:focus {
outline: thin dotted;
outline: 5px auto -webkit-focus-ring-color;
outline-offset: -2px;
}
hr {
flex-basis: 1000000px;
border-top: 1px solid #dfe3e7;
}
svg:not(:root) {
overflow: hidden;
}
button,
input,
optgroup,
select,
textarea {
margin: 0;
color: inherit;
font: inherit;
}
button {
overflow: visible;
}
button,
select {
text-transform: none;
}
button,
html input[type='button'],
input[type='reset'],
input[type='submit'] {
cursor: pointer;
appearance: button;
}
button[disabled],
html input[disabled] {
cursor: default;
}
button::-moz-focus-inner,
input::-moz-focus-inner {
padding: 0;
border: 0;
}
textarea {
overflow: auto;
}
/* stylelint-disable-next-line plugin/no-unsupported-browser-features -- properties were in place prior to stylelint. No support on iOS Safari */
::selection {
background-color: ${({ theme }) => theme.navNeutral200};
color: ${({ theme }) => theme.navNeutral500};
}
input[type='number']::-webkit-inner-spin-button,
input[type='number']::-webkit-outer-spin-button {
margin: 0;
appearance: none;
}
input::-ms-clear {
display: none;
}
h1,
h2,
h3,
h4,
h5,
h6,
p,
li,
span {
margin: 0;
font-family: ${({ theme }) => theme.fontPrimary};
font-weight: 400;
}
h1.h0 {
font-size: 40px;
font-weight: 200;
line-height: 1.125;
text-transform: uppercase;
}
h1 {
font-size: 32px;
font-weight: 600;
line-height: 1.188;
}
h2 {
font-size: 24px;
line-height: 1.167;
}
h3 {
font-size: 20px;
line-height: 1.3;
}
@media (max-width: 599px) {
h1.h0 {
font-size: 24px;
line-height: 1.167;
}
h1 {
font-size: 20px;
line-height: 1.3;
}
h2 {
font-size: 18px;
line-height: 1.563;
}
h3 {
font-size: 16px;
line-height: 1.786;
}
}
p,
li {
font-size: 14px;
font-weight: 400;
line-height: 1.786;
}
small {
font-size: 12px;
line-height: 1.786;
}
label {
font-size: 12px;
line-height: 1.786;
}
`;
//# sourceMappingURL=global-styles.js.map