Skip to content
This repository has been archived by the owner on Sep 11, 2024. It is now read-only.

Compound color pass #11079

Merged
merged 35 commits into from
Jul 12, 2023
Merged
Show file tree
Hide file tree
Changes from 7 commits
Commits
Show all changes
35 commits
Select commit Hold shift + click to select a range
f4784c3
Integrate compound design tokens
Jun 13, 2023
a0451d0
Pareto color pass on the light theme
Jun 13, 2023
c5edcb8
Merge branch 'develop' into gsouquet/compound-color-pass
Jun 16, 2023
5e260ea
bugfixes in the light color pass
Jun 16, 2023
e234662
Merge branch 'develop' into gsouquet/compound-color-pass
Jun 19, 2023
d7a115a
Compound color pass dark theme
Jun 19, 2023
ee40c00
Compound color pass high contrast
Jun 19, 2023
a32156f
Merge branch 'develop' into gsouquet/compound-color-pass
Jun 27, 2023
4293b01
Fix typo
Jun 28, 2023
0bd9b3b
fix tooltip
Jun 29, 2023
19484d1
Fix PR feedback
Jun 29, 2023
ec12dbb
Merge branch 'develop' into gsouquet/compound-color-pass
Jul 5, 2023
7fb4333
fix composer button mixin
Jul 5, 2023
0ed5b4c
Normalise some of the auth page colors
Jul 5, 2023
2db7e35
Update based on figma feedback
Jul 5, 2023
ed2d479
lintfix
Jul 5, 2023
34d40d9
regenerate theme index
Jul 5, 2023
0eb671c
Fix cypress tests
Jul 5, 2023
18f8ff2
fix more e2e tests
Jul 5, 2023
c3c141f
update colors based on feedback
Jul 5, 2023
3565fe7
fix color pass
Jul 6, 2023
2fb87a1
Fix theme overrides
Jul 6, 2023
4e8db00
Restore -transparent
Jul 6, 2023
273ea8f
fix color mapping
Jul 7, 2023
f3cf7e7
Merge branch 'develop' into gsouquet/compound-color-pass
Jul 12, 2023
1e189b0
Final colour pass update
Jul 12, 2023
243da49
Do not consume compound colors directly
Jul 12, 2023
950465b
rethemedex
Jul 12, 2023
a3646e2
Update pass
Jul 12, 2023
b46a5d1
Final tweaks
Jul 12, 2023
3e329ea
a11y pass
Jul 12, 2023
0127888
scope opacity to checkbox and not label
Jul 12, 2023
de7815a
Add missing customisations var for theming
Jul 12, 2023
333bdf8
lintfix
Jul 12, 2023
2197248
remove unwanted test
Jul 12, 2023
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 6 additions & 4 deletions res/css/_common.pcss
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@ limitations under the License.
*/

@import url("@vector-im/compound-design-tokens/assets/web/css/compound-design-tokens.css");
@import "./_theme.pcss";
@import "./_font-sizes.pcss";
@import "./_font-weights.pcss";
@import "./_animations.pcss";
Expand Down Expand Up @@ -237,7 +238,7 @@ legend {
background-color: transparent;
color: $input-darker-fg-color;
border-radius: 4px;
border: 1px solid rgba($primary-content, 0.1);
border: 1px solid var(--cpd-color-gray-300);
germain-gg marked this conversation as resolved.
Show resolved Hide resolved
/* these things should probably not be defined globally */
margin: 9px;
}
Expand All @@ -250,7 +251,7 @@ legend {
:not(.mx_textinput):not(.mx_Field):not(.mx_no_textinput) > input[type="text"]::placeholder,
:not(.mx_textinput):not(.mx_Field):not(.mx_no_textinput) > input[type="search"]::placeholder,
.mx_textinput input::placeholder {
color: rgba($input-darker-fg-color, 0.75);
color: var(--cpd-color-text-placeholder);
germain-gg marked this conversation as resolved.
Show resolved Hide resolved
}
}

