@jetbrains/ring-ui 7.0.62 → 7.0.63

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (386) hide show
  1. package/components/alert/alert.css +1 -1
  2. package/components/alert/alert.d.ts +1 -1
  3. package/components/alert/alert.js +3 -3
  4. package/components/alert/container.css +2 -2
  5. package/components/alert/container.d.ts +1 -1
  6. package/components/alert/container.js +1 -1
  7. package/components/alert-service/alert-service.d.ts +2 -2
  8. package/components/analytics/{analytics__custom-plugin.d.ts → analytics-custom-plugin.d.ts} +1 -1
  9. package/components/analytics/{analytics__custom-plugin.js → analytics-custom-plugin.js} +2 -2
  10. package/components/auth/{auth__core.d.ts → auth-core.d.ts} +9 -8
  11. package/components/auth/{auth__core.js → auth-core.js} +14 -18
  12. package/components/auth/auth.d.ts +2 -2
  13. package/components/auth/auth.js +2 -2
  14. package/components/auth/background-flow.d.ts +2 -2
  15. package/components/auth/background-flow.js +0 -1
  16. package/components/auth/down-notification.css +1 -1
  17. package/components/auth/down-notification.js +1 -1
  18. package/components/auth/iframe-flow.d.ts +3 -3
  19. package/components/auth/iframe-flow.js +3 -5
  20. package/components/auth/request-builder.d.ts +2 -1
  21. package/components/auth/request-builder.js +1 -2
  22. package/components/auth/storage.d.ts +3 -3
  23. package/components/auth/storage.js +4 -8
  24. package/components/auth/token-validator.d.ts +2 -1
  25. package/components/auth/token-validator.js +6 -1
  26. package/components/auth/window-flow.d.ts +3 -3
  27. package/components/auth/window-flow.js +7 -7
  28. package/components/auth-dialog/auth-dialog.css +2 -2
  29. package/components/auth-dialog/auth-dialog.js +1 -1
  30. package/components/auth-dialog-service/auth-dialog-service.d.ts +1 -1
  31. package/components/avatar/avatar-info.d.ts +1 -1
  32. package/components/avatar/avatar.css +1 -1
  33. package/components/avatar/avatar.d.ts +1 -1
  34. package/components/avatar/avatar.figma.js +1 -1
  35. package/components/avatar/avatar.js +5 -7
  36. package/components/avatar/fallback-avatar.js +4 -8
  37. package/components/avatar-stack/avatar-stack.css +1 -1
  38. package/components/avatar-stack/avatar-stack.d.ts +3 -3
  39. package/components/avatar-stack/avatar-stack.figma.js +1 -1
  40. package/components/avatar-stack/avatar-stack.js +1 -1
  41. package/components/banner/banner.css +2 -2
  42. package/components/banner/banner.js +1 -1
  43. package/components/breadcrumbs/breadcrumbs.d.ts +1 -1
  44. package/components/breadcrumbs/breadcrumbs.figma.js +1 -1
  45. package/components/button/{button__classes.d.ts → button.classes.d.ts} +1 -1
  46. package/components/button/button.css +19 -16
  47. package/components/button/button.d.ts +4 -4
  48. package/components/button/button.figma.js +1 -1
  49. package/components/button/button.js +6 -6
  50. package/components/button-group/button-group.css +6 -6
  51. package/components/button-group/button-group.d.ts +1 -1
  52. package/components/button-group/button-group.js +1 -1
  53. package/components/button-group/caption.d.ts +1 -1
  54. package/components/button-set/button-set.css +2 -2
  55. package/components/button-set/button-set.d.ts +1 -1
  56. package/components/button-toolbar/button-toolbar.css +2 -2
  57. package/components/button-toolbar/button-toolbar.d.ts +1 -1
  58. package/components/caret/caret.js +23 -18
  59. package/components/checkbox/checkbox-group.figma.js +1 -1
  60. package/components/checkbox/checkbox.css +1 -1
  61. package/components/checkbox/checkbox.d.ts +1 -1
  62. package/components/checkbox/checkbox.figma.js +1 -1
  63. package/components/checkbox/checkbox.js +5 -5
  64. package/components/clipboard/clipboard.js +2 -2
  65. package/components/code/code.css +1 -1
  66. package/components/code/code.d.ts +1 -1
  67. package/components/code/code.js +5 -3
  68. package/components/collapse/collapse-content.d.ts +3 -3
  69. package/components/collapse/collapse-control.d.ts +2 -2
  70. package/components/collapse/collapse.css +1 -1
  71. package/components/collapse/collapse.d.ts +3 -3
  72. package/components/confirm/confirm.d.ts +1 -1
  73. package/components/confirm/confirm.js +1 -1
  74. package/components/confirm-service/confirm-service.d.ts +3 -3
  75. package/components/content-layout/content-layout.css +2 -2
  76. package/components/content-layout/content-layout.d.ts +1 -1
  77. package/components/content-layout/content-layout.js +2 -2
  78. package/components/content-layout/sidebar.d.ts +1 -1
  79. package/components/contenteditable/contenteditable.d.ts +1 -1
  80. package/components/contenteditable/contenteditable.js +2 -1
  81. package/components/control-help/control-help.css +1 -1
  82. package/components/control-help/control-help.d.ts +1 -1
  83. package/components/control-label/control-label.d.ts +1 -1
  84. package/components/data-list/data-list.css +1 -1
  85. package/components/data-list/data-list.d.ts +5 -5
  86. package/components/data-list/data-list.js +2 -2
  87. package/components/data-list/data-list.mock.d.ts +2 -2
  88. package/components/data-list/data-list.mock.js +20 -20
  89. package/components/data-list/item.d.ts +3 -3
  90. package/components/data-list/item.js +2 -2
  91. package/components/data-list/selection.d.ts +1 -1
  92. package/components/data-list/selection.js +8 -1
  93. package/components/data-list/title.d.ts +2 -2
  94. package/components/date-picker/consts.d.ts +1 -1
  95. package/components/date-picker/date-input.d.ts +1 -1
  96. package/components/date-picker/date-input.js +2 -2
  97. package/components/date-picker/date-picker.css +15 -15
  98. package/components/date-picker/date-picker.d.ts +5 -5
  99. package/components/date-picker/date-picker.js +17 -19
  100. package/components/date-picker/date-popup.d.ts +1 -1
  101. package/components/date-picker/date-popup.js +5 -3
  102. package/components/date-picker/day.d.ts +2 -2
  103. package/components/date-picker/day.js +4 -5
  104. package/components/date-picker/formats.js +1 -0
  105. package/components/date-picker/month-names.d.ts +1 -1
  106. package/components/date-picker/month-names.js +1 -1
  107. package/components/date-picker/month-slider.d.ts +2 -2
  108. package/components/date-picker/month-slider.js +1 -1
  109. package/components/date-picker/month.d.ts +1 -1
  110. package/components/date-picker/months.d.ts +1 -1
  111. package/components/date-picker/months.js +2 -2
  112. package/components/date-picker/years.d.ts +1 -1
  113. package/components/date-picker/years.js +2 -2
  114. package/components/dialog/{dialog__body-scroll-preventer.js → dialog-body-scroll-preventer.js} +6 -2
  115. package/components/dialog/dialog.css +5 -5
  116. package/components/dialog/dialog.d.ts +1 -1
  117. package/components/dialog/dialog.js +7 -7
  118. package/components/dropdown/anchor.d.ts +1 -1
  119. package/components/dropdown/dropdown.css +1 -1
  120. package/components/dropdown/dropdown.d.ts +2 -2
  121. package/components/dropdown/dropdown.js +2 -2
  122. package/components/dropdown-menu/dropdown-menu.d.ts +5 -5
  123. package/components/dropdown-menu/dropdown-menu.js +1 -1
  124. package/components/editable-heading/editable-heading.css +6 -8
  125. package/components/editable-heading/editable-heading.d.ts +1 -1
  126. package/components/editable-heading/editable-heading.js +3 -2
  127. package/components/error-bubble/error-bubble-legacy.css +3 -3
  128. package/components/error-bubble/error-bubble.css +5 -5
  129. package/components/error-bubble/error-bubble.d.ts +1 -1
  130. package/components/error-bubble/error-bubble.figma.js +1 -1
  131. package/components/error-bubble/error-bubble.js +2 -2
  132. package/components/error-message/error-message.css +1 -1
  133. package/components/error-message/error-message.d.ts +2 -2
  134. package/components/error-message/error-message.js +2 -2
  135. package/components/error-page/error-page.css +3 -3
  136. package/components/footer/footer.css +2 -2
  137. package/components/footer/footer.d.ts +1 -1
  138. package/components/footer/footer.js +1 -1
  139. package/components/form/form.css +3 -3
  140. package/components/global/compose-refs.d.ts +2 -0
  141. package/components/global/compose-refs.js +14 -0
  142. package/components/global/composeRefs.d.ts +6 -2
  143. package/components/global/composeRefs.js +7 -14
  144. package/components/global/create-stateful-context.d.ts +1 -1
  145. package/components/global/dom.d.ts +1 -1
  146. package/components/global/dom.js +2 -4
  147. package/components/global/focus-sensor-hoc.d.ts +1 -1
  148. package/components/global/focus-sensor-hoc.js +2 -2
  149. package/components/global/fuzzy-highlight.d.ts +2 -2
  150. package/components/global/get-event-key.d.ts +1 -1
  151. package/components/global/global.css +2 -2
  152. package/components/global/memoize.js +1 -1
  153. package/components/global/rerender-hoc.d.ts +1 -1
  154. package/components/global/rerender-hoc.js +2 -2
  155. package/components/global/theme.d.ts +1 -1
  156. package/components/global/theme.js +2 -2
  157. package/components/global/url.js +3 -3
  158. package/components/global/use-event-callback.js +1 -1
  159. package/components/global/variables.css +1 -1
  160. package/components/grid/col.d.ts +1 -1
  161. package/components/grid/col.js +1 -1
  162. package/components/grid/grid.css +4 -4
  163. package/components/grid/grid.d.ts +1 -1
  164. package/components/grid/grid.js +1 -1
  165. package/components/grid/row.d.ts +1 -1
  166. package/components/grid/row.js +1 -1
  167. package/components/group/group.css +1 -1
  168. package/components/group/group.d.ts +1 -1
  169. package/components/group/group.js +1 -1
  170. package/components/header/header-icon.d.ts +2 -2
  171. package/components/header/header.css +4 -4
  172. package/components/header/header.d.ts +1 -1
  173. package/components/header/links.d.ts +1 -1
  174. package/components/header/logo.d.ts +1 -1
  175. package/components/header/profile.d.ts +5 -5
  176. package/components/header/profile.js +3 -3
  177. package/components/header/services-link.d.ts +1 -1
  178. package/components/header/services-link.js +3 -3
  179. package/components/header/services.css +1 -1
  180. package/components/header/services.d.ts +2 -2
  181. package/components/header/services.js +3 -3
  182. package/components/header/smart-profile.d.ts +3 -3
  183. package/components/header/smart-profile.js +2 -1
  184. package/components/header/smart-services.d.ts +3 -3
  185. package/components/header/tray.d.ts +1 -1
  186. package/components/heading/heading.css +2 -2
  187. package/components/heading/heading.d.ts +1 -1
  188. package/components/http/http.mock.d.ts +1 -1
  189. package/components/hub-source/{hub-source__user.d.ts → hub-source-user.d.ts} +3 -2
  190. package/components/hub-source/{hub-source__users-groups.d.ts → hub-source-users-groups.d.ts} +3 -2
  191. package/components/hub-source/hub-source.d.ts +2 -2
  192. package/components/icon/{icon__svg.d.ts → icon-svg.d.ts} +1 -1
  193. package/components/icon/icon.css +5 -5
  194. package/components/icon/icon.d.ts +2 -2
  195. package/components/icon/icon.js +3 -3
  196. package/components/input/input-legacy.css +2 -2
  197. package/components/input/input.css +5 -5
  198. package/components/input/input.d.ts +3 -3
  199. package/components/input/input.figma.js +1 -1
  200. package/components/input/input.js +8 -8
  201. package/components/input-size/input-size.css +1 -1
  202. package/components/island/adaptive-island-hoc.d.ts +1 -1
  203. package/components/island/content.d.ts +1 -1
  204. package/components/island/content.js +2 -2
  205. package/components/island/header.d.ts +1 -1
  206. package/components/island/header.js +4 -4
  207. package/components/island/island.css +3 -3
  208. package/components/island/island.d.ts +1 -1
  209. package/components/line/line.css +1 -1
  210. package/components/link/clickable-link.d.ts +12 -0
  211. package/components/link/clickable-link.js +25 -0
  212. package/components/link/clickableLink.d.ts +11 -12
  213. package/components/link/clickableLink.js +4 -25
  214. package/components/link/link.css +1 -1
  215. package/components/link/link.d.ts +2 -2
  216. package/components/link/link.js +4 -4
  217. package/components/list/consts.d.ts +4 -5
  218. package/components/list/{list__custom.d.ts → list-custom.d.ts} +1 -1
  219. package/components/list/{list__custom.js → list-custom.js} +1 -1
  220. package/components/list/{list__hint.d.ts → list-hint.d.ts} +1 -1
  221. package/components/list/{list__hint.js → list-hint.js} +1 -1
  222. package/components/list/{list__item.d.ts → list-item.d.ts} +2 -2
  223. package/components/list/{list__item.js → list-item.js} +6 -5
  224. package/components/list/{list__separator.d.ts → list-separator.d.ts} +1 -1
  225. package/components/list/{list__separator.js → list-separator.js} +1 -1
  226. package/components/list/{list__title.d.ts → list-title.d.ts} +1 -1
  227. package/components/list/{list__title.js → list-title.js} +1 -1
  228. package/components/list/{list__users-groups-source.d.ts → list-users-groups-source.d.ts} +3 -2
  229. package/components/list/{list__users-groups-source.js → list-users-groups-source.js} +1 -1
  230. package/components/list/{list__classes.d.ts → list.classes.d.ts} +1 -1
  231. package/components/list/list.css +5 -5
  232. package/components/list/list.d.ts +7 -7
  233. package/components/list/list.js +34 -28
  234. package/components/loader/{loader__core.js → loader-core.js} +2 -2
  235. package/components/loader/loader.css +1 -1
  236. package/components/loader/loader.d.ts +2 -2
  237. package/components/loader/loader.js +1 -1
  238. package/components/loader-inline/loader-inline.css +2 -2
  239. package/components/loader-inline/loader-inline.d.ts +1 -1
  240. package/components/loader-screen/loader-screen.css +2 -2
  241. package/components/loader-screen/loader-screen.d.ts +1 -1
  242. package/components/login-dialog/login-dialog.css +2 -2
  243. package/components/login-dialog/login-dialog.d.ts +1 -1
  244. package/components/login-dialog/login-dialog.js +1 -1
  245. package/components/login-dialog/service.d.ts +1 -1
  246. package/components/markdown/markdown.css +3 -3
  247. package/components/markdown/markdown.d.ts +1 -1
  248. package/components/markdown/markdown.js +1 -1
  249. package/components/message/message.css +3 -3
  250. package/components/message/message.d.ts +4 -4
  251. package/components/message/message.js +3 -3
  252. package/components/old-browsers-message/old-browsers-message.css +2 -2
  253. package/components/old-browsers-message/old-browsers-message.js +1 -1
  254. package/components/pager/pager.css +1 -1
  255. package/components/pager/pager.d.ts +2 -2
  256. package/components/pager/pager.js +11 -12
  257. package/components/panel/panel.css +1 -1
  258. package/components/panel/panel.d.ts +1 -1
  259. package/components/panel/panel.js +1 -1
  260. package/components/permissions/{permissions__cache.js → permissions-cache.js} +4 -5
  261. package/components/permissions/permissions.d.ts +2 -2
  262. package/components/permissions/permissions.js +2 -4
  263. package/components/popup/popup.css +3 -3
  264. package/components/popup/popup.d.ts +2 -2
  265. package/components/popup/popup.js +6 -5
  266. package/components/popup/popup.target.d.ts +1 -1
  267. package/components/popup/position-css.js +6 -10
  268. package/components/popup/position.js +10 -10
  269. package/components/popup-menu/popup-menu.d.ts +4 -4
  270. package/components/progress-bar/progress-bar.css +6 -8
  271. package/components/progress-bar/progress-bar.d.ts +1 -1
  272. package/components/progress-bar/progress-bar.js +1 -1
  273. package/components/query-assist/{query-assist__suggestions.d.ts → query-assist-suggestions.d.ts} +1 -1
  274. package/components/query-assist/query-assist.css +11 -11
  275. package/components/query-assist/query-assist.d.ts +4 -4
  276. package/components/query-assist/query-assist.js +11 -11
  277. package/components/radio/{radio__item.d.ts → radio-item.d.ts} +1 -1
  278. package/components/radio/{radio__item.js → radio-item.js} +2 -2
  279. package/components/radio/radio.css +2 -2
  280. package/components/radio/radio.d.ts +2 -2
  281. package/components/radio/radio.js +1 -1
  282. package/components/scrollable-section/scrollable-section.d.ts +1 -1
  283. package/components/scrollable-section/scrollable-section.js +1 -1
  284. package/components/select/{select__filter.d.ts → select-filter.d.ts} +2 -2
  285. package/components/select/{select__filter.js → select-filter.js} +1 -1
  286. package/components/select/select-popup.css +5 -5
  287. package/components/select/{select__popup.d.ts → select-popup.d.ts} +8 -8
  288. package/components/select/{select__popup.js → select-popup.js} +11 -7
  289. package/components/select/select.css +10 -9
  290. package/components/select/select.d.ts +6 -6
  291. package/components/select/select.js +27 -25
  292. package/components/shortcuts/core.js +7 -7
  293. package/components/shortcuts/shortcuts-hoc.d.ts +2 -2
  294. package/components/shortcuts/shortcuts.d.ts +1 -1
  295. package/components/sidebar/sidebar.css +1 -1
  296. package/components/slider/slider.css +2 -2
  297. package/components/slider/slider.d.ts +5 -5
  298. package/components/slider/slider.js +5 -5
  299. package/components/slider/slider.utils.d.ts +1 -1
  300. package/components/slider/slider.utils.js +2 -4
  301. package/components/storage/{storage__local.d.ts → storage-local.d.ts} +1 -1
  302. package/components/storage/{storage__local.js → storage-local.js} +7 -7
  303. package/components/storage/storage.d.ts +1 -1
  304. package/components/storage/storage.js +1 -1
  305. package/components/tab-trap/tab-trap.css +1 -1
  306. package/components/tab-trap/tab-trap.d.ts +1 -1
  307. package/components/tab-trap/tab-trap.js +2 -5
  308. package/components/table/cell.d.ts +1 -1
  309. package/components/table/disable-hover-hoc.d.ts +1 -1
  310. package/components/table/header-cell.d.ts +1 -1
  311. package/components/table/header-cell.js +1 -1
  312. package/components/table/header.d.ts +2 -2
  313. package/components/table/header.js +2 -2
  314. package/components/table/multitable.d.ts +3 -3
  315. package/components/table/multitable.js +1 -1
  316. package/components/table/row-with-focus-sensor.d.ts +3 -3
  317. package/components/table/row.d.ts +4 -4
  318. package/components/table/row.js +1 -1
  319. package/components/table/selection-adapter.d.ts +2 -1
  320. package/components/table/selection-shortcuts-hoc.d.ts +4 -3
  321. package/components/table/selection-shortcuts-hoc.js +1 -3
  322. package/components/table/selection.js +4 -8
  323. package/components/table/simple-table.d.ts +2 -2
  324. package/components/table/smart-table.d.ts +2 -2
  325. package/components/table/table.css +6 -6
  326. package/components/table/table.d.ts +7 -7
  327. package/components/table/table.js +3 -3
  328. package/components/tabs/collapsible-more.d.ts +3 -3
  329. package/components/tabs/collapsible-more.js +2 -2
  330. package/components/tabs/collapsible-tab.d.ts +2 -2
  331. package/components/tabs/collapsible-tab.js +1 -1
  332. package/components/tabs/collapsible-tabs.d.ts +2 -2
  333. package/components/tabs/collapsible-tabs.js +6 -8
  334. package/components/tabs/custom-item.d.ts +2 -2
  335. package/components/tabs/dumb-tabs.d.ts +3 -3
  336. package/components/tabs/dumb-tabs.js +3 -3
  337. package/components/tabs/smart-tabs.d.ts +1 -1
  338. package/components/tabs/tab-link.d.ts +2 -2
  339. package/components/tabs/tab.d.ts +2 -2
  340. package/components/tabs/tabs.css +6 -6
  341. package/components/tag/tag.css +5 -5
  342. package/components/tag/tag.d.ts +2 -2
  343. package/components/tag/tag.js +2 -2
  344. package/components/tags-input/tags-input.css +3 -3
  345. package/components/tags-input/tags-input.d.ts +8 -8
  346. package/components/tags-input/tags-input.js +13 -7
  347. package/components/tags-list/tags-list.d.ts +2 -2
  348. package/components/tags-list/tags-list.js +1 -1
  349. package/components/text/text.css +1 -1
  350. package/components/text/text.d.ts +1 -1
  351. package/components/toggle/toggle.css +2 -2
  352. package/components/toggle/toggle.d.ts +1 -1
  353. package/components/toggle/toggle.js +1 -1
  354. package/components/tooltip/tooltip.css +1 -1
  355. package/components/tooltip/tooltip.d.ts +2 -2
  356. package/components/tooltip/tooltip.js +1 -1
  357. package/components/upload/upload.css +1 -1
  358. package/components/upload/upload.d.ts +3 -3
  359. package/components/upload/upload.js +2 -2
  360. package/components/user-agreement/service.d.ts +2 -2
  361. package/components/user-agreement/service.js +3 -5
  362. package/components/user-agreement/user-agreement.css +2 -2
  363. package/components/user-agreement/user-agreement.d.ts +1 -1
  364. package/components/user-agreement/user-agreement.js +1 -1
  365. package/components/user-card/card.d.ts +1 -1
  366. package/components/user-card/card.js +3 -2
  367. package/components/user-card/smart-user-card-tooltip.d.ts +2 -2
  368. package/components/user-card/smart-user-card-tooltip.js +1 -1
  369. package/components/user-card/tooltip.d.ts +3 -3
  370. package/components/user-card/user-card.css +1 -1
  371. package/package.json +4 -1
  372. /package/components/button/{button__classes.js → button.classes.js} +0 -0
  373. /package/components/dialog/{dialog__body-scroll-preventer.d.ts → dialog-body-scroll-preventer.d.ts} +0 -0
  374. /package/components/global/{variables.d.ts → variables.interface.d.ts} +0 -0
  375. /package/components/global/{variables.js → variables.interface.js} +0 -0
  376. /package/components/hub-source/{hub-source__user.js → hub-source-user.js} +0 -0
  377. /package/components/hub-source/{hub-source__users-groups.js → hub-source-users-groups.js} +0 -0
  378. /package/components/icon/{icon__svg.js → icon-svg.js} +0 -0
  379. /package/components/icon/{icon__constants.d.ts → icon.constants.d.ts} +0 -0
  380. /package/components/icon/{icon__constants.js → icon.constants.js} +0 -0
  381. /package/components/list/{list__classes.js → list.classes.js} +0 -0
  382. /package/components/loader/{loader__core.d.ts → loader-core.d.ts} +0 -0
  383. /package/components/old-browsers-message/{old-browsers-message__stop.d.ts → old-browsers-message-stop.d.ts} +0 -0
  384. /package/components/old-browsers-message/{old-browsers-message__stop.js → old-browsers-message-stop.js} +0 -0
  385. /package/components/permissions/{permissions__cache.d.ts → permissions-cache.d.ts} +0 -0
  386. /package/components/query-assist/{query-assist__suggestions.js → query-assist-suggestions.js} +0 -0
