@skhemata/skhemata-form
Version:
Skhemata Form Web Component. This web component can be used as base web component when working with forms and inputs.
74 lines (73 loc) • 2.7 kB
TypeScript
import { CSSResult } from '@skhemata/skhemata-base';
import { SkhemataFormInput } from './SkhemataFormInput';
import { SkhemataFormTextbox } from './SkhemataFormTextbox';
import { SkhemataFormTextarea } from './SkhemataFormTextarea';
import { SkhemataFormDropdown } from './SkhemataFormDropdown';
import { SkhemataFormDropzone } from './SkhemataFormDropzone';
import { SkhemataFormButton } from './SkhemataFormButton';
import { SkhemataFormQuill } from './SkhemataFormQuill';
import { SkhemataFormCheckbox } from './SkhemataFormCheckbox';
import { SkhemataFormToggle } from './SkhemataFormToggle';
import { SkhemataFormDatePicker } from './SkhemataFormDatePicker';
/**
* Repeater component that repeats inputs passed in.
*/
export declare class SkhemataFormRepeat extends SkhemataFormInput {
rowName: string;
addRowButtonText: string;
removeRowButtonText: string;
rowLimit: number;
repeatedFields: any[];
type: string;
fieldNodes: any[];
rowData: any[];
allowedComponents: {
textbox: string;
textarea: string;
dropdown: string;
dropzone: string;
button: string;
quill: string;
checkbox: string;
toggle: string;
datepicker: string;
};
static get scopedElements(): {
'skhemata-form-textbox': typeof SkhemataFormTextbox;
'skhemata-form-textarea': typeof SkhemataFormTextarea;
'skhemata-form-dropdown': typeof SkhemataFormDropdown;
'skhemata-form-dropzone': typeof SkhemataFormDropzone;
'skhemata-form-button': typeof SkhemataFormButton;
'skhemata-form-quill': typeof SkhemataFormQuill;
'skhemata-form-checkbox': typeof SkhemataFormCheckbox;
'skhemata-form-toggle': typeof SkhemataFormToggle;
'skhemata-form-date-picker': typeof SkhemataFormDatePicker;
};
constructor();
firstUpdated(): Promise<void>;
/**
* Appends a new row of inputs to the end of the component
*
*/
addRow(): void;
/**
* Removes row based on the index of the row
*/
removeRow(event: any): void;
static get styles(): CSSResult[];
/**
* Renders component based on repeatedFields object
* @param name
* @param attributes
* @param value
* @param content content that is inserted to <slot></slot>
* @returns HtmlTemplate
*/
renderComponent(name: String, attributes: Object, value?: any, content?: String): import("lit-html").TemplateResult<1>;
/**
* Life cycle method that triggers whenever updated
* if there are new rows added, trigger add row event
*/
updated(): void;
render(): import("lit-html").TemplateResult<1>;
}