-
-
Notifications
You must be signed in to change notification settings - Fork 7k
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 end-user-facing uses of inline CSS #13438
Merged
Gargron
merged 14 commits into
mastodon:master
from
ClearlyClaire:fixes/style_src-unsafe_inline
Apr 28, 2020
Merged
Fix end-user-facing uses of inline CSS #13438
Gargron
merged 14 commits into
mastodon:master
from
ClearlyClaire:fixes/style_src-unsafe_inline
Apr 28, 2020
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
ykzts
approved these changes
Apr 8, 2020
brawaru
reviewed
Apr 9, 2020
ClearlyClaire
force-pushed
the
fixes/style_src-unsafe_inline
branch
from
April 10, 2020 11:51
e145556
to
551131e
Compare
ClearlyClaire
force-pushed
the
fixes/style_src-unsafe_inline
branch
5 times, most recently
from
April 24, 2020 14:37
30b7971
to
7ceb2ce
Compare
ClearlyClaire
force-pushed
the
fixes/style_src-unsafe_inline
branch
from
April 24, 2020 14:40
7ceb2ce
to
71526dd
Compare
ClearlyClaire
changed the title
Fix some uses of inline CSS
Fix end-user-facing uses of inline CSS
Apr 24, 2020
No end-user-facing inline CSS should be left, which means that with this PR, However, the admin interface still makes use of inline CSS quite a bit. |
brawaru
reviewed
Apr 25, 2020
ClearlyClaire
force-pushed
the
fixes/style_src-unsafe_inline
branch
from
April 25, 2020 18:13
3422d68
to
ca928c4
Compare
Gargron
approved these changes
Apr 28, 2020
Merged
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Mastodon currently relies on inline CSS rules quite a bit, which is often suboptimal code factorization, and overall prevents us from using stricter Content-Security Policies.
This PR removes most of the inline CSS attributes an end-user would run into with the following exceptions:poll vote percentage bars in the JS-less fallback, as there doesn't seem to be any decent way to do thisthe account migration banner thing, as that uses background imagessome styling on the two-factor auth screen as I'm not sure where to put that inIt also doesn't fix most of the issues specific to the admin interface.
EDIT: used the
progress
HTML tag for fallback for poll options, successfully tested with recent Chromium and Firefox versions, as well as with an antiquated Firefox versionEDIT#2: changed the “moved” notice to use image tags
EDIT#3: changed the 2FA styling as well