@obolnetwork/obol-ui 1.0.26 → 1.0.29

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.
@@ -1,4 +1,5 @@
1
1
  /// <reference types="react" />
2
+ import { CSS } from "../../../stitches.config";
2
3
  export declare type RowDef<T> = {
3
4
  id: string;
4
5
  isRemovable?: boolean;
@@ -16,6 +17,7 @@ export declare type CellDef = {
16
17
  export declare type ColumnDef<T> = {
17
18
  accessorKey: keyof T;
18
19
  header: string | React.ReactNode;
20
+ css?: CSS;
19
21
  cell?: CellDef;
20
22
  };
21
23
  export interface TableProps {
package/dist/index.es.js CHANGED
@@ -1128,14 +1128,16 @@ var MinusIcon = function () { return (jsx("svg", __assign({ width: "15", height:
1128
1128
 
1129
1129
  var PlusIcon = function () { return (jsx("svg", __assign({ width: "14", height: "14", viewBox: "0 0 14 14", fill: "none", xmlns: "http://www.w3.org/2000/svg" }, { children: jsx("path", { d: "M14 8H8V14H6V8H0V6H6V0H8V6H14V8Z", fill: "#DAEEF3" }) }))); };
1130
1130
 
1131
- var TeamMemberCard = function (props) { return (jsxs(Box, __assign({ css: {
1131
+ var TeamMemberCard = function (props) { return (jsxs(Box, __assign({ className: "team-member-card", css: {
1132
1132
  display: "grid",
1133
1133
  gridTemplateColumns: "1fr",
1134
1134
  borderRadius: "$3",
1135
1135
  backgroundColor: "$bg04",
1136
1136
  alignItems: "center",
1137
+ justifyItems: "center",
1138
+ width: "288px",
1137
1139
  gap: "$lg",
1138
- p: "$xl",
1140
+ py: "$xl",
1139
1141
  "@sm": { gridTemplateColumns: "1fr 2fr", p: "$sm" },
1140
1142
  } }, { children: [jsx(Box, __assign({ css: {
1141
1143
  $$size: "160px",
@@ -1729,11 +1731,11 @@ var Navbar = function (_a) {
1729
1731
  "@sm": {
1730
1732
  pl: "$sm",
1731
1733
  },
1732
- } }, { children: [jsxs(Box, __assign({ css: {
1734
+ } }, { children: [jsxs(Box, __assign({ as: "a", css: {
1733
1735
  display: "flex",
1734
1736
  alignItems: "center",
1735
1737
  "@sm": { display: "none" },
1736
- } }, { children: [jsx(ObolDarkBgH, {}), logoText && (jsx(Text, __assign({ css: {
1738
+ }, href: "/" }, { children: [jsx(ObolDarkBgH, {}), logoText && (jsx(Text, __assign({ css: {
1737
1739
  fontSize: "28px",
1738
1740
  color: "$muted",
1739
1741
  fontWeight: "bold",
@@ -2007,7 +2009,10 @@ var AddNewRow = function (_a) {
2007
2009
  };
2008
2010
  var SplitterTable = function (_a) {
2009
2011
  var rows = _a.rows, columns = _a.columns, onAddRow = _a.onAddRow, onRemoveRow = _a.onRemoveRow, onUpdateRow = _a.onUpdateRow, _b = _a.totalSplitFooter, totalSplitFooter = _b === void 0 ? 100 : _b;
2010
- return (jsxs(StyledTable, { children: [jsx("thead", { children: jsxs("tr", { children: [jsx(Th, {}), columns.map(function (column, index) { return (jsx(Th, __assign({ css: { textAlign: "start" } }, { children: column.header }), "header-".concat(index))); }), jsx(Th, {})] }) }), jsxs("tbody", { children: [rows.map(function (_a, rowIndex) {
2012
+ return (jsxs(StyledTable, { children: [jsx("thead", { children: jsxs("tr", { children: [jsx(Th, {}), columns.map(function (_a, index) {
2013
+ var css = _a.css, column = __rest(_a, ["css"]);
2014
+ return (jsx(Th, __assign({ css: __assign({ textAlign: "start" }, css) }, { children: column.header }), "header-".concat(index)));
2015
+ }), jsx(Th, {})] }) }), jsxs("tbody", { children: [rows.map(function (_a, rowIndex) {
2011
2016
  var _b = _a.isRemovable, isRemovable = _b === void 0 ? true : _b, _c = _a.isEditable, isEditable = _c === void 0 ? true : _c, row = __rest(_a, ["isRemovable", "isEditable"]);
2012
2017
  return (jsxs("tr", { children: [jsx(Td, __assign({ textCenter: true, size: "sm" }, { children: rowIndex + 1 })), columns.map(function (column, cellIndex) {
2013
2018
  var _a, _b, _c, _d, _e, _f, _g;
@@ -2059,7 +2064,10 @@ var SplitterTable = function (_a) {
2059
2064
  };
2060
2065
  var Table = function (_a) {
2061
2066
  var rows = _a.rows, columns = _a.columns;
2062
- return (jsxs(StyledTable, { children: [jsx("thead", { children: jsx("tr", { children: columns.map(function (column, index) { return (jsx(Th, __assign({ css: { textAlign: "start" } }, { children: column.header }), "header-".concat(index))); }) }) }), jsx("tbody", { children: rows.map(function (row, rowIndex) { return (jsx("tr", { children: columns.map(function (column, cellIndex) {
2067
+ return (jsxs(StyledTable, { children: [jsx("thead", { children: jsx("tr", { children: columns.map(function (_a, index) {
2068
+ var css = _a.css, column = __rest(_a, ["css"]);
2069
+ return (jsx(Th, __assign({ css: __assign({ textAlign: "start" }, css) }, { children: column.header }), "header-".concat(index)));
2070
+ }) }) }), jsx("tbody", { children: rows.map(function (row, rowIndex) { return (jsx("tr", { children: columns.map(function (column, cellIndex) {
2063
2071
  return (jsx(Td, __assign({ css: { color: "$light" } }, { children: row[column.accessorKey] }), "cell ".concat(cellIndex)));
2064
2072
  }) }, "row ".concat(rowIndex))); }) })] }));
2065
2073
  };
package/dist/index.js CHANGED
@@ -1160,14 +1160,16 @@ var MinusIcon = function () { return (jsxRuntime.jsx("svg", __assign({ width: "1
1160
1160
 
1161
1161
  var PlusIcon = function () { return (jsxRuntime.jsx("svg", __assign({ width: "14", height: "14", viewBox: "0 0 14 14", fill: "none", xmlns: "http://www.w3.org/2000/svg" }, { children: jsxRuntime.jsx("path", { d: "M14 8H8V14H6V8H0V6H6V0H8V6H14V8Z", fill: "#DAEEF3" }) }))); };
1162
1162
 
1163
- var TeamMemberCard = function (props) { return (jsxRuntime.jsxs(Box, __assign({ css: {
1163
+ var TeamMemberCard = function (props) { return (jsxRuntime.jsxs(Box, __assign({ className: "team-member-card", css: {
1164
1164
  display: "grid",
1165
1165
  gridTemplateColumns: "1fr",
1166
1166
  borderRadius: "$3",
1167
1167
  backgroundColor: "$bg04",
1168
1168
  alignItems: "center",
1169
+ justifyItems: "center",
1170
+ width: "288px",
1169
1171
  gap: "$lg",
1170
- p: "$xl",
1172
+ py: "$xl",
1171
1173
  "@sm": { gridTemplateColumns: "1fr 2fr", p: "$sm" },
1172
1174
  } }, { children: [jsxRuntime.jsx(Box, __assign({ css: {
1173
1175
  $$size: "160px",
@@ -1761,11 +1763,11 @@ var Navbar = function (_a) {
1761
1763
  "@sm": {
1762
1764
  pl: "$sm",
1763
1765
  },
1764
- } }, { children: [jsxRuntime.jsxs(Box, __assign({ css: {
1766
+ } }, { children: [jsxRuntime.jsxs(Box, __assign({ as: "a", css: {
1765
1767
  display: "flex",
1766
1768
  alignItems: "center",
1767
1769
  "@sm": { display: "none" },
1768
- } }, { children: [jsxRuntime.jsx(ObolDarkBgH, {}), logoText && (jsxRuntime.jsx(Text, __assign({ css: {
1770
+ }, href: "/" }, { children: [jsxRuntime.jsx(ObolDarkBgH, {}), logoText && (jsxRuntime.jsx(Text, __assign({ css: {
1769
1771
  fontSize: "28px",
1770
1772
  color: "$muted",
1771
1773
  fontWeight: "bold",
@@ -2039,7 +2041,10 @@ var AddNewRow = function (_a) {
2039
2041
  };
2040
2042
  var SplitterTable = function (_a) {
2041
2043
  var rows = _a.rows, columns = _a.columns, onAddRow = _a.onAddRow, onRemoveRow = _a.onRemoveRow, onUpdateRow = _a.onUpdateRow, _b = _a.totalSplitFooter, totalSplitFooter = _b === void 0 ? 100 : _b;
2042
- return (jsxRuntime.jsxs(StyledTable, { children: [jsxRuntime.jsx("thead", { children: jsxRuntime.jsxs("tr", { children: [jsxRuntime.jsx(Th, {}), columns.map(function (column, index) { return (jsxRuntime.jsx(Th, __assign({ css: { textAlign: "start" } }, { children: column.header }), "header-".concat(index))); }), jsxRuntime.jsx(Th, {})] }) }), jsxRuntime.jsxs("tbody", { children: [rows.map(function (_a, rowIndex) {
2044
+ return (jsxRuntime.jsxs(StyledTable, { children: [jsxRuntime.jsx("thead", { children: jsxRuntime.jsxs("tr", { children: [jsxRuntime.jsx(Th, {}), columns.map(function (_a, index) {
2045
+ var css = _a.css, column = __rest(_a, ["css"]);
2046
+ return (jsxRuntime.jsx(Th, __assign({ css: __assign({ textAlign: "start" }, css) }, { children: column.header }), "header-".concat(index)));
2047
+ }), jsxRuntime.jsx(Th, {})] }) }), jsxRuntime.jsxs("tbody", { children: [rows.map(function (_a, rowIndex) {
2043
2048
  var _b = _a.isRemovable, isRemovable = _b === void 0 ? true : _b, _c = _a.isEditable, isEditable = _c === void 0 ? true : _c, row = __rest(_a, ["isRemovable", "isEditable"]);
2044
2049
  return (jsxRuntime.jsxs("tr", { children: [jsxRuntime.jsx(Td, __assign({ textCenter: true, size: "sm" }, { children: rowIndex + 1 })), columns.map(function (column, cellIndex) {
2045
2050
  var _a, _b, _c, _d, _e, _f, _g;
@@ -2091,7 +2096,10 @@ var SplitterTable = function (_a) {
2091
2096
  };
2092
2097
  var Table = function (_a) {
2093
2098
  var rows = _a.rows, columns = _a.columns;
2094
- return (jsxRuntime.jsxs(StyledTable, { children: [jsxRuntime.jsx("thead", { children: jsxRuntime.jsx("tr", { children: columns.map(function (column, index) { return (jsxRuntime.jsx(Th, __assign({ css: { textAlign: "start" } }, { children: column.header }), "header-".concat(index))); }) }) }), jsxRuntime.jsx("tbody", { children: rows.map(function (row, rowIndex) { return (jsxRuntime.jsx("tr", { children: columns.map(function (column, cellIndex) {
2099
+ return (jsxRuntime.jsxs(StyledTable, { children: [jsxRuntime.jsx("thead", { children: jsxRuntime.jsx("tr", { children: columns.map(function (_a, index) {
2100
+ var css = _a.css, column = __rest(_a, ["css"]);
2101
+ return (jsxRuntime.jsx(Th, __assign({ css: __assign({ textAlign: "start" }, css) }, { children: column.header }), "header-".concat(index)));
2102
+ }) }) }), jsxRuntime.jsx("tbody", { children: rows.map(function (row, rowIndex) { return (jsxRuntime.jsx("tr", { children: columns.map(function (column, cellIndex) {
2095
2103
  return (jsxRuntime.jsx(Td, __assign({ css: { color: "$light" } }, { children: row[column.accessorKey] }), "cell ".concat(cellIndex)));
2096
2104
  }) }, "row ".concat(rowIndex))); }) })] }));
2097
2105
  };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@obolnetwork/obol-ui",
3
- "version": "1.0.26",
3
+ "version": "1.0.29",
4
4
  "main": "dist/index.js",
5
5
  "module": "dist/index.es.js",
6
6
  "license": "MIT",