@sb1/ffe-tables-react 11.0.4 → 11.0.5

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.
@@ -32,6 +32,7 @@ export var TableRowExpandable = React.forwardRef(function (_a, ref) {
32
32
  var expandoRowId = useId();
33
33
  var _d = useState(false), isAnimating = _d[0], setIsAnimating = _d[1];
34
34
  var expandButtonRef = useRef(null);
35
+ var expandIdHidden = !isAnimating && !isOpen;
35
36
  return (React.createElement(React.Fragment, null,
36
37
  React.createElement("tr", __assign({ className: classNames('ffe-table__tr', 'ffe-table__tr--expand', {
37
38
  'ffe-table__tr--expand-open': isOpen,
@@ -56,8 +57,8 @@ export var TableRowExpandable = React.forwardRef(function (_a, ref) {
56
57
  onClick === null || onClick === void 0 ? void 0 : onClick(e);
57
58
  } },
58
59
  React.createElement(Icon, { fileUrl: "data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIGhlaWdodD0iMjQiIHZpZXdCb3g9IjAgLTk2MCA5NjAgOTYwIiB3aWR0aD0iMjQiPjxwYXRoIGQ9Ik00ODAtMzczLjUzOXEtNy4yMzEgMC0xMy40NjEtMi4zMDgtNi4yMzEtMi4zMDgtMTEuODQ2LTcuOTIzTDI3NC45MjQtNTYzLjUzOXEtOC4zMDgtOC4zMDctOC41LTIwLjg4NC0uMTkzLTEyLjU3NyA4LjUtMjEuMjY5IDguNjkyLTguNjkyIDIxLjA3Ni04LjY5MnQyMS4wNzYgOC42OTJMNDgwLTQ0Mi43NjhsMTYyLjkyNC0xNjIuOTI0cTguMzA3LTguMzA3IDIwLjg4NC04LjUgMTIuNTc2LS4xOTIgMjEuMjY4IDguNSA4LjY5MyA4LjY5MiA4LjY5MyAyMS4wNzcgMCAxMi4zODQtOC42OTMgMjEuMDc2TDUwNS4zMDctMzgzLjc3cS01LjYxNSA1LjYxNS0xMS44NDYgNy45MjMtNi4yMyAyLjMwOC0xMy40NjEgMi4zMDhaIi8+PC9zdmc+", size: "md" }))))),
59
- React.createElement("tr", { "aria-hidden": !isAnimating && !isOpen, id: expandoRowId },
60
+ React.createElement("tr", { className: "ffe-table__expand-content-tr", "aria-hidden": expandIdHidden, id: expandoRowId },
60
61
  React.createElement("td", { colSpan: 9999 },
61
62
  React.createElement(Collapse, { isOpen: isOpen, onRest: function () { return setIsAnimating(false); } },
62
- React.createElement(CellContent, { className: "ffe-table__expand-content" }, expandContent))))));
63
+ React.createElement(CellContent, { className: "ffe-table__expand-content" }, !expandIdHidden && expandContent))))));
63
64
  });
