@clickhouse/click-ui 0.0.232 → 0.0.234

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.
@@ -40244,7 +40244,9 @@ Defaulting to \`${$89eedd556c436f6a$var$DEFAULT_ORIENTATION}\`.`;
40244
40244
  `);
40245
40245
  const HeaderContentWrapper = styled.styled.div.withConfig({
40246
40246
  componentId: "sc-1q458rb-1"
40247
- })(["display:flex;align-items:center;justify-content:start;gap:inherit;"]);
40247
+ })(["display:flex;align-items:center;justify-content:start;gap:inherit;", ""], ({
40248
+ $interactive
40249
+ }) => $interactive && "cursor: pointer;");
40248
40250
  const SortIcon = styled.styled(SvgImage).withConfig({
40249
40251
  componentId: "sc-1q458rb-2"
40250
40252
  })(["transition:all 200ms;transform:rotate(", ");"], ({
@@ -40261,6 +40263,7 @@ Defaulting to \`${$89eedd556c436f6a$var$DEFAULT_ORIENTATION}\`.`;
40261
40263
  ...delegated
40262
40264
  }) => {
40263
40265
  const isSorted = typeof sortDir === "string";
40266
+ const isInteractive = Boolean(typeof onClick === "function" || isSortable && typeof onSort === "function");
40264
40267
  const onHeaderClick = (e) => {
40265
40268
  if (typeof onClick === "function") {
40266
40269
  onClick(e);
@@ -40269,7 +40272,7 @@ Defaulting to \`${$89eedd556c436f6a$var$DEFAULT_ORIENTATION}\`.`;
40269
40272
  onSort();
40270
40273
  }
40271
40274
  };
40272
- return /* @__PURE__ */ jsxRuntime.jsx(StyledHeader, { $size: size2, ...delegated, children: /* @__PURE__ */ jsxRuntime.jsxs(HeaderContentWrapper, { onClick: onHeaderClick, children: [
40275
+ return /* @__PURE__ */ jsxRuntime.jsx(StyledHeader, { $size: size2, ...delegated, children: /* @__PURE__ */ jsxRuntime.jsxs(HeaderContentWrapper, { onClick: onHeaderClick, $interactive: isInteractive, children: [
40273
40276
  isSorted && isSortable && sortPosition == "start" && /* @__PURE__ */ jsxRuntime.jsx(SortIcon, { $sortDir: sortDir, name: "arrow-down", size: "sm" }),
40274
40277
  label,
40275
40278
  isSorted && isSortable && sortPosition == "end" && /* @__PURE__ */ jsxRuntime.jsx(SortIcon, { $sortDir: sortDir, name: "arrow-down", size: "sm" })