Update the way we render icons for accessibility (#31731)
* Switch to Compound icons to replace old icons Signed-off-by: Michael Telatynski <7t3chguy@gmail.com> * Apply same treatment to missed icons Signed-off-by: Michael Telatynski <7t3chguy@gmail.com> * Iterate Signed-off-by: Michael Telatynski <7t3chguy@gmail.com> * Update snapshots Signed-off-by: Michael Telatynski <7t3chguy@gmail.com> * Remove duplicated icon Signed-off-by: Michael Telatynski <7t3chguy@gmail.com> * Update icon Signed-off-by: Michael Telatynski <7t3chguy@gmail.com> * Update snapshots Signed-off-by: Michael Telatynski <7t3chguy@gmail.com> * Switch from css masks to rendering svg in ImageView Signed-off-by: Michael Telatynski <7t3chguy@gmail.com> * Switch from css masks to rendering svg in ExtensionsCard Signed-off-by: Michael Telatynski <7t3chguy@gmail.com> * Switch from css masks to rendering svg in LegacyRoomListHeader Signed-off-by: Michael Telatynski <7t3chguy@gmail.com> * Switch from css masks to rendering svg in ImageSizePanel Signed-off-by: Michael Telatynski <7t3chguy@gmail.com> * Switch from css masks to rendering svg in LegacyRoomList Signed-off-by: Michael Telatynski <7t3chguy@gmail.com> * Remove icon from CreateSecretStorageDialog title Signed-off-by: Michael Telatynski <7t3chguy@gmail.com> * Switch from css masks to rendering svg in LiveContentSummary Signed-off-by: Michael Telatynski <7t3chguy@gmail.com> * Switch from css masks to rendering svg in RoomCallBanner Signed-off-by: Michael Telatynski <7t3chguy@gmail.com> * Switch from css masks to rendering svg in NonUrgentEchoFailureToast Signed-off-by: Michael Telatynski <7t3chguy@gmail.com> * Switch from css masks to rendering svg in LegacyCallViewHeader Signed-off-by: Michael Telatynski <7t3chguy@gmail.com> * Switch from css masks to rendering svg in CallEvent Signed-off-by: Michael Telatynski <7t3chguy@gmail.com> * Delint Signed-off-by: Michael Telatynski <7t3chguy@gmail.com> * Iterate Signed-off-by: Michael Telatynski <7t3chguy@gmail.com> * Update screenshots Signed-off-by: Michael Telatynski <7t3chguy@gmail.com> * Replace dark-light-mode.svg with Compound Signed-off-by: Michael Telatynski <7t3chguy@gmail.com> * Draw stop icon using svg rather than square mask Signed-off-by: Michael Telatynski <7t3chguy@gmail.com> * Replace masks in RoomSublist with SVG icons Signed-off-by: Michael Telatynski <7t3chguy@gmail.com> * Replace masks with SVG icons in LegacyCall views Signed-off-by: Michael Telatynski <7t3chguy@gmail.com> * Replace masks with SVG icons in EventTile Signed-off-by: Michael Telatynski <7t3chguy@gmail.com> * Replace masks with SVG icons in ForwardDialog Signed-off-by: Michael Telatynski <7t3chguy@gmail.com> * Remove redundant css style The `::before` has no content so is never rendered Signed-off-by: Michael Telatynski <7t3chguy@gmail.com> * delint Signed-off-by: Michael Telatynski <7t3chguy@gmail.com> * Update tests Signed-off-by: Michael Telatynski <7t3chguy@gmail.com> * Update playwright tests & screenshots Signed-off-by: Michael Telatynski <7t3chguy@gmail.com> * Iterate Signed-off-by: Michael Telatynski <7t3chguy@gmail.com> * Update snapshot Signed-off-by: Michael Telatynski <7t3chguy@gmail.com> * Remove snapshot as it causes issues Signed-off-by: Michael Telatynski <7t3chguy@gmail.com> * Delint Signed-off-by: Michael Telatynski <7t3chguy@gmail.com> * More tests Signed-off-by: Michael Telatynski <7t3chguy@gmail.com> --------- Signed-off-by: Michael Telatynski <7t3chguy@gmail.com>
This commit is contained in:
@@ -44,15 +44,10 @@ Please see LICENSE files in the repository root for full details.
|
||||
|
||||
box-shadow: 0px 4px 4px 0px #00000026; /* Same on both themes */
|
||||
|
||||
&::before {
|
||||
content: "";
|
||||
svg {
|
||||
display: inline-block;
|
||||
|
||||
mask-repeat: no-repeat;
|
||||
mask-size: contain;
|
||||
mask-position: center;
|
||||
|
||||
background-color: $call-view-button-on-foreground;
|
||||
color: $call-view-button-on-foreground;
|
||||
|
||||
height: 24px;
|
||||
width: 24px;
|
||||
@@ -66,103 +61,60 @@ Please see LICENSE files in the repository root for full details.
|
||||
right: 0;
|
||||
bottom: 0;
|
||||
|
||||
&::before {
|
||||
svg {
|
||||
width: 16px;
|
||||
height: 16px;
|
||||
mask-image: url("@vector-im/compound-design-tokens/icons/chevron-up.svg");
|
||||
}
|
||||
}
|
||||
|
||||
&.mx_LegacyCallViewButtons_dropdownButton_collapsed::before {
|
||||
transform: rotate(180deg);
|
||||
}
|
||||
&.mx_LegacyCallViewButtons_button_mic svg {
|
||||
height: 20px;
|
||||
width: 20px;
|
||||
}
|
||||
|
||||
/* State buttons */
|
||||
&.mx_LegacyCallViewButtons_button_on {
|
||||
background-color: $call-view-button-on-background;
|
||||
|
||||
&::before {
|
||||
background-color: $call-view-button-on-foreground;
|
||||
}
|
||||
|
||||
&.mx_LegacyCallViewButtons_button_mic::before {
|
||||
height: 20px;
|
||||
mask-image: url("@vector-im/compound-design-tokens/icons/mic-on-solid.svg");
|
||||
width: 20px;
|
||||
}
|
||||
|
||||
&.mx_LegacyCallViewButtons_button_vid::before {
|
||||
mask-image: url("@vector-im/compound-design-tokens/icons/video-call-solid.svg");
|
||||
svg {
|
||||
color: $call-view-button-on-foreground;
|
||||
}
|
||||
|
||||
&.mx_LegacyCallViewButtons_button_screensharing {
|
||||
background-color: $accent;
|
||||
|
||||
&::before {
|
||||
mask-image: url("@vector-im/compound-design-tokens/icons/share-screen-solid.svg");
|
||||
background-color: white; /* Same on both themes */
|
||||
svg {
|
||||
color: white; /* Same on both themes */
|
||||
}
|
||||
}
|
||||
|
||||
&.mx_LegacyCallViewButtons_button_sidebar::before {
|
||||
mask-image: url("@vector-im/compound-design-tokens/icons/list-view.svg");
|
||||
}
|
||||
}
|
||||
|
||||
&.mx_LegacyCallViewButtons_button_off {
|
||||
background-color: $call-view-button-off-background;
|
||||
|
||||
&::before {
|
||||
background-color: $call-view-button-off-foreground;
|
||||
}
|
||||
|
||||
&.mx_LegacyCallViewButtons_button_mic::before {
|
||||
height: 20px;
|
||||
mask-image: url("@vector-im/compound-design-tokens/icons/mic-off-solid.svg");
|
||||
width: 20px;
|
||||
}
|
||||
|
||||
&.mx_LegacyCallViewButtons_button_vid::before {
|
||||
mask-image: url("@vector-im/compound-design-tokens/icons/video-call-off-solid.svg");
|
||||
}
|
||||
|
||||
&.mx_LegacyCallViewButtons_button_screensharing {
|
||||
background-color: $call-view-button-on-background;
|
||||
|
||||
&::before {
|
||||
mask-image: url("@vector-im/compound-design-tokens/icons/share-screen-solid.svg");
|
||||
background-color: $call-view-button-on-foreground;
|
||||
}
|
||||
svg {
|
||||
color: $call-view-button-off-foreground;
|
||||
}
|
||||
|
||||
&.mx_LegacyCallViewButtons_button_screensharing,
|
||||
&.mx_LegacyCallViewButtons_button_sidebar {
|
||||
background-color: $call-view-button-on-background;
|
||||
|
||||
&::before {
|
||||
mask-image: url("@vector-im/compound-design-tokens/icons/spotlight-view.svg");
|
||||
background-color: $call-view-button-on-foreground;
|
||||
svg {
|
||||
color: $call-view-button-on-foreground;
|
||||
}
|
||||
}
|
||||
}
|
||||
/* State buttons */
|
||||
|
||||
/* Stateless buttons */
|
||||
&.mx_LegacyCallViewButtons_dialpad::before {
|
||||
mask-image: url("@vector-im/compound-design-tokens/icons/dial-pad.svg");
|
||||
}
|
||||
|
||||
&.mx_LegacyCallViewButtons_button_hangup {
|
||||
background-color: $alert;
|
||||
|
||||
&::before {
|
||||
mask-image: url("@vector-im/compound-design-tokens/icons/end-call.svg");
|
||||
background-color: white; /* Same on both themes */
|
||||
svg {
|
||||
color: white; /* Same on both themes */
|
||||
}
|
||||
}
|
||||
|
||||
&.mx_LegacyCallViewButtons_button_more::before {
|
||||
mask-image: url("@vector-im/compound-design-tokens/icons/overflow-horizontal.svg");
|
||||
}
|
||||
/* Stateless buttons */
|
||||
|
||||
/* Invisible state */
|
||||
|
||||
Reference in New Issue
Block a user