feat: Reorganize print name and date fields into a two-column grid in print modals and reduce STL viewer dimensions in the edit modal.
This commit is contained in:
@@ -236,27 +236,36 @@
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<Input label="Print Name" name="name" value={print.name} required />
|
<div class="grid grid-cols-2 gap-4">
|
||||||
|
<Input
|
||||||
|
label="Print Name"
|
||||||
|
name="name"
|
||||||
|
value={print.name}
|
||||||
|
required
|
||||||
|
/>
|
||||||
|
|
||||||
<!-- Date Field -->
|
<!-- Date Field -->
|
||||||
<div class="space-y-2">
|
<div class="space-y-2">
|
||||||
<!-- svelte-ignore a11y_label_has_associated_control -->
|
<!-- svelte-ignore a11y_label_has_associated_control -->
|
||||||
<label
|
<label
|
||||||
class="block text-xs font-medium text-slate-400 uppercase tracking-wider"
|
class="block text-xs font-medium text-slate-400 uppercase tracking-wider"
|
||||||
>
|
>
|
||||||
Date
|
Date
|
||||||
</label>
|
</label>
|
||||||
<div class="relative">
|
<div class="relative">
|
||||||
<Icon
|
<Icon
|
||||||
icon="mdi:calendar"
|
icon="mdi:calendar"
|
||||||
class="absolute left-3 top-1/2 -translate-y-1/2 w-5 h-5 text-slate-500 pointer-events-none"
|
class="absolute left-3 top-1/2 -translate-y-1/2 w-5 h-5 text-slate-500 pointer-events-none"
|
||||||
/>
|
/>
|
||||||
<input
|
<input
|
||||||
type="date"
|
type="date"
|
||||||
name="date"
|
name="date"
|
||||||
value={new Date(print.date).toISOString().split("T")[0]}
|
value={new Date(print.date)
|
||||||
class="w-full rounded-lg bg-slate-800/50 border border-slate-700 pl-10 pr-4 py-2.5 text-sm text-slate-100 focus:border-blue-500 focus:outline-none focus:ring-1 focus:ring-blue-500/30 transition-all"
|
.toISOString()
|
||||||
/>
|
.split("T")[0]}
|
||||||
|
class="w-full rounded-lg bg-slate-800/50 border border-slate-700 pl-10 pr-4 py-2.5 text-sm text-slate-100 focus:border-blue-500 focus:outline-none focus:ring-1 focus:ring-blue-500/30 transition-all"
|
||||||
|
/>
|
||||||
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
@@ -278,8 +287,8 @@
|
|||||||
{#await import("$lib/components/STLViewer.svelte") then { default: STLViewer }}
|
{#await import("$lib/components/STLViewer.svelte") then { default: STLViewer }}
|
||||||
<STLViewer
|
<STLViewer
|
||||||
modelPath={print.stl_file}
|
modelPath={print.stl_file}
|
||||||
width={400}
|
width={350}
|
||||||
height={250}
|
height={180}
|
||||||
/>
|
/>
|
||||||
{/await}
|
{/await}
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
@@ -185,32 +185,34 @@
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<Input
|
<div class="grid grid-cols-2 gap-4">
|
||||||
label="Print Name"
|
<Input
|
||||||
name="name"
|
label="Print Name"
|
||||||
placeholder="Dragon Scale Mail"
|
name="name"
|
||||||
required
|
placeholder="Dragon Scale Mail"
|
||||||
/>
|
required
|
||||||
|
/>
|
||||||
|
|
||||||
<!-- Date Field -->
|
<!-- Date Field -->
|
||||||
<div class="space-y-2">
|
<div class="space-y-2">
|
||||||
<!-- svelte-ignore a11y_label_has_associated_control -->
|
<!-- svelte-ignore a11y_label_has_associated_control -->
|
||||||
<label
|
<label
|
||||||
class="block text-xs font-medium text-slate-400 uppercase tracking-wider"
|
class="block text-xs font-medium text-slate-400 uppercase tracking-wider"
|
||||||
>
|
>
|
||||||
Date
|
Date
|
||||||
</label>
|
</label>
|
||||||
<div class="relative">
|
<div class="relative">
|
||||||
<Icon
|
<Icon
|
||||||
icon="mdi:calendar"
|
icon="mdi:calendar"
|
||||||
class="absolute left-3 top-1/2 -translate-y-1/2 w-5 h-5 text-slate-500 pointer-events-none"
|
class="absolute left-3 top-1/2 -translate-y-1/2 w-5 h-5 text-slate-500 pointer-events-none"
|
||||||
/>
|
/>
|
||||||
<input
|
<input
|
||||||
type="date"
|
type="date"
|
||||||
name="date"
|
name="date"
|
||||||
value={new Date().toISOString().split("T")[0]}
|
value={new Date().toISOString().split("T")[0]}
|
||||||
class="w-full rounded-lg bg-slate-800/50 border border-slate-700 pl-10 pr-4 py-2.5 text-sm text-slate-100 focus:border-blue-500 focus:outline-none focus:ring-1 focus:ring-blue-500/30 transition-all"
|
class="w-full rounded-lg bg-slate-800/50 border border-slate-700 pl-10 pr-4 py-2.5 text-sm text-slate-100 focus:border-blue-500 focus:outline-none focus:ring-1 focus:ring-blue-500/30 transition-all"
|
||||||
/>
|
/>
|
||||||
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user