y200subcontrols 0.0.346 → 0.0.348
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -45,14 +45,14 @@ function closeAdvancedSearch() {
|
|
|
45
45
|
</h1>
|
|
46
46
|
<div class="ml-auto my-auto flex">
|
|
47
47
|
{#if showSearch}
|
|
48
|
-
<div class="relative
|
|
48
|
+
<div class="relative">
|
|
49
49
|
<input
|
|
50
50
|
disabled={!allowSearch || isBusy}
|
|
51
51
|
type="text"
|
|
52
52
|
class="border border-slate-300 rounded-md pl-2 pr-8 py-1.5
|
|
53
53
|
focus:border-indigo-500 focus:ring ring-indigo-500/30 focus:outline-none
|
|
54
54
|
md:min-w-[250px] lg:min-w-[300px]
|
|
55
|
-
rounded-r-none disabled:bg-slate-200 disabled:text-slate-400
|
|
55
|
+
rounded-r-none disabled:bg-slate-200 disabled:text-slate-400 h-full
|
|
56
56
|
"
|
|
57
57
|
placeholder={searchHint}
|
|
58
58
|
on:keyup={handleSearchRequested}
|
|
@@ -149,7 +149,6 @@ function closeAdvancedSearch() {
|
|
|
149
149
|
>
|
|
150
150
|
<svg
|
|
151
151
|
xmlns="http://www.w3.org/2000/svg"
|
|
152
|
-
|
|
153
152
|
fill="currentColor"
|
|
154
153
|
class="w-3 h-3 pointer-events-none inline-block {isAdvancedSearchOpen
|
|
155
154
|
? 'rotate-0'
|
|
@@ -174,6 +173,7 @@ function closeAdvancedSearch() {
|
|
|
174
173
|
hover:bg-blue-50 active:bg-blue-500 active:text-blue-50 outline-blue-600 h-full
|
|
175
174
|
disabled:text-slate-300"
|
|
176
175
|
on:click={() => (isMenuOpen = true)}
|
|
176
|
+
disabled={isBusy}
|
|
177
177
|
>
|
|
178
178
|
<i class="bi bi-three-dots"></i>
|
|
179
179
|
</button>
|
|
@@ -7,6 +7,7 @@ export let name = void 0;
|
|
|
7
7
|
export let placeholder = void 0;
|
|
8
8
|
export let validationText = void 0;
|
|
9
9
|
export let theme = "teal";
|
|
10
|
+
export let size = "lg";
|
|
10
11
|
export let input = void 0;
|
|
11
12
|
export let visible = true;
|
|
12
13
|
export let disabled = false;
|
|
@@ -70,11 +71,14 @@ onMount(() => {
|
|
|
70
71
|
{placeholder}
|
|
71
72
|
{name}
|
|
72
73
|
on:change
|
|
73
|
-
class="border peer block w-full
|
|
74
|
+
class="border peer block w-full rounded-md shadow-sm bg-white text-neutral-900
|
|
74
75
|
focus:outline-none focus:ring
|
|
75
76
|
placeholder:text-sm placeholder:font-thin
|
|
76
77
|
dark:bg-slate-900 dark:text-neutral-100 appearance-none
|
|
77
|
-
|
|
78
|
+
${size === 'sm' ? 'py-1 px-2 text-sm' : ''}
|
|
79
|
+
${size === 'md' ? 'py-1.5 px-2 text-base' : ''}
|
|
80
|
+
${size === 'lg' ? 'py-2 px-2 text-lg' : ''}
|
|
81
|
+
pr-10
|
|
78
82
|
{!isValid
|
|
79
83
|
? 'border-pink-600 dark:border-pink-500 focus:ring-pink-600/20 dark:focus:ring-pink-600/40'
|
|
80
84
|
: 'dark:border-slate-600 border-slate-300'}
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { SvelteComponent } from "svelte";
|
|
2
2
|
import type { ColorThemes } from './types.js';
|
|
3
|
+
import type { Size } from './types.js';
|
|
3
4
|
declare const __propDef: {
|
|
4
5
|
props: {
|
|
5
6
|
labelText?: string | undefined;
|
|
@@ -10,6 +11,7 @@ declare const __propDef: {
|
|
|
10
11
|
placeholder?: string | undefined;
|
|
11
12
|
validationText?: string | undefined;
|
|
12
13
|
theme?: ColorThemes;
|
|
14
|
+
size?: Size;
|
|
13
15
|
input?: HTMLInputElement | HTMLSelectElement | HTMLTextAreaElement | any | undefined;
|
|
14
16
|
visible?: boolean;
|
|
15
17
|
disabled?: boolean;
|
|
@@ -3,7 +3,7 @@ export type ColorThemes = 'red' | 'dark' | 'indigo' | 'teal' | 'blue' | 'purple'
|
|
|
3
3
|
export type PopupMenuItem = {
|
|
4
4
|
id: number;
|
|
5
5
|
content: string;
|
|
6
|
-
action: (param?: any | undefined) => {};
|
|
6
|
+
action: (param?: any | undefined) => {} | void;
|
|
7
7
|
disabled?: boolean;
|
|
8
8
|
};
|
|
9
9
|
export type KeyValue<TKey, T> = {
|