diff --git a/source/_ext/template.py b/source/_ext/template.py index d345db0..d497423 100644 --- a/source/_ext/template.py +++ b/source/_ext/template.py @@ -4,8 +4,6 @@ def template(app, docname: str, source: list[str]): return content = content.replace("!template", "", 1) - print("*"*80) - print(app.config.templates_context) rendered = app.builder.templates.render_string(content, app.config.templates_context) source[0] = rendered diff --git a/source/_static/apyb-dark.svg b/source/_static/apyb-dark.svg new file mode 100644 index 0000000..c722638 --- /dev/null +++ b/source/_static/apyb-dark.svg @@ -0,0 +1,287 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/source/_static/apyb-light.svg b/source/_static/apyb-light.svg new file mode 100644 index 0000000..e7fe423 --- /dev/null +++ b/source/_static/apyb-light.svg @@ -0,0 +1,253 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/source/_static/bg-dark.jpg b/source/_static/bg-dark.jpg new file mode 100644 index 0000000..53bf84a Binary files /dev/null and b/source/_static/bg-dark.jpg differ diff --git a/source/_static/bg-light.jpg b/source/_static/bg-light.jpg new file mode 100644 index 0000000..eb7baeb Binary files /dev/null and b/source/_static/bg-light.jpg differ diff --git a/source/_static/css/custom.css b/source/_static/css/custom.css new file mode 100644 index 0000000..520eb20 --- /dev/null +++ b/source/_static/css/custom.css @@ -0,0 +1,17 @@ +body { + --image-background-primary: url('../bg-light.jpg'); +} + +body[data-theme=dark] { + --image-background-primary: url('../bg-dark.jpg'); +} + +.content { + background: var(--color-background-primary); +} +.main { + background: var(--image-background-primary) repeat fixed; +} +.sidebar-logo { + padding: 1.5rem 0; +} diff --git a/source/conf.py b/source/conf.py index b3c2275..7955499 100644 --- a/source/conf.py +++ b/source/conf.py @@ -72,10 +72,50 @@ # The theme to use for HTML and HTML Help pages. See the documentation for # a list of builtin themes. # -html_theme = 'furo' +html_theme = "furo" +html_theme_options = { + "light_logo": "apyb-light.svg", + "dark_logo": "apyb-dark.svg", + "sidebar_hide_name": True, + "light_css_variables": { + # Background + "color-background-secondary": "#FAF9FA", + # Sidebar + "color-link-underline": "#FAF9FA", + "color-link-underline--hover": "#0056CD", + "color-sidebar-link-text--top-level": "#0056CD", + # Text + "color-content-foreground": "#011224", + "color-link": "#0056cd", + }, + "dark_css_variables": { + # Background + "color-background-border": "#0056CD", + "color-background-hover": "#01122430", + "color-background-primary": "#011224", + "color-background-secondary": "#0056CD", + # Sidebar + "color-sidebar-caption-text": "#ffffff", + "color-sidebar-link-text": "#ffffffaa", + "color-sidebar-link-text--top-level": "#ffffff", + "color-sidebar-search-background": "rgba(255, 255, 255, 0.1)", + "color-sidebar-search-background--focus": "rgba(255, 255, 255, 0.2)", + "color-sidebar-search-foreground": "#ffffff", + "color-sidebar-search-icon": "rgba(255, 255, 255, 0.5)", + # Text + "color-content-foreground": "#FAF9FAee", + "color-link": "#fff", + "color-link--hover": "#FFB93B", + "color-link-underline": "#FFB93B", + "color-link-underline--hover": "#FFB93B", + }, +} # Add any paths that contain custom static files (such as style sheets) here, # relative to this directory. They are copied after the builtin static files, # so a file named "default.css" will overwrite the builtin "default.css". -html_static_path = ['_static'] +html_static_path = ["_static"] +html_css_files = [ + "css/custom.css", +] html_title = "Associação Python Brasil"