@narmi/design_system 4.41.1 → 4.42.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.
- package/dist/index.js +1 -1
- package/dist/index.js.map +1 -1
- package/dist/style.css +3 -3
- package/dist/style.css.map +1 -1
- package/dist/tokens/css/rgbColors.css +1 -1
- package/dist/tokens/css/tokens.css +1 -1
- package/dist/tokens/js/colors.js +1 -1
- package/dist/tokens/js/manifest.js +1 -1
- package/dist/tokens/js/reactNativeWeb.js +1 -1
- package/dist/types/Radio/index.d.ts +6 -2
- package/dist/types/Radio/index.d.ts.map +1 -1
- package/dist/types/RadioButtons/index.d.ts +4 -1
- package/dist/types/RadioButtons/index.d.ts.map +1 -1
- package/package.json +1 -1
package/dist/tokens/js/colors.js
CHANGED
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import React from "react";
|
|
2
|
+
export type RadioKind = "normal" | "card" | "input-card" | "checkmark";
|
|
2
3
|
interface RadioProps {
|
|
3
4
|
/** The `name` attribute for radio input. Use this to group radio sets. */
|
|
4
5
|
name: string;
|
|
@@ -10,7 +11,8 @@ interface RadioProps {
|
|
|
10
11
|
* Optional callback when the Radio is checked by a user.
|
|
11
12
|
* Called with the `value` of the currently checked input
|
|
12
13
|
*/
|
|
13
|
-
onCheck
|
|
14
|
+
onCheck?: (value: string) => void;
|
|
15
|
+
kind?: RadioKind;
|
|
14
16
|
/**
|
|
15
17
|
* Optional prop to set the Radio to checked, making the Radio fully controlled.
|
|
16
18
|
* When fully controlled track the checked state by value in the parent component.
|
|
@@ -21,10 +23,12 @@ interface RadioProps {
|
|
|
21
23
|
isDisabled?: boolean;
|
|
22
24
|
/** Error text */
|
|
23
25
|
error?: string;
|
|
26
|
+
/** Applies error style without a message */
|
|
27
|
+
hasError?: boolean;
|
|
24
28
|
}
|
|
25
29
|
/**
|
|
26
30
|
* Single radio input that takes arbitrary JSX children as a label.
|
|
27
31
|
*/
|
|
28
|
-
declare const Radio: ({ name, value, isDisabled, onCheck, checked, children, error, }: RadioProps) => import("react/jsx-runtime").JSX.Element;
|
|
32
|
+
declare const Radio: ({ name, value, isDisabled, onCheck, checked, children, error, hasError, kind, }: RadioProps) => import("react/jsx-runtime").JSX.Element;
|
|
29
33
|
export default Radio;
|
|
30
34
|
//# sourceMappingURL=index.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/Radio/index.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/Radio/index.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAO1B,MAAM,MAAM,SAAS,GAAG,QAAQ,GAAG,MAAM,GAAG,YAAY,GAAG,WAAW,CAAC;AAEvE,UAAU,UAAU;IAClB,0EAA0E;IAC1E,IAAI,EAAE,MAAM,CAAC;IACb,+CAA+C;IAC/C,KAAK,EAAE,MAAM,CAAC;IACd,sCAAsC;IACtC,QAAQ,EAAE,KAAK,CAAC,SAAS,GAAG,MAAM,CAAC;IACnC;;;OAGG;IACH,OAAO,CAAC,EAAE,CAAC,KAAK,EAAE,MAAM,KAAK,IAAI,CAAC;IAClC,IAAI,CAAC,EAAE,SAAS,CAAC;IACjB;;;;OAIG;IACH,OAAO,CAAC,EAAE,OAAO,CAAC;IAClB,qCAAqC;IACrC,UAAU,CAAC,EAAE,OAAO,CAAC;IACrB,iBAAiB;IACjB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,4CAA4C;IAC5C,QAAQ,CAAC,EAAE,OAAO,CAAC;CACpB;AAED;;GAEG;AACH,QAAA,MAAM,KAAK,GAAI,iFAUZ,UAAU,4CA2DZ,CAAC;AAEF,eAAe,KAAK,CAAC"}
|
|
@@ -1,4 +1,7 @@
|
|
|
1
1
|
import React from "react";
|
|
2
|
+
import type { RadioKind } from "../Radio";
|
|
3
|
+
type RadioButtonsLayouts = "row" | "row-start";
|
|
4
|
+
type RadioButtonsKind = RadioKind | RadioButtonsLayouts;
|
|
2
5
|
interface RadioButtonsProps {
|
|
3
6
|
/** Map of label strings to input values
|
|
4
7
|
*
|
|
@@ -33,7 +36,7 @@ interface RadioButtonsProps {
|
|
|
33
36
|
*
|
|
34
37
|
* `checkmark` - uses a checkmark icon instead of a faux radio
|
|
35
38
|
*/
|
|
36
|
-
kind?:
|
|
39
|
+
kind?: RadioButtonsKind;
|
|
37
40
|
/**
|
|
38
41
|
* Error message. When passed, the `error` prop will
|
|
39
42
|
* render the radio group in an error state.
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/RadioButtons/index.tsx"],"names":[],"mappings":"AAAA,OAAO,KAA8B,MAAM,OAAO,CAAC;AAInD,UAAU,iBAAiB;IACzB;;;;;;;;;;SAUK;IACL,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,yBAAyB;IACzB,IAAI,EAAE,MAAM,CAAC;IACb,8DAA8D;IAC9D,YAAY,CAAC,EAAE,OAAO,CAAC;IACvB;;;;OAIG;IACH,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,+CAA+C;IAC/C,QAAQ,CAAC,EAAE,CAAC,CAAC,EAAE,KAAK,CAAC,WAAW,CAAC,gBAAgB,CAAC,KAAK,IAAI,CAAC;IAC5D;;;;;;;;OAQG;IACH,IAAI,CAAC,EAAE,
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/RadioButtons/index.tsx"],"names":[],"mappings":"AAAA,OAAO,KAA8B,MAAM,OAAO,CAAC;AAInD,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,UAAU,CAAC;AAE1C,KAAK,mBAAmB,GAAG,KAAK,GAAG,WAAW,CAAC;AAC/C,KAAK,gBAAgB,GAAG,SAAS,GAAG,mBAAmB,CAAC;AAExD,UAAU,iBAAiB;IACzB;;;;;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