@atlaskit/page-header
Version:
A page header defines the top of a page. It contains a title and can be optionally combined with breadcrumbs buttons, search, and filters.
33 lines (32 loc) • 1.94 kB
JavaScript
/* title-container.tsx generated by @compiled/babel-plugin v3.0.2 */
// TODO: Remove this eslint-disable when prop names have been renamed.
// This rule is here as prop name changes are a major as they are used
// by our consumers. The prop name concerned here is truncateTitle.
// This can be done in the next lite-mode conversion.
/* eslint-disable @repo/internal/react/boolean-prop-naming-convention */
;
var _typeof = require("@babel/runtime/helpers/typeof");
Object.defineProperty(exports, "__esModule", {
value: true
});
exports.default = void 0;
require("./title-container.compiled.css");
var React = _interopRequireWildcard(require("react"));
var _runtime = require("@compiled/react/runtime");
function _interopRequireWildcard(e, t) { if ("function" == typeof WeakMap) var r = new WeakMap(), n = new WeakMap(); return (_interopRequireWildcard = function _interopRequireWildcard(e, t) { if (!t && e && e.__esModule) return e; var o, i, f = { __proto__: null, default: e }; if (null === e || "object" != _typeof(e) && "function" != typeof e) return f; if (o = t ? n : r) { if (o.has(e)) return o.get(e); o.set(e, f); } for (var _t in e) "default" !== _t && {}.hasOwnProperty.call(e, _t) && ((i = (o = Object.defineProperty) && Object.getOwnPropertyDescriptor(e, _t)) && (i.get || i.set) ? o(f, _t, i) : f[_t] = e[_t]); return f; })(e, t); }
var titleContainerStyles = null;
var titleContainerTruncateStyles = null;
/**
* Title container.
*
* A title container is a container that wraps around the title and its styles (if applied).
*
*/
var TitleContainer = function TitleContainer(_ref) {
var children = _ref.children,
truncateTitle = _ref.truncateTitle;
return /*#__PURE__*/React.createElement("div", {
className: (0, _runtime.ax)(["_16jlkb7n _1o9zkb7n _i0dl1wug _1ul9idpf _p12f1osq _6rthu2gc _1i4q1hna", truncateTitle && "_1o9zkb7n"])
}, children);
};
var _default = exports.default = TitleContainer;