@@ -5,7 +5,7 @@ import styles from './tabs.css';
5
5
  import TabLink from './tab-link';
6
6
  import { CustomItem } from './custom-item';
7
7
  const TabTitle = React.memo(function TabTitle({ selected, child, handleSelect, collapsed = false, tabIndex, }) {
8
- if (child == null || typeof child !== 'object' || child.type === CustomItem) {
8
+ if (child === null || typeof child !== 'object' || child.type === CustomItem) {
9
9
  return child;
10
10
  }
11
11
  const { title, titleProps, disabled, href, className, activeClassName, collapsedClassName, collapsedActiveClassName } = child.props;
@@ -1,5 +1,5 @@
1
- import { ReactElement, ReactNode } from 'react';
2
- import { TabProps } from './tab';
1
+ import { type ReactElement, type ReactNode } from 'react';
2
+ import { type TabProps } from './tab';
3
3
  export interface CollapsibleTabsProps {
4
4
  children: ReactElement<TabProps>[];
5
5
  selected?: string | undefined;
@@ -37,12 +37,10 @@ export const CollapsibleTabs = ({ children, selected, onSelect, onLastVisibleInd
37
37
  if (preparedElements.ready) {
38
38
  return preparedElements.hidden;
39
39
  }
40
- else if (initialVisibleItems) {
40
+ if (initialVisibleItems) {
41
41
  return children.filter(item => !visibleElements.some(visibleItem => visibleItem.props.child === item));
42
42
  }
43
- else {
44
- return [];
45
- }
43
+ return [];
46
44
  }, [children, preparedElements.hidden, preparedElements.ready, visibleElements, initialVisibleItems]);
47
45
  const adjustTabs = useCallback((entry) => {
48
46
  const containerWidth = entry.contentRect.width;
@@ -102,10 +100,10 @@ export const CollapsibleTabs = ({ children, selected, onSelect, onLastVisibleInd
102
100
  accumulator.hidden.push(tab);
103
101
  }
104
102
  return accumulator;
105
- }, { visible: [], hidden: [], ready: elements.lastVisibleIndex !== null });
103
+ }, { visible: [], hidden: [], ready: !!elements.lastVisibleIndex });
106
104
  if (selectedIndex > (elements.lastVisibleIndex ?? 0)) {
107
105
  const selectedItem = children.find(tab => !tab.props.alwaysHidden && tab.props.id === selected);
108
- if (selectedItem != null) {
106
+ if (selectedItem) {
109
107
  res.visible.push(selectedItem);
110
108
  }
111
109
  }
@@ -128,7 +126,7 @@ export const CollapsibleTabs = ({ children, selected, onSelect, onLastVisibleInd
128
126
  }, [children]);
129
127
  // Initial measure for tabs and more button sizes
130
128
  useEffect(() => {
131
- if (measureRef.current == null) {
129
+ if (measureRef.current === null) {
132
130
  return undefined;
133
131
  }
134
132
  const measureTask = fastdom.measure(() => {
@@ -173,7 +171,7 @@ export const CollapsibleTabs = ({ children, selected, onSelect, onLastVisibleInd
173
171
  resizeObserver.disconnect();
174
172
  };
175
173
  }, [adjustTabs]);
176
- const isAdjusted = (elements.lastVisibleIndex !== null && preparedElements.ready === true) || initialVisibleItems;
174
+ const isAdjusted = (!!elements.lastVisibleIndex && preparedElements.ready) || initialVisibleItems;
177
175
  const className = classNames(styles.titles, styles.autoCollapse, isAdjusted && styles.adjusted);
178
176
  return (_jsxs("div", { className: styles.autoCollapseContainer, children: [_jsxs("div", { className: classNames(className, styles.rendered), children: [visibleElements, _jsx(MoreButton, { moreClassName: moreClassName, moreActiveClassName: moreActiveClassName, morePopupClassName: morePopupClassName, morePopupBeforeEnd: morePopupBeforeEnd, morePopupItemClassName: morePopupItemClassName, items: hiddenElements, selected: selected, onSelect: onSelect })] }), _jsxs("div", { ref: measureRef, className: classNames(className, styles.measure), children: [childrenToMeasure, _jsx(FakeMoreButton, { hasActiveChildren: hiddenElements.some(item => item.props.alwaysHidden && item.props.id === selected), moreClassName: moreClassName, moreActiveClassName: moreActiveClassName })] })] }));
179
177
  };
@@ -1,3 +1,3 @@
1
- import { ReactElement } from 'react';
2
- import { TabProps } from './tab';
1
+ import { type ReactElement } from 'react';
2
+ import { type TabProps } from './tab';
3
3
  export declare const CustomItem: ({ children }: TabProps) => ReactElement;
@@ -1,8 +1,8 @@
1
- import { PureComponent, ReactElement } from 'react';
1
+ import { PureComponent, type ReactElement } from 'react';
2
2
  import * as React from 'react';
3
- import { CollapsibleTabsProps } from './collapsible-tabs';
3
+ import { type CollapsibleTabsProps } from './collapsible-tabs';
4
4
  import { CustomItem } from './custom-item';
5
- import { TabProps } from './tab';
5
+ import { type TabProps } from './tab';
6
6
  export { CustomItem };
7
7
  export type Children = readonly (Children | null | boolean)[] | ReactElement<TabProps> | null | boolean;
8
8
  export interface TabsProps extends Omit<CollapsibleTabsProps, 'onSelect' | 'children'> {
@@ -12,7 +12,7 @@ export { CustomItem };
12
12
  class Tabs extends PureComponent {
13
13
  handleSelect = memoize((key) => () => this.props.onSelect?.(key));
14
14
  getTabTitle = (child, i) => {
15
- if (child == null || typeof child !== 'object' || child.type === CustomItem) {
15
+ if (child === null || typeof child !== 'object' || child.type === CustomItem) {
16
16
  return child;
17
17
  }
18
18
  const { selected, onSelect } = this.props;
@@ -22,13 +22,13 @@ class Tabs extends PureComponent {
22
22
  const titleClasses = classNames(styles.title, className, isSelected && activeClassName, {
23
23
  [styles.selected]: isSelected,
24
24
  });
25
- return (_jsx(TabLink, { title: title, isSelected: isSelected, href: href, className: titleClasses, disabled: disabled, onPlainLeftClick: onSelect != null ? this.handleSelect(key) : undefined, ...titleProps }, key));
25
+ return (_jsx(TabLink, { title: title, isSelected: isSelected, href: href, className: titleClasses, disabled: disabled, onPlainLeftClick: onSelect ? this.handleSelect(key) : undefined, ...titleProps }, key));
26
26
  };
27
27
  render() {
28
28
  const { className, tabContainerClassName, children, selected, autoCollapse, 'data-test': dataTest, onSelect, ...restProps } = this.props;
29
29
  const classes = classNames(styles.tabs, className);
30
30
  const childrenArray = React.Children.toArray(children).filter(Boolean);
31
- return (_jsxs("div", { className: classes, "data-test": dataTests('ring-dumb-tabs', dataTest), children: [autoCollapse === true ? (_jsx(CollapsibleTabs, { ...restProps, onSelect: onSelect != null ? this.handleSelect : undefined, selected: selected, children: childrenArray })) : (_jsx("div", { className: styles.titles, children: childrenArray.map(this.getTabTitle) })), _jsx("div", { className: classNames(tabContainerClassName), children: childrenArray.find(({ props }, i) => (props.id || String(i)) === selected) })] }));
31
+ return (_jsxs("div", { className: classes, "data-test": dataTests('ring-dumb-tabs', dataTest), children: [autoCollapse === true ? (_jsx(CollapsibleTabs, { ...restProps, onSelect: onSelect ? this.handleSelect : undefined, selected: selected, children: childrenArray })) : (_jsx("div", { className: styles.titles, children: childrenArray.map(this.getTabTitle) })), _jsx("div", { className: classNames(tabContainerClassName), children: childrenArray.find(({ props }, i) => (props.id || String(i)) === selected) })] }));
32
32
  }
33
33
  }
34
34
  export default Tabs;
@@ -1,5 +1,5 @@
1
1
  import { PureComponent } from 'react';
2
- import { TabsAttrs, Children } from './dumb-tabs';
2
+ import { type TabsAttrs, type Children } from './dumb-tabs';
3
3
  export interface SmartTabsProps extends TabsAttrs {
4
4
  children: Children;
5
5
  initSelected?: string | null | undefined;
@@ -1,5 +1,5 @@
1
- import { ReactNode } from 'react';
2
- import { LinkProps } from '../link/link';
1
+ import { type ReactNode } from 'react';
2
+ import { type LinkProps } from '../link/link';
3
3
  export interface TabLinkProps extends Omit<LinkProps, 'title' | 'children'> {
4
4
  isSelected: boolean;
5
5
  collapsed?: boolean;
@@ -1,5 +1,5 @@
1
- import { PureComponent, ReactNode } from 'react';
2
- import { TabLinkProps } from './tab-link';
1
+ import { PureComponent, type ReactNode } from 'react';
2
+ import { type TabLinkProps } from './tab-link';
3
3
  export interface TabProps {
4
4
  title?: ReactNode | ((isSelected: boolean, collapsed: boolean | undefined) => ReactNode);
5
5
  titleProps?: Partial<TabLinkProps>;
@@ -1,7 +1,7 @@
1
- @import "../global/variables.css";
1
+ @import '../global/variables.css';
2
2
 
3
3
  /* ensure styles order */
4
- @import "../link/link.css";
4
+ @import '../link/link.css';
5
5
 
6
6
  :root,
7
7
  :host {
@@ -16,7 +16,7 @@
16
16
  --ring-tabs-line-shadow: inset 0 -1px 0 0;
17
17
  --ring-tabs-selected-line-shadow: inset 0 -2px 0 0;
18
18
 
19
- composes: font from "../global/global.css";
19
+ composes: font from '../global/global.css';
20
20
  }
21
21
 
22
22
  .titles {
@@ -34,7 +34,7 @@
34
34
  }
35
35
 
36
36
  .title {
37
- composes: font from "../global/global.css";
37
+ composes: font from '../global/global.css';
38
38
 
39
39
  position: relative;
40
40
 
@@ -46,7 +46,7 @@
46
46
 
47
47
  color: inherit;
48
48
 
49
- border: none;
49
+ border: 0;
50
50
  border-radius: 0;
51
51
  background: none;
52
52
 
@@ -191,7 +191,7 @@
191
191
  .collapsed.collapsed {
192
192
  width: 100%;
193
193
 
194
- border-bottom: none;
194
+ border-bottom: 0;
195
195
  box-shadow: none;
196
196
 
197
197
  line-height: calc(var(--ring-unit) * 3);
@@ -1,7 +1,7 @@
1
- @import "../global/variables.css";
1
+ @import '../global/variables.css';
2
2
 
3
3
  /* ensure styles order */
4
- @import "../link/link.css";
4
+ @import '../link/link.css';
5
5
 
6
6
  :root,
7
7
  :host {
@@ -15,7 +15,7 @@
15
15
  .tag {
16
16
  --ring-tag-max-height: 20px;
17
17
 
18
- composes: resetButton from "../global/global.css";
18
+ composes: resetButton from '../global/global.css';
19
19
 
20
20
  position: relative;
21
21
  z-index: 1;
@@ -34,7 +34,7 @@
34
34
 
35
35
  color: var(--ring-tag-text-color);
36
36
 
37
- border: none;
37
+ border: 0;
38
38
  border-radius: var(--ring-border-radius);
39
39
 
40
40
  font-size: 12px;
@@ -155,7 +155,7 @@
155
155
  }
156
156
 
157
157
  .content {
158
- composes: ellipsis from "../global/global.css";
158
+ composes: ellipsis from '../global/global.css';
159
159
  }
160
160
 
161
161
  .disabled.tag {
@@ -1,6 +1,6 @@
1
- import { HTMLAttributes, PureComponent, ReactNode, RefCallback } from 'react';
1
+ import { type HTMLAttributes, PureComponent, type ReactNode, type RefCallback } from 'react';
2
2
  import * as React from 'react';
3
- import { IconType } from '../icon/icon';
3
+ import { type IconType } from '../icon/icon';
4
4
  export interface TagRenderProps extends HTMLAttributes<HTMLElement> {
5
5
  disabled: boolean;
6
6
  ref: RefCallback<HTMLElement>;
@@ -24,7 +24,7 @@ export default class Tag extends PureComponent {
24
24
  readOnly: false,
25
25
  disabled: false,
26
26
  focused: false,
27
- render: props => _jsx("button", { type: "button", ...props }),
27
+ render: props => _jsx("button", { type: 'button', ...props }),
28
28
  tagType: TagType.DEFAULT,
29
29
  };
30
30
  state = {
@@ -88,7 +88,7 @@ export default class Tag extends PureComponent {
88
88
  }
89
89
  renderRemoveIcon() {
90
90
  if (!this.props.readOnly && this.props.onRemove) {
91
- return (_jsx(Button, { title: "Remove", icon: closeIcon, "data-test": "ring-tag-remove", className: styles.remove, onClick: this.props.onRemove, style: { '--ring-secondary-color': this.props.textColor }, height: ControlsHeight.M }));
91
+ return (_jsx(Button, { title: 'Remove', icon: closeIcon, "data-test": 'ring-tag-remove', className: styles.remove, onClick: this.props.onRemove, style: { '--ring-secondary-color': this.props.textColor }, height: ControlsHeight.M }));
92
92
  }
93
93
  return null;
94
94
  }
@@ -1,6 +1,6 @@
1
- @import "../global/variables.css";
1
+ @import '../global/variables.css';
2
2
 
3
- @value outerContainer, container, input from "../input/input.css";
3
+ @value outerContainer, container, input from '../input/input.css';
4
4
 
5
5
  .tagsInput {
6
6
  --ring-input-icon-offset: calc(var(--ring-unit) * 2.5);
@@ -60,7 +60,7 @@
60
60
 
61
61
  caret-color: var(--ring-main-color);
62
62
 
63
- [dir="rtl"] & {
63
+ [dir='rtl'] & {
64
64
  padding-right: var(--ring-input-padding-start);
65
65
  padding-left: var(--ring-input-padding-end);
66
66
  }
@@ -1,13 +1,13 @@
1
- import { PureComponent, SyntheticEvent, ReactNode, ComponentType } from 'react';
1
+ import { PureComponent, type SyntheticEvent, type ReactNode, type ComponentType } from 'react';
2
2
  import * as React from 'react';
3
- import Select, { SelectItem } from '../select/select';
4
- import { TagType } from '../tags-list/tags-list';
3
+ import Select, { type SelectItem } from '../select/select';
4
+ import { type TagType } from '../tags-list/tags-list';
5
5
  import Caret from '../caret/caret';
6
6
  import { Size } from '../input/input';
7
- import { ControlsHeight, ControlsHeightContext } from '../global/controls-height';
8
- import { Filter } from '../select/select__popup';
9
- import { TagAttrs } from '../tag/tag';
10
- import { LabelType } from '../control-label/control-label';
7
+ import { type ControlsHeight, ControlsHeightContext } from '../global/controls-height';
8
+ import { type Filter } from '../select/select-popup';
9
+ import { type TagAttrs } from '../tag/tag';
10
+ import { type LabelType } from '../control-label/control-label';
11
11
  declare function noop(): void;
12
12
  export interface ToggleTagParams {
13
13
  tag: TagType;
@@ -104,7 +104,7 @@ export default class TagsInput extends PureComponent<TagsInputProps, TagsInputSt
104
104
  handleKeyDown: (event: React.KeyboardEvent) => boolean;
105
105
  handleClick: (arg: TagType) => () => void;
106
106
  handleRemove: (arg: TagType) => () => Promise<void | TagType[]>;
107
- handleTagCreation: (label: string) => void;
107
+ handleTagCreation: (label: string | undefined) => void;
108
108
  select?: Select | null;
109
109
  selectRef: (el: Select | null) => void;
110
110
  render(): import("react/jsx-runtime").JSX.Element;
@@ -1,4 +1,5 @@
1
1
  import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
2
+ /* eslint-disable max-lines */
2
3
  import { PureComponent } from 'react';
3
4
  import classNames from 'classnames';
4
5
  import getEventKey from '../global/get-event-key';
@@ -50,8 +51,8 @@ export default class TagsInput extends PureComponent {
50
51
  };
51
52
  static getDerivedStateFromProps({ tags }, { prevTags }) {
52
53
  const nextState = { prevTags: tags };
53
- if (tags != null && tags !== prevTags) {
54
- Object.assign(nextState, { tags, activeIndex: tags.length });
54
+ if (tags && tags !== prevTags) {
55
+ Object.assign(nextState, { tags, activeIndex: tags?.length });
55
56
  }
56
57
  return nextState;
57
58
  }
@@ -59,6 +60,7 @@ export default class TagsInput extends PureComponent {
59
60
  if (this.props.autoOpen && !this.props.disabled) {
60
61
  this.focusInput();
61
62
  this.loadSuggestions();
63
+ // eslint-disable-next-line no-underscore-dangle
62
64
  this.select?._showPopup();
63
65
  }
64
66
  }
@@ -91,7 +93,7 @@ export default class TagsInput extends PureComponent {
91
93
  this.focusInput();
92
94
  };
93
95
  addTag = (tag) => {
94
- if (tag == null) {
96
+ if (tag === null) {
95
97
  return;
96
98
  }
97
99
  const isUniqueTag = this.state.tags.filter(item => tag.key === item.key).length === 0;
@@ -119,6 +121,7 @@ export default class TagsInput extends PureComponent {
119
121
  if (event.target !== this.node && event.target.parentElement !== this.node) {
120
122
  return;
121
123
  }
124
+ // eslint-disable-next-line no-underscore-dangle
122
125
  this.select?._clickHandler();
123
126
  };
124
127
  filterExistingTags = (suggestions) => {
@@ -158,22 +161,24 @@ export default class TagsInput extends PureComponent {
158
161
  this.setActiveIndex(newActiveIndex);
159
162
  }
160
163
  };
164
+ // eslint-disable-next-line complexity
161
165
  handleKeyDown = (event) => {
162
166
  const key = getEventKey(event);
163
167
  const isInputFocused = () => event.target instanceof Element && event.target.matches(this.getInputNode()?.tagName ?? '');
164
168
  if (key === ' ' && this.props.allowAddNewTags) {
165
169
  event.stopPropagation();
166
170
  const value = this.getInputNode()?.value;
167
- if (value != null && value !== '') {
171
+ if (value) {
168
172
  this.handleTagCreation(value);
169
173
  }
170
174
  return true;
171
175
  }
176
+ // eslint-disable-next-line no-underscore-dangle
172
177
  if (this.select?._popup?.isVisible()) {
173
178
  return true;
174
179
  }
175
180
  if (key === 'ArrowLeft') {
176
- if (this.getInputNode() && this.caret != null && Number(this.caret.getPosition()) > 0) {
181
+ if (this.getInputNode() && this.caret && Number(this.caret?.getPosition()) > 0) {
177
182
  return true;
178
183
  }
179
184
  this.selectTag();
@@ -195,12 +200,13 @@ export default class TagsInput extends PureComponent {
195
200
  if (key === 'Backspace' && !this.getInputNode()?.value) {
196
201
  event.preventDefault();
197
202
  const tagsLength = this.state.tags.length;
203
+ // eslint-disable-next-line no-underscore-dangle
198
204
  this.select?._hidePopup(true); // otherwise confirmation may be overlapped by popup
199
205
  this.onRemoveTag(this.state.tags[tagsLength - 1]);
200
206
  return false;
201
207
  }
202
208
  if ((key === 'Delete' || key === 'Backspace') &&
203
- this.state.activeIndex != null &&
209
+ this.state.activeIndex &&
204
210
  this.state.tags[this.state.activeIndex]) {
205
211
  this.onRemoveTag(this.state.tags[this.state.activeIndex]).then(() => this.selectTag(true));
206
212
  return false;
@@ -228,7 +234,7 @@ export default class TagsInput extends PureComponent {
228
234
  }, this.props.className);
229
235
  return (_jsxs("div", {
230
236
  // it transfers focus to input
231
- role: "presentation", className: classes, onKeyDown: this.handleKeyDown, onClick: this.clickHandler, ref: this.nodeRef, children: [label && (_jsx(ControlLabel, { htmlFor: this.id, disabled: disabled, type: labelType, children: label })), _jsx(TagsList, { tags: tags, activeIndex: activeIndex, disabled: disabled, canNotBeEmpty: canNotBeEmpty, handleRemove: this.handleRemove, className: styles.tagsList, tagClassName: styles.tag, handleClick: this.handleClick, customTagComponent: this.props.customTagComponent, children: _jsx(Select, { id: this.id, ref: this.selectRef, size: Select.Size.AUTO, type: Select.Type.INPUT_WITHOUT_CONTROLS, inputPlaceholder: this.props.placeholder, data: this.state.suggestions, className: classNames(styles.tagsSelect), onSelect: this.addTag, onFocus: this._focusHandler, onBlur: this._blurHandler, renderOptimization: this.props.renderOptimization, add: allowAddNewTags ? { prefix: 'Add new tag' } : undefined, onAdd: allowAddNewTags ? this.handleTagCreation : undefined, filter: filter, maxHeight: this.props.maxPopupHeight, minWidth: this.props.minPopupWidth, top: POPUP_VERTICAL_SHIFT, loading: this.state.loading, onFilter: this.loadSuggestions, onBeforeOpen: this.loadSuggestions, onKeyDown: this.handleKeyDown, disabled: this.props.disabled, loadingMessage: this.props.loadingMessage, notFoundMessage: this.props.notFoundMessage, hint: this.props.hint }) })] }));
237
+ role: 'presentation', className: classes, onKeyDown: this.handleKeyDown, onClick: this.clickHandler, ref: this.nodeRef, children: [label && (_jsx(ControlLabel, { htmlFor: this.id, disabled: disabled, type: labelType, children: label })), _jsx(TagsList, { tags: tags, activeIndex: activeIndex, disabled: disabled, canNotBeEmpty: canNotBeEmpty, handleRemove: this.handleRemove, className: styles.tagsList, tagClassName: styles.tag, handleClick: this.handleClick, customTagComponent: this.props.customTagComponent, children: _jsx(Select, { id: this.id, ref: this.selectRef, size: Select.Size.AUTO, type: Select.Type.INPUT_WITHOUT_CONTROLS, inputPlaceholder: this.props.placeholder, data: this.state.suggestions, className: classNames(styles.tagsSelect), onSelect: this.addTag, onFocus: this._focusHandler, onBlur: this._blurHandler, renderOptimization: this.props.renderOptimization, add: allowAddNewTags ? { prefix: 'Add new tag' } : undefined, onAdd: allowAddNewTags ? this.handleTagCreation : undefined, filter: filter, maxHeight: this.props.maxPopupHeight, minWidth: this.props.minPopupWidth, top: POPUP_VERTICAL_SHIFT, loading: this.state.loading, onFilter: this.loadSuggestions, onBeforeOpen: this.loadSuggestions, onKeyDown: this.handleKeyDown, disabled: this.props.disabled, loadingMessage: this.props.loadingMessage, notFoundMessage: this.props.notFoundMessage, hint: this.props.hint }) })] }));
232
238
  }
233
239
  }
234
240
  export const RerenderableTagsInput = rerenderHOC(TagsInput);
@@ -1,6 +1,6 @@
1
- import { Component, ComponentType, HTMLAttributes, ReactNode } from 'react';
1
+ import { Component, type ComponentType, type HTMLAttributes, type ReactNode } from 'react';
2
2
  import * as React from 'react';
3
- import { TagAttrs } from '../tag/tag';
3
+ import { type TagAttrs } from '../tag/tag';
4
4
  declare function noop(): void;
5
5
  export interface TagType extends Omit<TagAttrs, 'onClick' | 'children'> {
6
6
  label?: ReactNode;
@@ -25,6 +25,6 @@ export default class TagsList extends Component {
25
25
  const { children, className, customTagComponent, canNotBeEmpty, handleClick, tagClassName, handleRemove, tags, activeIndex, ...props } = this.props;
26
26
  const classes = classNames('ring-js-shortcuts', className);
27
27
  const tagsList = (this.props.tags || []).map((tag, index) => this.renderTag(tag, this.props.activeIndex === index));
28
- return (_jsxs("div", { "data-test": "ring-tags-list", className: classes, ...props, children: [tagsList, children] }));
28
+ return (_jsxs("div", { "data-test": 'ring-tags-list', className: classes, ...props, children: [tagsList, children] }));
29
29
  }
30
30
  }
@@ -1,4 +1,4 @@
1
- @import "../global/variables.css";
1
+ @import '../global/variables.css';
2
2
 
3
3
  .text {
4
4
  color: var(--ring-text-color);
@@ -1,4 +1,4 @@
1
- import { Component, HTMLAttributes } from 'react';
1
+ import { Component, type HTMLAttributes } from 'react';
2
2
  declare const TextSizes: {
3
3
  readonly S: "s";
4
4
  readonly M: "m";
@@ -1,4 +1,4 @@
1
- @import "../global/variables.css";
1
+ @import '../global/variables.css';
2
2
 
3
3
  .toggle {
4
4
  --ring-toggle-padding: 2px;
@@ -94,7 +94,7 @@
94
94
  width: calc(var(--ring-unit) * 1.5);
95
95
  height: calc(var(--ring-unit) * 1.5);
96
96
 
97
- content: "";
97
+ content: '';
98
98
 
99
99
  transition: transform var(--ring-toggle-timing-function) var(--ring-toggle-duration);
100
100
 
@@ -1,4 +1,4 @@
1
- import { InputHTMLAttributes, PureComponent, ReactNode } from 'react';
1
+ import { type InputHTMLAttributes, PureComponent, type ReactNode } from 'react';
2
2
  export declare const Size: {
3
3
  Size14: string;
4
4
  Size16: string;
@@ -16,7 +16,7 @@ class Toggle extends PureComponent {
16
16
  render() {
17
17
  const { className, children, disabled, title, leftLabel, size = Size.Size16, 'data-test': dataTest, help, onTransitionEnd, ...restProps } = this.props;
18
18
  const classes = classNames(className, size, styles.toggle, disabled && styles.disabled);
19
- return (_jsxs("label", { className: classes, title: title, "data-test": dataTests('ring-toggle', dataTest), children: [leftLabel && (_jsxs("span", { className: styles.leftLabel, children: [leftLabel, help && _jsx(ControlHelp, { className: styles.help, children: help })] })), _jsxs("span", { className: styles.switchWrapper, children: [_jsx("input", { "data-test": "ring-toggle-input", ...restProps, type: "checkbox", disabled: disabled, className: styles.input }), _jsx("span", { className: styles.switch, onTransitionEnd: onTransitionEnd })] }), children && (_jsxs("div", { className: styles.label, children: [children, help && _jsx(ControlHelp, { className: styles.help, children: help })] }))] }));
19
+ return (_jsxs("label", { className: classes, title: title, "data-test": dataTests('ring-toggle', dataTest), children: [leftLabel && (_jsxs("span", { className: styles.leftLabel, children: [leftLabel, help && _jsx(ControlHelp, { className: styles.help, children: help })] })), _jsxs("span", { className: styles.switchWrapper, children: [_jsx("input", { "data-test": 'ring-toggle-input', ...restProps, type: 'checkbox', disabled: disabled, className: styles.input }), _jsx("span", { className: styles.switch, onTransitionEnd: onTransitionEnd })] }), children && (_jsxs("div", { className: styles.label, children: [children, help && _jsx(ControlHelp, { className: styles.help, children: help })] }))] }));
20
20
  }
21
21
  }
22
22
  export default Toggle;
@@ -1,4 +1,4 @@
1
- @import "../global/variables.css";
1
+ @import '../global/variables.css';
2
2
 
3
3
  :root,
4
4
  :host {
@@ -1,6 +1,6 @@
1
1
  import * as React from 'react';
2
- import { AllHTMLAttributes, Component, ReactNode } from 'react';
3
- import Popup, { PopupAttrs } from '../popup/popup';
2
+ import { type AllHTMLAttributes, Component, type ReactNode } from 'react';
3
+ import Popup, { type PopupAttrs } from '../popup/popup';
4
4
  import { Listeners } from '../global/dom';
5
5
  import Theme from '../global/theme';
6
6
  interface Context {
@@ -89,7 +89,7 @@ export default class Tooltip extends Component {
89
89
  this.setState({ showPopup: false });
90
90
  };
91
91
  addListeners() {
92
- if (this.containerNode != null) {
92
+ if (this.containerNode) {
93
93
  this.listeners.add(this.containerNode, 'mouseenter', this.tryToShowPopup);
94
94
  this.listeners.add(this.containerNode, 'mouseleave', ev => {
95
95
  if (ev.relatedTarget && this.popup?.container?.contains(ev.relatedTarget)) {
@@ -1,4 +1,4 @@
1
- @import "../global/variables.css";
1
+ @import '../global/variables.css';
2
2
 
3
3
  .upload {
4
4
  --ring-upload-text-color: var(--ring-secondary-color);
@@ -1,4 +1,4 @@
1
- import { ReactNode } from 'react';
1
+ import { type ReactNode } from 'react';
2
2
  export type UploadVariant = 'empty' | 'error' | 'success';
3
3
  interface Props {
4
4
  className?: string;
@@ -12,8 +12,8 @@ interface Props {
12
12
  variant?: UploadVariant;
13
13
  children?: ReactNode;
14
14
  }
15
- export type UploadHandle = {
15
+ export interface UploadHandle {
16
16
  openFilePicker: () => void;
17
- };
17
+ }
18
18
  export declare const Upload: import("react").ForwardRefExoticComponent<Props & import("react").RefAttributes<UploadHandle>>;
19
19
  export default Upload;
@@ -1,5 +1,5 @@
1
1
  import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
2
- import { forwardRef, useCallback, useImperativeHandle, useRef, useState } from 'react';
2
+ import { forwardRef, useCallback, useImperativeHandle, useRef, useState, } from 'react';
3
3
  import classNames from 'classnames';
4
4
  import attachmentIcon from '@jetbrains/icons/attachment';
5
5
  import Icon from '../icon';
@@ -33,6 +33,6 @@ export const Upload = forwardRef(function Upload({ children, className, onFilesS
33
33
  [styles.dragOver]: dragOver,
34
34
  [styles.success]: variant === 'success',
35
35
  [styles.error]: variant === 'error',
36
- }), "data-test": "ring-upload", children: [_jsx("input", { onDragEnter: onDragEnter, onDragOver: onDragOver, onDragLeave: onDragLeave, disabled: disabled, ref: fileInputRef, "data-test": "ring-file-input", multiple: multiple, accept: accept, onChange: onInputChange, type: "file", autoComplete: "off", "aria-label": "file-picker", className: styles.invisibleFileInput }), renderIcon(), children] }));
36
+ }), "data-test": 'ring-upload', children: [_jsx("input", { onDragEnter: onDragEnter, onDragOver: onDragOver, onDragLeave: onDragLeave, disabled: disabled, ref: fileInputRef, "data-test": 'ring-file-input', multiple: multiple, accept: accept, onChange: onInputChange, type: 'file', autoComplete: 'off', "aria-label": 'file-picker', className: styles.invisibleFileInput }), renderIcon(), children] }));
37
37
  });
38
38
  export default Upload;
@@ -1,6 +1,6 @@
1
- import { ReactNode } from 'react';
1
+ import { type ReactNode } from 'react';
2
2
  import Storage from '../storage/storage';
3
- import { UserAgreementAttrs, UserAgreementTranslations } from './user-agreement';
3
+ import { type UserAgreementAttrs, type UserAgreementTranslations } from './user-agreement';
4
4
  export declare const showMessage = "userAgreementShow";
5
5
  export declare const hideMessage = "userAgreementHide";
6
6
  export interface Consent {
@@ -71,7 +71,7 @@ export default class UserAgreementService {
71
71
  this.hideDialog();
72
72
  };
73
73
  onStorageEvent = (event) => {
74
- if (event.key === storageKey && event.newValue != null) {
74
+ if (event.key === storageKey && event.newValue) {
75
75
  const { tabId, command } = JSON.parse(event.newValue);
76
76
  if (tabId !== this.tabId) {
77
77
  if (command === showMessage) {
@@ -108,9 +108,7 @@ export default class UserAgreementService {
108
108
  if (await this.checkConsent()) {
109
109
  return this.hideDialogAndAlert(withoutNotifications);
110
110
  }
111
- else {
112
- return this.showDialogOrAlert(withoutNotifications);
113
- }
111
+ return this.showDialogOrAlert(withoutNotifications);
114
112
  };
115
113
  checkConsent = async () => {
116
114
  if (!this.checkingPromise) {
@@ -138,7 +136,7 @@ export default class UserAgreementService {
138
136
  this.hideAlert(withoutNotifications);
139
137
  resolve();
140
138
  };
141
- const message = (_jsxs(Group, { children: [_jsx("span", { children: userAgreement || 'User Agreement' }), _jsx(Link, { onClick: onReview, "data-test": "review", children: reviewNow || 'Review now' }), _jsx(Link, { onClick: onRemind, "data-test": "later", children: remindLater || 'Remind me later' })] }));
139
+ const message = (_jsxs(Group, { children: [_jsx("span", { children: userAgreement || 'User Agreement' }), _jsx(Link, { onClick: onReview, "data-test": 'review', children: reviewNow || 'Review now' }), _jsx(Link, { onClick: onRemind, "data-test": 'later', children: remindLater || 'Remind me later' })] }));
142
140
  this.alertKey = alertService.addAlert(message, Alert.Type.WARNING, 0, { closeable: false });
143
141
  });
144
142
  if (!withoutNotifications) {
@@ -1,6 +1,6 @@
1
- @import "../global/variables.css";
1
+ @import '../global/variables.css';
2
2
 
3
- @value extra-small-screen-media from "../global/global.css";
3
+ @value extra-small-screen-media from '../global/global.css';
4
4
 
5
5
  .agreementDialog {
6
6
  padding-bottom: 80px;
@@ -1,7 +1,7 @@
1
1
  /**
2
2
  * @name User Agreement
3
3
  */
4
- import { PureComponent, ReactNode } from 'react';
4
+ import { PureComponent, type ReactNode } from 'react';
5
5
  declare function noop(): void;
6
6
  export interface UserAgreementTranslations {
7
7
  userAgreement: string;
@@ -28,6 +28,6 @@ export default class UserAgreement extends PureComponent {
28
28
  render() {
29
29
  const { scrolledDown } = this.state;
30
30
  const { translations, onAccept, onDecline, onClose, onRemindLater, children, show, preview, className } = this.props;
31
- return (_jsx(I18nContext.Consumer, { children: ({ translate }) => (_jsxs(Dialog, { label: translations?.userAgreement ?? translate('userAgreement'), show: show, className: classNames(style.agreementDialog, className), contentClassName: style.dialogContent, trapFocus: true, autoFocusFirst: false, "data-test": "user-agreement", children: [_jsx(Header, { children: translations?.userAgreement ?? translate('userAgreement') }), _jsx(Content, { tabIndex: 0, fade: true, onScrollToBottom: this.onScrollToBottom, children: children }), !preview && (_jsxs(Panel, { children: [onRemindLater && !scrolledDown && (_jsx("div", { className: style.suggestion, children: translations?.scrollToAccept ?? translate('scrollToAccept') })), _jsx(Button, { primary: true, disabled: !scrolledDown, onClick: onAccept, "data-test": "accept", children: translations?.accept ?? translate('accept') }), _jsx(Button, { onClick: onDecline, autoFocus: true, "data-test": "decline", children: translations?.decline ?? translate('decline') }), !onRemindLater && !scrolledDown && (_jsx("span", { className: style.suggestion, children: translations?.scrollToAccept ?? translate('scrollToAccept') })), onRemindLater && (_jsx(Button, { className: style.remindLaterButton, onClick: onRemindLater, "data-test": "later", children: translations?.remindLater ?? translate('remindLater') }))] })), preview && (_jsx(Panel, { children: _jsx(Button, { onClick: onClose, autoFocus: true, "data-test": "close", children: translations?.close ?? translate('close') }) }))] })) }));
31
+ return (_jsx(I18nContext.Consumer, { children: ({ translate }) => (_jsxs(Dialog, { label: translations?.userAgreement ?? translate('userAgreement'), show: show, className: classNames(style.agreementDialog, className), contentClassName: style.dialogContent, trapFocus: true, autoFocusFirst: false, "data-test": 'user-agreement', children: [_jsx(Header, { children: translations?.userAgreement ?? translate('userAgreement') }), _jsx(Content, { tabIndex: 0, fade: true, onScrollToBottom: this.onScrollToBottom, children: children }), !preview && (_jsxs(Panel, { children: [onRemindLater && !scrolledDown && (_jsx("div", { className: style.suggestion, children: translations?.scrollToAccept ?? translate('scrollToAccept') })), _jsx(Button, { primary: true, disabled: !scrolledDown, onClick: onAccept, "data-test": 'accept', children: translations?.accept ?? translate('accept') }), _jsx(Button, { onClick: onDecline, autoFocus: true, "data-test": 'decline', children: translations?.decline ?? translate('decline') }), !onRemindLater && !scrolledDown && (_jsx("span", { className: style.suggestion, children: translations?.scrollToAccept ?? translate('scrollToAccept') })), onRemindLater && (_jsx(Button, { className: style.remindLaterButton, onClick: onRemindLater, "data-test": 'later', children: translations?.remindLater ?? translate('remindLater') }))] })), preview && (_jsx(Panel, { children: _jsx(Button, { onClick: onClose, autoFocus: true, "data-test": 'close', children: translations?.close ?? translate('close') }) }))] })) }));
32
32
  }
33
33
  }
@@ -1,4 +1,4 @@
1
- import { HTMLAttributes, PureComponent, ReactElement } from 'react';
1
+ import { type HTMLAttributes, PureComponent, type ReactElement } from 'react';
2
2
  import * as React from 'react';
3
3
  export interface UserCardUser {
4
4
  name: string;