UNPKG

@intility/bifrost-react

Version:

React library for Intility's design system, Bifrost.

65 lines 1.44 kB
import { c as _c } from "react-compiler-runtime"; import { forwardRef } from "react"; import classNames from "classnames"; import accessibleOnClick from "../../utils/accessibleOnClick.js"; import { jsx as _jsx } from "react/jsx-runtime"; const TableCell = /*#__PURE__*/forwardRef((t0, ref) => { const $ = _c(15); let t1; let t2; let t3; let t4; if ($[0] !== ref || $[1] !== t0) { const { className, onClick, rightBorder, ...props } = t0; if ($[6] !== className || $[7] !== onClick || $[8] !== rightBorder) { t1 = classNames(className, { "bf-table-cell-clickable": onClick, "bf-table-cell-right-border": rightBorder }); $[6] = className; $[7] = onClick; $[8] = rightBorder; $[9] = t1; } else { t1 = $[9]; } t2 = ref; t3 = props; t4 = accessibleOnClick(props, onClick); $[0] = ref; $[1] = t0; $[2] = t1; $[3] = t2; $[4] = t3; $[5] = t4; } else { t1 = $[2]; t2 = $[3]; t3 = $[4]; t4 = $[5]; } let t5; if ($[10] !== t1 || $[11] !== t2 || $[12] !== t3 || $[13] !== t4) { t5 = /*#__PURE__*/_jsx("td", { className: t1, ref: t2, ...t3, ...t4 }); $[10] = t1; $[11] = t2; $[12] = t3; $[13] = t4; $[14] = t5; } else { t5 = $[14]; } return t5; }); TableCell.displayName = "Table.Cell"; export default TableCell;