UNPKG

@ng-formworks/cssframework

Version:

Angular ng-formworks - JSON Schema Form builder cssframework

151 lines (144 loc) 5.97 kB
import * as i0 from '@angular/core'; import { InjectionToken, OnInit, OnChanges, OnDestroy, ChangeDetectorRef } from '@angular/core'; import * as i2 from '@ng-formworks/core'; import { JsonSchemaFormService, FrameworkLibraryService, Framework } from '@ng-formworks/core'; import { Observable, BehaviorSubject, Subscription } from 'rxjs'; import * as i3 from '@angular/common'; declare const CSS_FRAMEWORK_CFG: InjectionToken<css_fw.frameworkcfg>; declare namespace css_fw { type themeKV = { name: string; text: string; }; class csscategories { fieldHtmlClass?: string | string[]; labelHtmlClass?: string | string[]; htmlClass?: string | string[]; itemLabelHtmlClass?: string | string[]; activeClass?: string | string[]; [key: `widget_${string}`]: string | string[]; } type widgetstyles = { '$ref'?: csscategories; 'alt-date'?: csscategories; 'alt-datetime'?: csscategories; __themes__?: themeKV[]; __array_item_nonref__: csscategories; __form_group__: csscategories; __control_label__: csscategories; __active__: csscategories; __required_asterisk__: string; __array__: csscategories; '__remove_item__': string; __help_block__: string; __field_addon_left__: string; __field_addon_right__: string; __screen_reader__: string; array: csscategories; authfieldset?: csscategories; advancedfieldset?: csscategories; button?: csscategories; checkbox?: csscategories; checkboxes?: csscategories; checkboxbuttons?: csscategories; 'checkboxes-inline'?: csscategories; date?: csscategories; 'datetime-local'?: csscategories; fieldset?: csscategories; integer?: csscategories; number?: csscategories; optionfieldset?: csscategories; password?: csscategories; radiobuttons?: csscategories; radio?: csscategories; radios?: csscategories; "radios-inline"?: csscategories; 'range'?: csscategories; section?: csscategories; selectfieldset?: csscategories; select?: csscategories; submit?: csscategories; text?: csscategories; tabs?: csscategories; tabarray?: csscategories; 'one-of'?: csscategories; textarea?: csscategories; default: csscategories; }; type frameworkcfg = { name: string; text: string; stylesheets: string[]; scripts?: string[]; widgetstyles: widgetstyles; widgets?: any; }; } declare class CssframeworkService { frameworkTheme$: Observable<string>; activeRequestedTheme: string; frameworkThemeSubject: BehaviorSubject<string>; constructor(); requestThemeChange(themeName: string): void; getActiveRequestedTheme(): string; static ɵfac: i0.ɵɵFactoryDeclaration<CssframeworkService, never>; static ɵprov: i0.ɵɵInjectableDeclaration<CssframeworkService>; } declare class CssFrameworkComponent implements OnInit, OnChanges, OnDestroy { cdr: ChangeDetectorRef; jsf: JsonSchemaFormService; jsfFLService: FrameworkLibraryService; cssFWService: CssframeworkService; frameworkInitialized: boolean; widgetOptions: any; widgetLayoutNode: any; options: any; formControl: any; debugOutput: any; debug: any; parentArray: any; isOrderable: boolean; dynamicTitle: string; isDynamicTitle: boolean; readonly layoutNode: i0.InputSignal<any>; readonly layoutIndex: i0.InputSignal<number[]>; readonly dataIndex: i0.InputSignal<number[]>; readonly widgetStyles: i0.ModelSignal<css_fw.widgetstyles>; applyCssClasses(type: any, widgetOptions: any, styleOptions: any): void; flattenWidgetStyles(wstyles: css_fw.widgetstyles): any; defaultStyling: css_fw.widgetstyles; theme: string; frameworkThemeSubs: Subscription; constructor(); ngOnDestroy(): void; get showRemoveButton(): boolean; ngOnInit(): void; ngOnChanges(changes: any): void; initializeFramework(): void; updateHelpBlock(status: any): void; setTitle(): string; updateTitle(): void; removeItem(): void; static ɵfac: i0.ɵɵFactoryDeclaration<CssFrameworkComponent, never>; static ɵcmp: i0.ɵɵComponentDeclaration<CssFrameworkComponent, "css-framework", never, { "layoutNode": { "alias": "layoutNode"; "required": false; "isSignal": true; }; "layoutIndex": { "alias": "layoutIndex"; "required": false; "isSignal": true; }; "dataIndex": { "alias": "dataIndex"; "required": false; "isSignal": true; }; "widgetStyles": { "alias": "widgetStyles"; "required": false; "isSignal": true; }; }, { "widgetStyles": "widgetStylesChange"; }, never, never, false, never>; } declare class CssFrameworkModule { static ɵfac: i0.ɵɵFactoryDeclaration<CssFrameworkModule, never>; static ɵmod: i0.ɵɵNgModuleDeclaration<CssFrameworkModule, [typeof CssFrameworkComponent], [typeof i2.JsonSchemaFormModule, typeof i3.CommonModule, typeof i2.WidgetLibraryModule], [typeof CssFrameworkComponent]>; static ɵinj: i0.ɵɵInjectorDeclaration<CssFrameworkModule>; } declare class CssFramework extends Framework { cssFWService: CssframeworkService; name: string; framework: any; config: css_fw.frameworkcfg; constructor(cfg: css_fw.frameworkcfg); getActiveTheme(): css_fw.themeKV; requestThemeChange(name: string): void; registerTheme(newTheme: css_fw.themeKV, overwrite?: boolean): boolean; unregisterTheme(name: string): boolean; getConfig(): css_fw.frameworkcfg; static ɵfac: i0.ɵɵFactoryDeclaration<CssFramework, never>; static ɵprov: i0.ɵɵInjectableDeclaration<CssFramework>; } export { CSS_FRAMEWORK_CFG, CssFramework, CssFrameworkComponent, CssFrameworkModule, CssframeworkService, css_fw };