@rt-tools/ui-kit-v2 0.11.0 → 0.13.0

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 (167) hide show
  1. package/README.md +110 -5
  2. package/fesm2022/rt-tools-ui-kit-v2-rich-editor.mjs +947 -0
  3. package/fesm2022/rt-tools-ui-kit-v2-rich-editor.mjs.map +1 -0
  4. package/fesm2022/rt-tools-ui-kit-v2.mjs +12236 -8927
  5. package/fesm2022/rt-tools-ui-kit-v2.mjs.map +1 -1
  6. package/package.json +8 -1
  7. package/rt-tools-ui-kit-v2-0.13.0.tgz +0 -0
  8. package/src/assets/fonts/montserrat-cyrillic-ext-wght-italic.woff2 +0 -0
  9. package/src/assets/fonts/montserrat-cyrillic-ext-wght-normal.woff2 +0 -0
  10. package/src/assets/fonts/montserrat-cyrillic-wght-italic.woff2 +0 -0
  11. package/src/assets/fonts/montserrat-cyrillic-wght-normal.woff2 +0 -0
  12. package/src/assets/fonts/montserrat-latin-ext-wght-italic.woff2 +0 -0
  13. package/src/assets/fonts/montserrat-latin-ext-wght-normal.woff2 +0 -0
  14. package/src/assets/fonts/montserrat-latin-wght-italic.woff2 +0 -0
  15. package/src/assets/fonts/montserrat-latin-wght-normal.woff2 +0 -0
  16. package/src/assets/icons/arrows.svg +9 -0
  17. package/src/assets/icons/equals.svg +8 -0
  18. package/src/assets/icons/user-off.svg +16 -0
  19. package/src/assets/icons-material/NOTICE.md +6 -2
  20. package/src/assets/icons-material/arrow-left.fill.svg +3 -0
  21. package/src/assets/icons-material/arrow-left.svg +1 -1
  22. package/src/assets/icons-material/arrow-right.fill.svg +3 -0
  23. package/src/assets/icons-material/arrow-right.svg +3 -0
  24. package/src/assets/icons-material/arrows.fill.svg +5 -0
  25. package/src/assets/icons-material/arrows.svg +5 -0
  26. package/src/assets/icons-material/ban.fill.svg +5 -0
  27. package/src/assets/icons-material/ban.svg +1 -1
  28. package/src/assets/icons-material/bars.fill.svg +3 -0
  29. package/src/assets/icons-material/bars.svg +1 -1
  30. package/src/assets/icons-material/check.fill.svg +3 -0
  31. package/src/assets/icons-material/check.svg +1 -1
  32. package/src/assets/icons-material/chevron-down.fill.svg +3 -0
  33. package/src/assets/icons-material/chevron-down.svg +1 -1
  34. package/src/assets/icons-material/chevron-left.fill.svg +3 -0
  35. package/src/assets/icons-material/chevron-left.svg +1 -1
  36. package/src/assets/icons-material/chevron-right.fill.svg +3 -0
  37. package/src/assets/icons-material/chevron-right.svg +1 -1
  38. package/src/assets/icons-material/close.fill.svg +3 -0
  39. package/src/assets/icons-material/close.svg +1 -1
  40. package/src/assets/icons-material/cloud-upload.fill.svg +5 -0
  41. package/src/assets/icons-material/cloud-upload.svg +1 -1
  42. package/src/assets/icons-material/cog.fill.svg +5 -0
  43. package/src/assets/icons-material/cog.svg +1 -1
  44. package/src/assets/icons-material/copy.fill.svg +5 -0
  45. package/src/assets/icons-material/copy.svg +1 -1
  46. package/src/assets/icons-material/ellipsis-h.fill.svg +5 -0
  47. package/src/assets/icons-material/ellipsis-h.svg +1 -1
  48. package/src/assets/icons-material/ellipsis-v.fill.svg +5 -0
  49. package/src/assets/icons-material/ellipsis-v.svg +1 -1
  50. package/src/assets/icons-material/email.fill.svg +5 -0
  51. package/src/assets/icons-material/email.svg +5 -0
  52. package/src/assets/icons-material/equals.fill.svg +3 -0
  53. package/src/assets/icons-material/equals.svg +3 -0
  54. package/src/assets/icons-material/external-link.fill.svg +5 -0
  55. package/src/assets/icons-material/external-link.svg +1 -1
  56. package/src/assets/icons-material/eye-slash.fill.svg +5 -0
  57. package/src/assets/icons-material/eye-slash.svg +1 -1
  58. package/src/assets/icons-material/eye.fill.svg +5 -0
  59. package/src/assets/icons-material/eye.svg +1 -1
  60. package/src/assets/icons-material/ico-download.fill.svg +5 -0
  61. package/src/assets/icons-material/ico-download.svg +1 -1
  62. package/src/assets/icons-material/ico-plus.fill.svg +3 -0
  63. package/src/assets/icons-material/ico-plus.svg +1 -1
  64. package/src/assets/icons-material/info-circle.fill.svg +5 -0
  65. package/src/assets/icons-material/info-circle.svg +1 -1
  66. package/src/assets/icons-material/pencil.fill.svg +5 -0
  67. package/src/assets/icons-material/pencil.svg +1 -1
  68. package/src/assets/icons-material/refresh.fill.svg +5 -0
  69. package/src/assets/icons-material/refresh.svg +1 -1
  70. package/src/assets/icons-material/search.fill.svg +5 -0
  71. package/src/assets/icons-material/search.svg +1 -1
  72. package/src/assets/icons-material/star.fill.svg +3 -0
  73. package/src/assets/icons-material/star.svg +1 -1
  74. package/src/assets/icons-material/sync.fill.svg +5 -0
  75. package/src/assets/icons-material/sync.svg +1 -1
  76. package/src/assets/icons-material/table.fill.svg +5 -0
  77. package/src/assets/icons-material/table.svg +1 -1
  78. package/src/assets/icons-material/tag.fill.svg +5 -0
  79. package/src/assets/icons-material/tag.svg +1 -1
  80. package/src/assets/icons-material/trash.fill.svg +5 -0
  81. package/src/assets/icons-material/trash.svg +1 -1
  82. package/src/assets/icons-material/user-off.fill.svg +5 -0
  83. package/src/assets/icons-material/user-off.svg +5 -0
  84. package/src/assets/icons-material/user.fill.svg +5 -0
  85. package/src/assets/icons-material/user.svg +1 -1
  86. package/src/lib/components/CONTEXT.md +19 -16
  87. package/src/lib/components/accordion/CONTEXT.md +31 -0
  88. package/src/lib/components/accordion/rt-accordion.component.scss +61 -0
  89. package/src/lib/components/action-bar/CONTEXT.md +53 -0
  90. package/src/lib/components/action-bar/rt-action-bar-holder.component.scss +70 -0
  91. package/src/lib/components/action-bar/rt-action-bar.component.scss +122 -0
  92. package/src/lib/components/aside/CONTEXT.md +5 -1
  93. package/src/lib/components/aside/_rt-aside-overlay.scss +9 -0
  94. package/src/lib/components/aside/header/rt-aside-header.component.scss +18 -2
  95. package/src/lib/components/aside/rt-aside.component.scss +5 -1
  96. package/src/lib/components/autocomplete/CONTEXT.md +2 -1
  97. package/src/lib/components/button/CONTEXT.md +11 -11
  98. package/src/lib/components/checkbox/rt-checkbox.component.scss +5 -1
  99. package/src/lib/components/data-list/CONTEXT.md +122 -0
  100. package/src/lib/components/data-list/rt-data-list.component.scss +57 -0
  101. package/src/lib/components/data-list/settings/rt-data-list-settings-aside.component.scss +256 -0
  102. package/src/lib/components/data-list/toolbar/rt-data-list-toolbar.component.scss +128 -0
  103. package/src/lib/components/data-table/CONTEXT.md +102 -0
  104. package/src/lib/components/data-table/cell/rt-data-table-cell.component.scss +115 -0
  105. package/src/lib/components/data-table/filter-cell/rt-data-table-filter-cell.component.scss +51 -0
  106. package/src/lib/components/data-table/header-cell/rt-data-table-header-cell.component.scss +111 -0
  107. package/src/lib/components/data-table/rt-data-table.component.scss +263 -0
  108. package/src/lib/components/date-picker/rt-date-picker.component.scss +13 -0
  109. package/src/lib/components/delta-view/CONTEXT.md +1 -1
  110. package/src/lib/components/dialog/CONTEXT.md +4 -0
  111. package/src/lib/components/dynamic-list/CONTEXT.md +90 -0
  112. package/src/lib/components/dynamic-list/rt-dynamic-list.component.scss +123 -0
  113. package/src/lib/components/empty-state/CONTEXT.md +5 -0
  114. package/src/lib/components/empty-state/rt-empty-state.component.scss +19 -5
  115. package/src/lib/components/file-card/rt-file-card.component.scss +14 -0
  116. package/src/lib/components/file-drop/rt-file-drop.component.scss +44 -8
  117. package/src/lib/components/icon-button/rt-icon-button.component.scss +28 -4
  118. package/src/lib/components/input/rt-input.component.scss +25 -1
  119. package/src/lib/components/input-number/rt-input-number.component.scss +13 -0
  120. package/src/lib/components/menu/CONTEXT.md +10 -0
  121. package/src/lib/components/menu/rt-menu-item.component.scss +35 -3
  122. package/src/lib/components/menu/rt-menu.component.scss +15 -5
  123. package/src/lib/components/multiselect/CONTEXT.md +3 -0
  124. package/src/lib/components/multiselect/rt-multiselect.component.scss +58 -1
  125. package/src/lib/components/pagination/CONTEXT.md +4 -1
  126. package/src/lib/components/pagination/rt-pagination.component.scss +43 -13
  127. package/src/lib/components/radio-button/CONTEXT.md +42 -0
  128. package/src/lib/components/radio-button/rt-radio-button.component.scss +105 -0
  129. package/src/lib/components/scroll-area/CONTEXT.md +52 -0
  130. package/src/lib/components/scroll-area/rt-scroll-area.component.scss +69 -0
  131. package/src/lib/components/select/CONTEXT.md +8 -1
  132. package/src/lib/components/select/rt-select.component.scss +110 -7
  133. package/src/lib/components/table/CONTEXT.md +46 -1
  134. package/src/lib/components/table/filter-header/CONTEXT.md +64 -0
  135. package/src/lib/components/table/filter-header/rt-table-filter-header.component.scss +76 -0
  136. package/src/lib/components/table/rt-table.component.scss +32 -1
  137. package/src/lib/components/tag/CONTEXT.md +9 -0
  138. package/src/lib/components/tag/rt-tag.component.scss +38 -0
  139. package/src/lib/components/textarea/CONTEXT.md +1 -1
  140. package/src/lib/components/toolbar/CONTEXT.md +3 -0
  141. package/src/lib/components/toolbar/rt-toolbar.component.scss +9 -2
  142. package/src/lib/components/tooltip/CONTEXT.md +4 -4
  143. package/src/lib/components/tooltip/rt-tooltip.component.scss +2 -2
  144. package/src/{lib → rich-editor/lib}/components/chat/CONTEXT.md +1 -1
  145. package/src/{lib → rich-editor/lib}/components/message-composer/CONTEXT.md +5 -1
  146. package/src/{lib → rich-editor/lib}/components/message-composer/rt-message-composer.component.scss +9 -0
  147. package/src/{lib → rich-editor/lib}/components/rich-editor/CONTEXT.md +2 -2
  148. package/src/styles/_coarse-pointer.scss +15 -0
  149. package/src/styles/_coexist.scss +28 -0
  150. package/src/styles/_fonts.scss +99 -0
  151. package/src/styles/_index.scss +13 -0
  152. package/src/styles/_preset-material.scss +201 -26
  153. package/src/styles/_primitives.scss +41 -5
  154. package/src/styles/_scrollbar.scss +16 -12
  155. package/src/styles/_semantic-lists.scss +89 -0
  156. package/src/styles/_semantic.scss +80 -9
  157. package/src/styles/_theme-dark.scss +36 -0
  158. package/src/styles/_theme-scope.scss +111 -0
  159. package/src/styles/tokens.coexist.scss +3 -0
  160. package/src/styles/tokens.package.scss +6 -0
  161. package/styles/tokens.coexist.css +27 -0
  162. package/styles/tokens.css +5443 -43
  163. package/types/rt-tools-ui-kit-v2-rich-editor.d.ts +529 -0
  164. package/types/rt-tools-ui-kit-v2.d.ts +2778 -1375
  165. package/rt-tools-ui-kit-v2-0.11.0.tgz +0 -0
  166. /package/src/{lib → rich-editor/lib}/components/chat/rt-chat.component.scss +0 -0
  167. /package/src/{lib → rich-editor/lib}/components/rich-editor/rt-rich-editor.component.scss +0 -0
