@cloudparker/moldex.js 0.0.36 → 0.0.38

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.
Files changed (22) hide show
  1. package/dist/views/core/input/components/color-field/color-field.svelte +1 -1
  2. package/dist/views/core/input/components/date-field/date-field.svelte +2 -2
  3. package/dist/views/core/input/components/date-field/date-field.svelte.d.ts +1 -1
  4. package/dist/views/core/input/components/datetime-field/datetime-field.svelte +2 -2
  5. package/dist/views/core/input/components/datetime-field/datetime-field.svelte.d.ts +1 -1
  6. package/dist/views/core/input/components/email-field/email-field.svelte +8 -2
  7. package/dist/views/core/input/components/email-field/email-field.svelte.d.ts +1 -1
  8. package/dist/views/core/input/components/file-field/file-field.svelte +2 -2
  9. package/dist/views/core/input/components/file-field/file-field.svelte.d.ts +2 -2
  10. package/dist/views/core/input/components/input-field/input-field.svelte +1 -1
  11. package/dist/views/core/input/components/number-field/number-field.svelte +2 -2
  12. package/dist/views/core/input/components/number-field/number-field.svelte.d.ts +1 -1
  13. package/dist/views/core/input/components/password-field/password-field.svelte +2 -0
  14. package/dist/views/core/input/components/password-field/password-field.svelte.d.ts +1 -1
  15. package/dist/views/core/input/components/range-field/range-field.svelte +1 -1
  16. package/dist/views/core/input/components/search-field/search-field.svelte +3 -2
  17. package/dist/views/core/input/components/search-field/search-field.svelte.d.ts +1 -1
  18. package/dist/views/core/input/components/text-field/text-field.svelte +1 -6
  19. package/dist/views/core/input/components/textarea-field/textarea-field.svelte +1 -0
  20. package/dist/views/core/input/components/time-field/time-field.svelte +2 -2
  21. package/dist/views/core/input/components/time-field/time-field.svelte.d.ts +1 -1
  22. package/package.json +1 -1
@@ -85,11 +85,11 @@
85
85
  <InputField
86
86
  {...props}
87
87
  type="text"
88
- bind:value
89
88
  bind:this={inputFieldRef}
90
89
  className="pr-8 {props?.className}"
91
90
  rightSnippet={colorButton}
92
91
  maxlength={9}
92
+ bind:value={value as string}
93
93
  />
94
94
 
95
95
  <input
@@ -1,7 +1,7 @@
1
1
  <script lang="ts">
2
2
  import InputField, { type InputFieldPropsType } from '../input-field/input-field.svelte';
3
3
 
4
- let props: InputFieldPropsType = $props();
4
+ let { value = $bindable(null), ...props }: InputFieldPropsType = $props();
5
5
 
6
6
  let inputFieldRef: InputField | null = $state(null);
7
7
 
@@ -10,4 +10,4 @@
10
10
  }
11
11
  </script>
12
12
 
13
- <InputField bind:this={inputFieldRef} {...props} type="date" />
13
+ <InputField bind:this={inputFieldRef} {...props} type="date" bind:value />
@@ -16,6 +16,6 @@ declare const DateField: $$__sveltets_2_IsomorphicComponent<InputFieldPropsType,
16
16
  [evt: string]: CustomEvent<any>;
17
17
  }, {}, {
18
18
  focus: () => void;
19
- }, "">;
19
+ }, "value">;
20
20
  type DateField = InstanceType<typeof DateField>;
21
21
  export default DateField;
@@ -1,7 +1,7 @@
1
1
  <script lang="ts">
2
2
  import InputField, { type InputFieldPropsType } from '../input-field/input-field.svelte';
3
3
 
4
- let props: InputFieldPropsType = $props();
4
+ let { value = $bindable(), ...props }: InputFieldPropsType = $props();
5
5
 
6
6
  let inputFieldRef: InputField | null = $state(null);
7
7
 
@@ -10,4 +10,4 @@
10
10
  }
11
11
  </script>
12
12
 
13
- <InputField bind:this={inputFieldRef} {...props} type="datetime-local" />
13
+ <InputField bind:this={inputFieldRef} {...props} type="datetime-local" bind:value />
@@ -16,6 +16,6 @@ declare const DatetimeField: $$__sveltets_2_IsomorphicComponent<InputFieldPropsT
16
16
  [evt: string]: CustomEvent<any>;
