Skip to content
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

Allow and preserve image width and height attributes #14201

Closed
Witoso opened this issue May 22, 2023 · 0 comments · Fixed by #14233
Closed

Allow and preserve image width and height attributes #14201

Witoso opened this issue May 22, 2023 · 0 comments · Fixed by #14233
Assignees
Labels
package:image squad:core Issue to be handled by the Core team. type:task This issue reports a chore (non-production change) and other types of "todos".

Comments

@Witoso
Copy link
Member

Witoso commented May 22, 2023

After checking the PoC check in #14147, we decided that we want to go further with this approach.

Scope

  • load the width and height attributes from HTML (done in the PoC).
  • breaking change: model width-> resizedWidth, widthAttribute -> width (it was not a part of the PoC).
  • breaking change: streamlined the srcset attribute in the model. On master it is { data: "...", width: "" } but since now width has been delegated to ImageSizeAttributes, I figured this object form is useless (done in the PoC).
  • resize stays as is but we add height: auto to the styles to preserve the proper aspect ratio. (Is it a BC?)

We need to test it against our current upload adapters if this doesn't break anything.

@Witoso Witoso added type:task This issue reports a chore (non-production change) and other types of "todos". squad:core Issue to be handled by the Core team. package:image labels May 22, 2023
@CKEditorBot CKEditorBot added the status:planned Set automatically when an issue lands in the "Sprint backlog" column. We will be working on it soon. label May 22, 2023
@Witoso Witoso changed the title Support image width and height attributes Allow and preserve image width and height attributes May 22, 2023
@mmotyczynska mmotyczynska self-assigned this May 22, 2023
@CKEditorBot CKEditorBot added status:in-progress Set automatically when an issue lands in the "In progress" column. We are working on it. and removed status:planned Set automatically when an issue lands in the "Sprint backlog" column. We will be working on it soon. labels May 22, 2023
mmotyczynska added a commit that referenced this issue Jun 7, 2023
…mage-width-and-height

Feature (image): It should be possible to load and preserve image width and height attributes. Closes #14201.

MAJOR BREAKING CHANGE (image): The name of the image resize width attribute has been changed to resizedWidth. The width and height attributes are now used to preserve image width and height.

MAJOR BREAKING CHANGE (image): The srcset attribute has been simplified. It is no longer an object { data: "...", width: "..." }, but a value previously stored in the data part.
@arkflpc arkflpc closed this as completed Jul 3, 2023
@CKEditorBot CKEditorBot removed the status:in-progress Set automatically when an issue lands in the "In progress" column. We are working on it. label Jul 3, 2023
@CKEditorBot CKEditorBot added this to the upcoming milestone Jul 3, 2023
@CKEditorBot CKEditorBot modified the milestones: upcoming, iteration 67 Sep 14, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
package:image squad:core Issue to be handled by the Core team. type:task This issue reports a chore (non-production change) and other types of "todos".
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants