Skip to content

fix: control HCMS entry editor width using Width config #4555

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Feb 25, 2025

Conversation

leopuleo
Copy link
Contributor

Changes

With this PR, we are introducing a new ContentEntryEditorConfig called Width.

The Width component in the ContentEntryEditorConfig accepts the following props:

  • value: A string representing the width value (e.g., "100%", "960px").
  • modelIds: An optional array of strings specifying the model IDs to which this width configuration applies. The width configuration will not be applied if the current model's ID is not in this array.

Bonus

The IsApplicableToCurrentModel is also used for the Action config, rather than manually checking the provided model IDs.

How Has This Been Tested?

Manually

Documentation

This extension must be updated to use the newly created config instead of customising the editor width via CSS.

@leopuleo leopuleo added the cms label Feb 24, 2025
@leopuleo leopuleo added this to the 5.42.2 milestone Feb 24, 2025
@leopuleo leopuleo requested a review from Pavel910 February 24, 2025 14:20
@leopuleo leopuleo self-assigned this Feb 24, 2025
Copy link
Collaborator

@Pavel910 Pavel910 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Very nice! 👍

@leopuleo leopuleo merged commit ba662b1 into dev Feb 25, 2025
17 checks passed
@leopuleo leopuleo deleted the leo/fix/entry-editor-width-config branch March 5, 2025 08:22
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants