Skip to content
Snippets Groups Projects
toolbar.component.ts 520 B
Newer Older
  • Learn to ignore specific revisions
  • import { Component } from '@angular/core';
    
    import { UnitService } from '../../services/unit.service';
    
      selector: 'aspect-toolbar',
    
      templateUrl: './toolbar.component.html',
      styles: [
        'mat-toolbar {background-color: #696969}',
        'mat-toolbar button {margin: 15px}'
      ]
    })
    export class ToolbarComponent {
    
      constructor(private unitService: UnitService) { }
    
    
      save(): void {
        this.unitService.saveUnit();
      }
    
      async load(): Promise<void> {
    
        await this.unitService.loadUnitFromFile();