@oliasoft-open-source/react-ui-library 4.0.0-beta-25 → 4.0.0-beta-27

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 CHANGED
@@ -11714,6 +11714,16 @@ Spinner$1.propTypes = {
11714
11714
  small: propTypes$1.exports.bool,
11715
11715
  tiny: propTypes$1.exports.bool
11716
11716
  };
11717
+ const ButtonTooltipWrapper = ({ children, tooltip: tooltip2 }) => {
11718
+ if (!tooltip2) {
11719
+ return children;
11720
+ }
11721
+ return /* @__PURE__ */ jsxRuntime.exports.jsx(Tooltip, {
11722
+ text: tooltip2,
11723
+ display: "inline-flex",
11724
+ children
11725
+ });
11726
+ };
11717
11727
  const Button$1 = ({
11718
11728
  active: active2,
11719
11729
  basic: basic2,
@@ -11731,6 +11741,7 @@ const Button$1 = ({
11731
11741
  small: small2,
11732
11742
  width,
11733
11743
  title: title2,
11744
+ tooltip: tooltip2,
11734
11745
  type,
11735
11746
  styles: styles2,
11736
11747
  error: error2,
@@ -11768,47 +11779,50 @@ const Button$1 = ({
11768
11779
  }
11769
11780
  return "";
11770
11781
  })();
11771
- return /* @__PURE__ */ jsxRuntime.exports.jsxs("button", {
11772
- type: type === "submit" ? "submit" : "button",
11773
- className: cx$2(
11774
- buttonStyles.button,
11775
- active2 ? buttonStyles.active : "",
11776
- basic2 ? buttonStyles.basic : "",
11777
- color2,
11778
- disabled2 || disabledContext ? buttonStyles.disabled : "",
11779
- (icon2 || loading) && !label2 ? buttonStyles.iconOnly : "",
11780
- inverted2 ? buttonStyles.inverted : "",
11781
- order2,
11782
- pill2 ? buttonStyles.pill : "",
11783
- round2 ? buttonStyles.round : "",
11784
- small2 ? buttonStyles.small : "",
11785
- error2 ? buttonStyles.error : warning2 ? buttonStyles.warning : "",
11786
- styles2
11787
- ),
11788
- disabled: disabled2 || disabledContext,
11789
- name: name2,
11790
- onClick,
11791
- ...title2 ? { title: title2 } : {},
11792
- style: { width },
11793
- "data-testid": testId,
11794
- children: [
11795
- icon2 && /* @__PURE__ */ jsxRuntime.exports.jsx("span", {
11796
- className: buttonStyles.icon,
11797
- children: /* @__PURE__ */ jsxRuntime.exports.jsx(Icon, {
11798
- icon: icon2
11799
- })
11800
- }),
11801
- loading && /* @__PURE__ */ jsxRuntime.exports.jsx("span", {
11802
- className: buttonStyles.icon,
11803
- children: /* @__PURE__ */ jsxRuntime.exports.jsx(Spinner$1, {
11804
- small: !small2,
11805
- tiny: small2,
11806
- dark: !colored2 && !basic2,
11807
- colored: basic2
11808
- })
11809
- }),
11810
- label2
11811
- ]
11782
+ return /* @__PURE__ */ jsxRuntime.exports.jsx(ButtonTooltipWrapper, {
11783
+ tooltip: tooltip2,
11784
+ children: /* @__PURE__ */ jsxRuntime.exports.jsxs("button", {
11785
+ type: type === "submit" ? "submit" : "button",
11786
+ className: cx$2(
11787
+ buttonStyles.button,
11788
+ active2 ? buttonStyles.active : "",
11789
+ basic2 ? buttonStyles.basic : "",
11790
+ color2,
11791
+ disabled2 || disabledContext ? buttonStyles.disabled : "",
11792
+ (icon2 || loading) && !label2 ? buttonStyles.iconOnly : "",
11793
+ inverted2 ? buttonStyles.inverted : "",
11794
+ order2,
11795
+ pill2 ? buttonStyles.pill : "",
11796
+ round2 ? buttonStyles.round : "",
11797
+ small2 ? buttonStyles.small : "",
11798
+ error2 ? buttonStyles.error : warning2 ? buttonStyles.warning : "",
11799
+ styles2
11800
+ ),
11801
+ disabled: disabled2 || disabledContext,
11802
+ name: name2,
11803
+ onClick,
11804
+ ...title2 ? { title: title2 } : {},
11805
+ style: { width },
11806
+ "data-testid": testId,
11807
+ children: [
11808
+ icon2 && /* @__PURE__ */ jsxRuntime.exports.jsx("span", {
11809
+ className: buttonStyles.icon,
11810
+ children: /* @__PURE__ */ jsxRuntime.exports.jsx(Icon, {
11811
+ icon: icon2
11812
+ })
11813
+ }),
11814
+ loading && /* @__PURE__ */ jsxRuntime.exports.jsx("span", {
11815
+ className: buttonStyles.icon,
11816
+ children: /* @__PURE__ */ jsxRuntime.exports.jsx(Spinner$1, {
11817
+ small: !small2,
11818
+ tiny: small2,
11819
+ dark: !colored2 && !basic2,
11820
+ colored: basic2
11821
+ })
11822
+ }),
11823
+ label2
11824
+ ]
11825
+ })
11812
11826
  });
11813
11827
  };
11814
11828
  Button$1.defaultProps = {
@@ -11833,6 +11847,7 @@ Button$1.defaultProps = {
11833
11847
  error: void 0,
11834
11848
  warning: void 0,
11835
11849
  testId: void 0,
11850
+ tooltip: void 0,
11836
11851
  inverted: false
11837
11852
  };
11838
11853
  Button$1.propTypes = {
@@ -11840,10 +11855,7 @@ Button$1.propTypes = {
11840
11855
  basic: propTypes$1.exports.bool,
11841
11856
  colored: propTypes$1.exports.oneOfType([propTypes$1.exports.bool, propTypes$1.exports.string]),
11842
11857
  disabled: propTypes$1.exports.bool,
11843
- icon: propTypes$1.exports.oneOfType([
11844
- propTypes$1.exports.node,
11845
- propTypes$1.exports.string
11846
- ]),
11858
+ icon: propTypes$1.exports.oneOfType([propTypes$1.exports.node, propTypes$1.exports.string]),
11847
11859
  groupOrder: propTypes$1.exports.string,
11848
11860
  label: propTypes$1.exports.oneOfType([propTypes$1.exports.node, propTypes$1.exports.string]),
11849
11861
  title: propTypes$1.exports.string,
@@ -11857,6 +11869,7 @@ Button$1.propTypes = {
11857
11869
  width: propTypes$1.exports.oneOfType([propTypes$1.exports.string, propTypes$1.exports.number]),
11858
11870
  error: propTypes$1.exports.string,
11859
11871
  warning: propTypes$1.exports.string,
11872
+ tooltip: propTypes$1.exports.oneOfType([propTypes$1.exports.node, propTypes$1.exports.string]),
11860
11873
  testId: propTypes$1.exports.string,
11861
11874
  pill: propTypes$1.exports.bool,
11862
11875
  inverted: propTypes$1.exports.bool
@@ -12042,6 +12055,7 @@ const actionShape = propTypes$1.exports.shape({
12042
12055
  disabled: propTypes$1.exports.bool,
12043
12056
  primary: propTypes$1.exports.bool,
12044
12057
  hidden: propTypes$1.exports.bool,
12058
+ tooltip: propTypes$1.exports.oneOfType([propTypes$1.exports.node, propTypes$1.exports.string]),
12045
12059
  testId: propTypes$1.exports.string
12046
12060
  });
12047
12061
  const subActionShape = propTypes$1.exports.shape({
@@ -12378,14 +12392,15 @@ const styles$J = {
12378
12392
  active: active$6
12379
12393
  };
12380
12394
  const SubmenuActions = (props) => {
12381
- const { actions: actions2, subMenuIcon, primary: primary2, testId } = props;
12395
+ const { actions: actions2, subMenuIcon, primary: primary2, testId, tooltip: tooltip2 } = props;
12382
12396
  const menuButton = /* @__PURE__ */ jsxRuntime.exports.jsx(Button$1, {
12383
12397
  colored: primary2 ? true : "muted",
12384
12398
  basic: !primary2,
12385
12399
  round: true,
12386
12400
  small: true,
12387
12401
  icon: subMenuIcon != null ? subMenuIcon : "menu",
12388
- testId
12402
+ testId,
12403
+ tooltip: tooltip2
12389
12404
  });
12390
12405
  if (actions2.length) {
12391
12406
  const subMenu = {
@@ -12433,7 +12448,8 @@ const Actions = (props) => {
12433
12448
  primary: action2.primary,
12434
12449
  subMenuIcon: action2.icon,
12435
12450
  testId: action2.testId,
12436
- right: right2
12451
+ right: right2,
12452
+ tooltip: action2.tooltip
12437
12453
  }, index2);
12438
12454
  } else {
12439
12455
  return /* @__PURE__ */ jsxRuntime.exports.jsx(Button$1, {
@@ -12454,7 +12470,8 @@ const Actions = (props) => {
12454
12470
  action2.onClick(evt);
12455
12471
  }
12456
12472
  },
12457
- testId: action2.testId
12473
+ testId: action2.testId,
12474
+ tooltip: action2.tooltip
12458
12475
  }, index2);
12459
12476
  }
12460
12477
  }
@@ -17138,17 +17155,17 @@ Label$2.propTypes = {
17138
17155
  }),
17139
17156
  labelLeft: propTypes$1.exports.bool
17140
17157
  };
17141
- const field = "_field_2ll8c_1";
17142
- const labelLeft = "_labelLeft_2ll8c_5";
17143
- const fieldInput = "_fieldInput_2ll8c_9";
17144
- const formRow$1 = "_formRow_2ll8c_12";
17145
- const button$2 = "_button_2ll8c_22";
17158
+ const field = "_field_1byxq_1";
17159
+ const labelLeft = "_labelLeft_1byxq_5";
17160
+ const fieldInput = "_fieldInput_1byxq_9";
17161
+ const formRow$1 = "_formRow_1byxq_12";
17162
+ const button$2 = "_button_1byxq_22";
17146
17163
  const styles$v = {
17147
17164
  field,
17148
17165
  labelLeft,
17149
17166
  fieldInput,
17150
17167
  formRow: formRow$1,
17151
- "form-row": "_form-row_2ll8c_13",
17168
+ "form-row": "_form-row_1byxq_13",
17152
17169
  button: button$2
17153
17170
  };
17154
17171
  const Field = ({
@@ -59610,36 +59627,35 @@ Footer.propTypes = {
59610
59627
  pagination: paginationShape,
59611
59628
  content: propTypes$1.exports.object
59612
59629
  };
59613
- const inputInTable$1 = "_inputInTable_hyzeo_1";
59614
- const inputHover$1 = "_inputHover_hyzeo_13";
59615
- const inputFocus$1 = "_inputFocus_hyzeo_18";
59616
- const inputError$1 = "_inputError_hyzeo_25";
59617
- const inputWarning$1 = "_inputWarning_hyzeo_26";
59618
- const inputDisabled$1 = "_inputDisabled_hyzeo_61";
59619
- const hideScrollbars$1 = "_hideScrollbars_hyzeo_67";
59620
- const cell = "_cell_hyzeo_77";
59621
- const disabledLink = "_disabledLink_hyzeo_87";
59622
- const inputWrapper = "_inputWrapper_hyzeo_91";
59623
- const breakWord = "_breakWord_hyzeo_106";
59624
- const inputCell = "_inputCell_hyzeo_109";
59625
- const sliderCell = "_sliderCell_hyzeo_112";
59626
- const staticCell = "_staticCell_hyzeo_116";
59627
- const staticCellContent = "_staticCellContent_hyzeo_119";
59628
- const error$1 = "_error_hyzeo_132";
59629
- const warning$2 = "_warning_hyzeo_133";
59630
- const unit = "_unit_hyzeo_142";
59631
- const sortingCell = "_sortingCell_hyzeo_145";
59632
- const sortingCellIcon = "_sortingCellIcon_hyzeo_156";
59633
- const icon = "_icon_hyzeo_167";
59634
- const checkBoxCell = "_checkBoxCell_hyzeo_171";
59635
- const iconCell = "_iconCell_hyzeo_175";
59636
- const iconWrapper = "_iconWrapper_hyzeo_180";
59637
- const actionsCell = "_actionsCell_hyzeo_184";
59638
- const rightAligned = "_rightAligned_hyzeo_192";
59639
- const centerAligned = "_centerAligned_hyzeo_198";
59640
- const leftAligned = "_leftAligned_hyzeo_204";
59641
- const popover = "_popover_hyzeo_207";
59642
- const disabledPointerEvents = "_disabledPointerEvents_hyzeo_210";
59630
+ const inputInTable$1 = "_inputInTable_sgjeo_1";
59631
+ const inputHover$1 = "_inputHover_sgjeo_13";
59632
+ const inputFocus$1 = "_inputFocus_sgjeo_18";
59633
+ const inputError$1 = "_inputError_sgjeo_25";
59634
+ const inputWarning$1 = "_inputWarning_sgjeo_26";
59635
+ const inputDisabled$1 = "_inputDisabled_sgjeo_61";
59636
+ const hideScrollbars$1 = "_hideScrollbars_sgjeo_67";
59637
+ const cell = "_cell_sgjeo_77";
59638
+ const disabledLink = "_disabledLink_sgjeo_87";
59639
+ const inputWrapper = "_inputWrapper_sgjeo_91";
59640
+ const breakWord = "_breakWord_sgjeo_106";
59641
+ const inputCell = "_inputCell_sgjeo_109";
59642
+ const sliderCell = "_sliderCell_sgjeo_112";
59643
+ const staticCell = "_staticCell_sgjeo_116";
59644
+ const staticCellContent = "_staticCellContent_sgjeo_119";
59645
+ const error$1 = "_error_sgjeo_132";
59646
+ const warning$2 = "_warning_sgjeo_133";
59647
+ const unit = "_unit_sgjeo_142";
59648
+ const sortingCell = "_sortingCell_sgjeo_145";
59649
+ const sortingCellIcon = "_sortingCellIcon_sgjeo_156";
59650
+ const icon = "_icon_sgjeo_167";
59651
+ const checkBoxCell = "_checkBoxCell_sgjeo_171";
59652
+ const iconCellWrapper = "_iconCellWrapper_sgjeo_175";
59653
+ const actionsCell = "_actionsCell_sgjeo_179";
59654
+ const rightAligned = "_rightAligned_sgjeo_187";
59655
+ const centerAligned = "_centerAligned_sgjeo_193";
59656
+ const leftAligned = "_leftAligned_sgjeo_199";
59657
+ const popover = "_popover_sgjeo_202";
59658
+ const disabledPointerEvents = "_disabledPointerEvents_sgjeo_205";
59643
59659
  const styles$7 = {
59644
59660
  inputInTable: inputInTable$1,
59645
59661
  inputHover: inputHover$1,
@@ -59663,8 +59679,7 @@ const styles$7 = {
59663
59679
  sortingCellIcon,
59664
59680
  icon,
59665
59681
  checkBoxCell,
59666
- iconCell,
59667
- iconWrapper,
59682
+ iconCellWrapper,
59668
59683
  actionsCell,
59669
59684
  rightAligned,
59670
59685
  centerAligned,
@@ -60018,10 +60033,17 @@ const CellLibraryIcon = (props) => {
60018
60033
  };
60019
60034
  const IconCell = (props) => {
60020
60035
  const { cell: cell2 } = props;
60036
+ const { tooltip: tooltip2, icon: icon2 } = cell2;
60021
60037
  return /* @__PURE__ */ jsxRuntime.exports.jsx("div", {
60022
- className: styles$7.iconWrapper,
60023
- children: /* @__PURE__ */ jsxRuntime.exports.jsx(Icon, {
60024
- icon: cell2.icon
60038
+ className: styles$7.iconCellWrapper,
60039
+ children: /* @__PURE__ */ jsxRuntime.exports.jsx(Tooltip, {
60040
+ text: tooltip2,
60041
+ enabled: tooltip2 && isStringNumberOrNode(tooltip2),
60042
+ display: "flex",
60043
+ placement: "top-center",
60044
+ children: /* @__PURE__ */ jsxRuntime.exports.jsx(Icon, {
60045
+ icon: icon2
60046
+ })
60025
60047
  })
60026
60048
  });
60027
60049
  };
@@ -60927,16 +60949,16 @@ Table.propTypes = {
60927
60949
  }).isRequired,
60928
60950
  onListReorder: propTypes$1.exports.func
60929
60951
  };
60930
- const tabs = "_tabs_bpi2q_1";
60931
- const padding = "_padding_bpi2q_7";
60932
- const margin = "_margin_bpi2q_11";
60933
- const contentPadding = "_contentPadding_bpi2q_14";
60934
- const item$1 = "_item_bpi2q_17";
60935
- const active$1 = "_active_bpi2q_38";
60936
- const hidden = "_hidden_bpi2q_57";
60937
- const disabled$1 = "_disabled_bpi2q_60";
60938
- const left$1 = "_left_bpi2q_64";
60939
- const right$1 = "_right_bpi2q_64";
60952
+ const tabs = "_tabs_eqy95_1";
60953
+ const padding = "_padding_eqy95_7";
60954
+ const margin = "_margin_eqy95_11";
60955
+ const contentPadding = "_contentPadding_eqy95_14";
60956
+ const item$1 = "_item_eqy95_17";
60957
+ const active$1 = "_active_eqy95_38";
60958
+ const hidden = "_hidden_eqy95_57";
60959
+ const disabled$1 = "_disabled_eqy95_60";
60960
+ const left$1 = "_left_eqy95_64";
60961
+ const right$1 = "_right_eqy95_64";
60940
60962
  const styles$5 = {
60941
60963
  tabs,
60942
60964
  padding,
@@ -62450,22 +62472,22 @@ Toggle.propTypes = {
62450
62472
  helpText: propTypes$1.exports.string,
62451
62473
  onClickHelp: propTypes$1.exports.func
62452
62474
  };
62453
- const topbar = "_topbar_uzfj5_8";
62454
- const fixed = "_fixed_uzfj5_17";
62455
- const appSwitcher = "_appSwitcher_uzfj5_25";
62456
- const title = "_title_uzfj5_49";
62457
- const logo = "_logo_uzfj5_65";
62458
- const label = "_label_uzfj5_68";
62459
- const brand = "_brand_uzfj5_73";
62460
- const version = "_version_uzfj5_78";
62461
- const left = "_left_uzfj5_85";
62462
- const right = "_right_uzfj5_86";
62463
- const item = "_item_uzfj5_100";
62464
- const link = "_link_uzfj5_101";
62465
- const button = "_button_uzfj5_113";
62466
- const menu = "_menu_uzfj5_114";
62467
- const active = "_active_uzfj5_142";
62468
- const alert = "_alert_uzfj5_167";
62475
+ const topbar = "_topbar_ki10t_8";
62476
+ const fixed = "_fixed_ki10t_17";
62477
+ const appSwitcher = "_appSwitcher_ki10t_25";
62478
+ const title = "_title_ki10t_49";
62479
+ const logo = "_logo_ki10t_65";
62480
+ const label = "_label_ki10t_68";
62481
+ const brand = "_brand_ki10t_73";
62482
+ const version = "_version_ki10t_78";
62483
+ const left = "_left_ki10t_85";
62484
+ const right = "_right_ki10t_86";
62485
+ const item = "_item_ki10t_100";
62486
+ const link = "_link_ki10t_101";
62487
+ const button = "_button_ki10t_113";
62488
+ const menu = "_menu_ki10t_114";
62489
+ const active = "_active_ki10t_142";
62490
+ const alert = "_alert_ki10t_167";
62469
62491
  const styles$2 = {
62470
62492
  topbar,
62471
62493
  fixed,
@@ -74495,10 +74517,13 @@ const TreeItem = ({
74495
74517
  item: data
74496
74518
  }),
74497
74519
  /* @__PURE__ */ jsxRuntime.exports.jsx("div", {
74498
- className: listStyles.actions,
74499
- children: /* @__PURE__ */ jsxRuntime.exports.jsx(Actions, {
74500
- actions: actions2,
74501
- right: true
74520
+ className: listStyles.right,
74521
+ children: /* @__PURE__ */ jsxRuntime.exports.jsx("div", {
74522
+ className: listStyles.actions,
74523
+ children: /* @__PURE__ */ jsxRuntime.exports.jsx(Actions, {
74524
+ actions: actions2,
74525
+ right: true
74526
+ })
74502
74527
  })
74503
74528
  })
74504
74529
  ]