discourse/app/assets/javascripts/admin/addon
Martin Brennan 456fbb1dbf
FEATURE: Allow themes to define screenshots (#29079)
This commit allows themes to define up to 2 screenshots
in about.json. These should be paths within the theme's
git repository, images with a 1MB max file size and max width 3840x2160.

These screenshots will be downloaded and stored against a theme
field, and we will use these in the redesigned theme grid UI.

These screenshots will be updated when the theme is updated
in the same way the additional theme files are.

For now this is gated behind a hidden `theme_download_screenshots`
site setting, to allow us to test this on a small number of sites without
making other sites make unnecessary uploads.

**Future considerations:**

* We may want to have a specialized naming system for screenshots. E.g. having light.png/dark.png/some_palette.png
* We may want to show more than one screenshot for the theme, maybe in a carousel or reacting to dark mode or color palette changes
* We may want to allow clicking on the theme screenshot to show a lightbox
* We may want to make an optimized thumbnail image for the theme grid

---------

Co-authored-by: Ted Johansson <ted@discourse.org>
2024-10-28 10:10:20 +10:00
..
adapters FEATURE: Add Filter for Webhook Events by Status (#27332) 2024-06-07 10:26:00 -05:00
components FEATURE: Allow themes to define screenshots (#29079) 2024-10-28 10:10:20 +10:00
controllers FIX: do not overrider trigger when equals 0 (#29269) 2024-10-18 08:34:34 +09:00
helpers DEV: remap all core icons for fontawesome 6 upgrade (#28715) 2024-09-13 16:50:52 +01:00
lib DEV: Convert admin charts to glimmer/gjs (#28271) 2024-08-23 14:59:56 +02:00
mixins DEV: remap all core icons for fontawesome 6 upgrade (#28715) 2024-09-13 16:50:52 +01:00
models UX: Multiple fixes to theme card rendering (#29225) 2024-10-16 11:13:36 -05:00
routes FEATURE: Initial themes config area with grid (#28828) 2024-10-15 10:54:38 -05:00
services DEV: remap all core icons for fontawesome 6 upgrade (#28715) 2024-09-13 16:50:52 +01:00
templates DEV: Add outlet wrapper for user badges form (#29333) 2024-10-24 11:10:10 -03:00