yggdrasil/components/skeletons/
write_skeleton.rs1use crate::components::skeletons::atoms::*;
7use dioxus::prelude::*;
8
9#[component]
14pub fn WriteSkeleton() -> Element {
15 rsx! {
16 div { class: "relative flex-1 flex flex-col min-h-0 overflow-hidden bg-[var(--color-paper-theme)]",
19 div { class: "flex-shrink-0 px-6 py-3 border-b border-[var(--color-paper-border)]/60 flex items-center justify-between gap-4 select-none",
21 div { class: "flex items-center gap-3",
22 SkeletonBox { class: "h-7 w-20 rounded-full" }
23 div { class: "w-px h-4 bg-[var(--color-paper-border)]/60" }
24 SkeletonBox { class: "h-5 w-24 rounded-md" }
25 SkeletonBox { class: "h-4 w-10 rounded-full" }
26 }
27 div { class: "hidden md:flex items-center gap-3",
28 SkeletonBox { class: "h-4 w-28 rounded" }
29 }
30 SkeletonBox { class: "h-7 w-20 rounded-full" }
31 }
32
33 div { class: "flex-1 min-h-0 flex",
35 div { class: "flex-1 min-w-0 min-h-0 overflow-y-auto px-6 sm:px-10 md:px-14 py-8 flex flex-col items-center",
37 div { class: "w-full max-w-4xl flex-1 flex flex-col",
38 SkeletonBox { class: "h-12 w-3/4 rounded-xl mb-4" }
40
41 div { class: "flex-1 min-h-[480px] flex flex-col mb-4",
43 div { class: "flex-1 min-h-0 w-full border border-[var(--color-paper-border)]/70 rounded-2xl overflow-hidden bg-[var(--color-paper-entry)]/40 p-6 space-y-4 shadow-xs",
44 SkeletonBox { class: "h-5 w-[90%] rounded-md" }
45 SkeletonBox { class: "h-5 w-full rounded-md" }
46 SkeletonBox { class: "h-5 w-[85%] rounded-md" }
47 SkeletonBox { class: "h-5 w-[95%] rounded-md" }
48 SkeletonBox { class: "h-5 w-[60%] rounded-md" }
49 SkeletonBox { class: "h-5 w-full rounded-md" }
50 SkeletonBox { class: "h-5 w-[75%] rounded-md" }
51 }
52 }
53 }
54 }
55
56 div { class: "w-80 sm:w-88 flex-shrink-0 min-h-0 overflow-y-auto border-l border-[var(--color-paper-border)]/70 flex flex-col bg-[var(--color-paper-theme)]",
58 div { class: "px-5 py-4 border-b border-[var(--color-paper-border)]/60 flex items-center justify-between",
60 SkeletonBox { class: "h-4 w-20 rounded" }
61 SkeletonBox { class: "h-4 w-4 rounded" }
62 }
63 div { class: "p-5 border-b border-[var(--color-paper-border)]/60 space-y-2.5",
65 SkeletonBox { class: "h-3 w-16 rounded" }
66 SkeletonBox { class: "h-8 w-full rounded-2xl" }
67 }
68 div { class: "p-5 border-b border-[var(--color-paper-border)]/60 space-y-2.5",
70 SkeletonBox { class: "h-3 w-16 rounded" }
71 SkeletonBox { class: "h-8 w-full rounded-2xl" }
72 }
73 div { class: "p-5 border-b border-[var(--color-paper-border)]/60 space-y-2.5",
75 SkeletonBox { class: "h-3 w-16 rounded" }
76 SkeletonBox { class: "h-20 w-full rounded-2xl" }
77 }
78 div { class: "p-5 space-y-2.5",
80 SkeletonBox { class: "h-3 w-16 rounded" }
81 SkeletonBox { class: "h-14 w-full rounded-2xl" }
82 }
83 }
84 }
85
86 div { class: "flex-shrink-0 px-6 py-3.5 flex items-center justify-between border-t border-[var(--color-paper-border)]/80 bg-[var(--color-paper-theme)] shadow-xs",
88 SkeletonBox { class: "h-9 w-24 rounded-full" }
89 div { class: "flex items-center gap-3",
90 SkeletonBox { class: "h-9 w-28 rounded-full" }
91 div { class: "w-px h-5 bg-[var(--color-paper-border)]/60" }
92 SkeletonBox { class: "h-9 w-24 rounded-full" }
93 }
94 }
95 }
96 }
97}