mirror of
https://github.com/community-scripts/ProxmoxVE.git
synced 2025-05-04 14:23:07 +00:00
Changed the random script button to be the same as all the other buttons (#4183)
This commit is contained in:
parent
15deb9c658
commit
dc36ba409c
@ -16,7 +16,10 @@ import React from "react";
|
||||
import { Badge } from "./ui/badge";
|
||||
import { Button } from "./ui/button";
|
||||
import { DialogTitle } from "./ui/dialog";
|
||||
import { Sparkles } from "lucide-react"; // <- Hinzugefügt
|
||||
import { Sparkles } from "lucide-react";
|
||||
import { TooltipContent, TooltipProvider } from "./ui/tooltip";
|
||||
import { TooltipTrigger } from "./ui/tooltip";
|
||||
import { Tooltip } from "./ui/tooltip";
|
||||
|
||||
export const formattedBadge = (type: string) => {
|
||||
switch (type) {
|
||||
@ -111,16 +114,19 @@ export default function CommandMenu() {
|
||||
</kbd>
|
||||
</Button>
|
||||
|
||||
<Button
|
||||
variant="outline"
|
||||
size="icon"
|
||||
onClick={openRandomScript}
|
||||
title="Open random script"
|
||||
disabled={isLoading}
|
||||
className="h-9 w-9"
|
||||
>
|
||||
<Sparkles className="h-5 w-5" />
|
||||
</Button>
|
||||
<TooltipProvider>
|
||||
<Tooltip delayDuration={100}>
|
||||
<TooltipTrigger asChild>
|
||||
<Button variant="outline" size="icon" onClick={openRandomScript} disabled={isLoading} className="hidden lg:flex">
|
||||
<Sparkles className="size-4" />
|
||||
<span className="sr-only">Open Random Script</span>
|
||||
</Button>
|
||||
</TooltipTrigger>
|
||||
<TooltipContent>
|
||||
<p>Open Random Script</p>
|
||||
</TooltipContent>
|
||||
</Tooltip>
|
||||
</TooltipProvider>
|
||||
</div>
|
||||
|
||||
<CommandDialog open={open} onOpenChange={setOpen}>
|
||||
|
@ -41,8 +41,8 @@ export default function CodeCopyButton({
|
||||
|
||||
return (
|
||||
<div className="mt-4 flex">
|
||||
<Card className="flex items-center overflow-x-auto bg-primary-foreground pl-4">
|
||||
<div className="overflow-x-auto whitespace-pre-wrap text-nowrap break-all pr-4 text-sm">
|
||||
<Card className="flex items-center overflow-x-auto bg-primary-foreground pl-4 [&::-webkit-scrollbar]:h-1.5 [&::-webkit-scrollbar-thumb]:rounded-full [&::-webkit-scrollbar-thumb]:bg-muted-foreground/20">
|
||||
<div className="overflow-x-auto whitespace-pre-wrap text-nowrap break-all pr-4 text-sm [&::-webkit-scrollbar]:h-1.5 [&::-webkit-scrollbar-thumb]:rounded-full [&::-webkit-scrollbar-thumb]:bg-muted-foreground/20">
|
||||
{!isMobile && children ? children : "Copy install command"}
|
||||
</div>
|
||||
<button
|
||||
|
Loading…
x
Reference in New Issue
Block a user