loon-bulma-react 2026.0.58 → 2026.0.59
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.
|
@@ -138,8 +138,10 @@ type DataTableProps<T extends unknown = unknown> = {
|
|
|
138
138
|
* - function: een function die een `string` returned om te gebruiken als `key` voor de row.
|
|
139
139
|
*/
|
|
140
140
|
rowIdentifier: keyof T | ((item: T) => string);
|
|
141
|
-
/** extra content boven de tabel, links van het zoekveld. Deze content wordt automatisch gewrapped met een `<td>...</td
|
|
142
|
-
|
|
141
|
+
/** extra content boven de tabel, links van het zoekveld. Deze content wordt automatisch gewrapped met een `<td>...</td>`.
|
|
142
|
+
* __BEHALVE als de headerContent__ de tekst `searchbar` is. In dat geval gebruikt de zoek-bar de hele breedte van de tabel. (Tenzij `searchHiden` is true, dan wordt de zoekbar niet getoond)
|
|
143
|
+
*/
|
|
144
|
+
headerContent?: 'searchbar' | React.ReactNode | undefined;
|
|
143
145
|
/** extra content onder de tabel. Een ReactNode.
|
|
144
146
|
* Deze content **MOET** een `<tr><td>...</td></tr>` bevatten!
|
|
145
147
|
*/
|
package/dist/index.js
CHANGED
|
@@ -13599,6 +13599,7 @@ function S_({ data: e = [], columns: n = [], defaultSortColNum: r = void 0, comp
|
|
|
13599
13599
|
cols: M,
|
|
13600
13600
|
size: p,
|
|
13601
13601
|
searchValue: P,
|
|
13602
|
+
searchBarIsWholeWidth: d === "searchbar",
|
|
13602
13603
|
filterCount: te.length,
|
|
13603
13604
|
dataCount: e.length,
|
|
13604
13605
|
hideSearch: u,
|
|
@@ -13608,7 +13609,7 @@ function S_({ data: e = [], columns: n = [], defaultSortColNum: r = void 0, comp
|
|
|
13608
13609
|
sortColNum: L,
|
|
13609
13610
|
onSortIndexChanged: R,
|
|
13610
13611
|
tableID: N,
|
|
13611
|
-
children: d
|
|
13612
|
+
children: d === "searchbar" ? void 0 : d
|
|
13612
13613
|
}),
|
|
13613
13614
|
/* @__PURE__ */ b(C_, {
|
|
13614
13615
|
searchTerm: I,
|
|
@@ -13699,34 +13700,34 @@ function T_({ rowClass: e, rowKey: n, columns: r, item: i, onRowSelected: a, onR
|
|
|
13699
13700
|
})
|
|
13700
13701
|
});
|
|
13701
13702
|
}
|
|
13702
|
-
function E_({ children: e = void 0, searchValue: t, filterCount: n, dataCount: r, searchPlaceholder: i,
|
|
13703
|
-
let
|
|
13704
|
-
function
|
|
13705
|
-
let n = t + 1, r =
|
|
13706
|
-
r && r.sort && (Math.abs(
|
|
13703
|
+
function E_({ children: e = void 0, searchValue: t, filterCount: n, dataCount: r, searchPlaceholder: i, searchBarIsWholeWidth: a, cols: o, size: s, sortColNum: c, hideSearch: l, sticky: u, tableID: d, onSortIndexChanged: f, onSearchValueChanged: p, infoMessage: m }) {
|
|
13704
|
+
let h = l ? o.length : Math.ceil(o.filter((e) => !e.hidden).length / 2), g = l ? 0 : a ? o.length : o.length - h;
|
|
13705
|
+
function _(e, t) {
|
|
13706
|
+
let n = t + 1, r = o[t];
|
|
13707
|
+
r && r.sort && (Math.abs(c) === n ? f(c * -1) : c !== n && f(n));
|
|
13707
13708
|
}
|
|
13708
13709
|
return /* @__PURE__ */ x("thead", {
|
|
13709
|
-
className:
|
|
13710
|
+
className: u === "all" ? "is-sticky-head" : void 0,
|
|
13710
13711
|
children: [/* @__PURE__ */ x("tr", {
|
|
13711
13712
|
role: "header-row",
|
|
13712
|
-
children: [/* @__PURE__ */ b("th", {
|
|
13713
|
-
colSpan: m,
|
|
13714
|
-
children: e
|
|
13715
|
-
}), !c && /* @__PURE__ */ b("th", {
|
|
13713
|
+
children: [e && /* @__PURE__ */ b("th", {
|
|
13716
13714
|
colSpan: h,
|
|
13715
|
+
children: e
|
|
13716
|
+
}), !l && /* @__PURE__ */ b("th", {
|
|
13717
|
+
colSpan: g,
|
|
13717
13718
|
children: /* @__PURE__ */ x("div", {
|
|
13718
13719
|
title: i,
|
|
13719
13720
|
className: "control has-icons-left",
|
|
13720
13721
|
children: [/* @__PURE__ */ b(Ah, {
|
|
13721
|
-
size:
|
|
13722
|
+
size: s,
|
|
13722
13723
|
type: "text",
|
|
13723
|
-
name: `lbr-datatable-search-${
|
|
13724
|
-
id: `lbr-datatable-search-${
|
|
13725
|
-
optionListId: `lbr-datatable-datalist-${
|
|
13724
|
+
name: `lbr-datatable-search-${d}`,
|
|
13725
|
+
id: `lbr-datatable-search-${d}`,
|
|
13726
|
+
optionListId: `lbr-datatable-datalist-${d}`,
|
|
13726
13727
|
placeholder: i,
|
|
13727
13728
|
value: t,
|
|
13728
|
-
onValueChanged:
|
|
13729
|
-
infoMessage:
|
|
13729
|
+
onValueChanged: p,
|
|
13730
|
+
infoMessage: m(n, r, t)
|
|
13730
13731
|
}), /* @__PURE__ */ b("span", {
|
|
13731
13732
|
className: "icon is-small is-left",
|
|
13732
13733
|
children: /* @__PURE__ */ b(Io, { icon: Uo })
|
|
@@ -13735,17 +13736,17 @@ function E_({ children: e = void 0, searchValue: t, filterCount: n, dataCount: r
|
|
|
13735
13736
|
})]
|
|
13736
13737
|
}), /* @__PURE__ */ b("tr", {
|
|
13737
13738
|
role: "header-row",
|
|
13738
|
-
className:
|
|
13739
|
-
children:
|
|
13739
|
+
className: u === "header" ? "is-sticky-row" : void 0,
|
|
13740
|
+
children: o.map((e, t) => {
|
|
13740
13741
|
if (e.hidden) return null;
|
|
13741
|
-
let n = e.sort !== void 0, r = Math.abs(
|
|
13742
|
+
let n = e.sort !== void 0, r = Math.abs(c) - 1 === t, i;
|
|
13742
13743
|
i = e.header || e.header === "" ? e.header : typeof e.value == "string" ? e.value : e.value.toString();
|
|
13743
13744
|
let a = `${cf(e.alignment ?? "l")} mx-0 px-1`, o = _s;
|
|
13744
|
-
return r &&
|
|
13745
|
+
return r && c > 0 ? o = qo : r && c < 0 && (o = Us), /* @__PURE__ */ x("th", {
|
|
13745
13746
|
role: "sort-col",
|
|
13746
13747
|
style: { cursor: n ? "pointer" : void 0 },
|
|
13747
13748
|
className: a,
|
|
13748
|
-
onClick: (e) =>
|
|
13749
|
+
onClick: (e) => _(e, t),
|
|
13749
13750
|
children: [n && /* @__PURE__ */ x("span", {
|
|
13750
13751
|
className: "icon-text mx-0 px-0",
|
|
13751
13752
|
role: "icon-with-text",
|