feat(exercises): enhance inline media functionality and update styles
Deploy Development / deploy (push) Successful in 33s
Test Suite / pytest-backend (push) Successful in 24s
Test Suite / lint-backend (push) Successful in 0s
Test Suite / build-frontend (push) Successful in 7s
Test Suite / playwright-tests (push) Successful in 27s
Deploy Development / deploy (push) Successful in 33s
Test Suite / pytest-backend (push) Successful in 24s
Test Suite / lint-backend (push) Successful in 0s
Test Suite / build-frontend (push) Successful in 7s
Test Suite / playwright-tests (push) Successful in 27s
- Updated inline media markup to include a new data attribute for media size. - Enhanced the Rich Text Editor to support media size selection when inserting inline media. - Improved CSS styles for inline media display, accommodating different sizes (small, medium, full). - Bumped version to 0.8.62 and updated changelog to reflect these changes.
This commit is contained in:
1 parent
979e328cef
commit
311a106d93
14 files changed
+703
-113
No files matched your search
@@ -0,0 +1,14 @@
|
||||
/** Inline-Medium im Fließtext §11 — Darstellung (CSS + data-shinkan-exercise-media-size). */
|
||||
export const INLINE_MEDIA_SIZES = [
|
||||
{ value: 'small', label: 'Klein (~33 %)' },
|
||||
{ value: 'medium', label: 'Mittel (~66 %)', default: true },
|
||||
{ value: 'full', label: 'Volle Breite' },
|
||||
]
|
||||
|
||||
export const DEFAULT_INLINE_MEDIA_SIZE = 'medium'
|
||||
|
||||
export function sanitizeInlineMediaSize(v) {
|
||||
const s = String(v || '').toLowerCase().trim()
|
||||
if (s === 'small' || s === 'medium' || s === 'full') return s
|
||||
return DEFAULT_INLINE_MEDIA_SIZE
|
||||
}
|
||||
Reference in new issue
Block a user