@casinogate/ui 1.1.1 → 1.1.2

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.
@@ -1,4 +1,4 @@
1
- /*! tailwindcss v4.1.15 | MIT License | https://tailwindcss.com */
1
+ /*! tailwindcss v4.1.16 | MIT License | https://tailwindcss.com */
2
2
  @layer properties;
3
3
  @layer theme, base, components, utilities;
4
4
  @layer theme {
@@ -130,9 +130,7 @@
130
130
  ::placeholder {
131
131
  color: currentcolor;
132
132
  @supports (color: color-mix(in lab, red, red)) {
133
- & {
134
- color: color-mix(in oklab, currentcolor 50%, transparent);
135
- }
133
+ color: color-mix(in oklab, currentcolor 50%, transparent);
136
134
  }
137
135
  }
138
136
  }
@@ -564,9 +562,7 @@
564
562
  .cgui\:bg-neutral-40\/50 {
565
563
  background-color: var(--cg-ui-palette-neutral-40);
566
564
  @supports (color: color-mix(in lab, red, red)) {
567
- & {
568
- background-color: color-mix(in oklab, var(--cg-ui-palette-neutral-40) 50%, transparent);
569
- }
565
+ background-color: color-mix(in oklab, var(--cg-ui-palette-neutral-40) 50%, transparent);
570
566
  }
571
567
  }
572
568
  .cgui\:bg-primary-10 {
@@ -609,18 +605,14 @@
609
605
  .cgui\:from-neutral-40\/30 {
610
606
  --tw-gradient-from: var(--cg-ui-palette-neutral-40);
611
607
  @supports (color: color-mix(in lab, red, red)) {
612
- & {
613
- --tw-gradient-from: color-mix(in oklab, var(--cg-ui-palette-neutral-40) 30%, transparent);
614
- }
608
+ --tw-gradient-from: color-mix(in oklab, var(--cg-ui-palette-neutral-40) 30%, transparent);
615
609
  }
616
610
  --tw-gradient-stops: var(--tw-gradient-via-stops, var(--tw-gradient-position), var(--tw-gradient-from) var(--tw-gradient-from-position), var(--tw-gradient-to) var(--tw-gradient-to-position));
617
611
  }
618
612
  .cgui\:to-neutral-10\/0 {
619
613
  --tw-gradient-to: var(--cg-ui-palette-neutral-10);
620
614
  @supports (color: color-mix(in lab, red, red)) {
621
- & {
622
- --tw-gradient-to: color-mix(in oklab, var(--cg-ui-palette-neutral-10) 0%, transparent);
623
- }
615
+ --tw-gradient-to: color-mix(in oklab, var(--cg-ui-palette-neutral-10) 0%, transparent);
624
616
  }
625
617
  --tw-gradient-stops: var(--tw-gradient-via-stops, var(--tw-gradient-position), var(--tw-gradient-from) var(--tw-gradient-from-position), var(--tw-gradient-to) var(--tw-gradient-to-position));
626
618
  }
@@ -1,6 +1,7 @@
1
1
  import { SLOT_ATTR_NAME } from '../../../internal/constants/attrs.js';
2
2
  import { getDataActive, getDataDisabled } from '../../../internal/utils/attrs.js';
3
3
  import { Context } from 'runed';
4
+ import { untrack } from 'svelte';
4
5
  import { attachRef } from 'svelte-toolbelt';
5
6
  const SLOT_ATTR_VALUES = {
6
7
  root: 'field-root',
@@ -21,7 +22,9 @@ export class FieldRootState {
21
22
  this.attachment = attachRef(opts.ref);
22
23
  }
23
24
  setId(key, id) {
24
- this.#ids = { ...this.#ids, [key]: id };
25
+ untrack(() => {
26
+ this.#ids = { ...this.#ids, [key]: id };
27
+ });
25
28
  }
26
29
  getId(key) {
27
30
  return this.#ids[key];
@@ -47,7 +50,8 @@ export class FieldLabelState {
47
50
  this.opts = opts;
48
51
  this.root = root;
49
52
  this.attachment = attachRef(opts.ref);
50
- $effect.pre(() => {
53
+ this.root.setId('label', this.opts.id.current);
54
+ $effect(() => {
51
55
  this.root.setId('label', this.opts.id.current);
52
56
  });
53
57
  }
@@ -70,7 +74,8 @@ export class FieldErrorState {
70
74
  this.opts = opts;
71
75
  this.root = root;
72
76
  this.attachment = attachRef(opts.ref);
73
- $effect.pre(() => {
77
+ this.root.setId('error', this.opts.id.current);
78
+ $effect(() => {
74
79
  this.root.setId('error', this.opts.id.current);
75
80
  });
76
81
  }
@@ -91,7 +96,7 @@ export class FieldDescriptionState {
91
96
  this.opts = opts;
92
97
  this.root = root;
93
98
  this.attachment = attachRef(opts.ref);
94
- $effect.pre(() => {
99
+ $effect(() => {
95
100
  this.root.setId('description', this.opts.id.current);
96
101
  });
97
102
  }
@@ -110,7 +115,7 @@ export class FieldControlState {
110
115
  constructor(opts, root) {
111
116
  this.opts = opts;
112
117
  this.root = root;
113
- $effect.pre(() => {
118
+ $effect(() => {
114
119
  this.root.setId('control', this.opts.id.current);
115
120
  });
116
121
  }
@@ -17,7 +17,7 @@
17
17
  import FieldLabel from './components/field.label.svelte';
18
18
  import FieldRoot, { type FieldRootProps } from './components/field.root.svelte';
19
19
 
20
- let { label, error, description, ref = $bindable(null), children, ...restProps }: FieldProps = $props();
20
+ let { label, error, description, ref = $bindable(null), children: childrenSlot, ...restProps }: FieldProps = $props();
21
21
  </script>
22
22
 
23
23
  <FieldRoot bind:ref {...restProps}>
@@ -29,7 +29,7 @@
29
29
 
30
30
  <FieldControl>
31
31
  {#snippet children({ props })}
32
- {@render children?.({ props })}
32
+ {@render childrenSlot?.({ props })}
33
33
  {/snippet}
34
34
  </FieldControl>
35
35
 
@@ -1,6 +1,6 @@
1
1
  import { type InputPasswordProps } from './input.password.svelte';
2
2
  import { type InputProps } from './input.svelte';
3
3
  export declare const Input: import("svelte").Component<InputProps, {}, "ref"> & {
4
- InputPassword: import("svelte").Component<InputPasswordProps, {}, "ref" | "showPassword">;
4
+ Password: import("svelte").Component<InputPasswordProps, {}, "ref" | "showPassword">;
5
5
  };
6
6
  export type { InputPasswordProps, InputProps };
@@ -1,5 +1,5 @@
1
1
  import InputPassword, {} from './input.password.svelte';
2
2
  import Root, {} from './input.svelte';
3
3
  export const Input = Object.assign(Root, {
4
- InputPassword,
4
+ Password: InputPassword,
5
5
  });
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@casinogate/ui",
3
- "version": "1.1.1",
3
+ "version": "1.1.2",
4
4
  "files": [
5
5
  "dist",
6
6
  "!dist/**/*.test.*",