@bouku/core 0.4.3 → 0.4.4

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.
@@ -4,8 +4,8 @@ import { Fragment } from "react";
4
4
  import { RowBox } from "../container/flex.js";
5
5
  import { CheckBox } from "../miscellaneous/checkbox/index.js";
6
6
  import { cn } from "../../utils/functions/style.js";
7
- import ArrowUp from "../static/icons/arrow-up.svg";
8
- import ArrowDown from "../static/icons/arrow-down.svg";
7
+ import ArrowUp from "../../assets/icons/arrow-up.svg";
8
+ import ArrowDown from "../../assets/icons/arrow-down.svg";
9
9
  export const Header = ({ columnLabels, sortColumn, sortDirection, hasActions, sortBy, toggleSortDirection, selection }) => (_jsxs(RowBox, { style: s.container, children: [selection && (_jsx(RowBox, { style: s.selection, children: _jsx(CheckBox, { size: "sm", value: selection.allSelected, update: selection.toggleAll }) })), Object.entries(columnLabels).map(([col, label], i) => (_jsxs(RowBox, { style: cn(s.column, i === 0 && "justify-start"), children: [_jsx("span", { className: s.label, onClick: () => sortBy(col), children: label }), col === sortColumn && (_jsxs(Fragment, { children: [sortDirection === "desc" && _jsx(ArrowDown, { className: s.sorter, onClick: () => toggleSortDirection() }), sortDirection === "asc" && _jsx(ArrowUp, { className: s.sorter, onClick: () => toggleSortDirection() })] }))] }, i))), hasActions && (_jsx(RowBox, { style: s.column, children: _jsx("span", { children: "Actions" }) }))] }));
10
10
  const s = {
11
11
  container: "w-full px-4 h-11 shrink-0 bg-background-light border-b border-border",
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@bouku/core",
3
- "version": "0.4.3",
3
+ "version": "0.4.4",
4
4
  "main": "./dist/index.js",
5
5
  "type": "module",
6
6
  "types": "./dist/index.d.ts",