dce-reactkit 3.7.16 → 3.7.17
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/cjs/index.js +2 -2
- package/dist/cjs/index.js.map +1 -1
- package/dist/cjs/types/components/ToggleSwitch.d.ts +1 -0
- package/dist/esm/index.js +2 -2
- package/dist/esm/index.js.map +1 -1
- package/dist/esm/types/components/ToggleSwitch.d.ts +1 -0
- package/dist/index.d.ts +1 -0
- package/package.json +1 -1
- package/src/components/ToggleSwitch.tsx +4 -1
package/dist/esm/index.js
CHANGED
|
@@ -12879,7 +12879,7 @@ const ToggleSwitch = (props) => {
|
|
|
12879
12879
|
/*------------------------------------------------------------------------*/
|
|
12880
12880
|
/* -------------- Props ------------- */
|
|
12881
12881
|
// Destructure all props
|
|
12882
|
-
const { isOn, onToggle, id, description, backgroundVariantWhenOn = Variant$1.Info, } = props;
|
|
12882
|
+
const { isOn, onToggle, id, className, description, backgroundVariantWhenOn = Variant$1.Info, } = props;
|
|
12883
12883
|
/*------------------------------------------------------------------------*/
|
|
12884
12884
|
/* ------------------------------- Render ------------------------------- */
|
|
12885
12885
|
/*------------------------------------------------------------------------*/
|
|
@@ -12889,7 +12889,7 @@ const ToggleSwitch = (props) => {
|
|
|
12889
12889
|
const backgroundVariant = (isOn
|
|
12890
12890
|
? backgroundVariantWhenOn
|
|
12891
12891
|
: 'secondary');
|
|
12892
|
-
return (React__default.createElement("button", { id: id, "aria-label": `If on, ${description}. Currently ${isOn ? 'on' : 'off'}. Click to turn ${isOn ? 'off' : 'on'}.`, className: `alert alert-${backgroundVariant} bg-${backgroundVariant} mb-0 rounded-pill d-inline-block pt-0 pb-0 px-3`, onClick: () => {
|
|
12892
|
+
return (React__default.createElement("button", { id: id, "aria-label": `If on, ${description}. Currently ${isOn ? 'on' : 'off'}. Click to turn ${isOn ? 'off' : 'on'}.`, className: `alert alert-${backgroundVariant} bg-${backgroundVariant} mb-0 rounded-pill d-inline-block pt-0 pb-0 px-3 ${className !== null && className !== void 0 ? className : ''}`, onClick: () => {
|
|
12893
12893
|
onToggle(!isOn);
|
|
12894
12894
|
}, type: "button" },
|
|
12895
12895
|
React__default.createElement(FontAwesomeIcon, { icon: faCircle, className: "text-light", style: {
|