UNPKG

@atlaskit/table-tree

Version:

A table tree is an expandable table for showing nested hierarchies of information.

38 lines (35 loc) • 1.24 kB
/* header.tsx generated by @compiled/babel-plugin v3.0.2 */ import "./header.compiled.css"; import * as React from 'react'; import { ax, ix } from "@compiled/react/runtime"; import CommonCell from './internal/common-cell'; import withColumnWidth from './internal/with-column-width'; var headerStyles = null; /** * This is hard-coded here because our actual <Header /> has no typings * for its props. * * Adding types for real *might* break things so will need a little care. * * Defining it here for now lets us provide *something* without much headache. */ var HeaderComponent = function HeaderComponent(_ref) { var width = _ref.width, children = _ref.children, onClick = _ref.onClick, id = _ref.id, _ref$role = _ref.role, role = _ref$role === void 0 ? 'columnheader' : _ref$role; // TODO: Determine whether proper `th` elements can be used instead of // roles (DSP-11588) return /*#__PURE__*/React.createElement(CommonCell, { role: role, width: width, id: id, onClick: onClick, className: ax(["_11c8wadc _syazazsu _k48pwu06"]) }, children); }; var Header = withColumnWidth(HeaderComponent); // eslint-disable-next-line @repo/internal/react/require-jsdoc export default Header;