dce-reactkit 3.7.15 → 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.
@@ -9,6 +9,8 @@ type Props = {
9
9
  children: React.ReactNode;
10
10
  className?: string;
11
11
  wrapButtonsAndAddGaps?: boolean;
12
+ isAdminFeature?: boolean;
13
+ noMarginOnBottom?: boolean;
12
14
  };
13
15
  declare const ButtonInputGroup: React.FC<Props>;
14
16
  export default ButtonInputGroup;
@@ -13,6 +13,7 @@ type Props = {
13
13
  */
14
14
  onToggle: (isOn: boolean) => void;
15
15
  id?: string;
16
+ className?: string;
16
17
  description: string;
17
18
  backgroundVariantWhenOn?: Variant;
18
19
  };
package/dist/esm/index.js CHANGED
@@ -1543,21 +1543,21 @@ const ButtonInputGroup = (props) => {
1543
1543
  /*------------------------------------------------------------------------*/
1544
1544
  /* -------------- Props ------------- */
1545
1545
  // Destructure all props
1546
- const { label, minLabelWidth, children, className, wrapButtonsAndAddGaps, } = props;
1546
+ const { label, minLabelWidth, children, className, wrapButtonsAndAddGaps, isAdminFeature, noMarginOnBottom, } = props;
1547
1547
  /*------------------------------------------------------------------------*/
1548
1548
  /* ------------------------------- Render ------------------------------- */
1549
1549
  /*------------------------------------------------------------------------*/
1550
1550
  /*----------------------------------------*/
1551
1551
  /* --------------- Main UI -------------- */
1552
1552
  /*----------------------------------------*/
1553
- return (React__default.createElement("div", { className: `input-group ${className !== null && className !== void 0 ? className : ''}` },
1553
+ return (React__default.createElement("div", { className: `input-group ${className !== null && className !== void 0 ? className : ''} ${noMarginOnBottom ? '' : 'mb-2'}` },
1554
1554
  React__default.createElement("div", { className: "input-group-prepend d-flex w-100" },
1555
- React__default.createElement("span", { className: "input-group-text", style: {
1555
+ React__default.createElement("span", { className: `input-group-text ${isAdminFeature ? 'border border-success progress-bar-striped bg-success text-white fw-bold' : ''}`, style: {
1556
1556
  minWidth: (minLabelWidth !== null && minLabelWidth !== void 0 ? minLabelWidth : undefined),
1557
1557
  borderTopRightRadius: 0,
1558
1558
  borderBottomRightRadius: 0,
1559
1559
  } }, label),
1560
- React__default.createElement("span", { className: "input-group-text flex-grow-1 rounded-right d-flex flex-wrap", style: {
1560
+ React__default.createElement("span", { className: `input-group-text flex-grow-1 ${isAdminFeature ? 'border-success ' : ''}rounded-right d-flex flex-wrap`, style: {
1561
1561
  backgroundColor: 'white',
1562
1562
  borderTopLeftRadius: 0,
1563
1563
  borderBottomLeftRadius: 0,
@@ -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: {