@doku-dev/doku-fragment
Version:
A new Angular UI library that moving away from Bootstrap and built from scratch.
59 lines (58 loc) • 2.26 kB
TypeScript
import { NgClass } from '@angular/common';
import { AfterViewInit, ApplicationRef, ChangeDetectorRef, OnChanges, OnDestroy, Renderer2 } from '@angular/core';
import { DokuRadioCustomAppearanceContext } from './context';
import { DokuRadioGroup } from './radio-group.component';
import * as i0 from "@angular/core";
export declare class DokuRadio implements AfterViewInit, OnChanges, OnDestroy {
private cdr;
private appRef;
private renderer;
private radioGroup?;
/**
* Analog to HTML 'name' attribute used to group radios for unique selection.
* @default 'd-radio-name-[nextId]''
*/
name: string;
/**
* The value of this radio button.
* @default ''
*/
value: string;
/**
* Whether this radio button is checked.
* @default false
*/
checked: boolean;
/**
* Whether the radio button is disabled.
* @default false
*/
disabled: boolean;
/**
* The size of the radio button indicator.
* @default 'medium'
*/
size: 'medium' | 'small';
private container?;
private indicator?;
private label?;
private customAppearance?;
private builtInAppearance?;
protected customAppearanceContext: DokuRadioCustomAppearanceContext;
protected hasIndicator: boolean;
protected checkedChangeCallback?: (value: string, checked: boolean) => void;
private destroy$;
constructor(cdr: ChangeDetectorRef, appRef: ApplicationRef, renderer: Renderer2, radioGroup?: DokuRadioGroup | undefined);
protected get classes(): NgClass['ngClass'];
protected get hasCustomAppearance(): boolean;
ngAfterViewInit(): void;
ngOnChanges(): void;
ngOnDestroy(): void;
protected onCheckedChange(ev: Event): void;
private appendIndicator;
private createAndAppendCustomAppearance;
private updateCustomAppearanceContext;
private watchGroupChanges;
static ɵfac: i0.ɵɵFactoryDeclaration<DokuRadio, [null, null, null, { optional: true; host: true; }]>;
static ɵcmp: i0.ɵɵComponentDeclaration<DokuRadio, "doku-radio", ["dokuRadio"], { "name": "name"; "value": "value"; "checked": "checked"; "disabled": "disabled"; "size": "size"; }, {}, ["customAppearance", "builtInAppearance"], ["*"], true>;
}