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

Bug: [DebugBar] Rotation applied outside of toolbar #7875

Closed
sanchawebo opened this issue Aug 29, 2023 · 3 comments · Fixed by #7882
Closed

Bug: [DebugBar] Rotation applied outside of toolbar #7875

sanchawebo opened this issue Aug 29, 2023 · 3 comments · Fixed by #7882
Labels
4.4 bug Verified issues on the current code behavior or pull requests that will fix them good first issue Good for newcomers

Comments

@sanchawebo
Copy link
Contributor

PHP Version

8.1

CodeIgniter4 Version

4.4

CodeIgniter4 Installation Method

Composer (using codeigniter4/appstarter)

Which operating systems have you tested for this bug?

macOS

Which server did you use?

apache

Database

MySQL 5.7.39

What happened?

Since the new update (4.4) a rotation-css-rule is applied to my icons.

Steps to Reproduce

Place an element with the rotate-class anywhere on a page where the toolbar is active.

Expected Output

No rotation.

Anything else?

In vendor/codeigniter4/framework/system/Debug/Toolbar/Views/toolbar.css I found this rule:

/* ENDLESS ROTATE */
.rotate {
  animation: rotate 9s linear infinite;
}

This rule gets applied to my own elements which have the rotate-class, as it is not scoped.

@sanchawebo sanchawebo added the bug Verified issues on the current code behavior or pull requests that will fix them label Aug 29, 2023
@sanchawebo
Copy link
Contributor Author

sanchawebo commented Aug 29, 2023

Workaround:

  • Change rotate to .debug-bar-rotate (or anything else) in vendor/codeigniter4/framework/system/Debug/Toolbar/Views/toolbar.css
  • Change/Rename all occurences of rotate to debug-bar-rotate in vendor/codeigniter4/framework/system/Debug/Toolbar/Views/toolbar.js
  • (Optional) Change the name of the animation in toolbar.css to something different.

@kenjis kenjis added the 4.4 label Aug 29, 2023
@kenjis
Copy link
Member

kenjis commented Aug 30, 2023

Thank you for reporting.

The class="rotate" is too big. It should be, e.g., class="toolbar rotate".

<img src="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABgAAAAYCAYAAADgdz34AAAACXBIWXMAAAsTAAALEwEAmpwYAAABNklEQVR4nN2US04CQRCGv/DaiBxEvYWuBRPDKSCIXsCdcg0ULqTI8xIGN7JwTCU/ScV5tTO64Us6maSq/7+nuqvgkLgHopTl+QAWwBToAg3+wMTzM7YBrihp4jkCToEB8OJyRkCFAB5yDDxVoAd8OpNMOkrcAeMAgz3nzsQ0EqkDayXZqXy5Qugrdy2tGNdKeNWv40xCqGpvJK0YEwXt8ooylMZzUnCh4EkJgzNpmFaMrYLNEgbH0thmGVhSUVrSeE8KLv+7RBMFb0oY3EnDeihGN+WZhmJ7ZlnPtKHB5RvtNwy0d5XWaGgqRmp7a/9QLjRevoDLvOSRM+nnlKumk++0xwZlLhVnEulOhnohTS37vnU1t5M/ho7rPR03/LKW1bxNQep6ETZb5mpGW2/Ak2KpF3oYfAPX9Xpc671kqwAAAABJRU5ErkJggg==" class="rotate">

@kenjis
Copy link
Member

kenjis commented Aug 30, 2023

@kenjis kenjis added the good first issue Good for newcomers label Aug 30, 2023
@kenjis kenjis changed the title Bug: Rotation applied outside of toolbar Bug: [DebugBar] Rotation applied outside of toolbar Aug 30, 2023
@sanchawebo sanchawebo reopened this Aug 30, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
4.4 bug Verified issues on the current code behavior or pull requests that will fix them good first issue Good for newcomers
Projects
None yet
2 participants