Oregami
Repositories/oxedyne/daimond

oxedyne/daimond/www/css/lapse.css

4.8 KiB, 1 run

created by r2519314175:1107, which is this file's identity for as long as the history lasts, whatever it is later renamed to

download · who wrote it · its history

1/* lapse.css — the in-app lapse notice, and the legal row in About.
2 *
3 * The app-side half of the legal work. Its twin, `css/legal.css`, styles the
4 * documents THEMSELVES, which are shown inside the Web panel's frame and load
5 * their own stylesheets; nothing here reaches into that frame and nothing there
6 * reaches out.
7 *
8 * The notice sits over the workspace rather than in a panel, because a panel can
9 * be closed, folded away, or never opened — and a promise to tell somebody
10 * before their data is deleted is not kept by a sentence in a drawer. It is
11 * bottom-right, out of the way of the rail, the composer and the top bar, and it
12 * is bounded: at most two of these can ever be up at once.
13 */
14
15/* ── The notice ──────────────────────────────────────────────────────────── */
16.lapse-notices {
17 position: fixed;
18 right: calc(12px + var(--safe-r, 0px));
19 bottom: calc(12px + var(--safe-b, 0px));
20 z-index: 900; /* under a modal, over the workspace */
21 display: flex;
22 flex-direction: column;
23 gap: 10px;
24 width: min(380px, calc(100vw - 24px));
25 pointer-events: none; /* the gap between cards is not a shield */
26}
27
28.lapse-note {
29 position: relative;
30 pointer-events: auto;
31 background: var(--bg-secondary);
32 border: 1px solid var(--warn);
33 border-left-width: 3px;
34 border-radius: var(--radius);
35 box-shadow: 0 8px 24px rgba(0, 0, 0, 0.28);
36 padding: 12px 34px 12px 14px;
37 font-size: var(--fs-sm);
38 color: var(--text-secondary);
39 line-height: 1.5;
40}
41
42/* A licence ending is not a warning: nothing is lost, and the app carries on.
43 A deletion is. The two are drawn differently for that reason alone. */
44.lapse-licence { border-color: var(--border-2); }
45
46.lapse-head {
47 color: var(--text-primary);
48 font-weight: 650;
49 font-size: var(--fs-base);
50 margin-bottom: 6px;
51}
52
53.lapse-body { margin: 0 0 6px; }
54.lapse-body:last-of-type { margin-bottom: 10px; }
55
56.lapse-acts {
57 display: flex;
58 flex-wrap: wrap;
59 gap: 8px 14px;
60 align-items: center;
61}
62
63.lapse-act {
64 background: none;
65 border: none;
66 padding: 0;
67 font: inherit;
68 color: var(--accent-text);
69 cursor: pointer;
70 text-decoration: none;
71}
72.lapse-act:hover { text-decoration: underline; }
73.lapse-act:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
74
75.lapse-act-primary {
76 background: var(--accent);
77 color: var(--on-fill);
78 border-radius: var(--radius-sm);
79 padding: 5px 10px;
80 font-weight: 600;
81}
82.lapse-act-primary:hover { background: var(--accent-hover); text-decoration: none; }
83
84.lapse-x {
85 position: absolute;
86 top: 6px;
87 right: 6px;
88 width: 24px;
89 height: 24px;
90 line-height: 1;
91 background: none;
92 border: none;
93 border-radius: var(--radius-sm);
94 color: var(--text-muted);
95 font-size: 18px;
96 cursor: pointer;
97}
98.lapse-x:hover { color: var(--text-primary); background: var(--bg-hover); }
99.lapse-x:focus-visible { outline: 2px solid var(--accent); outline-offset: -2px; }
100
101/* A phone puts it at the TOP, and this is not symmetry for its own sake.
102 The phone shell is a conversation floor with a draggable SHEET rising from
103 the bottom — Web, Doc, Compose — and a notice anchored down there sits on
104 top of whichever one the reader just opened, including the very document
105 this notice links to. The top of the chat is the one region a sheet never
106 takes. Full width, because at 420px a 380px card centred on nothing looks
107 like a mistake. */
108@media (max-width: 760px) {
109 .lapse-notices {
110 left: calc(8px + var(--safe-l, 0px));
111 right: calc(8px + var(--safe-r, 0px));
112 width: auto;
113 top: calc(var(--safe-t, 0px) + var(--header-h, 44px) + 8px);
114 bottom: auto;
115 }
116}
117
118/* ── The legal row in About ──────────────────────────────────────────────
119 No rule of its own. `.about-maker` draws one directly below, and the card
120 already carries the note that two lines 60px apart read as a mistake. The
121 body is a centred flex column with a gap, so the row needs only its words. */
122.about-legal { text-align: center; }
123.about-legal-links {
124 display: flex;
125 justify-content: center;
126 gap: 10px;
127 font-size: var(--fs-sm);
128}
129/* The app sets no colour on a bare `a`, because it has almost none — so an
130 anchor here arrives in the browser's blue, on a card whose every other word
131 is the palette's. */
132.about-legal-links a,
133.lapse-note a { color: var(--accent-text); text-decoration: none; }
134.about-legal-links a:hover,
135.lapse-note a:hover { text-decoration: underline; }
136.about-legal-links a:focus-visible,
137.lapse-note a:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
138.about-legal-sep { color: var(--text-muted); }
139.about-legal-note {
140 margin: 4px 0 0;
141 font-size: var(--fs-xs);
142 color: var(--text-muted);
143}