@@ -5,7 +5,11 @@
5
5
  // двигается только цвет, поэтому раскладка стоит на месте.
6
6
  // Стандартные свойства объявлены рядом с псевдоэлементами: одни понимает одна ветка
7
7
  // браузеров, другие — другая, и написанные порознь они расходятся видом.
8
- * {
8
+ // Правила стоят только на узлах кита — у них класс с приставкой `rt-`. Стандартное свойство,
9
+ // поставленное всем узлам, выключает в Chrome `::-webkit-scrollbar` у всего приложения, а
10
+ // псевдоэлементы на всех узлах красили бы полосы приложения видом кита. Вес селектора нулевой,
11
+ // и своё правило приложения перебивает его без счёта.
12
+ :where([class^='rt-'], [class*=' rt-']) {
9
13
  scrollbar-color: transparent transparent;
10
14
  scrollbar-width: thin;
11
15
  }
@@ -13,39 +17,39 @@
13
17
  // Проявляется ползунок наведением на саму зону, а не на себя: навести на невидимое нечем.
14
18
  // Фокус внутри зоны показывает его наравне — прокрутка с клавиатуры идёт без указателя, и
15
19
  // человек иначе не видит ни того, где он в списке, ни того, что список прокручивается.
16
- *:hover,
17
- *:focus-within {
20
+ :where([class^='rt-'], [class*=' rt-']):hover,
21
+ :where([class^='rt-'], [class*=' rt-']):focus-within {
18
22
  scrollbar-color: var(--rt-color-border-default) transparent;
19
23
  }
20
24
 
21
- ::-webkit-scrollbar {
25
+ :where([class^='rt-'], [class*=' rt-'])::-webkit-scrollbar {
22
26
  width: 12px;
23
27
  }
24
28
 
25
- ::-webkit-scrollbar:horizontal {
29
+ :where([class^='rt-'], [class*=' rt-'])::-webkit-scrollbar:horizontal {
26
30
  height: 12px;
27
31
  }
28
32
 
29
- ::-webkit-scrollbar-thumb {
33
+ :where([class^='rt-'], [class*=' rt-'])::-webkit-scrollbar-thumb {
30
34
  border: var(--rt-border-width-thick) solid transparent;
31
35
  border-radius: var(--rt-radius-md);
32
36
  background: transparent;
33
37
  background-clip: content-box;
34
38
  }
35
39
 
36
- *:hover::-webkit-scrollbar-thumb,
37
- *:focus-within::-webkit-scrollbar-thumb {
40
+ :where([class^='rt-'], [class*=' rt-']):hover::-webkit-scrollbar-thumb,
41
+ :where([class^='rt-'], [class*=' rt-']):focus-within::-webkit-scrollbar-thumb {
38
42
  background: var(--rt-color-border-default);
39
43
  background-clip: content-box;
40
44
  }
41
45
 
42
- ::-webkit-scrollbar-thumb:hover {
46
+ :where([class^='rt-'], [class*=' rt-'])::-webkit-scrollbar-thumb:hover {
43
47
  border: var(--rt-border-width-medium) solid transparent;
44
48
  background: var(--rt-color-border-strong);
45
49
  background-clip: content-box;
46
50
  }
47
51
 
48
- ::-webkit-scrollbar-track:hover {
52
+ :where([class^='rt-'], [class*=' rt-'])::-webkit-scrollbar-track:hover {
49
53
  border: var(--rt-border-width-thin) solid var(--rt-color-bg-subtle);
50
54
  }
51
55
 
@@ -53,11 +57,11 @@
53
57
  // экране указателя нет вовсе, а признак прокручиваемости зоны нужен ровно так же.
54
58
  // Ветка hover-none: наведения на этом экране не бывает.
55
59
  @media (hover: none) {
56
- * {
60
+ :where([class^='rt-'], [class*=' rt-']) {
57
61
  scrollbar-color: var(--rt-color-border-default) transparent;
58
62
  }
59
63
 
60
- ::-webkit-scrollbar-thumb {
64
+ :where([class^='rt-'], [class*=' rt-'])::-webkit-scrollbar-thumb {
61
65
  background: var(--rt-color-border-default);
62
66
  background-clip: content-box;
63
67
  }
@@ -0,0 +1,89 @@
1
+ /* Built by the generator `tools/build-tokens-v2.mjs` from `tokens.source.mjs` — edited there, not here:
2
+ an edit on the spot is lost on the next build, and `pnpm run check:tokens-build` names it. */
3
+
4
+ /* The light theme's assignments of the list panel, the pagination bar and the empty list. */
5
+
6
+ @mixin rt-theme-light-list-tokens {
7
+ /* Кнопки действий на панели списка — свои и приложения. Свой вид оставляет их кнопками-
8
+ значками без подъёма; материальный набор делает из них круглые кнопки действия первого кита. */
9
+ --rt-list-action-gap: var(--rt-space-sm);
10
+ --rt-list-action-divider-height: var(--rt-size-5);
11
+ --rt-list-action-radius: var(--rt-radius-md);
12
+ --rt-list-action-shadow: var(--rt-shadow-none);
13
+ --rt-list-action-shadow-hover: var(--rt-shadow-none);
14
+ --rt-list-action-icon-size: var(--rt-size-5);
15
+ --rt-list-action-color: var(--rt-color-text-primary);
16
+ --rt-list-action-color-hover: var(--rt-color-text-primary);
17
+ --rt-list-action-color-bg-hover: var(--rt-icon-button-color-bg-hover);
18
+
19
+ /* Значки, кнопки и копирование таблицы списка: материальный набор рисует их, как первый кит. */
20
+ --rt-list-table-icon-size: 0px;
21
+ --rt-list-table-icon-color: var(--rt-color-text-primary);
22
+ --rt-list-table-head-divider-color: var(--rt-color-border-strong);
23
+ --rt-list-table-button-size: var(--rt-control-height-md);
24
+ --rt-list-table-button-radius: var(--rt-radius-md);
25
+ --rt-list-copy-button-size: var(--rt-control-height-sm);
26
+ --rt-list-copy-button-radius: var(--rt-radius-md);
27
+ --rt-list-copy-button-bg: transparent;
28
+ --rt-list-copy-button-bg-hover: var(--rt-icon-button-color-bg-hover);
29
+ --rt-list-copy-button-color: var(--rt-color-text-primary);
30
+
31
+ /* Подпись флажка «отметить все» на панели списка: свой вид — текст, материальный набор —
32
+ приглушённый серый первого кита. */
33
+ --rt-list-selector-label-color: var(--rt-color-text-primary);
34
+
35
+ /* Полоса страниц rt-pagination: ячейка страницы, текущая страница, стрелки, подпись
36
+ диапазона и поле размера. Свой вид — прежние значения; материальный набор делает из них
37
+ полосу первого кита. */
38
+ --rt-pagination-justify: space-between;
39
+ --rt-pagination-padding-y: var(--rt-space-4);
40
+ --rt-pagination-padding-x: var(--rt-space-xs);
41
+ --rt-pagination-gap: var(--rt-space-md);
42
+ --rt-pagination-nav-gap: var(--rt-space-xs);
43
+ --rt-pagination-range-display: inline;
44
+ --rt-pagination-box-size: var(--rt-space-xl);
45
+ --rt-pagination-box-radius: var(--rt-radius-md);
46
+ --rt-pagination-box-color-border: var(--rt-color-border-default);
47
+ --rt-pagination-box-color-text: var(--rt-color-text-primary);
48
+ --rt-pagination-box-current-color-bg: var(--rt-color-bg-surface-subtle);
49
+ --rt-pagination-box-current-color-text: var(--rt-color-text-primary);
50
+ --rt-pagination-box-current-color-border: var(--rt-color-border-strong);
51
+ --rt-pagination-box-current-font-weight: var(--rt-font-weight-semibold);
52
+ --rt-pagination-arrow-size: var(--rt-control-height-sm);
53
+ --rt-pagination-arrow-radius: var(--rt-radius-md);
54
+ --rt-pagination-arrow-shadow: var(--rt-shadow-none);
55
+ --rt-pagination-arrow-color: var(--rt-color-text-primary);
56
+ --rt-pagination-per-page-gap: var(--rt-space-sm);
57
+ --rt-pagination-per-page-label-white-space: normal;
58
+ --rt-pagination-field-height: var(--rt-input-height-md);
59
+ --rt-pagination-field-radius: var(--rt-input-radius);
60
+ --rt-pagination-field-color-border: var(--rt-input-color-border);
61
+ --rt-pagination-field-padding-x: var(--rt-input-padding-x);
62
+ --rt-pagination-field-color-bg: var(--rt-input-color-bg);
63
+ --rt-pagination-field-color-text: var(--rt-input-color-text);
64
+
65
+ /* Отступы вокруг тулбара списка и нижний отступ содержимого. Свой вид держит полосу с отступом
66
+ 8px сверху и снизу вплотную к таблице; материальный набор даёт 16px сверху и 16px до таблицы. */
67
+ --rt-list-toolbar-padding-top: var(--rt-space-2);
68
+ --rt-list-toolbar-padding-bottom: var(--rt-space-2);
69
+ --rt-list-toolbar-gap: 0px;
70
+ --rt-list-content-padding-bottom: 0px;
71
+
72
+ /* Пустой список — заглушка rt-empty-state. Свой вид держит значок в сером круге и заголовок
73
+ среднего размера; материальный набор даёт значок 48px без круга и крупный заголовок первого кита. */
74
+ --rt-list-empty-icon-wrap-size: var(--rt-size-16);
75
+ --rt-list-empty-icon-wrap-bg: var(--rt-color-bg-subtle);
76
+ --rt-list-empty-icon-size: var(--rt-size-8);
77
+ --rt-list-empty-title-size: var(--rt-text-md);
78
+ --rt-list-empty-title-weight: var(--rt-font-weight-medium);
79
+
80
+ /* Плашка колонки в панели настройки списка под материальным набором: скругление первого кита. */
81
+ --rt-list-settings-item-radius: var(--rt-radius-sm);
82
+
83
+ /* Строка поля в фильтре и место под заглушку и крутилку пустого списка. Свой вид держит
84
+ строку по размеру шрифта и заглушку во всю высоту списка; материальный набор даёт строку 24px,
85
+ как у поля Material первого кита. */
86
+ --rt-list-filter-line-height: var(--rt-leading-none);
87
+ --rt-list-placeholder-min-height: var(--rt-size-60);
88
+ --rt-list-placeholder-grow: 1;
89
+ }
@@ -8,6 +8,8 @@
8
8
  pair «light ↔ dark» cannot be shown while the application stands in the dark theme —
9
9
  the container would inherit the dark values, and both halves would show the same. */
10
10
 
11
+ @use './semantic-lists' as lists;
12
+
11
13
  @mixin rt-theme-light-tokens {
12
14
  /* Background */
13
15
  --rt-color-bg-page: var(--rt-neutral-50);
@@ -136,6 +138,11 @@
136
138
  /* State */
137
139
  --rt-color-state-success: var(--rt-success-500); /* rt-theme-shared: цвет статуса один в обеих темах */
138
140
  --rt-color-state-success-bg: var(--rt-success-50);
141
+
142
+ /* Подпись успеха на поверхности — пункт меню, строка статуса. Сам статус как текст порога
143
+ контраста не берёт ни на белом, ни на графите: он для значка и заливки. Пара к
144
+ warning-text и error-text. */
145
+ --rt-color-state-success-text: var(--rt-success-600);
139
146
  --rt-color-state-warning: var(--rt-warning-500); /* rt-theme-shared: цвет статуса один в обеих темах */
140
147
  --rt-color-state-warning-bg: var(--rt-warning-50);
141
148
 
@@ -148,6 +155,17 @@
148
155
  --rt-color-state-info: var(--rt-info-500); /* rt-theme-shared: цвет статуса один в обеих темах */
149
156
  --rt-color-state-info-bg: var(--rt-info-50);
150
157
 
158
+ /* Data table (rt-data-table) — заливка шапки. Своё имя, а не подложка роли: в материальном
159
+ наборе шапка залита цветом залитого поля, как у первого кита, а подложка роли остаётся
160
+ серой у всех остальных частей кита. Тёмная тема отвечает на имя сама: без ответа она
161
+ уступила бы его материальному набору, и тёмная шапка получила бы светлую заливку. */
162
+ --rt-color-table-head-bg: var(--rt-color-bg-surface-subtle);
163
+
164
+ /* Залитое поле (вид fill у поля ввода, числа, даты и выбора) — черта снизу. Своё имя,
165
+ а не рамка роли: в материальном наборе она берёт цвет черты поля Material, а рамка роли
166
+ остаётся светлой у всех остальных частей кита. Тёмная тема отвечает на имя сама. */
167
+ --rt-color-field-fill-underline: var(--rt-color-border-strong);
168
+
151
169
  /* Stepper (rt-stepper) — рельса прогресса. Текущий шаг — янтарный (одинаков
152
170
  в обеих темах); трек/прогресс переопределяются в dark на приглушённые. */
153
171
  --rt-color-stepper-current: var(--rt-amber-400); /* rt-theme-shared: янтарь текущего шага один в обеих темах */
@@ -181,6 +199,43 @@
181
199
  --rt-color-skeleton-base: var(--rt-neutral-100);
182
200
  --rt-color-skeleton-wave: var(--rt-neutral-50);
183
201
 
202
+ /* Панели над страницей — меню, выпадающий список, подсказка: скругление и тень. Свой вид
203
+ держит ступени кита; материальный набор даёт числа и подъём первого кита. */
204
+ --rt-overlay-menu-radius: var(--rt-radius-md);
205
+ --rt-overlay-menu-shadow: var(--rt-shadow-lg);
206
+ --rt-overlay-select-radius: var(--rt-input-radius);
207
+ --rt-overlay-select-shadow: var(--rt-shadow-md);
208
+ --rt-overlay-tooltip-radius: var(--rt-radius-sm);
209
+ --rt-overlay-tooltip-shadow: var(--rt-shadow-md);
210
+
211
+ /* Меню и выпадающий список: фон, отступ и вес подписей меню, красный опасного пункта, пункт
212
+ списка и отметка выбранного. Свой вид держит прежние значения; материальный набор — первого кита. */
213
+ --rt-overlay-menu-bg: var(--rt-color-bg-surface);
214
+ --rt-overlay-menu-padding-y: var(--rt-space-xs);
215
+ --rt-overlay-menu-item-weight: var(--rt-font-weight-regular);
216
+ --rt-overlay-menu-danger-color: var(--rt-color-state-error-text);
217
+ --rt-overlay-select-option-font-size: var(--rt-input-font-size);
218
+ --rt-overlay-select-selected-bg: var(--rt-color-action-primary-subtle);
219
+ --rt-overlay-select-selected-weight: var(--rt-font-weight-semibold);
220
+ --rt-overlay-select-check-display: none;
221
+ --rt-overlay-menu-current-bg: var(--rt-color-bg-hover);
222
+
223
+ /* Размеры меню и выпадающего списка, рамка панели списка и неактивная кнопка-значок. Свой вид
224
+ держит прежние значения; материальный набор — числа первого кита. */
225
+ --rt-overlay-menu-min-width: 180px;
226
+ --rt-overlay-menu-item-min-height: auto;
227
+ --rt-overlay-menu-item-padding-y: var(--rt-space-sm);
228
+ --rt-overlay-menu-item-padding-x: var(--rt-space-md);
229
+ --rt-overlay-menu-item-icon-size: var(--rt-size-4);
230
+ --rt-overlay-menu-sm-item-min-height: var(--rt-overlay-menu-item-min-height);
231
+ --rt-overlay-menu-sm-item-icon-size: var(--rt-overlay-menu-item-icon-size);
232
+ --rt-overlay-menu-danger-label-color: var(--rt-overlay-menu-danger-color);
233
+ --rt-overlay-select-option-min-height: auto;
234
+ --rt-overlay-select-panel-border-width: var(--rt-input-border-width);
235
+ --rt-icon-button-disabled-opacity: 0.5;
236
+ --rt-icon-button-disabled-color: currentcolor;
237
+ --rt-icon-button-disabled-fill: 100%;
238
+
184
239
  /* Spacing aliases — named semantic aliases на primitive numeric scale */
185
240
  --rt-space-2xs: var(--rt-space-0-5); /* 2px */
186
241
  --rt-space-xs: var(--rt-space-1); /* 4px */
@@ -208,6 +263,9 @@
208
263
  --rt-input-color-border-error: var(--rt-color-state-danger);
209
264
  --rt-input-color-text: var(--rt-color-text-primary);
210
265
  --rt-input-color-text-placeholder: var(--rt-color-text-muted);
266
+ --rt-input-icon-color: var(--rt-neutral-600);
267
+ --rt-input-icon-size: var(--rt-size-4);
268
+ --rt-input-gap: var(--rt-space-sm);
211
269
 
212
270
  /* Sizes (single-line height scale) */
213
271
  --rt-input-height-sm: var(--rt-control-height-sm);
@@ -219,6 +277,26 @@
219
277
  внутри flex-баров контрол без ограничения растягивается на всю строку. */
220
278
  --rt-input-max-width: var(--rt-control-max-width);
221
279
 
280
+ /* Поиск списка (rt-data-list). Свои имена, а не имена поля: в материальном наборе поиск
281
+ списка — поле Material первого кита, 52px высотой, со скруглением 4px и рамкой цвета
282
+ outline темы, а остальные поля набора остаются полями первого кита вне Material. */
283
+ --rt-list-search-height: var(--rt-input-height-sm);
284
+ --rt-list-search-radius: var(--rt-input-radius);
285
+ --rt-list-search-color-border: var(--rt-input-color-border);
286
+ --rt-list-search-color-bg: var(--rt-input-color-bg);
287
+ --rt-list-search-width: var(--rt-size-60);
288
+ --rt-list-search-padding-x: var(--rt-input-padding-x);
289
+ --rt-list-search-gap: var(--rt-input-gap);
290
+ --rt-list-search-font-size: var(--rt-input-font-size);
291
+ --rt-list-search-icon-size: var(--rt-input-icon-size);
292
+ --rt-list-search-icon-color: var(--rt-input-icon-color);
293
+ --rt-list-search-color-placeholder: var(--rt-input-color-text-placeholder);
294
+
295
+ /* Панель настройки колонок списка — заливка плашки колонки и тон значков на ней.
296
+ Свой вид берёт подложку и приглушённый текст; материальный набор отдаёт их теме. */
297
+ --rt-list-settings-item-bg: var(--rt-color-bg-subtle);
298
+ --rt-list-settings-icon-color: var(--rt-color-text-muted);
299
+
222
300
  /* Скругление контрола — назначение, а не ступень на месте. Кнопка, поле ввода и
223
301
  всё, что стоит с ними в строке, берут его отсюда: набор оформления живёт слоем
224
302
  назначений и до ступени, взятой компонентом напрямую, не достаёт. */
@@ -394,17 +472,10 @@
394
472
  --rt-field-value-font-size: var(--rt-text-sm);
395
473
  --rt-field-value-color: var(--rt-color-text-primary);
396
474
  --rt-field-value-empty-color: var(--rt-color-text-muted);
475
+
476
+ @include lists.rt-theme-light-list-tokens;
397
477
  }
398
478
 
399
479
  :root {
400
480
  @include rt-theme-light-tokens;
401
481
  }
402
-
403
- /* On touch devices an input is not smaller than 16px: WebKit (all of iOS, Chrome included)
404
- zooms the page on focusing a field with font-size < 16px — hence the horizontal
405
- shift of the layout. The desktop keeps the dense 14px. */
406
- @media (pointer: coarse) {
407
- :root {
408
- --rt-input-font-size: var(--rt-text-md);
409
- }
410
- }
@@ -16,6 +16,9 @@
16
16
  a pair is visible right there rather than caught by matching two files. */
17
17
 
18
18
  @mixin rt-theme-dark-tokens {
19
+ /* The Material colours of the page are resolved dark under the kit's dark theme. */
20
+ color-scheme: dark;
21
+
19
22
  /* Background — тёплый графит */
20
23
  --rt-color-bg-page: var(--rt-charcoal-900);
21
24
  --rt-color-bg-surface: var(--rt-charcoal-800);
@@ -42,12 +45,42 @@
42
45
 
43
46
  /* Input border видим в dark (в light — transparent). */
44
47
  --rt-input-color-border: var(--rt-charcoal-border);
48
+ --rt-list-search-color-border: var(--rt-input-color-border);
49
+ --rt-list-search-color-bg: var(--rt-input-color-bg);
50
+ --rt-list-search-icon-color: var(--rt-input-icon-color);
51
+ --rt-list-search-color-placeholder: var(--rt-input-color-text-placeholder);
52
+ --rt-list-settings-item-bg: var(--rt-color-bg-subtle);
53
+ --rt-list-settings-icon-color: var(--rt-color-text-muted);
54
+ --rt-list-action-color: var(--rt-color-text-primary);
55
+ --rt-list-action-color-hover: var(--rt-color-text-primary);
56
+ --rt-list-action-color-bg-hover: var(--rt-icon-button-color-bg-hover);
57
+ --rt-list-table-icon-color: var(--rt-color-text-primary);
58
+ --rt-list-table-head-divider-color: var(--rt-color-border-strong);
59
+ --rt-list-copy-button-bg: transparent;
60
+ --rt-list-copy-button-bg-hover: var(--rt-icon-button-color-bg-hover);
61
+ --rt-list-copy-button-color: var(--rt-color-text-primary);
62
+ --rt-list-selector-label-color: var(--rt-color-text-primary);
63
+ --rt-pagination-box-color-border: var(--rt-color-border-default);
64
+ --rt-pagination-box-color-text: var(--rt-color-text-primary);
65
+ --rt-pagination-box-current-color-bg: var(--rt-color-bg-surface-subtle);
66
+ --rt-pagination-box-current-color-text: var(--rt-color-text-primary);
67
+ --rt-pagination-box-current-color-border: var(--rt-color-border-strong);
68
+ --rt-pagination-arrow-color: var(--rt-color-text-primary);
69
+ --rt-pagination-field-color-border: var(--rt-input-color-border);
70
+ --rt-pagination-field-color-bg: var(--rt-input-color-bg);
71
+ --rt-pagination-field-color-text: var(--rt-input-color-text);
72
+ --rt-input-icon-color: var(--rt-neutral-600);
45
73
 
46
74
  /* Stepper — в dark рельса уходит от яркого синего к приглушённому серо-синему
47
75
  (текущий шаг остаётся янтарным из light-семантики). */
48
76
  --rt-color-stepper-track: var(--rt-navy-600);
49
77
  --rt-color-stepper-progress: var(--rt-slate-300);
50
78
 
79
+ /* Шапка таблицы — та же подложка роли, что в светлой: ответ стоит, чтобы тёмная тема
80
+ выигрывала у материального набора и на этом имени. */
81
+ --rt-color-table-head-bg: var(--rt-color-bg-surface-subtle);
82
+ --rt-color-field-fill-underline: var(--rt-color-border-strong);
83
+
51
84
  /* Навигация — вся шкала серых разворачивается: подложка уходит глубже
52
85
  поверхности, а приглушённые подписи становятся светлее фона, а не темнее.
53
86
  Плашка шапки садится на глубокий графит, активный пункт поднимается на
@@ -107,6 +140,8 @@
107
140
  общий bg-surface на обоих слил бы их в один силуэт. Тень на графите
108
141
  не работает, роль разделителя берёт на себя контраст. */
109
142
  --rt-toggle-color-track: var(--rt-charcoal-950);
143
+ --rt-toggle-color-track-on: var(--rt-color-action-primary);
144
+ --rt-toggle-color-border: var(--rt-color-border-strong);
110
145
  --rt-toggle-color-thumb: var(--rt-neutral-50);
111
146
  --rt-toggle-shadow-thumb: var(--rt-shadow-none);
112
147
 
@@ -120,6 +155,7 @@
120
155
  --rt-color-state-danger-bg: color-mix(in srgb, var(--rt-danger-500) 12%, transparent);
121
156
  --rt-color-state-error-text: var(--rt-danger-500);
122
157
  --rt-color-state-warning-text: var(--rt-warning-500);
158
+ --rt-color-state-success-text: var(--rt-success-400);
123
159
  --rt-color-state-info-bg: color-mix(in srgb, var(--rt-info-500) 12%, transparent);
124
160
 
125
161
  /* Chat — на графите светлые фоны пузырей нечитаемы: входящее уходит в
@@ -0,0 +1,111 @@
1
+ /* Built by the generator `tools/build-tokens-v2.mjs` from `tokens.source.mjs` — edited there, not here:
2
+ an edit on the spot is lost on the next build, and `pnpm run check:tokens-build` names it. */
3
+
4
+ /* A local piece of the theme: the sign answers on an ordinary node too, not at the root of the page
5
+ alone. A dark card inside a light page, a light card inside a dark one, and either of them inside
6
+ a page of the styling set.
7
+
8
+ Every rule here declares the whole set of the assignments on one node rather than only the
9
+ difference from the page. That is not a repetition: the value of a property that refers to another
10
+ one is resolved where it is declared, not where it is read. A node carrying only the difference
11
+ inherits the rest from the root already resolved — by the values of the root — and the piece comes
12
+ out half of one theme and half of the other, whole and green in the frame.
13
+
14
+ The root is cut out of every rule by `:not(:root)`: there the layers already lie in the right
15
+ order, and laying the base over them once more would wipe the set on a dark page.
16
+
17
+ The file stands last in the aggregator: its rules are stronger than the root ones by their place,
18
+ not by specificity, and a piece must win over the page around it. */
19
+
20
+ @use './semantic' as semantic;
21
+ @use './theme-dark' as dark;
22
+ @use './preset-material' as material;
23
+ @use './coarse-pointer' as coarse;
24
+
25
+ /* A light piece inside a page of another theme. */
26
+ [data-theme='light']:not(:root) {
27
+ color-scheme: light;
28
+
29
+ @include semantic.rt-theme-light-tokens;
30
+ @include coarse.rt-coarse-pointer-tokens;
31
+ }
32
+
33
+ /* A dark piece inside a page of another theme. The light base goes under the dark answers, exactly
34
+ as it lies under them at the root: a piece carrying the dark answers alone would inherit the rest
35
+ from the root already resolved by the light values, and come out half dark. */
36
+ [data-theme='dark']:not(:root) {
37
+ @include semantic.rt-theme-light-tokens;
38
+ @include dark.rt-theme-dark-tokens;
39
+ @include coarse.rt-coarse-pointer-tokens;
40
+ }
41
+
42
+ /* A node carrying the set on a light page. The set alone rewrites only its own names, and a name
43
+ whose value refers to one of them would stay resolved at the root by the base values: the text
44
+ button in a panel of the set kept the base blue while the brand beside it followed the theme. The
45
+ node therefore declares the light base under the set. The dark rules below have the same force and
46
+ stand after this one, so a node under a dark theme still takes them. */
47
+ [data-preset='material']:not(:root),
48
+ .rt-preset-material:not(:root) {
49
+ @include semantic.rt-theme-light-tokens;
50
+ @include material.rt-preset-material-tokens;
51
+ @include coarse.rt-coarse-pointer-tokens;
52
+ }
53
+
54
+ /* A piece carrying the set under a dark theme — of the page or of a piece around it. A component
55
+ draws the look of the first kit by carrying the set on its own host, and the plain rule of the set
56
+ would lay its light values over the dark ones the node inherited: the table came out light with
57
+ dark text in a dark piece. The node therefore declares the whole set in the order the root has —
58
+ light base, the set, the dark answers. A light piece between the dark one and the node answers
59
+ with the light base and the set; one level of such nesting is told apart, the next is not. */
60
+ [data-theme='dark'] [data-preset='material'],
61
+ [data-theme='dark'] .rt-preset-material,
62
+ html.rt-theme-dark [data-preset='material'],
63
+ html.rt-theme-dark .rt-preset-material {
64
+ @include semantic.rt-theme-light-tokens;
65
+ @include material.rt-preset-material-tokens;
66
+ @include dark.rt-theme-dark-tokens;
67
+ @include material.rt-preset-material-dark-tokens;
68
+ @include coarse.rt-coarse-pointer-tokens;
69
+ }
70
+
71
+ [data-theme='dark'] [data-theme='light'] [data-preset='material'],
72
+ [data-theme='dark'] [data-theme='light'] .rt-preset-material,
73
+ html.rt-theme-dark [data-theme='light'] [data-preset='material'],
74
+ html.rt-theme-dark [data-theme='light'] .rt-preset-material {
75
+ @include semantic.rt-theme-light-tokens;
76
+ @include material.rt-preset-material-tokens;
77
+ @include coarse.rt-coarse-pointer-tokens;
78
+ }
79
+
80
+ /* A piece inside a page of the styling set, and a piece carrying the set itself. The set lies over
81
+ the light base and under the dark answers — the same order the root has, and there the order is
82
+ what the dark theme wins over the set by. */
83
+ [data-preset='material'][data-theme='light']:not(:root),
84
+ [data-preset='material'] [data-theme='light']:not(:root),
85
+ .rt-preset-material[data-theme='light']:not(:root),
86
+ .rt-preset-material [data-theme='light']:not(:root) {
87
+ @include semantic.rt-theme-light-tokens;
88
+ @include material.rt-preset-material-tokens;
89
+ @include coarse.rt-coarse-pointer-tokens;
90
+ }
91
+
92
+ [data-preset='material'][data-theme='dark']:not(:root),
93
+ [data-preset='material'] [data-theme='dark']:not(:root),
94
+ .rt-preset-material[data-theme='dark']:not(:root),
95
+ .rt-preset-material [data-theme='dark']:not(:root) {
96
+ @include semantic.rt-theme-light-tokens;
97
+ @include material.rt-preset-material-tokens;
98
+ @include dark.rt-theme-dark-tokens;
99
+ @include material.rt-preset-material-dark-tokens;
100
+ @include coarse.rt-coarse-pointer-tokens;
101
+ }
102
+
103
+ /* The set and a dark theme both on the page root. The dark answers come after the set there by order,
104
+ and this rule lays the Material chains back over them: it is heavier than both root rules, so the
105
+ order of the files does not decide. */
106
+ :root[data-theme='dark'][data-preset='material'],
107
+ :root[data-theme='dark'].rt-preset-material,
108
+ html.rt-theme-dark[data-preset='material'],
109
+ html.rt-theme-dark.rt-preset-material {
110
+ @include material.rt-preset-material-dark-tokens;
111
+ }
@@ -0,0 +1,3 @@
1
+ // Вход сборки `styles/tokens.coexist.css` пакета: ступени второго кита на узле материального набора
2
+ // на время, пока приложение держит оба кита. Удаляется вместе с первым китом.
3
+ @use 'coexist';
@@ -0,0 +1,6 @@
1
+ // Вход сборки `styles/tokens.css` пакета. Файл лежит на каталог выше исходников партиалов, и
2
+ // адрес начертаний ему нужен свой: шрифты в пакете лежат в `src/assets/fonts`.
3
+ @use 'fonts' with (
4
+ $rt-fonts-url: '../src/assets/fonts'
5
+ );
6
+ @use 'index';
@@ -0,0 +1,27 @@
1
+ @charset "UTF-8";
2
+ /* Built by the generator `tools/build-tokens-v2.mjs` from `tokens.source.mjs` — edited there, not here:
3
+ an edit on the spot is lost on the next build, and `pnpm run check:tokens-build` names it. */
4
+ /* Coexistence with the first kit for the time of migration. The first kit declares ten steps of the
5
+ same names on the page root with its own values, and an application holding both kits gets them
6
+ inside the second kit's components: a 4px rounding becomes 8px. Here the second kit's values stand
7
+ on the preset node, and the preset is drawn by its own scale whatever lies on the root.
8
+
9
+ The selector outweighs the first kit's root by one step wherever the preset flag stands, the page
10
+ root included: there both kits declare the steps on the same node, and without the extra weight
11
+ the order of inclusion decides.
12
+
13
+ The application includes it only while it holds the first kit, and removes it together with it:
14
+ the values repeat the scale, so without the first kit the look does not change. */
15
+ [data-preset=material]:is(:root, :not(:root)),
16
+ .rt-preset-material:is(:root, :not(:root)) {
17
+ --rt-radius-xs: 2px;
18
+ --rt-radius-sm: 4px;
19
+ --rt-radius-md: 8px;
20
+ --rt-radius-lg: 10px;
21
+ --rt-radius-xl: 15px;
22
+ --rt-radius-2xl: 20px;
23
+ --rt-radius-full: 9999px;
24
+ --rt-shadow-sm: 0 1px 2px rgb(0 0 0 / 5%);
25
+ --rt-shadow-md: 0 4px 6px -1px rgb(0 0 0 / 10%), 0 2px 4px -2px rgb(0 0 0 / 6%);
26
+ --rt-shadow-lg: 0 10px 15px -3px rgb(0 0 0 / 10%), 0 4px 6px -4px rgb(0 0 0 / 6%);
27
+ }