| 20 | 20 | pagination(method: 'getCurrentPageNum'): number; |
| 21 | 21 | pagination(method: string, options?: any): JQuery; |
| 22 | 22 | pagination(options?: any): JQuery; |
| 23 | | - transition(options?: any, complete?: function): JQuery; |
| 24 | | - autocomplete(options?: any): JQuery; |
| 25 | | - autocomplete(method: string, options?: any): JQuery; |
| 26 | | - slider(options?: any): JQuery; |
| 27 | | - slider(method: string, func: string, options?: any): JQuery; |
| 28 | | - cropper(options?: any): JQuery; |
| 29 | 23 | izoomify(options?: any): JQuery; |
| 30 | | - |
| 31 | | - //#region select2 |
| 32 | | - |
| 33 | | - /** |
| 34 | | - * Initializes or modifies a select2 instance with provided options |
| 35 | | - * |
| 36 | | - * @param options - Configuration options for the select2 instance |
| 37 | | - * @returns The jQuery object for chaining |
| 38 | | - */ |
| 39 | | - select2(options?: Select2Options): JQuery; |
| 40 | | - |
| 41 | | - /** |
| 42 | | - * Retrieves data currently selected in the select2 instance |
| 43 | | - * |
| 44 | | - * @param field - A string specifying the 'data' method |
| 45 | | - * @returns An array of selected items |
| 46 | | - */ |
| 47 | | - select2(field: 'data'): any[]; |
| 48 | | - |
| 49 | | - /** |
| 50 | | - * Calls the specified select2 method |
| 51 | | - * |
| 52 | | - * @param method - The name of the select2 method to invoke |
| 53 | | - * @returns The jQuery object for chaining |
| 54 | | - */ |
| 55 | | - select2(method: 'open' | 'close' | 'destroy' | 'focus' | 'val', value?: any): JQuery; |
| 56 | | - |
| 57 | | - //#endregion |
| 58 | | - |
| 59 | | - //#region sortable |
| 60 | | - |
| 61 | | - /** |
| 62 | | - * Initializes or updates a sortable instance with the provided options |
| 63 | | - * |
| 64 | | - * @param options - Configuration options for the sortable instance |
| 65 | | - * @returns The jQuery object for chaining |
| 66 | | - */ |
| 67 | | - sortable(options?: SortableOptions): JQuery; |
| 68 | | - |
| 69 | | - /** |
| 70 | | - * Calls a sortable method to perform actions on the instance |
| 71 | | - * |
| 72 | | - * @param method - The name of the sortable method to invoke |
| 73 | | - * @returns The jQuery object for chaining |
| 74 | | - */ |
| 75 | | - sortable(method: 'destroy' | 'disable' | 'enable' | 'refresh' | 'toArray'): JQuery; |
| 76 | | - |
| 77 | | - /** |
| 78 | | - * Retrieves the sortable's instance object. If the element does not have an associated instance, undefined is returned. |
| 79 | | - * |
| 80 | | - * @returns The instance of the sortable object |
| 81 | | - */ |
| 82 | | - sortable(method: 'instance'): object; |
| 83 | | - |
| 84 | | - /** |
| 85 | | - * Retrieves the current option value for the specified option |
| 86 | | - * |
| 87 | | - * @param method - The string 'option' to retrieve an option value |
| 88 | | - * @param optionName - The name of the option to retrieve |
| 89 | | - * @returns The value of the specified option |
| 90 | | - */ |
| 91 | | - sortable(method: 'option', optionName: string): any; |
| 92 | | - |
| 93 | | - /** |
| 94 | | - * Sets the value of the specified option |
| 95 | | - * |
| 96 | | - * @param method - The string 'option' to set an option value |
| 97 | | - * @param optionName - The name of the option to set |
| 98 | | - * @param value - The value to assign to the option |
| 99 | | - * @returns The jQuery object for chaining |
| 100 | | - */ |
| 101 | | - sortable(method: 'option', optionName: string, value: any): JQuery; |
| 102 | | - |
| 103 | | - /** |
| 104 | | - * Sets multiple options using an object |
| 105 | | - * |
| 106 | | - * @param method - The string 'option' to set options |
| 107 | | - * @param options - An object containing multiple option key-value pairs |
| 108 | | - * @returns The jQuery object for chaining |
| 109 | | - */ |
| 110 | | - sortable(method: 'option', options: SortableOptions): JQuery; |
| 111 | | - |
| 112 | | - //#endregion |
| 113 | 24 | } |
| 114 | | -} |
| 115 | | - |
| 116 | | -//#region select2 |
| 117 | | - |
| 118 | | -/** Options for configuring a select2 instance */ |
| 119 | | -interface Select2Options { |
| 120 | | - /** |
| 121 | | - * Provides support for ajax data sources |
| 122 | | - * @param params - Parameters including the search term |
| 123 | | - * @param callback - A callback function to handle the results |
| 124 | | - * @default null |
| 125 | | - */ |
| 126 | | - ajax?: { |
| 127 | | - url: string; |
| 128 | | - dataType?: string; |
| 129 | | - delay?: number; |
| 130 | | - data?: (params: any) => any; |
| 131 | | - processResults?: (data: any, params: any) => any; |
| 132 | | - } | { transport: (params, success, failure) => any }; |
| 133 | | - |
| 134 | | - /** |
| 135 | | - * Provides support for clearable selections |
| 136 | | - * @default false |
| 137 | | - */ |
| 138 | | - allowClear?: boolean; |
| 139 | | - |
| 140 | | - /** |
| 141 | | - * See Using Select2 with AMD or CommonJS loaders |
| 142 | | - * @default './i18n/' |
| 143 | | - */ |
| 144 | | - amdLanguageBase?: string; |
| 145 | | - |
| 146 | | - /** |
| 147 | | - * Controls whether the dropdown is closed after a selection is made |
| 148 | | - * @default true |
| 149 | | - */ |
| 150 | | - closeOnSelect?: boolean; |
| 151 | | - |
| 152 | | - /** |
| 153 | | - * Allows rendering dropdown options from an array |
| 154 | | - * @default null |
| 155 | | - */ |
| 156 | | - data?: object[]; |
| 157 | | - |
| 158 | | - /** |
| 159 | | - * Used to override the built-in DataAdapter |
| 160 | | - * @default SelectAdapter |
| 161 | | - */ |
| 162 | | - dataAdapter?: SelectAdapter; |
| 163 | | - |
| 164 | | - /** |
| 165 | | - * Enable debugging messages in the browser console |
| 166 | | - * @default false |
| 167 | | - */ |
| 168 | | - debug?: boolean; |
| 169 | | - |
| 170 | | - /** |
| 171 | | - * Sets the dir attribute on the selection and dropdown containers to indicate the direction of the text |
| 172 | | - * @default 'ltr' |
| 173 | | - */ |
| 174 | | - dir?: string; |
| 175 | | - |
| 176 | | - /** |
| 177 | | - * When set to true, the select control will be disabled |
| 178 | | - * @default false |
| 179 | | - */ |
| 180 | | - disabled?: boolean; |
| 181 | | - |
| 182 | | - /** |
| 183 | | - * Used to override the built-in DropdownAdapter |
| 184 | | - * @default DropdownAdapter |
| 185 | | - */ |
| 186 | | - dropdownAdapter?: DropdownAdapter; |
| 187 | | - |
| 188 | | - /** |
| 189 | | - * @default false |
| 190 | | - */ |
| 191 | | - dropdownAutoWidth?: boolean; |
| 192 | | - |
| 193 | | - /** |
| 194 | | - * Adds additional CSS classes to the dropdown container. The helper :all: can be used to add all CSS classes present on the original <select> element. |
| 195 | | - * @default '' |
| 196 | | - */ |
| 197 | | - dropdownCssClass?: string; |
| 198 | | - |
| 199 | | - /** |
| 200 | | - * Allows you to customize placement of the dropdown |
| 201 | | - * @default $(document.body) |
| 202 | | - */ |
| 203 | | - dropdownParent?: JQuery | HTMLElement; |
| 204 | | - |
| 205 | | - /** |
| 206 | | - * Handles automatic escaping of content rendered by custom templates |
| 207 | | - * @default Utils.escapeMarkup |
| 208 | | - */ |
| 209 | | - escapeMarkup?: function; |
| 210 | | - |
| 211 | | - /** |
| 212 | | - * Specify the language used for Select2 messages |
| 213 | | - * @default EnglishTranslation |
| 214 | | - */ |
| 215 | | - language?: string | object; |
| 216 | | - |
| 217 | | - /** |
| 218 | | - * Handles custom search matching |
| 219 | | - * @default null |
| 220 | | - */ |
| 221 | | - matcher?: (searchParams: object, data: object) => boolean; |
| 222 | | - |
| 223 | | - /** |
| 224 | | - * Maximum number of characters that may be provided for a search term |
| 225 | | - * @default 0 |
| 226 | | - */ |
| 227 | | - maximumInputLength?: number; |
| 228 | | - |
| 229 | | - /** |
| 230 | | - * The maximum number of items that may be selected in a multi-select control. If the value of this option is less than 1, the number of selected items will not be limited. |
| 231 | | - * @default 0 |
| 232 | | - */ |
| 233 | | - maximumSelectionLength?: number; |
| 234 | 25 | |
| 235 | | - /** |
| 26 | + namespace Select2 { |
| 236 | | - * Minimum number of characters required to start a search |
| 27 | + interface Options<Result = DataFormat | GroupedDataFormat, RemoteResult = any> { |
| 237 | | - * @default 0 |
| 28 | + /** |
| 238 | | - */ |
| 29 | + * Extends Select2 v4 plugin by adding an option to set a placeholder for the 'search' input field |
| 239 | | - minimumInputLength?: number; |
| 30 | + * [Custom Field] |
| 240 | | - |
| 31 | + * @default '' |
| 241 | | - /** |
| 32 | + */ |
| 242 | | - * The minimum number of results required to display the search box |
| 33 | + searchInputPlaceholder?: string; |
| 243 | | - * @default 0 |
| 34 | + |
| 244 | | - */ |
| 35 | + /** |
| 245 | | - minimumResultsForSearch?: number; |
| 36 | + * Extends select2 plugin by adding a custom css class for the 'search' input field |
| 246 | | - |
| 37 | + * [Custom Field] |
| 247 | | - /** |
| 38 | + * @default '' |
| 248 | | - * This option enables multi-select (pillbox) mode. Select2 will automatically map the value of the multiple HTML attribute to this option during initialization. |
| 39 | + */ |
| 249 | | - * @default false |
| 40 | + searchInputCssClass?: string; |
| 250 | | - */ |
| 41 | + } |
| 251 | | - multiple?: boolean; |
| 42 | + } |
| 252 | | - |
| 253 | | - /** |
| 254 | | - * Specifies the placeholder for the control |
| 255 | | - * @default null |
| 256 | | - */ |
| 257 | | - placeholder?: string; |
| 258 | | - |
| 259 | | - /** |
| 260 | | - * Used to override the built-in ResultsAdapter |
| 261 | | - * @default ResultsAdapter |
| 262 | | - */ |
| 263 | | - resultsAdapter?: ResultsAdapter; |
| 264 | | - |
| 265 | | - /** |
| 266 | | - * Used to override the built-in SelectionAdapter |
| 267 | | - * @default SingleSelection | MultipleSelection |
| 268 | | - */ |
| 269 | | - selectionAdapter?: SingleSelection | MultipleSelection; |
| 270 | | - |
| 271 | | - /** |
| 272 | | - * Adds additional CSS classes to the selection container. The helper :all: can be used to add all CSS classes present on the original <select> element |
| 273 | | - * @default '' |
| 274 | | - */ |
| 275 | | - selectionCssClass?: string; |
| 276 | | - |
| 277 | | - /** |
| 278 | | - * Implements automatic selection when the dropdown is closed |
| 279 | | - * @default false |
| 280 | | - */ |
| 281 | | - selectOnClose?: boolean; |
| 282 | | - |
| 283 | | - sorter?: function; |
| 284 | | - |
| 285 | | - /** |
| 286 | | - * When set to `true`, allows the user to create new tags that aren't pre-populated |
| 287 | | - * Used to enable free text responses |
| 288 | | - * @default false |
| 289 | | - */ |
| 290 | | - tags?: boolean | object[]; |
| 291 | | - |
| 292 | | - /** |
| 293 | | - * Customizes the way that search results are rendered |
| 294 | | - * @param item - The item object to format |
| 295 | | - * @returns The formatted representation |
| 296 | | - * @default null |
| 297 | | - */ |
| 298 | | - templateResult?: (item: any) => JQuery | string; |
| 299 | | - |
| 300 | | - /** |
| 301 | | - * Customizes the way that selections are rendered |
| 302 | | - * @param item - The selected item object to format |
| 303 | | - * @returns The formatted representation |
| 304 | | - * @default null |
| 305 | | - */ |
| 306 | | - templateSelection?: (item: any) => JQuery | string; |
| 307 | | - |
| 308 | | - /** |
| 309 | | - * Allows you to set the theme |
| 310 | | - * @default 'default' |
| 311 | | - */ |
| 312 | | - theme?: string; |
| 313 | | - |
| 314 | | - /** |
| 315 | | - * A callback that handles automatic tokenization of free-text entry |
| 316 | | - * @default null |
| 317 | | - */ |
| 318 | | - tokenizer?: (input: { _type: string, term: string }, selection: { options: object }, callback: (Select2Option) => any) => { term: string }; |
| 319 | | - |
| 320 | | - /** |
| 321 | | - * The list of characters that should be used as token separators |
| 322 | | - * @default null |
| 323 | | - */ |
| 324 | | - tokenSeparators?: string[]; |
| 325 | | - |
| 326 | | - /** |
| 327 | | - * Supports customization of the container width |
| 328 | | - * @default 'resolve' |
| 329 | | - */ |
| 330 | | - width?: string; |
| 331 | | - |
| 332 | | - /** |
| 333 | | - * If true, resolves issue for multiselects using closeOnSelect: false that caused the list of results to scroll to the first selection after each select/unselect |
| 334 | | - * @default false |
| 335 | | - */ |
| 336 | | - scrollAfterSelect?: boolean; |
| 337 | | - |
| 338 | | - /** |
| 339 | | - * Extends Select2 v4 plugin by adding an option to set a placeholder for the 'search' input field |
| 340 | | - * [Custom Field] |
| 341 | | - * @default '' |
| 342 | | - */ |
| 343 | | - searchInputPlaceholder?: string; |
| 344 | | - |
| 345 | | - /** |
| 346 | | - * Extends select2 plugin by adding a custom css class for the 'searcH' input field |
| 347 | | - * [Custom Field] |
| 348 | | - * @default '' |
| 349 | | - */ |
| 350 | | - searchInputCssClass?: string; |
| 351 | | -} |
| 352 | | - |
| 353 | | -//#endregion |
| 354 | | - |
| 355 | | -//#region sortable |
| 356 | | - |
| 357 | | -/** Options for configuring a sortable instance */ |
| 358 | | -interface SortableOptions { |
| 359 | | - /** |
| 360 | | - * When set, prevents the sortable items from being dragged unless clicked with a delay |
| 361 | | - * @default 0 |
| 362 | | - */ |
| 363 | | - delay?: number; |
| 364 | | - |
| 365 | | - /** |
| 366 | | - * Class name for elements to handle sorting. Elements with this class can be dragged to sort. |
| 367 | | - * @default '' |
| 368 | | - */ |
| 369 | | - handle?: string; |
| 370 | | - |
| 371 | | - /** |
| 372 | | - * Whether to allow sorting between different connected lists |
| 373 | | - * @default false |
| 374 | | - */ |
| 375 | | - connectWith?: string | boolean; |
| 376 | | - |
| 377 | | - /** |
| 378 | | - * Function called when sorting starts |
| 379 | | - * @param event - The event object |
| 380 | | - * @param ui - The UI object containing the helper and position information |
| 381 | | - */ |
| 382 | | - start?: (event: Event, ui: SortableUI) => void; |
| 383 | | - |
| 384 | | - /** |
| 385 | | - * Function called when sorting stops |
| 386 | | - * @param event - The event object |
| 387 | | - * @param ui - The UI object containing the helper and position information |
| 388 | | - */ |
| 389 | | - stop?: (event: Event, ui: SortableUI) => void; |
| 390 | | - |
| 391 | | - /** |
| 392 | | - * Function called when sorting updates |
| 393 | | - * @param event - The event object |
| 394 | | - * @param ui - The UI object containing the helper and position information |
| 395 | | - */ |
| 396 | | - update?: (event: Event, ui: SortableUI) => void; |
| 397 | | - |
| 398 | | - /** |
| 399 | | - * Specifies which items inside the element should be sortable |
| 400 | | - * @default '> *' |
| 401 | | - */ |
| 402 | | - items?: string; |
| 403 | | -} |
| 404 | | - |
| 405 | | -/** UI object passed to sortable event handlers */ |
| 406 | | -interface SortableUI { |
| 407 | | - /** jQuery object representing the helper element */ |
| 408 | | - helper: JQuery; |
| 409 | | - /** The current position of the helper element */ |
| 410 | | - position: { top: number; left: number }; |
| 411 | | - /** Original position of the helper element */ |
| 412 | | - originalPosition: { top: number; left: number }; |
| 413 | | - /** jQuery object representing the item being sorted */ |
| 414 | | - item: JQuery; |
| 415 | | - /** The placeholder element used during sorting */ |
| 416 | | - placeholder: JQuery; |
| 417 | 43 | } |
| 418 | | - |
| 419 | | -//#endregion |