@gravity-ui/aikit 2.7.0 → 2.7.1-beta.9cedd61361943cd0ba3f67bdeee91a18e3e00cfc.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.
@@ -87,18 +87,37 @@
87
87
  display: none;
88
88
  }
89
89
  .g-aikit-markdown-renderer {
90
+ width: 100%;
90
91
  max-width: 100%;
92
+ min-width: 0;
91
93
  overflow-x: auto;
92
- /* Tables inside message wrappers: reset inherited word-break; scroll on this root when wide */
94
+ /*
95
+ * Override @diplodoc/transform `.yfm table` (inline-block + max-width: 100%).
96
+ * min-width: 100% — narrow tables fill the message; width: max-content — wide tables grow.
97
+ * Horizontal scroll lives on this root (min-width: 0 on flex ancestors required).
98
+ */
93
99
  }
94
100
  .g-aikit-markdown-renderer table {
101
+ display: table;
95
102
  table-layout: auto;
96
103
  word-break: normal;
97
- min-width: 100%;
98
104
  width: max-content;
105
+ min-width: 100%;
106
+ max-width: none;
107
+ overflow: visible;
99
108
  }
100
- .g-aikit-markdown-renderer th,
101
- .g-aikit-markdown-renderer td {
109
+ .g-aikit-markdown-renderer table th {
102
110
  word-break: normal;
103
111
  white-space: nowrap;
112
+ overflow: visible;
113
+ text-overflow: clip;
114
+ }
115
+ .g-aikit-markdown-renderer table td {
116
+ max-width: var(--g-aikit-markdown-renderer-table-cell-max-width);
117
+ word-break: normal;
118
+ white-space: normal;
119
+ /* Wrap multi-word text at spaces within max-width; do not break tokens at hyphens */
120
+ overflow-wrap: normal;
121
+ overflow: visible;
122
+ text-overflow: clip;
104
123
  }
@@ -10,6 +10,8 @@
10
10
  }
11
11
  .g-aikit-base-message_variant_system, .g-aikit-base-message_variant_assistant {
12
12
  align-items: flex-start;
13
+ min-width: 0;
14
+ max-width: 100%;
13
15
  }
14
16
  .g-aikit-base-message_btn-hover .g-aikit-base-message__actions {
15
17
  visibility: hidden;
@@ -3,4 +3,5 @@
3
3
  flex-direction: column;
4
4
  gap: var(--g-spacing-3);
5
5
  width: 100%;
6
+ min-width: 0;
6
7
  }
@@ -4,6 +4,7 @@
4
4
  display: flex;
5
5
  flex-direction: column;
6
6
  min-height: 0;
7
+ min-width: 0;
7
8
  flex: 1;
8
9
  align-self: stretch;
9
10
  }
@@ -11,6 +12,7 @@
11
12
  display: flex;
12
13
  flex-direction: column;
13
14
  gap: var(--g-spacing-4);
15
+ min-width: 0;
14
16
  }
15
17
  .g-aikit-message-list_virtualized {
16
18
  overflow: hidden;
@@ -17,6 +17,7 @@
17
17
  align-self: stretch;
18
18
  flex: 1;
19
19
  min-height: 0;
20
+ min-width: 0;
20
21
  }
21
22
  .g-aikit-chat-content__message-list {
22
23
  padding: var(--g-spacing-2) var(--g-spacing-2) 0 var(--g-spacing-2);
@@ -1 +1 @@
1
- {"version":"2.7.0","type":"commonjs","sideEffects":["*.css","*.scss"]}
1
+ {"version":"2.7.1-beta.9cedd61361943cd0ba3f67bdeee91a18e3e00cfc.0","type":"commonjs","sideEffects":["*.css","*.scss"]}
@@ -74,4 +74,7 @@
74
74
  /* === Action Popup === */
75
75
  --g-aikit-action-popup-min-width: 280px;
76
76
  --g-aikit-action-popup-max-width: 400px;
77
+
78
+ /* === Markdown Renderer === */
79
+ --g-aikit-markdown-renderer-table-cell-max-width: 240px;
77
80
  }
@@ -76,4 +76,7 @@
76
76
  /* === Action Popup === */
77
77
  --g-aikit-action-popup-min-width: 280px;
78
78
  --g-aikit-action-popup-max-width: 400px;
79
+
80
+ /* === Markdown Renderer === */
81
+ --g-aikit-markdown-renderer-table-cell-max-width: 240px;
79
82
  }
@@ -87,18 +87,37 @@
87
87
  display: none;
88
88
  }
