mirror of
https://github.com/carbon-design-system/carbon-components-svelte.git
synced 2025-09-18 19:46:36 +00:00
add name prop to Search component
This commit is contained in:
parent
b5b392963e
commit
90d983216d
5 changed files with 2975 additions and 1522 deletions
|
@ -3097,6 +3097,7 @@ None.
|
||||||
| labelText | No | <code>let</code> | No | <code>string</code> | <code>""</code> | Specify the label text |
|
| labelText | No | <code>let</code> | No | <code>string</code> | <code>""</code> | Specify the label text |
|
||||||
| icon | No | <code>let</code> | No | <code>typeof import("svelte").SvelteComponent</code> | <code>undefined</code> | Specify the icon to render.<br />Defaults to `<Search />` |
|
| icon | No | <code>let</code> | No | <code>typeof import("svelte").SvelteComponent</code> | <code>undefined</code> | Specify the icon to render.<br />Defaults to `<Search />` |
|
||||||
| id | No | <code>let</code> | No | <code>string</code> | <code>"ccs-" + Math.random().toString(36)</code> | Set an id for the input element |
|
| id | No | <code>let</code> | No | <code>string</code> | <code>"ccs-" + Math.random().toString(36)</code> | Set an id for the input element |
|
||||||
|
| name | No | <code>let</code> | No | <code>string</code> | <code>undefined</code> | Specify a name attribute for the input |
|
||||||
|
|
||||||
### Slots
|
### Slots
|
||||||
|
|
||||||
|
|
|
@ -9950,6 +9950,17 @@
|
||||||
"constant": false,
|
"constant": false,
|
||||||
"reactive": false
|
"reactive": false
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
"name": "name",
|
||||||
|
"kind": "let",
|
||||||
|
"description": "Specify a name attribute for the input",
|
||||||
|
"type": "string",
|
||||||
|
"isFunction": false,
|
||||||
|
"isFunctionDeclaration": false,
|
||||||
|
"isRequired": false,
|
||||||
|
"constant": false,
|
||||||
|
"reactive": false
|
||||||
|
},
|
||||||
{
|
{
|
||||||
"name": "ref",
|
"name": "ref",
|
||||||
"kind": "let",
|
"kind": "let",
|
||||||
|
|
|
@ -62,6 +62,12 @@
|
||||||
/** Set an id for the input element */
|
/** Set an id for the input element */
|
||||||
export let id = "ccs-" + Math.random().toString(36);
|
export let id = "ccs-" + Math.random().toString(36);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Specify a name attribute for the input
|
||||||
|
* @type {string}
|
||||||
|
*/
|
||||||
|
export let name = undefined;
|
||||||
|
|
||||||
/** Obtain a reference to the input HTML element */
|
/** Obtain a reference to the input HTML element */
|
||||||
export let ref = null;
|
export let ref = null;
|
||||||
|
|
||||||
|
@ -126,6 +132,7 @@
|
||||||
autocomplete="{autocomplete}"
|
autocomplete="{autocomplete}"
|
||||||
disabled="{disabled}"
|
disabled="{disabled}"
|
||||||
id="{id}"
|
id="{id}"
|
||||||
|
name="{name}"
|
||||||
placeholder="{placeholder}"
|
placeholder="{placeholder}"
|
||||||
{...$$restProps}
|
{...$$restProps}
|
||||||
on:change
|
on:change
|
||||||
|
|
6
types/Search/Search.svelte.d.ts
vendored
6
types/Search/Search.svelte.d.ts
vendored
|
@ -93,6 +93,12 @@ export interface SearchProps {
|
||||||
*/
|
*/
|
||||||
id?: string;
|
id?: string;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Specify a name attribute for the input
|
||||||
|
* @default undefined
|
||||||
|
*/
|
||||||
|
name?: string;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Obtain a reference to the input HTML element
|
* Obtain a reference to the input HTML element
|
||||||
* @default null
|
* @default null
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue