Context / Intro
As content pages and fragments development evolves, we provide more options to customize the styles of a given fragment.
On one hand, we have been implemented layers of styling control through permissions, to allow for basic, limited or full styles edition capabilities.
But, in addition to this, we must enable a filter for fragment developers to restrict which styles should be editable in the fragment they are developing. In this way, they will ensure that the fragment is edited only in the parameters they consider.
This will allow clients to have a higher control on what content creators can do to customize pages and fragments.
- Add a new configuration in the Fragment configuration file to disable style options (we follow the same pattern as setup options for form fragments)
- With this option, the fragment developer will be able to disable one or more style properties.
- Do not allow to hide sizing or margin styles, since these directly impact on how to build a page layout and we would be restricting capabilities for users.
- If a style property is disabled (e.g. Background-color), that style property will NOT BE AVAILABLE for edition in the styles tab of the page editor.
- Add an option to enable/disable custom CSS addition. This enablement must complement the "advanced" permission. Besides allowing access to the advanced tab for users with the appropiate permission, Custom CSS for a given fragment depends on this configuration.
- TO BE DISCUSSED: do we want to hide the style property or show it disabled with a hover tooltip that says: Property disabled for edition in this fragment"? At least, users must be aware somehow that the fragment has some styles restricted for edition.
- We must provide guidance for developers on how each style in the styling tab matches with specific wording for the JSON file.