mnfst 0.5.230 → 0.5.232
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/manifest.appwrite.data.js +1 -1
- package/lib/manifest.components.js +8 -0
- package/lib/manifest.css +343 -408
- package/lib/manifest.d.ts +170 -39
- package/lib/manifest.data.js +1 -1
- package/lib/manifest.defer.js +1 -1
- package/lib/manifest.dropdowns.js +2 -0
- package/lib/manifest.edit.css +89 -146
- package/lib/manifest.edit.js +2409 -1040
- package/lib/manifest.integrity.json +10 -10
- package/lib/manifest.js +119 -25
- package/lib/manifest.min.css +1 -1
- package/lib/{manifest.text.edit.css → manifest.rich.text.css} +62 -70
- package/lib/manifest.rich.text.js +2848 -0
- package/lib/manifest.router.js +8 -0
- package/lib/manifest.sw.js +1 -1
- package/package.json +2 -1
- package/lib/manifest.text.edit.js +0 -2234
|
@@ -1,75 +1,71 @@
|
|
|
1
|
-
/* Manifest Text
|
|
1
|
+
/* Manifest Rich Text */
|
|
2
2
|
|
|
3
3
|
@layer base, components, utilities;
|
|
4
4
|
|
|
5
|
-
/* Self-contained. The editable area is a field first — it borrows the tokens inputs
|
|
6
|
-
and textareas use, so it sits in a form without looking bolted on. Controls are
|
|
7
|
-
styled where they are, not by where they sit, because they can be anywhere. */
|
|
8
|
-
|
|
9
5
|
@layer components {
|
|
10
6
|
|
|
11
|
-
:where([data-text-edit]) {
|
|
7
|
+
:where([data-rich-text]:not([data-edit-text])) {
|
|
12
8
|
position: relative;
|
|
13
9
|
overflow-y: auto;
|
|
14
|
-
max-height: var(--text-
|
|
10
|
+
max-height: var(--rich-text-max-height, none);
|
|
15
11
|
outline: none;
|
|
16
12
|
|
|
17
|
-
/*
|
|
18
|
-
|
|
19
|
-
font-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
keeps, and the tag holding it is not predictable after a wipe. The
|
|
27
|
-
placeholder OVERLAYS the first line (it is not a line of its own), so
|
|
28
|
-
the caret sits on top of it and nothing jumps when typing starts. */
|
|
29
|
-
&[data-text-edit-empty]::before {
|
|
13
|
+
/* Document-wide styles (.all controls, $rich.all) */
|
|
14
|
+
font-family: var(--rich-text-font, inherit);
|
|
15
|
+
font-size: var(--rich-text-size, inherit);
|
|
16
|
+
line-height: var(--rich-text-leading, inherit);
|
|
17
|
+
text-align: var(--rich-text-align, start);
|
|
18
|
+
color: var(--rich-text-color, inherit);
|
|
19
|
+
|
|
20
|
+
/* Placeholder overlays the first line */
|
|
21
|
+
&[data-rich-text-empty]::before {
|
|
30
22
|
content: attr(placeholder);
|
|
31
23
|
position: absolute;
|
|
32
|
-
inset-block-start: var(--text-
|
|
33
|
-
inset-inline: var(--text-
|
|
24
|
+
inset-block-start: var(--rich-text-padding, 0.75rem);
|
|
25
|
+
inset-inline: var(--rich-text-padding, 0.75rem);
|
|
34
26
|
color: var(--color-content-subtle);
|
|
35
27
|
pointer-events: none;
|
|
36
28
|
}
|
|
37
29
|
}
|
|
38
30
|
|
|
39
|
-
/*
|
|
40
|
-
:where([data-text
|
|
31
|
+
/* .all background on an unstyled area */
|
|
32
|
+
:where([data-rich-text].unstyle[style*="--rich-text-background"]) {
|
|
33
|
+
background: var(--rich-text-background);
|
|
34
|
+
}
|
|
35
|
+
|
|
36
|
+
/* Unstyled: placeholder hugs the line */
|
|
37
|
+
:where([data-rich-text].unstyle)[data-rich-text-empty]::before {
|
|
41
38
|
inset-block-start: 0;
|
|
42
39
|
inset-inline: 0;
|
|
43
40
|
}
|
|
44
41
|
|
|
45
|
-
/*
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
padding: var(--text-edit-padding, 0.75rem);
|
|
51
|
-
background: var(--text-edit-background, var(--color-surface-1));
|
|
42
|
+
/* Field look; .unstyle drops it */
|
|
43
|
+
:where([data-rich-text]:not(.unstyle, [data-edit-text])) {
|
|
44
|
+
min-height: var(--rich-text-min-height, 8rem);
|
|
45
|
+
padding: var(--rich-text-padding, 0.75rem);
|
|
46
|
+
background: var(--rich-text-background, var(--color-surface-1));
|
|
52
47
|
border: 1px solid var(--color-line);
|
|
53
48
|
border-radius: var(--radius);
|
|
54
49
|
|
|
55
|
-
/* Held while
|
|
56
|
-
control takes NATIVE focus by design, and the ring must not flicker
|
|
57
|
-
off while the writer is mid-command. */
|
|
50
|
+
/* Held while a focus-taking control acts on the area */
|
|
58
51
|
&:focus,
|
|
59
|
-
&[data-text-
|
|
52
|
+
&[data-rich-text-focused] {
|
|
60
53
|
border-color: var(--color-content-subtle);
|
|
61
54
|
}
|
|
62
55
|
}
|
|
63
56
|
|
|
64
|
-
/*
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
57
|
+
/* Single-line (.inline) */
|
|
58
|
+
:where([data-rich-text-inline]:not(.unstyle, [data-edit-text])) {
|
|
59
|
+
min-height: var(--rich-text-min-height, auto);
|
|
60
|
+
}
|
|
61
|
+
|
|
62
|
+
/* ---- Selection menu (x-rich-text-menu) ---- */
|
|
63
|
+
:where([data-rich-text-menu]) {
|
|
68
64
|
position: fixed;
|
|
69
65
|
margin: 0;
|
|
70
66
|
inset: auto;
|
|
71
|
-
left: var(--text-
|
|
72
|
-
top: var(--text-
|
|
67
|
+
left: var(--rich-text-selection-center);
|
|
68
|
+
top: var(--rich-text-selection-y);
|
|
73
69
|
transform: translate(-50%, calc(-100% - 0.5rem));
|
|
74
70
|
gap: 0.25rem;
|
|
75
71
|
align-items: center;
|
|
@@ -80,27 +76,21 @@
|
|
|
80
76
|
box-shadow: 0 8px 30px rgb(0 0 0 / 0.2);
|
|
81
77
|
}
|
|
82
78
|
|
|
83
|
-
/*
|
|
84
|
-
|
|
85
|
-
over the page before any selection exists. */
|
|
86
|
-
:where([data-text-edit-menu]:popover-open) {
|
|
79
|
+
/* Display only while open */
|
|
80
|
+
:where([data-rich-text-menu]:popover-open) {
|
|
87
81
|
display: flex;
|
|
88
82
|
}
|
|
89
83
|
|
|
90
|
-
/*
|
|
91
|
-
permanently fixed on the page — hide it there; the bubble is progressive
|
|
92
|
-
enhancement. (In supporting browsers a closed popover is hidden natively.) */
|
|
84
|
+
/* No Popover API: hidden */
|
|
93
85
|
@supports not selector(:popover-open) {
|
|
94
|
-
:where([data-text-
|
|
86
|
+
:where([data-rich-text-menu]) {
|
|
95
87
|
display: none;
|
|
96
88
|
}
|
|
97
89
|
}
|
|
98
90
|
|
|
99
|
-
/* ---- Controls ----
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
:where([data-text-edit-control]) {
|
|
103
|
-
&[data-text-edit-active] {
|
|
91
|
+
/* ---- Controls ---- */
|
|
92
|
+
:where([data-rich-text-control]) {
|
|
93
|
+
&[data-rich-text-active] {
|
|
104
94
|
background: color-mix(in oklch, var(--color-content-stark) 10%, transparent);
|
|
105
95
|
color: var(--color-content-stark);
|
|
106
96
|
}
|
|
@@ -111,15 +101,19 @@
|
|
|
111
101
|
}
|
|
112
102
|
}
|
|
113
103
|
|
|
114
|
-
|
|
104
|
+
/* Icon-only buttons */
|
|
105
|
+
:where(button[data-rich-text-control]:has(> svg:only-child)) {
|
|
115
106
|
padding: 0.35rem;
|
|
116
107
|
line-height: 0;
|
|
117
108
|
}
|
|
118
109
|
|
|
119
|
-
/*
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
110
|
+
/* Disabled controls still catch the click, so the area keeps focus */
|
|
111
|
+
:where([data-rich-text-control][aria-disabled=true]) {
|
|
112
|
+
pointer-events: auto;
|
|
113
|
+
}
|
|
114
|
+
|
|
115
|
+
/* ---- Editable content ---- */
|
|
116
|
+
:where([data-rich-text]:not([data-edit-text])) {
|
|
123
117
|
|
|
124
118
|
& > * + * {
|
|
125
119
|
margin-block-start: 0.75em;
|
|
@@ -197,21 +191,19 @@
|
|
|
197
191
|
}
|
|
198
192
|
}
|
|
199
193
|
|
|
200
|
-
/*
|
|
201
|
-
|
|
202
|
-
selection visible. */
|
|
203
|
-
& :where(td, th)[data-text-edit-cell] {
|
|
194
|
+
/* Cell block selection */
|
|
195
|
+
& :where(td, th)[data-rich-text-cell] {
|
|
204
196
|
background: color-mix(in oklch, var(--color-brand-content) 18%, transparent);
|
|
205
197
|
}
|
|
206
198
|
|
|
207
|
-
/*
|
|
208
|
-
&[data-text-
|
|
209
|
-
&[data-text-
|
|
210
|
-
&[data-text-
|
|
211
|
-
&[data-text-
|
|
212
|
-
&[data-text-
|
|
199
|
+
/* Table border resizing */
|
|
200
|
+
&[data-rich-text-border="x"] { cursor: col-resize }
|
|
201
|
+
&[data-rich-text-border="y"] { cursor: row-resize }
|
|
202
|
+
&[data-rich-text-resizing] { user-select: none }
|
|
203
|
+
&[data-rich-text-resizing="x"] { cursor: col-resize }
|
|
204
|
+
&[data-rich-text-resizing="y"] { cursor: row-resize }
|
|
213
205
|
|
|
214
|
-
/* Task lists
|
|
206
|
+
/* Task lists */
|
|
215
207
|
& :where(ul[data-checklist]) {
|
|
216
208
|
padding-inline-start: 0.25em;
|
|
217
209
|
list-style: none;
|