Skip to content
Snippets Groups Projects
text.component.ts 872 B
Newer Older
import { Component } from '@angular/core';
import { FormElementComponent } from '../canvas-element-component.directive';
rhenck's avatar
rhenck committed
  selector: 'app-text',
  template: `
rhenck's avatar
rhenck committed
      <div [style.width.px]="elementModel.width"
           [style.height.px]="elementModel.height"
           [style.background-color]="elementModel.backgroundColor"
           [style.color]="elementModel.fontColor"
           [style.font-family]="elementModel.font"
           [style.font-size.px]="elementModel.fontSize"
           [style.font-weight]="elementModel.bold ? 'bold' : ''"
           [style.font-style]="elementModel.italic ? 'italic' : ''"
           [style.text-decoration]="elementModel.underline ? 'underline' : ''"
           [style.white-space]="'pre-wrap'">
          {{$any(elementModel).text}}
export class TextComponent extends FormElementComponent { }