17
17
  }, {}, {
18
18
  focus: () => void;
19
- }, "">;
19
+ }, "value">;
20
20
  type DatetimeField = InstanceType<typeof DatetimeField>;
21
21
  export default DatetimeField;
@@ -1,7 +1,7 @@
1
1
  <script lang="ts">
2
2
  import InputField, { type InputFieldPropsType } from '../input-field/input-field.svelte';
3
3
 
4
- let props: InputFieldPropsType = $props();
4
+ let { value = $bindable(''), ...props }: InputFieldPropsType = $props();
5
5
  let inputFieldRef: InputField | null = $state(null);
6
6
 
7
7
  export function focus() {
@@ -9,4 +9,10 @@
9
9
  }
10
10
  </script>
11
11
 
12
- <InputField bind:this={inputFieldRef} {...props} type="email" maxlength={props?.maxlength || 80} />
12
+ <InputField
13
+ bind:this={inputFieldRef}
14
+ {...props}
15
+ type="email"
16
+ maxlength={props?.maxlength || 80}
17
+ bind:value
18
+ />
@@ -16,6 +16,6 @@ declare const EmailField: $$__sveltets_2_IsomorphicComponent<InputFieldPropsType
16
16
  [evt: string]: CustomEvent<any>;
17
17
  }, {}, {
18
18
  focus: () => void;
19
- }, "">;
19
+ }, "value">;
20
20
  type EmailField = InstanceType<typeof EmailField>;
21
21
  export default EmailField;
@@ -11,12 +11,12 @@
11
11
  className,
12
12
  accept = '',
13
13
  multiple = false,
14
- value,
14
+ value = $bindable(null),
15
15
  ...props
16
16
  }: InputFieldPropsType & {
17
17
  accept?: string;
18
18
  multiple?: boolean;
19
- value?: File | File[];
19
+ value?: File | File[] | null;
20
20
  } = $props();
21
21
 
22
22
  let btnRoundedClassName = $state('');
@@ -15,11 +15,11 @@ interface $$__sveltets_2_IsomorphicComponent<Props extends Record<string, any> =
15
15
  declare const FileField: $$__sveltets_2_IsomorphicComponent<InputFieldPropsType & {
16
16
  accept?: string;
17
17
  multiple?: boolean;
18
- value?: File | File[];
18
+ value?: File | File[] | null;
19
19
  }, {
20
20
  [evt: string]: CustomEvent<any>;
21
21
  }, {}, {
22
22
  focus: () => void;
23
- }, "">;
23
+ }, "value">;
24
24
  type FileField = InstanceType<typeof FileField>;
25
25
  export default FileField;
@@ -135,7 +135,7 @@
135
135
  size = 'md',
136
136
  step,
137
137
  type = 'text',
138
- value = $bindable('')
138
+ value = $bindable()
139
139
  }: InputFieldPropsType = $props();
140
140
 
141
141
  let inputRef: HTMLInputElement | HTMLTextAreaElement | HTMLButtonElement | null = $state(null);
@@ -1,7 +1,7 @@
1
1
  <script lang="ts">
2
2
  import InputField, { type InputFieldPropsType } from '../input-field/input-field.svelte';
3
3
 
4
- let props: InputFieldPropsType = $props();
4
+ let { value = $bindable(), ...props }: InputFieldPropsType = $props();
5
5
 
6
6
  let inputFieldRef: InputField | null = $state(null);
7
7
 
@@ -10,4 +10,4 @@
10
10
  }
11
11
  </script>
12
12
 
13
- <InputField bind:this={inputFieldRef} {...props} type="number" />
13
+ <InputField bind:this={inputFieldRef} {...props} type="number" bind:value />
@@ -16,6 +16,6 @@ declare const NumberField: $$__sveltets_2_IsomorphicComponent<InputFieldPropsTyp
16
16
  [evt: string]: CustomEvent<any>;
17
17
  }, {}, {
18
18
  focus: () => void;
19
- }, "">;
19
+ }, "value">;
20
20
  type NumberField = InstanceType<typeof NumberField>;
21
21
  export default NumberField;
@@ -10,6 +10,7 @@
10
10
  appearance,
11
11
  buttonClassName,
