license import { Pipe , PipeTransform } from '@angular/core' ; import { ToggleOption } from 'src/app/models/toggle-option.model' ; import { AvailableTheme } from './available-theme.model' ; @ Pipe ( { name : 'availableThemesToOptions' , } ) export class AvailableThemesToOptionsPipe implements PipeTransform { transform ( value ) { return value . map ( ( t ) => ( { id : t . theme , text : 'ぁあ' , style : { color : t . option . fontColor , 'background-color' : t . option . backgroundColor , } , } ) ) ; } }