This commit is contained in:
2023-10-17 18:56:37 +03:00
parent d9736b29a4
commit 4b9e9cb4f6
13 changed files with 4 additions and 432 deletions
-20
View File
@@ -1,20 +0,0 @@
<script>
import { uniqueId } from "lodash";
export let label;
export let value;
let id = uniqueId();
</script>
<div class="form-check">
<input
value=""
class="form-check-input"
type="checkbox"
bind:checked={value}
id={id}
/>
<label class="form-check-label" for={id}>
{label}
</label>
</div>
-23
View File
@@ -1,23 +0,0 @@
<script>
import { uniqueId } from "lodash";
export let label;
export let value;
let id = uniqueId();
</script>
{#if label}
<div class="d-flex justify-content-between">
<label for={id} class="form-label">{label}</label>
</div>
{/if}
<div class="input-group ">
<div style="width:64px;">
<input
type="color"
class="form-control form-control-color"
bind:value
/>
</div>
<input type="text" {id} class="form-control" bind:value />
</div>
-38
View File
@@ -1,38 +0,0 @@
<script>
import { onMount } from "svelte";
import flatpickr from "flatpickr";
import "flatpickr/dist/flatpickr.css";
import "flatpickr/dist/themes/light.css";
import { uniqueId } from "lodash";
export let label;
export let value;
let pickerInput;
let id = uniqueId();
let flatpickrOptions = {
enableTime: false,
allowInput: true,
dateFormat: "Y-m-d",
defaultDate: value,
};
onMount(() => {
flatpickr(pickerInput, flatpickrOptions);
});
</script>
{#if label}
<div class="d-flex justify-content-between">
<label for={id} class="form-label">{label}</label>
</div>
{/if}
<input
type="text"
{id}
class="form-control"
bind:value
bind:this={pickerInput}
autocomplete="off"
/>