Open-source and local-first Slack and Notion alternative that puts you in control of your data
TypeScript chatchat-applicationcrdteditorelectronknowledge-baselocal-firstnotionnotion-alternativerealtime-collaborationself-hostedslacksqliteteam-collaborationwikiyjs
import { LocalPageNode } from '@colanode/client/types';
import { NodeRole, hasNodeRole } from '@colanode/core';
import { Document } from '@colanode/ui/components/documents/document';
interface PageContainerProps {
page: LocalPageNode;
role: NodeRole;
}
export const PageContainer = ({ page, role }: PageContainerProps) => {
const canEdit = hasNodeRole(role, 'editor');
return <Document node={page} canEdit={canEdit} autoFocus="start" />;
};