This file contains hidden or 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
| svg { | |
| width: inherit; | |
| height: inherit; | |
| fill: inherit; | |
| background: inherit; | |
| background-color: inherit; | |
| } | |
| img { | |
| width: inherit; |
This file contains hidden or 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
| import { Component, Input } from '@angular/core'; | |
| @Component({ | |
| selector: 'ces-svg', | |
| template: ` | |
| <img src="/assets/images/svgs/{{ type }}.svg" [alt]="type + ' icon'" [title]="title"> | |
| `, | |
| styleUrls: [ | |
| './svg.component.scss' | |
| ] |
This file contains hidden or 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
| import { Directive, HostListener } from '@angular/core'; | |
| import { DevicesService } from './devices.service'; | |
| @Directive({ | |
| selector: '[cesDeviceScreenSize]' | |
| }) | |
| export class DeviceScreenSizeDirective { | |
| constructor( | |
| private devices: DevicesService | |
| ) { } |
This file contains hidden or 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
| import { Directive, HostListener } from '@angular/core'; | |
| import { DevicesService } from './devices.service'; | |
| @Directive({ | |
| selector: '[cesDeviceScreenSize]' | |
| }) | |
| export class DeviceScreenSizeDirective { | |
| constructor( | |
| private devices: DevicesService | |
| ) { } |
This file contains hidden or 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
| import { Injectable, Input } from '@angular/core'; | |
| import { Subject, Observable } from 'rxjs'; | |
| import { ScreenSize, DetectType } from './devices'; | |
| @Injectable({ | |
| providedIn: 'root' | |
| }) | |
| export class DevicesService { | |
| screenSize: Subject<any> = new Subject(); | |
| @Input() detectSize: DetectType; |
This file contains hidden or 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
| import { Directive, HostListener, ElementRef, Renderer2, Output, EventEmitter, Input } from '@angular/core'; | |
| import { Observable } from 'rxjs'; | |
| import { EditUpdate } from '../forms'; | |
| @Directive({ | |
| selector: '[cesClickEdit]' | |
| }) | |
| export class ClickEditDirective { | |
| value: string; |
This file contains hidden or 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
| import { Injectable, ErrorHandler } from '@angular/core'; | |
| import { HttpClient, HttpHeaders, HttpErrorResponse } from '@angular/common/http'; | |
| import { Observable, throwError } from 'rxjs'; | |
| import { catchError} from 'rxjs/operators'; | |
| @Injectable({ | |
| providedIn: 'root' | |
| }) | |
| export class SvgsApiService implements ErrorHandler { |
This file contains hidden or 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
| .log { | |
| .header { | |
| display: flex; | |
| justify-content: space-between; | |
| } | |
| .body { | |
| position: absolute; | |
| height: 50vh; | |
| width: 100%; |