index.d.ts 78 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164116511661167116811691170117111721173117411751176117711781179118011811182118311841185118611871188118911901191119211931194119511961197119811991200120112021203120412051206120712081209121012111212121312141215121612171218121912201221122212231224122512261227122812291230123112321233123412351236123712381239124012411242124312441245124612471248124912501251125212531254125512561257125812591260126112621263126412651266126712681269127012711272127312741275127612771278127912801281128212831284128512861287128812891290129112921293129412951296129712981299130013011302130313041305130613071308130913101311131213131314131513161317131813191320132113221323132413251326132713281329133013311332133313341335133613371338133913401341134213431344134513461347134813491350135113521353135413551356135713581359136013611362136313641365136613671368136913701371137213731374137513761377137813791380138113821383138413851386138713881389139013911392139313941395139613971398139914001401140214031404140514061407140814091410141114121413141414151416141714181419142014211422142314241425142614271428142914301431143214331434143514361437143814391440144114421443144414451446144714481449145014511452145314541455145614571458145914601461146214631464146514661467146814691470147114721473147414751476147714781479148014811482148314841485148614871488148914901491149214931494149514961497149814991500150115021503150415051506150715081509151015111512151315141515151615171518151915201521152215231524152515261527152815291530153115321533153415351536153715381539154015411542154315441545154615471548154915501551155215531554155515561557155815591560156115621563156415651566156715681569157015711572157315741575157615771578157915801581158215831584158515861587158815891590159115921593159415951596159715981599160016011602160316041605160616071608160916101611161216131614161516161617161816191620162116221623162416251626162716281629163016311632163316341635163616371638163916401641164216431644164516461647164816491650165116521653165416551656165716581659166016611662166316641665166616671668166916701671167216731674167516761677167816791680168116821683168416851686168716881689169016911692169316941695169616971698169917001701170217031704170517061707170817091710171117121713171417151716171717181719172017211722172317241725172617271728172917301731173217331734173517361737173817391740174117421743174417451746174717481749175017511752175317541755175617571758175917601761176217631764176517661767176817691770177117721773177417751776177717781779178017811782178317841785178617871788178917901791179217931794179517961797179817991800180118021803180418051806180718081809181018111812181318141815181618171818181918201821182218231824182518261827182818291830183118321833183418351836183718381839184018411842184318441845184618471848184918501851185218531854185518561857185818591860186118621863186418651866186718681869187018711872187318741875187618771878187918801881188218831884188518861887188818891890189118921893189418951896189718981899190019011902190319041905190619071908190919101911191219131914191519161917191819191920192119221923192419251926192719281929193019311932193319341935193619371938193919401941194219431944194519461947194819491950195119521953195419551956195719581959196019611962196319641965196619671968196919701971197219731974197519761977197819791980198119821983198419851986198719881989199019911992199319941995199619971998199920002001200220032004200520062007200820092010201120122013201420152016201720182019
  1. /// <reference types="jquery" />
  2. declare namespace JQueryUI {
  3. // Accordion //////////////////////////////////////////////////
  4. interface AccordionOptions extends AccordionEvents {
  5. active?: any; // boolean or number
  6. animate?: any; // boolean, number, string or object
  7. collapsible?: boolean | undefined;
  8. disabled?: boolean | undefined;
  9. event?: string | undefined;
  10. header?: string | undefined;
  11. heightStyle?: string | undefined;
  12. icons?: any;
  13. }
  14. interface AccordionUIParams {
  15. newHeader: JQuery;
  16. oldHeader: JQuery;
  17. newPanel: JQuery;
  18. oldPanel: JQuery;
  19. }
  20. interface AccordionEvent {
  21. (event: JQueryEventObject, ui: AccordionUIParams): void;
  22. }
  23. interface AccordionEvents {
  24. activate?: AccordionEvent | undefined;
  25. beforeActivate?: AccordionEvent | undefined;
  26. create?: AccordionEvent | undefined;
  27. }
  28. interface Accordion extends Widget, AccordionOptions {
  29. }
  30. // Autocomplete //////////////////////////////////////////////////
  31. interface AutocompleteOptions extends AutocompleteEvents {
  32. appendTo?: any; // Selector;
  33. autoFocus?: boolean | undefined;
  34. delay?: number | undefined;
  35. disabled?: boolean | undefined;
  36. minLength?: number | undefined;
  37. position?: any; // object
  38. source?: any; // [], string or ()
  39. classes?: AutocompleteClasses | undefined;
  40. }
  41. interface AutocompleteClasses {
  42. "ui-autocomplete"?: string | undefined;
  43. "ui-autocomplete-input"?: string | undefined;
  44. }
  45. interface AutocompleteUIParams {
  46. /**
  47. * The item selected from the menu, if any. Otherwise the property is null
  48. */
  49. item?: any;
  50. content?: any;
  51. }
  52. interface AutocompleteEvent {
  53. (event: JQueryEventObject, ui: AutocompleteUIParams): void;
  54. }
  55. interface AutocompleteEvents {
  56. change?: AutocompleteEvent | undefined;
  57. close?: AutocompleteEvent | undefined;
  58. create?: AutocompleteEvent | undefined;
  59. focus?: AutocompleteEvent | undefined;
  60. open?: AutocompleteEvent | undefined;
  61. response?: AutocompleteEvent | undefined;
  62. search?: AutocompleteEvent | undefined;
  63. select?: AutocompleteEvent | undefined;
  64. }
  65. interface Autocomplete extends Widget, AutocompleteOptions {
  66. escapeRegex: (value: string) => string;
  67. filter: (array: any, term: string) => any;
  68. }
  69. // Button //////////////////////////////////////////////////
  70. interface ButtonOptions {
  71. disabled?: boolean | undefined;
  72. icons?: any;
  73. label?: string | undefined;
  74. text?: string | boolean | undefined;
  75. click?: ((event?: Event) => void) | undefined;
  76. }
  77. interface Button extends Widget, ButtonOptions {
  78. }
  79. // Datepicker //////////////////////////////////////////////////
  80. interface DatepickerOptions {
  81. /**
  82. * An input element that is to be updated with the selected date from the datepicker. Use the altFormat option to change the format of the date within this field. Leave as blank for no alternate field.
  83. */
  84. altField?: any; // Selector, jQuery or Element
  85. /**
  86. * The dateFormat to be used for the altField option. This allows one date format to be shown to the user for selection purposes, while a different format is actually sent behind the scenes. For a full list of the possible formats see the formatDate function
  87. */
  88. altFormat?: string | undefined;
  89. /**
  90. * The text to display after each date field, e.g., to show the required format.
  91. */
  92. appendText?: string | undefined;
  93. /**
  94. * Set to true to automatically resize the input field to accommodate dates in the current dateFormat.
  95. */
  96. autoSize?: boolean | undefined;
  97. /**
  98. * A function that takes an input field and current datepicker instance and returns an options object to update the datepicker with. It is called just before the datepicker is displayed.
  99. */
  100. beforeShow?: ((input: Element, inst: any) => JQueryUI.DatepickerOptions) | undefined;
  101. /**
  102. * A function that takes a date as a parameter and must return an array with:
  103. * [0]: true/false indicating whether or not this date is selectable
  104. * [1]: a CSS class name to add to the date's cell or "" for the default presentation
  105. * [2]: an optional popup tooltip for this date
  106. * The function is called for each day in the datepicker before it is displayed.
  107. */
  108. beforeShowDay?: ((date: Date) => any[]) | undefined;
  109. /**
  110. * A URL of an image to use to display the datepicker when the showOn option is set to "button" or "both". If set, the buttonText option becomes the alt value and is not directly displayed.
  111. */
  112. buttonImage?: string | undefined;
  113. /**
  114. * Whether the button image should be rendered by itself instead of inside a button element. This option is only relevant if the buttonImage option has also been set.
  115. */
  116. buttonImageOnly?: boolean | undefined;
  117. /**
  118. * The text to display on the trigger button. Use in conjunction with the showOn option set to "button" or "both".
  119. */
  120. buttonText?: string | undefined;
  121. /**
  122. * A function to calculate the week of the year for a given date. The default implementation uses the ISO 8601 definition: weeks start on a Monday; the first week of the year contains the first Thursday of the year.
  123. */
  124. calculateWeek?: ((date: Date) => string) | undefined;
  125. /**
  126. * Whether the month should be rendered as a dropdown instead of text.
  127. */
  128. changeMonth?: boolean | undefined;
  129. /**
  130. * Whether the year should be rendered as a dropdown instead of text. Use the yearRange option to control which years are made available for selection.
  131. */
  132. changeYear?: boolean | undefined;
  133. /**
  134. * The text to display for the close link. Use the showButtonPanel option to display this button.
  135. */
  136. closeText?: string | undefined;
  137. /**
  138. * When true, entry in the input field is constrained to those characters allowed by the current dateFormat option.
  139. */
  140. constrainInput?: boolean | undefined;
  141. /**
  142. * The text to display for the current day link. Use the showButtonPanel option to display this button.
  143. */
  144. currentText?: string | undefined;
  145. /**
  146. * The format for parsed and displayed dates. For a full list of the possible formats see the formatDate function.
  147. */
  148. dateFormat?: string | undefined;
  149. /**
  150. * The list of long day names, starting from Sunday, for use as requested via the dateFormat option.
  151. */
  152. dayNames?: string[] | undefined;
  153. /**
  154. * The list of minimised day names, starting from Sunday, for use as column headers within the datepicker.
  155. */
  156. dayNamesMin?: string[] | undefined;
  157. /**
  158. * The list of abbreviated day names, starting from Sunday, for use as requested via the dateFormat option.
  159. */
  160. dayNamesShort?: string[] | undefined;
  161. /**
  162. * Set the date to highlight on first opening if the field is blank. Specify either an actual date via a Date object or as a string in the current dateFormat, or a number of days from today (e.g. +7) or a string of values and periods ('y' for years, 'm' for months, 'w' for weeks, 'd' for days, e.g. '+1m +7d'), or null for today.
  163. * Multiple types supported:
  164. * Date: A date object containing the default date.
  165. * Number: A number of days from today. For example 2 represents two days from today and -1 represents yesterday.
  166. * String: A string in the format defined by the dateFormat option, or a relative date. Relative dates must contain value and period pairs; valid periods are "y" for years, "m" for months, "w" for weeks, and "d" for days. For example, "+1m +7d" represents one month and seven days from today.
  167. */
  168. defaultDate?: any; // Date, number or string
  169. /**
  170. * Control the speed at which the datepicker appears, it may be a time in milliseconds or a string representing one of the three predefined speeds ("slow", "normal", "fast").
  171. */
  172. duration?: string | undefined;
  173. /**
  174. * Set the first day of the week: Sunday is 0, Monday is 1, etc.
  175. */
  176. firstDay?: number | undefined;
  177. /**
  178. * When true, the current day link moves to the currently selected date instead of today.
  179. */
  180. gotoCurrent?: boolean | undefined;
  181. /**
  182. * Normally the previous and next links are disabled when not applicable (see the minDate and maxDate options). You can hide them altogether by setting this attribute to true.
  183. */
  184. hideIfNoPrevNext?: boolean | undefined;
  185. /**
  186. * Whether the current language is drawn from right to left.
  187. */
  188. isRTL?: boolean | undefined;
  189. /**
  190. * The maximum selectable date. When set to null, there is no maximum.
  191. * Multiple types supported:
  192. * Date: A date object containing the maximum date.
  193. * Number: A number of days from today. For example 2 represents two days from today and -1 represents yesterday.
  194. * String: A string in the format defined by the dateFormat option, or a relative date. Relative dates must contain value and period pairs; valid periods are "y" for years, "m" for months, "w" for weeks, and "d" for days. For example, "+1m +7d" represents one month and seven days from today.
  195. */
  196. maxDate?: any; // Date, number or string
  197. /**
  198. * The minimum selectable date. When set to null, there is no minimum.
  199. * Multiple types supported:
  200. * Date: A date object containing the minimum date.
  201. * Number: A number of days from today. For example 2 represents two days from today and -1 represents yesterday.
  202. * String: A string in the format defined by the dateFormat option, or a relative date. Relative dates must contain value and period pairs; valid periods are "y" for years, "m" for months, "w" for weeks, and "d" for days. For example, "+1m +7d" represents one month and seven days from today.
  203. */
  204. minDate?: any; // Date, number or string
  205. /**
  206. * The list of full month names, for use as requested via the dateFormat option.
  207. */
  208. monthNames?: string[] | undefined;
  209. /**
  210. * The list of abbreviated month names, as used in the month header on each datepicker and as requested via the dateFormat option.
  211. */
  212. monthNamesShort?: string[] | undefined;
  213. /**
  214. * Whether the prevText and nextText options should be parsed as dates by the formatDate function, allowing them to display the target month names for example.
  215. */
  216. navigationAsDateFormat?: boolean | undefined;
  217. /**
  218. * The text to display for the next month link. With the standard ThemeRoller styling, this value is replaced by an icon.
  219. */
  220. nextText?: string | undefined;
  221. /**
  222. * The number of months to show at once.
  223. * Multiple types supported:
  224. * Number: The number of months to display in a single row.
  225. * Array: An array defining the number of rows and columns to display.
  226. */
  227. numberOfMonths?: any; // number or number[]
  228. /**
  229. * Called when the datepicker moves to a new month and/or year. The function receives the selected year, month (1-12), and the datepicker instance as parameters. this refers to the associated input field.
  230. */
  231. onChangeMonthYear?: ((year: number, month: number, inst: any) => void) | undefined;
  232. /**
  233. * Called when the datepicker is closed, whether or not a date is selected. The function receives the selected date as text ("" if none) and the datepicker instance as parameters. this refers to the associated input field.
  234. */
  235. onClose?: ((dateText: string, inst: any) => void) | undefined;
  236. /**
  237. * Called when the datepicker is selected. The function receives the selected date as text and the datepicker instance as parameters. this refers to the associated input field.
  238. */
  239. onSelect?: ((dateText: string, inst: any) => void) | undefined;
  240. /**
  241. * The text to display for the previous month link. With the standard ThemeRoller styling, this value is replaced by an icon.
  242. */
  243. prevText?: string | undefined;
  244. /**
  245. * Whether days in other months shown before or after the current month are selectable. This only applies if the showOtherMonths option is set to true.
  246. */
  247. selectOtherMonths?: boolean | undefined;
  248. /**
  249. * The cutoff year for determining the century for a date (used in conjunction with dateFormat 'y'). Any dates entered with a year value less than or equal to the cutoff year are considered to be in the current century, while those greater than it are deemed to be in the previous century.
  250. * Multiple types supported:
  251. * Number: A value between 0 and 99 indicating the cutoff year.
  252. * String: A relative number of years from the current year, e.g., "+3" or "-5".
  253. */
  254. shortYearCutoff?: any; // number or string
  255. /**
  256. * The name of the animation used to show and hide the datepicker. Use "show" (the default), "slideDown", "fadeIn", any of the jQuery UI effects. Set to an empty string to disable animation.
  257. */
  258. showAnim?: string | undefined;
  259. /**
  260. * Whether to display a button pane underneath the calendar. The button pane contains two buttons, a Today button that links to the current day, and a Done button that closes the datepicker. The buttons' text can be customized using the currentText and closeText options respectively.
  261. */
  262. showButtonPanel?: boolean | undefined;
  263. /**
  264. * When displaying multiple months via the numberOfMonths option, the showCurrentAtPos option defines which position to display the current month in.
  265. */
  266. showCurrentAtPos?: number | undefined;
  267. /**
  268. * Whether to show the month after the year in the header.
  269. */
  270. showMonthAfterYear?: boolean | undefined;
  271. /**
  272. * When the datepicker should appear. The datepicker can appear when the field receives focus ("focus"), when a button is clicked ("button"), or when either event occurs ("both").
  273. */
  274. showOn?: string | undefined;
  275. /**
  276. * If using one of the jQuery UI effects for the showAnim option, you can provide additional settings for that animation via this option.
  277. */
  278. showOptions?: any; // TODO
  279. /**
  280. * Whether to display dates in other months (non-selectable) at the start or end of the current month. To make these days selectable use the selectOtherMonths option.
  281. */
  282. showOtherMonths?: boolean | undefined;
  283. /**
  284. * When true, a column is added to show the week of the year. The calculateWeek option determines how the week of the year is calculated. You may also want to change the firstDay option.
  285. */
  286. showWeek?: boolean | undefined;
  287. /**
  288. * Set how many months to move when clicking the previous/next links.
  289. */
  290. stepMonths?: number | undefined;
  291. /**
  292. * The text to display for the week of the year column heading. Use the showWeek option to display this column.
  293. */
  294. weekHeader?: string | undefined;
  295. /**
  296. * The range of years displayed in the year drop-down: either relative to today's year ("-nn:+nn"), relative to the currently selected year ("c-nn:c+nn"), absolute ("nnnn:nnnn"), or combinations of these formats ("nnnn:-nn"). Note that this option only affects what appears in the drop-down, to restrict which dates may be selected use the minDate and/or maxDate options.
  297. */
  298. yearRange?: string | undefined;
  299. /**
  300. * Additional text to display after the year in the month headers.
  301. */
  302. yearSuffix?: string | undefined;
  303. /**
  304. * Set to true to automatically hide the datepicker.
  305. */
  306. autohide?: boolean | undefined;
  307. /**
  308. * Set to date to automatically enddate the datepicker.
  309. */
  310. endDate?: Date | undefined;
  311. }
  312. interface DatepickerFormatDateOptions {
  313. dayNamesShort?: string[] | undefined;
  314. dayNames?: string[] | undefined;
  315. monthNamesShort?: string[] | undefined;
  316. monthNames?: string[] | undefined;
  317. }
  318. interface Datepicker extends Widget, DatepickerOptions {
  319. regional: { [languageCod3: string]: any };
  320. setDefaults(defaults: DatepickerOptions): void;
  321. formatDate(format: string, date: Date, settings?: DatepickerFormatDateOptions): string;
  322. parseDate(format: string, date: string, settings?: DatepickerFormatDateOptions): Date;
  323. iso8601Week(date: Date): number;
  324. noWeekends(date: Date): any[];
  325. }
  326. // Dialog //////////////////////////////////////////////////
  327. interface DialogOptions extends DialogEvents {
  328. autoOpen?: boolean | undefined;
  329. buttons?: { [buttonText: string]: (event?: Event) => void } | DialogButtonOptions[] | undefined;
  330. closeOnEscape?: boolean | undefined;
  331. classes?: DialogClasses | undefined;
  332. closeText?: string | undefined;
  333. appendTo?: string | undefined;
  334. dialogClass?: string | undefined;
  335. disabled?: boolean | undefined;
  336. draggable?: boolean | undefined;
  337. height?: number | string | undefined;
  338. hide?: boolean | number | string | DialogShowHideOptions | undefined;
  339. maxHeight?: number | undefined;
  340. maxWidth?: number | undefined;
  341. minHeight?: number | undefined;
  342. minWidth?: number | undefined;
  343. modal?: boolean | undefined;
  344. position?: any; // object, string or []
  345. resizable?: boolean | undefined;
  346. show?: boolean | number | string | DialogShowHideOptions | undefined;
  347. stack?: boolean | undefined;
  348. title?: string | undefined;
  349. width?: any; // number or string
  350. zIndex?: number | undefined;
  351. open?: DialogEvent | undefined;
  352. close?: DialogEvent | undefined;
  353. }
  354. interface DialogClasses {
  355. "ui-dialog"?: string | undefined;
  356. "ui-dialog-content"?: string | undefined;
  357. "ui-dialog-dragging"?: string | undefined;
  358. "ui-dialog-resizing"?: string | undefined;
  359. "ui-dialog-buttons"?: string | undefined;
  360. "ui-dialog-titlebar"?: string | undefined;
  361. "ui-dialog-title"?: string | undefined;
  362. "ui-dialog-titlebar-close"?: string | undefined;
  363. "ui-dialog-buttonpane"?: string | undefined;
  364. "ui-dialog-buttonset"?: string | undefined;
  365. "ui-widget-overlay"?: string | undefined;
  366. }
  367. interface DialogButtonOptions {
  368. icons?: any;
  369. showText?: string | boolean | undefined;
  370. text?: string | undefined;
  371. click?: ((eventObject: JQueryEventObject) => any) | undefined;
  372. [attr: string]: any; // attributes for the <button> element
  373. }
  374. interface DialogShowHideOptions {
  375. effect: string;
  376. delay?: number | undefined;
  377. duration?: number | undefined;
  378. easing?: string | undefined;
  379. }
  380. interface DialogUIParams {
  381. }
  382. interface DialogEvent {
  383. (event: JQueryEventObject, ui: DialogUIParams): void;
  384. }
  385. interface DialogEvents {
  386. beforeClose?: DialogEvent | undefined;
  387. close?: DialogEvent | undefined;
  388. create?: DialogEvent | undefined;
  389. drag?: DialogEvent | undefined;
  390. dragStart?: DialogEvent | undefined;
  391. dragStop?: DialogEvent | undefined;
  392. focus?: DialogEvent | undefined;
  393. open?: DialogEvent | undefined;
  394. resize?: DialogEvent | undefined;
  395. resizeStart?: DialogEvent | undefined;
  396. resizeStop?: DialogEvent | undefined;
  397. }
  398. interface Dialog extends Widget, DialogOptions {
  399. }
  400. // Draggable //////////////////////////////////////////////////
  401. interface DraggableEventUIParams {
  402. helper: JQuery;
  403. position: { top: number; left: number };
  404. originalPosition: { top: number; left: number };
  405. offset: { top: number; left: number };
  406. }
  407. interface DraggableEvent {
  408. (event: JQueryEventObject, ui: DraggableEventUIParams): void;
  409. }
  410. interface DraggableOptions extends DraggableEvents {
  411. disabled?: boolean | undefined;
  412. addClasses?: boolean | undefined;
  413. appendTo?: any;
  414. axis?: string | undefined;
  415. cancel?: string | undefined;
  416. classes?: DraggableClasses | undefined;
  417. connectToSortable?: Element | Element[] | JQuery | string | undefined;
  418. containment?: any;
  419. cursor?: string | undefined;
  420. cursorAt?: any;
  421. delay?: number | undefined;
  422. distance?: number | undefined;
  423. grid?: number[] | undefined;
  424. handle?: any;
  425. helper?: any;
  426. iframeFix?: any;
  427. opacity?: number | undefined;
  428. refreshPositions?: boolean | undefined;
  429. revert?: any;
  430. revertDuration?: number | undefined;
  431. scope?: string | undefined;
  432. scroll?: boolean | undefined;
  433. scrollSensitivity?: number | undefined;
  434. scrollSpeed?: number | undefined;
  435. snap?: any;
  436. snapMode?: string | undefined;
  437. snapTolerance?: number | undefined;
  438. stack?: string | undefined;
  439. zIndex?: number | undefined;
  440. }
  441. interface DraggableClasses {
  442. "ui-draggable"?: string | undefined;
  443. "ui-draggable-disabled"?: string | undefined;
  444. "ui-draggable-dragging"?: string | undefined;
  445. "ui-draggable-handle"?: string | undefined;
  446. }
  447. interface DraggableEvents {
  448. create?: DraggableEvent | undefined;
  449. start?: DraggableEvent | undefined;
  450. drag?: DraggableEvent | undefined;
  451. stop?: DraggableEvent | undefined;
  452. }
  453. interface Draggable extends Widget, DraggableOptions, DraggableEvent {
  454. }
  455. // Droppable //////////////////////////////////////////////////
  456. interface DroppableEventUIParam {
  457. draggable: JQuery;
  458. helper: JQuery;
  459. position: { top: number; left: number };
  460. offset: { top: number; left: number };
  461. }
  462. interface DroppableEvent {
  463. (event: JQueryEventObject, ui: DroppableEventUIParam): void;
  464. }
  465. interface DroppableOptions extends DroppableEvents {
  466. accept?: any;
  467. activeClass?: string | undefined;
  468. addClasses?: boolean | undefined;
  469. disabled?: boolean | undefined;
  470. greedy?: boolean | undefined;
  471. hoverClass?: string | undefined;
  472. scope?: string | undefined;
  473. tolerance?: string | undefined;
  474. }
  475. interface DroppableEvents {
  476. create?: DroppableEvent | undefined;
  477. activate?: DroppableEvent | undefined;
  478. deactivate?: DroppableEvent | undefined;
  479. over?: DroppableEvent | undefined;
  480. out?: DroppableEvent | undefined;
  481. drop?: DroppableEvent | undefined;
  482. }
  483. interface Droppable extends Widget, DroppableOptions {
  484. }
  485. // Menu //////////////////////////////////////////////////
  486. interface MenuOptions extends MenuEvents {
  487. disabled?: boolean | undefined;
  488. icons?: any;
  489. menus?: string | undefined;
  490. position?: any; // TODO
  491. role?: string | undefined;
  492. }
  493. interface MenuUIParams {
  494. item?: JQuery | undefined;
  495. }
  496. interface MenuEvent {
  497. (event: JQueryEventObject, ui: MenuUIParams): void;
  498. }
  499. interface MenuEvents {
  500. blur?: MenuEvent | undefined;
  501. create?: MenuEvent | undefined;
  502. focus?: MenuEvent | undefined;
  503. select?: MenuEvent | undefined;
  504. }
  505. interface Menu extends Widget, MenuOptions {
  506. }
  507. // Progressbar //////////////////////////////////////////////////
  508. interface ProgressbarOptions extends ProgressbarEvents {
  509. disabled?: boolean | undefined;
  510. value?: number | boolean | undefined;
  511. max?: number | undefined;
  512. }
  513. interface ProgressbarUIParams {
  514. }
  515. interface ProgressbarEvent {
  516. (event: JQueryEventObject, ui: ProgressbarUIParams): void;
  517. }
  518. interface ProgressbarEvents {
  519. change?: ProgressbarEvent | undefined;
  520. complete?: ProgressbarEvent | undefined;
  521. create?: ProgressbarEvent | undefined;
  522. }
  523. interface Progressbar extends Widget, ProgressbarOptions {
  524. }
  525. // Resizable //////////////////////////////////////////////////
  526. interface ResizableOptions extends ResizableEvents {
  527. alsoResize?: any; // Selector, JQuery or Element
  528. animate?: boolean | undefined;
  529. animateDuration?: any; // number or string
  530. animateEasing?: string | undefined;
  531. aspectRatio?: any; // boolean or number
  532. autoHide?: boolean | undefined;
  533. cancel?: string | undefined;
  534. containment?: any; // Selector, Element or string
  535. delay?: number | undefined;
  536. disabled?: boolean | undefined;
  537. distance?: number | undefined;
  538. ghost?: boolean | undefined;
  539. grid?: any;
  540. handles?: any; // string or object
  541. helper?: string | undefined;
  542. maxHeight?: number | undefined;
  543. maxWidth?: number | undefined;
  544. minHeight?: number | undefined;
  545. minWidth?: number | undefined;
  546. }
  547. interface ResizableUIParams {
  548. element: JQuery;
  549. helper: JQuery;
  550. originalElement: JQuery;
  551. originalPosition: any;
  552. originalSize: any;
  553. position: any;
  554. size: any;
  555. }
  556. interface ResizableEvent {
  557. (event: JQueryEventObject, ui: ResizableUIParams): void;
  558. }
  559. interface ResizableEvents {
  560. resize?: ResizableEvent | undefined;
  561. start?: ResizableEvent | undefined;
  562. stop?: ResizableEvent | undefined;
  563. create?: ResizableEvent | undefined;
  564. }
  565. interface Resizable extends Widget, ResizableOptions {
  566. }
  567. // Selectable //////////////////////////////////////////////////
  568. interface SelectableOptions extends SelectableEvents {
  569. autoRefresh?: boolean | undefined;
  570. cancel?: string | undefined;
  571. delay?: number | undefined;
  572. disabled?: boolean | undefined;
  573. distance?: number | undefined;
  574. filter?: string | undefined;
  575. tolerance?: string | undefined;
  576. }
  577. interface SelectableEvents {
  578. selected?(event: JQueryEventObject, ui: { selected?: Element | undefined }): void;
  579. selecting?(event: JQueryEventObject, ui: { selecting?: Element | undefined }): void;
  580. start?(event: JQueryEventObject, ui: any): void;
  581. stop?(event: JQueryEventObject, ui: any): void;
  582. unselected?(event: JQueryEventObject, ui: { unselected: Element }): void;
  583. unselecting?(event: JQueryEventObject, ui: { unselecting: Element }): void;
  584. }
  585. interface Selectable extends Widget, SelectableOptions {
  586. }
  587. // SelectMenu //////////////////////////////////////////////////
  588. interface SelectMenuOptions extends SelectMenuEvents {
  589. appendTo?: string | undefined;
  590. classes?: SelectMenuClasses | undefined;
  591. disabled?: boolean | undefined;
  592. icons?: any;
  593. position?: JQueryPositionOptions | undefined;
  594. width?: number | undefined;
  595. }
  596. interface SelectMenuClasses {
  597. "ui-selectmenu-button"?: string | undefined;
  598. "ui-selectmenu-button-closed"?: string | undefined;
  599. "ui-selectmenu-button-open"?: string | undefined;
  600. "ui-selectmenu-text"?: string | undefined;
  601. "ui-selectmenu-icon"?: string | undefined;
  602. "ui-selectmenu-menu"?: string | undefined;
  603. "ui-selectmenu-open"?: string | undefined;
  604. "ui-selectmenu-optgroup"?: string | undefined;
  605. }
  606. interface SelectMenuUIParams {
  607. item?: JQuery | undefined;
  608. }
  609. interface SelectMenuEvent {
  610. (event: JQueryEventObject, ui: SelectMenuUIParams): void;
  611. }
  612. interface SelectMenuEvents {
  613. change?: SelectMenuEvent | undefined;
  614. close?: SelectMenuEvent | undefined;
  615. create?: SelectMenuEvent | undefined;
  616. focus?: SelectMenuEvent | undefined;
  617. open?: SelectMenuEvent | undefined;
  618. select?: SelectMenuEvent | undefined;
  619. }
  620. interface SelectMenu extends Widget, SelectMenuOptions {
  621. }
  622. // Slider //////////////////////////////////////////////////
  623. interface SliderOptions extends SliderEvents {
  624. animate?: any; // boolean, string or number
  625. disabled?: boolean | undefined;
  626. max?: number | undefined;
  627. min?: number | undefined;
  628. orientation?: string | undefined;
  629. range?: any; // boolean or string
  630. step?: number | undefined;
  631. value?: number | undefined;
  632. values?: number[] | undefined;
  633. highlight?: boolean | undefined;
  634. classes?: SliderClasses | undefined;
  635. }
  636. interface SliderClasses {
  637. "ui-slider"?: string | undefined;
  638. "ui-slider-horizontal"?: string | undefined;
  639. "ui-slider-vertical"?: string | undefined;
  640. "ui-slider-handle"?: string | undefined;
  641. "ui-slider-range"?: string | undefined;
  642. "ui-slider-range-min"?: string | undefined;
  643. "ui-slider-range-max"?: string | undefined;
  644. }
  645. interface SliderUIParams {
  646. handle?: JQuery | undefined;
  647. value?: number | undefined;
  648. values?: number[] | undefined;
  649. }
  650. interface SliderEvent {
  651. (event: JQueryEventObject, ui: SliderUIParams): void;
  652. }
  653. interface SliderEvents {
  654. change?: SliderEvent | undefined;
  655. create?: SliderEvent | undefined;
  656. slide?: SliderEvent | undefined;
  657. start?: SliderEvent | undefined;
  658. stop?: SliderEvent | undefined;
  659. }
  660. interface Slider extends Widget, SliderOptions {
  661. }
  662. // Sortable //////////////////////////////////////////////////
  663. interface SortableOptions extends SortableEvents {
  664. appendTo?: any; // jQuery, Element, Selector or string
  665. attribute?: string | undefined;
  666. axis?: string | undefined;
  667. cancel?: any; // Selector
  668. connectWith?: any; // Selector
  669. containment?: any; // Element, Selector or string
  670. cursor?: string | undefined;
  671. cursorAt?: any;
  672. delay?: number | undefined;
  673. disabled?: boolean | undefined;
  674. distance?: number | undefined;
  675. dropOnEmpty?: boolean | undefined;
  676. forceHelperSize?: boolean | undefined;
  677. forcePlaceholderSize?: boolean | undefined;
  678. grid?: number[] | undefined;
  679. helper?: string | ((event: JQueryEventObject, element: Sortable) => Element) | undefined;
  680. handle?: any; // Selector or Element
  681. items?: any; // Selector
  682. opacity?: number | undefined;
  683. placeholder?: string | undefined;
  684. revert?: any; // boolean or number
  685. scroll?: boolean | undefined;
  686. scrollSensitivity?: number | undefined;
  687. scrollSpeed?: number | undefined;
  688. tolerance?: string | undefined;
  689. zIndex?: number | undefined;
  690. }
  691. interface SortableUIParams {
  692. helper: JQuery;
  693. item: JQuery;
  694. offset: any;
  695. position: any;
  696. originalPosition: any;
  697. sender: JQuery;
  698. placeholder: JQuery;
  699. }
  700. interface SortableEvent {
  701. (event: JQueryEventObject, ui: SortableUIParams): void;
  702. }
  703. interface SortableEvents {
  704. activate?: SortableEvent | undefined;
  705. beforeStop?: SortableEvent | undefined;
  706. change?: SortableEvent | undefined;
  707. deactivate?: SortableEvent | undefined;
  708. out?: SortableEvent | undefined;
  709. over?: SortableEvent | undefined;
  710. receive?: SortableEvent | undefined;
  711. remove?: SortableEvent | undefined;
  712. sort?: SortableEvent | undefined;
  713. start?: SortableEvent | undefined;
  714. stop?: SortableEvent | undefined;
  715. update?: SortableEvent | undefined;
  716. }
  717. interface Sortable extends Widget, SortableOptions, SortableEvents {
  718. }
  719. // Spinner //////////////////////////////////////////////////
  720. interface SpinnerOptions extends SpinnerEvents {
  721. culture?: string | undefined;
  722. disabled?: boolean | undefined;
  723. icons?: any;
  724. incremental?: any; // boolean or ()
  725. max?: any; // number or string
  726. min?: any; // number or string
  727. numberFormat?: string | undefined;
  728. page?: number | undefined;
  729. step?: any; // number or string
  730. }
  731. interface SpinnerUIParam {
  732. value: number;
  733. }
  734. interface SpinnerEvent<T> {
  735. (event: JQueryEventObject, ui: T): void;
  736. }
  737. interface SpinnerEvents {
  738. change?: SpinnerEvent<{}> | undefined;
  739. create?: SpinnerEvent<{}> | undefined;
  740. spin?: SpinnerEvent<SpinnerUIParam> | undefined;
  741. start?: SpinnerEvent<{}> | undefined;
  742. stop?: SpinnerEvent<{}> | undefined;
  743. }
  744. interface Spinner extends Widget, SpinnerOptions {
  745. }
  746. // Tabs //////////////////////////////////////////////////
  747. interface TabsOptions extends TabsEvents {
  748. active?: any; // boolean or number
  749. classes?: TabClasses | undefined;
  750. collapsible?: boolean | undefined;
  751. disabled?: any; // boolean or []
  752. event?: string | undefined;
  753. heightStyle?: string | undefined;
  754. hide?: any; // boolean, number, string or object
  755. show?: any; // boolean, number, string or object
  756. }
  757. interface TabClasses {
  758. "ui-tabs"?: string | undefined;
  759. "ui-tabs-collapsible"?: string | undefined;
  760. "ui-tabs-nav"?: string | undefined;
  761. "ui-tabs-tab"?: string | undefined;
  762. "ui-tabs-active"?: string | undefined;
  763. "ui-tabs-loading"?: string | undefined;
  764. "ui-tabs-anchor"?: string | undefined;
  765. "ui-tabs-panel"?: string | undefined;
  766. }
  767. interface TabsActivationUIParams {
  768. newTab: JQuery;
  769. oldTab: JQuery;
  770. newPanel: JQuery;
  771. oldPanel: JQuery;
  772. }
  773. interface TabsBeforeLoadUIParams {
  774. tab: JQuery;
  775. panel: JQuery;
  776. jqXHR: JQueryXHR;
  777. ajaxSettings: any;
  778. }
  779. interface TabsCreateOrLoadUIParams {
  780. tab: JQuery;
  781. panel: JQuery;
  782. }
  783. interface TabsEvent<UI> {
  784. (event: JQueryEventObject, ui: UI): void;
  785. }
  786. interface TabsEvents {
  787. activate?: TabsEvent<TabsActivationUIParams> | undefined;
  788. beforeActivate?: TabsEvent<TabsActivationUIParams> | undefined;
  789. beforeLoad?: TabsEvent<TabsBeforeLoadUIParams> | undefined;
  790. load?: TabsEvent<TabsCreateOrLoadUIParams> | undefined;
  791. create?: TabsEvent<TabsCreateOrLoadUIParams> | undefined;
  792. }
  793. interface Tabs extends Widget, TabsOptions {
  794. }
  795. // Tooltip //////////////////////////////////////////////////
  796. interface TooltipOptions extends TooltipEvents {
  797. content?: any; // () or string
  798. disabled?: boolean | undefined;
  799. hide?: any; // boolean, number, string or object
  800. items?: string | JQuery | undefined;
  801. position?: any; // TODO
  802. show?: any; // boolean, number, string or object
  803. tooltipClass?: string | undefined; // deprecated in jQuery UI 1.12
  804. track?: boolean | undefined;
  805. classes?: { [key: string]: string } | undefined;
  806. }
  807. interface TooltipUIParams {
  808. tooltip: JQuery;
  809. }
  810. interface TooltipEvent {
  811. (event: JQueryEventObject, ui: TooltipUIParams): void;
  812. }
  813. interface TooltipEvents {
  814. close?: TooltipEvent | undefined;
  815. open?: TooltipEvent | undefined;
  816. }
  817. interface Tooltip extends Widget, TooltipOptions {
  818. }
  819. // Effects //////////////////////////////////////////////////
  820. interface EffectOptions {
  821. effect: string;
  822. easing?: string | undefined;
  823. duration?: number | undefined;
  824. complete: Function;
  825. }
  826. interface BlindEffect {
  827. direction?: string | undefined;
  828. }
  829. interface BounceEffect {
  830. distance?: number | undefined;
  831. times?: number | undefined;
  832. }
  833. interface ClipEffect {
  834. direction?: number | undefined;
  835. }
  836. interface DropEffect {
  837. direction?: number | undefined;
  838. }
  839. interface ExplodeEffect {
  840. pieces?: number | undefined;
  841. }
  842. interface FadeEffect {}
  843. interface FoldEffect {
  844. size?: any;
  845. horizFirst?: boolean | undefined;
  846. }
  847. interface HighlightEffect {
  848. color?: string | undefined;
  849. }
  850. interface PuffEffect {
  851. percent?: number | undefined;
  852. }
  853. interface PulsateEffect {
  854. times?: number | undefined;
  855. }
  856. interface ScaleEffect {
  857. direction?: string | undefined;
  858. origin?: string[] | undefined;
  859. percent?: number | undefined;
  860. scale?: string | undefined;
  861. }
  862. interface ShakeEffect {
  863. direction?: string | undefined;
  864. distance?: number | undefined;
  865. times?: number | undefined;
  866. }
  867. interface SizeEffect {
  868. to?: any;
  869. origin?: string[] | undefined;
  870. scale?: string | undefined;
  871. }
  872. interface SlideEffect {
  873. direction?: string | undefined;
  874. distance?: number | undefined;
  875. }
  876. interface TransferEffect {
  877. className?: string | undefined;
  878. to?: string | undefined;
  879. }
  880. interface JQueryPositionOptions {
  881. my?: string | undefined;
  882. at?: string | undefined;
  883. of?: any;
  884. collision?: string | undefined;
  885. using?: Function | undefined;
  886. within?: any;
  887. }
  888. // UI //////////////////////////////////////////////////
  889. interface MouseOptions {
  890. cancel?: string | undefined;
  891. delay?: number | undefined;
  892. distance?: number | undefined;
  893. }
  894. interface KeyCode {
  895. BACKSPACE: number;
  896. COMMA: number;
  897. DELETE: number;
  898. DOWN: number;
  899. END: number;
  900. ENTER: number;
  901. ESCAPE: number;
  902. HOME: number;
  903. LEFT: number;
  904. NUMPAD_ADD: number;
  905. NUMPAD_DECIMAL: number;
  906. NUMPAD_DIVIDE: number;
  907. NUMPAD_ENTER: number;
  908. NUMPAD_MULTIPLY: number;
  909. NUMPAD_SUBTRACT: number;
  910. PAGE_DOWN: number;
  911. PAGE_UP: number;
  912. PERIOD: number;
  913. RIGHT: number;
  914. SPACE: number;
  915. TAB: number;
  916. UP: number;
  917. }
  918. interface UI {
  919. mouse(method: string): JQuery;
  920. mouse(options: MouseOptions): JQuery;
  921. mouse(optionLiteral: string, optionName: string, optionValue: any): JQuery;
  922. mouse(optionLiteral: string, optionValue: any): any;
  923. accordion: Accordion;
  924. autocomplete: Autocomplete;
  925. button: Button;
  926. buttonset: Button;
  927. datepicker: Datepicker;
  928. dialog: Dialog;
  929. keyCode: KeyCode;
  930. menu: Menu;
  931. progressbar: Progressbar;
  932. selectmenu: SelectMenu;
  933. slider: Slider;
  934. spinner: Spinner;
  935. tabs: Tabs;
  936. tooltip: Tooltip;
  937. version: string;
  938. }
  939. // Widget //////////////////////////////////////////////////
  940. interface WidgetOptions {
  941. disabled?: boolean | undefined;
  942. hide?: any;
  943. show?: any;
  944. }
  945. interface WidgetCommonProperties {
  946. element: JQuery;
  947. defaultElement: string;
  948. document: Document;
  949. namespace: string;
  950. uuid: string;
  951. widgetEventPrefix: string;
  952. widgetFullName: string;
  953. window: Window;
  954. }
  955. interface Widget {
  956. (methodName: string): JQuery;
  957. (options: WidgetOptions): JQuery;
  958. (options: AccordionOptions): JQuery;
  959. (optionLiteral: string, optionName: string): any;
  960. (optionLiteral: string, options: WidgetOptions): any;
  961. (optionLiteral: string, optionName: string, optionValue: any): JQuery;
  962. <T>(name: string, prototype: T & ThisType<T & WidgetCommonProperties>): JQuery;
  963. <T>(name: string, base: Function, prototype: T & ThisType<T & WidgetCommonProperties>): JQuery;
  964. }
  965. ////////////////////////////////////////////////////////////////////////////////////////////////////
  966. }
  967. interface JQuery {
  968. accordion(): JQuery;
  969. accordion(methodName: "destroy"): void;
  970. accordion(methodName: "disable"): void;
  971. accordion(methodName: "enable"): void;
  972. accordion(methodName: "refresh"): void;
  973. accordion(methodName: "widget"): JQuery;
  974. accordion(methodName: string): JQuery;
  975. accordion(options: JQueryUI.AccordionOptions): JQuery;
  976. accordion(optionLiteral: string, optionName: string): any;
  977. accordion(optionLiteral: string, options: JQueryUI.AccordionOptions): any;
  978. accordion(optionLiteral: string, optionName: string, optionValue: any): JQuery;
  979. autocomplete(): JQuery;
  980. autocomplete(methodName: "close"): void;
  981. autocomplete(methodName: "destroy"): void;
  982. autocomplete(methodName: "disable"): void;
  983. autocomplete(methodName: "enable"): void;
  984. autocomplete(methodName: "search", value?: string): void;
  985. autocomplete(methodName: "widget"): JQuery;
  986. autocomplete(methodName: string): JQuery;
  987. autocomplete(options: JQueryUI.AutocompleteOptions): JQuery;
  988. autocomplete(optionLiteral: string, optionName: string): any;
  989. autocomplete(optionLiteral: string, options: JQueryUI.AutocompleteOptions): any;
  990. autocomplete(optionLiteral: string, optionName: string, optionValue: any): JQuery;
  991. button(): JQuery;
  992. button(methodName: "destroy"): void;
  993. button(methodName: "disable"): void;
  994. button(methodName: "enable"): void;
  995. button(methodName: "refresh"): void;
  996. button(methodName: "widget"): JQuery;
  997. button(methodName: string): JQuery;
  998. button(options: JQueryUI.ButtonOptions): JQuery;
  999. button(optionLiteral: string, optionName: string): any;
  1000. button(optionLiteral: string, options: JQueryUI.ButtonOptions): any;
  1001. button(optionLiteral: string, optionName: string, optionValue: any): JQuery;
  1002. buttonset(): JQuery;
  1003. buttonset(methodName: "destroy"): void;
  1004. buttonset(methodName: "disable"): void;
  1005. buttonset(methodName: "enable"): void;
  1006. buttonset(methodName: "refresh"): void;
  1007. buttonset(methodName: "widget"): JQuery;
  1008. buttonset(methodName: string): JQuery;
  1009. buttonset(options: JQueryUI.ButtonOptions): JQuery;
  1010. buttonset(optionLiteral: string, optionName: string): any;
  1011. buttonset(optionLiteral: string, options: JQueryUI.ButtonOptions): any;
  1012. buttonset(optionLiteral: string, optionName: string, optionValue: any): JQuery;
  1013. /**
  1014. * Initialize a datepicker
  1015. */
  1016. datepicker(): JQuery;
  1017. /**
  1018. * Removes the datepicker functionality completely. This will return the element back to its pre-init state.
  1019. *
  1020. * @param methodName 'destroy'
  1021. */
  1022. datepicker(methodName: "destroy"): JQuery;
  1023. /**
  1024. * Opens the datepicker in a dialog box.
  1025. *
  1026. * @param methodName 'dialog'
  1027. * @param date The initial date.
  1028. * @param onSelect A callback function when a date is selected. The function receives the date text and date picker instance as parameters.
  1029. * @param settings The new settings for the date picker.
  1030. * @param pos The position of the top/left of the dialog as [x, y] or a MouseEvent that contains the coordinates. If not specified the dialog is centered on the screen.
  1031. */
  1032. datepicker(
  1033. methodName: "dialog",
  1034. date: Date,
  1035. onSelect?: () => void,
  1036. settings?: JQueryUI.DatepickerOptions,
  1037. pos?: number[],
  1038. ): JQuery;
  1039. /**
  1040. * Opens the datepicker in a dialog box.
  1041. *
  1042. * @param methodName 'dialog'
  1043. * @param date The initial date.
  1044. * @param onSelect A callback function when a date is selected. The function receives the date text and date picker instance as parameters.
  1045. * @param settings The new settings for the date picker.
  1046. * @param pos The position of the top/left of the dialog as [x, y] or a MouseEvent that contains the coordinates. If not specified the dialog is centered on the screen.
  1047. */
  1048. datepicker(
  1049. methodName: "dialog",
  1050. date: Date,
  1051. onSelect?: () => void,
  1052. settings?: JQueryUI.DatepickerOptions,
  1053. pos?: MouseEvent,
  1054. ): JQuery;
  1055. /**
  1056. * Opens the datepicker in a dialog box.
  1057. *
  1058. * @param methodName 'dialog'
  1059. * @param date The initial date.
  1060. * @param onSelect A callback function when a date is selected. The function receives the date text and date picker instance as parameters.
  1061. * @param settings The new settings for the date picker.
  1062. * @param pos The position of the top/left of the dialog as [x, y] or a MouseEvent that contains the coordinates. If not specified the dialog is centered on the screen.
  1063. */
  1064. datepicker(
  1065. methodName: "dialog",
  1066. date: string,
  1067. onSelect?: () => void,
  1068. settings?: JQueryUI.DatepickerOptions,
  1069. pos?: number[],
  1070. ): JQuery;
  1071. /**
  1072. * Opens the datepicker in a dialog box.
  1073. *
  1074. * @param methodName 'dialog'
  1075. * @param date The initial date.
  1076. * @param onSelect A callback function when a date is selected. The function receives the date text and date picker instance as parameters.
  1077. * @param settings The new settings for the date picker.
  1078. * @param pos The position of the top/left of the dialog as [x, y] or a MouseEvent that contains the coordinates. If not specified the dialog is centered on the screen.
  1079. */
  1080. datepicker(
  1081. methodName: "dialog",
  1082. date: string,
  1083. onSelect?: () => void,
  1084. settings?: JQueryUI.DatepickerOptions,
  1085. pos?: MouseEvent,
  1086. ): JQuery;
  1087. /**
  1088. * Returns the current date for the datepicker or null if no date has been selected.
  1089. *
  1090. * @param methodName 'getDate'
  1091. */
  1092. datepicker(methodName: "getDate"): Date;
  1093. /**
  1094. * Close a previously opened date picker.
  1095. *
  1096. * @param methodName 'hide'
  1097. */
  1098. datepicker(methodName: "hide"): JQuery;
  1099. /**
  1100. * Determine whether a date picker has been disabled.
  1101. *
  1102. * @param methodName 'isDisabled'
  1103. */
  1104. datepicker(methodName: "isDisabled"): boolean;
  1105. /**
  1106. * Redraw the date picker, after having made some external modifications.
  1107. *
  1108. * @param methodName 'refresh'
  1109. */
  1110. datepicker(methodName: "refresh"): JQuery;
  1111. /**
  1112. * Sets the date for the datepicker. The new date may be a Date object or a string in the current date format (e.g., "01/26/2009"), a number of days from today (e.g., +7) or a string of values and periods ("y" for years, "m" for months, "w" for weeks, "d" for days, e.g., "+1m +7d"), or null to clear the selected date.
  1113. *
  1114. * @param methodName 'setDate'
  1115. * @param date The new date.
  1116. */
  1117. datepicker(methodName: "setDate", date: Date): JQuery;
  1118. /**
  1119. * Sets the date for the datepicker. The new date may be a Date object or a string in the current date format (e.g., "01/26/2009"), a number of days from today (e.g., +7) or a string of values and periods ("y" for years, "m" for months, "w" for weeks, "d" for days, e.g., "+1m +7d"), or null to clear the selected date.
  1120. *
  1121. * @param methodName 'setDate'
  1122. * @param date The new date.
  1123. */
  1124. datepicker(methodName: "setDate", date: string): JQuery;
  1125. /**
  1126. * Open the date picker. If the datepicker is attached to an input, the input must be visible for the datepicker to be shown.
  1127. *
  1128. * @param methodName 'show'
  1129. */
  1130. datepicker(methodName: "show"): JQuery;
  1131. /**
  1132. * Returns a jQuery object containing the datepicker.
  1133. *
  1134. * @param methodName 'widget'
  1135. */
  1136. datepicker(methodName: "widget"): JQuery;
  1137. /**
  1138. * Get the altField option, after initialization
  1139. *
  1140. * @param methodName 'option'
  1141. * @param optionName 'altField'
  1142. */
  1143. datepicker(methodName: "option", optionName: "altField"): any;
  1144. /**
  1145. * Set the altField option, after initialization
  1146. *
  1147. * @param methodName 'option'
  1148. * @param optionName 'altField'
  1149. * @param altFieldValue An input element that is to be updated with the selected date from the datepicker. Use the altFormat option to change the format of the date within this field. Leave as blank for no alternate field.
  1150. */
  1151. datepicker(methodName: "option", optionName: "altField", altFieldValue: string): JQuery;
  1152. /**
  1153. * Set the altField option, after initialization
  1154. *
  1155. * @param methodName 'option'
  1156. * @param optionName 'altField'
  1157. * @param altFieldValue An input element that is to be updated with the selected date from the datepicker. Use the altFormat option to change the format of the date within this field. Leave as blank for no alternate field.
  1158. */
  1159. datepicker(methodName: "option", optionName: "altField", altFieldValue: JQuery): JQuery;
  1160. /**
  1161. * Set the altField option, after initialization
  1162. *
  1163. * @param methodName 'option'
  1164. * @param optionName 'altField'
  1165. * @param altFieldValue An input element that is to be updated with the selected date from the datepicker. Use the altFormat option to change the format of the date within this field. Leave as blank for no alternate field.
  1166. */
  1167. datepicker(methodName: "option", optionName: "altField", altFieldValue: Element): JQuery;
  1168. /**
  1169. * Get the altFormat option, after initialization
  1170. *
  1171. * @param methodName 'option'
  1172. * @param optionName 'altFormat'
  1173. */
  1174. datepicker(methodName: "option", optionName: "altFormat"): string;
  1175. /**
  1176. * Set the altFormat option, after initialization
  1177. *
  1178. * @param methodName 'option'
  1179. * @param optionName 'altFormat'
  1180. * @param altFormatValue The dateFormat to be used for the altField option. This allows one date format to be shown to the user for selection purposes, while a different format is actually sent behind the scenes. For a full list of the possible formats see the formatDate function
  1181. */
  1182. datepicker(methodName: "option", optionName: "altFormat", altFormatValue: string): JQuery;
  1183. /**
  1184. * Get the appendText option, after initialization
  1185. *
  1186. * @param methodName 'option'
  1187. * @param optionName 'appendText'
  1188. */
  1189. datepicker(methodName: "option", optionName: "appendText"): string;
  1190. /**
  1191. * Set the appendText option, after initialization
  1192. *
  1193. * @param methodName 'option'
  1194. * @param optionName 'appendText'
  1195. * @param appendTextValue The text to display after each date field, e.g., to show the required format.
  1196. */
  1197. datepicker(methodName: "option", optionName: "appendText", appendTextValue: string): JQuery;
  1198. /**
  1199. * Get the autoSize option, after initialization
  1200. *
  1201. * @param methodName 'option'
  1202. * @param optionName 'autoSize'
  1203. */
  1204. datepicker(methodName: "option", optionName: "autoSize"): boolean;
  1205. /**
  1206. * Set the autoSize option, after initialization
  1207. *
  1208. * @param methodName 'option'
  1209. * @param optionName 'autoSize'
  1210. * @param autoSizeValue Set to true to automatically resize the input field to accommodate dates in the current dateFormat.
  1211. */
  1212. datepicker(methodName: "option", optionName: "autoSize", autoSizeValue: boolean): JQuery;
  1213. /**
  1214. * Get the beforeShow option, after initialization
  1215. *
  1216. * @param methodName 'option'
  1217. * @param optionName 'beforeShow'
  1218. */
  1219. datepicker(
  1220. methodName: "option",
  1221. optionName: "beforeShow",
  1222. ): (input: Element, inst: any) => JQueryUI.DatepickerOptions;
  1223. /**
  1224. * Set the beforeShow option, after initialization
  1225. *
  1226. * @param methodName 'option'
  1227. * @param optionName 'beforeShow'
  1228. * @param beforeShowValue A function that takes an input field and current datepicker instance and returns an options object to update the datepicker with. It is called just before the datepicker is displayed.
  1229. */
  1230. datepicker(
  1231. methodName: "option",
  1232. optionName: "beforeShow",
  1233. beforeShowValue: (input: Element, inst: any) => JQueryUI.DatepickerOptions,
  1234. ): JQuery;
  1235. /**
  1236. * Get the beforeShow option, after initialization
  1237. *
  1238. * @param methodName 'option'
  1239. * @param optionName 'beforeShowDay'
  1240. */
  1241. datepicker(methodName: "option", optionName: "beforeShowDay"): (date: Date) => any[];
  1242. /**
  1243. * Set the beforeShow option, after initialization
  1244. *
  1245. * @param methodName 'option'
  1246. * @param optionName 'beforeShowDay'
  1247. * @param beforeShowDayValue A function that takes a date as a parameter and must return an array with:
  1248. * [0]: true/false indicating whether or not this date is selectable
  1249. * [1]: a CSS class name to add to the date's cell or "" for the default presentation
  1250. * [2]: an optional popup tooltip for this date
  1251. * The function is called for each day in the datepicker before it is displayed.
  1252. */
  1253. datepicker(methodName: "option", optionName: "beforeShowDay", beforeShowDayValue: (date: Date) => any[]): JQuery;
  1254. /**
  1255. * Get the buttonImage option, after initialization
  1256. *
  1257. * @param methodName 'option'
  1258. * @param optionName 'buttonImage'
  1259. */
  1260. datepicker(methodName: "option", optionName: "buttonImage"): string;
  1261. /**
  1262. * Set the buttonImage option, after initialization
  1263. *
  1264. * @param methodName 'option'
  1265. * @param optionName 'buttonImage'
  1266. * @param buttonImageValue A URL of an image to use to display the datepicker when the showOn option is set to "button" or "both". If set, the buttonText option becomes the alt value and is not directly displayed.
  1267. */
  1268. datepicker(methodName: "option", optionName: "buttonImage", buttonImageValue: string): JQuery;
  1269. /**
  1270. * Get the buttonImageOnly option, after initialization
  1271. *
  1272. * @param methodName 'option'
  1273. * @param optionName 'buttonImageOnly'
  1274. */
  1275. datepicker(methodName: "option", optionName: "buttonImageOnly"): boolean;
  1276. /**
  1277. * Set the buttonImageOnly option, after initialization
  1278. *
  1279. * @param methodName 'option'
  1280. * @param optionName 'buttonImageOnly'
  1281. * @param buttonImageOnlyValue Whether the button image should be rendered by itself instead of inside a button element. This option is only relevant if the buttonImage option has also been set.
  1282. */
  1283. datepicker(methodName: "option", optionName: "buttonImageOnly", buttonImageOnlyValue: boolean): JQuery;
  1284. /**
  1285. * Get the buttonText option, after initialization
  1286. *
  1287. * @param methodName 'option'
  1288. * @param optionName 'buttonText'
  1289. */
  1290. datepicker(methodName: "option", optionName: "buttonText"): string;
  1291. /**
  1292. * Get the autohide option, after initialization
  1293. *
  1294. * @param methodName 'option'
  1295. * @param optionName 'autohide'
  1296. */
  1297. datepicker(methodName: "option", optionName: "autohide"): boolean;
  1298. /**
  1299. * Get the endDate after initialization
  1300. *
  1301. * @param methodName 'option'
  1302. * @param optionName 'endDate'
  1303. */
  1304. datepicker(methodName: "option", optionName: "endDate"): Date;
  1305. /**
  1306. * Set the buttonText option, after initialization
  1307. *
  1308. * @param methodName 'option'
  1309. * @param optionName 'buttonText'
  1310. * @param buttonTextValue The text to display on the trigger button. Use in conjunction with the showOn option set to "button" or "both".
  1311. */
  1312. datepicker(methodName: "option", optionName: "buttonText", buttonTextValue: string): JQuery;
  1313. /**
  1314. * Get the calculateWeek option, after initialization
  1315. *
  1316. * @param methodName 'option'
  1317. * @param optionName 'calculateWeek'
  1318. */
  1319. datepicker(methodName: "option", optionName: "calculateWeek"): (date: Date) => string;
  1320. /**
  1321. * Set the calculateWeek option, after initialization
  1322. *
  1323. * @param methodName 'option'
  1324. * @param optionName 'calculateWeek'
  1325. * @param calculateWeekValue A function to calculate the week of the year for a given date. The default implementation uses the ISO 8601 definition: weeks start on a Monday; the first week of the year contains the first Thursday of the year.
  1326. */
  1327. datepicker(methodName: "option", optionName: "calculateWeek", calculateWeekValue: (date: Date) => string): JQuery;
  1328. /**
  1329. * Get the changeMonth option, after initialization
  1330. *
  1331. * @param methodName 'option'
  1332. * @param optionName 'changeMonth'
  1333. */
  1334. datepicker(methodName: "option", optionName: "changeMonth"): boolean;
  1335. /**
  1336. * Set the changeMonth option, after initialization
  1337. *
  1338. * @param methodName 'option'
  1339. * @param optionName 'changeMonth'
  1340. * @param changeMonthValue Whether the month should be rendered as a dropdown instead of text.
  1341. */
  1342. datepicker(methodName: "option", optionName: "changeMonth", changeMonthValue: boolean): JQuery;
  1343. /**
  1344. * Get the changeYear option, after initialization
  1345. *
  1346. * @param methodName 'option'
  1347. * @param optionName 'changeYear'
  1348. */
  1349. datepicker(methodName: "option", optionName: "changeYear"): boolean;
  1350. /**
  1351. * Set the changeYear option, after initialization
  1352. *
  1353. * @param methodName 'option'
  1354. * @param optionName 'changeYear'
  1355. * @param changeYearValue Whether the year should be rendered as a dropdown instead of text. Use the yearRange option to control which years are made available for selection.
  1356. */
  1357. datepicker(methodName: "option", optionName: "changeYear", changeYearValue: boolean): JQuery;
  1358. /**
  1359. * Get the closeText option, after initialization
  1360. *
  1361. * @param methodName 'option'
  1362. * @param optionName 'closeText'
  1363. */
  1364. datepicker(methodName: "option", optionName: "closeText"): string;
  1365. /**
  1366. * Set the closeText option, after initialization
  1367. *
  1368. * @param methodName 'option'
  1369. * @param optionName 'closeText'
  1370. * @param closeTextValue The text to display for the close link. Use the showButtonPanel option to display this button.
  1371. */
  1372. datepicker(methodName: "option", optionName: "closeText", closeTextValue: string): JQuery;
  1373. /**
  1374. * Get the constrainInput option, after initialization
  1375. *
  1376. * @param methodName 'option'
  1377. * @param optionName 'constrainInput'
  1378. */
  1379. datepicker(methodName: "option", optionName: "constrainInput"): boolean;
  1380. /**
  1381. * Set the constrainInput option, after initialization
  1382. *
  1383. * @param methodName 'option'
  1384. * @param optionName 'constrainInput'
  1385. * @param constrainInputValue When true, entry in the input field is constrained to those characters allowed by the current dateFormat option.
  1386. */
  1387. datepicker(methodName: "option", optionName: "constrainInput", constrainInputValue: boolean): JQuery;
  1388. /**
  1389. * Get the currentText option, after initialization
  1390. *
  1391. * @param methodName 'option'
  1392. * @param optionName 'currentText'
  1393. */
  1394. datepicker(methodName: "option", optionName: "currentText"): string;
  1395. /**
  1396. * Set the currentText option, after initialization
  1397. *
  1398. * @param methodName 'option'
  1399. * @param optionName 'currentText'
  1400. * @param currentTextValue The text to display for the current day link. Use the showButtonPanel option to display this button.
  1401. */
  1402. datepicker(methodName: "option", optionName: "currentText", currentTextValue: string): JQuery;
  1403. /**
  1404. * Get the dateFormat option, after initialization
  1405. *
  1406. * @param methodName 'option'
  1407. * @param optionName 'dateFormat'
  1408. */
  1409. datepicker(methodName: "option", optionName: "dateFormat"): string;
  1410. /**
  1411. * Set the dateFormat option, after initialization
  1412. *
  1413. * @param methodName 'option'
  1414. * @param optionName 'dateFormat'
  1415. * @param dateFormatValue The format for parsed and displayed dates. For a full list of the possible formats see the formatDate function.
  1416. */
  1417. datepicker(methodName: "option", optionName: "dateFormat", dateFormatValue: string): JQuery;
  1418. /**
  1419. * Get the dayNames option, after initialization
  1420. *
  1421. * @param methodName 'option'
  1422. * @param optionName 'dayNames'
  1423. */
  1424. datepicker(methodName: "option", optionName: "dayNames"): string[];
  1425. /**
  1426. * Set the dayNames option, after initialization
  1427. *
  1428. * @param methodName 'option'
  1429. * @param optionName 'dayNames'
  1430. * @param dayNamesValue The list of long day names, starting from Sunday, for use as requested via the dateFormat option.
  1431. */
  1432. datepicker(methodName: "option", optionName: "dayNames", dayNamesValue: string[]): JQuery;
  1433. /**
  1434. * Get the dayNamesMin option, after initialization
  1435. *
  1436. * @param methodName 'option'
  1437. * @param optionName 'dayNamesMin'
  1438. */
  1439. datepicker(methodName: "option", optionName: "dayNamesMin"): string[];
  1440. /**
  1441. * Set the dayNamesMin option, after initialization
  1442. *
  1443. * @param methodName 'option'
  1444. * @param optionName 'dayNamesMin'
  1445. * @param dayNamesMinValue The list of minimised day names, starting from Sunday, for use as column headers within the datepicker.
  1446. */
  1447. datepicker(methodName: "option", optionName: "dayNamesMin", dayNamesMinValue: string[]): JQuery;
  1448. /**
  1449. * Get the dayNamesShort option, after initialization
  1450. *
  1451. * @param methodName 'option'
  1452. * @param optionName 'dayNamesShort'
  1453. */
  1454. datepicker(methodName: "option", optionName: "dayNamesShort"): string[];
  1455. /**
  1456. * Set the dayNamesShort option, after initialization
  1457. *
  1458. * @param methodName 'option'
  1459. * @param optionName 'dayNamesShort'
  1460. * @param dayNamesShortValue The list of abbreviated day names, starting from Sunday, for use as requested via the dateFormat option.
  1461. */
  1462. datepicker(methodName: "option", optionName: "dayNamesShort", dayNamesShortValue: string[]): JQuery;
  1463. /**
  1464. * Get the defaultDate option, after initialization
  1465. *
  1466. * @param methodName 'option'
  1467. * @param optionName 'defaultDate'
  1468. */
  1469. datepicker(methodName: "option", optionName: "defaultDate"): any;
  1470. /**
  1471. * Set the defaultDate option, after initialization
  1472. *
  1473. * @param methodName 'option'
  1474. * @param optionName 'defaultDate'
  1475. * @param defaultDateValue A date object containing the default date.
  1476. */
  1477. datepicker(methodName: "option", optionName: "defaultDate", defaultDateValue: Date): JQuery;
  1478. /**
  1479. * Set the defaultDate option, after initialization
  1480. *
  1481. * @param methodName 'option'
  1482. * @param optionName 'defaultDate'
  1483. * @param defaultDateValue A number of days from today. For example 2 represents two days from today and -1 represents yesterday.
  1484. */
  1485. datepicker(methodName: "option", optionName: "defaultDate", defaultDateValue: number): JQuery;
  1486. /**
  1487. * Set the defaultDate option, after initialization
  1488. *
  1489. * @param methodName 'option'
  1490. * @param optionName 'defaultDate'
  1491. * @param defaultDateValue A string in the format defined by the dateFormat option, or a relative date. Relative dates must contain value and period pairs; valid periods are "y" for years, "m" for months, "w" for weeks, and "d" for days. For example, "+1m +7d" represents one month and seven days from today.
  1492. */
  1493. datepicker(methodName: "option", optionName: "defaultDate", defaultDateValue: string): JQuery;
  1494. /**
  1495. * Get the duration option, after initialization
  1496. *
  1497. * @param methodName 'option'
  1498. * @param optionName 'duration'
  1499. */
  1500. datepicker(methodName: "option", optionName: "duration"): string;
  1501. /**
  1502. * Set the duration option, after initialization
  1503. *
  1504. * @param methodName 'option'
  1505. * @param optionName 'duration'
  1506. * @param durationValue Control the speed at which the datepicker appears, it may be a time in milliseconds or a string representing one of the three predefined speeds ("slow", "normal", "fast").
  1507. */
  1508. datepicker(methodName: "option", optionName: "duration", durationValue: string): JQuery;
  1509. /**
  1510. * Get the firstDay option, after initialization
  1511. *
  1512. * @param methodName 'option'
  1513. * @param optionName 'firstDay'
  1514. */
  1515. datepicker(methodName: "option", optionName: "firstDay"): number;
  1516. /**
  1517. * Set the firstDay option, after initialization
  1518. *
  1519. * @param methodName 'option'
  1520. * @param optionName 'firstDay'
  1521. * @param firstDayValue Set the first day of the week: Sunday is 0, Monday is 1, etc.
  1522. */
  1523. datepicker(methodName: "option", optionName: "firstDay", firstDayValue: number): JQuery;
  1524. /**
  1525. * Get the gotoCurrent option, after initialization
  1526. *
  1527. * @param methodName 'option'
  1528. * @param optionName 'gotoCurrent'
  1529. */
  1530. datepicker(methodName: "option", optionName: "gotoCurrent"): boolean;
  1531. /**
  1532. * Set the gotoCurrent option, after initialization
  1533. *
  1534. * @param methodName 'option'
  1535. * @param optionName 'gotoCurrent'
  1536. * @param gotoCurrentValue When true, the current day link moves to the currently selected date instead of today.
  1537. */
  1538. datepicker(methodName: "option", optionName: "gotoCurrent", gotoCurrentValue: boolean): JQuery;
  1539. /**
  1540. * Gets the value currently associated with the specified optionName.
  1541. *
  1542. * @param methodName 'option'
  1543. * @param optionName The name of the option to get.
  1544. */
  1545. datepicker(methodName: "option", optionName: string): any;
  1546. datepicker(methodName: "option", optionName: string, ...otherParams: any[]): any; // Used for getting and setting options
  1547. datepicker(methodName: string, ...otherParams: any[]): any;
  1548. /**
  1549. * Initialize a datepicker with the given options
  1550. */
  1551. datepicker(options: JQueryUI.DatepickerOptions): JQuery;
  1552. dialog(): JQuery;
  1553. dialog(methodName: "close"): JQuery;
  1554. dialog(methodName: "destroy"): JQuery;
  1555. dialog(methodName: "isOpen"): boolean;
  1556. dialog(methodName: "moveToTop"): JQuery;
  1557. dialog(methodName: "open"): JQuery;
  1558. dialog(methodName: "widget"): JQuery;
  1559. dialog(methodName: string): JQuery;
  1560. dialog(options: JQueryUI.DialogOptions): JQuery;
  1561. dialog(optionLiteral: string, optionName: string): any;
  1562. dialog(optionLiteral: string, options: JQueryUI.DialogOptions): any;
  1563. dialog(optionLiteral: string, optionName: string, optionValue: any): JQuery;
  1564. draggable(): JQuery;
  1565. draggable(methodName: "destroy"): void;
  1566. draggable(methodName: "disable"): void;
  1567. draggable(methodName: "enable"): void;
  1568. draggable(methodName: "widget"): JQuery;
  1569. draggable(methodName: string): JQuery;
  1570. draggable(options: JQueryUI.DraggableOptions): JQuery;
  1571. draggable(optionLiteral: string, optionName: string): any;
  1572. draggable(optionLiteral: string, options: JQueryUI.DraggableOptions): any;
  1573. draggable(optionLiteral: string, optionName: string, optionValue: any): JQuery;
  1574. droppable(): JQuery;
  1575. droppable(methodName: "destroy"): void;
  1576. droppable(methodName: "disable"): void;
  1577. droppable(methodName: "enable"): void;
  1578. droppable(methodName: "widget"): JQuery;
  1579. droppable(methodName: string): JQuery;
  1580. droppable(options: JQueryUI.DroppableOptions): JQuery;
  1581. droppable(optionLiteral: string, optionName: string): any;
  1582. droppable(optionLiteral: string, options: JQueryUI.DraggableOptions): any;
  1583. droppable(optionLiteral: string, optionName: string, optionValue: any): JQuery;
  1584. menu: {
  1585. (): JQuery;
  1586. (methodName: "blur"): void;
  1587. (methodName: "collapse", event?: JQueryEventObject): void;
  1588. (methodName: "collapseAll", event?: JQueryEventObject, all?: boolean): void;
  1589. (methodName: "destroy"): void;
  1590. (methodName: "disable"): void;
  1591. (methodName: "enable"): void;
  1592. (methodName: string, event: JQueryEventObject, item: JQuery): void;
  1593. (methodName: "focus", event: JQueryEventObject, item: JQuery): void;
  1594. (methodName: "isFirstItem"): boolean;
  1595. (methodName: "isLastItem"): boolean;
  1596. (methodName: "next", event?: JQueryEventObject): void;
  1597. (methodName: "nextPage", event?: JQueryEventObject): void;
  1598. (methodName: "previous", event?: JQueryEventObject): void;
  1599. (methodName: "previousPage", event?: JQueryEventObject): void;
  1600. (methodName: "refresh"): void;
  1601. (methodName: "select", event?: JQueryEventObject): void;
  1602. (methodName: "widget"): JQuery;
  1603. (methodName: string): JQuery;
  1604. (options: JQueryUI.MenuOptions): JQuery;
  1605. (optionLiteral: string, optionName: string): any;
  1606. (optionLiteral: string, options: JQueryUI.MenuOptions): any;
  1607. (optionLiteral: string, optionName: string, optionValue: any): JQuery;
  1608. active: boolean;
  1609. };
  1610. progressbar(): JQuery;
  1611. progressbar(methodName: "destroy"): void;
  1612. progressbar(methodName: "disable"): void;
  1613. progressbar(methodName: "enable"): void;
  1614. progressbar(methodName: "refresh"): void;
  1615. progressbar(methodName: "value"): any; // number or boolean
  1616. progressbar(methodName: "value", value: number): void;
  1617. progressbar(methodName: "value", value: boolean): void;
  1618. progressbar(methodName: "widget"): JQuery;
  1619. progressbar(methodName: string): JQuery;
  1620. progressbar(options: JQueryUI.ProgressbarOptions): JQuery;
  1621. progressbar(optionLiteral: string, optionName: string): any;
  1622. progressbar(optionLiteral: string, options: JQueryUI.ProgressbarOptions): any;
  1623. progressbar(optionLiteral: string, optionName: string, optionValue: any): JQuery;
  1624. resizable(): JQuery;
  1625. resizable(methodName: "destroy"): void;
  1626. resizable(methodName: "disable"): void;
  1627. resizable(methodName: "enable"): void;
  1628. resizable(methodName: "widget"): JQuery;
  1629. resizable(methodName: string): JQuery;
  1630. resizable(options: JQueryUI.ResizableOptions): JQuery;
  1631. resizable(optionLiteral: string, optionName: string): any;
  1632. resizable(optionLiteral: string, options: JQueryUI.ResizableOptions): any;
  1633. resizable(optionLiteral: string, optionName: string, optionValue: any): JQuery;
  1634. selectable(): JQuery;
  1635. selectable(methodName: "destroy"): void;
  1636. selectable(methodName: "disable"): void;
  1637. selectable(methodName: "enable"): void;
  1638. selectable(methodName: "widget"): JQuery;
  1639. selectable(methodName: string): JQuery;
  1640. selectable(options: JQueryUI.SelectableOptions): JQuery;
  1641. selectable(optionLiteral: string, optionName: string): any;
  1642. selectable(optionLiteral: string, options: JQueryUI.SelectableOptions): any;
  1643. selectable(optionLiteral: string, optionName: string, optionValue: any): JQuery;
  1644. selectmenu(): JQuery;
  1645. selectmenu(methodName: "close"): JQuery;
  1646. selectmenu(methodName: "destroy"): JQuery;
  1647. selectmenu(methodName: "disable"): JQuery;
  1648. selectmenu(methodName: "enable"): JQuery;
  1649. selectmenu(methodName: "instance"): any;
  1650. selectmenu(methodName: "menuWidget"): JQuery;
  1651. selectmenu(methodName: "open"): JQuery;
  1652. selectmenu(methodName: "refresh"): JQuery;
  1653. selectmenu(methodName: "widget"): JQuery;
  1654. selectmenu(methodName: string): JQuery;
  1655. selectmenu(options: JQueryUI.SelectMenuOptions): JQuery;
  1656. selectmenu(optionLiteral: string, optionName: string): any;
  1657. selectmenu(optionLiteral: string, options: JQueryUI.SelectMenuOptions): any;
  1658. selectmenu(optionLiteral: string, optionName: string, optionValue: any): JQuery;
  1659. slider(): JQuery;
  1660. slider(methodName: "destroy"): void;
  1661. slider(methodName: "disable"): void;
  1662. slider(methodName: "enable"): void;
  1663. slider(methodName: "refresh"): void;
  1664. slider(methodName: "value"): number;
  1665. slider(methodName: "value", value: number): void;
  1666. slider(methodName: "values"): number[];
  1667. slider(methodName: "values", index: number): number;
  1668. slider(methodName: string, index: number, value: number): void;
  1669. slider(methodName: "values", index: number, value: number): void;
  1670. slider(methodName: string, values: number[]): void;
  1671. slider(methodName: "values", values: number[]): void;
  1672. slider(methodName: "widget"): JQuery;
  1673. slider(methodName: string): JQuery;
  1674. slider(options: JQueryUI.SliderOptions): JQuery;
  1675. slider(optionLiteral: string, optionName: string): any;
  1676. slider(optionLiteral: string, options: JQueryUI.SliderOptions): any;
  1677. slider(optionLiteral: string, optionName: string, optionValue: any): JQuery;
  1678. sortable(): JQuery;
  1679. sortable(methodName: "destroy"): void;
  1680. sortable(methodName: "disable"): void;
  1681. sortable(methodName: "enable"): void;
  1682. sortable(methodName: "widget"): JQuery;
  1683. sortable(methodName: "toArray", options?: { attribute?: string | undefined }): string[];
  1684. sortable(methodName: string): JQuery;
  1685. sortable(options: JQueryUI.SortableOptions): JQuery;
  1686. sortable(optionLiteral: string, optionName: string): any;
  1687. sortable(
  1688. methodName: "serialize",
  1689. options?: { key?: string | undefined; attribute?: string | undefined; expression?: RegExp | undefined },
  1690. ): string;
  1691. sortable(optionLiteral: string, options: JQueryUI.SortableOptions): any;
  1692. sortable(optionLiteral: string, optionName: string, optionValue: any): JQuery;
  1693. spinner(): JQuery;
  1694. spinner(methodName: "destroy"): void;
  1695. spinner(methodName: "disable"): void;
  1696. spinner(methodName: "enable"): void;
  1697. spinner(methodName: "pageDown", pages?: number): void;
  1698. spinner(methodName: "pageUp", pages?: number): void;
  1699. spinner(methodName: "stepDown", steps?: number): void;
  1700. spinner(methodName: "stepUp", steps?: number): void;
  1701. spinner(methodName: "value"): number;
  1702. spinner(methodName: "value", value: number): void;
  1703. spinner(methodName: "widget"): JQuery;
  1704. spinner(methodName: string): JQuery;
  1705. spinner(options: JQueryUI.SpinnerOptions): JQuery;
  1706. spinner(optionLiteral: string, optionName: string): any;
  1707. spinner(optionLiteral: string, options: JQueryUI.SpinnerOptions): any;
  1708. spinner(optionLiteral: string, optionName: string, optionValue: any): JQuery;
  1709. tabs(): JQuery;
  1710. tabs(methodName: "destroy"): void;
  1711. tabs(methodName: "disable"): void;
  1712. tabs(methodName: "disable", index: number): void;
  1713. tabs(methodName: "enable"): void;
  1714. tabs(methodName: "enable", index: number): void;
  1715. tabs(methodName: "load", index: number): void;
  1716. tabs(methodName: "refresh"): void;
  1717. tabs(methodName: "widget"): JQuery;
  1718. tabs(methodName: "select", index: number): JQuery;
  1719. tabs(methodName: string): JQuery;
  1720. tabs(options: JQueryUI.TabsOptions): JQuery;
  1721. tabs(optionLiteral: string, optionName: string): any;
  1722. tabs(optionLiteral: string, options: JQueryUI.TabsOptions): any;
  1723. tabs(optionLiteral: string, optionName: string, optionValue: any): JQuery;
  1724. tooltip(): JQuery;
  1725. tooltip(methodName: "destroy"): void;
  1726. tooltip(methodName: "disable"): void;
  1727. tooltip(methodName: "enable"): void;
  1728. tooltip(methodName: "open"): void;
  1729. tooltip(methodName: "close"): void;
  1730. tooltip(methodName: "widget"): JQuery;
  1731. tooltip(methodName: string): JQuery;
  1732. tooltip(options: JQueryUI.TooltipOptions): JQuery;
  1733. tooltip(optionLiteral: string, optionName: string): any;
  1734. tooltip(optionLiteral: string, options: JQueryUI.TooltipOptions): any;
  1735. tooltip(optionLiteral: string, optionName: string, optionValue: any): JQuery;
  1736. addClass(classNames: string, speed?: number, callback?: Function): this;
  1737. addClass(classNames: string, speed?: string, callback?: Function): this;
  1738. addClass(classNames: string, speed?: number, easing?: string, callback?: Function): this;
  1739. addClass(classNames: string, speed?: string, easing?: string, callback?: Function): this;
  1740. removeClass(classNames: string, speed?: number, callback?: Function): this;
  1741. removeClass(classNames: string, speed?: string, callback?: Function): this;
  1742. removeClass(classNames: string, speed?: number, easing?: string, callback?: Function): this;
  1743. removeClass(classNames: string, speed?: string, easing?: string, callback?: Function): this;
  1744. switchClass(
  1745. removeClassName: string,
  1746. addClassName: string,
  1747. duration?: number,
  1748. easing?: string,
  1749. complete?: Function,
  1750. ): this;
  1751. switchClass(
  1752. removeClassName: string,
  1753. addClassName: string,
  1754. duration?: string,
  1755. easing?: string,
  1756. complete?: Function,
  1757. ): this;
  1758. toggleClass(className: string, duration?: number, easing?: string, complete?: Function): this;
  1759. toggleClass(className: string, duration?: string, easing?: string, complete?: Function): this;
  1760. toggleClass(className: string, aswitch?: boolean, duration?: number, easing?: string, complete?: Function): this;
  1761. toggleClass(className: string, aswitch?: boolean, duration?: string, easing?: string, complete?: Function): this;
  1762. effect(options: any): this;
  1763. effect(effect: string, options?: any, duration?: number, complete?: Function): this;
  1764. effect(effect: string, options?: any, duration?: string, complete?: Function): this;
  1765. hide(options: any): this;
  1766. hide(effect: string, options?: any, duration?: number, complete?: Function): this;
  1767. hide(effect: string, options?: any, duration?: string, complete?: Function): this;
  1768. show(options: any): this;
  1769. show(effect: string, options?: any, duration?: number, complete?: Function): this;
  1770. show(effect: string, options?: any, duration?: string, complete?: Function): this;
  1771. toggle(options: any): this;
  1772. toggle(effect: string, options?: any, duration?: number, complete?: Function): this;
  1773. toggle(effect: string, options?: any, duration?: string, complete?: Function): this;
  1774. position(options: JQueryUI.JQueryPositionOptions): JQuery;
  1775. enableSelection(): JQuery;
  1776. disableSelection(): JQuery;
  1777. focus(delay: number, callback?: Function): JQuery;
  1778. uniqueId(): JQuery;
  1779. removeUniqueId(): JQuery;
  1780. scrollParent(): JQuery;
  1781. zIndex(): number;
  1782. zIndex(zIndex: number): JQuery;
  1783. widget: JQueryUI.Widget;
  1784. jQuery: JQueryStatic;
  1785. }
  1786. interface JQueryStatic {
  1787. ui: JQueryUI.UI;
  1788. datepicker: JQueryUI.Datepicker;
  1789. widget: JQueryUI.Widget;
  1790. Widget: JQueryUI.Widget;
  1791. }
  1792. interface JQueryEasingFunctions {
  1793. easeInQuad: JQueryEasingFunction;
  1794. easeOutQuad: JQueryEasingFunction;
  1795. easeInOutQuad: JQueryEasingFunction;
  1796. easeInCubic: JQueryEasingFunction;
  1797. easeOutCubic: JQueryEasingFunction;
  1798. easeInOutCubic: JQueryEasingFunction;
  1799. easeInQuart: JQueryEasingFunction;
  1800. easeOutQuart: JQueryEasingFunction;
  1801. easeInOutQuart: JQueryEasingFunction;
  1802. easeInQuint: JQueryEasingFunction;
  1803. easeOutQuint: JQueryEasingFunction;
  1804. easeInOutQuint: JQueryEasingFunction;
  1805. easeInExpo: JQueryEasingFunction;
  1806. easeOutExpo: JQueryEasingFunction;
  1807. easeInOutExpo: JQueryEasingFunction;
  1808. easeInSine: JQueryEasingFunction;
  1809. easeOutSine: JQueryEasingFunction;
  1810. easeInOutSine: JQueryEasingFunction;
  1811. easeInCirc: JQueryEasingFunction;
  1812. easeOutCirc: JQueryEasingFunction;
  1813. easeInOutCirc: JQueryEasingFunction;
  1814. easeInElastic: JQueryEasingFunction;
  1815. easeOutElastic: JQueryEasingFunction;
  1816. easeInOutElastic: JQueryEasingFunction;
  1817. easeInBack: JQueryEasingFunction;
  1818. easeOutBack: JQueryEasingFunction;
  1819. easeInOutBack: JQueryEasingFunction;
  1820. easeInBounce: JQueryEasingFunction;
  1821. easeOutBounce: JQueryEasingFunction;
  1822. easeInOutBounce: JQueryEasingFunction;
  1823. }