New Changes with table Classes and Modification

This commit is contained in:
2025-11-06 16:16:13 +05:30
parent f1aed75947
commit aba7743ecd
+2 -1
View File
@@ -205,6 +205,7 @@ const id = `table-${Math.random().toString(36).slice(2, 9)}`;
dataset.length - 1 != i ? "wr:border-b" : "", dataset.length - 1 != i ? "wr:border-b" : "",
"wr:border-gray-300 wr:dark:border-neutral-800", "wr:border-gray-300 wr:dark:border-neutral-800",
rowCls, rowCls,
rowClickFn ? "wr:cursor-pointer" : "",
] ]
.filter(Boolean) .filter(Boolean)
.join(" ")}">`; .join(" ")}">`;
@@ -251,7 +252,7 @@ const id = `table-${Math.random().toString(36).slice(2, 9)}`;
}; };
// 📱 Mobile // 📱 Mobile
let card = `<div data-row-idx="${i}" class="wr:rounded-lg wr:border wr:border-gray-300 wr:dark:border-neutral-700 wr:p-4 wr:space-y-2 wr:bg-white wr:dark:bg-neutral-800">`; let card = `<div data-row-idx="${i}" class="wr:rounded-lg wr:border wr:border-gray-300 wr:dark:border-neutral-700 wr:p-4 wr:space-y-2 wr:bg-white wr:dark:bg-neutral-800 ${rowClickFn ? "wr:cursor-pointer" : ""}">`;
columns.forEach((col, colIndex) => { columns.forEach((col, colIndex) => {
let value = row[col.key] ?? ""; let value = row[col.key] ?? "";