@tuspe/components 1.8.9 → 1.8.11

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.
@@ -9,16 +9,33 @@
9
9
  disabled?: boolean
10
10
  group?: boolean
11
11
  id?: string
12
+ noLineHeight?: boolean
12
13
  outerClass?: string
13
14
  required?: boolean
14
15
  value?: number | string
15
16
  }
16
17
 
17
- let {children, onchange, checked = $bindable(false), disabled, group = $bindable(), id, outerClass, required, value, ...props}: Props = $props()
18
- let classes = $state('checkbox')
18
+ let {
19
+ children,
20
+ onchange,
21
+ checked = $bindable(false),
22
+ disabled,
23
+ group = $bindable(),
24
+ id,
25
+ noLineHeight = false,
26
+ outerClass,
27
+ required,
28
+ value,
29
+ ...props
30
+ }: Props = $props()
31
+
32
+ let classes = $state('input-checkbox')
19
33
  if (outerClass) {
20
34
  classes += ` ${outerClass}`
21
35
  }
36
+ if (noLineHeight) {
37
+ classes += ' leading-none'
38
+ }
22
39
  </script>
23
40
 
24
41
  <label class={classes}>
@@ -56,6 +73,9 @@
56
73
  font-size: 1rem;
57
74
  gap: 1rem;
58
75
  grid-template-columns: 20px 1fr;
76
+ }
77
+
78
+ label:not(.leading-none) {
59
79
  line-height: 1.25;
60
80
  }
61
81
 
@@ -6,6 +6,7 @@ interface Props {
6
6
  disabled?: boolean;
7
7
  group?: boolean;
8
8
  id?: string;
9
+ noLineHeight?: boolean;
9
10
  outerClass?: string;
10
11
  required?: boolean;
11
12
  value?: number | string;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@tuspe/components",
3
- "version": "1.8.9",
3
+ "version": "1.8.11",
4
4
  "description": "A reusable SvelteKit component library for form elements, breadcrumbs, prices and images.",
5
5
  "keywords": [
6
6
  "svelteKit",