@liveblocks/react-ui
Version:
A set of React pre-built components for the Liveblocks products. Liveblocks is the all-in-one toolkit to build collaborative products like Figma, Notion, and more.
27 lines (22 loc) • 623 B
JavaScript
"use client";
;
var jsxRuntime = require('react/jsx-runtime');
var react = require('@liveblocks/react');
var cn = require('../../utils/cn.cjs');
function Group({ groupId, className, children, ...props }) {
const { info, isLoading } = react.useGroupInfo(groupId);
return /* @__PURE__ */ jsxRuntime.jsxs(
"span",
{
className: cn.cn("lb-name lb-group", className),
"data-loading": isLoading ? "" : void 0,
...props,
children: [
isLoading ? null : info?.name ?? groupId,
children
]
}
);
}
exports.Group = Group;
//# sourceMappingURL=Group.cjs.map