UNPKG

smart-webcomponents-angular

Version:

[![Price](https://img.shields.io/badge/price-COMMERCIAL-0098f7.svg)](https://jqwidgets.com/license/)

114 lines (113 loc) 10.2 kB
import { RadioButton } from './../index'; import { Animation, CheckMode, ClickMode } from './../index'; import { AfterViewInit, ElementRef, OnInit, OnChanges, OnDestroy, SimpleChanges, EventEmitter } from '@angular/core'; import { BaseElement } from './smart.element'; import { ControlValueAccessor } from '@angular/forms'; import * as i0 from "@angular/core"; export { Animation, CheckMode, ClickMode, ElementRenderMode } from './../index'; export { Smart } from './smart.element'; export { RadioButton } from './../index'; export declare class RadioButtonComponent extends BaseElement implements OnInit, AfterViewInit, OnDestroy, OnChanges, ControlValueAccessor { constructor(ref: ElementRef<RadioButton>); private eventHandlers; nativeElement: RadioButton; /** @description Creates the component on demand. * @param properties An optional object of properties, which will be added to the template binded ones. */ createComponent(properties?: {}): any; /** * @description * The registered callback function called when a change event occurs on the form elements. */ _onChange: (value: any) => void; /** * @description * The registered callback function called when a blur event occurs on the form elements. */ _onTouched: () => any; /** @description Sets or retrieves the current animation mode. When this property is set to 'none', all animations are disabled for the associated element. Use this property to enable, disable, or adjust the animation behavior as needed. */ get animation(): Animation | string; set animation(value: Animation | string); /** @description Sets or retrieves the current checked state of the control. This property allows you to specify whether the control is checked, unchecked, or—if supported—set to an indeterminate state. You can use it to update the visual state of elements like checkboxes or radio buttons, or to query their current status in your application logic. */ get checked(): boolean; set checked(value: boolean); /** @description Sets or retrieves the specific part of the element responsible for toggling its state (such as showing or hiding content). This attribute identifies which internal component or sub-element responds to toggle actions, enabling interactive behavior. */ get checkMode(): CheckMode | string; set checkMode(value: CheckMode | string); /** @description Specifies how the radio button responds to user click events, determining whether the button is selected, toggled, or triggers a specific action when clicked. */ get clickMode(): ClickMode | string; set clickMode(value: ClickMode | string); /** @description Controls whether the ratio button is displayed and functional. When enabled, users can interact with the ratio button; when disabled, the button is hidden or inactive. */ get disabled(): boolean; set disabled(value: boolean); /** @description Sets or retrieves the name of the group to which the widget belongs. This property allows you to organize multiple widgets into logical groups, enabling group-based behavior or styling. When setting this property, the widget is associated with the specified group; when getting, it returns the current group name assigned to the widget. */ get groupName(): string; set groupName(value: string); /** @description Gets or sets the HTML content contained within the widget. Setting this property updates the widget’s inner HTML structure, while getting it returns the current HTML markup inside the widget. Use this property to dynamically modify or retrieve the widget’s content. */ get innerHTML(): string; set innerHTML(value: string); /** @description Defines or retrieves the unlockKey property, which serves as the credential required to unlock access to the product. */ get unlockKey(): string; set unlockKey(value: string); /** @description Sets or retrieves the current language code (e.g., "en", "fr", "es") used by the component or application. This property works together with the messages property to determine which set of localized messages or translations should be displayed to the user. Adjusting the language value dynamically updates the displayed content based on the corresponding messages for the selected language. */ get locale(): string; set locale(value: string); /** @description Callback function associated with the localization module, typically invoked to handle events or updates related to language changes, text translation, or region-specific content within the application. */ get localizeFormatFunction(): any; set localizeFormatFunction(value: any); /** @description Defines an object that maps different password strength states to their corresponding descriptive string values. This allows you to customize the messages shown to users based on the evaluated strength of their password (e.g., "weak," "medium," "strong"). */ get messages(): any; set messages(value: any); /** @description Gets the current name of the widget or assigns a new name to the widget. The name serves as a unique identifier, which can be used for tracking, referencing, or interacting with the widget programmatically. */ get name(): string; set name(value: string); /** @description When the custom element is set to readonly, its value cannot be modified by user input or interaction. All form controls within the element will display their current values but will be non-editable, preventing users from changing, adding, or deleting content. However, the element may still support programmatic updates via JavaScript. */ get readonly(): boolean; set readonly(value: boolean); /** @description Specifies or retrieves a Boolean value that determines whether the element’s content is aligned to accommodate right-to-left (RTL) languages, such as Arabic or Hebrew. When set to true, the element’s layout and text flow are adjusted to support RTL locales and fonts. */ get rightToLeft(): boolean; set rightToLeft(value: boolean); /** @description Specifies the visual theme to be applied. The selected theme controls the overall appearance, including colors, fonts, and styling of the element. */ get theme(): string; set theme(value: string); /** @description When set to true, this property prevents the element from receiving keyboard focus, making it impossible for users to navigate to the element using the Tab key or other focus methods. */ get unfocusable(): boolean; set unfocusable(value: boolean); /** @description Sets a new value for the widget or retrieves its current value, depending on the context in which the method is called. This allows you to programmatically update the widget's content or access the value entered or selected by the user. */ get value(): string; set value(value: string); /** @description This event is triggered whenever the widget’s checked state changes, such as when a user selects (checks) or deselects (unchecks) the widget. It allows you to execute custom logic in response to the user interacting with the widget’s selection control. * @param event. The custom event. Custom event was created with: event.detail( value, oldValue, changeType) * value - A boolean value indicating the new state of the button ( checked or not ). * oldValue - A boolean value indicating the previous state of the button ( checked or not ). * changeType - A string flag indicating whether the change event was triggered via API or an event. */ onChange: EventEmitter<CustomEvent>; /** @description This event is triggered whenever the widget's checked state changes from unchecked to checked, indicating that the user has selected or activated the widget. This event is typically used to execute custom logic in response to the widget being checked, such as updating the UI, submitting data, or enabling related features. * @param event. The custom event. Custom event was created with: event.detail( changeType) * changeType - A string flag indicating whether the change event was triggered via API or an event. */ onCheckValue: EventEmitter<CustomEvent>; /** @description This event is triggered whenever the user deselects or unchecks the widget, indicating a change in its state from checked to unchecked. It allows developers to respond to the action of unchecking, such as updating the user interface or processing form data. * @param event. The custom event. Custom event was created with: event.detail( changeType) * changeType - A string flag indicating whether the change event was triggered via API or an event. */ onUncheckValue: EventEmitter<CustomEvent>; get isRendered(): boolean; ngOnInit(): void; ngAfterViewInit(): void; ngOnDestroy(): void; _initialChange: boolean; get ngValue(): any; set ngValue(value: any); writeValue(value: any): void; registerOnChange(fn: any): void; registerOnTouched(fn: any): void; ngOnChanges(changes: SimpleChanges): void; /** @description Add event listeners. */ private listen; /** @description Remove event listeners. */ private unlisten; static ɵfac: i0.ɵɵFactoryDeclaration<RadioButtonComponent, never>; static ɵdir: i0.ɵɵDirectiveDeclaration<RadioButtonComponent, "smart-radio-button, [smart-radio-button]", ["smart-radio-button"], { "animation": "animation"; "checked": "checked"; "checkMode": "checkMode"; "clickMode": "clickMode"; "disabled": "disabled"; "groupName": "groupName"; "innerHTML": "innerHTML"; "unlockKey": "unlockKey"; "locale": "locale"; "localizeFormatFunction": "localizeFormatFunction"; "messages": "messages"; "name": "name"; "readonly": "readonly"; "rightToLeft": "rightToLeft"; "theme": "theme"; "unfocusable": "unfocusable"; "value": "value"; }, { "onChange": "onChange"; "onCheckValue": "onCheckValue"; "onUncheckValue": "onUncheckValue"; }, never>; }