@primer/react
Version:
An implementation of GitHub's Primer Design System using React
48 lines (45 loc) • 1 kB
JavaScript
import { c } from 'react-compiler-runtime';
import classes from './_TokenTextContainer.module.css.js';
import { clsx } from 'clsx';
import { BoxWithFallback } from '../internal/components/BoxWithFallback.js';
import { jsx } from 'react/jsx-runtime';
const TokenTextContainer = t0 => {
const $ = c(7);
let children;
let props;
if ($[0] !== t0) {
({
children,
...props
} = t0);
$[0] = t0;
$[1] = children;
$[2] = props;
} else {
children = $[1];
props = $[2];
}
let t1;
if ($[3] === Symbol.for("react.memo_cache_sentinel")) {
t1 = clsx(classes.TokenTextContainer);
$[3] = t1;
} else {
t1 = $[3];
}
let t2;
if ($[4] !== children || $[5] !== props) {
t2 = /*#__PURE__*/jsx(BoxWithFallback, {
as: "span",
className: t1,
...props,
children: children
});
$[4] = children;
$[5] = props;
$[6] = t2;
} else {
t2 = $[6];
}
return t2;
};
export { TokenTextContainer as default };