89
89
  .g-aikit-markdown-renderer {
90
+ width: 100%;
90
91
  max-width: 100%;
92
+ min-width: 0;
91
93
  overflow-x: auto;
92
- /* Tables inside message wrappers: reset inherited word-break; scroll on this root when wide */
94
+ /*
95
+ * Override @diplodoc/transform `.yfm table` (inline-block + max-width: 100%).
96
+ * min-width: 100% — narrow tables fill the message; width: max-content — wide tables grow.
97
+ * Horizontal scroll lives on this root (min-width: 0 on flex ancestors required).
98
+ */
93
99
  }
94
100
  .g-aikit-markdown-renderer table {
101
+ display: table;
95
102
  table-layout: auto;
96
103
  word-break: normal;
97
- min-width: 100%;
98
104
  width: max-content;
105
+ min-width: 100%;
106
+ max-width: none;
107
+ overflow: visible;
99
108
  }
100
- .g-aikit-markdown-renderer th,
101
- .g-aikit-markdown-renderer td {
109
+ .g-aikit-markdown-renderer table th {
102
110
  word-break: normal;
103
111
  white-space: nowrap;
112
+ overflow: visible;
113
+ text-overflow: clip;
114
+ }
115
+ .g-aikit-markdown-renderer table td {
116
+ max-width: var(--g-aikit-markdown-renderer-table-cell-max-width);
117
+ word-break: normal;
118
+ white-space: normal;
119
+ /* Wrap multi-word text at spaces within max-width; do not break tokens at hyphens */
120
+ overflow-wrap: normal;
121
+ overflow: visible;
122
+ text-overflow: clip;
104
123
  }
@@ -10,6 +10,8 @@
10
10
  }
11
11
  .g-aikit-base-message_variant_system, .g-aikit-base-message_variant_assistant {
12
12
  align-items: flex-start;
13
+ min-width: 0;
14
+ max-width: 100%;
13
15
  }
14
16
  .g-aikit-base-message_btn-hover .g-aikit-base-message__actions {
15
17
  visibility: hidden;
@@ -3,4 +3,5 @@
3
3
  flex-direction: column;
4
4
  gap: var(--g-spacing-3);
5
5
  width: 100%;
6
+ min-width: 0;
6
7
  }
@@ -4,6 +4,7 @@
4
4
  display: flex;
5
5
  flex-direction: column;
6
6
  min-height: 0;
7
+ min-width: 0;
7
8
  flex: 1;
8
9
  align-self: stretch;
9
10
  }
@@ -11,6 +12,7 @@
11
12
  display: flex;
12
13
  flex-direction: column;
13
14
  gap: var(--g-spacing-4);
15
+ min-width: 0;
14
16
  }
15
17
  .g-aikit-message-list_virtualized {
16
18
  overflow: hidden;
@@ -17,6 +17,7 @@
17
17
  align-self: stretch;
18
18
  flex: 1;
19
19
  min-height: 0;
20
+ min-width: 0;
20
21
  }
21
22
  .g-aikit-chat-content__message-list {
22
23
  padding: var(--g-spacing-2) var(--g-spacing-2) 0 var(--g-spacing-2);
@@ -1 +1 @@
1
- {"version":"2.7.0","type":"module","sideEffects":["*.css","*.scss"]}
1
+ {"version":"2.7.1-beta.9cedd61361943cd0ba3f67bdeee91a18e3e00cfc.0","type":"module","sideEffects":["*.css","*.scss"]}
@@ -74,4 +74,7 @@
74
74
  /* === Action Popup === */
75
75
  --g-aikit-action-popup-min-width: 280px;
76
76
  --g-aikit-action-popup-max-width: 400px;
77
+
78
+ /* === Markdown Renderer === */
79
+ --g-aikit-markdown-renderer-table-cell-max-width: 240px;
77
80
  }
@@ -76,4 +76,7 @@
76
76
  /* === Action Popup === */
77
77
  --g-aikit-action-popup-min-width: 280px;
78
78
  --g-aikit-action-popup-max-width: 400px;
79
+
80
+ /* === Markdown Renderer === */
81
+ --g-aikit-markdown-renderer-table-cell-max-width: 240px;
79
82
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@gravity-ui/aikit",
3
- "version": "2.7.0",
3
+ "version": "2.7.1-beta.9cedd61361943cd0ba3f67bdeee91a18e3e00cfc.0",
4
4
  "description": "Gravity UI base kit for building ai assistant chats",
5
5
  "license": "MIT",
6
6
  "type": "commonjs",