@allbluecn/admin-app 0.3.4 → 0.3.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +5 -5
- package/src/components/admin/admin-user-menu.tsx +4 -4
- package/src/components/admin/developer-log.tsx +7 -7
- package/src/components/ai-memory/memory-facts-panel.tsx +9 -9
- package/src/components/ai-prompts/preview-panel.tsx +1 -1
- package/src/components/ai-prompts/prompt-editor.tsx +8 -8
- package/src/components/ai-prompts/prompt-table.tsx +6 -6
- package/src/components/ai-prompts/section-editor.tsx +3 -3
- package/src/components/ai-prompts/variable-panel.tsx +2 -2
- package/src/components/ai-prompts/version-history.tsx +5 -5
- package/src/components/ai-provider/model-list-editor.tsx +2 -2
- package/src/components/ai-provider/provider-form.tsx +7 -7
- package/src/components/ai-provider/provider-table.tsx +6 -6
- package/src/components/auth/admin-login-form.tsx +6 -6
- package/src/components/auth/icon-input.tsx +2 -2
- package/src/components/auth/password-input.tsx +2 -2
- package/src/components/component/component-form-dialog.tsx +8 -8
- package/src/components/component/component-import-dialog.tsx +6 -6
- package/src/components/component/component-table.tsx +3 -3
- package/{allblue-ui/src → src}/components/confirm-dialog.tsx +2 -2
- package/src/components/dependency/changelog-dialog.tsx +2 -2
- package/src/components/dependency/columns.tsx +3 -3
- package/src/components/dependency/dependency-table.tsx +7 -7
- package/src/components/dependency/edit-dialog.tsx +8 -8
- package/src/components/invitations/invitations-page.tsx +13 -13
- package/src/components/knowledge-public/bookmark-form-dialog.tsx +6 -6
- package/src/components/knowledge-public/compliance-form-dialog.tsx +6 -6
- package/src/components/knowledge-public/legal-form-dialog.tsx +7 -7
- package/src/components/layout/sidebar-02/app-sidebar.tsx +1 -1
- package/src/components/layout/sidebar-02/index.tsx +1 -1
- package/src/components/layout/sidebar-02/nav-main.tsx +2 -2
- package/src/components/layout/sidebar-02/nav-notifications.tsx +3 -3
- package/src/components/market/columns.tsx +4 -4
- package/src/components/market/market-app-form.tsx +6 -6
- package/src/components/market/market-app-list.tsx +4 -4
- package/src/components/monitoring/error-list.tsx +1 -1
- package/src/components/monitoring/metrics-stats.tsx +1 -1
- package/src/components/monitoring/request-log-table.tsx +1 -1
- package/src/components/oauth-providers/provider-page.tsx +9 -9
- package/src/components/permissions/assign-dialog.tsx +5 -5
- package/src/components/permissions/create-role-dialog.tsx +6 -6
- package/{allblue-ui/src → src/components}/ui/sidebar.tsx +1 -1
- package/src/components/user/columns.tsx +4 -4
- package/src/components/user/settings-activity-log.tsx +7 -7
- package/src/components/user/settings-profile/avatar-uploader.tsx +2 -2
- package/src/components/user/settings-profile/social-links.tsx +2 -2
- package/src/components/user/settings-profile.tsx +6 -6
- package/src/components/user/user-create-dialog.tsx +6 -6
- package/src/components/user/user-detail/error-boundary.tsx +1 -1
- package/src/components/user/user-detail/user-detail-dialogs.tsx +6 -6
- package/src/components/user/user-filters.tsx +3 -3
- package/src/providers/index.tsx +1 -1
- package/src/routes/__root.tsx +1 -1
- package/src/routes/_nav/audit/route.lazy.tsx +1 -1
- package/src/routes/_nav/compliance/route.lazy.tsx +3 -3
- package/src/routes/_nav/components/route.lazy.tsx +4 -4
- package/src/routes/_nav/knowledge-public/bookmarks/route.lazy.tsx +6 -6
- package/src/routes/_nav/knowledge-public/compliance/route.lazy.tsx +6 -6
- package/src/routes/_nav/knowledge-public/legal/route.lazy.tsx +6 -6
- package/src/routes/_nav/licenses/$licenseId/route.lazy.tsx +3 -3
- package/src/routes/_nav/licenses/new/route.lazy.tsx +5 -5
- package/src/routes/_nav/licenses/route.lazy.tsx +1 -1
- package/src/routes/_nav/monitoring/ai-usage/route.lazy.tsx +2 -2
- package/src/routes/_nav/monitoring/errors/route.lazy.tsx +1 -1
- package/src/routes/_nav/monitoring/health/route.lazy.tsx +3 -3
- package/src/routes/_nav/monitoring/logs/route.lazy.tsx +3 -3
- package/src/routes/_nav/monitoring/metrics/route.lazy.tsx +3 -3
- package/src/routes/_nav/monitoring/route.lazy.tsx +2 -2
- package/src/routes/_nav/monitoring/sentry/route.lazy.tsx +1 -1
- package/src/routes/_nav/permissions/route.lazy.tsx +4 -4
- package/src/routes/_nav/sso/route.lazy.tsx +2 -2
- package/src/routes/_nav/users/$userId/route.lazy.tsx +8 -8
- package/src/routes/_nav/users/-components/users-table.tsx +1 -1
- package/src/routes/_nav/users/route.lazy.tsx +1 -1
- package/src/routes/setup/route.lazy.tsx +2 -2
- package/src/server/dependency/helpers.ts +0 -1
- package/src/styles/globals.css +3 -3
- package/allblue-ui/package.json +0 -6
- package/allblue-ui/src/components/infinite-scroll-sentinel.tsx +0 -37
- package/allblue-ui/src/hooks/use-load-more.ts +0 -57
- package/allblue-ui/src/index.ts +0 -31
- package/allblue-ui/src/lib/avatar.ts +0 -41
- package/allblue-ui/src/lib/utils.ts +0 -1
- /package/{allblue-ui/src → src/components}/data-table/data-table-pagination.tsx +0 -0
- /package/{allblue-ui/src → src/components}/data-table/data-table.tsx +0 -0
- /package/{allblue-ui/src → src/components}/data-table/table-detail-layout.tsx +0 -0
- /package/{allblue-ui/src → src}/components/notion-avatar.tsx +0 -0
- /package/{allblue-ui/src → src/components}/ui/alert-dialog.tsx +0 -0
- /package/{allblue-ui/src → src/components}/ui/alert.tsx +0 -0
- /package/{allblue-ui/src → src/components}/ui/avatar.tsx +0 -0
- /package/{allblue-ui/src → src/components}/ui/badge.tsx +0 -0
- /package/{allblue-ui/src → src/components}/ui/button.tsx +0 -0
- /package/{allblue-ui/src → src/components}/ui/card.tsx +0 -0
- /package/{allblue-ui/src → src/components}/ui/checkbox.tsx +0 -0
- /package/{allblue-ui/src → src/components}/ui/collapsible.tsx +0 -0
- /package/{allblue-ui/src → src/components}/ui/dialog.tsx +0 -0
- /package/{allblue-ui/src → src/components}/ui/dropdown-menu.tsx +0 -0
- /package/{allblue-ui/src → src/components}/ui/field.tsx +0 -0
- /package/{allblue-ui/src → src/components}/ui/input-group.tsx +0 -0
- /package/{allblue-ui/src → src/components}/ui/input.tsx +0 -0
- /package/{allblue-ui/src → src/components}/ui/label.tsx +0 -0
- /package/{allblue-ui/src → src/components}/ui/pagination.tsx +0 -0
- /package/{allblue-ui/src → src/components}/ui/select.tsx +0 -0
- /package/{allblue-ui/src → src/components}/ui/separator.tsx +0 -0
- /package/{allblue-ui/src → src/components}/ui/sheet.tsx +0 -0
- /package/{allblue-ui/src → src/components}/ui/skeleton.tsx +0 -0
- /package/{allblue-ui/src → src/components}/ui/switch.tsx +0 -0
- /package/{allblue-ui/src → src/components}/ui/table.tsx +0 -0
- /package/{allblue-ui/src → src/components}/ui/textarea.tsx +0 -0
- /package/{allblue-ui/src → src/components}/ui/toast.tsx +0 -0
- /package/{allblue-ui/src → src/components}/ui/tooltip.tsx +0 -0
- /package/{allblue-ui/src → src}/components/user-avatar.tsx +0 -0
- /package/{allblue-ui/src → src}/hooks/use-mobile.ts +0 -0
- /package/{allblue-ui/src → src}/lib/datetime.ts +0 -0
- /package/{allblue-ui/src → src}/lib/sanitize.ts +0 -0
|
@@ -17,18 +17,18 @@
|
|
|
17
17
|
|
|
18
18
|
import { useState, useEffect } from 'react'
|
|
19
19
|
import { Loader2 } from 'lucide-react'
|
|
20
|
-
import { toast } from '
|
|
21
|
-
import { Button } from '
|
|
22
|
-
import { Input } from '
|
|
23
|
-
import { Label } from '
|
|
24
|
-
import { Textarea } from '
|
|
20
|
+
import { toast } from '@/components/ui/toast'
|
|
21
|
+
import { Button } from '@/components/ui/button'
|
|
22
|
+
import { Input } from '@/components/ui/input'
|
|
23
|
+
import { Label } from '@/components/ui/label'
|
|
24
|
+
import { Textarea } from '@/components/ui/textarea'
|
|
25
25
|
import {
|
|
26
26
|
Dialog,
|
|
27
27
|
DialogContent,
|
|
28
28
|
DialogFooter,
|
|
29
29
|
DialogHeader,
|
|
30
30
|
DialogTitle,
|
|
31
|
-
} from '
|
|
31
|
+
} from '@/components/ui/dialog'
|
|
32
32
|
import { adminCreateBookmarkFn } from '@/server/serverFns/knowledge-public/bookmarks/create'
|
|
33
33
|
import { adminUpdateBookmarkFn } from '@/server/serverFns/knowledge-public/bookmarks/update'
|
|
34
34
|
import { adminGetBookmarkDetailFn } from '@/server/serverFns/knowledge-public/bookmarks/detail'
|
|
@@ -17,18 +17,18 @@
|
|
|
17
17
|
|
|
18
18
|
import { useState, useEffect } from 'react'
|
|
19
19
|
import { Loader2, PlusIcon, Trash2Icon } from 'lucide-react'
|
|
20
|
-
import { toast } from '
|
|
21
|
-
import { Button } from '
|
|
22
|
-
import { Input } from '
|
|
23
|
-
import { Label } from '
|
|
24
|
-
import { Textarea } from '
|
|
20
|
+
import { toast } from '@/components/ui/toast'
|
|
21
|
+
import { Button } from '@/components/ui/button'
|
|
22
|
+
import { Input } from '@/components/ui/input'
|
|
23
|
+
import { Label } from '@/components/ui/label'
|
|
24
|
+
import { Textarea } from '@/components/ui/textarea'
|
|
25
25
|
import {
|
|
26
26
|
Dialog,
|
|
27
27
|
DialogContent,
|
|
28
28
|
DialogFooter,
|
|
29
29
|
DialogHeader,
|
|
30
30
|
DialogTitle,
|
|
31
|
-
} from '
|
|
31
|
+
} from '@/components/ui/dialog'
|
|
32
32
|
import { adminCreateComplianceFn } from '@/server/serverFns/knowledge-public/compliance/create'
|
|
33
33
|
import { adminUpdateComplianceFn } from '@/server/serverFns/knowledge-public/compliance/update'
|
|
34
34
|
import { adminGetComplianceDetailFn } from '@/server/serverFns/knowledge-public/compliance/detail'
|
|
@@ -18,25 +18,25 @@
|
|
|
18
18
|
import { useState, useEffect } from 'react'
|
|
19
19
|
import { m } from '@/paraglide/messages.js'
|
|
20
20
|
import { Loader2 } from 'lucide-react'
|
|
21
|
-
import { toast } from '
|
|
22
|
-
import { Button } from '
|
|
23
|
-
import { Input } from '
|
|
24
|
-
import { Label } from '
|
|
25
|
-
import { Textarea } from '
|
|
21
|
+
import { toast } from '@/components/ui/toast'
|
|
22
|
+
import { Button } from '@/components/ui/button'
|
|
23
|
+
import { Input } from '@/components/ui/input'
|
|
24
|
+
import { Label } from '@/components/ui/label'
|
|
25
|
+
import { Textarea } from '@/components/ui/textarea'
|
|
26
26
|
import {
|
|
27
27
|
Select,
|
|
28
28
|
SelectContent,
|
|
29
29
|
SelectItem,
|
|
30
30
|
SelectTrigger,
|
|
31
31
|
SelectValue,
|
|
32
|
-
} from '
|
|
32
|
+
} from '@/components/ui/select'
|
|
33
33
|
import {
|
|
34
34
|
Dialog,
|
|
35
35
|
DialogContent,
|
|
36
36
|
DialogFooter,
|
|
37
37
|
DialogHeader,
|
|
38
38
|
DialogTitle,
|
|
39
|
-
} from '
|
|
39
|
+
} from '@/components/ui/dialog'
|
|
40
40
|
import { adminCreateLegalFn } from '@/server/serverFns/knowledge-public/legal/create'
|
|
41
41
|
import { adminUpdateLegalFn } from '@/server/serverFns/knowledge-public/legal/update'
|
|
42
42
|
import { adminGetLegalDetailFn } from '@/server/serverFns/knowledge-public/legal/detail'
|
|
@@ -16,7 +16,7 @@
|
|
|
16
16
|
// along with this program. If not, see <https://www.gnu.org/licenses/>.
|
|
17
17
|
|
|
18
18
|
import type { ReactNode } from "react"
|
|
19
|
-
import { SidebarInset, SidebarProvider } from "
|
|
19
|
+
import { SidebarInset, SidebarProvider } from "@/components/ui/sidebar";
|
|
20
20
|
import { DashboardSidebar } from "@/components/layout/sidebar-02/app-sidebar";
|
|
21
21
|
|
|
22
22
|
export default function Sidebar02({ children }: { children?: ReactNode }) {
|
|
@@ -19,7 +19,7 @@
|
|
|
19
19
|
import {
|
|
20
20
|
Collapsible,
|
|
21
21
|
CollapsibleContent,
|
|
22
|
-
} from "
|
|
22
|
+
} from "@/components/ui/collapsible";
|
|
23
23
|
import {
|
|
24
24
|
SidebarMenu,
|
|
25
25
|
SidebarMenuButton,
|
|
@@ -28,7 +28,7 @@ import {
|
|
|
28
28
|
SidebarMenuSubButton,
|
|
29
29
|
SidebarMenuItem as SidebarMenuSubItem,
|
|
30
30
|
useSidebar,
|
|
31
|
-
} from "
|
|
31
|
+
} from "@/components/ui/sidebar";
|
|
32
32
|
import { cn } from "@/lib/utils";
|
|
33
33
|
import { ChevronDown, ChevronUp } from "lucide-react";
|
|
34
34
|
import { Link } from "@tanstack/react-router";
|
|
@@ -16,8 +16,8 @@
|
|
|
16
16
|
// along with this program. If not, see <https://www.gnu.org/licenses/>.
|
|
17
17
|
|
|
18
18
|
|
|
19
|
-
import { Avatar, AvatarFallback, AvatarImage } from "
|
|
20
|
-
import { Button } from "
|
|
19
|
+
import { Avatar, AvatarFallback, AvatarImage } from "@/components/ui/avatar";
|
|
20
|
+
import { Button } from "@/components/ui/button";
|
|
21
21
|
import {
|
|
22
22
|
DropdownMenu,
|
|
23
23
|
DropdownMenuContent,
|
|
@@ -25,7 +25,7 @@ import {
|
|
|
25
25
|
DropdownMenuLabel,
|
|
26
26
|
DropdownMenuSeparator,
|
|
27
27
|
DropdownMenuTrigger,
|
|
28
|
-
} from "
|
|
28
|
+
} from "@/components/ui/dropdown-menu";
|
|
29
29
|
import { BellIcon } from "lucide-react";
|
|
30
30
|
|
|
31
31
|
type Notification = {
|
|
@@ -15,17 +15,17 @@
|
|
|
15
15
|
// You should have received a copy of the GNU Affero General Public License
|
|
16
16
|
// along with this program. If not, see <https://www.gnu.org/licenses/>.
|
|
17
17
|
|
|
18
|
-
import type { AdminColumnDef } from "
|
|
18
|
+
import type { AdminColumnDef } from "@/components/data-table/data-table";
|
|
19
19
|
import { m } from '@/paraglide/messages.js'
|
|
20
|
-
import { Badge } from "
|
|
21
|
-
import { Button } from "
|
|
20
|
+
import { Badge } from "@/components/ui/badge"
|
|
21
|
+
import { Button } from "@/components/ui/button"
|
|
22
22
|
import {
|
|
23
23
|
DropdownMenu,
|
|
24
24
|
DropdownMenuContent,
|
|
25
25
|
DropdownMenuItem,
|
|
26
26
|
DropdownMenuSeparator,
|
|
27
27
|
DropdownMenuTrigger,
|
|
28
|
-
} from "
|
|
28
|
+
} from "@/components/ui/dropdown-menu"
|
|
29
29
|
import { MoreHorizontalIcon, PencilIcon, TrashIcon, EyeIcon, EyeOffIcon } from "lucide-react"
|
|
30
30
|
|
|
31
31
|
export type MarketAppRow = {
|
|
@@ -25,18 +25,18 @@ import {
|
|
|
25
25
|
DialogFooter,
|
|
26
26
|
DialogHeader,
|
|
27
27
|
DialogTitle,
|
|
28
|
-
} from "
|
|
29
|
-
import { Button } from "
|
|
30
|
-
import { Input } from "
|
|
31
|
-
import { Label } from "
|
|
28
|
+
} from "@/components/ui/dialog"
|
|
29
|
+
import { Button } from "@/components/ui/button"
|
|
30
|
+
import { Input } from "@/components/ui/input"
|
|
31
|
+
import { Label } from "@/components/ui/label"
|
|
32
32
|
import {
|
|
33
33
|
Select,
|
|
34
34
|
SelectContent,
|
|
35
35
|
SelectItem,
|
|
36
36
|
SelectTrigger,
|
|
37
37
|
SelectValue,
|
|
38
|
-
} from "
|
|
39
|
-
import { toast } from '
|
|
38
|
+
} from "@/components/ui/select"
|
|
39
|
+
import { toast } from '@/components/ui/toast'
|
|
40
40
|
|
|
41
41
|
interface MarketAppFormProps {
|
|
42
42
|
open: boolean
|
|
@@ -17,15 +17,15 @@
|
|
|
17
17
|
|
|
18
18
|
import { useCallback, useEffect, useState } from "react"
|
|
19
19
|
import { m } from '@/paraglide/messages.js'
|
|
20
|
-
import { DataTable } from "
|
|
20
|
+
import { DataTable } from "@/components/data-table/data-table"
|
|
21
21
|
import { getMarketColumns, MarketAppRow } from "./columns"
|
|
22
22
|
import { MarketAppForm } from "./market-app-form"
|
|
23
23
|
import { MarketAppFormData } from "@/lib/anyhub/types"
|
|
24
|
-
import { Button } from "
|
|
24
|
+
import { Button } from "@/components/ui/button"
|
|
25
25
|
import { PlusIcon } from "lucide-react"
|
|
26
|
-
import { toast } from '
|
|
26
|
+
import { toast } from '@/components/ui/toast'
|
|
27
27
|
import { listMarketAppsFn, updateMarketAppFn, deleteMarketAppFn } from "@/server/serverFns/anyhub/market"
|
|
28
|
-
import { ConfirmDialog } from "
|
|
28
|
+
import { ConfirmDialog } from "@/components/confirm-dialog"
|
|
29
29
|
|
|
30
30
|
export function MarketAppList() {
|
|
31
31
|
const [apps, setApps] = useState<MarketAppRow[]>([])
|
|
@@ -17,7 +17,7 @@
|
|
|
17
17
|
|
|
18
18
|
import { useState } from 'react'
|
|
19
19
|
import { m } from '@/paraglide/messages.js'
|
|
20
|
-
import { DataTable, type AdminColumnDef } from '
|
|
20
|
+
import { DataTable, type AdminColumnDef } from '@/components/data-table/data-table'
|
|
21
21
|
|
|
22
22
|
function formatRelativeTime(dateStr: string): string {
|
|
23
23
|
const now = new Date()
|
|
@@ -15,7 +15,7 @@
|
|
|
15
15
|
// You should have received a copy of the GNU Affero General Public License
|
|
16
16
|
// along with this program. If not, see <https://www.gnu.org/licenses/>.
|
|
17
17
|
|
|
18
|
-
import { DataTable, type AdminColumnDef } from '
|
|
18
|
+
import { DataTable, type AdminColumnDef } from '@/components/data-table/data-table'
|
|
19
19
|
import { m } from '@/paraglide/messages.js'
|
|
20
20
|
import { describeMetric } from '@/lib/monitoring-descriptions'
|
|
21
21
|
import { getBenchmark, getBenchmarkSource, compareDuration } from '@/lib/monitoring-benchmarks'
|
|
@@ -17,7 +17,7 @@
|
|
|
17
17
|
|
|
18
18
|
import type React from 'react'
|
|
19
19
|
import { m } from '@/paraglide/messages.js'
|
|
20
|
-
import { DataTable, type AdminColumnDef } from '
|
|
20
|
+
import { DataTable, type AdminColumnDef } from '@/components/data-table/data-table'
|
|
21
21
|
import { describePath } from '@/lib/monitoring-descriptions'
|
|
22
22
|
import { getBenchmark, getBenchmarkSource, compareDuration } from '@/lib/monitoring-benchmarks'
|
|
23
23
|
import { ArrowDown, ArrowUp, Info } from 'lucide-react'
|
|
@@ -19,17 +19,17 @@ import { useEffect, useState } from 'react'
|
|
|
19
19
|
import type React from 'react'
|
|
20
20
|
import { m } from '@/paraglide/messages.js'
|
|
21
21
|
import { useMutation, useQuery, useQueryClient } from '@tanstack/react-query'
|
|
22
|
-
import { toast } from '
|
|
22
|
+
import { toast } from '@/components/ui/toast'
|
|
23
23
|
import { Eye, EyeOff, KeyRound, PlugZap, Save, Trash2 } from 'lucide-react'
|
|
24
24
|
import { PageHeader } from '@/components/common/page-header'
|
|
25
|
-
import { Button } from '
|
|
26
|
-
import { Badge } from '
|
|
27
|
-
import { Card, CardContent } from '
|
|
28
|
-
import { Input } from '
|
|
29
|
-
import { Label } from '
|
|
30
|
-
import { Switch } from '
|
|
31
|
-
import { Skeleton } from '
|
|
32
|
-
import { ConfirmDialog } from '
|
|
25
|
+
import { Button } from '@/components/ui/button'
|
|
26
|
+
import { Badge } from '@/components/ui/badge'
|
|
27
|
+
import { Card, CardContent } from '@/components/ui/card'
|
|
28
|
+
import { Input } from '@/components/ui/input'
|
|
29
|
+
import { Label } from '@/components/ui/label'
|
|
30
|
+
import { Switch } from '@/components/ui/switch'
|
|
31
|
+
import { Skeleton } from '@/components/ui/skeleton'
|
|
32
|
+
import { ConfirmDialog } from '@/components/confirm-dialog'
|
|
33
33
|
import {
|
|
34
34
|
deleteOAuthProviderFn,
|
|
35
35
|
listOAuthProvidersFn,
|
|
@@ -2,7 +2,7 @@ import { useEffect, useState } from 'react'
|
|
|
2
2
|
import type React from 'react'
|
|
3
3
|
import { m } from '@/paraglide/messages.js'
|
|
4
4
|
import { useServerFn } from '@tanstack/react-start'
|
|
5
|
-
import { toast } from '
|
|
5
|
+
import { toast } from '@/components/ui/toast'
|
|
6
6
|
import {
|
|
7
7
|
assignRoleFn,
|
|
8
8
|
unassignRoleFn,
|
|
@@ -15,9 +15,9 @@ import {
|
|
|
15
15
|
DialogFooter,
|
|
16
16
|
DialogHeader,
|
|
17
17
|
DialogTitle,
|
|
18
|
-
} from '
|
|
19
|
-
import { Button } from '
|
|
20
|
-
import { Input } from '
|
|
18
|
+
} from '@/components/ui/dialog'
|
|
19
|
+
import { Button } from '@/components/ui/button'
|
|
20
|
+
import { Input } from '@/components/ui/input'
|
|
21
21
|
import {
|
|
22
22
|
Table,
|
|
23
23
|
TableBody,
|
|
@@ -25,7 +25,7 @@ import {
|
|
|
25
25
|
TableHead,
|
|
26
26
|
TableHeader,
|
|
27
27
|
TableRow,
|
|
28
|
-
} from '
|
|
28
|
+
} from '@/components/ui/table'
|
|
29
29
|
import type { AssignmentItem, RoleItem } from './types'
|
|
30
30
|
|
|
31
31
|
export function AssignDialog({
|
|
@@ -2,7 +2,7 @@ import { useCallback, useEffect, useState } from 'react'
|
|
|
2
2
|
import type React from 'react'
|
|
3
3
|
import { m } from '@/paraglide/messages.js'
|
|
4
4
|
import { useServerFn } from '@tanstack/react-start'
|
|
5
|
-
import { toast } from '
|
|
5
|
+
import { toast } from '@/components/ui/toast'
|
|
6
6
|
import { createRoleFn } from '@/server/serverFns/permissions'
|
|
7
7
|
import {
|
|
8
8
|
Dialog,
|
|
@@ -11,17 +11,17 @@ import {
|
|
|
11
11
|
DialogFooter,
|
|
12
12
|
DialogHeader,
|
|
13
13
|
DialogTitle,
|
|
14
|
-
} from '
|
|
15
|
-
import { Button } from '
|
|
16
|
-
import { Input } from '
|
|
17
|
-
import { Label } from '
|
|
14
|
+
} from '@/components/ui/dialog'
|
|
15
|
+
import { Button } from '@/components/ui/button'
|
|
16
|
+
import { Input } from '@/components/ui/input'
|
|
17
|
+
import { Label } from '@/components/ui/label'
|
|
18
18
|
import {
|
|
19
19
|
Select,
|
|
20
20
|
SelectContent,
|
|
21
21
|
SelectItem,
|
|
22
22
|
SelectTrigger,
|
|
23
23
|
SelectValue,
|
|
24
|
-
} from '
|
|
24
|
+
} from '@/components/ui/select'
|
|
25
25
|
import { ALL_ACTIONS, ALL_RESOURCES, LEVELS, type ResourcePermission } from './types'
|
|
26
26
|
|
|
27
27
|
export function CreateRoleDialog({
|
|
@@ -4,7 +4,7 @@ import { useRender } from "@base-ui/react/use-render"
|
|
|
4
4
|
import { cva, type VariantProps } from "class-variance-authority"
|
|
5
5
|
import { cn } from "cn"
|
|
6
6
|
|
|
7
|
-
import { useIsMobile } from "
|
|
7
|
+
import { useIsMobile } from "@/hooks/use-mobile"
|
|
8
8
|
import { Button } from "./button"
|
|
9
9
|
import { Input } from "./input"
|
|
10
10
|
import { Separator } from "./separator"
|
|
@@ -16,12 +16,12 @@
|
|
|
16
16
|
// along with this program. If not, see <https://www.gnu.org/licenses/>.
|
|
17
17
|
|
|
18
18
|
|
|
19
|
-
import { Badge } from "
|
|
20
|
-
import { Button } from "
|
|
19
|
+
import { Badge } from "@/components/ui/badge";
|
|
20
|
+
import { Button } from "@/components/ui/button";
|
|
21
21
|
import { EyeIcon } from "lucide-react";
|
|
22
|
-
import { UserAvatar } from "
|
|
22
|
+
import { UserAvatar } from "@/components/user-avatar";
|
|
23
23
|
import type { AvatarConfig } from "@allbluecn/kernel";
|
|
24
|
-
import type { AdminColumnDef } from "
|
|
24
|
+
import type { AdminColumnDef } from "@/components/data-table/data-table";
|
|
25
25
|
|
|
26
26
|
export type UserRow = {
|
|
27
27
|
id: string;
|
|
@@ -26,28 +26,28 @@ import {
|
|
|
26
26
|
import { useState } from "react";
|
|
27
27
|
import { m } from '@/paraglide/messages.js'
|
|
28
28
|
import { cn } from "@/lib/utils";
|
|
29
|
-
import { Badge } from "
|
|
30
|
-
import { Button } from "
|
|
29
|
+
import { Badge } from "@/components/ui/badge";
|
|
30
|
+
import { Button } from "@/components/ui/button";
|
|
31
31
|
import {
|
|
32
32
|
Card,
|
|
33
33
|
CardContent,
|
|
34
34
|
CardDescription,
|
|
35
35
|
CardHeader,
|
|
36
36
|
CardTitle,
|
|
37
|
-
} from "
|
|
38
|
-
import { FieldLabel } from "
|
|
37
|
+
} from "@/components/ui/card";
|
|
38
|
+
import { FieldLabel } from "@/components/ui/field";
|
|
39
39
|
import {
|
|
40
40
|
InputGroup,
|
|
41
41
|
InputGroupInput,
|
|
42
|
-
} from "
|
|
42
|
+
} from "@/components/ui/input-group";
|
|
43
43
|
import {
|
|
44
44
|
Select,
|
|
45
45
|
SelectContent,
|
|
46
46
|
SelectItem,
|
|
47
47
|
SelectTrigger,
|
|
48
48
|
SelectValue,
|
|
49
|
-
} from "
|
|
50
|
-
import { Separator } from "
|
|
49
|
+
} from "@/components/ui/select";
|
|
50
|
+
import { Separator } from "@/components/ui/separator";
|
|
51
51
|
|
|
52
52
|
export interface ActivityLogEntry {
|
|
53
53
|
id: string;
|
|
@@ -2,8 +2,8 @@
|
|
|
2
2
|
|
|
3
3
|
import { Camera, Loader2, X } from "lucide-react";
|
|
4
4
|
import { cn } from "@/lib/utils";
|
|
5
|
-
import { FieldLabel } from "
|
|
6
|
-
import { Button } from "
|
|
5
|
+
import { FieldLabel } from "@/components/ui/field";
|
|
6
|
+
import { Button } from "@/components/ui/button";
|
|
7
7
|
|
|
8
8
|
/**
|
|
9
9
|
* 头像上传区(纯展示):预览/拖拽/进度态由父组件持有——errors 是父级
|
|
@@ -4,11 +4,11 @@ import {
|
|
|
4
4
|
Field,
|
|
5
5
|
FieldContent,
|
|
6
6
|
FieldLabel,
|
|
7
|
-
} from "
|
|
7
|
+
} from "@/components/ui/field";
|
|
8
8
|
import {
|
|
9
9
|
InputGroup,
|
|
10
10
|
InputGroupInput,
|
|
11
|
-
} from "
|
|
11
|
+
} from "@/components/ui/input-group";
|
|
12
12
|
import {
|
|
13
13
|
defaultSocialPlatforms,
|
|
14
14
|
socialPlatformLabels,
|
|
@@ -18,27 +18,27 @@
|
|
|
18
18
|
import { Loader2, Save } from "lucide-react";
|
|
19
19
|
import { useCallback, useRef, useState } from "react";
|
|
20
20
|
import { cn } from "@/lib/utils";
|
|
21
|
-
import { Button } from "
|
|
21
|
+
import { Button } from "@/components/ui/button";
|
|
22
22
|
import {
|
|
23
23
|
Card,
|
|
24
24
|
CardContent,
|
|
25
25
|
CardDescription,
|
|
26
26
|
CardHeader,
|
|
27
27
|
CardTitle,
|
|
28
|
-
} from "
|
|
28
|
+
} from "@/components/ui/card";
|
|
29
29
|
import {
|
|
30
30
|
Field,
|
|
31
31
|
FieldContent,
|
|
32
32
|
FieldDescription,
|
|
33
33
|
FieldError,
|
|
34
34
|
FieldLabel,
|
|
35
|
-
} from "
|
|
35
|
+
} from "@/components/ui/field";
|
|
36
36
|
import {
|
|
37
37
|
InputGroup,
|
|
38
38
|
InputGroupInput,
|
|
39
|
-
} from "
|
|
40
|
-
import { Separator } from "
|
|
41
|
-
import { Textarea } from "
|
|
39
|
+
} from "@/components/ui/input-group";
|
|
40
|
+
import { Separator } from "@/components/ui/separator";
|
|
41
|
+
import { Textarea } from "@/components/ui/textarea";
|
|
42
42
|
import { AvatarUploader } from "./settings-profile/avatar-uploader";
|
|
43
43
|
import { SocialLinks } from "./settings-profile/social-links";
|
|
44
44
|
import type {
|
|
@@ -23,19 +23,19 @@ import {
|
|
|
23
23
|
DialogHeader,
|
|
24
24
|
DialogTitle,
|
|
25
25
|
DialogFooter,
|
|
26
|
-
} from "
|
|
27
|
-
import { Button } from "
|
|
28
|
-
import { Input } from "
|
|
29
|
-
import { Label } from "
|
|
26
|
+
} from "@/components/ui/dialog";
|
|
27
|
+
import { Button } from "@/components/ui/button";
|
|
28
|
+
import { Input } from "@/components/ui/input";
|
|
29
|
+
import { Label } from "@/components/ui/label";
|
|
30
30
|
import {
|
|
31
31
|
Select,
|
|
32
32
|
SelectContent,
|
|
33
33
|
SelectItem,
|
|
34
34
|
SelectTrigger,
|
|
35
35
|
SelectValue,
|
|
36
|
-
} from "
|
|
36
|
+
} from "@/components/ui/select";
|
|
37
37
|
import { createUserFn } from "@/server/serverFns/user/create";
|
|
38
|
-
import { toast } from '
|
|
38
|
+
import { toast } from '@/components/ui/toast';
|
|
39
39
|
|
|
40
40
|
interface UserCreateDialogProps {
|
|
41
41
|
open: boolean;
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
import { m } from '@/paraglide/messages.js'
|
|
4
4
|
import { AlertCircle } from 'lucide-react'
|
|
5
|
-
import { Button } from '
|
|
5
|
+
import { Button } from '@/components/ui/button'
|
|
6
6
|
|
|
7
7
|
export function AdminUserErrorBoundary({ error, reset }: { error: unknown; reset: () => void }) {
|
|
8
8
|
return <AdminUserErrorBoundaryInner error={error instanceof Error ? error : new Error(String(error))} reset={reset} />
|
|
@@ -7,7 +7,7 @@ import {
|
|
|
7
7
|
DialogFooter,
|
|
8
8
|
DialogHeader,
|
|
9
9
|
DialogTitle,
|
|
10
|
-
} from '
|
|
10
|
+
} from '@/components/ui/dialog'
|
|
11
11
|
import {
|
|
12
12
|
AlertDialog,
|
|
13
13
|
AlertDialogAction,
|
|
@@ -17,17 +17,17 @@ import {
|
|
|
17
17
|
AlertDialogFooter,
|
|
18
18
|
AlertDialogHeader,
|
|
19
19
|
AlertDialogTitle,
|
|
20
|
-
} from '
|
|
20
|
+
} from '@/components/ui/alert-dialog'
|
|
21
21
|
import {
|
|
22
22
|
Select,
|
|
23
23
|
SelectContent,
|
|
24
24
|
SelectItem,
|
|
25
25
|
SelectTrigger,
|
|
26
26
|
SelectValue,
|
|
27
|
-
} from '
|
|
28
|
-
import { Input } from '
|
|
29
|
-
import { Label } from '
|
|
30
|
-
import { Button } from '
|
|
27
|
+
} from '@/components/ui/select'
|
|
28
|
+
import { Input } from '@/components/ui/input'
|
|
29
|
+
import { Label } from '@/components/ui/label'
|
|
30
|
+
import { Button } from '@/components/ui/button'
|
|
31
31
|
|
|
32
32
|
export type UserDialogState = { open: boolean; value: string }
|
|
33
33
|
export type UserDeleteDialogState = { open: boolean; confirmName: string }
|
|
@@ -18,15 +18,15 @@
|
|
|
18
18
|
import { useNavigate } from "@tanstack/react-router";
|
|
19
19
|
import { m } from '@/paraglide/messages.js'
|
|
20
20
|
import { useCallback } from "react";
|
|
21
|
-
import { Input } from "
|
|
22
|
-
import { Button } from "
|
|
21
|
+
import { Input } from "@/components/ui/input";
|
|
22
|
+
import { Button } from "@/components/ui/button";
|
|
23
23
|
import {
|
|
24
24
|
Select,
|
|
25
25
|
SelectContent,
|
|
26
26
|
SelectItem,
|
|
27
27
|
SelectTrigger,
|
|
28
28
|
SelectValue,
|
|
29
|
-
} from "
|
|
29
|
+
} from "@/components/ui/select";
|
|
30
30
|
import { SearchIcon, XIcon } from "lucide-react";
|
|
31
31
|
|
|
32
32
|
interface UserFiltersProps {
|
package/src/providers/index.tsx
CHANGED
|
@@ -18,7 +18,7 @@
|
|
|
18
18
|
|
|
19
19
|
import { ThemeProvider } from "next-themes";
|
|
20
20
|
import { type ReactNode } from "react";
|
|
21
|
-
import { TooltipProvider } from "
|
|
21
|
+
import { TooltipProvider } from "@/components/ui/tooltip";
|
|
22
22
|
|
|
23
23
|
export function Providers({
|
|
24
24
|
children,
|
package/src/routes/__root.tsx
CHANGED
|
@@ -21,7 +21,7 @@ import globalsCss from '../styles/globals.css?url'
|
|
|
21
21
|
import type { RouterContext } from '@/lib/router-context'
|
|
22
22
|
import type { AppLocale } from '@/lib/i18n/config'
|
|
23
23
|
import { Providers } from '@/providers'
|
|
24
|
-
import { Toaster } from '
|
|
24
|
+
import { Toaster } from '@/components/ui/toast'
|
|
25
25
|
import { getSessionFn } from '@/server/serverFns/auth/session'
|
|
26
26
|
import { getLocaleFn } from '@/server/serverFns/locale'
|
|
27
27
|
import { reportClientError } from '@/server/serverFns/monitoring/report-error'
|
|
@@ -18,7 +18,7 @@
|
|
|
18
18
|
import { createLazyFileRoute } from '@tanstack/react-router'
|
|
19
19
|
import { m } from '@/paraglide/messages.js'
|
|
20
20
|
import type React from 'react'
|
|
21
|
-
import { Badge } from '
|
|
21
|
+
import { Badge } from '@/components/ui/badge'
|
|
22
22
|
|
|
23
23
|
export const Route = createLazyFileRoute('/_nav/audit')({
|
|
24
24
|
pendingComponent: () => (
|
|
@@ -19,11 +19,11 @@ import { createLazyFileRoute } from '@tanstack/react-router'
|
|
|
19
19
|
import { m } from '@/paraglide/messages.js'
|
|
20
20
|
import { useQuery, useQueryClient } from '@tanstack/react-query'
|
|
21
21
|
import { useServerFn } from '@tanstack/react-start'
|
|
22
|
-
import { toast } from '
|
|
22
|
+
import { toast } from '@/components/ui/toast'
|
|
23
23
|
import type React from 'react'
|
|
24
24
|
import { listComplianceExportsFn, executeComplianceJobFn } from '@/server/serverFns/compliance'
|
|
25
|
-
import { Badge } from '
|
|
26
|
-
import { Button } from '
|
|
25
|
+
import { Badge } from '@/components/ui/badge'
|
|
26
|
+
import { Button } from '@/components/ui/button'
|
|
27
27
|
import { Loader2 } from 'lucide-react'
|
|
28
28
|
|
|
29
29
|
export const Route = createLazyFileRoute('/_nav/compliance')({
|
|
@@ -18,15 +18,15 @@
|
|
|
18
18
|
import { useState } from 'react'
|
|
19
19
|
import { createLazyFileRoute, useNavigate, useRouter } from '@tanstack/react-router'
|
|
20
20
|
import { Plus, Search, Download } from 'lucide-react'
|
|
21
|
-
import { Button } from '
|
|
22
|
-
import { Input } from '
|
|
23
|
-
import { ConfirmDialog } from '
|
|
21
|
+
import { Button } from '@/components/ui/button'
|
|
22
|
+
import { Input } from '@/components/ui/input'
|
|
23
|
+
import { ConfirmDialog } from '@/components/confirm-dialog'
|
|
24
24
|
import { cn } from '@/lib/utils'
|
|
25
25
|
import { ComponentTable, type ComponentItem } from '@/components/component/component-table'
|
|
26
26
|
import { ComponentFormDialog } from '@/components/component/component-form-dialog'
|
|
27
27
|
import { ComponentImportDialog } from '@/components/component/component-import-dialog'
|
|
28
28
|
import { deleteComponentFn } from '@/server/serverFns/components/mutations'
|
|
29
|
-
import { toast } from '
|
|
29
|
+
import { toast } from '@/components/ui/toast'
|
|
30
30
|
|
|
31
31
|
const CATEGORY_TABS = [
|
|
32
32
|
{ key: 'all', label: '全部' },
|