@gooddata/sdk-ui-semantic-search 11.9.0-alpha.1 → 11.9.0-alpha.3

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 (53) hide show
  1. package/esm/FooterButtonAiAssistant.d.ts.map +1 -1
  2. package/esm/FooterButtonAiAssistant.js +2 -1
  3. package/esm/FooterButtonAiAssistant.js.map +1 -1
  4. package/esm/FooterButtonAiAssistant.module.css +24 -0
  5. package/esm/FooterButtonAiAssistant.module.css.map +1 -0
  6. package/esm/GroupResultCounterStyles.module.css +21 -0
  7. package/esm/GroupResultCounterStyles.module.css.map +1 -0
  8. package/esm/SearchItem.d.ts.map +1 -1
  9. package/esm/SearchItem.js +3 -5
  10. package/esm/SearchItem.js.map +1 -1
  11. package/esm/SearchItem.module.css +81 -0
  12. package/esm/SearchItem.module.css.map +1 -0
  13. package/esm/SearchItemDetailsStyles.module.css +41 -0
  14. package/esm/SearchItemDetailsStyles.module.css.map +1 -0
  15. package/esm/SearchItemText.module.css +18 -0
  16. package/esm/SearchItemText.module.css.map +1 -0
  17. package/esm/SemanticSearch.d.ts.map +1 -1
  18. package/esm/SemanticSearch.js +7 -5
  19. package/esm/SemanticSearch.js.map +1 -1
  20. package/esm/SemanticSearch.module.css +18 -0
  21. package/esm/SemanticSearch.module.css.map +1 -0
  22. package/esm/SemanticSearchItem.d.ts.map +1 -1
  23. package/esm/SemanticSearchItem.js +2 -1
  24. package/esm/SemanticSearchItem.js.map +1 -1
  25. package/esm/internal/GroupResultCounter.d.ts.map +1 -1
  26. package/esm/internal/GroupResultCounter.js +2 -1
  27. package/esm/internal/GroupResultCounter.js.map +1 -1
  28. package/esm/internal/HistorySearchTreeViewItem.d.ts.map +1 -1
  29. package/esm/internal/HistorySearchTreeViewItem.js +2 -1
  30. package/esm/internal/HistorySearchTreeViewItem.js.map +1 -1
  31. package/esm/internal/LeveledSearchTreeViewItem.d.ts.map +1 -1
  32. package/esm/internal/LeveledSearchTreeViewItem.js +2 -1
  33. package/esm/internal/LeveledSearchTreeViewItem.js.map +1 -1
  34. package/esm/internal/SearchItemDetails.d.ts.map +1 -1
  35. package/esm/internal/SearchItemDetails.js +3 -2
  36. package/esm/internal/SearchItemDetails.js.map +1 -1
  37. package/esm/internal/SearchNoResults.d.ts.map +1 -1
  38. package/esm/internal/SearchNoResults.js +3 -2
  39. package/esm/internal/SearchNoResults.js.map +1 -1
  40. package/esm/internal/SearchNoResults.module.css +10 -0
  41. package/esm/internal/SearchNoResults.module.css.map +1 -0
  42. package/esm/internal/SearchOverlay.d.ts.map +1 -1
  43. package/esm/internal/SearchOverlay.js +3 -2
  44. package/esm/internal/SearchOverlay.js.map +1 -1
  45. package/esm/internal/SearchOverlay.module.css +22 -0
  46. package/esm/internal/SearchOverlay.module.css.map +1 -0
  47. package/package.json +16 -13
  48. package/styles/css/internal.css +2 -208
  49. package/styles/css/internal.css.map +1 -1
  50. package/styles/css/main.css +0 -176
  51. package/styles/css/main.css.map +1 -1
  52. package/styles/scss/internal.scss +11 -50
  53. package/styles/scss/main.scss +4 -214
@@ -6,58 +6,19 @@
6
6
  @use "@gooddata/sdk-ui-kit/styles/scss/mixins" as kit-mixins;
7
7
  @use "./main.scss" as main;
8
8
 
9
- .gd-semantic-search {
10
- &__overlay {
11
- background: kit-variables.$gd-color-white;
12
- margin: 10px 0;
9
+ // Context-dependent styles that cannot be expressed in CSS modules
10
+ // These styles apply when semantic search is used within specific containers
13
11
 
14
- // Desktop view
15
- .gd-header-search-dropdown & {
16
- width: 440px;
17
- }
18
-
19
- // Mobile view
20
- .gd-header-menu-search & {
21
- .gd-semantic-search__overlay-input {
22
- margin-bottom: 10px;
23
- }
24
- }
25
- }
26
-
27
- &__overlay-input {
28
- margin: 0 10px;
29
-
30
- input:focus-visible {
31
- outline: 1px auto kit-variables.$gd-input-text-border-outline;
32
- outline-offset: 0;
33
- }
34
- }
35
-
36
- &__ai_assistant_button {
37
- button.gd-ui-kit-button--variant-tertiary.gd-ui-kit-button--hasIconBefore {
38
- padding-left: 7px;
39
- }
40
-
41
- button:focus-visible {
42
- outline: 1px auto kit-variables.$gd-input-text-border-outline;
43
- outline-offset: 0;
44
- }
45
- }
46
-
47
- &__overlay-error,
48
- &__overlay-no-results {
49
- display: flex;
50
- justify-content: center;
51
- align-items: center;
52
- color: kit-variables.$gd-color-state-blank;
53
- }
54
-
55
- &__overlay-error {
56
- padding: 10px 10px 0;
12
+ // Desktop header dropdown context
13
+ .gd-header-search-dropdown {
14
+ .gd-semantic-search__overlay {
15
+ width: 440px;
57
16
  }
17
+ }
58
18
 
59
- &__overlay-no-results {
60
- height: 100px;
61
- padding: 0 10px;
19
+ // Mobile header menu context
20
+ .gd-header-menu-search {
21
+ .gd-semantic-search__overlay-input {
22
+ margin-bottom: 10px;
62
23
  }
63
24
  }
@@ -4,221 +4,11 @@
4
4
  @use "@gooddata/sdk-ui-kit/src/@ui/defaultTheme.scss";
5
5
  @use "@gooddata/sdk-ui-kit/styles/scss/variables" as kit-variables;
6
6
 
7
- @mixin icon($icon_size) {
8
- width: $icon_size;
9
- height: $icon_size;
10
-
11
- svg {
12
- // dashboard icon needs explicit size
13
- width: $icon_size;
14
- height: $icon_size;
15
- }
16
- }
17
-
18
- .gd-semantic-search {
19
- &__results-item {
20
- $root: &;
21
- cursor: pointer;
22
- user-select: none;
23
- width: 100%;
24
-
25
- display: flex;
26
- flex-direction: row;
27
- align-items: center;
28
-
29
- &[data-level="1"] {
30
- $item-height: 50px;
31
- height: $item-height;
32
-
33
- #{$root}__content {
34
- height: calc($item-height - 2px);
35
- }
36
- #{$root}__icon {
37
- @include icon(26px);
38
- }
39
- }
40
-
41
- &[data-level="2"] {
42
- $item-height: 30px;
43
- height: $item-height;
44
- padding-left: 10px;
45
-
46
- #{$root}__content {
47
- height: calc($item-height - 2px);
48
- }
49
- #{$root}__icon {
50
- @include icon(16px);
51
- }
52
- }
53
-
54
- &--active {
55
- color: kit-variables.$is-focused-color;
56
- background: kit-variables.$is-focused-background;
57
- }
58
-
59
- &__content {
60
- box-sizing: border-box;
61
- width: 100%;
62
- margin: 1px 0;
63
- display: flex;
64
- flex-direction: row;
65
- align-items: center;
66
- gap: 1em;
67
- padding: 5px 12px;
68
- text-decoration: none;
69
-
70
- &:hover,
71
- &:focus,
72
- &:active,
73
- &:visited {
74
- text-decoration: none;
75
- }
76
-
77
- &:focus-visible {
78
- outline: revert;
79
- }
80
- }
81
-
82
- &__text {
83
- flex: 1;
84
- min-width: 0; // A hack to make ellipsis work in flexbox
85
- display: flex;
86
- flex-direction: column;
87
- font-weight: 400;
88
- color: kit-variables.$gd-color-text;
89
- font-size: 14px;
90
- line-height: 20px;
91
-
92
- &__row {
93
- display: flex;
94
- flex-direction: row;
95
- align-items: center;
96
- gap: 5px;
97
- }
98
-
99
- &__row:not(:first-child) {
100
- color: kit-variables.$gd-color-state-blank;
101
- }
102
-
103
- &__ellipsis {
104
- white-space: nowrap;
105
- overflow: hidden;
106
- text-overflow: ellipsis;
107
- flex-shrink: 1;
108
- }
109
- }
110
-
111
- &__details-container {
112
- display: grid;
113
- justify-items: end;
114
- height: 100%;
115
- font-size: 14px;
116
- color: kit-variables.$gd-color-state-blank;
117
- }
118
-
119
- &__details {
120
- width: 16px;
121
- height: 16px;
122
- align-self: center;
123
- align-items: center;
124
-
125
- & .gd-ellipsis-text {
126
- margin: 10px 0 0;
127
- }
128
- }
129
-
130
- &__details__contents {
131
- width: 190px;
132
- padding: 5px;
133
- box-sizing: border-box;
134
- display: flex;
135
- flex-direction: column;
136
-
137
- h3 {
138
- font-size: 14px;
139
- margin: 0;
140
- }
141
-
142
- .gd-ellipsis-text-content {
143
- font-size: 12px;
144
- }
145
-
146
- h4 {
147
- margin: 10px 0 0;
148
- text-transform: uppercase;
149
- font-size: 10px;
150
- font-weight: 400;
151
- color: kit-variables.$gd-color-state-blank;
152
- }
153
-
154
- hr {
155
- margin: 10px 0;
156
- border: 0;
157
- border-top: 1px solid kit-variables.$gd-border-color;
158
- }
159
-
160
- &__match h4 {
161
- text-transform: none;
162
- font-size: 12px;
163
- }
164
- }
165
-
166
- &__counter {
167
- display: flex;
168
- align-self: end;
169
- align-items: center;
170
- gap: 5px;
171
- line-height: 16px;
172
- }
173
-
174
- &__counter__icon {
175
- width: 16px;
176
- height: 16px;
177
- transition: rotate 0.2s;
178
- transform-origin: center;
179
- rotate: 0deg;
180
-
181
- &--expanded {
182
- rotate: 90deg;
183
- }
184
- }
185
- }
186
-
187
- &__bubble.bubble.bubble-light {
188
- background: kit-variables.$gd-color-white;
189
- }
190
-
191
- &__bubble_trigger {
192
- display: flex;
193
- }
194
-
195
- &__ai_assistant_button {
196
- display: flex;
197
- height: 50px;
198
- align-items: center;
199
- margin-bottom: -10px;
200
- border: 1px solid kit-variables.$gd-color-white;
201
- border-top-color: kit-variables.$gd-border-color;
202
- background: kit-variables.$gd-color-white;
203
- margin-top: 10px;
204
-
205
- button {
206
- height: 100%;
207
- width: 100%;
208
- justify-content: flex-start;
209
- }
210
- }
211
-
212
- &__message {
213
- display: flex;
214
- justify-content: center;
215
- align-items: center;
216
- color: kit-variables.$gd-color-state-blank;
217
- height: 100px;
218
- padding: 0 10px;
219
- }
220
- }
7
+ // All component styles have been migrated to CSS modules
8
+ // This file is kept for backward compatibility
9
+ // Legacy consumers still import styles/css/main.css which needs defaultTheme
221
10
 
11
+ // The only remaining style that hasn't been migrated, overrides a classname defined in sdk-ui-kit:
222
12
  .gd-ui-kit-treeview {
223
13
  margin: 10px 0;
224
14
  }