UNPKG

@atlaskit/menu

Version:

A list of options to help users navigate, or perform actions.

43 lines (42 loc) 1.64 kB
/* heading-item.tsx generated by @compiled/babel-plugin v0.36.1 */ import _extends from "@babel/runtime/helpers/extends"; import _objectWithoutProperties from "@babel/runtime/helpers/objectWithoutProperties"; var _excluded = ["children", "testId", "headingLevel", "id", "className"]; import "./heading-item.compiled.css"; import * as React from 'react'; import { ax, ix } from "@compiled/react/runtime"; import { memo } from 'react'; import { N300 } from '@atlaskit/theme/colors'; var headingStyles = null; /** * __Heading item__ * * A heading item is used to describe sibling menu items. * * - [Examples](https://atlaskit.atlassian.com/packages/design-system/menu/docs/heading-item) * - [Code](https://atlaskit.atlassian.com/packages/design-system/menu) */ var HeadingItem = /*#__PURE__*/memo(function (_ref) { var children = _ref.children, testId = _ref.testId, _ref$headingLevel = _ref.headingLevel, headingLevel = _ref$headingLevel === void 0 ? 2 : _ref$headingLevel, id = _ref.id, UNSAFE_className = _ref.className, rest = _objectWithoutProperties(_ref, _excluded); return /*#__PURE__*/React.createElement("div", _extends({ role: "heading", "aria-level": headingLevel, "data-testid": testId, "data-ds--menu--heading-item": true, id: id // eslint-disable-next-line @atlaskit/ui-styling-standard/no-classname-prop -- Ignored via go/DSP-18766 , className: ax(["_11c81vhk _1rjcze3t _18zrpxbi _syaz1vvm", UNSAFE_className]) }, rest, { style: { "--_bbz764": ix("var(--ds-text-subtle, ".concat(N300, ")")) } }), children); }); export default HeadingItem;