@@ -61,6 +61,7 @@ exports.TableRowExpandable = react_1.default.forwardRef(function (_a, ref) {
61
61
  var expandoRowId = (0, react_1.useId)();
62
62
  var _d = (0, react_1.useState)(false), isAnimating = _d[0], setIsAnimating = _d[1];
63
63
  var expandButtonRef = (0, react_1.useRef)(null);
64
+ var expandIdHidden = !isAnimating && !isOpen;
64
65
  return (react_1.default.createElement(react_1.default.Fragment, null,
65
66
  react_1.default.createElement("tr", __assign({ className: (0, classnames_1.default)('ffe-table__tr', 'ffe-table__tr--expand', {
66
67
  'ffe-table__tr--expand-open': isOpen,
@@ -85,8 +86,8 @@ exports.TableRowExpandable = react_1.default.forwardRef(function (_a, ref) {
85
86
  onClick === null || onClick === void 0 ? void 0 : onClick(e);
86
87
  } },
87
88
  react_1.default.createElement(ffe_icons_react_1.Icon, { fileUrl: "data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIGhlaWdodD0iMjQiIHZpZXdCb3g9IjAgLTk2MCA5NjAgOTYwIiB3aWR0aD0iMjQiPjxwYXRoIGQ9Ik00ODAtMzczLjUzOXEtNy4yMzEgMC0xMy40NjEtMi4zMDgtNi4yMzEtMi4zMDgtMTEuODQ2LTcuOTIzTDI3NC45MjQtNTYzLjUzOXEtOC4zMDgtOC4zMDctOC41LTIwLjg4NC0uMTkzLTEyLjU3NyA4LjUtMjEuMjY5IDguNjkyLTguNjkyIDIxLjA3Ni04LjY5MnQyMS4wNzYgOC42OTJMNDgwLTQ0Mi43NjhsMTYyLjkyNC0xNjIuOTI0cTguMzA3LTguMzA3IDIwLjg4NC04LjUgMTIuNTc2LS4xOTIgMjEuMjY4IDguNSA4LjY5MyA4LjY5MiA4LjY5MyAyMS4wNzcgMCAxMi4zODQtOC42OTMgMjEuMDc2TDUwNS4zMDctMzgzLjc3cS01LjYxNSA1LjYxNS0xMS44NDYgNy45MjMtNi4yMyAyLjMwOC0xMy40NjEgMi4zMDhaIi8+PC9zdmc+", size: "md" }))))),
88
- react_1.default.createElement("tr", { "aria-hidden": !isAnimating && !isOpen, id: expandoRowId },
89
+ react_1.default.createElement("tr", { className: "ffe-table__expand-content-tr", "aria-hidden": expandIdHidden, id: expandoRowId },
89
90
  react_1.default.createElement("td", { colSpan: 9999 },
90
91
  react_1.default.createElement(ffe_collapse_react_1.Collapse, { isOpen: isOpen, onRest: function () { return setIsAnimating(false); } },
91
- react_1.default.createElement(CellContent_1.CellContent, { className: "ffe-table__expand-content" }, expandContent))))));
92
+ react_1.default.createElement(CellContent_1.CellContent, { className: "ffe-table__expand-content" }, !expandIdHidden && expandContent))))));
92
93
  });
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@sb1/ffe-tables-react",
3
- "version": "11.0.4",
3
+ "version": "11.0.5",
4
4
  "description": "React implementation of ffe-tables",
5
5
  "license": "MIT",
6
6
  "author": "SpareBank 1",
@@ -26,13 +26,13 @@
26
26
  "test:watch": "ffe-buildtool jest --watch"
27
27
  },
28
28
  "dependencies": {
29
- "@sb1/ffe-collapse-react": "^5.0.7",
30
- "@sb1/ffe-icons-react": "^11.0.5",
31
- "@sb1/ffe-tables": "^17.0.2",
29
+ "@sb1/ffe-collapse-react": "^5.0.8",
30
+ "@sb1/ffe-icons-react": "^11.0.6",
31
+ "@sb1/ffe-tables": "^17.0.3",
32
32
  "classnames": "^2.3.1"
33
33
  },
34
34
  "devDependencies": {
35
- "@sb1/ffe-buildtool": "^0.8.0",
35
+ "@sb1/ffe-buildtool": "^0.8.1",
36
36
  "react": "^18.2.0",
37
37
  "react-dom": "^18.2.0"
38
38
  },
@@ -42,5 +42,5 @@
42
42
  "publishConfig": {
43
43
  "access": "public"
44
44
  },
45
- "gitHead": "8008aad1c638b69d8e149dbea6ebe2705758b762"
45
+ "gitHead": "b628311e80b2a2cc84cb534e4aa4f6a7f251d9b5"
46
46
  }