UI tweaks
This commit is contained in:
parent
68842dbea2
commit
628b08339a
5 changed files with 88 additions and 42 deletions
|
|
@ -116,6 +116,7 @@
|
||||||
"No group found": "No group found",
|
"No group found": "No group found",
|
||||||
"No page history saved yet.": "No page history saved yet.",
|
"No page history saved yet.": "No page history saved yet.",
|
||||||
"No pages yet": "No pages yet",
|
"No pages yet": "No pages yet",
|
||||||
|
"No shared pages": "No shared pages",
|
||||||
"No results found...": "No results found...",
|
"No results found...": "No results found...",
|
||||||
"No user found": "No user found",
|
"No user found": "No user found",
|
||||||
"Overview": "Overview",
|
"Overview": "Overview",
|
||||||
|
|
|
||||||
|
|
@ -1,8 +1,24 @@
|
||||||
import { Group, Table, ThemeIcon } from "@mantine/core";
|
import { Group, List, Stack, Table, Text, ThemeIcon } from "@mantine/core";
|
||||||
import { IconCheck } from "@tabler/icons-react";
|
import { IconCheck } from "@tabler/icons-react";
|
||||||
|
|
||||||
|
const enterpriseFeatures = [
|
||||||
|
"SSO (SAML, OIDC, LDAP)",
|
||||||
|
"Multi-factor Authentication",
|
||||||
|
"Page-level Permissions",
|
||||||
|
"Audit Logs",
|
||||||
|
"API Keys",
|
||||||
|
"AI Integration",
|
||||||
|
"MCP Support",
|
||||||
|
"Advanced Search Engine Support",
|
||||||
|
"Full-text Search in Attachments (PDF, DOCX)",
|
||||||
|
"Resolve Comments",
|
||||||
|
"Confluence Import",
|
||||||
|
"DOCX Import",
|
||||||
|
];
|
||||||
|
|
||||||
export default function OssDetails() {
|
export default function OssDetails() {
|
||||||
return (
|
return (
|
||||||
|
<Stack gap="lg">
|
||||||
<Table.ScrollContainer minWidth={500} py="md">
|
<Table.ScrollContainer minWidth={500} py="md">
|
||||||
<Table
|
<Table
|
||||||
variant="vertical"
|
variant="vertical"
|
||||||
|
|
@ -10,9 +26,6 @@ export default function OssDetails() {
|
||||||
layout="fixed"
|
layout="fixed"
|
||||||
withTableBorder
|
withTableBorder
|
||||||
>
|
>
|
||||||
<Table.Caption>
|
|
||||||
To unlock enterprise features like SSO, AI, Page-level permissions, SSO, MFA, Resolve comments, contact sales@docmost.com.
|
|
||||||
</Table.Caption>
|
|
||||||
<Table.Tbody>
|
<Table.Tbody>
|
||||||
<Table.Tr>
|
<Table.Tr>
|
||||||
<Table.Th w={160}>Edition</Table.Th>
|
<Table.Th w={160}>Edition</Table.Th>
|
||||||
|
|
@ -35,5 +48,29 @@ export default function OssDetails() {
|
||||||
</Table.Tbody>
|
</Table.Tbody>
|
||||||
</Table>
|
</Table>
|
||||||
</Table.ScrollContainer>
|
</Table.ScrollContainer>
|
||||||
|
|
||||||
|
<Stack gap="md">
|
||||||
|
<Text fw={500}>Upgrade to the Enterprise Edition to unlock:</Text>
|
||||||
|
|
||||||
|
<List
|
||||||
|
spacing={4}
|
||||||
|
size="sm"
|
||||||
|
icon={
|
||||||
|
<ThemeIcon size={20} color={"gray"} radius="xl">
|
||||||
|
<IconCheck size={14} />
|
||||||
|
</ThemeIcon>
|
||||||
|
}
|
||||||
|
>
|
||||||
|
{enterpriseFeatures.map((feature) => (
|
||||||
|
<List.Item key={feature}>{feature}</List.Item>
|
||||||
|
))}
|
||||||
|
</List>
|
||||||
|
|
||||||
|
<Text size="sm" c="dimmed">
|
||||||
|
Contact <a href="mailto:sales@docmost.com">sales@docmost.com </a> for
|
||||||
|
enquiries.
|
||||||
|
</Text>
|
||||||
|
</Stack>
|
||||||
|
</Stack>
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -25,7 +25,6 @@ import { usePageQuery } from "@/features/page/queries/page-query.ts";
|
||||||
import { IPagination } from "@/lib/types.ts";
|
import { IPagination } from "@/lib/types.ts";
|
||||||
import { extractPageSlugId } from "@/lib";
|
import { extractPageSlugId } from "@/lib";
|
||||||
import { useTranslation } from "react-i18next";
|
import { useTranslation } from "react-i18next";
|
||||||
import { useIsCloudEE } from "@/hooks/use-is-cloud-ee";
|
|
||||||
import { useGetSpaceBySlugQuery } from "@/features/space/queries/space-query.ts";
|
import { useGetSpaceBySlugQuery } from "@/features/space/queries/space-query.ts";
|
||||||
import { IconArrowUp, IconMessageOff } from "@tabler/icons-react";
|
import { IconArrowUp, IconMessageOff } from "@tabler/icons-react";
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -2,6 +2,7 @@ import { Table, Group, Text, Anchor } from "@mantine/core";
|
||||||
import React from "react";
|
import React from "react";
|
||||||
import { Link } from "react-router-dom";
|
import { Link } from "react-router-dom";
|
||||||
import { useTranslation } from "react-i18next";
|
import { useTranslation } from "react-i18next";
|
||||||
|
import { IconWorld } from "@tabler/icons-react";
|
||||||
import Paginate from "@/components/common/paginate.tsx";
|
import Paginate from "@/components/common/paginate.tsx";
|
||||||
import { useCursorPaginate } from "@/hooks/use-cursor-paginate";
|
import { useCursorPaginate } from "@/hooks/use-cursor-paginate";
|
||||||
import { useGetSharesQuery } from "@/features/share/queries/share-query.ts";
|
import { useGetSharesQuery } from "@/features/share/queries/share-query.ts";
|
||||||
|
|
@ -11,6 +12,7 @@ import ShareActionMenu from "@/features/share/components/share-action-menu.tsx";
|
||||||
import { buildSharedPageUrl } from "@/features/page/page.utils.ts";
|
import { buildSharedPageUrl } from "@/features/page/page.utils.ts";
|
||||||
import { getPageIcon } from "@/lib";
|
import { getPageIcon } from "@/lib";
|
||||||
import { CustomAvatar } from "@/components/ui/custom-avatar.tsx";
|
import { CustomAvatar } from "@/components/ui/custom-avatar.tsx";
|
||||||
|
import { EmptyState } from "@/components/ui/empty-state.tsx";
|
||||||
import classes from "./share.module.css";
|
import classes from "./share.module.css";
|
||||||
|
|
||||||
export default function ShareList() {
|
export default function ShareList() {
|
||||||
|
|
@ -18,6 +20,10 @@ export default function ShareList() {
|
||||||
const { cursor, goNext, goPrev } = useCursorPaginate();
|
const { cursor, goNext, goPrev } = useCursorPaginate();
|
||||||
const { data, isLoading } = useGetSharesQuery({ cursor });
|
const { data, isLoading } = useGetSharesQuery({ cursor });
|
||||||
|
|
||||||
|
if (!isLoading && data?.items.length === 0) {
|
||||||
|
return <EmptyState icon={IconWorld} title={t("No shared pages")} />;
|
||||||
|
}
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<>
|
<>
|
||||||
<Table.ScrollContainer minWidth={500}>
|
<Table.ScrollContainer minWidth={500}>
|
||||||
|
|
|
||||||
|
|
@ -94,14 +94,17 @@ export default function WorkspaceMembersTable() {
|
||||||
)}
|
)}
|
||||||
</Table.Td>
|
</Table.Td>
|
||||||
<Table.Td>
|
<Table.Td>
|
||||||
|
{isAdmin ? (
|
||||||
<RoleSelectMenu
|
<RoleSelectMenu
|
||||||
roles={assignableUserRoles}
|
roles={assignableUserRoles}
|
||||||
roleName={getUserRoleLabel(user.role)}
|
roleName={getUserRoleLabel(user.role)}
|
||||||
onChange={(newRole) =>
|
onChange={(newRole) =>
|
||||||
handleRoleChange(user.id, user.role, newRole)
|
handleRoleChange(user.id, user.role, newRole)
|
||||||
}
|
}
|
||||||
disabled={!isAdmin}
|
|
||||||
/>
|
/>
|
||||||
|
) : (
|
||||||
|
<Text fz="sm">{t(getUserRoleLabel(user.role))}</Text>
|
||||||
|
)}
|
||||||
</Table.Td>
|
</Table.Td>
|
||||||
<Table.Td>
|
<Table.Td>
|
||||||
{isAdmin && (
|
{isAdmin && (
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue