odaptos_design_system 2.0.211 → 2.0.212

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.
@@ -28,6 +28,7 @@ interface InputProps {
28
28
  min?: number | null;
29
29
  max?: number | null;
30
30
  inputProps?: any;
31
+ isInteger?: boolean;
31
32
  }
32
33
  /** Figma link : https://www.figma.com/file/fjnhhbL12HvKccPmJchVnr/Atomic-Library?type=design&node-id=738-5899&mode=dev */
33
34
  export declare const NumberField: (props: InputProps) => React.JSX.Element;
@@ -94,8 +94,8 @@ const Avatar = ({
94
94
  }));
95
95
  };
96
96
 
97
- var css_248z$1 = ".Badge-modules_badge__Gj8cZ{align-items:center;border-radius:62.4375rem;display:flex;gap:.5rem;justify-content:center;max-width:10rem;padding:0 .75rem;width:-moz-fit-content;width:fit-content}.Badge-modules_badge__Gj8cZ p{white-space:nowrap}.Badge-modules_badge_idle__-do4O{background:var(--Color-Neutral-Clear-Shades-150,#eee)}.Badge-modules_badge_idle__-do4O svg{stroke:#64666a!important;fill:#64666a!important}.Badge-modules_badge_info__qlqva{background:var(--color-primary-100,#e5f1ff)}.Badge-modules_badge_info__qlqva svg{stroke:#004799!important;fill:#004799!important}.Badge-modules_badge_violet__2Sbtc{background:var(--Color-Extended-Purple-100,#e9d3fd)}.Badge-modules_badge_violet__2Sbtc svg{stroke:#5c1994!important;fill:#5c1994!important}.Badge-modules_badge_light__Sqifq{background:var(--Color-Neutral-Clear-Shades-150,#eee)}.Badge-modules_badge_light__Sqifq svg{stroke:#32353a!important;fill:#32353a!important}.Badge-modules_badge_success__RHeGJ{background:var(--color-extended-green-100,#e8f5ea)}.Badge-modules_badge_success__RHeGJ svg{stroke:#3c743d!important;fill:#3c743d!important}.Badge-modules_badge_warning__lr6Dd{background:var(--color-extended-yellow-100,#fff3d6)}.Badge-modules_badge_warning__lr6Dd svg{stroke:#6e4f00!important;fill:#6e4f00!important}.Badge-modules_badge_critical__8eo56{background:var(--color-extended-red-100,#fddbdb)}.Badge-modules_badge_critical__8eo56 svg{stroke:#98312e!important;fill:#98312e!important}.Badge-modules_badge_alt__oWM6X{background:var(--Color-Extended-Purple-100,#e9d3fd)}.Badge-modules_badge_alt__oWM6X svg{stroke:#5c1994!important;fill:#5c1994!important}.Badge-modules_badge_sm__HMjnW{align-items:center;gap:.25rem;height:1.25rem;justify-content:center;padding:0 .75rem}.Badge-modules_badge_sm__HMjnW svg{height:.75rem;width:.75rem}.Badge-modules_badge_lg__IYXgd{align-items:center;gap:.5rem;height:2.25rem;justify-content:center;padding:0 .75rem}.Badge-modules_badge_lg__IYXgd svg{height:1rem;width:1rem}.Badge-modules_badge_base__h-9E6{align-items:center;gap:.5rem;height:1.75rem;justify-content:center;padding:0 .75rem}.Badge-modules_badge_base__h-9E6 svg{height:1rem;width:1rem}";
98
- var styles$1 = {"badge":"Badge-modules_badge__Gj8cZ","badge_idle":"Badge-modules_badge_idle__-do4O","badge_info":"Badge-modules_badge_info__qlqva","badge_violet":"Badge-modules_badge_violet__2Sbtc","badge_light":"Badge-modules_badge_light__Sqifq","badge_success":"Badge-modules_badge_success__RHeGJ","badge_warning":"Badge-modules_badge_warning__lr6Dd","badge_critical":"Badge-modules_badge_critical__8eo56","badge_alt":"Badge-modules_badge_alt__oWM6X","badge_sm":"Badge-modules_badge_sm__HMjnW","badge_lg":"Badge-modules_badge_lg__IYXgd","badge_base":"Badge-modules_badge_base__h-9E6"};
97
+ var css_248z$1 = ".Badge-modules_badge__Gj8cZ{align-items:center;border-radius:62.4375rem;display:flex;gap:.5rem;justify-content:center;max-width:10rem;padding:0 .75rem;width:-moz-fit-content;width:fit-content}.Badge-modules_badge__Gj8cZ p{white-space:nowrap}.Badge-modules_interactiveIcon__njnoy{border-radius:50%;cursor:pointer;margin:-3px;padding:3px;transition:background-color .2s ease}.Badge-modules_interactiveIcon__njnoy:hover{background-color:rgba(0,0,0,.1)}.Badge-modules_badge_idle__-do4O{background:var(--Color-Neutral-Clear-Shades-150,#eee)}.Badge-modules_badge_idle__-do4O svg{stroke:#64666a!important;fill:#64666a!important}.Badge-modules_badge_info__qlqva{background:var(--color-primary-100,#e5f1ff)}.Badge-modules_badge_info__qlqva svg{stroke:#004799!important;fill:#004799!important}.Badge-modules_badge_violet__2Sbtc{background:var(--Color-Extended-Purple-100,#e9d3fd)}.Badge-modules_badge_violet__2Sbtc svg{stroke:#5c1994!important;fill:#5c1994!important}.Badge-modules_badge_light__Sqifq{background:var(--Color-Neutral-Clear-Shades-150,#eee)}.Badge-modules_badge_light__Sqifq svg{stroke:#32353a!important;fill:#32353a!important}.Badge-modules_badge_success__RHeGJ{background:var(--color-extended-green-100,#e8f5ea)}.Badge-modules_badge_success__RHeGJ svg{stroke:#3c743d!important;fill:#3c743d!important}.Badge-modules_badge_warning__lr6Dd{background:var(--color-extended-yellow-100,#fff3d6)}.Badge-modules_badge_warning__lr6Dd svg{stroke:#6e4f00!important;fill:#6e4f00!important}.Badge-modules_badge_critical__8eo56{background:var(--color-extended-red-100,#fddbdb)}.Badge-modules_badge_critical__8eo56 svg{stroke:#98312e!important;fill:#98312e!important}.Badge-modules_badge_alt__oWM6X{background:var(--Color-Extended-Purple-100,#e9d3fd)}.Badge-modules_badge_alt__oWM6X svg{stroke:#5c1994!important;fill:#5c1994!important}.Badge-modules_badge_sm__HMjnW{align-items:center;gap:.25rem;height:1.25rem;justify-content:center;padding:0 .75rem}.Badge-modules_badge_sm__HMjnW svg{height:.75rem;width:.75rem}.Badge-modules_badge_lg__IYXgd{align-items:center;gap:.5rem;height:2.25rem;justify-content:center;padding:0 .75rem}.Badge-modules_badge_lg__IYXgd svg{height:1rem;width:1rem}.Badge-modules_badge_base__h-9E6{align-items:center;gap:.5rem;height:1.75rem;justify-content:center;padding:0 .75rem}.Badge-modules_badge_base__h-9E6 svg{height:1rem;width:1rem}";
98
+ var styles$1 = {"badge":"Badge-modules_badge__Gj8cZ","interactiveIcon":"Badge-modules_interactiveIcon__njnoy","badge_idle":"Badge-modules_badge_idle__-do4O","badge_info":"Badge-modules_badge_info__qlqva","badge_violet":"Badge-modules_badge_violet__2Sbtc","badge_light":"Badge-modules_badge_light__Sqifq","badge_success":"Badge-modules_badge_success__RHeGJ","badge_warning":"Badge-modules_badge_warning__lr6Dd","badge_critical":"Badge-modules_badge_critical__8eo56","badge_alt":"Badge-modules_badge_alt__oWM6X","badge_sm":"Badge-modules_badge_sm__HMjnW","badge_lg":"Badge-modules_badge_lg__IYXgd","badge_base":"Badge-modules_badge_base__h-9E6"};
99
99
  styleInject(css_248z$1);
