Skip to content

Commit

Permalink
feat: add corporate theme settings
Browse files Browse the repository at this point in the history
  • Loading branch information
mohammad-haji committed Jul 20, 2018
1 parent 4b7b8ad commit e455b97
Show file tree
Hide file tree
Showing 3 changed files with 74 additions and 1 deletion.
24 changes: 24 additions & 0 deletions src/app/@theme/layouts/three-columns/three-columns.layout.scss
Original file line number Diff line number Diff line change
Expand Up @@ -47,11 +47,31 @@

margin-top: nb-theme(sidebar-header-gap);

@include nb-for-theme(corporate) {
margin-top: 0;
}

/deep/ .main-container {
height:
calc(#{nb-theme(sidebar-height)} - #{nb-theme(header-height)} - #{nb-theme(sidebar-header-gap)}) !important;
@include nb-ltr(border-top-right-radius, nb-theme(radius));
@include nb-rtl(border-top-left-radius, nb-theme(radius));

@include nb-for-theme(corporate) {
border: 1px solid nb-theme(separator);
height:
calc(#{nb-theme(sidebar-height)} - #{nb-theme(header-height)}) !important;
}
}

/deep/ .scrollable {
@include nb-for-theme(corporate) {
padding-top: 0;

.menu-item:first-child {
border-top: none;
}
}
}

/deep/ nb-sidebar-header {
Expand All @@ -67,6 +87,10 @@
font-weight: bold;
transition: padding 0.3s cubic-bezier(0.18, 0.89, 0.32, 1.48);

@include nb-for-theme(corporate) {
border-radius: nb-theme(radius);
}

i {
font-size: 2rem;
text-shadow: 0 1px 1px rgba(0, 0, 0, 0.2);
Expand Down
25 changes: 25 additions & 0 deletions src/app/@theme/layouts/two-columns/two-columns.layout.scss
Original file line number Diff line number Diff line change
Expand Up @@ -47,11 +47,32 @@

margin-top: nb-theme(sidebar-header-gap);

@include nb-for-theme(corporate) {
margin-top: 2rem;
}

/deep/ .main-container {
height:
calc(#{nb-theme(sidebar-height)} - #{nb-theme(header-height)} - #{nb-theme(sidebar-header-gap)}) !important;
@include nb-ltr(border-top-right-radius, nb-theme(radius));
@include nb-rtl(border-top-left-radius, nb-theme(radius));

@include nb-for-theme(corporate) {
border: 1px solid nb-theme(separator);
height:
calc(#{nb-theme(sidebar-height)} - #{nb-theme(header-height)}) !important;

}
}

/deep/ .scrollable {
@include nb-for-theme(corporate) {
padding-top: 0;

.menu-item:first-child {
border-top: none;
}
}
}

/deep/ nb-sidebar-header {
Expand All @@ -67,6 +88,10 @@
font-weight: bold;
transition: padding 0.3s cubic-bezier(0.18, 0.89, 0.32, 1.48);

@include nb-for-theme(corporate) {
border-radius: nb-theme(radius);
}

i {
font-size: 2rem;
text-shadow: 0 1px 1px rgba(0, 0, 0, 0.2);
Expand Down
26 changes: 25 additions & 1 deletion src/app/@theme/styles/themes.scss
Original file line number Diff line number Diff line change
Expand Up @@ -4,22 +4,46 @@
@import '~@nebular/theme/styles/themes';

// which themes you what to enable (empty to enable all)
$nb-enabled-themes: (default, cosmic);
$nb-enabled-themes: (default, cosmic, corporate);

$nb-themes: nb-register-theme((
// app wise variables for each theme
sidebar-header-gap: 2rem,
sidebar-header-height: initial,
layout-content-width: 1400px,

font-main: IRANSans,
font-secondary: IRANSans,

switcher-background: #ebeff5,
switcher-background-percentage: 50%,
drops-icon-line-gadient: -webkit-linear-gradient(#01dbb5, #0bbb79),
), default, default);

$nb-themes: nb-register-theme((
// app wise variables for each theme
sidebar-header-gap: 2rem,
sidebar-header-height: initial,
layout-content-width: 1400px,

font-main: IRANSans,
font-secondary: IRANSans,

switcher-background: #4e41a5,
switcher-background-percentage: 14%,
drops-icon-line-gadient: -webkit-linear-gradient(#a258fe, #7958fa),
), cosmic, cosmic);

$nb-themes: nb-register-theme((
// app wise variables for each theme
sidebar-header-gap: 2rem,
sidebar-header-height: initial,
layout-content-width: 1400px,

font-main: IRANSans,
font-secondary: IRANSans,

switcher-background: #2b2d34,
switcher-background-percentage: 14%,
drops-icon-line-gadient: -webkit-linear-gradient(#e9e8eb, #a7a2be),
), corporate, corporate);

0 comments on commit e455b97

Please sign in to comment.