12
12
  iconClassName,
13
+ value = $bindable(),
13
14
  ...props
14
15
  }: InputFieldPropsType & {
15
16
  buttonClassName?: string;
@@ -80,4 +81,5 @@
80
81
  rightSnippet={showPasswordButton}
81
82
  {size}
82
83
  {appearance}
84
+ bind:value
83
85
  />
@@ -19,6 +19,6 @@ declare const PasswordField: $$__sveltets_2_IsomorphicComponent<InputFieldPropsT
19
19
  [evt: string]: CustomEvent<any>;
20
20
  }, {}, {
21
21
  focus: () => void;
22
- }, "">;
22
+ }, "value">;
23
23
  type PasswordField = InstanceType<typeof PasswordField>;
24
24
  export default PasswordField;
@@ -19,7 +19,7 @@
19
19
 
20
20
  let {
21
21
  id,
22
- value = $bindable(50),
22
+ value = $bindable(0),
23
23
  size = 'md',
24
24
  min = 0,
25
25
  max = 100,
@@ -7,10 +7,10 @@
7
7
  className,
8
8
  placeholder,
9
9
  iconClassName,
10
+ value=$bindable(''),
10
11
  onSearch,
11
12
  ...props
12
- }: InputFieldPropsType & { iconClassName?: string; onSearch?: (value: string) => void } =
13
- $props();
13
+ }: InputFieldPropsType & { iconClassName?: string; onSearch?: (value: string) => void } = $props();
14
14
 
15
15
  const debouncedSearch = debounce(search, 300);
16
16
  let lastQuery: string;
@@ -64,4 +64,5 @@
64
64
  className=" pl-12 {className}"
65
65
  {placeholder}
66
66
  oninput={handleInput}
67
+ bind:value
67
68
  />
@@ -19,6 +19,6 @@ declare const SearchField: $$__sveltets_2_IsomorphicComponent<InputFieldPropsTyp
19
19
  [evt: string]: CustomEvent<any>;
20
20
  }, {}, {
21
21
  focus: () => void;
22
- }, "">;
22
+ }, "value">;
23
23
  type SearchField = InstanceType<typeof SearchField>;
24
24
  export default SearchField;
@@ -1,14 +1,9 @@
1
1
  <script lang="ts">
2
2
  import InputField, {
3
3
  type InputFieldPropsType,
4
- type InputValueType
5
4
  } from '../input-field/input-field.svelte';
6
5
 
7
- let {
8
- maxlength,
9
- value = $bindable<InputValueType>(''),
10
- ...props
11
- }: InputFieldPropsType = $props();
6
+ let { maxlength, value = $bindable(''), ...props }: InputFieldPropsType = $props();
12
7
  let inputFieldRef: InputField | null = $state(null);
13
8
 
14
9
  export function focus() {
@@ -14,4 +14,5 @@
14
14
  {...props}
15
15
  type="textarea"
16
16
  maxlength={props?.maxlength || 300}
17
+ bind:value
17
18
  />
@@ -1,7 +1,7 @@
1
1
  <script lang="ts">
2
2
  import InputField, { type InputFieldPropsType } from '../input-field/input-field.svelte';
3
3
 
4
- let props: InputFieldPropsType = $props();
4
+ let { value = $bindable(), ...props }: InputFieldPropsType = $props();
5
5
  let inputFieldRef: InputField | null = $state(null);
6
6
 
7
7
  export function focus() {
@@ -9,4 +9,4 @@
9
9
  }
10
10
  </script>
11
11
 
12
- <InputField bind:this={inputFieldRef} {...props} type="time" />
12
+ <InputField bind:this={inputFieldRef} {...props} type="time" bind:value />
@@ -16,6 +16,6 @@ declare const TimeField: $$__sveltets_2_IsomorphicComponent<InputFieldPropsType,
16
16
  [evt: string]: CustomEvent<any>;
17
17
  }, {}, {
18
18
  focus: () => void;
19
- }, "">;
19
+ }, "value">;
20
20
  type TimeField = InstanceType<typeof TimeField>;
21
21
  export default TimeField;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@cloudparker/moldex.js",
3
- "version": "0.0.36",
3
+ "version": "0.0.38",
4
4
  "author": "cloudparker.com",
5
5
  "license": "MIT",
6
6
  "keywords": [