100
100
 
101
101
  colord.extend([mixPlugin]);
@@ -186,7 +186,8 @@ const Badge = ({
186
186
  style: {
187
187
  fill: getTextColor(),
188
188
  stroke: getTextColor()
189
- }
189
+ },
190
+ className: `${canBeRemoved && styles$1.interactiveIcon}`
190
191
  }));
191
192
  };
192
193
 
@@ -52204,9 +52205,6 @@ const MultiSelect = ({
52204
52205
  canBeRemoved: true,
52205
52206
  iconRight: /*#__PURE__*/React__default.createElement(RemoveCircledIcon, {
52206
52207
  fill: colors.neutral_700,
52207
- style: {
52208
- cursor: 'pointer !important'
52209
- },
52210
52208
  onClick: () => {
52211
52209
  if (!disabled) deleteOption(option);
52212
52210
  }
@@ -52489,9 +52487,6 @@ const MultiSelectWithCategories = ({
52489
52487
  canBeRemoved: true,
52490
52488
  iconRight: /*#__PURE__*/React__default.createElement(RemoveCircledIcon, {
52491
52489
  fill: colors.neutral_700,
52492
- style: {
52493
- cursor: 'pointer !important'
52494
- },
52495
52490
  onClick: () => {
52496
52491
  if (!disabled) deleteOption(option);
52497
52492
  }
@@ -52766,9 +52761,6 @@ const MultiSelectWithoutFilter = ({
52766
52761
  canBeRemoved: true,
52767
52762
  iconRight: /*#__PURE__*/React__default.createElement(RemoveCircledIcon, {
52768
52763
  fill: colors.neutral_700,
52769
- style: {
52770
- cursor: 'pointer !important'
52771
- },
52772
52764
  onClick: () => {
52773
52765
  if (!disabled) deleteOption(option);
52774
52766
  }
@@ -52938,7 +52930,8 @@ const NumberField = props => {
52938
52930
  errorText,
52939
52931
  inputProps,
52940
52932
  max,
52941
- min
52933
+ min,
52934
+ isInteger = true
52942
52935
  } = props;
52943
52936
  const endAdornment = rightIcon ? /*#__PURE__*/React__default.createElement(material.InputAdornment, {
52944
52937
  position: "end"
@@ -52989,7 +52982,7 @@ const NumberField = props => {
52989
52982
  inputProps: inputProps,
52990
52983
  variant: variant,
52991
52984
  onChange: e => {
52992
- var value = parseInt(e.target.value, 10);
52985
+ var value = isInteger ? parseInt(e.target.value.replace(/[^\d]/g, ''), 10) : parseFloat(e.target.value);
52993
52986
  if (max && value > max) value = max;
52994
52987
  if (min && value < min) value = min;
52995
52988
  if (min === 0 && value < 0) value = 0;
@@ -53940,9 +53933,6 @@ const SingleSelectWithCategories = ({
53940
53933
  canBeRemoved: true,
53941
53934
  iconRight: /*#__PURE__*/React__default.createElement(RemoveCircledIcon, {
53942
53935
  fill: colors.neutral_700,
53943
- style: {
53944
- cursor: 'pointer !important'
53945
- },
53946
53936
  onClick: () => {
53947
53937
  if (!disabled) deleteOption(option);
53948
53938
  }