Expand Down Expand Up @@ -799,7 +800,8 @@ legend {
}

@define-mixin composerButtonHighLight {
background: rgba($accent, 0.25);
/* TODO: Refactor as this will break for apps that override the accent color */
background: var(--cpd-color-green-300);
/* make the icon the accent color too */
&::before {
background-color: $accent !important;
Expand Down Expand Up @@ -842,7 +844,7 @@ legend {

&:hover {
&::after {
background: rgba($hover-color, 0.1);
germain-gg marked this conversation as resolved.
Show resolved Hide resolved
background: var(--cpd-color-bg-action-secondary-hovered);
}

&::before {
Expand Down
2 changes: 1 addition & 1 deletion res/css/compound/_Icon.pcss
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ limitations under the License.
}

.mx_Icon_bg-accent-light {
background-color: rgba($accent, 0.1);
background-color: $accent-300;
germain-gg marked this conversation as resolved.
Show resolved Hide resolved
}

.mx_Icon_alert {
Expand Down
7 changes: 0 additions & 7 deletions res/css/structures/_LeftPanel.pcss
Original file line number Diff line number Diff line change
Expand Up @@ -14,13 +14,6 @@ See the License for the specific language governing permissions and
limitations under the License.
*/

.mx_MatrixChat--with-avatar {
.mx_LeftPanel,
.mx_LeftPanel .mx_LeftPanel_roomListContainer {
background-color: transparent;
}
}
t3chguy marked this conversation as resolved.
Show resolved Hide resolved

.mx_LeftPanel_outerWrapper {
display: flex;
flex-direction: column;
Expand Down
4 changes: 2 additions & 2 deletions res/css/structures/_RoomView.pcss
Original file line number Diff line number Diff line change
Expand Up @@ -258,8 +258,8 @@ limitations under the License.
height: var(--RoomHeader-indicator-dot-size);
border-radius: 50%;
transform: scale(1);
background: rgba(var(--RoomHeader-indicator-pulseColor), 1);
box-shadow: 0 0 0 0 rgba(var(--RoomHeader-indicator-pulseColor), 1);
background: var(--RoomHeader-indicator-pulseColor);
box-shadow: 0 0 0 0 var(--RoomHeader-indicator-pulseColor);
animation: mx_Indicator_pulse 2s infinite;
animation-iteration-count: 1;

Expand Down
2 changes: 1 addition & 1 deletion res/css/structures/_SpacePanel.pcss
Original file line number Diff line number Diff line change
Expand Up @@ -369,7 +369,7 @@ limitations under the License.

.mx_UserMenu {
padding: 0 2px 8px;
border-bottom: 1px solid $quinary-content;
border-bottom: 1px solid var(--cpd-color-gray-700);
margin: 12px 14px 4px 18px;
}
}
Expand Down
2 changes: 1 addition & 1 deletion res/css/views/beta/_BetaCard.pcss
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ limitations under the License.

.mx_BetaCard {
padding: $spacing-24;
background-color: $system;
background-color: var(--cpd-color-bg-subtle-secondary);
border-radius: 8px;
box-sizing: border-box;
color: $secondary-content;
Expand Down
2 changes: 1 addition & 1 deletion res/css/views/dialogs/_PollCreateDialog.pcss
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ limitations under the License.
.mx_PollCreateDialog_busy {
position: absolute;
inset: 0;
background-color: rgba($background, 0.6);
background-color: var(--cpd-color-alpha-gray-800);
germain-gg marked this conversation as resolved.
Show resolved Hide resolved
z-index: 1;
}

Expand Down
2 changes: 1 addition & 1 deletion res/css/views/elements/_SSOButtons.pcss
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ limitations under the License.
}

.mx_SSOButton:hover {
background-color: $panel-hover;
background-color: var(--cpd-color-alpha-gray-300);
}

.mx_SSOButton_default {
Expand Down
2 changes: 1 addition & 1 deletion res/css/views/elements/_StyledCheckbox.pcss
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ limitations under the License.
width: $size;
size: 0.5rem;

border: $border-size solid rgba($muted-fg-color, 0.5);
border: $border-size solid var(--cpd-color-border-interactive-primary);
box-sizing: border-box;
border-radius: $border-radius;

Expand Down
2 changes: 1 addition & 1 deletion res/css/views/elements/_Tooltip.pcss
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,7 @@ limitations under the License.
word-break: break-word;

background-color: #21262c; /* Same on both themes */
color: $accent-fg-color;
color: $secondary-content;
border: 0;
text-align: center;

Expand Down
2 changes: 1 addition & 1 deletion res/css/views/right_panel/_UserInfo.pcss
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@ limitations under the License.
}

.mx_UserInfo_separator {
border-bottom: 1px solid rgba($primary-content, 0.1);
border-bottom: 1px solid var(--cpd-color-gray-600);
germain-gg marked this conversation as resolved.
Show resolved Hide resolved
}

.mx_UserInfo_memberDetailsContainer {
Expand Down
2 changes: 1 addition & 1 deletion res/css/views/rooms/_EditMessageComposer.pcss
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ limitations under the License.
padding: 3px 6px;

&:focus {
border-color: rgba($accent, 0.5); /* Only ever used here */
border-color: $accent-500;
germain-gg marked this conversation as resolved.
Show resolved Hide resolved
}
}

Expand Down
6 changes: 4 additions & 2 deletions res/css/views/rooms/_MessageComposer.pcss
Original file line number Diff line number Diff line change
Expand Up @@ -197,11 +197,12 @@ limitations under the License.

&.mx_MessageComposer_closeButtonMenu {
&::after {
background: rgba($accent, 0.1);
background: $accent-300;
germain-gg marked this conversation as resolved.
Show resolved Hide resolved
}

&::before {
background-color: $accent;
z-index: 2;
}
}

Expand Down Expand Up @@ -235,11 +236,12 @@ limitations under the License.

&.mx_MessageComposer_closeButtonMenu {
&::after {
background: rgba($accent, 0.1);
background: $accent-300;
germain-gg marked this conversation as resolved.
Show resolved Hide resolved
}

&::before {
background-color: $accent;
z-index: 2;
}
}

Expand Down
2 changes: 1 addition & 1 deletion res/css/views/rooms/_RecentlyViewedButton.pcss
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ limitations under the License.
width: max-content;
max-width: 240px;
max-height: 400px;
border: 1px solid rgba($primary-content, 0.1);
border: 1px solid var(--cpd-color-gray-300);
germain-gg marked this conversation as resolved.
Show resolved Hide resolved
border-radius: 8px;
box-shadow: 0 8px 4px rgba(0, 0, 0, 0.08);
display: flex;
Expand Down
20 changes: 10 additions & 10 deletions res/css/views/rooms/_RoomHeader.pcss
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ limitations under the License.
min-width: 0;
margin: 0 20px 0 16px;
padding-top: 6px;
border-bottom: 1px solid $system;
border-bottom: 1px solid var(--cpd-color-gray-500);
germain-gg marked this conversation as resolved.
Show resolved Hide resolved

.mx_InviteOnlyIcon_large {
margin: 0;
Expand Down Expand Up @@ -112,7 +112,7 @@ limitations under the License.
}

&[aria-expanded="true"] {
background-color: $quinary-content;
background-color: var(--cpd-color-gray-400);
germain-gg marked this conversation as resolved.
Show resolved Hide resolved

.mx_RoomHeader_chevron {
transform: rotate(180deg);
Expand Down Expand Up @@ -191,7 +191,7 @@ limitations under the License.
}

&:hover {
background: rgba($accent, 0.1);
background: $accent-300;
germain-gg marked this conversation as resolved.
Show resolved Hide resolved

&::before {
background-color: $accent;
Expand All @@ -209,7 +209,7 @@ limitations under the License.
border-radius: 50%;
transform: scale(1.6);
transform-origin: center center;
background: rgba($background, 1);
background: $background;
}

.mx_RoomHeader_button_unreadIndicator {
Expand All @@ -219,18 +219,18 @@ limitations under the License.
margin: 4px;

&.mx_Indicator_red {
background: rgba($alert, 1);
box-shadow: rgba($alert, 1);
background: $alert;
box-shadow: $alert;
}

&.mx_Indicator_gray {
background: rgba($room-icon-unread-color, 1);
box-shadow: rgba($room-icon-unread-color, 1);
background: $room-icon-unread-color;
box-shadow: $room-icon-unread-color;
}

&.mx_Indicator_bold {
background: rgba($primary-content, 1);
box-shadow: rgba($primary-content, 1);
background: $primary-content;
box-shadow: $primary-content;
}
}

Expand Down
4 changes: 2 additions & 2 deletions res/css/views/rooms/_ThreadSummary.pcss
Original file line number Diff line number Diff line change
Expand Up @@ -55,8 +55,8 @@ limitations under the License.
bottom: 0;
width: 60px;
box-sizing: border-box;
/* XXX: We use `$system-transparent` instead of `transparent` to work around a Safari <15.4 bug */
background: linear-gradient(270deg, $system 50%, $system-transparent 100%);
/* XXX: We use an HEXA `transparent` to work around a Safari <15.4 bug */
background: linear-gradient(270deg, $system 50%, #e1e6ec00 100%);
germain-gg marked this conversation as resolved.
Show resolved Hide resolved

opacity: 0;
transform: translateX(60px);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ limitations under the License.
padding: 3px 6px;

&:focus {
border-color: rgba($accent, 0.5); /* Only ever used here */
border-color: $accent-400;
}
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ limitations under the License.

.mx_FormattingButtons_Button_hover {
&:hover {
background: rgba($secondary-content, 0.1);
background: var(--cpd-color-bg-subtle-secondary);

.mx_FormattingButtons_Icon {
color: $secondary-content;
Expand All @@ -43,7 +43,7 @@ limitations under the License.
}

.mx_FormattingButtons_active {
background: rgba($accent, 0.1);
background: $accent-300;

.mx_FormattingButtons_Icon {
color: $accent;
Expand Down
2 changes: 1 addition & 1 deletion res/css/views/settings/_FontScalingPanel.pcss
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ limitations under the License.
display: flex;
align-items: center;
padding: 15px $spacing-20 35px;
background: rgba($quinary-content, 0.2);
background: var(--cpd-color-bg-subtle-secondary);
border-radius: 10px;
font-size: $font-10px;

Expand Down
3 changes: 2 additions & 1 deletion res/css/views/settings/_LayoutSwitcher.pcss
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,7 @@ limitations under the License.
flex-shrink: 1;
display: flex;
flex-direction: column;
overflow: hidden;
t3chguy marked this conversation as resolved.
Show resolved Hide resolved

flex-basis: 33%;
min-width: 0;
Expand Down Expand Up @@ -71,7 +72,7 @@ limitations under the License.
}

.mx_StyledRadioButton_checked {
background-color: rgba($accent, 0.08);
background-color: $accent-200;
germain-gg marked this conversation as resolved.
Show resolved Hide resolved
}

.mx_EventTile {
Expand Down
2 changes: 1 addition & 1 deletion res/css/views/voip/_CallView.pcss
Original file line number Diff line number Diff line change
Expand Up @@ -104,7 +104,7 @@ limitations under the License.
left: 0;
right: 0;

background-color: rgba($call-background, 0.9);
background-color: var(--cpd-color-gray-1100);

display: flex;
justify-content: center;
Expand Down
Loading
Loading