diff --git a/client/src/app/+about/about-instance/about-instance.component.scss b/client/src/app/+about/about-instance/about-instance.component.scss index 06ff88193..c162ca598 100644 --- a/client/src/app/+about/about-instance/about-instance.component.scss +++ b/client/src/app/+about/about-instance/about-instance.component.scss @@ -45,6 +45,6 @@ } .section-title { - color: var(--fg); + color: pvar(--fg); } } diff --git a/client/src/app/+accounts/accounts.component.scss b/client/src/app/+accounts/accounts.component.scss index f03247547..a3035abb9 100644 --- a/client/src/app/+accounts/accounts.component.scss +++ b/client/src/app/+accounts/accounts.component.scss @@ -4,8 +4,8 @@ @use '_miniature' as *; .root { - --myFontSize: 1rem; - --myGreyFontSize: 1rem; + --co-font-size: 1rem; + --co-secondary-font-size: 1rem; } .section-label { @@ -44,7 +44,7 @@ my-copy-button { } .account-avatar-row { - @include avatar-row-responsive(2rem, var(--myGreyFontSize)); + @include avatar-row-responsive(2rem, var(--co-secondary-font-size)); } .actor-display-name { @@ -101,8 +101,8 @@ my-copy-button { @media screen and (max-width: $mobile-view) { .root { - --myFontSize: 14px; - --myGreyFontSize: 13px; + --co-font-size: 14px; + --co-secondary-font-size: 13px; } .links { diff --git a/client/src/app/+admin/follows/followers-list/followers-list.component.scss b/client/src/app/+admin/follows/followers-list/followers-list.component.scss index 3a0fed6db..c442dca4c 100644 --- a/client/src/app/+admin/follows/followers-list/followers-list.component.scss +++ b/client/src/app/+admin/follows/followers-list/followers-list.component.scss @@ -1,22 +1,6 @@ @use '_variables' as *; @use '_mixins' as *; -a { - display: inline-block; - - @include disable-default-a-behaviour; - - &, - &:hover { - color: pvar(--fg); - } - - span { - font-size: 80%; - color: pvar(--secondary-750); - } -} - .action-cell { my-button:first-child { @include margin-right(10px); diff --git a/client/src/app/+admin/follows/following-list/following-list.component.scss b/client/src/app/+admin/follows/following-list/following-list.component.scss index 6c252ca45..89bde6b87 100644 --- a/client/src/app/+admin/follows/following-list/following-list.component.scss +++ b/client/src/app/+admin/follows/following-list/following-list.component.scss @@ -2,19 +2,7 @@ @use '_mixins' as *; a { - display: inline-block; - - @include disable-default-a-behaviour; - - &, - &:hover { - color: pvar(--fg); - } - - span { - font-size: 80%; - color: pvar(--secondary-750); - } + color: pvar(--fg); } my-delete-button { diff --git a/client/src/app/+admin/follows/video-redundancies-list/video-redundancies-list.component.scss b/client/src/app/+admin/follows/video-redundancies-list/video-redundancies-list.component.scss index 7457cbf46..8ec568074 100644 --- a/client/src/app/+admin/follows/video-redundancies-list/video-redundancies-list.component.scss +++ b/client/src/app/+admin/follows/video-redundancies-list/video-redundancies-list.component.scss @@ -2,19 +2,7 @@ @use '_mixins' as *; a { - display: inline-block; - - @include disable-default-a-behaviour; - - &, - &:hover { - color: pvar(--fg); - } - - span { - font-size: 80%; - color: pvar(--secondary-750); - } + color: pvar(--fg); } .expansion-block { diff --git a/client/src/app/+admin/overview/users/user-edit/user-edit.component.scss b/client/src/app/+admin/overview/users/user-edit/user-edit.component.scss index 29c146017..0672a8087 100644 --- a/client/src/app/+admin/overview/users/user-edit/user-edit.component.scss +++ b/client/src/app/+admin/overview/users/user-edit/user-edit.component.scss @@ -54,7 +54,7 @@ my-select-custom-value { > a, > div { padding: 20px; - background: pvar(--secondary-400); + background: pvar(--bg-secondary-400); border-radius: 4px; box-sizing: border-box; height: 100%; @@ -72,7 +72,7 @@ my-select-custom-value { .dashboard-label { font-size: 90%; - color: pvar(--main-fg-400); + color: pvar(--fg-300); text-align: center; } } diff --git a/client/src/app/+admin/plugins/shared/plugin-card.component.scss b/client/src/app/+admin/plugins/shared/plugin-card.component.scss index af7ffb912..81d015291 100644 --- a/client/src/app/+admin/plugins/shared/plugin-card.component.scss +++ b/client/src/app/+admin/plugins/shared/plugin-card.component.scss @@ -3,7 +3,7 @@ .plugin { margin: 15px 0; - background-color: pvar(--secondary-400); + background-color: pvar(--bg-secondary-400); } .first-row { @@ -25,10 +25,10 @@ @include margin-left(10px); my-global-icon { - color: pvar(--main-fg-500); + color: pvar(--fg-400); &[iconName=npm] { - @include fill-svg-color(pvar(--main-fg-500)); + @include fill-svg-color(pvar(--fg-400)); } } } diff --git a/client/src/app/+admin/system/logs/logs.component.scss b/client/src/app/+admin/system/logs/logs.component.scss index c5431d318..f97381a46 100644 --- a/client/src/app/+admin/system/logs/logs.component.scss +++ b/client/src/app/+admin/system/logs/logs.component.scss @@ -92,7 +92,7 @@ my-copy-button { position: absolute; right: 5px; - background: pvar(--secondary-300); + background: pvar(--bg-secondary-300); } @include on-small-main-col { diff --git a/client/src/app/+my-library/+my-video-channels/my-video-channels.component.scss b/client/src/app/+my-library/+my-video-channels/my-video-channels.component.scss index 16bfaa042..9ce6d090c 100644 --- a/client/src/app/+my-library/+my-video-channels/my-video-channels.component.scss +++ b/client/src/app/+my-library/+my-video-channels/my-video-channels.component.scss @@ -44,7 +44,7 @@ my-edit-button { .video-channel-name { font-size: 14px; - color: pvar(--main-fg-400); + color: pvar(--fg-300); @include margin-left(5px); } diff --git a/client/src/app/+my-library/my-history/my-history.component.scss b/client/src/app/+my-library/my-history/my-history.component.scss index bff714727..4e4f04998 100644 --- a/client/src/app/+my-library/my-history/my-history.component.scss +++ b/client/src/app/+my-library/my-history/my-history.component.scss @@ -32,7 +32,7 @@ label { margin: 0 0 0 5px; - color: var(--main-fg-500); + color: pvar(--fg-400); font-weight: $font-semibold; } } diff --git a/client/src/app/+my-library/my-video-playlists/my-video-playlist-elements.component.scss b/client/src/app/+my-library/my-video-playlists/my-video-playlist-elements.component.scss index 44fcf7a36..dbf1b6df7 100644 --- a/client/src/app/+my-library/my-video-playlists/my-video-playlist-elements.component.scss +++ b/client/src/app/+my-library/my-video-playlists/my-video-playlist-elements.component.scss @@ -70,7 +70,7 @@ my-video-playlist-miniature { } .playlist-info { - width: calc(100% + (2 * var(--x-margin-content))); + width: calc(100% + (2 * pvar(--x-margin-content))); padding-top: 20px; margin-bottom: 10px; } diff --git a/client/src/app/+search/search.component.scss b/client/src/app/+search/search.component.scss index b92a99452..0982c4881 100644 --- a/client/src/app/+search/search.component.scss +++ b/client/src/app/+search/search.component.scss @@ -86,7 +86,7 @@ } .video-channel-name { - color: pvar(--main-fg-400); + color: pvar(--fg-300); } // Use the same breakpoints as in video-miniature diff --git a/client/src/app/+signup/+register/custom-stepper.component.scss b/client/src/app/+signup/+register/custom-stepper.component.scss index 3ec59f9f8..ac5a32db1 100644 --- a/client/src/app/+signup/+register/custom-stepper.component.scss +++ b/client/src/app/+signup/+register/custom-stepper.component.scss @@ -47,7 +47,7 @@ header { justify-content: center; align-items: center; // Better than border color for aliasing - box-shadow: 0 0 0 1px var(--primary); + box-shadow: 0 0 0 1px pvar(--primary); overflow: hidden; my-global-icon { diff --git a/client/src/app/+stats/video/video-stats.component.scss b/client/src/app/+stats/video/video-stats.component.scss index 9aa4c1cfe..b20d7b07c 100644 --- a/client/src/app/+stats/video/video-stats.component.scss +++ b/client/src/app/+stats/video/video-stats.component.scss @@ -39,7 +39,7 @@ height: fit-content; min-height: 100px; min-width: 200px; - background-color: pvar(--secondary-400); + background-color: pvar(--bg-secondary-400); margin-bottom: 15px; @include margin-right(15px); diff --git a/client/src/app/+stats/video/video-stats.component.ts b/client/src/app/+stats/video/video-stats.component.ts index 5131b8821..79605b0a0 100644 --- a/client/src/app/+stats/video/video-stats.component.ts +++ b/client/src/app/+stats/video/video-stats.component.ts @@ -46,7 +46,7 @@ type ChartBuilderResult = { type Card = { label: string, value: string | number, moreInfo?: string, help?: string } ChartJSDefaults.backgroundColor = getComputedStyle(document.body).getPropertyValue('--bg') -ChartJSDefaults.borderColor = getComputedStyle(document.body).getPropertyValue('--secondary-350') +ChartJSDefaults.borderColor = getComputedStyle(document.body).getPropertyValue('--bg-secondary-350') ChartJSDefaults.color = getComputedStyle(document.body).getPropertyValue('--fg') @Component({ diff --git a/client/src/app/+video-channels/video-channels.component.scss b/client/src/app/+video-channels/video-channels.component.scss index fb7cbcfe0..bd87fc5d0 100644 --- a/client/src/app/+video-channels/video-channels.component.scss +++ b/client/src/app/+video-channels/video-channels.component.scss @@ -4,11 +4,11 @@ @use '_miniature' as *; .root { - --myGlobalTopPadding: 60px; - --myChannelImgMargin: 30px; - --myFontSize: 16px; - --myChannelHandleFontSize: 16px; - --myOwnerHandleFontSize: 14px; + --co-global-top-padding: 60px; + --co-channel-img-margin: 30px; + --co-font-size: 16px; + --co-channel-handle-font-size: 16px; + --co-owner-handle-font-size: 14px; } .section-label { @@ -35,8 +35,8 @@ grid-template-rows: auto auto; background-color: pvar(--channel-bg); - padding-top: var(--myGlobalTopPadding); - font-size: var(--myFontSize); + padding-top: var(--co-global-top-padding); + font-size: var(--co-font-size); // Use the same margin as the videos grid @include grid-videos-miniature-margins(false, 15px); @@ -44,7 +44,7 @@ } .channel-avatar-row { - @include avatar-row-responsive(var(--myChannelImgMargin), var(--myChannelHandleFontSize)); + @include avatar-row-responsive(var(--co-channel-img-margin), var(--co-channel-handle-font-size)); } .support-button { @@ -54,7 +54,7 @@ .channel-description { grid-column: 1; word-break: break-word; - padding-bottom: var(--myGlobalTopPadding); + padding-bottom: var(--co-global-top-padding); } .show-more { @@ -100,7 +100,7 @@ background-color: pvar(--bg); padding: 30px; width: 300px; - font-size: var(--myFontSize); + font-size: var(--co-font-size); .avatar-row { display: flex; @@ -120,8 +120,8 @@ } .actor-handle { - font-size: var(--myOwnerHandleFontSize); - color: pvar(--main-fg-400); + font-size: var(--co-owner-handle-font-size); + color: pvar(--fg-300); } } @@ -156,8 +156,8 @@ my-copy-button { @media screen and (max-width: 1100px) { .root { - --myGlobalTopPadding: 45px; - --myChannelImgMargin: 15px; + --co-global-top-padding: 45px; + --co-channel-img-margin: 15px; } .channel-info { @@ -194,7 +194,7 @@ my-copy-button { display: block; width: 100%; border-bottom: 2px solid $separator-border-color; - padding: var(--myGlobalTopPadding) 45px; + padding: var(--co-global-top-padding) 45px; margin-bottom: 60px; } @@ -234,10 +234,10 @@ my-copy-button { @media screen and (max-width: $mobile-view) { .root { - --myGlobalTopPadding: 15px; - --myFontSize: 14px; - --myChannelHandleFontSize: 13px; - --myOwnerHandleFontSize: 13px; + --co-global-top-padding: 15px; + --co-font-size: 14px; + --co-channel-handle-font-size: 13px; + --co-owner-handle-font-size: 13px; } .links { diff --git a/client/src/app/+video-studio/edit/video-studio-edit.component.scss b/client/src/app/+video-studio/edit/video-studio-edit.component.scss index 099f72d44..9d45a8fb3 100644 --- a/client/src/app/+video-studio/edit/video-studio-edit.component.scss +++ b/client/src/app/+video-studio/edit/video-studio-edit.component.scss @@ -83,7 +83,7 @@ h2 { } .description { - color: pvar(--main-fg-400); + color: pvar(--fg-300); margin-top: 5px; margin-bottom: 15px; } diff --git a/client/src/app/+videos/+video-edit/shared/caption/video-caption-edit-modal-content.component.scss b/client/src/app/+videos/+video-edit/shared/caption/video-caption-edit-modal-content.component.scss index 61494a0e1..902167f74 100644 --- a/client/src/app/+videos/+video-edit/shared/caption/video-caption-edit-modal-content.component.scss +++ b/client/src/app/+videos/+video-edit/shared/caption/video-caption-edit-modal-content.component.scss @@ -18,7 +18,7 @@ &.active, &:hover { - background: pvar(--secondary-300); + background: pvar(--bg-secondary-300); } } diff --git a/client/src/app/+videos/+video-edit/shared/video-edit.component.scss b/client/src/app/+videos/+video-edit/shared/video-edit.component.scss index 52809a2bc..740b88e27 100644 --- a/client/src/app/+videos/+video-edit/shared/video-edit.component.scss +++ b/client/src/app/+videos/+video-edit/shared/video-edit.component.scss @@ -68,7 +68,7 @@ my-timestamp-input { .message-submit { display: inline-block; - color: pvar(--main-fg-400); + color: pvar(--fg-300); @include margin-right(25px); } diff --git a/client/src/app/+videos/+video-edit/video-add-components/video-import-torrent.component.scss b/client/src/app/+videos/+video-edit/video-add-components/video-import-torrent.component.scss index 64f8a86c1..f814787f9 100644 --- a/client/src/app/+videos/+video-edit/video-add-components/video-import-torrent.component.scss +++ b/client/src/app/+videos/+video-edit/video-add-components/video-import-torrent.component.scss @@ -3,7 +3,7 @@ .first-step-block { .torrent-or-magnet { - @include divider($color: pvar(--secondary-750), $background: pvar(--secondary-400)); + @include divider($color: pvar(--secondary-icon-color), $background: pvar(--bg-secondary-400)); &[data-content] { margin: 1.5rem 0; diff --git a/client/src/app/+videos/+video-edit/video-add-components/video-send.scss b/client/src/app/+videos/+video-edit/video-add-components/video-send.scss index 81ffa0a60..11f3dddc2 100644 --- a/client/src/app/+videos/+video-edit/video-add-components/video-send.scss +++ b/client/src/app/+videos/+video-edit/video-add-components/video-send.scss @@ -19,7 +19,7 @@ $width-size: 275px; .upload-icon { width: 90px; margin-bottom: 25px; - color: pvar(--main-fg-400); + color: pvar(--fg-300); } .peertube-select-container { diff --git a/client/src/app/+videos/+video-edit/video-add.component.scss b/client/src/app/+videos/+video-edit/video-add.component.scss index 9b5560a3e..9b59b8d7b 100644 --- a/client/src/app/+videos/+video-edit/video-add.component.scss +++ b/client/src/app/+videos/+video-edit/video-add.component.scss @@ -41,21 +41,21 @@ $nav-link-height: 40px; padding-top: 20px; } -::ng-deep .video-add-nav { +:host ::ng-deep .video-add-nav { @include peertube-nav-tabs($border-width, $border-type, $border-color, $nav-link-height); a.nav-link { &.active { - background-color: pvar(--secondary-400) !important; + background-color: pvar(--bg-secondary-400) !important; } } } -::ng-deep .upload-video-container { +:host ::ng-deep .upload-video-container { border: $border-width $border-type $border-color; border-top: transparent; - background-color: pvar(--secondary-400); + background-color: pvar(--bg-secondary-400); border-bottom-left-radius: 3px; border-bottom-right-radius: 3px; width: 100%; diff --git a/client/src/app/+videos/+video-watch/shared/action-buttons/action-buttons.component.scss b/client/src/app/+videos/+video-watch/shared/action-buttons/action-buttons.component.scss index e73d5c17d..daaab3ece 100644 --- a/client/src/app/+videos/+video-watch/shared/action-buttons/action-buttons.component.scss +++ b/client/src/app/+videos/+video-watch/shared/action-buttons/action-buttons.component.scss @@ -22,7 +22,7 @@ padding: 4px 10px; white-space: nowrap; background-color: transparent !important; - color: pvar(--main-fg-400); + color: pvar(--fg-300); text-transform: uppercase; @include peertube-button; @@ -92,7 +92,7 @@ background-color: #909090; &.liked { - background-color: pvar(--main-fg-500); + background-color: pvar(--fg-400); } } } diff --git a/client/src/app/+videos/+video-watch/shared/action-buttons/video-rate.component.scss b/client/src/app/+videos/+video-watch/shared/action-buttons/video-rate.component.scss index 9e128562b..d4b0f68e6 100644 --- a/client/src/app/+videos/+video-watch/shared/action-buttons/video-rate.component.scss +++ b/client/src/app/+videos/+video-watch/shared/action-buttons/video-rate.component.scss @@ -11,5 +11,5 @@ } .activated { - color: pvar(--main-fg-500) !important; + color: pvar(--fg-400) !important; } diff --git a/client/src/app/+videos/+video-watch/shared/comment/video-comment.component.scss b/client/src/app/+videos/+video-watch/shared/comment/video-comment.component.scss index 832814847..3a1046123 100644 --- a/client/src/app/+videos/+video-watch/shared/comment/video-comment.component.scss +++ b/client/src/app/+videos/+video-watch/shared/comment/video-comment.component.scss @@ -32,7 +32,7 @@ .highlighted-comment { display: inline-block; - background-color: pvar(--secondary-350); + background-color: pvar(--bg-secondary-350); color: pvar(--fg); padding: 0 5px; font-size: 13px; @@ -78,13 +78,13 @@ } .comment-account-fid { - color: pvar(--main-fg-400); + color: pvar(--fg-300); } } .comment-date { font-size: 90%; - color: pvar(--main-fg-400); + color: pvar(--fg-300); text-decoration: none; @include margin-left(5px); @@ -116,7 +116,7 @@ } &.comment-html-deleted { - color: pvar(--main-fg-400); + color: pvar(--fg-300); margin-bottom: 1rem; } } @@ -127,7 +127,7 @@ ::ng-deep .dropdown-toggle, .comment-action-reply { - color: pvar(--main-fg-400); + color: pvar(--fg-300); cursor: pointer; @include margin-right(10px); diff --git a/client/src/app/+videos/+video-watch/shared/metadata/video-attributes.component.scss b/client/src/app/+videos/+video-watch/shared/metadata/video-attributes.component.scss index dab323a54..01967e0a7 100644 --- a/client/src/app/+videos/+video-watch/shared/metadata/video-attributes.component.scss +++ b/client/src/app/+videos/+video-watch/shared/metadata/video-attributes.component.scss @@ -10,7 +10,7 @@ .attribute-label { min-width: 142px; display: inline-block; - color: pvar(--main-fg-400); + color: pvar(--fg-300); font-weight: $font-bold; @include padding-right(5px); diff --git a/client/src/app/+videos/+video-watch/shared/metadata/video-description.component.scss b/client/src/app/+videos/+video-watch/shared/metadata/video-description.component.scss index 046e78497..aa51dd4ea 100644 --- a/client/src/app/+videos/+video-watch/shared/metadata/video-description.component.scss +++ b/client/src/app/+videos/+video-watch/shared/metadata/video-description.component.scss @@ -29,7 +29,7 @@ .video-info-description-more { cursor: pointer; font-weight: $font-semibold; - color: pvar(--main-fg-400); + color: pvar(--fg-300); margin-top: 1rem; @include font-size(14px); diff --git a/client/src/app/+videos/+video-watch/shared/player-widgets/player-widget.component.scss b/client/src/app/+videos/+video-watch/shared/player-widgets/player-widget.component.scss index 777df36db..a4e765491 100644 --- a/client/src/app/+videos/+video-watch/shared/player-widgets/player-widget.component.scss +++ b/client/src/app/+videos/+video-watch/shared/player-widgets/player-widget.component.scss @@ -12,7 +12,7 @@ border-bottom: 1px solid $separator-border-color; .widget-header { - background-color: pvar(--secondary-400); + background-color: pvar(--bg-secondary-400); padding: 1rem 2rem; } diff --git a/client/src/app/+videos/+video-watch/shared/player-widgets/video-transcription.component.scss b/client/src/app/+videos/+video-watch/shared/player-widgets/video-transcription.component.scss index d5ee3e554..e74d00119 100644 --- a/client/src/app/+videos/+video-watch/shared/player-widgets/video-transcription.component.scss +++ b/client/src/app/+videos/+video-watch/shared/player-widgets/video-transcription.component.scss @@ -4,7 +4,7 @@ .segment { &.active, &:hover { - background: pvar(--secondary-300); + background: pvar(--bg-secondary-300); } } diff --git a/client/src/app/+videos/+video-watch/shared/player-widgets/video-watch-playlist.component.scss b/client/src/app/+videos/+video-watch/shared/player-widgets/video-watch-playlist.component.scss index 7482702a5..1e1336ffc 100644 --- a/client/src/app/+videos/+video-watch/shared/player-widgets/video-watch-playlist.component.scss +++ b/client/src/app/+videos/+video-watch/shared/player-widgets/video-watch-playlist.component.scss @@ -5,7 +5,7 @@ .playlist { .playlist-by-index { - color: pvar(--main-fg-400); + color: pvar(--fg-300); display: flex; .playlist-by { diff --git a/client/src/app/+videos/+video-watch/video-watch.component.scss b/client/src/app/+videos/+video-watch/video-watch.component.scss index 899199dee..894ab4d42 100644 --- a/client/src/app/+videos/+video-watch/video-watch.component.scss +++ b/client/src/app/+videos/+video-watch/video-watch.component.scss @@ -40,7 +40,7 @@ $video-max-height: calc(100vh - #{$header-height} - #{$theater-bottom-space}); } ::ng-deep .video-js { - --player-height: #{$video-max-height}; + --co-player-height: #{$video-max-height}; } .player-widget-component ::ng-deep .widget-root { @@ -62,16 +62,16 @@ $video-max-height: calc(100vh - #{$header-height} - #{$theater-bottom-space}); } ::ng-deep .video-js { - --player-height: #{$video-default-height}; - --player-portrait-mode: 0; + --co-player-height: #{$video-default-height}; + --co-player-portrait-mode: 0; // Default player ratio, redefined by the player to automatically adapt player size - --player-ratio: #{math.div(16, 9)}; + --co-player-ratio: #{math.div(16, 9)}; width: 100%; - height: var(--player-height); + height: var(--co-player-height); // Can be recalculated by the player depending on video ratio - max-width: calc(var(--player-height) * var(--player-ratio)); + max-width: calc(var(--co-player-height) * var(--co-player-ratio)); // VideoJS create an inner video player video { @@ -253,8 +253,8 @@ my-video-comments { .remote-server-down, ::ng-deep .video-js { - --player-portrait-mode: 1; - --player-height: calc(100vw / var(--player-ratio)) !important; + --co-player-portrait-mode: 1; + --co-player-height: calc(100vw / var(--co-player-ratio)) !important; max-height: calc(100vh - #{$header-height} - #{$player-portrait-bottom-space}); } diff --git a/client/src/app/core/theme/theme.service.ts b/client/src/app/core/theme/theme.service.ts index ba785a775..edfdc2033 100644 --- a/client/src/app/core/theme/theme.service.ts +++ b/client/src/app/core/theme/theme.service.ts @@ -181,8 +181,8 @@ export class ThemeService { const toProcess = [ { prefix: 'primary', invertIfDark: false }, - { prefix: 'secondary', invertIfDark: true }, - { prefix: 'main-fg', invertIfDark: true } + { prefix: 'bg-secondary', invertIfDark: true }, + { prefix: 'fg', invertIfDark: true } ] for (const { prefix, invertIfDark } of toProcess) { diff --git a/client/src/app/header/header.component.scss b/client/src/app/header/header.component.scss index 9dc144d3d..7a329340c 100644 --- a/client/src/app/header/header.component.scss +++ b/client/src/app/header/header.component.scss @@ -2,6 +2,10 @@ @use '_variables' as *; @use '_mixins' as *; +.root { + background-color: pvar(--bg); +} + .peertube-title { font-size: 24px; font-weight: $font-bold; @@ -70,7 +74,7 @@ } .username { - color: pvar(--main-fg-400); + color: pvar(--fg-300); } > .dropdown-toggle { diff --git a/client/src/app/menu/menu.component.scss b/client/src/app/menu/menu.component.scss index a511a2259..341b66460 100644 --- a/client/src/app/menu/menu.component.scss +++ b/client/src/app/menu/menu.component.scss @@ -3,7 +3,7 @@ @use '_mixins' as *; .menu-container { - --menuXPadding: 1.5rem; + --co-menu-x-padding: 1.5rem; z-index: z(menu); width: calc(#{$menu-width} - 2rem); @@ -13,7 +13,7 @@ @include margin-left(2rem); &.collapsed { - --menuXPadding: 0.25rem; + --co-menu-x-padding: 0.25rem; width: auto; @@ -30,11 +30,11 @@ } .toggle-menu { - color: pvar(--secondary-750); + color: pvar-fallback(--menu-fg, --fg-200); width: 24px; height: 24px; border-radius: 100%; - background-color: pvar(--secondary-450); + background-color: pvar-fallback(--menu-bg, --bg-secondary-500); @include button-with-icon(20px, 0, 0, 1px); @@ -89,7 +89,7 @@ padding-top: 1.5rem; padding-bottom: 1.5rem; border-radius: 14px; - background-color: pvar(--secondary-400); + background-color: pvar-fallback(--menu-bg, --bg-secondary-400); } .menu-link, @@ -97,8 +97,8 @@ .block-title, .about .description, .about my-button { - @include padding-left(var(--menuXPadding)); - @include padding-right(var(--menuXPadding)); + @include padding-left(var(--co-menu-x-padding)); + @include padding-right(var(--co-menu-x-padding)); } .menu-block, @@ -107,8 +107,7 @@ content: ''; display: block; height: 2px; - background: pvar(--secondary-450); - margin: 1rem var(--menuXPadding); + margin: 1rem var(--co-menu-x-padding); } } @@ -136,6 +135,7 @@ .block-title { font-weight: $font-bold; + color: pvar-fallback(--menu-fg, --fg-350); font-size: 14px; margin-bottom: 0.5rem; } @@ -144,7 +144,7 @@ display: flex; align-items: center; - color: pvar(--main-fg-450); + color: pvar-fallback(--menu-fg, --fg-400); white-space: normal; word-break: break-word; transition: background-color .1s ease-in-out; @@ -156,11 +156,11 @@ &:hover, &:focus-visible { - background-color: pvar(--secondary-500); + background-color: pvar-fallback(--menu-fg, --bg-secondary-500); } &.active { - background-color: pvar(--secondary-600); + background-color: pvar-fallback(--menu-fg, --bg-secondary-600); } my-global-icon { @@ -169,7 +169,7 @@ line-height: 22px; position: relative; top: -1px; - color: pvar(--secondary-750); + color: pvar-fallback(--menu-fg, --secondary-icon-color); + *:not(.visually-hidden) { @include margin-left(12px); @@ -184,6 +184,6 @@ .about { .description { font-size: 14px; - color: pvar(--main-fg-300); + color: pvar-fallback(--menu-fg, --fg-200) } } diff --git a/client/src/app/shared/shared-abuse-list/abuse-list-table.component.scss b/client/src/app/shared/shared-abuse-list/abuse-list-table.component.scss index c1f90528e..5d62f1490 100644 --- a/client/src/app/shared/shared-abuse-list/abuse-list-table.component.scss +++ b/client/src/app/shared/shared-abuse-list/abuse-list-table.component.scss @@ -5,7 +5,7 @@ .account-flagged-handle, .video-owner { font-size: 11px; - color: var(--main-fg-400); + color: pvar(--fg-300); } .abuse-messages { diff --git a/client/src/app/shared/shared-abuse-list/abuse-message-modal.component.scss b/client/src/app/shared/shared-abuse-list/abuse-message-modal.component.scss index 66d26615a..70f972695 100644 --- a/client/src/app/shared/shared-abuse-list/abuse-message-modal.component.scss +++ b/client/src/app/shared/shared-abuse-list/abuse-message-modal.component.scss @@ -33,7 +33,7 @@ textarea { max-width: 60%; .author { - color: var(--main-fg-400); + color: pvar(--fg-300); font-size: 14px; padding: 0 0 3px 10px; } @@ -41,23 +41,23 @@ textarea { .bubble { border-radius: 10px; padding: 5px 10px; - color: var(--fg); - background-color: var(--secondary-400); + color: pvar(--fg); + background-color: pvar(--bg-secondary-400); .date { font-size: 13px; - color: var(--main-fg-400); + color: pvar(--fg-300); } } &.by-me { .bubble { - color: var(--on-primary); - background-color: var(--primary-400); + color: pvar(--on-primary); + background-color: pvar(--primary-400); .date { - color: var(--on-primary); + color: pvar(--on-primary); } } } diff --git a/client/src/app/shared/shared-actor-image-edit/actor-avatar-edit.component.scss b/client/src/app/shared/shared-actor-image-edit/actor-avatar-edit.component.scss index c4a9dcaf1..825bacc39 100644 --- a/client/src/app/shared/shared-actor-image-edit/actor-avatar-edit.component.scss +++ b/client/src/app/shared/shared-actor-image-edit/actor-avatar-edit.component.scss @@ -24,7 +24,7 @@ .actor-info-username { position: relative; font-size: 14px; - color: pvar(--main-fg-400); + color: pvar(--fg-300); } .actor-info-followers { diff --git a/client/src/app/shared/shared-actor-image-edit/actor-banner-edit.component.scss b/client/src/app/shared/shared-actor-image-edit/actor-banner-edit.component.scss index b5e27c4ee..84c9a7883 100644 --- a/client/src/app/shared/shared-actor-image-edit/actor-banner-edit.component.scss +++ b/client/src/app/shared/shared-actor-image-edit/actor-banner-edit.component.scss @@ -6,7 +6,7 @@ } .banner-placeholder { - background-color: pvar(--secondary-350); + background-color: pvar(--bg-secondary-350); } .actor-img-edit-container { diff --git a/client/src/app/shared/shared-actor-image/actor-avatar.component.scss b/client/src/app/shared/shared-actor-image/actor-avatar.component.scss index 9eef52575..7c8c20116 100644 --- a/client/src/app/shared/shared-actor-image/actor-avatar.component.scss +++ b/client/src/app/shared/shared-actor-image/actor-avatar.component.scss @@ -3,10 +3,10 @@ .avatar { // Defined in component - width: var(--avatarSize); - height: var(--avatarSize); - min-width: var(--avatarSize); - min-height: var(--avatarSize); + width: var(--co-avatar-size); + height: var(--co-avatar-size); + min-width: var(--co-avatar-size); + min-height: var(--co-avatar-size); &.account { object-fit: cover; @@ -28,7 +28,8 @@ a:hover { display: flex; align-items: center; justify-content: center; - font-size: var(--initialFontSize); + // Defined in component + font-size: var(--co-font-size); &.blue { background-color: #009FD4; diff --git a/client/src/app/shared/shared-actor-image/actor-avatar.component.ts b/client/src/app/shared/shared-actor-image/actor-avatar.component.ts index 02b8ded73..3262a6028 100644 --- a/client/src/app/shared/shared-actor-image/actor-avatar.component.ts +++ b/client/src/app/shared/shared-actor-image/actor-avatar.component.ts @@ -69,7 +69,7 @@ export class ActorAvatarComponent implements OnInit, OnChanges { private buildClasses () { let avatarSize = '100%' - let initialFontSize = '22px' + let fontSize = '22px' this.classes = [ 'avatar' ] @@ -77,11 +77,11 @@ export class ActorAvatarComponent implements OnInit, OnChanges { avatarSize = `${this.size}px` if (this.size <= 18) { - initialFontSize = '13px' + fontSize = '13px' } else if (this.size >= 100) { - initialFontSize = '40px' + fontSize = '40px' } else if (this.size >= 120) { - initialFontSize = '46px' + fontSize = '46px' } } @@ -98,8 +98,8 @@ export class ActorAvatarComponent implements OnInit, OnChanges { } const elStyle = (this.el.nativeElement as HTMLElement).style - elStyle.setProperty('--avatarSize', avatarSize) - elStyle.setProperty('--initialFontSize', initialFontSize) + elStyle.setProperty('--co-avatar-size', avatarSize) + elStyle.setProperty('--co-font-size', fontSize) } private buildDefaultAvatarUrl () { diff --git a/client/src/app/shared/shared-custom-markup/peertube-custom-tags/channel-miniature-markup.component.scss b/client/src/app/shared/shared-custom-markup/peertube-custom-tags/channel-miniature-markup.component.scss index fc0c5590b..ce2662a5d 100644 --- a/client/src/app/shared/shared-custom-markup/peertube-custom-tags/channel-miniature-markup.component.scss +++ b/client/src/app/shared/shared-custom-markup/peertube-custom-tags/channel-miniature-markup.component.scss @@ -52,6 +52,6 @@ .video-label { font-size: 12px; - color: pvar(--main-fg-400); + color: pvar(--fg-300); margin: 15px 0 5px; } diff --git a/client/src/app/shared/shared-forms/markdown-textarea.component.scss b/client/src/app/shared/shared-forms/markdown-textarea.component.scss index b28a7840a..0b33ae96b 100644 --- a/client/src/app/shared/shared-forms/markdown-textarea.component.scss +++ b/client/src/app/shared/shared-forms/markdown-textarea.component.scss @@ -11,7 +11,7 @@ $input-border-radius: 3px; flex-direction: column; textarea { - background-color: pvar(--secondary-350); + background-color: pvar(--bg-secondary-350); font-family: monospace; font-size: 13px; @@ -120,7 +120,7 @@ $input-border-radius: 3px; overflow-y: auto; word-wrap: break-word; - scrollbar-color: pvar(--main-fg-400) pvar(--bg); + scrollbar-color: pvar(--fg-300) pvar(--bg); } textarea, diff --git a/client/src/app/shared/shared-forms/peertube-checkbox.component.html b/client/src/app/shared/shared-forms/peertube-checkbox.component.html index 1ea52896e..bea2d05ce 100644 --- a/client/src/app/shared/shared-forms/peertube-checkbox.component.html +++ b/client/src/app/shared/shared-forms/peertube-checkbox.component.html @@ -1,5 +1,5 @@