chuijs 4.0.3 → 4.0.4

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 (258) hide show
  1. package/CHANGELOG.md +536 -0
  2. package/framework/appLayout/default/chui_app_layout.js +361 -303
  3. package/framework/appLayout/default/global_style.css +243 -89
  4. package/framework/appLayout/default/main_theme_style.css +188 -101
  5. package/framework/components/chui_accordion/accordion.js +17 -17
  6. package/framework/components/chui_accordion/styles.css +7 -7
  7. package/framework/components/chui_action_sheet/action_sheet.js +35 -32
  8. package/framework/components/chui_action_sheet/styles.css +10 -4
  9. package/framework/components/chui_actions_bar/actions_bar.js +338 -0
  10. package/framework/components/chui_actions_bar/styles.css +139 -0
  11. package/framework/components/chui_affix/affix.js +4 -4
  12. package/framework/components/chui_affix/styles.css +5 -0
  13. package/framework/components/chui_alert/alert.js +11 -5
  14. package/framework/components/chui_alert/styles.css +7 -0
  15. package/framework/components/chui_avatar/avatar.js +13 -13
  16. package/framework/components/chui_avatar/styles.css +1 -1
  17. package/framework/components/chui_avatar_group/avatar_group.js +4 -4
  18. package/framework/components/chui_avatar_group/styles.css +1 -1
  19. package/framework/components/chui_backtop/backtop.js +25 -2
  20. package/framework/components/chui_backtop/styles.css +21 -0
  21. package/framework/components/chui_badge/badge.js +15 -15
  22. package/framework/components/chui_badge/styles.css +6 -6
  23. package/framework/components/chui_banner/banner.js +222 -0
  24. package/framework/components/chui_banner/styles.css +170 -0
  25. package/framework/components/chui_breadcrumb/styles.css +1 -1
  26. package/framework/components/chui_button/button.js +24 -28
  27. package/framework/components/chui_button/styles.css +5 -5
  28. package/framework/components/chui_calendar/calendar.js +6 -6
  29. package/framework/components/chui_card/card.js +14 -14
  30. package/framework/components/chui_card_scroll/card_scroll.js +169 -0
  31. package/framework/components/chui_card_scroll/styles.css +86 -0
  32. package/framework/components/chui_chat/chat.js +73 -51
  33. package/framework/components/chui_chat/styles.css +18 -7
  34. package/framework/components/chui_clipboard_history/clipboard_history.js +25 -20
  35. package/framework/components/chui_clipboard_history/styles.css +10 -8
  36. package/framework/components/chui_code/code.js +8 -8
  37. package/framework/components/chui_code/styles.css +2 -2
  38. package/framework/components/chui_code_editor/code_editor.js +26 -26
  39. package/framework/components/chui_code_editor/styles.css +3 -3
  40. package/framework/components/chui_command_palette/command_palette.js +29 -29
  41. package/framework/components/chui_command_palette/styles.css +5 -5
  42. package/framework/components/chui_console/console.js +9 -9
  43. package/framework/components/chui_console/styles.css +5 -2
  44. package/framework/components/chui_content_block/content_block.js +2 -2
  45. package/framework/components/chui_context_menu/context_menu.js +162 -54
  46. package/framework/components/chui_context_menu/styles.css +82 -8
  47. package/framework/components/chui_custom_element/custom_element.js +11 -11
  48. package/framework/components/chui_data_grid/data_grid.js +268 -268
  49. package/framework/components/chui_data_grid/styles.css +14 -14
  50. package/framework/components/chui_descriptions/styles.css +1 -1
  51. package/framework/components/chui_details/details.js +12 -12
  52. package/framework/components/chui_details/styles.css +7 -7
  53. package/framework/components/chui_diff_viewer/diff_viewer.js +88 -88
  54. package/framework/components/chui_diff_viewer/styles.css +9 -9
  55. package/framework/components/chui_divider/divider.js +6 -6
  56. package/framework/components/chui_divider/styles.css +2 -2
  57. package/framework/components/chui_drawer/drawer.js +37 -14
  58. package/framework/components/chui_drawer/styles.css +18 -4
  59. package/framework/components/chui_drop_zone/drop_zone.js +6 -6
  60. package/framework/components/chui_drop_zone/styles.css +10 -6
  61. package/framework/components/chui_fieldset/fieldset.js +6 -6
  62. package/framework/components/chui_fieldset/styles.css +5 -5
  63. package/framework/components/chui_file_explorer/file_explorer.js +115 -115
  64. package/framework/components/chui_file_explorer/styles.css +6 -6
  65. package/framework/components/chui_form/form.js +11 -11
  66. package/framework/components/chui_gantt/gantt.js +41 -41
  67. package/framework/components/chui_gantt/styles.css +5 -5
  68. package/framework/components/chui_graphs/graphs.js +82 -46
  69. package/framework/components/chui_graphs/styles.css +26 -5
  70. package/framework/components/chui_hero/hero.js +63 -20
  71. package/framework/components/chui_hero/styles.css +176 -7
  72. package/framework/components/chui_html_block/html_block.js +5 -5
  73. package/framework/components/chui_html_block/styles.css +1 -1
  74. package/framework/components/chui_hx/styles.css +2 -2
  75. package/framework/components/chui_icons/icons.js +7 -7
  76. package/framework/components/chui_icons/styles.css +2 -1
  77. package/framework/components/chui_inputs/chui_check_box/styles.css +12 -3
  78. package/framework/components/chui_inputs/chui_chips/chips.js +92 -31
  79. package/framework/components/chui_inputs/chui_chips/styles.css +28 -5
  80. package/framework/components/chui_inputs/chui_color_picker/color_picker.js +20 -15
  81. package/framework/components/chui_inputs/chui_color_picker/styles.css +7 -7
  82. package/framework/components/chui_inputs/chui_combo_box/combo_box.js +58 -58
  83. package/framework/components/chui_inputs/chui_combo_box/styles.css +9 -9
  84. package/framework/components/chui_inputs/chui_date/date.js +93 -95
  85. package/framework/components/chui_inputs/chui_date/styles.css +8 -8
  86. package/framework/components/chui_inputs/chui_date_range/date_range.js +22 -22
  87. package/framework/components/chui_inputs/chui_date_range/styles.css +3 -3
  88. package/framework/components/chui_inputs/chui_datetime/datetime.js +12 -12
  89. package/framework/components/chui_inputs/chui_datetime/styles.css +3 -3
  90. package/framework/components/chui_inputs/chui_email/email.js +10 -10
  91. package/framework/components/chui_inputs/chui_email/styles.css +6 -6
  92. package/framework/components/chui_inputs/chui_file/file.js +8 -8
  93. package/framework/components/chui_inputs/chui_file/styles.css +12 -9
  94. package/framework/components/chui_inputs/chui_hotkey/hotkey.js +39 -39
  95. package/framework/components/chui_inputs/chui_hotkey/styles.css +6 -6
  96. package/framework/components/chui_inputs/chui_masked/masked.js +44 -44
  97. package/framework/components/chui_inputs/chui_masked/styles.css +5 -5
  98. package/framework/components/chui_inputs/chui_mention/mention.js +13 -13
  99. package/framework/components/chui_inputs/chui_mention/styles.css +14 -8
  100. package/framework/components/chui_inputs/chui_multi_combo_box/multi_combo_box.js +147 -137
  101. package/framework/components/chui_inputs/chui_multi_combo_box/styles.css +14 -8
  102. package/framework/components/chui_inputs/chui_number/number.js +42 -45
  103. package/framework/components/chui_inputs/chui_number/styles.css +6 -6
  104. package/framework/components/chui_inputs/chui_otp/otp.js +32 -32
  105. package/framework/components/chui_inputs/chui_otp/styles.css +5 -5
  106. package/framework/components/chui_inputs/chui_password/password.js +30 -36
  107. package/framework/components/chui_inputs/chui_password/styles.css +7 -7
  108. package/framework/components/chui_inputs/chui_radio_button/styles.css +2 -2
  109. package/framework/components/chui_inputs/chui_rating/rating.js +28 -28
  110. package/framework/components/chui_inputs/chui_rating/styles.css +3 -3
  111. package/framework/components/chui_inputs/chui_select_box/select_box.js +54 -54
  112. package/framework/components/chui_inputs/chui_select_box/styles.css +10 -10
  113. package/framework/components/chui_inputs/chui_slider/slider.js +14 -14
  114. package/framework/components/chui_inputs/chui_slider/styles.css +5 -4
  115. package/framework/components/chui_inputs/chui_text/styles.css +7 -7
  116. package/framework/components/chui_inputs/chui_text/text.js +13 -17
  117. package/framework/components/chui_inputs/chui_text_area/styles.css +8 -8
  118. package/framework/components/chui_inputs/chui_text_area/text_area.js +23 -23
  119. package/framework/components/chui_inputs/chui_time/styles.css +13 -17
  120. package/framework/components/chui_inputs/chui_time/time.js +35 -24
  121. package/framework/components/chui_inputs/chui_toggle/styles.css +10 -3
  122. package/framework/components/chui_inputs/chui_toggle/toggle.js +16 -16
  123. package/framework/components/chui_json_editor/json_editor.js +87 -87
  124. package/framework/components/chui_json_editor/styles.css +5 -5
  125. package/framework/components/chui_json_viewer/json_viewer.js +80 -80
  126. package/framework/components/chui_json_viewer/styles.css +6 -6
  127. package/framework/components/chui_kanban/kanban.js +27 -27
  128. package/framework/components/chui_kanban/styles.css +8 -4
  129. package/framework/components/chui_kbd/styles.css +1 -1
  130. package/framework/components/chui_label/label.js +17 -17
  131. package/framework/components/chui_label/styles.css +1 -1
  132. package/framework/components/chui_link/link.js +9 -9
  133. package/framework/components/chui_link/styles.css +11 -4
  134. package/framework/components/chui_list/list.js +11 -11
  135. package/framework/components/chui_list/styles.css +2 -2
  136. package/framework/components/chui_markdown_editor/markdown_editor.js +66 -66
  137. package/framework/components/chui_markdown_editor/styles.css +5 -5
  138. package/framework/components/chui_media/audio.js +240 -246
  139. package/framework/components/chui_media/audio_styles.css +41 -23
  140. package/framework/components/chui_media/image.js +49 -46
  141. package/framework/components/chui_media/image_compare.js +35 -35
  142. package/framework/components/chui_media/image_compare_styles.css +5 -5
  143. package/framework/components/chui_media/image_styles.css +1 -1
  144. package/framework/components/chui_media/video.js +148 -148
  145. package/framework/components/chui_media/video_styles.css +27 -11
  146. package/framework/components/chui_menu_bar/menu_bar.js +54 -54
  147. package/framework/components/chui_menu_bar/styles.css +10 -10
  148. package/framework/components/chui_message_bar/message_bar.js +551 -0
  149. package/framework/components/chui_message_bar/styles.css +248 -0
  150. package/framework/components/chui_modal/modal.js +37 -13
  151. package/framework/components/chui_notification/notification.js +76 -54
  152. package/framework/components/chui_notification/notification_download.js +26 -81
  153. package/framework/components/chui_notification/notification_download_card.js +115 -0
  154. package/framework/components/chui_notification/notification_download_progress.css +2 -2
  155. package/framework/components/chui_notification/notification_download_progress.js +70 -108
  156. package/framework/components/chui_notification/notification_update.js +31 -31
  157. package/framework/components/chui_notification/status_plate.css +3 -3
  158. package/framework/components/chui_notification/styles.css +6 -1
  159. package/framework/components/chui_notification/styles_download.css +1 -1
  160. package/framework/components/chui_notification/styles_update.css +2 -2
  161. package/framework/components/chui_org_chart/org_chart.js +29 -29
  162. package/framework/components/chui_org_chart/styles.css +2 -2
  163. package/framework/components/chui_pagination/pagination.js +3 -3
  164. package/framework/components/chui_pagination/styles.css +1 -1
  165. package/framework/components/chui_paragraph/styles.css +2 -2
  166. package/framework/components/chui_popover/popover.js +29 -23
  167. package/framework/components/chui_popover/styles.css +1 -1
  168. package/framework/components/chui_popups/popups.js +124 -124
  169. package/framework/components/chui_popups/styles.css +5 -5
  170. package/framework/components/chui_print_button/print_button.js +15 -10
  171. package/framework/components/chui_progress_bar/progress_bar.js +34 -12
  172. package/framework/components/chui_progress_bar/styles.css +4 -4
  173. package/framework/components/chui_progress_ring/progress_ring.js +15 -15
  174. package/framework/components/chui_progress_ring/styles.css +1 -1
  175. package/framework/components/chui_qrcode/qrcode.js +12 -12
  176. package/framework/components/chui_query_builder/query_builder.js +46 -46
  177. package/framework/components/chui_query_builder/styles.css +4 -4
  178. package/framework/components/chui_radio_group/styles.css +1 -1
  179. package/framework/components/chui_result/result.js +15 -15
  180. package/framework/components/chui_result/styles.css +3 -3
  181. package/framework/components/chui_scheduler/scheduler.js +74 -74
  182. package/framework/components/chui_scheduler/styles.css +5 -5
  183. package/framework/components/chui_screen_spinner/screen_spinner.js +167 -0
  184. package/framework/components/chui_screen_spinner/styles.css +49 -0
  185. package/framework/components/chui_segmented_control/segmented_control.js +63 -6
  186. package/framework/components/chui_segmented_control/styles.css +32 -6
  187. package/framework/components/chui_settings/settings.js +45 -46
  188. package/framework/components/chui_settings/styles.css +4 -4
  189. package/framework/components/chui_shortcut_help/shortcut_help.js +32 -34
  190. package/framework/components/chui_sidebar_nav/sidebar_nav.js +98 -29
  191. package/framework/components/chui_sidebar_nav/styles.css +9 -3
  192. package/framework/components/chui_slideshow/slideshow.js +85 -85
  193. package/framework/components/chui_slideshow/styles.css +6 -6
  194. package/framework/components/chui_spinner/spinner.js +10 -10
  195. package/framework/components/chui_split_button/split_button.js +30 -12
  196. package/framework/components/chui_split_button/styles.css +21 -5
  197. package/framework/components/chui_splitter/splitter.js +11 -11
  198. package/framework/components/chui_splitter/styles.css +2 -2
  199. package/framework/components/chui_statistic/statistic.js +47 -47
  200. package/framework/components/chui_status_bar/styles.css +2 -2
  201. package/framework/components/chui_stepper/stepper.js +202 -31
  202. package/framework/components/chui_stepper/styles.css +79 -14
  203. package/framework/components/chui_sticky_bar/sticky_bar.js +44 -13
  204. package/framework/components/chui_sticky_bar/styles.css +10 -8
  205. package/framework/components/chui_tabs/chui_tabs.js +74 -26
  206. package/framework/components/chui_tabs/styles.css +40 -12
  207. package/framework/components/chui_text_editor/styles.css +7 -7
  208. package/framework/components/chui_text_editor/text_editor.js +56 -56
  209. package/framework/components/chui_text_editor/text_editor_panel.js +173 -174
  210. package/framework/components/chui_theme_toggle/theme_toggle.js +21 -5
  211. package/framework/components/chui_timeline/styles.css +3 -1
  212. package/framework/components/chui_toast_queue/styles.css +11 -11
  213. package/framework/components/chui_toast_queue/toast_queue.js +30 -27
  214. package/framework/components/chui_toolbar/styles.css +2 -2
  215. package/framework/components/chui_tooltip/styles.css +2 -2
  216. package/framework/components/chui_tooltip/tooltip.js +3 -3
  217. package/framework/components/chui_tour/styles.css +8 -8
  218. package/framework/components/chui_tour/tour.js +72 -72
  219. package/framework/components/chui_transfer/styles.css +6 -6
  220. package/framework/components/chui_transfer/transfer.js +93 -106
  221. package/framework/components/chui_tree_table/styles.css +4 -4
  222. package/framework/components/chui_tree_table/tree_table.js +45 -45
  223. package/framework/components/chui_tree_view/styles.css +10 -8
  224. package/framework/components/chui_tree_view/tree_view.js +185 -183
  225. package/framework/components/chui_user_bar/styles.css +145 -0
  226. package/framework/components/chui_user_bar/user_bar.js +402 -0
  227. package/framework/components/chui_user_list_bar/styles.css +173 -0
  228. package/framework/components/chui_user_list_bar/user_list_bar.js +485 -0
  229. package/framework/components/chui_watermark/watermark.js +17 -17
  230. package/framework/components/chui_webview/webview.js +9 -9
  231. package/framework/components/chui_write_bar/styles.css +172 -0
  232. package/framework/components/chui_write_bar/write_bar.js +320 -0
  233. package/framework/main_window.js +1234 -0
  234. package/framework/modules/chui_a11y/chui_a11y.js +78 -79
  235. package/framework/modules/chui_animations/animations.js +77 -15
  236. package/framework/modules/chui_animations/motion.js +120 -0
  237. package/framework/modules/chui_animations/styles.css +36 -3
  238. package/framework/modules/chui_functions.js +31 -27
  239. package/framework/modules/chui_highlight/styles.css +13 -10
  240. package/framework/modules/chui_i18n/chui_i18n.js +3 -3
  241. package/framework/modules/chui_i18n/locales/feedback.js +62 -0
  242. package/framework/modules/chui_i18n/locales/navigation.js +4 -0
  243. package/framework/modules/chui_json/chui_json.js +2 -2
  244. package/framework/modules/chui_logger/chui_logger.js +23 -8
  245. package/framework/modules/chui_page/page.js +10 -10
  246. package/framework/modules/chui_palette/palette.js +61 -0
  247. package/framework/modules/chui_qr/chui_qr.js +23 -23
  248. package/framework/modules/chui_scrollbar/chui_scrollbar.js +45 -45
  249. package/framework/modules/chui_scrollbar/styles.css +3 -3
  250. package/framework/modules/chui_services/chui_services.js +8 -8
  251. package/framework/modules/chui_services/desktop.js +77 -71
  252. package/framework/modules/chui_sortable/chui_sortable.js +17 -17
  253. package/framework/modules/chui_validate/chui_validate.js +3 -3
  254. package/framework/tray_bar/chui_menu_items.js +2 -2
  255. package/index.d.ts +266 -34
  256. package/index.js +20 -1168
  257. package/package.json +6 -4
  258. package/framework/components/telegram_bot/chui_telegram_bot.js +0 -191
