diff --git a/assets/_custom.scss b/assets/_custom.scss index e111297..5739bc4 100644 --- a/assets/_custom.scss +++ b/assets/_custom.scss @@ -160,4 +160,38 @@ html { ::-webkit-scrollbar-thumb { background: var(--gray-500); border-radius: $padding-8; -} \ No newline at end of file +} + + + +// Links +// main colors are set in _variables.scss +a:focus, a:focus-visible { + opacity: .75; + text-decoration: none; + outline-style: auto; + outline-color: var(--color-link-mono); +} + +.markdown, .book-toc { + a:hover { + opacity: .75; + } +} + +.markdown a { + &:hover { + text-decoration: underline; + text-decoration-color: var(--color-link-mono); + } + + &:visited { + &:hover { + text-decoration-color: var(--color-visited-link-mono); + } + + &:focus, &:focus-visible { + outline-color: var(--color-visited-link-mono); + } + } +} diff --git a/assets/_variables.scss b/assets/_variables.scss new file mode 100644 index 0000000..48c64e9 --- /dev/null +++ b/assets/_variables.scss @@ -0,0 +1,21 @@ +// had to copy the whole mixin from _default.scss +@mixin theme-light { + --gray-100: #f8f9fa; + --gray-200: #e9ecef; + --gray-500: #adb5bd; + + // https://github.com/trailofbits/audit-reporting-tools/blob/88b75a31a7298e8079fb326c7992ff534868e497/make-report/make_report/colors.py#L86 + --color-link: #ad182b; + --color-link-mono: #c93447; // monochromatic + --color-visited-link: #683700; + --color-visited-link-mono: #84531c; // monochromatic + + --body-background: white; + --body-font-color: black; + + --icon-filter: none; + + --hint-color-info: #6bf; + --hint-color-warning: #fd6; + --hint-color-danger: #f66; +} \ No newline at end of file