diff --git a/.gitignore b/.gitignore index 2dceef8..8229388 100644 --- a/.gitignore +++ b/.gitignore @@ -9,3 +9,4 @@ private/cache/* !private/cache/.gitkeep private/config.ini error_log +custom.css \ No newline at end of file diff --git a/custom_template.css b/custom_template.css new file mode 100644 index 0000000..4d9f9fc --- /dev/null +++ b/custom_template.css @@ -0,0 +1,58 @@ +/* === Custom CSS based on: https://github.com/ilyadzh/plain-css */ + +:root { + --green: #27ae60; + --blue: #3498db; + --yellow: #f7af15; + --red: #e74c3c; + --orange: #fe5722; + --purple: #9b27af; + --gray: #747681; + --black: #333; + --alice: #f4f5f6; + --apple: #bfffbf; +} + +/* Global variables. */ +:root, +::backdrop { + /* Set sans-serif & mono fonts */ + --sans-font: -apple-system, BlinkMacSystemFont, "Avenir Next", Avenir, + "Nimbus Sans L", Roboto, "Noto Sans", "Segoe UI", Arial, Helvetica, + "Helvetica Neue", sans-serif; + --mono-font: Consolas, Menlo, Monaco, "Andale Mono", "Ubuntu Mono", monospace; + --standard-border-radius: 5px; + + /* Default (light) theme */ + --bg: #fff; + --accent-bg: var(--alice); + --text: #212121; + --text-light: #585858; + --border: #d1d1d1; + --accent: var(--green); + --code: #000; + --preformatted: #444; + --marked: #ffdd33; + --disabled: #efefef; +} + +/* Dark theme */ +@media (prefers-color-scheme: dark) { + :root, + ::backdrop { + color-scheme: dark; + --bg: #212121; + --accent-bg: #2b2b2b; + --text: #dcdcdc; + --text-light: #ababab; + --accent: #ffb300; + --code: #f06292; + --preformatted: #ccc; + --disabled: #111; + } + /* Add a bit of transparency so light media isn't so glaring in dark mode */ + img, + video { + opacity: 0.8; + } +} \ No newline at end of file diff --git a/libs/timeline.css b/libs/timeline.css index f078f8b..f37ddb8 100644 --- a/libs/timeline.css +++ b/libs/timeline.css @@ -1,20 +1,24 @@ -/* === SimpleCSS overwrites === */ -:root, ::backdrop { - - /* Default (light) theme */ - --sans-font: -apple-system,BlinkMacSystemFont,"Avenir Next",Avenir,"Nimbus Sans L",Roboto,"Noto Sans","Segoe UI",Arial,Helvetica,"Helvetica Neue",sans-serif; - --mono-font: Consolas,Menlo,Monaco,"Andale Mono","Ubuntu Mono",monospace; - --standard-border-radius: 0.5rem; - --bg: #fff; - --accent-bg: #f5f7ff; - --text: #212121; - --text-light: #585858; - --border: #d8dae1; /*#898EA4;*/ - --accent: #0d47a1; - --code: #d81b60; - --preformatted: #444; - --marked: #ffdd33; - --disabled: #efefef; +/* Global variables. */ +:root, +::backdrop { + /* Set sans-serif & mono fonts */ + --sans-font: -apple-system, BlinkMacSystemFont, "Avenir Next", Avenir, + "Nimbus Sans L", Roboto, "Noto Sans", "Segoe UI", Arial, Helvetica, + "Helvetica Neue", sans-serif; + --mono-font: Consolas, Menlo, Monaco, "Andale Mono", "Ubuntu Mono", monospace; + --standard-border-radius: 5px; + + /* Default (light) theme */ + --bg: #fff; + --accent-bg: #f5f7ff; + --text: #212121; + --text-light: #585858; + --border: #d8dae1; /*#898EA4;*/ + --accent: #0d47a1; + --code: #d81b60; + --preformatted: #444; + --marked: #ffdd33; + --disabled: #efefef; } /* Dark theme */ diff --git a/partials/header.php b/partials/header.php index 1f2f479..0067fc8 100644 --- a/partials/header.php +++ b/partials/header.php @@ -12,7 +12,7 @@ $profile = getTwtsFromTwtxtString($config['public_txt_url']); - +