Update all diff notices for dark mode and to include icons.
Review Request #13900 — Created May 28, 2024 and submitted
We list special notices in diffs for the following conditions:
- Files without any changes made
- Newly-added files that are empty
- Files that were deleted
- Files containing whitespace-only changes
- Files containing suspicious Unicode characters
These notices now all use the rb-c-diff-file-notice
component, showing
an icon and defaulting to a yellow warning background on light mode and
a header color on dark mode. This gives us a color scheme that both
stands out and safely shows diff colors.
The one notice type that isn't covered is for binary files. This is kept
more plain for now, just due to differences between standard file and
defaut states for binary files.
As part of this, we've moved away from embedded rb-c-alert
components.
We aren't using ink-c-alert
here, but rather introducing a new
rb-c-diff-file-notice
, which is specific to the diff viewer. This lets
us ensure a structure that works well in this context, with the visuals
we need, and without having to override styles from either rb-c-alert
or ink-c-alert
to make it fit correctly.
Unit tests pass.
Tested all notice combinations, making sure the visuals looked right in
light and dark modes.
Summary | ID |
---|---|
63a4f5d0bc2e4ee6e5f80445e22c8f871637f60c |
- Change Summary:
-
Half this change was missing and sitting in my Git index. Let's try this again.
- Commits:
-
Summary ID 6c9c3fa00a6e1ec1632f57f0e83c7aeac0da443c 63a4f5d0bc2e4ee6e5f80445e22c8f871637f60c - Diff:
-
Revision 2 (+458 -168)