@bonprix-ds/react-checkbox 1.0.3 → 1.0.5
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.d.ts +2 -2
- package/dist/index.js.map +1 -1
- package/package.json +2 -2
package/dist/index.d.ts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { CheckboxBaseProps } from '@bonprix-ds/internal-components';
|
|
2
|
-
import {
|
|
2
|
+
import { default as default_2 } from 'react';
|
|
3
3
|
|
|
4
|
-
declare const Checkbox:
|
|
4
|
+
declare const Checkbox: (props: CheckboxProps) => default_2.JSX.Element;
|
|
5
5
|
export default Checkbox;
|
|
6
6
|
|
|
7
7
|
export declare type CheckboxProps = {
|
package/dist/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","names":[],"sources":["../src/Checkbox.tsx"],"sourcesContent":["\"use client\";\n\nimport { CheckboxBase, CheckboxBaseProps, InputHelperTextSection } from \"@bonprix-ds/internal-components\";\nimport React, {
|
|
1
|
+
{"version":3,"file":"index.js","names":[],"sources":["../src/Checkbox.tsx"],"sourcesContent":["\"use client\";\n\nimport { CheckboxBase, CheckboxBaseProps, InputHelperTextSection } from \"@bonprix-ds/internal-components\";\nimport React, { useId } from \"react\";\n\nexport type Props = {\n /** The helper text to be displayed below the checkbox. Should provide an additional description about the input to help fill out the form. */\n helperText?: string;\n /** If set to `true`, the checkbox will be marked as erroneous. */\n error?: boolean;\n /** Provides an error message as additional description to an erroneous checkbox. Will only be shown if `error` is true. */\n errorText?: string;\n} & CheckboxBaseProps;\n\nconst Checkbox = (props: Props) => {\n const helperTextId = useId();\n const errorTextId = useId();\n const { helperText = \"\", error = false, errorText = \"\", ...checkboxProps } = props;\n return (\n <div data-bpds=\"checkbox\">\n <CheckboxBase\n {...checkboxProps}\n error={error}\n helperText={helperText}\n errorText={errorText}\n errorTextId={errorTextId}\n helperTextId={helperTextId}\n />\n <InputHelperTextSection\n helperText={helperText}\n error={error}\n errorText={errorText}\n helperTextId={helperTextId}\n errorTextId={errorTextId}\n />\n </div>\n );\n};\n\nexport default Checkbox;\n"],"mappings":";;;;;AAcA,IAAM,KAAY,MAAiB;CACjC,IAAM,IAAe,EAAM,GACrB,IAAc,EAAM,GACpB,EAAE,gBAAa,IAAI,WAAQ,IAAO,eAAY,IAAI,GAAG,MAAkB;CAC7E,OACE,kBAAC,OAAD;EAAK,aAAU;EAAf,UAAA,CACE,kBAAC,GAAD;GACE,GAAI;GACG;GACK;GACD;GACE;GACC;EACf,CAAA,GACD,kBAAC,GAAD;GACc;GACL;GACI;GACG;GACD;EACd,CAAA,CACE;;AAET"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@bonprix-ds/react-checkbox",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.5",
|
|
4
4
|
"description": "Checkbox component, implemented in React, for the Bonprix Design System.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"publishConfig": {
|
|
@@ -29,7 +29,7 @@
|
|
|
29
29
|
"directory": "packages/react/checkbox"
|
|
30
30
|
},
|
|
31
31
|
"dependencies": {
|
|
32
|
-
"@bonprix-ds/internal-components": "0.1.
|
|
32
|
+
"@bonprix-ds/internal-components": "0.1.4",
|
|
33
33
|
"@bonprix-ds/utils": "0.2.0"
|
|
34
34
|
},
|
|
35
35
|
"peerDependencies": {
|