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

Fix editor alignment issues #13573

Merged

Conversation

Karn-Blackmore
Copy link

@Karn-Blackmore Karn-Blackmore commented Dec 13, 2022

Prerequisites

  • I have added steps to test this contribution in the description below

Existing issue #13538

Description

Upon clicking a blocklist item the editor alignment does not properly align to the right and can be seen to jump about towards the left.

chrome-capture-2022-11-13 (2)

This is jumping bacause the editor class has transition: transform 400ms ease-in-out and it also runs its inputs within the editor through an auto focus $timeout function immediately. This focuses the input before its in the viewport causing the editor to jump into view and causes an issue with the left positioning.

There are few ways to fix this but in its simpliest form is setting an editor within the umb-editors to position: fixed

chrome-capture-2022-11-13 (3)

Tested by checking various editors in many different sequences and tested on Chrome and Firefox all seems to be working correctly.

chrome-capture-2022-11-13 (4)

There is still a slight issue with the transition on the second drawer editor (as seen in GIF) but I believe thats a different issue.

How to test

  1. Create a blocklist with at least 1 item.
  2. Create a document type with this blocklist
  3. Create a page of that document type
  4. Add content to this blocklist
  5. See that the overlay is aligned properly

@Karn-Blackmore Karn-Blackmore changed the title Fix algiment issues by setting the editor to position fix. Fix editor alginment issues Dec 13, 2022
@Karn-Blackmore Karn-Blackmore changed the title Fix editor alginment issues Fix editor alignment issues Dec 13, 2022
@georgebid georgebid self-requested a review March 14, 2023 09:18
@georgebid georgebid self-assigned this Mar 14, 2023
@georgebid georgebid changed the base branch from v10/dev to contrib March 14, 2023 09:18
@georgebid georgebid merged commit daf5446 into umbraco:contrib Mar 14, 2023
12 checks passed
@georgebid
Copy link
Contributor

Hi @Karn-Blackmore thanks for your PR to fix #13538! This is certainly an issue I have spotted when editing in the CMS so it's nice to see a fix for this 🎉 I have tested and I am happy to merge this in.

@nul800sebastiaan
Copy link
Member

Cherry picked for 10.5 in 2d32f46

@Karn-Blackmore Karn-Blackmore deleted the v10/bugfix/Editor-Positioning branch April 14, 2023 14:43
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants