- Refactored select component to align with shadcn design principles. - Updated server status indicator component for consistency with shadcn style. - Modified spinner component to follow shadcn design guidelines. - Enhanced stat card component with shadcn-inspired styles. - Adjusted tab panel component to reflect shadcn design updates. - Revamped table row and table data cell components to match shadcn aesthetics. - Updated table header cell component for improved styling consistency. - Refined table component to align with shadcn design principles. - Enhanced tabs component with shadcn-inspired styles. - Updated toggle component to follow shadcn design guidelines. - Refactored tooltip component to align with shadcn design principles. - Updated server card component to reflect shadcn-inspired design.
36 lines
985 B
PHP
36 lines
985 B
PHP
{{--
|
|
Copy Button Component - shadcn-style
|
|
Small inline button to copy text to clipboard
|
|
|
|
Usage:
|
|
<x-proxmox::ui.copy-button :value="$text" />
|
|
--}}
|
|
|
|
@props([
|
|
'value',
|
|
])
|
|
|
|
<div
|
|
x-data="{
|
|
copied: false,
|
|
copyText: @js($value),
|
|
copyToClipboard() {
|
|
navigator.clipboard.writeText(this.copyText);
|
|
this.copied = true;
|
|
setTimeout(() => this.copied = false, 2000);
|
|
}
|
|
}"
|
|
class="inline-flex items-center"
|
|
{{ $attributes }}
|
|
>
|
|
<button
|
|
@click="copyToClipboard()"
|
|
type="button"
|
|
class="text-muted-foreground hover:text-foreground transition-colors duration-150 relative inline-flex items-center justify-center size-4"
|
|
title="Copy to clipboard"
|
|
>
|
|
<x-ri-check-fill x-show="copied" x-transition x-cloak class="absolute size-4 text-success" />
|
|
<x-ri-file-copy-line x-show="!copied" x-transition class="absolute size-4" />
|
|
</button>
|
|
</div>
|