@spaced-out/ui-design-system 0.1.73 → 0.1.75

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/CHANGELOG.md CHANGED
@@ -2,6 +2,26 @@
2
2
 
3
3
  All notable changes to this project will be documented in this file. See [standard-version](https://github.com/conventional-changelog/standard-version) for commit guidelines.
4
4
 
5
+ ### [0.1.75](https://github.com/spaced-out/ui-design-system/compare/v0.1.74...v0.1.75) (2024-01-10)
6
+
7
+
8
+ ### Features
9
+
10
+ * new panel background, table inline edit fixes and breadcrumb example ([9339852](https://github.com/spaced-out/ui-design-system/commit/9339852c1c23814df1d28bfec0e31fb355d337b9))
11
+
12
+
13
+ ### Bug Fixes
14
+
15
+ * tablist example sizing fix ([138c023](https://github.com/spaced-out/ui-design-system/commit/138c023df80dfb81d4f4b6b38929e5b09d18798d))
16
+
17
+ ### [0.1.74](https://github.com/spaced-out/ui-design-system/compare/v0.1.73...v0.1.74) (2024-01-04)
18
+
19
+
20
+ ### Bug Fixes
21
+
22
+ * removed width of tablist container story ([caadaf6](https://github.com/spaced-out/ui-design-system/commit/caadaf69dfbc3c16598192719473d5b06cf8ae65))
23
+ * support window resize for tablist ([#156](https://github.com/spaced-out/ui-design-system/issues/156)) ([8c2990a](https://github.com/spaced-out/ui-design-system/commit/8c2990a3e862ebac43a75cc026754584260c6aaa))
24
+
5
25
  ### [0.1.73](https://github.com/spaced-out/ui-design-system/compare/v0.1.72...v0.1.73) (2024-01-02)
6
26
 
7
27
 
@@ -1,7 +1,7 @@
1
1
  @value (spaceNegFluid, spaceNone, spaceMedium, spaceSmall, spaceFluid) from '../../styles/variables/_space.css';
2
2
  @value (size4, size60, size480, size580, size720, sizeFluid) from '../../styles/variables/_size.css';
3
3
  @value (motionDurationNormal, motionEaseInEaseOut) from '../../styles/variables/_motion.css';
4
- @value (colorBackgroundTertiary, colorBackgroundPrimary, colorBackgroundSecondary) from '../../styles/variables/_color.css';
4
+ @value (colorBackgroundTertiary, colorBackgroundPrimary) from '../../styles/variables/_color.css';
5
5
  @value (borderRadiusNone) from '../../styles/variables/_border.css';
6
6
 
7
7
  .panel {
@@ -62,7 +62,7 @@
62
62
  padding: spaceMedium;
63
63
  height: sizeFluid;
64
64
  overflow: auto;
65
- background-color: colorBackgroundSecondary;
65
+ background-color: colorBackgroundPrimary;
66
66
  }
67
67
 
68
68
  .panelFooter {
@@ -5,6 +5,7 @@ Object.defineProperty(exports, "__esModule", {
5
5
  });
6
6
  exports.TabList = void 0;
7
7
  var React = _interopRequireWildcard(require("react"));
8
+ var _useWindowSize = require("../../../hooks/useWindowSize/useWindowSize");
8
9
  var _size = require("../../../styles/variables/_size");
9
10
  var _space = require("../../../styles/variables/_space");
10
11
  var _classify = require("../../../utils/classify");
@@ -25,6 +26,9 @@ const TabList = /*#__PURE__*/React.forwardRef((_ref, forwardRef) => {
25
26
  } = _ref;
26
27
  const ref = React.useRef(null);
27
28
  React.useImperativeHandle(forwardRef, () => ref.current);
29
+ const {
30
+ width
31
+ } = (0, _useWindowSize.useWindowSize)();
28
32
  const [containerWidth, setContainerWidth] = React.useState(0);
29
33
  const childrenWithProps = () => {
30
34
  const childrenArray = React.Children.toArray(children);
@@ -113,7 +117,8 @@ const TabList = /*#__PURE__*/React.forwardRef((_ref, forwardRef) => {
113
117
  const availableContainerWidth = ref.current.offsetWidth - (parseInt(_size.size36) + parseInt(_space.spaceMedium));
114
118
  setContainerWidth(availableContainerWidth);
115
119
  }
116
- }, [ref.current]);
120
+ // it depends on width of the screen as ref.current.offsetWidth will not provide the events when changed.
121
+ }, [ref.current, width]);
117
122
  return /*#__PURE__*/React.createElement("div", {
118
123
  ref: ref,
119
124
  "data-testid": "Tabs",
@@ -2,6 +2,7 @@
2
2
 
3
3
  import * as React from 'react';
4
4
 
5
+ import {useWindowSize} from '../../../hooks/useWindowSize/useWindowSize';
5
6
  import {size36, size100} from '../../../styles/variables/_size';
6
7
  import {spaceMedium} from '../../../styles/variables/_space';
7
8
  import {classify} from '../../../utils/classify';
@@ -37,6 +38,7 @@ export const TabList: React$AbstractComponent<TabListProps, HTMLDivElement> =
37
38
  ): React.Node => {
38
39
  const ref = React.useRef(null);
39
40
  React.useImperativeHandle(forwardRef, () => ref.current);
41
+ const {width} = useWindowSize();
40
42
 
41
43
  const [containerWidth, setContainerWidth] = React.useState(0);
42
44
 
@@ -132,7 +134,8 @@ export const TabList: React$AbstractComponent<TabListProps, HTMLDivElement> =
132
134
  (parseInt(size36) + parseInt(spaceMedium));
133
135
  setContainerWidth(availableContainerWidth);
134
136
  }
135
- }, [ref.current]);
137
+ // it depends on width of the screen as ref.current.offsetWidth will not provide the events when changed.
138
+ }, [ref.current, width]);
136
139
 
137
140
  return (
138
141
  <div
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@spaced-out/ui-design-system",
3
- "version": "0.1.73",
3
+ "version": "0.1.75",
4
4
  "main": "index.js",
5
5
  "description": "Sense UI components library",
6
6
  "author": {