mirror of
https://github.com/carbon-design-system/carbon-components-svelte.git
synced 2025-09-19 11:59:34 +00:00
fix(ui-shell): dispatched event is "select", not "search"
This commit is contained in:
parent
7d19ee8aa8
commit
5fe3f6d830
5 changed files with 7 additions and 13 deletions
|
@ -10325,15 +10325,14 @@
|
|||
{ "type": "dispatched", "name": "clear", "detail": "any" },
|
||||
{
|
||||
"type": "dispatched",
|
||||
"name": "search",
|
||||
"name": "select",
|
||||
"detail": "{ value: string; selectedResultIndex: number; selectedResult: HeaderSearchResult }"
|
||||
},
|
||||
{ "type": "forwarded", "name": "change", "element": "input" },
|
||||
{ "type": "forwarded", "name": "input", "element": "input" },
|
||||
{ "type": "forwarded", "name": "focus", "element": "input" },
|
||||
{ "type": "forwarded", "name": "blur", "element": "input" },
|
||||
{ "type": "forwarded", "name": "keydown", "element": "input" },
|
||||
{ "type": "dispatched", "name": "select" }
|
||||
{ "type": "forwarded", "name": "keydown", "element": "input" }
|
||||
],
|
||||
"typedefs": [
|
||||
{
|
||||
|
|
|
@ -63,17 +63,14 @@
|
|||
bind:ref
|
||||
bind:active
|
||||
bind:value
|
||||
on:search="{(e) => {
|
||||
console.log('on:search', e.detail);
|
||||
}}"
|
||||
bind:selectedResultIndex
|
||||
results="{results}"
|
||||
on:clear="{() => {
|
||||
console.log('on:clear');
|
||||
}}"
|
||||
on:select="{(e) => {
|
||||
console.log('on:select', e.detail);
|
||||
}}"
|
||||
results="{results}"
|
||||
bind:selectedResultIndex
|
||||
/>
|
||||
<HeaderAction bind:isOpen>
|
||||
<HeaderPanelLinks>
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue