mirror of
https://github.com/zhom/donutbrowser.git
synced 2026-04-22 11:56:22 +02:00
style: adjust modal height
This commit is contained in:
Vendored
+5
@@ -17,6 +17,7 @@
|
||||
"cmdk",
|
||||
"codegen",
|
||||
"CTYPE",
|
||||
"datareporting",
|
||||
"devedition",
|
||||
"doesn",
|
||||
"donutbrowser",
|
||||
@@ -32,12 +33,14 @@
|
||||
"gettimezone",
|
||||
"gifs",
|
||||
"gsettings",
|
||||
"healthreport",
|
||||
"hkcu",
|
||||
"icns",
|
||||
"idletime",
|
||||
"Inno",
|
||||
"KHTML",
|
||||
"launchservices",
|
||||
"letterboxing",
|
||||
"libatk",
|
||||
"libayatana",
|
||||
"libcairo",
|
||||
@@ -63,6 +66,7 @@
|
||||
"objc",
|
||||
"orhun",
|
||||
"osascript",
|
||||
"peerconnection",
|
||||
"pixbuf",
|
||||
"plasmohq",
|
||||
"prefs",
|
||||
@@ -94,6 +98,7 @@
|
||||
"timedatectl",
|
||||
"titlebar",
|
||||
"Torbrowser",
|
||||
"trackingprotection",
|
||||
"turbopack",
|
||||
"udeps",
|
||||
"unlisten",
|
||||
|
||||
@@ -140,7 +140,7 @@ export function CamoufoxConfigDialog({
|
||||
</DialogTitle>
|
||||
</DialogHeader>
|
||||
|
||||
<ScrollArea className="flex-1 pr-6 h-[350px]">
|
||||
<ScrollArea className="flex-1 pr-6 h-[320px]">
|
||||
<div className="py-4 space-y-6">
|
||||
{/* Operating System */}
|
||||
<div className="space-y-3">
|
||||
|
||||
@@ -25,7 +25,7 @@ import {
|
||||
} from "@/components/ui/select";
|
||||
import { Tabs, TabsContent, TabsList, TabsTrigger } from "@/components/ui/tabs";
|
||||
import { useBrowserDownload } from "@/hooks/use-browser-download";
|
||||
import { getBrowserIcon } from "@/lib/browser-utils";
|
||||
import { getBrowserIcon, getCurrentOS } from "@/lib/browser-utils";
|
||||
import type { BrowserReleaseTypes, CamoufoxConfig, StoredProxy } from "@/types";
|
||||
|
||||
type BrowserTypeString =
|
||||
@@ -95,16 +95,6 @@ const browserOptions: BrowserOption[] = [
|
||||
},
|
||||
];
|
||||
|
||||
const getCurrentOS = () => {
|
||||
if (typeof window !== "undefined") {
|
||||
const userAgent = window.navigator.userAgent;
|
||||
if (userAgent.includes("Win")) return "windows";
|
||||
if (userAgent.includes("Mac")) return "macos";
|
||||
if (userAgent.includes("Linux")) return "linux";
|
||||
}
|
||||
return "unknown";
|
||||
};
|
||||
|
||||
export function CreateProfileDialog({
|
||||
isOpen,
|
||||
onClose,
|
||||
@@ -325,7 +315,7 @@ export function CreateProfileDialog({
|
||||
<TabsTrigger value="anti-detect">Anti-Detect</TabsTrigger>
|
||||
</TabsList>
|
||||
|
||||
<ScrollArea className="flex-1 pr-6 h-[350px]">
|
||||
<ScrollArea className="flex-1 pr-6 h-[320px]">
|
||||
<div className="py-4 space-y-6">
|
||||
{/* Profile Name - Common to both tabs */}
|
||||
<div className="space-y-2">
|
||||
|
||||
@@ -45,7 +45,12 @@ import {
|
||||
TooltipTrigger,
|
||||
} from "@/components/ui/tooltip";
|
||||
import { useTableSorting } from "@/hooks/use-table-sorting";
|
||||
import { getBrowserDisplayName, getBrowserIcon } from "@/lib/browser-utils";
|
||||
import {
|
||||
getBrowserDisplayName,
|
||||
getBrowserIcon,
|
||||
getCurrentOS,
|
||||
} from "@/lib/browser-utils";
|
||||
import { cn } from "@/lib/utils";
|
||||
import type { BrowserProfile, StoredProxy } from "@/types";
|
||||
import { Input } from "./ui/input";
|
||||
import { Label } from "./ui/label";
|
||||
@@ -524,9 +529,16 @@ export function ProfilesDataTable({
|
||||
getCoreRowModel: getCoreRowModel(),
|
||||
});
|
||||
|
||||
const platform = getCurrentOS();
|
||||
|
||||
return (
|
||||
<>
|
||||
<ScrollArea className="h-[400px] rounded-md border">
|
||||
<ScrollArea
|
||||
className={cn(
|
||||
"rounded-md border",
|
||||
platform === "macos" ? "h-[380px]" : "h-[320px]",
|
||||
)}
|
||||
>
|
||||
<Table>
|
||||
<TableHeader>
|
||||
{table.getHeaderGroups().map((headerGroup) => (
|
||||
|
||||
@@ -49,3 +49,13 @@ export function getBrowserIcon(browserType: string) {
|
||||
return null;
|
||||
}
|
||||
}
|
||||
|
||||
export const getCurrentOS = () => {
|
||||
if (typeof window !== "undefined") {
|
||||
const userAgent = window.navigator.userAgent;
|
||||
if (userAgent.includes("Win")) return "windows";
|
||||
if (userAgent.includes("Mac")) return "macos";
|
||||
if (userAgent.includes("Linux")) return "linux";
|
||||
}
|
||||
return "unknown";
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user