3
0

Add side/top bar variables and minor changes.

This commit is contained in:
Mumbi Francis 2024-01-12 13:41:04 +03:00
parent 82f330a806
commit f983804b33
8 changed files with 34 additions and 10 deletions

View File

@ -173,6 +173,8 @@ export default {
'light', 'light',
'extra-light', 'extra-light',
'body-bg', 'body-bg',
'sidebar-bg',
'topbar-bg',
], ],
lightModeVariables: { lightModeVariables: {
'black': '#162425', 'black': '#162425',

View File

@ -55,7 +55,7 @@
v-if="namespace" v-if="namespace"
class="d-flex flex-column flex-grow-1" class="d-flex flex-column flex-grow-1"
> >
<div class="sticky-top bg-white w-100 py-2"> <div class="sticky-top w-100 py-2">
<b-button <b-button
v-if="isAdminPage" v-if="isAdminPage"
data-test-id="button-public" data-test-id="button-public"

View File

@ -130,6 +130,6 @@ export default {
} }
.b-calendar-inner { .b-calendar-inner {
background-color: white; background-color: var(--white);
} }
</style> </style>

View File

@ -7,9 +7,9 @@
v-model="isExpanded" v-model="isExpanded"
data-test-id="sidebar" data-test-id="sidebar"
:sidebar-class="`sidebar ${isExpanded ? 'expanded' : ''}`" :sidebar-class="`sidebar ${isExpanded ? 'expanded' : ''}`"
:header-class="`bg-white d-block sidebar-header ${isExpanded ? 'expanded border-bottom p-2' : ''}`" :header-class="`d-block sidebar-header ${isExpanded ? 'expanded border-bottom p-2' : ''}`"
:body-class="`bg-white ${isExpanded ? 'px-3' : ''}`" :body-class="`${isExpanded ? 'px-3' : ''}`"
:footer-class="`bg-white rounded-right ${isExpanded ? 'px-2' : ''}`" :footer-class="`rounded-right ${isExpanded ? 'px-2' : ''}`"
:no-header="!isExpanded" :no-header="!isExpanded"
:backdrop="isMobile" :backdrop="isMobile"
:shadow="isExpanded && 'sm'" :shadow="isExpanded && 'sm'"
@ -337,6 +337,10 @@ $header-height: 64px;
<style lang="scss"> <style lang="scss">
$nav-width: 320px; $nav-width: 320px;
.b-sidebar {
background-color: var(--sidebar-bg) !important;
}
.sidebar { .sidebar {
display: flex !important; display: flex !important;
left: calc(-#{$nav-width}) !important; left: calc(-#{$nav-width}) !important;

View File

@ -1,5 +1,5 @@
<template> <template>
<div class="header-navigation d-flex flex-wrap align-items-center pr-3"> <div class="header-navigation d-flex flex-wrap align-items-center pr-3 pb-1 mb-2">
<div <div
class="spacer" class="spacer"
:class="{ :class="{
@ -348,6 +348,7 @@ $nav-user-icon-size: 50px;
.header-navigation { .header-navigation {
width: 100vw; width: 100vw;
min-height: $header-height; min-height: $header-height;
background-color: var(--topbar-bg);
} }
.avatar { .avatar {

View File

@ -45,6 +45,8 @@ editor:
light: Light light: Light
extra-light: Extra light extra-light: Extra light
body-bg: Body background body-bg: Body background
sidebar-bg: Sidebar background
topbar-bg: Topbar background
topbar: topbar:
title: Topbar title: Topbar

View File

@ -1,6 +1,12 @@
@if $theme-mode != "light" { @if $theme-mode != "light" {
[data-color-mode="#{$theme-mode}"] { [data-color-mode="#{$theme-mode}"] {
// Buttons // Buttons
.btn {
color: $body-color;
@include hover() {
color: $body-color;
}
}
@each $color, $value in $theme-colors { @each $color, $value in $theme-colors {
.btn-#{$color} { .btn-#{$color} {
@include button-variant($value, $value); @include button-variant($value, $value);
@ -1719,5 +1725,10 @@
); );
} }
} }
// Custom corteza scss
.b-sidebar {
background-color: $sidebar-bg !important;
}
} }
} }

View File

@ -99,7 +99,7 @@ func provisionTheme(ctx context.Context, s store.Storer, name string, themes []t
func processNewTheme() (themes []types.Theme) { func processNewTheme() (themes []types.Theme) {
lightModeValues := ` lightModeValues := `
{ {
"black":"#162425", "black":"#162425",
"white":"#FFFFFF", "white":"#FFFFFF",
"primary":"#0B344E", "primary":"#0B344E",
"secondary":"#758D9B", "secondary":"#758D9B",
@ -108,12 +108,14 @@ func processNewTheme() (themes []types.Theme) {
"danger":"#E54122", "danger":"#E54122",
"light":"#F3F5F7", "light":"#F3F5F7",
"extra-light":"#E4E9EF", "extra-light":"#E4E9EF",
"body-bg":"#F3F5F7" "body-bg":"#F3F5F7",
"sidebar-bg": "#F3F5F7",
"topbar-bg": "#F3F5F7"
}` }`
darkModeValues := ` darkModeValues := `
{ {
"black":"#FBF7F4", "black":"#FBF7F4",
"white":"#0B344E", "white":"#0B344E",
"primary":"#FF9661", "primary":"#FF9661",
"secondary":"#758D9B", "secondary":"#758D9B",
@ -122,7 +124,9 @@ func processNewTheme() (themes []types.Theme) {
"danger":"#E54122", "danger":"#E54122",
"light":"#768D9A", "light":"#768D9A",
"extra-light":"#23495F", "extra-light":"#23495F",
"body-bg":"#092B40" "body-bg":"#092B40",
"sidebar-bg": "#768D9A",
"topbar-bg": "#768D9A"
}` }`
themes = []types.Theme{ themes = []types.Theme{