From af69be0f8c843b652ba56d2b4d3952b34d7a41aa Mon Sep 17 00:00:00 2001 From: Sweetbread Date: Sat, 11 Oct 2025 01:52:39 +0300 Subject: [PATCH] Restruct code --- app.py | 3 +- static/style/main.scss | 13 ++++++ static/style/risdeveau.scss | 33 ++++++++++++++ .../{risdeveau/index.html => risdeveau.html} | 45 +------------------ 4 files changed, 49 insertions(+), 45 deletions(-) create mode 100644 static/style/risdeveau.scss rename templates/personal/{risdeveau/index.html => risdeveau.html} (76%) diff --git a/app.py b/app.py index eb59400..ed5b955 100644 --- a/app.py +++ b/app.py @@ -61,6 +61,7 @@ def inject_translations(): if app.debug: console("sass static/style/main.scss static/style/main.css") + console("sass static/style/risdeveau.scss static/style/risdeveau.css") @app.route("/") def index(): @@ -76,4 +77,4 @@ def us(): @app.route("/risdeveau") def risdeveau(): - return render_template('personal/risdeveau/index.html') + return render_template('personal/risdeveau.html') diff --git a/static/style/main.scss b/static/style/main.scss index a7d81b9..d6dafbf 100644 --- a/static/style/main.scss +++ b/static/style/main.scss @@ -170,6 +170,19 @@ footer { } } +.badges { + .block { + flex: 1; + text-wrap-mode: nowrap; + text-align: -webkit-center; + + &:hover { + flex: 1.5; + transform: none; + } + } +} + .icon { width: 1.5em; vertical-align: middle; diff --git a/static/style/risdeveau.scss b/static/style/risdeveau.scss new file mode 100644 index 0000000..a5c8600 --- /dev/null +++ b/static/style/risdeveau.scss @@ -0,0 +1,33 @@ +h3 { + margin-block-end: 0; +} + +.qr { + img { width: 100% } + p { text-align: center; } + + &.blocks { + flex-wrap: nowrap; + overflow-x: auto; + width: calc(100vw - 1rem); + max-width: 45rem; + scroll: { + behavior: smooth; + snap-type: x mandatory; + } + + &::-webkit-scrollbar { display: none; } + + &:hover .block.qr:not(:hover) { + filter: blur(5px); + transition: all 0.3s ease; + } + } + + &.block { + flex: 0 0 calc(100vw - 2rem); + scroll-snap-align: start; + max-width: 13.666rem; + } +} + diff --git a/templates/personal/risdeveau/index.html b/templates/personal/risdeveau.html similarity index 76% rename from templates/personal/risdeveau/index.html rename to templates/personal/risdeveau.html index 8104276..2fc0101 100644 --- a/templates/personal/risdeveau/index.html +++ b/templates/personal/risdeveau.html @@ -4,6 +4,7 @@ Sweet Bread + - -