Merge pull request #699 from ing-bank/fix/buttons-within-lion-field-story
fix(form-system): buttons within fields story
This commit is contained in:
commit
e6a3ade004
1 changed files with 5 additions and 3 deletions
|
|
@ -2,16 +2,18 @@ import { Story, Meta, html } from '@open-wc/demoing-storybook';
|
||||||
import '@lion/input/lion-input.js';
|
import '@lion/input/lion-input.js';
|
||||||
import '@lion/button/lion-button.js';
|
import '@lion/button/lion-button.js';
|
||||||
|
|
||||||
|
<Meta title="Forms/System/Field integrations" />
|
||||||
|
|
||||||
# Content inside fields
|
# Content inside fields
|
||||||
|
|
||||||
Due to our custom inputs being Web Components, it is possible to put HTML content inside an input.
|
Due to our custom inputs being Web Components, it is possible to put HTML content inside an input.
|
||||||
For example if you want to add a button as a prefix or suffix.
|
For example if you want to add a button as a prefix or suffix.
|
||||||
|
|
||||||
<Story name="Buttons Within lion fields">
|
<Story name="Buttons within fields">
|
||||||
{html`
|
{html`
|
||||||
<lion-input label="Prefix and sufix">
|
<lion-input label="Prefix and sufix">
|
||||||
<lion-button slot="prefix" type="button">prefix</lion-button>
|
<lion-button slot="prefix" type="button">prefix</lion-button>
|
||||||
<lion-button slot="suffix" type="button">sufix</lion-button>
|
<lion-button slot="suffix" type="button">suffix</lion-button>
|
||||||
</lion-input>
|
</lion-input>
|
||||||
`}
|
`}
|
||||||
</Story>
|
</Story>
|
||||||
|
|
@ -19,6 +21,6 @@ For example if you want to add a button as a prefix or suffix.
|
||||||
```html
|
```html
|
||||||
<lion-input label="Prefix and sufix">
|
<lion-input label="Prefix and sufix">
|
||||||
<lion-button slot="prefix" type="button">prefix</lion-button>
|
<lion-button slot="prefix" type="button">prefix</lion-button>
|
||||||
<lion-button slot="suffix" type="button">sufix</lion-button>
|
<lion-button slot="suffix" type="button">suffix</lion-button>
|
||||||
</lion-input>
|
</lion-input>
|
||||||
```
|
```
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue