@atlaskit/navigation-system
Version:
The latest navigation system for Atlassian apps.
29 lines • 1.16 kB
JavaScript
/* custom-title.tsx generated by @compiled/babel-plugin v3.0.2 */
import "./custom-title.compiled.css";
import * as React from 'react';
import { ax, ix } from "@compiled/react/runtime";
import { forwardRef } from 'react';
import { fg } from '@atlaskit/platform-feature-flags/fg';
import { useHasCustomTheme } from './themed/has-custom-theme-context';
var styles = {
root: "_1reo15vq _18m915vq _11c8fhey _o5721q9c _p12fuuw1 _1bto1l2s _bozg1b66 _y4tiu2gc _1e0cglyw",
subtleText: "_syazazsu",
container: "_1e0c1u4u _dm251vcx",
viewport: "_10y41txw"
};
/**
* __Custom title__
*
* A custom site title to be displayed in the top navigation, to the right of the logo.
* It is hidden on smaller viewports.
*/
export var CustomTitle = /*#__PURE__*/forwardRef(function CustomTitle(_ref, ref) {
var children = _ref.children,
testId = _ref.testId;
var hasCustomTheme = useHasCustomTheme();
return /*#__PURE__*/React.createElement("div", {
ref: ref,
"data-testid": testId,
className: ax([styles.root, fg('platform-dst-chat-panel-layout') ? styles.container : styles.viewport, !hasCustomTheme && styles.subtleText])
}, children);
});