import { jsx, jsxs } from "react/jsx-runtime";
import { IconChevronDown, IconChevronRight } from "../../../icons/index.mjs";
/* empty css                                                                                                                                                                                          */
/* empty css                                                                                                                                                                                           */
/* empty css                                                                                                                                                                                                   */
/* empty css                                                                                                                                                                                              */
/* empty css                                                                                                                                                                                              */
import { Box } from "../../../node_modules/.pnpm/@mantine_core@7.15.2_patch_hash_jclkxeaefn6uz54h34k3r3yjsq_@mantine_hooks@7.15.2_react@18.3.1_szqfuioo5damkjdixckhzmwycq/node_modules/@mantine/core/esm/core/Box/Box.mjs";
const renderExpandCell = ({ row, cell, ...rest }) => {
  const canExpand = row.getCanExpand();
  const value = cell.getValue();
  const paddingLeft = row.depth * 20;
  const icon = row.getIsExpanded() ? /* @__PURE__ */ jsx(IconChevronDown, { size: 18 }) : /* @__PURE__ */ jsx(IconChevronRight, { size: 18 });
  return /* @__PURE__ */ jsxs(
    Box,
    {
      sx: () => ({
        paddingLeft: canExpand ? paddingLeft : paddingLeft + 6,
        display: "flex",
        alignItems: "center",
        cursor: canExpand ? "pointer" : void 0
      }),
      onClick: row.getToggleExpandedHandler(),
      children: [
        canExpand && /* @__PURE__ */ jsx(Box, { sx: { display: "flex", alignItems: "center", marginRight: 8 }, children: icon }),
        value
      ]
    }
  );
};
export {
  renderExpandCell
};
