|
| 1 | +import React from "react"; |
| 2 | +import { AccordionProperties } from "./../index"; |
| 3 | +import { Animation, AccordionExpandMode } from './../index'; |
| 4 | +export { AccordionProperties } from "./../index"; |
| 5 | +export { Animation, AccordionExpandMode } from './../index'; |
| 6 | +export { AccordionItem } from './accordionitem'; |
| 7 | +export { AccordionItemProperties } from "./../index"; |
| 8 | +export declare const Smart: any; |
| 9 | +export interface AccordionProps extends AccordionProperties { |
| 10 | + className?: string; |
| 11 | + style?: React.CSSProperties; |
| 12 | + onCollapse?: ((event?: Event) => void) | undefined; |
| 13 | + onCollapsing?: ((event?: Event) => void) | undefined; |
| 14 | + onDragEnd?: ((event?: Event) => void) | undefined; |
| 15 | + onDragStart?: ((event?: Event) => void) | undefined; |
| 16 | + onExpand?: ((event?: Event) => void) | undefined; |
| 17 | + onExpanding?: ((event?: Event) => void) | undefined; |
| 18 | +} |
| 19 | +/** |
| 20 | + Accordion organizes content within collapsable items. |
| 21 | +*/ |
| 22 | +export declare class Accordion extends React.Component<React.HTMLProps<Element> & AccordionProps, any> { |
| 23 | + private _id; |
| 24 | + private nativeElement; |
| 25 | + get id(): string; |
| 26 | + /** Sets or gets the animation mode. Animation is disabled when the property is set to 'none' |
| 27 | + * Property type: Animation |
| 28 | + */ |
| 29 | + get animation(): Animation; |
| 30 | + set animation(value: Animation); |
| 31 | + /** Enables or disables the accordion. Disabled elements can not be interacted with. |
| 32 | + * Property type: boolean |
| 33 | + */ |
| 34 | + get disabled(): boolean; |
| 35 | + set disabled(value: boolean); |
| 36 | + /** Sets or gets the expanded item indexes. Using this property items can be expanded by passing in their indexes. The number of expanded items is limited by the expandMode. |
| 37 | + * Property type: number[] |
| 38 | + */ |
| 39 | + get expandedIndexes(): number[]; |
| 40 | + set expandedIndexes(value: number[]); |
| 41 | + /** Sets or gets the expand mode. Expand mode determines how the items will expand or collapse. |
| 42 | + * Property type: AccordionExpandMode |
| 43 | + */ |
| 44 | + get expandMode(): AccordionExpandMode; |
| 45 | + set expandMode(value: AccordionExpandMode); |
| 46 | + /** Sets or gets the language. Used in conjunction with the property messages. |
| 47 | + * Property type: string |
| 48 | + */ |
| 49 | + get locale(): string; |
| 50 | + set locale(value: string); |
| 51 | + /** Callback used to customize the format of the messages that are returned from the Localization Module. |
| 52 | + * Property type: any |
| 53 | + */ |
| 54 | + get localizeFormatFunction(): any; |
| 55 | + set localizeFormatFunction(value: any); |
| 56 | + /** Sets or gets an object specifying strings used in the widget that can be localized. Used in conjunction with the property locale. |
| 57 | + * Property type: any |
| 58 | + */ |
| 59 | + get messages(): any; |
| 60 | + set messages(value: any); |
| 61 | + /** Determines if the element is readonly or not. If the element true, users cannot interact with it. |
| 62 | + * Property type: boolean |
| 63 | + */ |
| 64 | + get readonly(): boolean; |
| 65 | + set readonly(value: boolean); |
| 66 | + /** Enables or disables accordion reordering. |
| 67 | + * Property type: boolean |
| 68 | + */ |
| 69 | + get reorder(): boolean; |
| 70 | + set reorder(value: boolean); |
| 71 | + /** Sets or gets the value indicating whether the element is aligned to support locales using right-to-left fonts. |
| 72 | + * Property type: boolean |
| 73 | + */ |
| 74 | + get rightToLeft(): boolean; |
| 75 | + set rightToLeft(value: boolean); |
| 76 | + /** Determines the theme. Theme defines the look of the element |
| 77 | + * Property type: string |
| 78 | + */ |
| 79 | + get theme(): string; |
| 80 | + set theme(value: string); |
| 81 | + /** Determines whether the element can be focused or not. |
| 82 | + * Property type: boolean |
| 83 | + */ |
| 84 | + get unfocusable(): boolean; |
| 85 | + set unfocusable(value: boolean); |
| 86 | + get properties(): string[]; |
| 87 | + /** This event is triggered when an item is collapsed. |
| 88 | + * @param event. The custom event. Custom event was created with: event.detail( content, index, label) |
| 89 | + * content - The content of the item. |
| 90 | + * index - The index of the item. |
| 91 | + * label - The label of the item |
| 92 | + */ |
| 93 | + onCollapse?: ((event?: Event) => void) | undefined; |
| 94 | + /** This event is triggered when an item is going to be collapsed. |
| 95 | + * @param event. The custom event. Custom event was created with: event.detail( content, index, label) |
| 96 | + * content - The content of the item. |
| 97 | + * index - The index of the item. |
| 98 | + * label - The label of the item |
| 99 | + */ |
| 100 | + onCollapsing?: ((event?: Event) => void) | undefined; |
| 101 | + /** This event is triggered when a reordering operation is completed. |
| 102 | + * @param event. The custom event. Custom event was created with: event.detail( position, target, content, index, label) |
| 103 | + * position - The current top and left position of the item that was dragged. |
| 104 | + * target - The item that was dragged. |
| 105 | + * content - The content of the item. |
| 106 | + * index - The index of the item. |
| 107 | + * label - The label of the item. |
| 108 | + */ |
| 109 | + onDragEnd?: ((event?: Event) => void) | undefined; |
| 110 | + /** This event is triggered when a reordering operation is started. |
| 111 | + * @param event. The custom event. Custom event was created with: event.detail( position, target, content, index, label) |
| 112 | + * position - The current top and left position of the item that is about to be dragged. |
| 113 | + * target - The item that is about to be dragged. |
| 114 | + * content - The content of the item. |
| 115 | + * index - The index of the item. |
| 116 | + * label - The label of the item. |
| 117 | + */ |
| 118 | + onDragStart?: ((event?: Event) => void) | undefined; |
| 119 | + /** This event is triggered when an item is expanded. |
| 120 | + * @param event. The custom event. Custom event was created with: event.detail( position, target, content, index, label) |
| 121 | + * position - The current top and left position of the item. |
| 122 | + * target - The item that was dragged. |
| 123 | + * content - The content of the item. |
| 124 | + * index - The index of the item. |
| 125 | + * label - The label of the item. |
| 126 | + */ |
| 127 | + onExpand?: ((event?: Event) => void) | undefined; |
| 128 | + /** This event is triggered when an item is going to be expanded. |
| 129 | + * @param event. The custom event. Custom event was created with: event.detail( content, index, label) |
| 130 | + * content - The content of the item. |
| 131 | + * index - The index of the item. |
| 132 | + * label - The label of the item |
| 133 | + */ |
| 134 | + onExpanding?: ((event?: Event) => void) | undefined; |
| 135 | + /** This event occurs, when the React component is created. |
| 136 | + * @param event. The custom event. */ |
| 137 | + onCreate?: ((event?: Event) => void) | undefined; |
| 138 | + /** This event occurs, when the React component is completely rendered. |
| 139 | + * @param event. The custom event. */ |
| 140 | + onReady?: ((event?: Event) => void) | undefined; |
| 141 | + get events(): string[]; |
| 142 | + /** Collapses an item at a specified index. |
| 143 | + * @param {number} position. The index of the collapsed item. |
| 144 | + */ |
| 145 | + collapse(position: number): void; |
| 146 | + /** Expands an item at a specified index. |
| 147 | + * @param {number} position. The index of the expanded item. |
| 148 | + */ |
| 149 | + expand(position: number): void; |
| 150 | + /** Inserts a new item at a specified index. |
| 151 | + * @param {number} index. The index where the item must be inserted. |
| 152 | + * @param {any} item. An object containing the values for the properties of the new item to be inserted. |
| 153 | + */ |
| 154 | + insert(index: number, item: any): void; |
| 155 | + /** Removes an item at a specified index. |
| 156 | + * @param {number} position. The index of the item to be removed. |
| 157 | + */ |
| 158 | + removeAt(position: number): void; |
| 159 | + /** Updates an item from the element. |
| 160 | + * @param {number} index. The index of the item to be updated. |
| 161 | + * @param {any} settings. An object containing the values for the properties of the item that will be updated. |
| 162 | + */ |
| 163 | + update(index: number, settings: any): void; |
| 164 | + constructor(props: any); |
| 165 | + componentDidRender(initialize: boolean): void; |
| 166 | + componentDidMount(): void; |
| 167 | + componentDidUpdate(): void; |
| 168 | + componentWillUnmount(): void; |
| 169 | + render(): React.DOMElement<React.DOMAttributes<Element>, Element>; |
| 170 | +} |
| 171 | +export default Accordion; |
0 commit comments