@@ -36,37 +36,37 @@ class Transfer {
36
36
  #root = document.createElement("chui_transfer");
37
37
  #label = document.createElement("transfer_label");
38
38
  #row = document.createElement("transfer_row");
39
- #source_pane = document.createElement("transfer_pane");
40
- #target_pane = document.createElement("transfer_pane");
41
- #source_head = document.createElement("transfer_head");
42
- #target_head = document.createElement("transfer_head");
43
- #source_list = document.createElement("transfer_list");
44
- #target_list = document.createElement("transfer_list");
45
- #source_search = undefined;
46
- #target_search = undefined;
47
- #arrow_target = document.createElement("button");
48
- #arrow_source = document.createElement("button");
39
+ #sourcePane = document.createElement("transfer_pane");
40
+ #targetPane = document.createElement("transfer_pane");
41
+ #sourceHead = document.createElement("transfer_head");
42
+ #targetHead = document.createElement("transfer_head");
43
+ #sourceList = document.createElement("transfer_list");
44
+ #targetList = document.createElement("transfer_list");
45
+ #sourceSearch = undefined;
46
+ #targetSearch = undefined;
47
+ #arrowTarget = document.createElement("button");
48
+ #arrowSource = document.createElement("button");
49
49
  #hint = document.createElement("transfer_hint");
50
50
  #status = document.createElement("transfer_status");
51
51
  #error = document.createElement("chui_error_message");
52
- #source_roving = undefined;
53
- #target_roving = undefined;
52
+ #sourceRoving = undefined;
53
+ #targetRoving = undefined;
54
54
  #items = [];
55
55
  #marked = new Set();
56
56
  #id = undefined;
57
57
  #name = undefined;
58
- #title_text = undefined;
59
- #label_text = undefined;
60
- #source_title = undefined;
61
- #target_title = undefined;
58
+ #titleText = undefined;
59
+ #labelText = undefined;
60
+ #sourceTitle = undefined;
61
+ #targetTitle = undefined;
62
62
  #searchable = false;
63
63
  #disabled = false;
64
64
  #min = undefined;
65
65
  #max = undefined;
66
66
  #listeners = [];
67
- #on_change = undefined;
67
+ #onChange = undefined;
68
68
  // Строка, к которой нужно вернуть фокус после перерисовки
69
- #focus_value = undefined;
69
+ #focusValue = undefined;
70
70
 
71
71
  constructor(
72
72
  options = {
@@ -91,13 +91,12 @@ class Transfer {
91
91
  Transfer.#counter += 1;
92
92
  this.#id = options.id === undefined ? `chui_transfer_${Transfer.#counter}` : options.id;
93
93
  this.#name = options.name;
94
- this.#label_text = options.label;
95
- this.#on_change = options.onChange;
94
+ this.#labelText = options.label;
95
+ this.#onChange = options.onChange;
96
96
  this.#searchable = options.searchable === true;
97
- this.#source_title =
97
+ this.#sourceTitle =
98
98
  options.sourceTitle === undefined ? I18n.t("transfer.available") : String(options.sourceTitle);
99
- this.#target_title =
100
- options.targetTitle === undefined ? I18n.t("transfer.chosen") : String(options.targetTitle);
99
+ this.#targetTitle = options.targetTitle === undefined ? I18n.t("transfer.chosen") : String(options.targetTitle);
101
100
  this.#min = options.min;
102
101
  this.#max = options.max;
103
102
  this.#root.id = this.#id;
@@ -105,47 +104,35 @@ class Transfer {
105
104
  this.#label.id = `${this.#id}_label`;
106
105
  this.#row.className = "transfer_row";
107
106
  this.#row.setAttribute("role", "group");
108
- this.#list_pane(
109
- this.#source_pane,
110
- this.#source_head,
111
- this.#source_list,
112
- this.#source_title,
113
- Transfer.SIDE.SOURCE
114
- );
115
- this.#list_pane(
116
- this.#target_pane,
117
- this.#target_head,
118
- this.#target_list,
119
- this.#target_title,
120
- Transfer.SIDE.TARGET
121
- );
122
- this.#source_list.addEventListener("click", this.#onClick);
123
- this.#target_list.addEventListener("click", this.#onClick);
124
- this.#source_list.addEventListener("dblclick", this.#onDoubleClick);
125
- this.#target_list.addEventListener("dblclick", this.#onDoubleClick);
126
- this.#source_list.addEventListener("keydown", this.#onKeyDown);
127
- this.#target_list.addEventListener("keydown", this.#onKeyDown);
128
- this.#arrow_target.type = "button";
129
- this.#arrow_source.type = "button";
130
- this.#move_button(
131
- this.#arrow_target,
107
+ this.#listPane(this.#sourcePane, this.#sourceHead, this.#sourceList, this.#sourceTitle, Transfer.SIDE.SOURCE);
108
+ this.#listPane(this.#targetPane, this.#targetHead, this.#targetList, this.#targetTitle, Transfer.SIDE.TARGET);
109
+ this.#sourceList.addEventListener("click", this.#onClick);
110
+ this.#targetList.addEventListener("click", this.#onClick);
111
+ this.#sourceList.addEventListener("dblclick", this.#onDoubleClick);
112
+ this.#targetList.addEventListener("dblclick", this.#onDoubleClick);
113
+ this.#sourceList.addEventListener("keydown", this.#onKeyDown);
114
+ this.#targetList.addEventListener("keydown", this.#onKeyDown);
115
+ this.#arrowTarget.type = "button";
116
+ this.#arrowSource.type = "button";
117
+ this.#moveButton(
118
+ this.#arrowTarget,
132
119
  Transfer.SIDE.TARGET,
133
120
  Icons.NAVIGATION.CHEVRON_RIGHT,
134
- I18n.t("transfer.addMarked", { title: this.#target_title })
121
+ I18n.t("transfer.addMarked", { title: this.#targetTitle })
135
122
  );
136
- this.#move_button(
137
- this.#arrow_source,
123
+ this.#moveButton(
124
+ this.#arrowSource,
138
125
  Transfer.SIDE.SOURCE,
139
126
  Icons.NAVIGATION.CHEVRON_LEFT,
140
- I18n.t("transfer.removeMarked", { title: this.#source_title })
127
+ I18n.t("transfer.removeMarked", { title: this.#sourceTitle })
141
128
  );
142
129
  const controls = document.createElement("transfer_controls");
143
130
  controls.className = "transfer_controls";
144
- controls.appendChild(this.#arrow_target);
145
- controls.appendChild(this.#arrow_source);
146
- this.#row.appendChild(this.#source_pane);
131
+ controls.appendChild(this.#arrowTarget);
132
+ controls.appendChild(this.#arrowSource);
133
+ this.#row.appendChild(this.#sourcePane);
147
134
  this.#row.appendChild(controls);
148
- this.#row.appendChild(this.#target_pane);
135
+ this.#row.appendChild(this.#targetPane);
149
136
  this.#hint.id = `${this.#id}_hint`;
150
137
  this.#hint.className = "transfer_hint";
151
138
  this.#hint.hidden = true;
@@ -159,16 +146,16 @@ class Transfer {
159
146
  this.#root.appendChild(this.#status);
160
147
  if (options.title !== undefined) this.setTitle(options.title);
161
148
  else this.#label.hidden = true;
162
- this.setLabel(this.#label_text === undefined ? I18n.t("transfer.title") : this.#label_text);
149
+ this.setLabel(this.#labelText === undefined ? I18n.t("transfer.title") : this.#labelText);
163
150
  if (options.hint !== undefined) this.setHint(options.hint);
164
151
  // Число выбранных значений сравнивается своим правилом, а не строками
165
- const rules_options = Object.assign({}, options);
166
- delete rules_options.min;
167
- delete rules_options.max;
168
- Validate.installField(this, rules_options, this.#root, this.#error, () => this.getValue(), this.#row);
152
+ const rulesOptions = Object.assign({}, options);
153
+ delete rulesOptions.min;
154
+ delete rulesOptions.max;
155
+ Validate.installField(this, rulesOptions, this.#root, this.#error, () => this.getValue(), this.#row);
169
156
  this.#installRules();
170
- this.#source_roving = new RovingKeyboard(this.#source_list, { itemSelector: ".transfer_item" });
171
- this.#target_roving = new RovingKeyboard(this.#target_list, { itemSelector: ".transfer_item" });
157
+ this.#sourceRoving = new RovingKeyboard(this.#sourceList, { itemSelector: ".transfer_item" });
158
+ this.#targetRoving = new RovingKeyboard(this.#targetList, { itemSelector: ".transfer_item" });
172
159
  this.setItems(options.items);
173
160
  if (options.value !== undefined) this.setValue(options.value);
174
161
  this.setDisabled(options.disabled === true);
@@ -185,12 +172,12 @@ class Transfer {
185
172
  }
186
173
 
187
174
  getTitle() {
188
- return this.#title_text;
175
+ return this.#titleText;
189
176
  }
190
177
 
191
178
  /** Доступное имя группы, заданное в `label` */
192
179
  getLabel() {
193
- return this.#label_text;
180
+ return this.#labelText;
194
181
  }
195
182
 
196
183
  /** Значения выбранного списка по порядку */
@@ -239,7 +226,7 @@ class Transfer {
239
226
 
240
227
  /** Подпись над списками; `undefined` её убирает (имя тогда даёт `label`) */
241
228
  setTitle(text = undefined) {
242
- this.#title_text = text;
229
+ this.#titleText = text;
243
230
  if (text === undefined || text === "") {
244
231
  this.#label.hidden = true;
245
232
  this.#label.innerText = "";
@@ -256,8 +243,8 @@ class Transfer {
256
243
 
257
244
  /** Имя группы, когда подписи в разметке нет */
258
245
  setLabel(text = undefined) {
259
- this.#label_text = text;
260
- if (this.#title_text === undefined || this.#title_text === "") {
246
+ this.#labelText = text;
247
+ if (this.#titleText === undefined || this.#titleText === "") {
261
248
  if (text === undefined) this.#row.removeAttribute("aria-label");
262
249
  else this.#row.setAttribute("aria-label", String(text));
263
250
  }
@@ -350,13 +337,13 @@ class Transfer {
350
337
  setDisabled(disabled = Boolean()) {
351
338
  this.#disabled = disabled === true;
352
339
  this.#root.classList.toggle("transfer_disabled", this.#disabled);
353
- for (const list of [this.#source_list, this.#target_list]) {
340
+ for (const list of [this.#sourceList, this.#targetList]) {
354
341
  if (this.#disabled) list.setAttribute("aria-disabled", "true");
355
342
  else list.removeAttribute("aria-disabled");
356
343
  }
357
- if (this.#source_search !== undefined) {
358
- this.#source_search.disabled = this.#disabled;
359
- this.#target_search.disabled = this.#disabled;
344
+ if (this.#sourceSearch !== undefined) {
345
+ this.#sourceSearch.disabled = this.#disabled;
346
+ this.#targetSearch.disabled = this.#disabled;
360
347
  for (const clear of this.#root.querySelectorAll(".transfer_search_clear")) clear.disabled = this.#disabled;
361
348
  }
362
349
  this.#render();
@@ -372,7 +359,7 @@ class Transfer {
372
359
  /** Фокус на первую строку: `Form` зовёт это при ошибке валидации */
373
360
  focus() {
374
361
  if (this.#disabled) return this;
375
- const list = this.#source_list.querySelector(".transfer_item") === null ? this.#target_list : this.#source_list;
362
+ const list = this.#sourceList.querySelector(".transfer_item") === null ? this.#targetList : this.#sourceList;
376
363
  const row = list.querySelector(".transfer_item");
377
364
  if (row !== null) row.focus();
378
365
  return this;
@@ -385,8 +372,8 @@ class Transfer {
385
372
 
386
373
  // === ВНУТРЕННЕЕ ===
387
374
  #accessibleName() {
388
- if (this.#title_text !== undefined && this.#title_text !== "") return this.#title_text;
389
- if (this.#label_text !== undefined && this.#label_text !== "") return this.#label_text;
375
+ if (this.#titleText !== undefined && this.#titleText !== "") return this.#titleText;
376
+ if (this.#labelText !== undefined && this.#labelText !== "") return this.#labelText;
390
377
  return I18n.t("transfer.title");
391
378
  }
392
379
 
@@ -416,7 +403,7 @@ class Transfer {
416
403
  }
417
404
 
418
405
  // Пара «заголовок + список» одного бока: поиск, список и место под пустое состояние
419
- #list_pane(pane = undefined, head = undefined, list = undefined, title = String(), side = String()) {
406
+ #listPane(pane = undefined, head = undefined, list = undefined, title = String(), side = String()) {
420
407
  pane.className = "transfer_pane";
421
408
  head.className = "transfer_head";
422
409
  head.innerText = title;
@@ -455,8 +442,8 @@ class Transfer {
455
442
  clear.hidden = search.value === "";
456
443
  this.#render();
457
444
  });
458
- if (side === Transfer.SIDE.SOURCE) this.#source_search = search;
459
- else this.#target_search = search;
445
+ if (side === Transfer.SIDE.SOURCE) this.#sourceSearch = search;
446
+ else this.#targetSearch = search;
460
447
  box.appendChild(search);
461
448
  box.appendChild(clear);
462
449
  pane.appendChild(box);
@@ -465,7 +452,7 @@ class Transfer {
465
452
  return pane;
466
453
  }
467
454
 
468
- #move_button(button = undefined, side = String(), icon = String(), label = String()) {
455
+ #moveButton(button = undefined, side = String(), icon = String(), label = String()) {
469
456
  button.className = "transfer_move";
470
457
  button.setAttribute("aria-label", label);
471
458
  button.addEventListener("click", () => this.#moveSelected(side));
@@ -498,30 +485,30 @@ class Transfer {
498
485
  // запомним строку под фокусом, чтобы вернуть его после перерисовки
499
486
  const active = document.activeElement;
500
487
  const focused = active === null || !this.#root.contains(active) ? null : active.closest(".transfer_item");
501
- if (focused !== null) this.#focus_value = focused.dataset.value;
502
- this.#source_list.innerHTML = "";
503
- this.#target_list.innerHTML = "";
504
- const source_filter = this.#filterOf(this.#source_search);
505
- const target_filter = this.#filterOf(this.#target_search);
506
- let source_count = 0;
507
- let target_count = 0;
488
+ if (focused !== null) this.#focusValue = focused.dataset.value;
489
+ this.#sourceList.innerHTML = "";
490
+ this.#targetList.innerHTML = "";
491
+ const sourceFilter = this.#filterOf(this.#sourceSearch);
492
+ const targetFilter = this.#filterOf(this.#targetSearch);
493
+ let sourceCount = 0;
494
+ let targetCount = 0;
508
495
  for (const item of this.#items) {
509
- const list = item.chosen ? this.#target_list : this.#source_list;
510
- const filter = item.chosen ? target_filter : source_filter;
511
- if (item.chosen) target_count += 1;
512
- else source_count += 1;
496
+ const list = item.chosen ? this.#targetList : this.#sourceList;
497
+ const filter = item.chosen ? targetFilter : sourceFilter;
498
+ if (item.chosen) targetCount += 1;
499
+ else sourceCount += 1;
513
500
  if (filter !== "" && !this.#matches(item, filter)) continue;
514
501
  list.appendChild(this.#rowNode(item));
515
502
  }
516
- this.#emptyNode(this.#source_list, this.#source_title, source_filter);
517
- this.#emptyNode(this.#target_list, this.#target_title, target_filter);
518
- this.#source_head.querySelector("transfer_count").innerText = `(${source_count})`;
519
- this.#target_head.querySelector("transfer_count").innerText = `(${target_count})`;
503
+ this.#emptyNode(this.#sourceList, this.#sourceTitle, sourceFilter);
504
+ this.#emptyNode(this.#targetList, this.#targetTitle, targetFilter);
505
+ this.#sourceHead.querySelector("transfer_count").innerText = `(${sourceCount})`;
506
+ this.#targetHead.querySelector("transfer_count").innerText = `(${targetCount})`;
520
507
  this.#applyButtons();
521
508
  this.#restoreFocus();
522
509
  // Остановка обхода подхватывает уже сфокусированную строку, а без неё — первую видимую
523
- if (this.#source_roving !== undefined) this.#source_roving.refresh();
524
- if (this.#target_roving !== undefined) this.#target_roving.refresh();
510
+ if (this.#sourceRoving !== undefined) this.#sourceRoving.refresh();
511
+ if (this.#targetRoving !== undefined) this.#targetRoving.refresh();
525
512
  return this;
526
513
  }
527
514
 
@@ -568,25 +555,25 @@ class Transfer {
568
555
 
569
556
  #applyButtons() {
570
557
  const marked = this.#selectedValues();
571
- const can_add = marked.some((value) => {
558
+ const canAdd = marked.some((value) => {
572
559
  const item = this.#find(value);
573
560
  return item !== undefined && !item.chosen && !item.disabled;
574
561
  });
575
- const can_remove = marked.some((value) => {
562
+ const canRemove = marked.some((value) => {
576
563
  const item = this.#find(value);
577
564
  return item !== undefined && item.chosen && !item.disabled;
578
565
  });
579
566
  const chosen = this.#markedItems().length;
580
567
  const room = this.#max === undefined || chosen < this.#max;
581
- this.#arrow_target.disabled = this.#disabled || !can_add || !room;
582
- this.#arrow_source.disabled = this.#disabled || !can_remove;
568
+ this.#arrowTarget.disabled = this.#disabled || !canAdd || !room;
569
+ this.#arrowSource.disabled = this.#disabled || !canRemove;
583
570
  return this;
584
571
  }
585
572
 
586
573
  // После перерисовки фокус возвращается на ту же строку, а если её не стало — никуда
587
574
  #restoreFocus() {
588
- const value = this.#focus_value;
589
- this.#focus_value = undefined;
575
+ const value = this.#focusValue;
576
+ this.#focusValue = undefined;
590
577
  if (value === undefined) return;
591
578
  const row = this.#root.querySelector(`.transfer_item[data-value="${CSS.escape(value)}"]`);
592
579
  if (row === null) return;
@@ -620,12 +607,12 @@ class Transfer {
620
607
  titles.push(item.title);
621
608
  this.#marked.delete(value);
622
609
  }
623
- this.#focus_value = moving[0];
610
+ this.#focusValue = moving[0];
624
611
  this.#render();
625
- const side_title = side === Transfer.SIDE.TARGET ? this.#target_title : this.#source_title;
612
+ const sideTitle = side === Transfer.SIDE.TARGET ? this.#targetTitle : this.#sourceTitle;
626
613
  this.#announce(
627
614
  I18n.t("transfer.moved", {
628
- title: side_title,
615
+ title: sideTitle,
629
616
  titles: titles.join(", "),
630
617
  count: this.#markedItems().length,
631
618
  total: this.#items.length,
@@ -641,7 +628,7 @@ class Transfer {
641
628
  if (item === undefined || item.disabled) return;
642
629
  if (this.#marked.has(value)) this.#marked.delete(value);
643
630
  else this.#marked.add(value);
644
- this.#focus_value = value;
631
+ this.#focusValue = value;
645
632
  this.#render();
646
633
  // Об отметке сообщает сам список (aria-selected) — объявляем только снятие последней
647
634
  if (this.#marked.size === 0) this.#announce(I18n.t("transfer.nothingMarked"));
@@ -651,7 +638,7 @@ class Transfer {
651
638
  #notify() {
652
639
  const values = this.getValue();
653
640
  for (const listener of [...this.#listeners]) listener(values, this);
654
- if (this.#on_change !== undefined) this.#on_change(values, this);
641
+ if (this.#onChange !== undefined) this.#onChange(values, this);
655
642
  }
656
643
 
657
644
  #announce(text = String()) {
@@ -6,14 +6,14 @@ chui_tree_table {
6
6
  width: -webkit-fill-available;
7
7
  max-width: 100%;
8
8
  height: max-content;
9
- margin: var(--margin);
9
+ margin: var(--block_margin);
10
10
  box-sizing: border-box;
11
11
  }
12
12
 
13
13
  .tree_table_label {
14
14
  display: block;
15
15
  width: max-content;
16
- margin: var(--margin);
16
+ margin: var(--block_margin);
17
17
  color: var(--text_color);
18
18
  font-size: var(--font_labels_size);
19
19
  font-weight: 500;
@@ -31,7 +31,7 @@ chui_tree_table {
31
31
  max-width: 100%;
32
32
  overflow: hidden;
33
33
  border: 1px solid var(--border_color);
34
- border-radius: var(--border_radius);
34
+ border-radius: var(--radius_sm);
35
35
  background: var(--element_background);
36
36
  color: var(--text_color);
37
37
  }
@@ -129,7 +129,7 @@ tree_table_toggle_spacer {
129
129
  .tree_table_toggle chui_icon {
130
130
  color: inherit;
131
131
  font-size: 18px;
132
- transition: transform var(--transition_time) ease;
132
+ transition: transform var(--motion_fast) var(--motion_ease);
133
133
  }
134
134
 
135
135
  .tree_table_toggle:hover {