-
Notifications
You must be signed in to change notification settings - Fork 3
loading css back #620
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
loading css back #620
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change | ||||||||||||||||||||||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| @@ -0,0 +1,40 @@ | ||||||||||||||||||||||||||||||||||||||||||
| .loading-container{ | ||||||||||||||||||||||||||||||||||||||||||
| position: fixed; | ||||||||||||||||||||||||||||||||||||||||||
| top: 50%; | ||||||||||||||||||||||||||||||||||||||||||
| right: 50%; | ||||||||||||||||||||||||||||||||||||||||||
| transform: translate(50%, 50%); | ||||||||||||||||||||||||||||||||||||||||||
| z-index: 2; | ||||||||||||||||||||||||||||||||||||||||||
| } | ||||||||||||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||||||||||||
| .loading{ | ||||||||||||||||||||||||||||||||||||||||||
| background-color: var(--background-plot); | ||||||||||||||||||||||||||||||||||||||||||
| color: var(--text-plot); | ||||||||||||||||||||||||||||||||||||||||||
| padding: 3px 6px; | ||||||||||||||||||||||||||||||||||||||||||
| border-radius: 4px; | ||||||||||||||||||||||||||||||||||||||||||
| font-size: 24px; | ||||||||||||||||||||||||||||||||||||||||||
| font-weight: 700; | ||||||||||||||||||||||||||||||||||||||||||
| display: flex; | ||||||||||||||||||||||||||||||||||||||||||
| align-items: center; | ||||||||||||||||||||||||||||||||||||||||||
| gap: 6px; | ||||||||||||||||||||||||||||||||||||||||||
| } | ||||||||||||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||||||||||||
| .loading::after { | ||||||||||||||||||||||||||||||||||||||||||
| content: ''; | ||||||||||||||||||||||||||||||||||||||||||
| width: 24px; | ||||||||||||||||||||||||||||||||||||||||||
| height: 24px; | ||||||||||||||||||||||||||||||||||||||||||
| border: 2px solid var(--text-plot); | ||||||||||||||||||||||||||||||||||||||||||
| border-top-color: transparent; | ||||||||||||||||||||||||||||||||||||||||||
| border-radius: 50%; | ||||||||||||||||||||||||||||||||||||||||||
| animation: spin 1s linear infinite; | ||||||||||||||||||||||||||||||||||||||||||
| } | ||||||||||||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||||||||||||
| .progress-bar{ | ||||||||||||||||||||||||||||||||||||||||||
| left:0; | ||||||||||||||||||||||||||||||||||||||||||
| width: 100%; | ||||||||||||||||||||||||||||||||||||||||||
| height: 6px; | ||||||||||||||||||||||||||||||||||||||||||
| margin-top: 2px; | ||||||||||||||||||||||||||||||||||||||||||
| background-color: rgb(213, 219, 154); | ||||||||||||||||||||||||||||||||||||||||||
| border-radius: 3px; | ||||||||||||||||||||||||||||||||||||||||||
| box-shadow: 0px 0px 2px rgb(0, 0, 0); | ||||||||||||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||||||||||||
| } | ||||||||||||||||||||||||||||||||||||||||||
|
Comment on lines
+31
to
+40
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. The
Suggested change
|
||||||||||||||||||||||||||||||||||||||||||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The current CSS for
.loading-containerwill not correctly center the element in the viewport. Usingtop: 50%andright: 50%withtransform: translate(50%, 50%)offsets the element down and to the right of the center. To properly center it, you can useleft: 50%andtransform: translate(-50%, -50%), which is a more common and reliable method for centering.