From daad4b1d6b542b188d60ecedb97d8dbfcf12bcac Mon Sep 17 00:00:00 2001 From: Andrzej WP Date: Tue, 3 Oct 2023 23:27:33 +0200 Subject: [PATCH 1/4] add dark mode, remove repo link --- docs/css/flotiq.css | 34 +++++++--------------------------- mkdocs.yml | 19 ++++++++++++++++--- 2 files changed, 23 insertions(+), 30 deletions(-) diff --git a/docs/css/flotiq.css b/docs/css/flotiq.css index 8c990c15..441b4615 100644 --- a/docs/css/flotiq.css +++ b/docs/css/flotiq.css @@ -2,21 +2,7 @@ max-width: 70rem; } -.md-container { - background: linear-gradient(to right, #E9F3FF, #E9F3FF calc((100% - 70rem)/2 + 12.5rem), #fff calc((100% - 70rem)/2 + 12.5rem), #fff 100%); -} - -@media screen and (max-width: 88rem) { - .md-container { - background: linear-gradient(to right, #E9F3FF, #E9F3FF 12.5rem, #fff 12.5rem, #fff 100%); - } -} -@media screen and (max-width: 76.1875em) { - .md-container { - background: white; - } -} @media screen and (min-width: 76.25em) { @@ -27,7 +13,7 @@ } .md-typeset, .md-nav__link{ - color: #141046; +/* color: #141046;*/ font-family: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", "Roboto", "Oxygen", "Ubuntu", "Fira Sans", "Droid Sans", "Helvetica Neue", sans-serif; font-size: 14px; font-style: normal; @@ -36,19 +22,13 @@ letter-spacing: -0.005em; } -.md-nav__link:focus, .md-nav__link:hover { - color: #0083FC; -} -.md-nav__item .md-nav__link--active { - color: #0083FC; -} .md-typeset h1, .md-typeset h2, .md-typeset h3, .md-typeset h4, .md-typeset h5 { - color: #050038; + font-weight: bold; } .video-wrapper { @@ -76,7 +56,7 @@ header.md-header { } .md-tabs{ - background-color: #141046; + } .md-sidebar__scrollwrap, .md-content { @@ -158,14 +138,14 @@ pre::before { .md-typeset summary:after { - color: #0083FC; + /*color: #0083FC;*/ } .md-typeset .admonition.example > .admonition-title, .md-typeset .admonition.example > summary, .md-typeset details.example > .admonition-title, .md-typeset details.example > summary { - background-color: rgba(154, 109, 255, 0.21); + /*background-color: rgba(154, 109, 255, 0.21);*/ } .md-nav__link[data-md-state='blur'] { @@ -179,11 +159,11 @@ pre::before { */ .md-typeset .footnote { - color: #888484 !important; + /*color: #888484 !important;*/ } .md-typeset .footnote-ref:before { - border-color: #888484 !important; + /* border-color: #888484 !important;*/ } .md-typeset code.hljs { diff --git a/mkdocs.yml b/mkdocs.yml index 467ad3d5..c6ea259d 100644 --- a/mkdocs.yml +++ b/mkdocs.yml @@ -1,7 +1,7 @@ site_name: Flotiq Developer Documentation site_url: https://flotiq.com/docs/ -repo_url: https://github.com/flotiq/flotiq-docs/ -edit_uri: edit/master/docs/ +#repo_url: https://github.com/flotiq/flotiq-docs/ +edit_uri: https://github.com/flotiq/flotiq-docs/edit/master/docs/ copyright: Copyright © 2019 onwards Flotiq dev_addr: 0.0.0.0:4000 theme: @@ -11,7 +11,20 @@ theme: custom_dir: theme language: en palette: - primary: '#0083FC' + + # Palette toggle for light mode + - media: "(prefers-color-scheme: light)" + primary: '#0083FC' + toggle: + icon: material/brightness-7 + name: Switch to dark mode + + # Palette toggle for dark mode + - media: "(prefers-color-scheme: dark)" + scheme: slate + toggle: + icon: material/brightness-4 + name: Switch to light mode features: - navigation.instant - navigation.top From ab0ae5db93343a1d874d99d67d16e335b85e8f11 Mon Sep 17 00:00:00 2001 From: WHLukasz Date: Mon, 9 Oct 2023 18:27:33 +0200 Subject: [PATCH 2/4] wip --- docs/css/flotiq.css | 30 ++++++++++++++++++++++++++++-- mkdocs.yml | 3 +++ 2 files changed, 31 insertions(+), 2 deletions(-) diff --git a/docs/css/flotiq.css b/docs/css/flotiq.css index 441b4615..1a2d4738 100644 --- a/docs/css/flotiq.css +++ b/docs/css/flotiq.css @@ -113,6 +113,30 @@ pre::before { */padding: 10px; } +/* :root { + --md-primary-fg-color: #4051b5; + --md-primary-fg-color--light: #5d6cc0; + --md-primary-fg-color--dark: #303fa1; + --md-primary-bg-color: #fff; + --md-primary-bg-color--light: #ffffffb3; + --md-accent-fg-color: #526cfe; + --md-accent-fg-color--transparent: #526cfe1a; + --md-accent-bg-color: #fff; + --md-accent-bg-color--light: #ffffffb3; + --md-primary-fg-color: #4051b5; + --md-primary-fg-color--light: #5d6cc0; + --md-primary-fg-color--dark: #303fa1; + --md-primary-bg-color: #fff; + --md-primary-bg-color--light: #ffffffb3; + --md-accent-fg-color: #526cfe; + --md-accent-bg-color: #fff; + --md-accent-bg-color--light: #ffffffb3; +} */ + +[data-md-color-scheme="slate"] { + --md-accent-fg-color: #8597fe; + --md-primary-fg-color: #6070c7; +} /* ///////////////// // Code Blocks // @@ -271,7 +295,8 @@ pre::before { } .md-footer { - background: white; + /* background: white; */ + background: #141046; color: #8EA1B8; } @@ -282,7 +307,8 @@ pre::before { } .md-footer-meta { - background: white; + /* background: white; */ + background: #141046; max-width: 48rem; margin: 0 auto; padding: 0 1.2rem; diff --git a/mkdocs.yml b/mkdocs.yml index c6ea259d..92913d49 100644 --- a/mkdocs.yml +++ b/mkdocs.yml @@ -14,6 +14,7 @@ theme: # Palette toggle for light mode - media: "(prefers-color-scheme: light)" + scheme: default primary: '#0083FC' toggle: icon: material/brightness-7 @@ -22,6 +23,8 @@ theme: # Palette toggle for dark mode - media: "(prefers-color-scheme: dark)" scheme: slate + primary: custom + accent: custom toggle: icon: material/brightness-4 name: Switch to light mode From 59eade5f9015836013abe7f6b7eabf0b0c75875b Mon Sep 17 00:00:00 2001 From: WHLukasz Date: Thu, 12 Oct 2023 14:11:09 +0200 Subject: [PATCH 3/4] modify slate color scheme --- docs/css/flotiq.css | 25 +++++++++++++++++++++++++ 1 file changed, 25 insertions(+) diff --git a/docs/css/flotiq.css b/docs/css/flotiq.css index 1a2d4738..80abf000 100644 --- a/docs/css/flotiq.css +++ b/docs/css/flotiq.css @@ -136,6 +136,18 @@ pre::before { [data-md-color-scheme="slate"] { --md-accent-fg-color: #8597fe; --md-primary-fg-color: #6070c7; + .md-typeset h1, + .md-typeset h2, + .md-typeset h3, + .md-typeset h4, + .md-typeset h5 { + color: white; + } + + #disqus_thread .thread__container .thread__wrapper { + background-color: black; + color: white; + } } /* ///////////////// @@ -393,6 +405,19 @@ li.md-nav__item.md-nav__item--active:not(.md-nav__item--nested) { color: #141046; } +[data-md-color-scheme="slate"] { + .was-it-helpful-wrapper .give__title { + color: white; + } + .was-it-helpful-wrapper .give-answers a { + color: white; + } + + /* .disqus_thread { + background-color: black; + } */ +} + .was-it-helpful-wrapper .give-answers a { text-transform: none !important; font-family: Inter, 'sans-serif'; From 02d71f49cda751340d0212ddec98fea8e1251b7a Mon Sep 17 00:00:00 2001 From: WHLukasz Date: Mon, 16 Oct 2023 11:06:49 +0200 Subject: [PATCH 4/4] correct colors --- docs/css/flotiq.css | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/docs/css/flotiq.css b/docs/css/flotiq.css index 80abf000..3d35bb95 100644 --- a/docs/css/flotiq.css +++ b/docs/css/flotiq.css @@ -141,12 +141,12 @@ pre::before { .md-typeset h3, .md-typeset h4, .md-typeset h5 { - color: white; + color: #e9ebfc; } - #disqus_thread .thread__container .thread__wrapper { + #disqus_thread { background-color: black; - color: white; + color: #e9ebfc; } } /*