2018-07-26 16:40:34 +02:00
|
|
|
@import '~@angular/material/theming';
|
|
|
|
|
|
|
|
/** Custom component theme. Only lives in a specific scope */
|
2018-09-03 17:57:20 +02:00
|
|
|
@mixin os-site-theme($theme) {
|
2018-07-26 16:40:34 +02:00
|
|
|
$primary: map-get($theme, primary);
|
|
|
|
$accent: map-get($theme, accent);
|
|
|
|
$warn: map-get($theme, accent);
|
|
|
|
$foreground: map-get($theme, foreground);
|
|
|
|
$background: map-get($theme, background);
|
|
|
|
|
2018-08-03 11:05:21 +02:00
|
|
|
/** the name of the selector */
|
2018-09-03 17:57:20 +02:00
|
|
|
os-site {
|
2018-08-03 11:05:21 +02:00
|
|
|
mat-sidenav-container {
|
|
|
|
/** nav panel on the left */
|
|
|
|
mat-sidenav {
|
|
|
|
/** rules for icons in the whole site-view */
|
2018-10-11 14:03:44 +02:00
|
|
|
mat-icon {
|
2018-08-03 11:05:21 +02:00
|
|
|
min-width: 20px; //puts the text to the right on the same level
|
|
|
|
margin-right: 10px; // the distance from the icon to the text
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2018-07-31 15:46:55 +02:00
|
|
|
/** adjust the color of the main container to our theme */
|
|
|
|
.main-container {
|
|
|
|
background-color: mat-color($background, background);
|
|
|
|
}
|
|
|
|
|
2018-07-26 16:40:34 +02:00
|
|
|
/** change the nav-toolbar to the darker nuance of the current theme*/
|
|
|
|
.nav-toolbar {
|
2018-08-03 11:05:21 +02:00
|
|
|
height: 80px;
|
2018-07-26 16:40:34 +02:00
|
|
|
background-color: mat-color($primary, darker);
|
2018-08-03 11:05:21 +02:00
|
|
|
|
|
|
|
mat-toolbar-row {
|
|
|
|
height: 80px;
|
|
|
|
}
|
2018-07-26 16:40:34 +02:00
|
|
|
}
|
|
|
|
|
|
|
|
/** make the .user-menu expansion panel look like the nav-toolbar above */
|
|
|
|
.user-menu {
|
2018-10-05 16:34:08 +02:00
|
|
|
background: mat-color($primary, darker);
|
|
|
|
// background-color: mat-color($primary, darker);
|
2018-07-31 15:46:55 +02:00
|
|
|
color: mat-color($background, raised-button);
|
2018-08-03 11:05:21 +02:00
|
|
|
min-height: 48px;
|
|
|
|
|
|
|
|
/** color of the divider just above the log out button */
|
|
|
|
mat-divider {
|
|
|
|
border-top-color: rgba(255, 255, 255, 0.25);
|
|
|
|
}
|
|
|
|
|
2018-10-11 14:03:44 +02:00
|
|
|
mat-icon {
|
2018-08-03 11:05:21 +02:00
|
|
|
color: mat-color($background, raised-button);
|
|
|
|
}
|
|
|
|
|
|
|
|
span {
|
|
|
|
color: mat-color($background, raised-button);
|
|
|
|
}
|
2018-07-26 16:40:34 +02:00
|
|
|
|
|
|
|
.mat-expansion-indicator:after {
|
2018-07-31 15:46:55 +02:00
|
|
|
color: mat-color($background, raised-button);
|
2018-07-26 16:40:34 +02:00
|
|
|
}
|
2018-10-05 16:34:08 +02:00
|
|
|
|
|
|
|
.mat-expansion-panel-header:hover {
|
|
|
|
// prevent the panel to become white after collapse
|
|
|
|
background: mat-color($primary, darker) !important;
|
|
|
|
}
|
2018-07-26 16:40:34 +02:00
|
|
|
}
|
|
|
|
|
2018-07-31 15:46:55 +02:00
|
|
|
/** style and align the nav icons the icons*/
|
2018-07-26 16:40:34 +02:00
|
|
|
.main-nav {
|
2018-10-11 14:03:44 +02:00
|
|
|
mat-icon {
|
2018-07-31 15:46:55 +02:00
|
|
|
color: mat-color($foreground, icon);
|
2018-07-26 16:40:34 +02:00
|
|
|
}
|
|
|
|
span {
|
2018-08-02 16:39:08 +02:00
|
|
|
font-weight: bold;
|
2018-07-31 15:46:55 +02:00
|
|
|
color: mat-color($foreground, text);
|
2018-07-26 16:40:34 +02:00
|
|
|
}
|
|
|
|
}
|
2018-08-02 16:39:08 +02:00
|
|
|
|
|
|
|
/** style the active link */
|
|
|
|
.active {
|
2018-10-11 14:03:44 +02:00
|
|
|
mat-icon {
|
2018-08-02 16:39:08 +02:00
|
|
|
color: mat-color($primary);
|
|
|
|
}
|
|
|
|
span {
|
|
|
|
color: mat-color($primary);
|
|
|
|
}
|
|
|
|
}
|
2018-07-26 16:40:34 +02:00
|
|
|
}
|
|
|
|
}
|