import { EmbedInputViewStyle, embedInputViewStyleFromJson, embedInputViewStyleToJson, } from './EmbedInputViewStyle'; export class EmbedInputStyle { base?: EmbedInputViewStyle; error?: EmbedInputViewStyle; focus?: EmbedInputViewStyle; constructor( base?: EmbedInputViewStyle, error?: EmbedInputViewStyle, focus?: EmbedInputViewStyle ) { this.base = base; this.error = error; this.focus = focus; } } export function embedInputStyleFromJson(json: { [key: string]: any; }): EmbedInputStyle { return new EmbedInputStyle( json.base ? embedInputViewStyleFromJson(json.base) : undefined, json.error ? embedInputViewStyleFromJson(json.error) : undefined, json.focus ? embedInputViewStyleFromJson(json.focus) : undefined ); } export function embedInputStyleToJson(embedInputStyle: EmbedInputStyle): { [key: string]: any; } { return { base: embedInputStyle.base ? embedInputViewStyleToJson(embedInputStyle.base) : undefined, error: embedInputStyle.error ? embedInputViewStyleToJson(embedInputStyle.error) : undefined, focus: embedInputStyle.focus ? embedInputViewStyleToJson(embedInputStyle.focus) : undefined, }; }