@vendure-io/ui 2.0.0-beta.14 → 2.0.0-beta.15
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/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@vendure-io/ui",
|
|
3
|
-
"version": "2.0.0-beta.
|
|
3
|
+
"version": "2.0.0-beta.15",
|
|
4
4
|
"description": "React component library for Vendure, built on shadcn/ui and Tailwind v4",
|
|
5
5
|
"license": "SEE LICENSE IN LICENSE.md",
|
|
6
6
|
"homepage": "https://github.com/vendurehq/design/tree/main/packages/ui",
|
|
@@ -144,6 +144,17 @@ function ComboboxFreeText<T extends ComboboxFreeTextItem = ComboboxFreeTextItem>
|
|
|
144
144
|
// flashing when there is nothing to pick.
|
|
145
145
|
onFocus={() => setOpen(true)}
|
|
146
146
|
onClick={() => setOpen(true)}
|
|
147
|
+
// Enter has a local meaning here — commit the highlighted suggestion
|
|
148
|
+
// or keep the typed text — so it must never double as the browser's
|
|
149
|
+
// implicit form submission (Base UI deliberately lets Enter fall
|
|
150
|
+
// through to submit when nothing is highlighted). preventDefault
|
|
151
|
+
// cancels only the native submit; Base UI's own Enter handling runs
|
|
152
|
+
// regardless, since merged handlers ignore defaultPrevented.
|
|
153
|
+
onKeyDown={(event) => {
|
|
154
|
+
if (event.key === 'Enter') {
|
|
155
|
+
event.preventDefault();
|
|
156
|
+
}
|
|
157
|
+
}}
|
|
147
158
|
/>
|
|
148
159
|
{loading ? (
|
|
149
160
|
<InputGroupAddon align="inline-end">
|