-
-
Notifications
You must be signed in to change notification settings - Fork 32
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat(daffio): update named views to pass in options for sidebar heade…
…r, content, and footer, and update usages in sidebars
- Loading branch information
Showing
32 changed files
with
237 additions
and
84 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
10 changes: 7 additions & 3 deletions
10
apps/daffio/src/app/core/sidebar/components/docs-sidebar/docs-sidebar.module.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,23 +1,27 @@ | ||
import { CommonModule } from '@angular/common'; | ||
import { NgModule } from '@angular/core'; | ||
import { RouterModule } from '@angular/router'; | ||
import { FontAwesomeModule } from '@fortawesome/angular-fontawesome'; | ||
|
||
import { DaffButtonModule } from '@daffodil/design/button'; | ||
import { DaffListModule } from '@daffodil/design/list'; | ||
|
||
import { DaffioDocsSidebarComponent } from './docs-sidebar.component'; | ||
import { DaffioDocsSidebarContentComponent } from './docs-sidebar-content/docs-sidebar-content.component'; | ||
|
||
@NgModule({ | ||
imports: [ | ||
CommonModule, | ||
RouterModule, | ||
|
||
FontAwesomeModule, | ||
DaffListModule, | ||
DaffButtonModule, | ||
], | ||
declarations: [ | ||
DaffioDocsSidebarComponent, | ||
DaffioDocsSidebarContentComponent, | ||
], | ||
exports: [ | ||
DaffioDocsSidebarComponent, | ||
DaffioDocsSidebarContentComponent, | ||
], | ||
}) | ||
export class DaffioDocsSidebarComponentModule { } |
File renamed without changes.
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
1 change: 1 addition & 0 deletions
1
...onents/marketing-sidebar/marketing-sidebar-footer/marketing-sidebar-footer.component.html
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
<a href="https://github.com/graycoreio/daffodil" rel="noopener noreferrer" target="_blank" class="daffio-marketing-sidebar-footer">Get Started</a> |
10 changes: 10 additions & 0 deletions
10
...onents/marketing-sidebar/marketing-sidebar-footer/marketing-sidebar-footer.component.scss
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
@use 'utilities' as daff; | ||
|
||
.daffio-marketing-sidebar-footer { | ||
@include daff.clickable(); | ||
display: block; | ||
font-weight: 500; | ||
padding: 16px; | ||
text-align: center; | ||
text-decoration: none; | ||
} |
13 changes: 13 additions & 0 deletions
13
...mponents/marketing-sidebar/marketing-sidebar-footer/marketing-sidebar-footer.component.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
import { | ||
ChangeDetectionStrategy, | ||
Component, | ||
} from '@angular/core'; | ||
|
||
@Component({ | ||
selector: 'daffio-marketing-sidebar-footer', | ||
templateUrl: './marketing-sidebar-footer.component.html', | ||
styleUrls: ['./marketing-sidebar-footer.component.scss'], | ||
changeDetection: ChangeDetectionStrategy.OnPush, | ||
}) | ||
export class DaffioMarketingSidebarFooterComponent { | ||
} |
3 changes: 3 additions & 0 deletions
3
...onents/marketing-sidebar/marketing-sidebar-header/marketing-sidebar-header.component.html
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
<button daff-icon-button color="theme-contrast" daffSidebarHeaderAction (click)="close()"> | ||
<fa-icon [icon]="faTimes"></fa-icon> | ||
</button> |
24 changes: 24 additions & 0 deletions
24
...mponents/marketing-sidebar/marketing-sidebar-header/marketing-sidebar-header.component.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
import { | ||
ChangeDetectionStrategy, | ||
Component, | ||
} from '@angular/core'; | ||
import { faTimes } from '@fortawesome/free-solid-svg-icons'; | ||
import { Store } from '@ngrx/store'; | ||
|
||
import { CloseSidebar } from '../../../actions/sidebar.actions'; | ||
import * as fromDaffioSidebar from '../../../reducers/index'; | ||
|
||
@Component({ | ||
selector: 'daffio-marketing-sidebar-header', | ||
templateUrl: './marketing-sidebar-header.component.html', | ||
changeDetection: ChangeDetectionStrategy.OnPush, | ||
}) | ||
export class DaffioMarketingSidebarHeaderComponent { | ||
faTimes = faTimes; | ||
|
||
constructor(private store: Store<fromDaffioSidebar.State>){} | ||
|
||
close() { | ||
this.store.dispatch(new CloseSidebar()); | ||
} | ||
} |
17 changes: 17 additions & 0 deletions
17
apps/daffio/src/app/core/sidebar/components/marketing-sidebar/marketing-sidebar-theme.scss
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
@use 'sass:map'; | ||
@use 'theme' as daff-theme; | ||
|
||
@mixin daffio-marketing-sidebar-theme($theme) { | ||
$gray: daff-theme.daff-map-deep-get($theme, 'core.gray'); | ||
$base: daff-theme.daff-map-deep-get($theme, 'core.base'); | ||
$base-contrast: daff-theme.daff-map-deep-get($theme, 'core.base-contrast'); | ||
$primary: map.get($theme, primary); | ||
|
||
.daffio-marketing-sidebar-footer { | ||
background: daff-theme.daff-illuminate($base, $gray, 2); | ||
|
||
&:hover { | ||
background: daff-theme.daff-illuminate($base, $gray, 3); | ||
} | ||
} | ||
} |
18 changes: 15 additions & 3 deletions
18
apps/daffio/src/app/core/sidebar/components/marketing-sidebar/marketing-sidebar.module.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,23 +1,35 @@ | ||
import { CommonModule } from '@angular/common'; | ||
import { NgModule } from '@angular/core'; | ||
import { RouterModule } from '@angular/router'; | ||
import { FontAwesomeModule } from '@fortawesome/angular-fontawesome'; | ||
|
||
import { DaffButtonModule } from '@daffodil/design/button'; | ||
import { DaffListModule } from '@daffodil/design/list'; | ||
import { DaffSidebarModule } from '@daffodil/design/sidebar'; | ||
|
||
import { DaffioMarketingSidebarComponent } from './marketing-sidebar.component'; | ||
import { DaffioMarketingSidebarContentComponent } from './marketing-sidebar-content/marketing-sidebar-content.component'; | ||
import { DaffioMarketingSidebarFooterComponent } from './marketing-sidebar-footer/marketing-sidebar-footer.component'; | ||
import { DaffioMarketingSidebarHeaderComponent } from './marketing-sidebar-header/marketing-sidebar-header.component'; | ||
|
||
@NgModule({ | ||
imports: [ | ||
CommonModule, | ||
RouterModule, | ||
|
||
FontAwesomeModule, | ||
DaffListModule, | ||
DaffButtonModule, | ||
DaffSidebarModule, | ||
], | ||
declarations: [ | ||
DaffioMarketingSidebarComponent, | ||
DaffioMarketingSidebarHeaderComponent, | ||
DaffioMarketingSidebarContentComponent, | ||
DaffioMarketingSidebarFooterComponent, | ||
], | ||
exports: [ | ||
DaffioMarketingSidebarComponent, | ||
DaffioMarketingSidebarHeaderComponent, | ||
DaffioMarketingSidebarContentComponent, | ||
DaffioMarketingSidebarFooterComponent, | ||
], | ||
}) | ||
export class DaffioMarketingSidebarComponentModule { } |
12 changes: 5 additions & 7 deletions
12
apps/daffio/src/app/core/sidebar/containers/sidebar-viewport/sidebar-viewport.component.html
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
14 changes: 5 additions & 9 deletions
14
apps/daffio/src/app/core/sidebar/containers/sidebar-viewport/sidebar-viewport.component.scss
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,9 +1,5 @@ | ||
.daffio-sidebar-viewport { | ||
&__get-started { | ||
display: block; | ||
font-weight: 500; | ||
padding: 16px; | ||
text-align: center; | ||
text-decoration: none; | ||
} | ||
} | ||
.daffio-sidebar { | ||
max-width: 290px; | ||
width: 100%; | ||
border-right: 1px solid rgb(var(--daff-theme-contrast-rgb), 0.1); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.