diff --git a/docusaurus.config.js b/docusaurus.config.js index cecb0b97d..2a4387f48 100644 --- a/docusaurus.config.js +++ b/docusaurus.config.js @@ -66,11 +66,7 @@ module.exports = { blogSidebarCount: 0, }, theme: { - customCss: [ - require.resolve('./src/css/font.css'), - require.resolve('./src/css/types.css'), - require.resolve('./src/css/custom.css'), - ], + customCss: [require.resolve('./src/css/custom.css')], }, }, ], diff --git a/package.json b/package.json index 8fbff6b7f..e08ba6c54 100644 --- a/package.json +++ b/package.json @@ -63,6 +63,7 @@ "devDependencies": { "@docusaurus/module-type-aliases": "2.4.3", "@tsconfig/docusaurus": "^1.0.6", + "@types/js-cookie": "^3.0.6", "@typescript-eslint/eslint-plugin": "^4", "@typescript-eslint/parser": "^4", "autoprefixer": "^10.4.20", diff --git a/src/components/base/Button/index.tsx b/src/components/base/Button/index.tsx index dd65605cd..213c618bf 100644 --- a/src/components/base/Button/index.tsx +++ b/src/components/base/Button/index.tsx @@ -43,6 +43,7 @@ type ButtonBaseProps = { onClick?: () => void ariaLabel?: string role?: string + type?: 'button' | 'submit' | 'reset' } export const ButtonBase: FC> = ({ @@ -51,9 +52,10 @@ export const ButtonBase: FC> = ({ children, ariaLabel, role, + type = 'button', }) => { return ( - ) diff --git a/src/css/custom.css b/src/css/custom.css index 1a3307c57..07c844b12 100644 --- a/src/css/custom.css +++ b/src/css/custom.css @@ -6,18 +6,19 @@ */ /* You can override the default Infima variables here. */ -@import './infma-overrides.css'; +@import './infima-overrides.css'; @import 'tailwindcss/base'; @import 'tailwindcss/components'; @import 'tailwindcss/utilities'; -:root { - .site-max-width { - max-width: 1440px; - } +@import './font.css'; +@import './types.css'; - .default-grid { - @apply grid grid-cols-4 gap-gap-large sm:grid-cols-8; - } +.site-max-width { + max-width: 1440px; +} + +.default-grid { + @apply grid grid-cols-4 gap-gap-large sm:grid-cols-8; } diff --git a/src/css/infma-overrides.css b/src/css/infima-overrides.css similarity index 69% rename from src/css/infma-overrides.css rename to src/css/infima-overrides.css index 7bf3f79f1..c2f86f093 100644 --- a/src/css/infma-overrides.css +++ b/src/css/infima-overrides.css @@ -1,3 +1,29 @@ +button, +a { + all: initial; +} + +button:hover, +a:hover { + text-decoration: none; + color: inherit; + cursor: pointer; +} + +ul { + all: initial; + display: block; + list-style-type: none; +} + +* { + font-weight: unset; + border-style: solid; + border-width: 0; + border-color: unset; + font-style: unset; +} + /* Box sizing rules */ *, *::before, @@ -76,51 +102,3 @@ select { scroll-behavior: auto !important; } } - -button { - text-rendering: unset; - color: unset; - letter-spacing: unset; - word-spacing: unset; - line-height: unset; - text-transform: unset; - text-indent: unset; - text-shadow: unset; - display: unset; - text-align: unset; - align-items: unset; - cursor: pointer; - box-sizing: unset; - background-color: unset; - margin: unset; - padding-block: unset; - padding-inline: unset; - border-width: unset; - border-style: unset; - border-color: unset; - border-image: unset; -} - -ul { - display: block; - list-style-type: none; - margin-block-start: unset; - margin-block-end: unset; - margin-inline-start: unset; - margin-inline-end: unset; - padding-inline-start: unset; - unicode-bidi: unset; -} - -a:hover { - text-decoration: none; -} - -* { - font-weight: unset; - font-style: unset; - border-style: solid; - border-width: 0; - border-color: unset; - font-style: normal; -} diff --git a/src/theme/Navbar.tsx b/src/theme/Navbar.tsx index 4f7aa8c5a..0a6ec905b 100644 --- a/src/theme/Navbar.tsx +++ b/src/theme/Navbar.tsx @@ -8,7 +8,7 @@ const Navbar: FC = () => { return (