mirror of
https://github.com/carbon-design-system/carbon-components-svelte.git
synced 2025-09-20 20:33:02 +00:00
document static property on datepicker modal
This commit is contained in:
parent
af9b9a1d92
commit
49884b6421
1 changed files with 11 additions and 2 deletions
|
@ -3,10 +3,19 @@ components: ["DatePicker", "DatePickerInput", "DatePickerSkeleton"]
|
||||||
---
|
---
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
import { DatePicker, DatePickerSkeleton, DatePickerInput } from "carbon-components-svelte";
|
import { DatePicker, DatePickerSkeleton, DatePickerInput, InlineNotification, CodeSnippet } from "carbon-components-svelte";
|
||||||
import Preview from "../../components/Preview.svelte";
|
import Preview from "../../components/Preview.svelte";
|
||||||
|
|
||||||
|
const modalCodeSnippet = `<DatePicker datePickerType="single" flatpickrProps="{{ static: true }}">
|
||||||
|
<DatePickerInput />
|
||||||
|
</DatePicker>"/>`
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
|
<InlineNotification svx-ignore title="Note:" kind="info" hideCloseButton>
|
||||||
|
<span class="body-short-01">If you are using the DatePicker inside of a Modal you might need to add <code>static</code> to the <code>flatpickrProps</code> as shown below to correct the positioning.</span>
|
||||||
|
</InlineNotification>
|
||||||
|
<CodeSnippet type="multi" code={modalCodeSnippet}/>
|
||||||
|
|
||||||
### Default (simple)
|
### Default (simple)
|
||||||
|
|
||||||
<DatePicker>
|
<DatePicker>
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue