@wix/web5-core 1.57.2 → 1.58.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.
- package/dist/cjs/client/clientBundleUrl.js +40 -0
- package/dist/cjs/client/clientBundleUrl.js.map +1 -0
- package/dist/cjs/client/mergeClientConfig.js +59 -0
- package/dist/cjs/client/mergeClientConfig.js.map +1 -0
- package/dist/cjs/component/componentDefinitions/EntityCollectionSectionDefinition.js +159 -0
- package/dist/cjs/component/componentDefinitions/EntityCollectionSectionDefinition.js.map +1 -0
- package/dist/cjs/component/componentDefinitions/index.js +7 -1
- package/dist/cjs/component/componentDefinitions/index.js.map +1 -1
- package/dist/cjs/component/componentParser.js +38 -1
- package/dist/cjs/component/componentParser.js.map +1 -1
- package/dist/cjs/components/ui/SearchSection.css +66 -9
- package/dist/cjs/components/ui/SearchSection.js +23 -19
- package/dist/cjs/components/ui/SearchSection.js.map +1 -1
- package/dist/cjs/index.js +15 -3
- package/dist/cjs/index.js.map +1 -1
- package/dist/cjs/styles/prompt-input-tokens.css +41 -34
- package/dist/cjs/utils/matchDebug.js +93 -0
- package/dist/cjs/utils/matchDebug.js.map +1 -0
- package/dist/esm/client/clientBundleUrl.js +36 -0
- package/dist/esm/client/clientBundleUrl.js.map +1 -0
- package/dist/esm/client/mergeClientConfig.js +55 -0
- package/dist/esm/client/mergeClientConfig.js.map +1 -0
- package/dist/esm/component/componentDefinitions/EntityCollectionSectionDefinition.js +154 -0
- package/dist/esm/component/componentDefinitions/EntityCollectionSectionDefinition.js.map +1 -0
- package/dist/esm/component/componentDefinitions/index.js +7 -1
- package/dist/esm/component/componentDefinitions/index.js.map +1 -1
- package/dist/esm/component/componentParser.js +38 -1
- package/dist/esm/component/componentParser.js.map +1 -1
- package/dist/esm/components/ui/SearchSection.css +66 -9
- package/dist/esm/components/ui/SearchSection.js +5 -1
- package/dist/esm/components/ui/SearchSection.js.map +1 -1
- package/dist/esm/index.js +8 -1
- package/dist/esm/index.js.map +1 -1
- package/dist/esm/styles/prompt-input-tokens.css +41 -34
- package/dist/esm/utils/matchDebug.js +85 -0
- package/dist/esm/utils/matchDebug.js.map +1 -0
- package/dist/types/client/clientBundleUrl.d.ts +17 -0
- package/dist/types/client/clientBundleUrl.d.ts.map +1 -0
- package/dist/types/client/mergeClientConfig.d.ts +28 -0
- package/dist/types/client/mergeClientConfig.d.ts.map +1 -0
- package/dist/types/component/componentDefinitions/EntityCollectionSectionDefinition.d.ts +51 -0
- package/dist/types/component/componentDefinitions/EntityCollectionSectionDefinition.d.ts.map +1 -0
- package/dist/types/component/componentDefinitions/index.d.ts +1 -0
- package/dist/types/component/componentDefinitions/index.d.ts.map +1 -1
- package/dist/types/component/componentParser.d.ts.map +1 -1
- package/dist/types/components/ui/SearchSection.d.ts.map +1 -1
- package/dist/types/index.d.ts +4 -1
- package/dist/types/index.d.ts.map +1 -1
- package/dist/types/utils/matchDebug.d.ts +38 -0
- package/dist/types/utils/matchDebug.d.ts.map +1 -0
- package/package.json +2 -2
- package/src/components/ui/SearchSection.css +66 -9
- package/src/styles/prompt-input-tokens.css +41 -34
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@wix/web5-core",
|
|
3
3
|
"license": "MIT",
|
|
4
|
-
"version": "1.
|
|
4
|
+
"version": "1.58.0",
|
|
5
5
|
"author": {
|
|
6
6
|
"name": "tsachis",
|
|
7
7
|
"email": "tsachis@wix.com"
|
|
@@ -100,5 +100,5 @@
|
|
|
100
100
|
"wallaby": {
|
|
101
101
|
"autoDetect": true
|
|
102
102
|
},
|
|
103
|
-
"falconPackageHash": "
|
|
103
|
+
"falconPackageHash": "13170d1c2ae66823381f08daccc041ed2f0aeb0065eaea2486efa25d"
|
|
104
104
|
}
|
|
@@ -152,15 +152,20 @@
|
|
|
152
152
|
flex-direction: column-reverse;
|
|
153
153
|
}
|
|
154
154
|
|
|
155
|
+
/* Chips stack vertically above the pill, left-aligned to it, and share the
|
|
156
|
+
pill's width so the two edges line up as it expands on focus. */
|
|
155
157
|
.web5-prompt-shell__chips {
|
|
156
158
|
display: flex;
|
|
157
|
-
flex-
|
|
158
|
-
|
|
159
|
+
flex-direction: column;
|
|
160
|
+
flex-wrap: nowrap;
|
|
161
|
+
align-items: flex-start;
|
|
162
|
+
justify-content: flex-start;
|
|
159
163
|
gap: var(--pi-chip-gap);
|
|
160
164
|
margin: 0 auto;
|
|
161
165
|
width: 100%;
|
|
162
|
-
max-width:
|
|
166
|
+
max-width: var(--pi-content-max-w);
|
|
163
167
|
overflow: hidden;
|
|
168
|
+
/* `max-width` omitted for the same reason as `.web5-prompt-search__inner`. */
|
|
164
169
|
transition: transform var(--pi-transition-medium),
|
|
165
170
|
opacity var(--pi-transition-medium), max-height var(--pi-transition-medium);
|
|
166
171
|
pointer-events: auto;
|
|
@@ -169,10 +174,45 @@
|
|
|
169
174
|
.web5-prompt-shell__chips--visible {
|
|
170
175
|
transform: translateY(0);
|
|
171
176
|
opacity: 1;
|
|
172
|
-
max-height:
|
|
177
|
+
max-height: 260px;
|
|
173
178
|
overflow: visible;
|
|
174
179
|
}
|
|
175
180
|
|
|
181
|
+
/* Each chip rises into place, the one nearest the pill first. */
|
|
182
|
+
@keyframes web5-prompt-chip-float-up {
|
|
183
|
+
from {
|
|
184
|
+
opacity: 0;
|
|
185
|
+
transform: translateY(12px);
|
|
186
|
+
}
|
|
187
|
+
to {
|
|
188
|
+
opacity: 1;
|
|
189
|
+
transform: translateY(0);
|
|
190
|
+
}
|
|
191
|
+
}
|
|
192
|
+
|
|
193
|
+
.web5-prompt-shell__chips--visible .web5-prompt-chip {
|
|
194
|
+
animation: web5-prompt-chip-float-up 400ms cubic-bezier(0.22, 0.61, 0.36, 1)
|
|
195
|
+
both;
|
|
196
|
+
}
|
|
197
|
+
|
|
198
|
+
.web5-prompt-shell__chips--visible .web5-prompt-chip:nth-child(1) {
|
|
199
|
+
animation-delay: 400ms;
|
|
200
|
+
}
|
|
201
|
+
|
|
202
|
+
.web5-prompt-shell__chips--visible .web5-prompt-chip:nth-child(2) {
|
|
203
|
+
animation-delay: 300ms;
|
|
204
|
+
}
|
|
205
|
+
|
|
206
|
+
.web5-prompt-shell__chips--visible .web5-prompt-chip:nth-child(n + 3) {
|
|
207
|
+
animation-delay: 200ms;
|
|
208
|
+
}
|
|
209
|
+
|
|
210
|
+
@media (prefers-reduced-motion: reduce) {
|
|
211
|
+
.web5-prompt-shell__chips--visible .web5-prompt-chip {
|
|
212
|
+
animation: none;
|
|
213
|
+
}
|
|
214
|
+
}
|
|
215
|
+
|
|
176
216
|
.web5-prompt-shell__chips--hidden {
|
|
177
217
|
transform: translateY(1rem);
|
|
178
218
|
opacity: 0;
|
|
@@ -189,6 +229,7 @@
|
|
|
189
229
|
border: 1px solid var(--pi-chip-border, transparent);
|
|
190
230
|
border-radius: var(--pi-chip-radius);
|
|
191
231
|
background: var(--pi-chip-bg);
|
|
232
|
+
backdrop-filter: blur(var(--pi-chip-blur));
|
|
192
233
|
box-shadow: var(--pi-chip-shadow);
|
|
193
234
|
color: var(--pi-chip-text);
|
|
194
235
|
font-family: var(--pi-field-font-family);
|
|
@@ -209,7 +250,7 @@
|
|
|
209
250
|
/* Inset ring so the focus indicator isn't clipped by the chips container's overflow: hidden */
|
|
210
251
|
.web5-prompt-chip:focus-visible {
|
|
211
252
|
outline: none;
|
|
212
|
-
box-shadow: inset 0 0 0 2px
|
|
253
|
+
box-shadow: inset 0 0 0 2px var(--pi-chip-focus-ring), var(--pi-chip-shadow);
|
|
213
254
|
}
|
|
214
255
|
|
|
215
256
|
.web5-prompt-search {
|
|
@@ -220,12 +261,26 @@
|
|
|
220
261
|
|
|
221
262
|
.web5-prompt-search__inner {
|
|
222
263
|
position: relative;
|
|
223
|
-
width: min(100%,
|
|
264
|
+
/* `width: 100%` + a plain-length `max-width`, not `width: min(100%, …)`:
|
|
265
|
+
Chrome cannot interpolate between two min() values, which would freeze the
|
|
266
|
+
focus transition below at 0 progress. */
|
|
267
|
+
width: 100%;
|
|
268
|
+
max-width: var(--pi-content-max-w);
|
|
224
269
|
min-width: min(100%, var(--pi-content-min-w));
|
|
225
270
|
margin-inline: auto;
|
|
271
|
+
/* `max-width` is deliberately NOT transitioned: with a transition declared on
|
|
272
|
+
it, Chrome never runs the swap and the pill stays pinned at the idle width
|
|
273
|
+
(verified against the seed widget, which shares this rule shape). The widen
|
|
274
|
+
is therefore instant rather than the mock's 250ms ease. */
|
|
226
275
|
pointer-events: auto;
|
|
227
276
|
}
|
|
228
277
|
|
|
278
|
+
/* Focus widens the pill (and the chip column above it) from the idle width. */
|
|
279
|
+
.web5-prompt-shell--focused .web5-prompt-search__inner,
|
|
280
|
+
.web5-prompt-shell--focused .web5-prompt-shell__chips {
|
|
281
|
+
max-width: var(--pi-content-max-w-focused);
|
|
282
|
+
}
|
|
283
|
+
|
|
229
284
|
.web5-prompt-field-wrap {
|
|
230
285
|
position: relative;
|
|
231
286
|
display: flex;
|
|
@@ -243,6 +298,7 @@
|
|
|
243
298
|
border: var(--pi-field-border-width) solid var(--pi-field-border);
|
|
244
299
|
border-radius: var(--pi-field-radius-pill);
|
|
245
300
|
background: var(--pi-field-bg);
|
|
301
|
+
backdrop-filter: blur(var(--pi-field-blur));
|
|
246
302
|
box-shadow: var(--pi-field-shadow);
|
|
247
303
|
transition: min-height var(--pi-transition-medium),
|
|
248
304
|
border-radius var(--pi-transition-medium),
|
|
@@ -264,7 +320,8 @@
|
|
|
264
320
|
min-width: 0;
|
|
265
321
|
min-height: var(--pi-field-line-height);
|
|
266
322
|
max-height: calc(var(--pi-field-max-h) - var(--pi-field-line-height));
|
|
267
|
-
|
|
323
|
+
/* Clear the absolutely-positioned submit button. */
|
|
324
|
+
padding: 0 calc(var(--pi-submit-size) + 8px) 0 0;
|
|
268
325
|
border: 0;
|
|
269
326
|
outline: none;
|
|
270
327
|
background: transparent;
|
|
@@ -481,12 +538,12 @@
|
|
|
481
538
|
font-size: max(16px, var(--pi-field-font-size));
|
|
482
539
|
}
|
|
483
540
|
|
|
541
|
+
/* Keeps the chip fill: `--pi-chip-text` is light, so a transparent chip on
|
|
542
|
+
the white mobile panel would be unreadable. */
|
|
484
543
|
.web5-prompt-chip {
|
|
485
544
|
width: 100%;
|
|
486
545
|
justify-content: flex-start;
|
|
487
546
|
padding: 10px 18px;
|
|
488
|
-
background: transparent;
|
|
489
|
-
box-shadow: none;
|
|
490
547
|
font-size: 16px;
|
|
491
548
|
line-height: 20px;
|
|
492
549
|
white-space: normal;
|
|
@@ -56,53 +56,60 @@
|
|
|
56
56
|
);
|
|
57
57
|
--pi-home-entry-panel-shadow: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
|
|
58
58
|
--pi-home-entry-panel-blur: 20px;
|
|
59
|
-
|
|
59
|
+
/* Idle pill width; widens to `--pi-content-max-w-focused` while the field
|
|
60
|
+
(or a chip) holds focus. */
|
|
61
|
+
--pi-content-max-w: 320px;
|
|
62
|
+
--pi-content-max-w-focused: 550px;
|
|
60
63
|
--pi-content-min-w: 250px;
|
|
61
64
|
--pi-stack-gap: 15px;
|
|
62
|
-
--pi-chip-gap:
|
|
65
|
+
--pi-chip-gap: 6px;
|
|
63
66
|
--pi-chip-mobile-gap: 0;
|
|
64
67
|
--pi-chip-mobile-overflow-y: scroll;
|
|
65
|
-
--pi-field-min-h:
|
|
66
|
-
--pi-field-max-h:
|
|
67
|
-
--pi-field-border-width:
|
|
68
|
+
--pi-field-min-h: 48px;
|
|
69
|
+
--pi-field-max-h: 200px;
|
|
70
|
+
--pi-field-border-width: 0;
|
|
68
71
|
--pi-home-entry-field-radius: 10px;
|
|
69
|
-
--pi-field-radius-pill:
|
|
70
|
-
--pi-field-radius-multiline:
|
|
71
|
-
--pi-field-border:
|
|
72
|
-
--pi-field-bg:
|
|
73
|
-
|
|
74
|
-
--pi-field-
|
|
75
|
-
--pi-field-padding-
|
|
76
|
-
--pi-field-padding-
|
|
77
|
-
--pi-field-padding-
|
|
72
|
+
--pi-field-radius-pill: 24px;
|
|
73
|
+
--pi-field-radius-multiline: 24px;
|
|
74
|
+
--pi-field-border: transparent;
|
|
75
|
+
--pi-field-bg: rgba(255, 255, 255, 0.9);
|
|
76
|
+
/* Frosted pill: the host page shows through the translucent `--pi-field-bg`. */
|
|
77
|
+
--pi-field-blur: 10px;
|
|
78
|
+
--pi-field-padding-top: 13px;
|
|
79
|
+
--pi-field-padding-right: 10px;
|
|
80
|
+
--pi-field-padding-bottom: 13px;
|
|
81
|
+
--pi-field-padding-left: 26px;
|
|
82
|
+
--pi-field-padding-top-multiline: 16px;
|
|
78
83
|
--pi-field-text: #2b2b2b;
|
|
79
|
-
--pi-field-placeholder: #
|
|
84
|
+
--pi-field-placeholder: #6c6f74;
|
|
80
85
|
--pi-field-caret: #2b2b2b;
|
|
81
86
|
--pi-field-font-family: Poppins, ui-sans-serif, sans-serif, system-ui;
|
|
82
|
-
--pi-field-font-size:
|
|
83
|
-
--pi-field-line-height:
|
|
84
|
-
--pi-field-line-height-multiline:
|
|
85
|
-
--pi-field-shadow: 0
|
|
86
|
-
0
|
|
87
|
-
--pi-chip-padding-y:
|
|
88
|
-
--pi-chip-padding-x:
|
|
89
|
-
--pi-chip-radius:
|
|
87
|
+
--pi-field-font-size: 14px;
|
|
88
|
+
--pi-field-line-height: 21px;
|
|
89
|
+
--pi-field-line-height-multiline: 21px;
|
|
90
|
+
--pi-field-shadow: 0 -1px 0 0 rgba(0, 0, 0, 0.05),
|
|
91
|
+
0 1px 3px 0 rgba(9, 14, 21, 0.2), 0 6px 14px 0 rgba(0, 0, 0, 0.24);
|
|
92
|
+
--pi-chip-padding-y: 8px;
|
|
93
|
+
--pi-chip-padding-x: 16px;
|
|
94
|
+
--pi-chip-radius: 20px;
|
|
90
95
|
--pi-chip-border: transparent;
|
|
91
|
-
--pi-chip-bg:
|
|
92
|
-
--pi-chip-text: #
|
|
96
|
+
--pi-chip-bg: rgba(42, 42, 42, 0.5);
|
|
97
|
+
--pi-chip-text: #ffffff;
|
|
98
|
+
--pi-chip-blur: 100px;
|
|
93
99
|
--pi-chip-font-size: 14px;
|
|
94
|
-
--pi-chip-line-height:
|
|
95
|
-
--pi-chip-shadow: 0
|
|
96
|
-
|
|
97
|
-
--pi-chip-hover-bg: #f6f6f6;
|
|
100
|
+
--pi-chip-line-height: 20px;
|
|
101
|
+
--pi-chip-shadow: 0 1px 2px 0 rgba(9, 14, 21, 0.2);
|
|
102
|
+
--pi-chip-hover-bg: rgba(42, 42, 42, 0.58);
|
|
98
103
|
--pi-chip-hover-transform: translateY(-1px);
|
|
99
|
-
|
|
100
|
-
--pi-
|
|
101
|
-
--pi-submit-
|
|
102
|
-
--pi-submit-
|
|
104
|
+
/* Chips sit on a dark translucent fill — the ring has to read light. */
|
|
105
|
+
--pi-chip-focus-ring: rgba(255, 255, 255, 0.9);
|
|
106
|
+
--pi-submit-size: 32px;
|
|
107
|
+
--pi-submit-radius: 999px;
|
|
108
|
+
--pi-submit-bg: rgba(43, 43, 43, 0.1);
|
|
109
|
+
--pi-submit-fg: #6c6f74;
|
|
103
110
|
--pi-submit-active-bg: #2b2b2b;
|
|
104
111
|
--pi-submit-active-fg: #ffffff;
|
|
105
|
-
--pi-submit-bottom:
|
|
112
|
+
--pi-submit-bottom: 8px;
|
|
106
113
|
--pi-submit-icon-size: 16px;
|
|
107
114
|
--pi-collapsed-btn-min-h: 48px;
|
|
108
115
|
--pi-collapsed-btn-padding-y: 12px;
|