Skip to content

Commit

Permalink
feat: design toolset model
Browse files Browse the repository at this point in the history
  • Loading branch information
phodal committed Mar 26, 2020
1 parent 41429f7 commit 868db58
Show file tree
Hide file tree
Showing 3 changed files with 18 additions and 2 deletions.
9 changes: 8 additions & 1 deletion src/app/shared/toolset/toolset.component.html
Original file line number Diff line number Diff line change
@@ -1 +1,8 @@
<p>toolset works!</p>
<div *ngIf="option" [ngSwitch]="option.type">
<div *ngSwitchCase>

</div>
<div *ngSwitchDefault>
it works
</div>
</div>
5 changes: 4 additions & 1 deletion src/app/shared/toolset/toolset.component.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { Component, OnInit } from '@angular/core';
import { Component, Input, OnInit } from '@angular/core';

@Component({
selector: 'app-toolset',
Expand All @@ -7,6 +7,9 @@ import { Component, OnInit } from '@angular/core';
})
export class ToolsetComponent implements OnInit {

@Input()
option: ToolsetOption;

constructor() { }

ngOnInit(): void {
Expand Down
6 changes: 6 additions & 0 deletions src/app/shared/toolset/toolset.model.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
interface ToolsetOption {
id: string;
type: string; // slider
offsetHeight: string;
height: string;
}

0 comments on commit 868db58

Please sign in to comment.