Merge pull request 'Script to recompile SCSS and fetch/update JS assets' (#243) from h3ndrik/pyfedi:update_assets into main

Reviewed-on: https://codeberg.org/rimu/pyfedi/pulls/243
This commit is contained in:
rimu 2024-07-03 13:22:08 +00:00
commit 6de9f3dd39
3 changed files with 24 additions and 7 deletions

File diff suppressed because one or more lines are too long

View file

@ -0,0 +1,23 @@
#!/usr/bin/env bash
# Compile SCSS
sass --style expanded styles.scss styles.css
sass --style expanded structure.scss structure.css
# https://github.com/feimosi/baguetteBox.js (MIT license)
curl -o js/lightbox/baguetteBox.css -L https://github.com/feimosi/baguetteBox.js/raw/dev/dist/baguetteBox.min.css
curl -o js/lightbox/baguetteBox.js -L https://github.com/feimosi/baguetteBox.js/raw/dev/dist/baguetteBox.min.js
# https://github.com/fatihege/downarea (MIT license)
curl -o js/markdown/downarea.css -L https://github.com/fatihege/downarea/raw/main/src/downarea.min.css
curl -o js/markdown/downarea.js -L https://github.com/fatihege/downarea/raw/main/src/downarea.min.js
# https://htmx.org/ (Zero-Clause BSD)
curl -o js/htmx.min.js -L https://unpkg.com/htmx.org@2.0.0
# https://momentjs.com/ (MIT license)
curl -o js/moment-with-locales.min.js -L https://momentjs.com/downloads/moment-with-locales.min.js
# ToDo: coolfieldset.js
# ToDo: Feather webfont

View file

@ -40,7 +40,7 @@
<meta name="HandheldFriendly" content="True">
<meta name="MobileOptimized" content="320">
{% block styles -%}
<link href="{{ url_for('static', filename='bootstrap.css') }}" type="text/css" rel="stylesheet" />
{{ bootstrap.load_css() }}
<link href="{{ url_for('static', filename='structure.css', changed=getmtime('structure.css')) }}" type="text/css" rel="stylesheet" />
<link href="{{ url_for('static', filename='styles.css', changed=getmtime('styles.css')) }}" type="text/css" rel="stylesheet" />
<link href="{{ url_for('static', filename='themes/high_contrast/styles.css') }}" type="text/css" rel="alternate stylesheet" title="High contrast" />