Add a thumbnailScale field (xs/sm/md/lg/xl) to gallery layout settings that adjusts column counts for Grid, Masonry (columns mode), and Mosaic layouts. Each scale maps to a column offset applied on top of the layout's base columns, letting photographers control photo density. - Add thumbnailScale to GalleryLayoutSettings type - Apply scale offset in Grid, Masonry, and Mosaic layout components - Add thumbnail scale dropdown to admin theme customizer - Conditionally show dropdown only for applicable layouts - Safelist dynamic grid-cols classes in Tailwind config - Add i18n keys for EN, DE, PT, RU locales Co-authored-by: Paul Nothaft <[email protected]>
This commit is contained in:
co-authored by
Paul Nothaft
parent
3742d71535
commit
ee46088985
@@ -84,6 +84,13 @@ export default {
|
||||
},
|
||||
},
|
||||
},
|
||||
safelist: [
|
||||
// Dynamic grid-cols classes used by thumbnail scale offsets
|
||||
...Array.from({ length: 12 }, (_, i) => `grid-cols-${i + 1}`),
|
||||
...Array.from({ length: 12 }, (_, i) => `sm:grid-cols-${i + 1}`),
|
||||
...Array.from({ length: 12 }, (_, i) => `lg:grid-cols-${i + 1}`),
|
||||
...Array.from({ length: 12 }, (_, i) => `xl:grid-cols-${i + 1}`),
|
||||
],
|
||||
plugins: [],
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user