feat(main): Add custom CSS classes to HTML blocks
This feature allows administrators to define custom CSS classes for individual HTML blocks. It enhances styling flexibility and integrates with common grid systems (e.g., Bootstrap `col-md-6`) by applying user-defined classes to the block's wrapper element. Includes: - A new `custom_class` field in the block model, form, and data handlers. - Database schema updates with an upgrade path to handle potential renames from `column_class`. - Frontend rendering to apply the classes. - Registration of `actionFrontControllerSetMedia` hook to load front-end CSS. - Basic responsive image styling for blocks.
This commit is contained in:
@@ -64,6 +64,7 @@ trait Install
|
||||
`title` VARCHAR(256) NOT NULL DEFAULT \'\',
|
||||
`type` VARCHAR(32) NOT NULL DEFAULT \'html\',
|
||||
`content` LONGTEXT,
|
||||
`custom_class` VARCHAR(128) NOT NULL DEFAULT \'\',
|
||||
`active` TINYINT(1) NOT NULL DEFAULT 1,
|
||||
`show_title` TINYINT(1) NOT NULL DEFAULT 0,
|
||||
`ordering` INT(11) NOT NULL DEFAULT 0,
|
||||
|
||||
Reference in New Issue
Block a user