@infonomic/uikit 5.10.0 → 5.12.0

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.
@@ -4,7 +4,6 @@
4
4
 
5
5
  .chip,
6
6
  :global(.chip) {
7
- --chip-border: var(--surface-panel-border);
8
7
  --chip-font-size: 0.9rem;
9
8
  --chip-height: 34px;
10
9
  --chip-padding-y: 0.35rem;
@@ -12,7 +11,8 @@
12
11
  --chip-icon-size: 1rem;
13
12
 
14
13
  appearance: none;
15
- border: 1px solid var(--chip-border);
14
+ outline: 2px solid transparent;
15
+ outline-offset: 2px;
16
16
  display: inline-flex;
17
17
  align-items: center;
18
18
  gap: var(--gap-1);
@@ -2,14 +2,13 @@
2
2
 
3
3
  @layer infonomic-components {
4
4
  :is(.chip-AhhT7N, .chip) {
5
- --chip-border: var(--surface-panel-border);
6
5
  --chip-font-size: .9rem;
7
6
  --chip-height: 34px;
8
7
  --chip-padding-y: .35rem;
9
8
  --chip-padding-x: .4rem;
10
9
  --chip-icon-size: 1rem;
11
10
  appearance: none;
12
- border: 1px solid var(--chip-border);
11
+ outline-offset: 2px;
13
12
  align-items: center;
14
13
  gap: var(--gap-1);
15
14
  border-radius: var(--border-radius-sm);
@@ -20,6 +19,7 @@
20
19
  line-height: 1.1;
21
20
  font-size: var(--chip-font-size);
22
21
  transition: background-color var(--transition-normal), box-shadow var(--transition-normal);
22
+ outline: 2px solid #0000;
23
23
  text-decoration: none;
24
24
  display: inline-flex;
25
25
  }
@@ -9,7 +9,7 @@ import styles from './checkbox.module.css'
9
9
  interface Props extends HTMLAttributes<'input'> {
10
10
  id: string
11
11
  name: string
12
- label: string
12
+ label?: string
13
13
  variant?: Variant
14
14
  size?: Size
15
15
  intent?: Intent
@@ -81,9 +81,13 @@ const {
81
81
  </span>
82
82
  </label>
83
83
 
84
- <label for={id} class:list={[styles.label, labelClasses]}>
85
- {label}
86
- </label>
84
+ {
85
+ label && (
86
+ <label for={id} class:list={[styles.label, labelClasses]}>
87
+ {label}
88
+ </label>
89
+ )
90
+ }
87
91
  </div>
88
92
  {
89
93
  error ? (
@@ -3,7 +3,7 @@ import type { Intent, Size, Variant } from './@types/checkbox.js';
3
3
  export interface Props extends React.ButtonHTMLAttributes<HTMLButtonElement> {
4
4
  id: string;
5
5
  name: string;
6
- label: string;
6
+ label?: string;
7
7
  variant?: Variant;
8
8
  size?: Size;
9
9
  intent?: Intent;
@@ -1 +1 @@
1
- {"version":3,"file":"checkbox.d.ts","sourceRoot":"","sources":["../../../src/components/forms/checkbox.tsx"],"names":[],"mappings":"AAKA,OAAO,KAAK,KAAK,KAAK,MAAM,OAAO,CAAA;AAEnC,OAAO,KAAK,EAAE,MAAM,EAAE,IAAI,EAAE,OAAO,EAAE,MAAM,sBAAsB,CAAA;AAKjE,MAAM,WAAW,KAAM,SAAQ,KAAK,CAAC,oBAAoB,CAAC,iBAAiB,CAAC;IAC1E,EAAE,EAAE,MAAM,CAAA;IACV,IAAI,EAAE,MAAM,CAAA;IACZ,KAAK,EAAE,MAAM,CAAA;IACb,OAAO,CAAC,EAAE,OAAO,CAAA;IACjB,IAAI,CAAC,EAAE,IAAI,CAAA;IACX,MAAM,CAAC,EAAE,MAAM,CAAA;IACf,OAAO,CAAC,EAAE,OAAO,CAAA;IACjB,OAAO,CAAC,EAAE,OAAO,CAAA;IACjB,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,eAAe,CAAC,EAAE,MAAM,CAAA;IACxB,gBAAgB,CAAC,EAAE,MAAM,CAAA;IACzB,gBAAgB,CAAC,EAAE,MAAM,CAAA;IACzB,YAAY,CAAC,EAAE,MAAM,CAAA;IACrB,KAAK,CAAC,EAAE,OAAO,CAAA;IACf,QAAQ,CAAC,EAAE,MAAM,CAAA;IACjB,SAAS,CAAC,EAAE,MAAM,CAAA;IAClB,eAAe,CAAC,EAAE,CAAC,OAAO,EAAE,OAAO,GAAG,eAAe,KAAK,IAAI,CAAA;CAC/D;AAED,eAAO,MAA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K,CAAC,GAAG,CAAC,OA+Cb,CAAA"}
@@ -29,7 +29,7 @@ const checkbox_Checkbox = function({ ref, id, name, label, variant = 'outlined',
29
29
  })
30
30
  })
31
31
  }),
32
- /*#__PURE__*/ jsx(Label.Label, {
32
+ null != label && /*#__PURE__*/ jsx(Label.Label, {
33
33
  htmlFor: id,
34
34
  className: classnames(checkbox_module.label, labelClasses),
35
35
  children: label
package/package.json CHANGED
@@ -2,7 +2,7 @@
2
2
  "name": "@infonomic/uikit",
3
3
  "private": false,
4
4
  "license": "MIT",
5
- "version": "5.10.0",
5
+ "version": "5.12.0",
6
6
  "type": "module",
7
7
  "description": "Infonomic UI kit is a collection of reusable UI components and utilities for React and Astro.",
8
8
  "keywords": [
@@ -4,7 +4,6 @@
4
4
 
5
5
  .chip,
6
6
  :global(.chip) {
7
- --chip-border: var(--surface-panel-border);
8
7
  --chip-font-size: 0.9rem;
9
8
  --chip-height: 34px;
10
9
  --chip-padding-y: 0.35rem;
@@ -12,7 +11,8 @@
12
11
  --chip-icon-size: 1rem;
13
12
 
14
13
  appearance: none;
15
- border: 1px solid var(--chip-border);
14
+ outline: 2px solid transparent;
15
+ outline-offset: 2px;
16
16
  display: inline-flex;
17
17
  align-items: center;
18
18
  gap: var(--gap-1);
@@ -9,7 +9,7 @@ import styles from './checkbox.module.css'
9
9
  interface Props extends HTMLAttributes<'input'> {
10
10
  id: string
11
11
  name: string
12
- label: string
12
+ label?: string
13
13
  variant?: Variant
14
14
  size?: Size
15
15
  intent?: Intent
@@ -81,9 +81,13 @@ const {
81
81
  </span>
82
82
  </label>
83
83
 
84
- <label for={id} class:list={[styles.label, labelClasses]}>
85
- {label}
86
- </label>
84
+ {
85
+ label && (
86
+ <label for={id} class:list={[styles.label, labelClasses]}>
87
+ {label}
88
+ </label>
89
+ )
90
+ }
87
91
  </div>
88
92
  {
89
93
  error ? (
@@ -13,7 +13,7 @@ import { HelpText } from './help-text.js'
13
13
  export interface Props extends React.ButtonHTMLAttributes<HTMLButtonElement> {
14
14
  id: string
15
15
  name: string
16
- label: string
16
+ label?: string
17
17
  variant?: Variant
18
18
  size?: Size
19
19
  intent?: Intent
@@ -84,9 +84,11 @@ export const Checkbox = function Checkbox({
84
84
  </CheckboxPrimitive.Indicator>
85
85
  </CheckboxPrimitive.Root>
86
86
 
87
- <LabelPrimitive.Label htmlFor={id} className={cx(styles.label, labelClasses)}>
88
- {label}
89
- </LabelPrimitive.Label>
87
+ { label != null && (
88
+ <LabelPrimitive.Label htmlFor={id} className={cx(styles.label, labelClasses)}>
89
+ {label}
90
+ </LabelPrimitive.Label>
91
+ )}
90
92
  </div>
91
93
  {error ? (
92
94
  <ErrorText id={`error-for-${id}`} text={errorText ?? helpText} />