opus-toolkit-components 0.4.0 → 0.4.2
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.
|
@@ -54,6 +54,28 @@ ___CSS_LOADER_EXPORT___.push([module.id, `.dark-card{background-color:#24135f;co
|
|
|
54
54
|
/* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (___CSS_LOADER_EXPORT___);
|
|
55
55
|
|
|
56
56
|
|
|
57
|
+
/***/ }),
|
|
58
|
+
|
|
59
|
+
/***/ 705:
|
|
60
|
+
/***/ ((module, __webpack_exports__, __webpack_require__) => {
|
|
61
|
+
|
|
62
|
+
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
|
|
63
|
+
/* harmony export */ A: () => (__WEBPACK_DEFAULT_EXPORT__)
|
|
64
|
+
/* harmony export */ });
|
|
65
|
+
/* harmony import */ var _node_modules_css_loader_dist_runtime_sourceMaps_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(354);
|
|
66
|
+
/* harmony import */ var _node_modules_css_loader_dist_runtime_sourceMaps_js__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_node_modules_css_loader_dist_runtime_sourceMaps_js__WEBPACK_IMPORTED_MODULE_0__);
|
|
67
|
+
/* harmony import */ var _node_modules_css_loader_dist_runtime_api_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(314);
|
|
68
|
+
/* harmony import */ var _node_modules_css_loader_dist_runtime_api_js__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_node_modules_css_loader_dist_runtime_api_js__WEBPACK_IMPORTED_MODULE_1__);
|
|
69
|
+
// Imports
|
|
70
|
+
|
|
71
|
+
|
|
72
|
+
var ___CSS_LOADER_EXPORT___ = _node_modules_css_loader_dist_runtime_api_js__WEBPACK_IMPORTED_MODULE_1___default()((_node_modules_css_loader_dist_runtime_sourceMaps_js__WEBPACK_IMPORTED_MODULE_0___default()));
|
|
73
|
+
// Module
|
|
74
|
+
___CSS_LOADER_EXPORT___.push([module.id, `table thead th:first-of-type{border-top-left-radius:8px}table thead th:last-of-type{border-top-right-radius:8px}table tr:last-of-type td:first-of-type{border-bottom-left-radius:8px}table tr:last-of-type td:last-of-type{border-bottom-right-radius:8px}`, "",{"version":3,"sources":["webpack://./src/components/Tables/table.scss"],"names":[],"mappings":"AAGY,6BACI,0BAAA,CAEJ,4BACI,2BAAA,CAOA,uCACI,6BAAA,CAEJ,sCACI,8BAAA","sourcesContent":["table {\r\n thead {\r\n th {\r\n &:first-of-type {\r\n border-top-left-radius: 8px;\r\n }\r\n &:last-of-type {\r\n border-top-right-radius: 8px;\r\n }\r\n }\r\n }\r\n tr {\r\n &:last-of-type {\r\n td {\r\n &:first-of-type {\r\n border-bottom-left-radius: 8px;\r\n }\r\n &:last-of-type {\r\n border-bottom-right-radius: 8px;\r\n }\r\n }\r\n } \r\n } \r\n}"],"sourceRoot":""}]);
|
|
75
|
+
// Exports
|
|
76
|
+
/* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (___CSS_LOADER_EXPORT___);
|
|
77
|
+
|
|
78
|
+
|
|
57
79
|
/***/ }),
|
|
58
80
|
|
|
59
81
|
/***/ 314:
|
|
@@ -932,12 +954,61 @@ const RadioButtonGroup = _ref => {
|
|
|
932
954
|
};
|
|
933
955
|
RadioButtonGroup.displayName = 'RadioButtonGroup';
|
|
934
956
|
/* harmony default export */ const RadioButton = (RadioButtonGroup);
|
|
957
|
+
// EXTERNAL MODULE: ./node_modules/css-loader/dist/cjs.js!./node_modules/sass-loader/dist/cjs.js!./src/components/Tables/table.scss
|
|
958
|
+
var table = __webpack_require__(705);
|
|
959
|
+
;// ./src/components/Tables/table.scss
|
|
960
|
+
|
|
961
|
+
|
|
962
|
+
|
|
963
|
+
|
|
964
|
+
|
|
965
|
+
|
|
966
|
+
|
|
967
|
+
|
|
968
|
+
|
|
969
|
+
|
|
970
|
+
|
|
971
|
+
var table_options = {};
|
|
972
|
+
|
|
973
|
+
table_options.styleTagTransform = (styleTagTransform_default());
|
|
974
|
+
table_options.setAttributes = (setAttributesWithoutAttributes_default());
|
|
975
|
+
table_options.insert = insertBySelector_default().bind(null, "head");
|
|
976
|
+
table_options.domAPI = (styleDomAPI_default());
|
|
977
|
+
table_options.insertStyleElement = (insertStyleElement_default());
|
|
978
|
+
|
|
979
|
+
var table_update = injectStylesIntoStyleTag_default()(table/* default */.A, table_options);
|
|
980
|
+
|
|
981
|
+
|
|
982
|
+
|
|
983
|
+
|
|
984
|
+
/* harmony default export */ const Tables_table = (table/* default */.A && table/* default */.A.locals ? table/* default */.A.locals : undefined);
|
|
985
|
+
|
|
935
986
|
;// ./src/components/Tables/Table.js
|
|
936
987
|
|
|
937
|
-
|
|
988
|
+
|
|
989
|
+
function Table(_ref) {
|
|
990
|
+
let {
|
|
991
|
+
data = [],
|
|
992
|
+
// Array defining columns and rendering logic
|
|
993
|
+
rows = [],
|
|
994
|
+
// Array defining rows
|
|
995
|
+
className = "",
|
|
996
|
+
rowKeyExtractor = (row, index) => index // Function to extract unique keys for rows
|
|
997
|
+
} = _ref;
|
|
938
998
|
return /*#__PURE__*/external_react_default().createElement("table", {
|
|
939
|
-
|
|
940
|
-
}, /*#__PURE__*/external_react_default().createElement("thead", null, /*#__PURE__*/external_react_default().createElement("tr",
|
|
999
|
+
className: `w-full table-auto text-left border-collapse ${className}`
|
|
1000
|
+
}, /*#__PURE__*/external_react_default().createElement("thead", null, /*#__PURE__*/external_react_default().createElement("tr", {
|
|
1001
|
+
className: "bg-greyBaseDark900"
|
|
1002
|
+
}, data.map(column => /*#__PURE__*/external_react_default().createElement("th", {
|
|
1003
|
+
key: column.key,
|
|
1004
|
+
className: "border-b border-gray-300 py-2 px-4 text-sm font-normal text-greyDark1000"
|
|
1005
|
+
}, column.header)))), /*#__PURE__*/external_react_default().createElement("tbody", null, rows.map((row, index) => /*#__PURE__*/external_react_default().createElement("tr", {
|
|
1006
|
+
key: rowKeyExtractor(row, index),
|
|
1007
|
+
className: `${index % 2 === 0 ? "bg-greyLight100" : "bg-greyLight50"} hover:bg-greyLight500`
|
|
1008
|
+
}, data.map(column => /*#__PURE__*/external_react_default().createElement("td", {
|
|
1009
|
+
key: column.key,
|
|
1010
|
+
className: "p-4 text-sm text-greyLight700"
|
|
1011
|
+
}, column.render ? column.render(row) : row[column.key]))))));
|
|
941
1012
|
}
|
|
942
1013
|
;// ./node_modules/@react-aria/utils/dist/platform.mjs
|
|
943
1014
|
/*
|
|
@@ -9211,4 +9282,4 @@ function Dropdown(_ref) {
|
|
|
9211
9282
|
/******/ })()
|
|
9212
9283
|
;
|
|
9213
9284
|
});
|
|
9214
|
-
//# sourceMappingURL=main.
|
|
9285
|
+
//# sourceMappingURL=main.e560d9256b4456e21fe5.js.map
|