@acornly/ui 0.1.0 → 0.3.0
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/README.md +122 -4
- package/dist/brand.d.ts +50 -0
- package/dist/brand.d.ts.map +1 -0
- package/dist/brand.js +84 -0
- package/dist/brand.js.map +1 -0
- package/dist/card.d.ts +24 -1
- package/dist/card.d.ts.map +1 -1
- package/dist/card.js +49 -9
- package/dist/card.js.map +1 -1
- package/dist/chat-model.d.ts +165 -0
- package/dist/chat-model.d.ts.map +1 -0
- package/dist/chat-model.js +576 -0
- package/dist/chat-model.js.map +1 -0
- package/dist/chat-panel.d.ts +36 -0
- package/dist/chat-panel.d.ts.map +1 -0
- package/dist/chat-panel.js +760 -0
- package/dist/chat-panel.js.map +1 -0
- package/dist/chat-picker.d.ts +56 -0
- package/dist/chat-picker.d.ts.map +1 -0
- package/dist/chat-picker.js +284 -0
- package/dist/chat-picker.js.map +1 -0
- package/dist/chat-protocol.d.ts +151 -0
- package/dist/chat-protocol.d.ts.map +1 -0
- package/dist/chat-protocol.js +113 -0
- package/dist/chat-protocol.js.map +1 -0
- package/dist/chat-speech.d.ts +61 -0
- package/dist/chat-speech.d.ts.map +1 -0
- package/dist/chat-speech.js +119 -0
- package/dist/chat-speech.js.map +1 -0
- package/dist/chat.d.ts +148 -0
- package/dist/chat.d.ts.map +1 -0
- package/dist/chat.js +119 -0
- package/dist/chat.js.map +1 -0
- package/dist/compose.d.ts +1 -1
- package/dist/compose.d.ts.map +1 -1
- package/dist/compose.js.map +1 -1
- package/dist/composer.d.ts +26 -1
- package/dist/composer.d.ts.map +1 -1
- package/dist/composer.js +73 -5
- package/dist/composer.js.map +1 -1
- package/dist/index.d.ts +1 -1
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js.map +1 -1
- package/dist/media.d.ts.map +1 -1
- package/dist/media.js +0 -1
- package/dist/media.js.map +1 -1
- package/dist/painter.d.ts +20 -2
- package/dist/painter.d.ts.map +1 -1
- package/dist/painter.js +41 -6
- package/dist/painter.js.map +1 -1
- package/dist/panel.js +5 -5
- package/dist/parts.d.ts +2 -0
- package/dist/parts.d.ts.map +1 -1
- package/dist/parts.js +2 -0
- package/dist/parts.js.map +1 -1
- package/dist/pins.d.ts.map +1 -1
- package/dist/pins.js +14 -9
- package/dist/pins.js.map +1 -1
- package/dist/theme.d.ts +1 -1
- package/dist/theme.d.ts.map +1 -1
- package/dist/theme.js +14 -34
- package/dist/theme.js.map +1 -1
- package/dist/toolbar.js +3 -3
- package/package.json +11 -3
package/README.md
CHANGED
|
@@ -21,7 +21,7 @@ root.destroy(); // removes the element, its listeners and everything inside it
|
|
|
21
21
|
|
|
22
22
|
- Page CSS cannot reach the UI. The host carries inline `all: initial !important`, so page rules can neither hide or move it nor pass inherited fonts and colors into it.
|
|
23
23
|
- The UI adds no global styles and no `window` globals. (Lit itself records its version on `globalThis` for duplicate detection.)
|
|
24
|
-
- Text normalization in `@acornly/core` skips `<acornly-root>` (landing with [#19](https://github.com/
|
|
24
|
+
- Text normalization in `@acornly/core` skips `<acornly-root>` (landing with [#19](https://github.com/postagilab/acornly/issues/19)), so notes never anchor to Acornly's own text.
|
|
25
25
|
- Keys typed into an Acornly field stop at the shadow root, so the page's bubbling key listeners (most page shortcuts) never see them.
|
|
26
26
|
- Surfaces size text in `px` or `em`, never `rem`: `rem` follows the page's root font size, which the shell cannot isolate.
|
|
27
27
|
|
|
@@ -31,9 +31,9 @@ Set any of these custom properties on `acornly-root` in your CSS, or pass them a
|
|
|
31
31
|
|
|
32
32
|
| Property | Option | What it styles |
|
|
33
33
|
| ----------------------- | ---------------- | ----------------------------------- |
|
|
34
|
-
| `--ctx-accent` | `accent` | Buttons,
|
|
34
|
+
| `--ctx-accent` | `accent` | Buttons, links, focus rings |
|
|
35
35
|
| `--ctx-accent-contrast` | `accentContrast` | Text on the accent color |
|
|
36
|
-
| `--ctx-background` | `background` | Cards, toolbars, the panel
|
|
36
|
+
| `--ctx-background` | `background` | Cards, toolbars, the panel, pins |
|
|
37
37
|
| `--ctx-foreground` | `foreground` | Main text |
|
|
38
38
|
| `--ctx-muted` | `muted` | Timestamps, hints, placeholders |
|
|
39
39
|
| `--ctx-border` | `border` | Borders and dividers |
|
|
@@ -57,6 +57,21 @@ acornly-root {
|
|
|
57
57
|
|
|
58
58
|
`colorScheme: "auto"` (the default) follows `prefers-color-scheme`; the `color-scheme` attribute on the element shows the current setting.
|
|
59
59
|
|
|
60
|
+
The defaults are Acornly's own palettes, exported from `@acornly/ui/brand` as `LIGHT` and `DARK`:
|
|
61
|
+
|
|
62
|
+
| Token | Light | Dark |
|
|
63
|
+
| ------------ | ----------------------- | ----------------------- |
|
|
64
|
+
| `accent` | `#6253a8` violet | `#9184d9` violet |
|
|
65
|
+
| `background` | `#fffdf9` cream | `#232532` Nocturne |
|
|
66
|
+
| `foreground` | `#30231b` | `#e9e9ed` |
|
|
67
|
+
| `muted` | `#645850` | `#b2b6ca` |
|
|
68
|
+
| `border` | `#d6d0c9` | `#3f424d` |
|
|
69
|
+
| `highlight` | `rgb(236 178 110 / .4)` | `rgb(193 129 84 / .34)` |
|
|
70
|
+
| `font` | Inter, then system-ui | the same |
|
|
71
|
+
| `radius` | `14px` (controls 8px) | the same |
|
|
72
|
+
|
|
73
|
+
`@acornly/ui/brand` also draws the acorn marks: `drawMark(document, SPROUT)` (the logo) or `ACORN` (the pin mark) returns an `<svg>` element built without parsing markup, so it works under Trusted Types.
|
|
74
|
+
|
|
60
75
|
### Parts
|
|
61
76
|
|
|
62
77
|
For styling beyond the tokens, these `::part()` names are stable:
|
|
@@ -71,6 +86,7 @@ For styling beyond the tokens, these `::part()` names are stable:
|
|
|
71
86
|
| `selection-toolbar` | The toolbar next to a text selection. |
|
|
72
87
|
| `composer` | The note composer. |
|
|
73
88
|
| `launcher` | The SDK's notes button, fixed bottom right. |
|
|
89
|
+
| `chat` | The in-app chat panel (experimental). |
|
|
74
90
|
|
|
75
91
|
```css
|
|
76
92
|
acornly-root::part(layer) {
|
|
@@ -187,6 +203,7 @@ const card = openCard({
|
|
|
187
203
|
viewerId, // marks the viewer's own reactions, and shows their notes as "Me"
|
|
188
204
|
viewerPicture, // optional: the viewer's photo (https), next to their own notes
|
|
189
205
|
registry: ctx.bodyTypes, // app-defined body types
|
|
206
|
+
audience: (note) => (note.ext.audience.kind === "circles" ? "Visible to Lab" : null), // optional mark
|
|
190
207
|
actions: {
|
|
191
208
|
// Reply, Edit and Delete buttons on each note; the card only reports the choice.
|
|
192
209
|
reply: (note, button) => openReplyComposer(note, pin),
|
|
@@ -201,7 +218,7 @@ card.update(newerThread); // after a reply arrives
|
|
|
201
218
|
card.close();
|
|
202
219
|
```
|
|
203
220
|
|
|
204
|
-
The card is placed with [Floating UI](https://floating-ui.com): below its anchor, flipped above when there is no room, kept inside the viewport and following the anchor as the page scrolls. It shows the note and its replies, parents before children: replies are indented up to three levels (`MAX_INDENT`), and deeper ones are shown flat with a "Replying to …" label. Reactions are shown as counts on the note they react to; an edited note carries an "edited" mark and a deleted note that still has replies shows as a placeholder. The card is a `dialog` that takes focus, keeps Tab inside it and closes on Escape, its close button or a pointer down outside it and its anchor (`closeOnOutsideClick: false` turns that off); focus then returns to the anchor when it is an element (the pin or panel row), else to where it was. If that element was re-rendered meanwhile, the element with the same `data-id` and class gets focus instead. Every visible string can be replaced through `labels`. While its pin is hidden (its text scrolled out of a scroller, say), the card stays where the pin last was and follows the pin again once it shows. A removed pin does not come back as the same button, so close the card when its note goes away (`setAll` without it, say) and open a new one on the new pin. The card stacks above the side panel, whichever opened first. The card renders bodies with `@acornly/ui/markdown`, so loading it loads the Markdown renderer too.
|
|
221
|
+
The card is placed with [Floating UI](https://floating-ui.com): below its anchor, flipped above when there is no room, kept inside the viewport and following the anchor as the page scrolls. It shows the note and its replies, parents before children: replies are indented up to three levels (`MAX_INDENT`), and deeper ones are shown flat with a "Replying to …" label. Reactions are shown as counts on the note they react to; an edited note carries an "edited" mark and a deleted note that still has replies shows as a placeholder. The card is a `dialog` that takes focus, keeps Tab inside it and closes on Escape, its close button or a pointer down outside it and its anchor (`closeOnOutsideClick: false` turns that off); focus then returns to the anchor when it is an element (the pin or panel row), else to where it was. If that element was re-rendered meanwhile, the element with the same `data-id` and class gets focus instead (a panel row; a pin carries no `data-id`, as page CSS could read it through `::part(pin)`). Every visible string can be replaced through `labels`. While its pin is hidden (its text scrolled out of a scroller, say), the card stays where the pin last was and follows the pin again once it shows. A removed pin does not come back as the same button, so close the card when its note goes away (`setAll` without it, say) and open a new one on the new pin. The card stacks above the side panel, whichever opened first. The card renders bodies with `@acornly/ui/markdown`, so loading it loads the Markdown renderer too.
|
|
205
222
|
|
|
206
223
|
## Side panel
|
|
207
224
|
|
|
@@ -282,3 +299,104 @@ Keyboard shortcuts, registered in the shell's registry while the surface is open
|
|
|
282
299
|
| `composer.preview` | `mod+alt+p` | Switch between writing and the preview |
|
|
283
300
|
|
|
284
301
|
Once focus is in the toolbar (Alt+F10 or Tab), the arrow keys, Home and End move between buttons and Escape closes it and gives focus back. When two open surfaces bind the same key, the newest one wins while its `when` guard allows it (the composer's keys apply only while focus is inside it).
|
|
302
|
+
|
|
303
|
+
## In-app chat (experimental)
|
|
304
|
+
|
|
305
|
+
`@acornly/ui/chat` is the chat an app on Roots shows beside itself, on the app context protocol 0.1 ([docs/design/app-context-protocol.md](../../docs/design/app-context-protocol.md)), with **Comment** beside **Ask**: a note on the item in focus, from the same chip and Change picker. It is experimental: it may change in any minor release, and only math, and the Bible and history trial behind flights (postagilab/ops#651), adopt it until the checks in #695 pass.
|
|
306
|
+
|
|
307
|
+
```ts
|
|
308
|
+
import { contextAnchorProvider, contextNote } from "@acornly/sdk";
|
|
309
|
+
import { createChat } from "@acornly/ui/chat";
|
|
310
|
+
|
|
311
|
+
const rect = (id) => pinRect(id); // where a canvas or map item is on screen, or null
|
|
312
|
+
const places = contextAnchorProvider({ rect, host: (id) => mapElementFor(id) });
|
|
313
|
+
const acornly = await Acornly.init({ ...config, anchorProviders: [places] }, { ui: builtInUi });
|
|
314
|
+
map.on("move", () => places.moved()); // pins on rect items follow a pan
|
|
315
|
+
|
|
316
|
+
const chat = createChat(root, {
|
|
317
|
+
model: "claude-haiku-5-5",
|
|
318
|
+
proxy: { url: workerUrl, appId, token: () => appToken }, // or relay: { endpoint: "/api/chat" }
|
|
319
|
+
load: (id) => loadItem(id), // read_context: an item's content, or null
|
|
320
|
+
rect,
|
|
321
|
+
guard: (sentence) => leaks(sentence), // with rules.guard "callback"
|
|
322
|
+
onHandBack: (id, itemId) => run(id, itemId),
|
|
323
|
+
onKeep: (kept) => acornly.add(contextNote(kept)).then(() => {}),
|
|
324
|
+
onComment: (comment) => acornly.add(contextNote(comment)).then(() => {}),
|
|
325
|
+
onListening: (on) => (on ? guideVoice.pause() : guideVoice.resume()), // optional
|
|
326
|
+
renderMath: (tex, display) => katexNode(tex, display), // optional
|
|
327
|
+
});
|
|
328
|
+
chat.setContext(snapshot); // on every change; cheap while the chat is closed
|
|
329
|
+
askButton.onclick = () => chat.open(); // one "Comment / Ask about this" button
|
|
330
|
+
commentButton.onclick = () => chat.open(undefined, "comment"); // or a Comment button of its own
|
|
331
|
+
```
|
|
332
|
+
|
|
333
|
+
- Up front an app loads only `createChat`, which keeps the latest snapshot. The panel is its own chunk, fetched on the first `open`, and replies are drawn by the Markdown renderer's chunk after it.
|
|
334
|
+
- The panel sits at the right, 380 px wide and full height, over the app; an app that wants it beside its own panels makes room while it is open (`onClose` says when it shuts). At 520 px wide and less it is a bottom sheet, 62% of the screen tall, so what it is about stays in view above it.
|
|
335
|
+
- The panel is a `complementary` landmark. Its chip names the focus; **Change** shows outlines over every item marked with `data-acornly-context="<id>"` (or `data-ctx-anchor` with an item's id) or reported by `rect`, and from the keyboard opens the text tree, an ARIA `tree` with arrow keys and type-ahead.
|
|
336
|
+
- The reply streams in as the model writes it, with its Markdown drawn as it comes. With `rules.guard: "callback"` it shows a sentence at a time instead, each checked first. Until the reply starts, and while the model reads an item, three dots say it is thinking (a `status` that reads `thinking`, still under `prefers-reduced-motion`); the log is `aria-busy` while a reply streams, so screen readers hear it whole.
|
|
337
|
+
- Every model call carries `Acornly-Feature: chat`. With `rules.guard: "relay"` the calls go to the app's `relay` endpoint, which must forward that header and pass the proxy's error responses on as they are (status and body), so the panel can say why an ask failed. Each turn takes at most three model rounds, and a conversation at most 20 turns.
|
|
338
|
+
- `onKeep` gets the takeaway, its item, a `target` (the item by id in a `ProviderSelector`, then its quote and source), the item's `quote` and its `about` keys; the app saves it as an acorn. Without `onKeep`, Keep is not offered. Chats themselves are never stored.
|
|
339
|
+
- `onComment` gets a comment in the same shape. With it, the form has **Ask** and **Comment**; with `onComment` and no `proxy` or `relay`, the panel is for comments only. A comment calls no model and costs nothing, and does not tie the conversation to its item. It is saved on the focus item, or on its nearest ancestor with an `anchor`. `open(focus, "comment")` opens straight into Comment, so a trial can compare one button for both with a button each.
|
|
340
|
+
- `contextNote(c)` from `@acornly/sdk` is the `add` input for either: the text, the `about` keys as tags, and the target `{ context: item, quote }`. With `contextAnchorProvider` in `anchorProviders`, the built-in UI finds the note again by the item's mark (a verse), or pins it at the item's `rect` inside its `host` (a place on a map), hiding the pin while `rect` answers `null`; call `moved()` when rect items move without the page changing. Give `host` when the app has rect items (without it, an item is placed only if `rect` answers when the note is resolved, so notes on a map that is not ready yet stay page notes); it answers `null` for an id that is not one of the app's rect items, so a note on a verse whose mark is not on the page falls back to its quote. `rect` and `host` get ids from stored notes, which may be other people's: look them up, never build a selector or HTML from them. The `{ context }` target is experimental and outside the [client API contract](../../docs/contracts/client-api.md), as the chat is.
|
|
341
|
+
- A failed ask says why when the model proxy said so (#740): no leave to use the person's AI in this app (`no_grant`), no AI key on their account (`no_key`), or the app's budget for the month spent (`budget_exhausted`), each with a link to the hub page that fixes it (Apps you use, or Your AI), opening in a new tab. Keep's draft says the same when it fails for one of them. `inactive` and `rate_limited` are named too, with no link. `hubUrl` is the hub's origin, for a local or staging Cloud (default `https://acornly.ai`; a path on it is dropped). The chat's own share running out (`feature_cap`) keeps its message; any other failure says only that the chat couldn't answer.
|
|
342
|
+
- Every string can be replaced through `labels`.
|
|
343
|
+
|
|
344
|
+
### Static apps: the vendored bundle
|
|
345
|
+
|
|
346
|
+
An app with no npm (a static site such as the Interactive Bible or history.scholeo.com) copies a built bundle into its repository:
|
|
347
|
+
|
|
348
|
+
```sh
|
|
349
|
+
# in a checkout of postagilab/acornly at the main commit to take
|
|
350
|
+
pnpm install --frozen-lockfile
|
|
351
|
+
pnpm vendor ../bible/vendor/acornly # an empty folder, or the bundle there before
|
|
352
|
+
```
|
|
353
|
+
|
|
354
|
+
The folder holds ES modules and nothing else to install:
|
|
355
|
+
|
|
356
|
+
- `acornly.js`: the SDK (`Acornly`, `contextAnchorProvider`, `contextNote`, the errors), `builtInUi`, `CloudAdapter`, and `loadIndexedDB()` for notes kept on the device.
|
|
357
|
+
- `acornly-chat.js`: `createChat`, the protocol's types and checks, and `mountRoot` for the chat's shell. An app that never opens the chat never loads it, and the panel and the Markdown renderer are chunks of their own, so the flight is one `import` to revert.
|
|
358
|
+
- `chunks/`, loaded from beside the two entries; `VERSION`, the commit and package versions it was built from; `LICENSE`; and `SHA256SUMS`, to check the copy (`sha256sum -c SHA256SUMS` in the folder).
|
|
359
|
+
|
|
360
|
+
Sign-in stays site-kit's `acornly-sign-in.js` (vendored by every Scholeo site): its `getToken` is both the `CloudAdapter`'s and the chat's `proxy.token`.
|
|
361
|
+
|
|
362
|
+
```js
|
|
363
|
+
import {
|
|
364
|
+
Acornly,
|
|
365
|
+
CloudAdapter,
|
|
366
|
+
builtInUi,
|
|
367
|
+
contextAnchorProvider,
|
|
368
|
+
contextNote,
|
|
369
|
+
} from "./vendor/acornly/acornly.js";
|
|
370
|
+
|
|
371
|
+
const places = contextAnchorProvider({ rect, host });
|
|
372
|
+
const acornly = await Acornly.init(
|
|
373
|
+
{
|
|
374
|
+
adapter: new CloudAdapter({ ...CLOUD, getToken: auth.getToken }),
|
|
375
|
+
scope: `app:${APP_ID}`,
|
|
376
|
+
user: auth.user,
|
|
377
|
+
anchorProviders: [places],
|
|
378
|
+
},
|
|
379
|
+
{ ui: builtInUi },
|
|
380
|
+
);
|
|
381
|
+
// Behind the flight only: the chat loads when the person first asks or comments.
|
|
382
|
+
askButton.onclick = async () => {
|
|
383
|
+
const { createChat, mountRoot } = await import("./vendor/acornly/acornly-chat.js");
|
|
384
|
+
chat ??= createChat(mountRoot(), {
|
|
385
|
+
model: MODEL,
|
|
386
|
+
proxy: { url: MODEL_PROXY_URL, appId: APP_ID, token: auth.getToken },
|
|
387
|
+
rect,
|
|
388
|
+
onComment: (c) => acornly.add(contextNote(c)).then(() => {}),
|
|
389
|
+
onKeep: (k) => acornly.add(contextNote(k)).then(() => {}),
|
|
390
|
+
});
|
|
391
|
+
chat.setContext(snapshot());
|
|
392
|
+
chat.open();
|
|
393
|
+
};
|
|
394
|
+
```
|
|
395
|
+
|
|
396
|
+
**Updating it.** Run `pnpm vendor` again from a later `main` and commit the whole folder in one change; never edit the files. The bundle is 0.x like the chat: read the changelogs of `@acornly/ui` and `@acornly/sdk` between the two `VERSION` commits before taking it. Nothing is published to npm for this.
|
|
397
|
+
|
|
398
|
+
**What each app sets up for the chat** (the model calls run on the person's own key and budget):
|
|
399
|
+
|
|
400
|
+
- The app is registered on Acornly Cloud with its origin (the hub's Build console; the Bible is `interactive-bible` already, history needs its own app id with `https://history.scholeo.com`).
|
|
401
|
+
- Each person who tries it, test accounts first, connects a model key on the hub and sets an AI budget under Your AI. Either they let every app they approve use it ("Let every app I approve use my AI"), and the chat may spend a quarter of that budget across every uncapped app's chat, or they give the app a cap of its own under Apps you use (Manage, AI), for example $2 a month at 10 requests a minute, and the chat may spend a quarter of it: $0.50 a month (#711).
|
|
402
|
+
- Comments need no grant: they are notes, saved like the app's other notes.
|
package/dist/brand.d.ts
ADDED
|
@@ -0,0 +1,50 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Acornly's look, in one place: the default palettes of the built-in UI and the acorn marks.
|
|
3
|
+
* `theme.ts` builds the shell's defaults from these, and the extension's pages and page layer
|
|
4
|
+
* read them too, so every surface matches. The marks come from the brand assets (the sprout is
|
|
5
|
+
* "2b", the default icon); their colours stay the same in both schemes, only the stem follows the
|
|
6
|
+
* text colour.
|
|
7
|
+
*/
|
|
8
|
+
/** One color scheme's defaults, by theme token, plus the colours only Acornly's own pages use. */
|
|
9
|
+
export interface Palette {
|
|
10
|
+
accent: string;
|
|
11
|
+
accentContrast: string;
|
|
12
|
+
background: string;
|
|
13
|
+
foreground: string;
|
|
14
|
+
muted: string;
|
|
15
|
+
border: string;
|
|
16
|
+
highlight: string;
|
|
17
|
+
shadow: string;
|
|
18
|
+
/** Behind cards on Acornly's own pages (the hub, the extension's side panel). */
|
|
19
|
+
ground: string;
|
|
20
|
+
/** Personal things: the quoted passage's rule, counts. */
|
|
21
|
+
acorn: string;
|
|
22
|
+
}
|
|
23
|
+
/** Warm cream, with violet for actions. */
|
|
24
|
+
export declare const LIGHT: Palette;
|
|
25
|
+
/** Nocturne: deep blue-grey, with a softer violet. */
|
|
26
|
+
export declare const DARK: Palette;
|
|
27
|
+
/** Inter where the reader has it, then the system face. */
|
|
28
|
+
export declare const FONT = "Inter, system-ui, -apple-system, \"Segoe UI\", Roboto, \"Helvetica Neue\", Arial, sans-serif";
|
|
29
|
+
/** Corner radius of cards; buttons and fields inside them take `RADIUS - 6px`, list rows `- 4px`. */
|
|
30
|
+
export declare const RADIUS = "14px";
|
|
31
|
+
/** Fills painted behind notes on any page. One pair for both schemes: the page sets the ground. */
|
|
32
|
+
export declare const HIGHLIGHT_FILL = "rgb(236 178 110 / 0.4)";
|
|
33
|
+
export declare const HIGHLIGHT_ACTIVE_FILL = "rgb(236 178 110 / 0.72)";
|
|
34
|
+
/** One SVG element of a mark: its tag and attributes. */
|
|
35
|
+
export type Shape = [tag: "path" | "circle", attrs: Record<string, string>];
|
|
36
|
+
/** A mark: its shapes on a 64 unit square, and the part of the square they fill. */
|
|
37
|
+
export interface Mark {
|
|
38
|
+
viewBox: string;
|
|
39
|
+
shapes: readonly Shape[];
|
|
40
|
+
}
|
|
41
|
+
/** The sprout acorn, the logo. Its stem is `currentColor`, so it reads on any ground. */
|
|
42
|
+
export declare const SPROUT: Mark;
|
|
43
|
+
/** A plain acorn without stem or leaf, for small marks such as pins. */
|
|
44
|
+
export declare const ACORN: Mark;
|
|
45
|
+
/**
|
|
46
|
+
* Draws a mark as an `<svg>` element of `doc`, hidden from assistive tech. Built node by node
|
|
47
|
+
* rather than parsed, so it works on pages that enforce Trusted Types.
|
|
48
|
+
*/
|
|
49
|
+
export declare function drawMark(doc: Document, mark: Mark): SVGSVGElement;
|
|
50
|
+
//# sourceMappingURL=brand.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"brand.d.ts","sourceRoot":"","sources":["../src/brand.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAEH,kGAAkG;AAClG,MAAM,WAAW,OAAO;IACtB,MAAM,EAAE,MAAM,CAAC;IACf,cAAc,EAAE,MAAM,CAAC;IACvB,UAAU,EAAE,MAAM,CAAC;IACnB,UAAU,EAAE,MAAM,CAAC;IACnB,KAAK,EAAE,MAAM,CAAC;IACd,MAAM,EAAE,MAAM,CAAC;IACf,SAAS,EAAE,MAAM,CAAC;IAClB,MAAM,EAAE,MAAM,CAAC;IACf,iFAAiF;IACjF,MAAM,EAAE,MAAM,CAAC;IACf,0DAA0D;IAC1D,KAAK,EAAE,MAAM,CAAC;CACf;AAED,2CAA2C;AAC3C,eAAO,MAAM,KAAK,EAAE,OAWnB,CAAC;AAEF,sDAAsD;AACtD,eAAO,MAAM,IAAI,EAAE,OAWlB,CAAC;AAEF,2DAA2D;AAC3D,eAAO,MAAM,IAAI,iGAC2E,CAAC;AAE7F,qGAAqG;AACrG,eAAO,MAAM,MAAM,SAAS,CAAC;AAE7B,mGAAmG;AACnG,eAAO,MAAM,cAAc,2BAA2B,CAAC;AACvD,eAAO,MAAM,qBAAqB,4BAA4B,CAAC;AAO/D,yDAAyD;AACzD,MAAM,MAAM,KAAK,GAAG,CAAC,GAAG,EAAE,MAAM,GAAG,QAAQ,EAAE,KAAK,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC,CAAC;AAQ5E,oFAAoF;AACpF,MAAM,WAAW,IAAI;IACnB,OAAO,EAAE,MAAM,CAAC;IAChB,MAAM,EAAE,SAAS,KAAK,EAAE,CAAC;CAC1B;AAED,yFAAyF;AACzF,eAAO,MAAM,MAAM,EAAE,IAYpB,CAAC;AAEF,wEAAwE;AACxE,eAAO,MAAM,KAAK,EAAE,IAA+D,CAAC;AAIpF;;;GAGG;AACH,wBAAgB,QAAQ,CAAC,GAAG,EAAE,QAAQ,EAAE,IAAI,EAAE,IAAI,GAAG,aAAa,CAWjE"}
|
package/dist/brand.js
ADDED
|
@@ -0,0 +1,84 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Acornly's look, in one place: the default palettes of the built-in UI and the acorn marks.
|
|
3
|
+
* `theme.ts` builds the shell's defaults from these, and the extension's pages and page layer
|
|
4
|
+
* read them too, so every surface matches. The marks come from the brand assets (the sprout is
|
|
5
|
+
* "2b", the default icon); their colours stay the same in both schemes, only the stem follows the
|
|
6
|
+
* text colour.
|
|
7
|
+
*/
|
|
8
|
+
/** Warm cream, with violet for actions. */
|
|
9
|
+
export const LIGHT = {
|
|
10
|
+
accent: "#6253a8",
|
|
11
|
+
accentContrast: "#fffdf9",
|
|
12
|
+
background: "#fffdf9",
|
|
13
|
+
foreground: "#30231b",
|
|
14
|
+
muted: "#645850",
|
|
15
|
+
border: "#d6d0c9",
|
|
16
|
+
highlight: "rgb(236 178 110 / 0.4)",
|
|
17
|
+
shadow: "0 8px 24px rgb(48 35 27 / 0.1), 0 1px 2px rgb(48 35 27 / 0.08)",
|
|
18
|
+
ground: "#fbf6ee",
|
|
19
|
+
acorn: "#b47548",
|
|
20
|
+
};
|
|
21
|
+
/** Nocturne: deep blue-grey, with a softer violet. */
|
|
22
|
+
export const DARK = {
|
|
23
|
+
accent: "#9184d9",
|
|
24
|
+
accentContrast: "#161826",
|
|
25
|
+
background: "#232532",
|
|
26
|
+
foreground: "#e9e9ed",
|
|
27
|
+
muted: "#b2b6ca",
|
|
28
|
+
border: "#3f424d",
|
|
29
|
+
highlight: "rgb(193 129 84 / 0.34)",
|
|
30
|
+
shadow: "0 8px 24px rgb(0 0 0 / 0.5), 0 1px 3px rgb(0 0 0 / 0.4)",
|
|
31
|
+
ground: "#161826",
|
|
32
|
+
acorn: "#eeae7b",
|
|
33
|
+
};
|
|
34
|
+
/** Inter where the reader has it, then the system face. */
|
|
35
|
+
export const FONT = 'Inter, system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif';
|
|
36
|
+
/** Corner radius of cards; buttons and fields inside them take `RADIUS - 6px`, list rows `- 4px`. */
|
|
37
|
+
export const RADIUS = "14px";
|
|
38
|
+
/** Fills painted behind notes on any page. One pair for both schemes: the page sets the ground. */
|
|
39
|
+
export const HIGHLIGHT_FILL = "rgb(236 178 110 / 0.4)";
|
|
40
|
+
export const HIGHLIGHT_ACTIVE_FILL = "rgb(236 178 110 / 0.72)";
|
|
41
|
+
const NUT = "#c18154";
|
|
42
|
+
const CAP = "#84573e";
|
|
43
|
+
const LEAF = "#8dca80";
|
|
44
|
+
const CHEEK = "#dfb585";
|
|
45
|
+
const NUT_SHAPE = ["path", { d: "M13 30C13 48 22 58 32 58S51 48 51 30Z", fill: NUT }];
|
|
46
|
+
const CAP_SHAPE = [
|
|
47
|
+
"path",
|
|
48
|
+
{ d: "M9 31C9 18 19 11 32 11S55 18 55 31c0 2-2 3-4 3H13c-2 0-4-1-4-3Z", fill: CAP },
|
|
49
|
+
];
|
|
50
|
+
/** The sprout acorn, the logo. Its stem is `currentColor`, so it reads on any ground. */
|
|
51
|
+
export const SPROUT = {
|
|
52
|
+
viewBox: "0 0 64 64",
|
|
53
|
+
shapes: [
|
|
54
|
+
NUT_SHAPE,
|
|
55
|
+
CAP_SHAPE,
|
|
56
|
+
[
|
|
57
|
+
"path",
|
|
58
|
+
{ d: "M32 11V6", stroke: "currentColor", "stroke-width": "3", "stroke-linecap": "round" },
|
|
59
|
+
],
|
|
60
|
+
["path", { d: "M33 7c3-6 11-7 16-5-2 6-9 9-16 5Z", fill: LEAF }],
|
|
61
|
+
["circle", { cx: "23", cy: "42", r: "3.5", fill: CHEEK, opacity: ".6" }],
|
|
62
|
+
],
|
|
63
|
+
};
|
|
64
|
+
/** A plain acorn without stem or leaf, for small marks such as pins. */
|
|
65
|
+
export const ACORN = { viewBox: "8 8 48 52", shapes: [NUT_SHAPE, CAP_SHAPE] };
|
|
66
|
+
const SVG_NS = "http://www.w3.org/2000/svg";
|
|
67
|
+
/**
|
|
68
|
+
* Draws a mark as an `<svg>` element of `doc`, hidden from assistive tech. Built node by node
|
|
69
|
+
* rather than parsed, so it works on pages that enforce Trusted Types.
|
|
70
|
+
*/
|
|
71
|
+
export function drawMark(doc, mark) {
|
|
72
|
+
const svg = doc.createElementNS(SVG_NS, "svg");
|
|
73
|
+
svg.setAttribute("viewBox", mark.viewBox);
|
|
74
|
+
svg.setAttribute("aria-hidden", "true");
|
|
75
|
+
svg.setAttribute("focusable", "false");
|
|
76
|
+
for (const [tag, attrs] of mark.shapes) {
|
|
77
|
+
const shape = doc.createElementNS(SVG_NS, tag);
|
|
78
|
+
for (const [key, value] of Object.entries(attrs))
|
|
79
|
+
shape.setAttribute(key, value);
|
|
80
|
+
svg.append(shape);
|
|
81
|
+
}
|
|
82
|
+
return svg;
|
|
83
|
+
}
|
|
84
|
+
//# sourceMappingURL=brand.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"brand.js","sourceRoot":"","sources":["../src/brand.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAkBH,2CAA2C;AAC3C,MAAM,CAAC,MAAM,KAAK,GAAY;IAC5B,MAA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YAAY,CAAC,GAAG,EAAE,KAAK,CAAC,CAAC;QACjF,GAAG,CAAC,MAAM,CAAC,KAAK,CAAC,CAAC;IACpB,CAAC;IACD,OAAO,GAAG,CAAC;AACb,CAAC"}
|
package/dist/card.d.ts
CHANGED
|
@@ -30,8 +30,12 @@ export interface CardLabels {
|
|
|
30
30
|
remove: string;
|
|
31
31
|
/** The link to report a note, which opens the report form in a new tab. */
|
|
32
32
|
report: string;
|
|
33
|
+
/** Copies the link that shares a note with anyone who opens it. */
|
|
34
|
+
link: string;
|
|
33
35
|
/** An action button's accessible name, telling one note's from the next. */
|
|
34
36
|
action: (action: string, author: string) => string;
|
|
37
|
+
/** The alternative text of the screenshot of the region a note is on (#311). */
|
|
38
|
+
regionImage: string;
|
|
35
39
|
}
|
|
36
40
|
export declare const DEFAULT_CARD_LABELS: CardLabels;
|
|
37
41
|
/**
|
|
@@ -53,6 +57,10 @@ export interface CardActions {
|
|
|
53
57
|
* new tab), or null for no link. Default: none.
|
|
54
58
|
*/
|
|
55
59
|
report?: (annotation: Annotation) => string | null;
|
|
60
|
+
/** Copies a link that shares the note, for notes `canLink` allows. */
|
|
61
|
+
link?: (annotation: Annotation, button: HTMLElement) => void;
|
|
62
|
+
/** Whether this note has a link to copy, typically the reader's own shared by link. Default: none. */
|
|
63
|
+
canLink?: (annotation: Annotation) => boolean;
|
|
56
64
|
}
|
|
57
65
|
export interface CardOptions {
|
|
58
66
|
/** The shell's layer (`layerOf(root)`). */
|
|
@@ -67,6 +75,16 @@ export interface CardOptions {
|
|
|
67
75
|
viewerId?: string;
|
|
68
76
|
/** The viewer's profile photo (an https URL), shown next to their own notes. */
|
|
69
77
|
viewerPicture?: string;
|
|
78
|
+
/**
|
|
79
|
+
* Whether a note is the viewer's own, shown as {@link CardLabels.me} with their photo. Default:
|
|
80
|
+
* its creator's id is `viewerId`.
|
|
81
|
+
*/
|
|
82
|
+
isMine?: (annotation: Annotation) => boolean;
|
|
83
|
+
/**
|
|
84
|
+
* Draws an initial in a coloured circle before the names of other people's notes, as their
|
|
85
|
+
* avatar, its colour picked by their id. Default false.
|
|
86
|
+
*/
|
|
87
|
+
initials?: boolean;
|
|
70
88
|
/** App-defined body types. */
|
|
71
89
|
registry?: BodyTypeLookup;
|
|
72
90
|
/** Called once when the card closes, whatever closed it. */
|
|
@@ -74,7 +92,7 @@ export interface CardOptions {
|
|
|
74
92
|
/**
|
|
75
93
|
* Focused when the card closes. Defaults to the anchor when it is an element (a pin or a panel
|
|
76
94
|
* row), else to what had focus when the card opened. If that element has been re-rendered,
|
|
77
|
-
* the element with the same `data-id` is focused instead.
|
|
95
|
+
* the element with the same `data-id` (a panel row; pins carry none) is focused instead.
|
|
78
96
|
*/
|
|
79
97
|
returnFocusTo?: HTMLElement;
|
|
80
98
|
/** Close when the pointer goes down outside the card and its anchor. Default true. */
|
|
@@ -84,6 +102,11 @@ export interface CardOptions {
|
|
|
84
102
|
actions?: CardActions;
|
|
85
103
|
/** Formats a note's time. Defaults to the viewer's locale, date and time. */
|
|
86
104
|
formatTime?: (iso: string) => string;
|
|
105
|
+
/**
|
|
106
|
+
* Who besides its author can see a note, shown after its time, such as "Visible to Lab" on a
|
|
107
|
+
* circle note; null for nothing. Default: nothing.
|
|
108
|
+
*/
|
|
109
|
+
audience?: (annotation: Annotation) => string | null;
|
|
87
110
|
}
|
|
88
111
|
export interface NoteCard {
|
|
89
112
|
/** The card element, inside the shell's layer. */
|
package/dist/card.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"card.d.ts","sourceRoot":"","sources":["../src/card.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AACH,OAAO,EAOL,KAAK,gBAAgB,EACtB,MAAM,kBAAkB,CAAC;AAC1B,OAAO,
|
|
1
|
+
{"version":3,"file":"card.d.ts","sourceRoot":"","sources":["../src/card.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AACH,OAAO,EAOL,KAAK,gBAAgB,EACtB,MAAM,kBAAkB,CA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rB;;;;OAIG;IACH,aAAa,CAAC,EAAE,WAAW,CAAC;IAC5B,sFAAsF;IACtF,mBAAmB,CAAC,EAAE,OAAO,CAAC;IAC9B,MAAM,CAAC,EAAE,OAAO,CAAC,UAAU,CAAC,CAAC;IAC7B,sFAAsF;IACtF,OAAO,CAAC,EAAE,WAAW,CAAC;IACtB,6EAA6E;IAC7E,UAAU,CAAC,EAAE,CAAC,GAAG,EAAE,MAAM,KAAK,MAAM,CAAC;IACrC;;;OAGG;IACH,QAAQ,CAAC,EAAE,CAAC,UAAU,EAAE,UAAU,KAAK,MAAM,GAAG,IAAI,CAAC;CACtD;AAED,MAAM,WAAW,QAAQ;IACvB,kDAAkD;IAClD,QAAQ,CAAC,OAAO,EAAE,WAAW,CAAC;IAC9B,QAAQ,CAAC,MAAM,EAAE,OAAO,CAAC;IACzB,0EAA0E;IAC1E,MAAM,CAAC,MAAM,EAAE,UAAU,EAAE,OAAO,CAAC,EAAE;QAAE,WAAW,CAAC,EAAE,OAAO,CAAA;KAAE,GAAG,IAAI,CAAC;IACtE,KAAK,IAAI,IAAI,CAAC;CACf;AA4HD;;;;GAIG;AACH,wBAAgB,QAAQ,CAAC,OAAO,EAAE,WAAW,GAAG,QAAQ,CAqUvD"}
|
package/dist/card.js
CHANGED
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
* renderer, so neither sits on the page-load path.
|
|
5
5
|
*/
|
|
6
6
|
import { autoUpdate, computePosition, flip, offset, shift, size, } from "@floating-ui/dom";
|
|
7
|
-
import { countReactions, kindOf, } from "@acornly/core";
|
|
7
|
+
import { countReactions, kindOf, readRegionImage, } from "@acornly/core";
|
|
8
8
|
import { h, styleElement } from "./dom.js";
|
|
9
9
|
import { activeElement, tabbables, trapFocus } from "./focus.js";
|
|
10
10
|
import { renderBody } from "./markdown/render.js";
|
|
@@ -12,6 +12,7 @@ import { PARTS } from "./parts.js";
|
|
|
12
12
|
/** Replies are indented up to this many levels; deeper ones are shown flat with a label. */
|
|
13
13
|
export const MAX_INDENT = 3;
|
|
14
14
|
export const DEFAULT_CARD_LABELS = {
|
|
15
|
+
regionImage: "Screenshot of the area this note is on",
|
|
15
16
|
close: "Close",
|
|
16
17
|
approximate: "Approximate: the text changed since this note was written.",
|
|
17
18
|
edited: "edited",
|
|
@@ -26,6 +27,7 @@ export const DEFAULT_CARD_LABELS = {
|
|
|
26
27
|
edit: "Edit",
|
|
27
28
|
remove: "Delete",
|
|
28
29
|
report: "Report",
|
|
30
|
+
link: "Copy link",
|
|
29
31
|
action: (action, author) => `${action}, note by ${author}`,
|
|
30
32
|
};
|
|
31
33
|
const CARD_CSS = `
|
|
@@ -38,7 +40,7 @@ const CARD_CSS = `
|
|
|
38
40
|
box-sizing: border-box;
|
|
39
41
|
width: min(360px, calc(100vw - 16px));
|
|
40
42
|
overflow: auto;
|
|
41
|
-
padding:
|
|
43
|
+
padding: 14px 16px;
|
|
42
44
|
background: var(--_background);
|
|
43
45
|
color: var(--_foreground);
|
|
44
46
|
border: 1px solid var(--_border);
|
|
@@ -54,7 +56,7 @@ const CARD_CSS = `
|
|
|
54
56
|
float: right;
|
|
55
57
|
margin: -4px -6px 0 8px;
|
|
56
58
|
padding: 2px 6px;
|
|
57
|
-
border-radius: var(--_radius);
|
|
59
|
+
border-radius: calc(var(--_radius) - 6px);
|
|
58
60
|
color: var(--_muted);
|
|
59
61
|
font-size: 18px;
|
|
60
62
|
line-height: 1;
|
|
@@ -71,10 +73,13 @@ const CARD_CSS = `
|
|
|
71
73
|
.ctx-entry[data-level="3"] { margin-left: 42px; }
|
|
72
74
|
.ctx-entry:first-child { padding-top: 0; }
|
|
73
75
|
.ctx-meta { display: flex; flex-wrap: wrap; gap: 6px; align-items: baseline; color: var(--_muted); font-size: 0.86em; }
|
|
74
|
-
.ctx-author { color: var(--_foreground); font-weight:
|
|
76
|
+
.ctx-author { color: var(--_foreground); font-weight: 500; }
|
|
77
|
+
.ctx-audience { border: 1px solid var(--_border); border-radius: 999px; padding: 0 6px; }
|
|
75
78
|
.ctx-avatar { align-self: center; width: 20px; height: 20px; border-radius: 50%; object-fit: cover; }
|
|
79
|
+
.ctx-initial { align-self: center; display: inline-grid; place-items: center; width: 20px; height: 20px; border-radius: 50%; color: #fff; font-size: 11px; font-weight: 600; line-height: 1; }
|
|
76
80
|
.ctx-replying, .ctx-deleted { color: var(--_muted); font-size: 0.86em; }
|
|
77
81
|
.ctx-deleted { font-style: italic; }
|
|
82
|
+
.ctx-region-image { display: block; max-width: 100%; height: auto; margin-top: 6px; border: 1px solid var(--_border); border-radius: var(--_radius); }
|
|
78
83
|
.ctx-body { margin-top: 4px; overflow-wrap: anywhere; }
|
|
79
84
|
.ctx-body p, .ctx-body ul, .ctx-body ol, .ctx-body pre, .ctx-body blockquote, .ctx-body table { margin: 0 0 6px; }
|
|
80
85
|
.ctx-body a { color: var(--_accent); }
|
|
@@ -83,12 +88,12 @@ const CARD_CSS = `
|
|
|
83
88
|
.ctx-body .ctx-align-left { text-align: left; }
|
|
84
89
|
.ctx-body .ctx-align-center { text-align: center; }
|
|
85
90
|
.ctx-body .ctx-align-right { text-align: right; }
|
|
86
|
-
.ctx-body blockquote { padding-left: 8px; border-left: 3px solid var(--
|
|
91
|
+
.ctx-body blockquote { padding-left: 8px; border-left: 3px solid var(--_highlight); color: var(--_muted); }
|
|
87
92
|
.ctx-reactions { display: flex; flex-wrap: wrap; gap: 4px; margin-top: 6px; }
|
|
88
93
|
.ctx-reactions li { padding: 1px 7px; border: 1px solid var(--_border); border-radius: 999px; font-size: 0.86em; }
|
|
89
94
|
.ctx-reactions li[data-mine] { border-color: var(--_accent); }
|
|
90
95
|
.ctx-entry-actions { display: flex; gap: 2px; margin: 4px 0 0 -6px; }
|
|
91
|
-
.ctx-entry-actions button, .ctx-entry-actions a { all: unset; padding: 1px 6px; border-radius: var(--_radius); color: var(--_muted); font-size: 0.86em; cursor: pointer; }
|
|
96
|
+
.ctx-entry-actions button, .ctx-entry-actions a { all: unset; padding: 1px 6px; border-radius: calc(var(--_radius) - 6px); color: var(--_muted); font-size: 0.86em; cursor: pointer; }
|
|
92
97
|
.ctx-entry-actions button:hover, .ctx-entry-actions a:hover { color: var(--_foreground); }
|
|
93
98
|
.ctx-entry-actions button:focus-visible, .ctx-entry-actions a:focus-visible { outline: 2px solid var(--_accent); }
|
|
94
99
|
`;
|
|
@@ -148,12 +153,18 @@ export function openCard(options) {
|
|
|
148
153
|
let thread = options.thread;
|
|
149
154
|
let approximate = options.approximate === true;
|
|
150
155
|
let closed = false;
|
|
151
|
-
const mine = (a) => options.
|
|
156
|
+
const mine = (a) => options.isMine
|
|
157
|
+
? options.isMine(a)
|
|
158
|
+
: options.viewerId !== undefined && a.creator?.id === options.viewerId;
|
|
152
159
|
const authorOf = (a) => a.ext.deleted
|
|
153
160
|
? labels.anonymous
|
|
154
161
|
: mine(a)
|
|
155
162
|
? labels.me
|
|
156
163
|
: a.creator?.name?.trim() || labels.anonymous;
|
|
164
|
+
const audienceLabel = (a) => {
|
|
165
|
+
const text = options.audience?.(a);
|
|
166
|
+
return text ? h(doc, "span", { class: "ctx-audience" }, text) : null;
|
|
167
|
+
};
|
|
157
168
|
const picture = httpsUrl(options.viewerPicture);
|
|
158
169
|
/** The viewer's photo, decorative: their name is next to it. Hidden if it fails to load. */
|
|
159
170
|
const avatar = () => {
|
|
@@ -171,6 +182,20 @@ export function openCard(options) {
|
|
|
171
182
|
img.addEventListener("error", () => img.remove(), { once: true });
|
|
172
183
|
return img;
|
|
173
184
|
};
|
|
185
|
+
/** Another author's initial in a circle of a colour their id picks; decorative, by their name. */
|
|
186
|
+
const initial = (a) => {
|
|
187
|
+
const name = a.creator?.name?.trim();
|
|
188
|
+
if (!options.initials || !a.creator || !name || mine(a))
|
|
189
|
+
return null;
|
|
190
|
+
const letter = [...name][0].toLocaleUpperCase();
|
|
191
|
+
let hash = 0;
|
|
192
|
+
for (const c of a.creator.id)
|
|
193
|
+
hash = (hash * 31 + c.charCodeAt(0)) >>> 0;
|
|
194
|
+
const badge = h(doc, "span", { class: "ctx-initial", "aria-hidden": "true" }, letter);
|
|
195
|
+
// Through the CSSOM, which a page's policy against inline styles allows.
|
|
196
|
+
badge.style.background = `hsl(${hash % 360} 45% 40%)`;
|
|
197
|
+
return badge;
|
|
198
|
+
};
|
|
174
199
|
const closeButton = h(doc, "button", { type: "button", class: "ctx-card-close", "aria-label": labels.close }, "×");
|
|
175
200
|
const content = h(doc, "div", { class: "ctx-card-content" });
|
|
176
201
|
const card = h(doc, "section", { class: "ctx-card", part: PARTS.card, role: "dialog", tabindex: "-1" }, styleElement(doc, CARD_CSS), closeButton, content);
|
|
@@ -181,13 +206,27 @@ export function openCard(options) {
|
|
|
181
206
|
"data-id": a.id,
|
|
182
207
|
"data-level": String(row.level),
|
|
183
208
|
});
|
|
184
|
-
const meta = h(doc, "div", { class: "ctx-meta" }, !a.ext.deleted && mine(a)
|
|
209
|
+
const meta = h(doc, "div", { class: "ctx-meta" }, !a.ext.deleted && (mine(a) ? avatar() : initial(a)), h(doc, "span", { class: "ctx-author" }, authorOf(a)), h(doc, "time", { datetime: a.created }, formatTime(a.created)), a.ext.edited === true &&
|
|
185
210
|
!a.ext.deleted &&
|
|
186
|
-
h(doc, "span", { class: "ctx-edited" }, labels.edited));
|
|
211
|
+
h(doc, "span", { class: "ctx-edited" }, labels.edited), !a.ext.deleted && audienceLabel(a));
|
|
187
212
|
li.append(meta);
|
|
188
213
|
if (row.replyingTo !== null) {
|
|
189
214
|
li.append(h(doc, "div", { class: "ctx-replying" }, labels.replyingTo(authorOf(row.replyingTo))));
|
|
190
215
|
}
|
|
216
|
+
// What a note on a region of a canvas app's document was made on; hidden if it fails to load
|
|
217
|
+
// (a host page's policy may refuse data: images).
|
|
218
|
+
const shot = a.ext.deleted ? null : readRegionImage(a.ext.regionImage);
|
|
219
|
+
if (shot) {
|
|
220
|
+
const img = h(doc, "img", {
|
|
221
|
+
class: "ctx-region-image",
|
|
222
|
+
src: shot.src,
|
|
223
|
+
alt: labels.regionImage,
|
|
224
|
+
width: String(shot.width),
|
|
225
|
+
height: String(shot.height),
|
|
226
|
+
});
|
|
227
|
+
img.addEventListener("error", () => img.remove(), { once: true });
|
|
228
|
+
li.append(img);
|
|
229
|
+
}
|
|
191
230
|
if (a.ext.deleted) {
|
|
192
231
|
li.append(h(doc, "div", { class: "ctx-deleted" }, labels.deleted));
|
|
193
232
|
}
|
|
@@ -218,6 +257,7 @@ export function openCard(options) {
|
|
|
218
257
|
["reply", !a.ext.locked && (actions.canReply?.(a) ?? true) && actions.reply],
|
|
219
258
|
["edit", mine && (actions.canEdit?.(a) ?? true) && actions.edit],
|
|
220
259
|
["remove", mine && actions.remove],
|
|
260
|
+
["link", (actions.canLink?.(a) ?? false) && actions.link],
|
|
221
261
|
].flatMap(([name, run]) => {
|
|
222
262
|
if (!run)
|
|
223
263
|
return [];
|
package/dist/card.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"card.js","sourceRoot":"","sources":["../src/card.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AACH,OAAO,EACL,UAAU,EACV,eAAe,EACf,IAAI,EACJ,MAAM,EACN,KAAK,EACL,IAAI,GAEL,MAAM,kBAAkB,CAAC;AAC1B,OAAO,EACL,cAAc,EACd,MAAM,GAIP,MAAM,eAAe,CAAC;AACvB,OAAO,EAAE,CAAC,EAAE,YAAY,EAAE,MAAM,UAAU,CAAC;AAC3C,OAAO,EAAE,aAAa,EAAE,SAAS,EAAE,SAAS,EAAE,MAAM,YAAY,CAAC;AACjE,OAAO,EAAE,UAAU,EAAE,MAAM,sBAAsB,CAAC;AAClD,OAAO,EAAE,KAAK,EAAE,MAAM,YAAY,CAAC;AAEnC,4FAA4F;AAC5F,MAAM,CAAC,MAAM,UAAU,GAAG,CAAC,CAAC;AA6B5B,MAAM,CAAC,MAAM,mBAAmB,GAAe;IAC7C,KAAK,EAAE,OAAO;IACd,WAAW,EAAE,4DAA4D;IACzE,MAAM,EAAE,QAAQ;IACh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