@formicoidea/labre-core 0.60.0 → 0.61.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/architecture/code.c4 +28 -23
- package/architecture/likec4.config.json +3 -3
- package/dist/_pkgs/affine-block-attachment/asset-picker.d.ts +8 -0
- package/dist/_pkgs/affine-block-attachment/asset-picker.js +25 -1
- package/dist/_pkgs/affine-block-attachment/attachment-block.js +9 -7
- package/dist/_pkgs/affine-block-database/database-block.js +4 -5
- package/dist/_pkgs/affine-block-database/service/index.d.ts +1 -0
- package/dist/_pkgs/affine-block-database/service/index.js +1 -0
- package/dist/_pkgs/affine-block-database/service/initial-view.d.ts +33 -0
- package/dist/_pkgs/affine-block-database/service/initial-view.js +20 -0
- package/dist/_pkgs/affine-block-database/utils/current-view.d.ts +7 -0
- package/dist/_pkgs/affine-block-database/utils/current-view.js +14 -0
- package/dist/_pkgs/affine-block-embed/common/render-linked-doc.js +2 -0
- package/dist/_pkgs/affine-block-embed-doc/common/child-card.d.ts +25 -0
- package/dist/_pkgs/affine-block-embed-doc/common/child-card.js +27 -0
- package/dist/_pkgs/affine-block-embed-doc/embed-linked-doc-block/commands/insert-embed-linked-doc.js +6 -1
- package/dist/_pkgs/affine-block-embed-doc/embed-linked-doc-block/configs/new-doc.js +2 -2
- package/dist/_pkgs/affine-block-embed-doc/embed-linked-doc-block/embed-linked-doc-block.js +2 -6
- package/dist/_pkgs/affine-block-embed-doc/embed-synced-doc-block/embed-synced-doc-block.js +2 -3
- package/dist/_pkgs/affine-block-embed-doc/page-drop/page-drop.js +3 -3
- package/dist/_pkgs/affine-block-surface/extensions/reading-toolbar.js +12 -12
- package/dist/_pkgs/affine-components/highlight-dropdown-menu/highlight-duotone-icon.js +8 -8
- package/dist/_pkgs/affine-components/highlight-dropdown-menu/text-duotone-icon.js +11 -11
- package/dist/_pkgs/affine-components/icons/loading.d.ts +6 -0
- package/dist/_pkgs/affine-components/icons/loading.js +16 -12
- package/dist/_pkgs/affine-fragment-doc-title/title-band/show-here.js +2 -2
- package/dist/_pkgs/affine-fragment-doc-title/title-band/title-band.d.ts +8 -0
- package/dist/_pkgs/affine-fragment-doc-title/title-band/title-band.js +35 -13
- package/dist/_pkgs/affine-fragment-doc-title/translations.d.ts +1 -1
- package/dist/_pkgs/affine-fragment-doc-title/translations.js +1 -1
- package/dist/_pkgs/affine-gfx-mindmap/toolbar/basket-elements.d.ts +12 -0
- package/dist/_pkgs/affine-gfx-mindmap/toolbar/basket-elements.js +44 -5
- package/dist/_pkgs/affine-gfx-mindmap/toolbar/senior-tool.d.ts +3 -2
- package/dist/_pkgs/affine-gfx-mindmap/toolbar/senior-tool.js +3 -2
- package/dist/_pkgs/affine-gfx-template/builtin/slides/build.js +10 -10
- package/dist/_pkgs/affine-gfx-template/builtin/slides/consts.d.ts +48 -64
- package/dist/_pkgs/affine-gfx-template/builtin/slides/consts.js +24 -21
- package/dist/_pkgs/affine-gfx-template/builtin/slides/masks.d.ts +1 -2
- package/dist/_pkgs/affine-gfx-template/builtin/slides/masks.js +0 -34
- package/dist/_pkgs/affine-inline-reference/reference-node/configs/toolbar.js +2 -1
- package/dist/_pkgs/affine-shared/consts/index.d.ts +9 -0
- package/dist/_pkgs/affine-shared/consts/index.js +9 -0
- package/dist/_pkgs/affine-shared/services/asset-picker-service.d.ts +7 -6
- package/dist/_pkgs/affine-shared/services/asset-picker-service.js +5 -5
- package/dist/_pkgs/affine-shared/services/title-band-service.d.ts +19 -0
- package/dist/_pkgs/affine-widget-edgeless-zoom-toolbar/index.js +26 -26
- package/dist/_pkgs/affine-widget-keyboard-toolbar/icons.js +98 -98
- package/dist/_pkgs/affine-widget-page-dragging-area/index.js +10 -10
- package/dist/_pkgs/affine-widget-viewport-overlay/index.js +13 -13
- package/dist/_pkgs/data-view/core/component/cell-status/cell-status-css.d.ts +1 -1
- package/dist/_pkgs/data-view/core/component/cell-status/cell-status-css.js +10 -10
- package/dist/_pkgs/data-view/core/component/cell-status/cell-status.d.ts +1 -1
- package/dist/_pkgs/data-view/core/component/cell-status/cell-status.js +7 -5
- package/dist/_pkgs/data-view/core/utils/menu-title.js +17 -17
- package/dist/_pkgs/data-view/property-presets/number/cell-renderer.d.ts +18 -0
- package/dist/_pkgs/data-view/property-presets/number/cell-renderer.js +51 -10
- package/dist/_pkgs/data-view/property-presets/text/cell-renderer.d.ts +23 -1
- package/dist/_pkgs/data-view/property-presets/text/cell-renderer.js +56 -15
- package/dist/_pkgs/data-view/property-presets/typing-commit.d.ts +16 -0
- package/dist/_pkgs/data-view/property-presets/typing-commit.js +27 -0
- package/dist/_pkgs/data-view/view-presets/list/list-view.js +1 -1
- package/package.json +1 -1
|
@@ -2,9 +2,9 @@ import { DefaultTheme, FontWeight } from '../../../affine-model/index.js';
|
|
|
2
2
|
import { HEADING_SCALE } from '../../../affine-shared/consts/index.js';
|
|
3
3
|
import { darkThemeV2, lightThemeV2 } from '@toeverything/theme/v2';
|
|
4
4
|
/**
|
|
5
|
-
* The slide masks' one system: geometry, typography and the
|
|
6
|
-
*
|
|
7
|
-
*
|
|
5
|
+
* The slide masks' one system: geometry, typography and the one paper.
|
|
6
|
+
* Every mask in `masks.ts` reads these and restates none of them, so a size
|
|
7
|
+
* or a colour changes here, once, for the whole set.
|
|
8
8
|
*/
|
|
9
9
|
/** A 16:9 slide, the frame menu's own `16:9` preset (1600 × 900). */
|
|
10
10
|
export const SLIDE_WIDTH = 1600;
|
|
@@ -74,25 +74,28 @@ const NOTE_GREY = {
|
|
|
74
74
|
light: lightThemeV2['edgeless/note/grey'],
|
|
75
75
|
};
|
|
76
76
|
/**
|
|
77
|
-
*
|
|
78
|
-
*
|
|
79
|
-
*
|
|
77
|
+
* One paper for every mask: white, turning dark grey on a dark canvas. The
|
|
78
|
+
* set once had an `inverse` black slide (section, statement, quote); the PO
|
|
79
|
+
* wants every slide of a deck on white (recette of 0.60), so a deck reads as
|
|
80
|
+
* one sheet and prints as one.
|
|
81
|
+
*
|
|
82
|
+
* Words reach WCAG AA (4.5:1) on both sides of the paper, which the base
|
|
83
|
+
* palette's medium grey does not (`#929292` on white is 3.1:1): secondary
|
|
84
|
+
* words are set in ink, and their tone is carried by their role's size.
|
|
85
|
+
* The medium grey stays for rules and outlines, where 3:1 is the bar.
|
|
86
|
+
*
|
|
87
|
+
* ponytail: `muted` is the ink pair, so a muted line looks like an ink one
|
|
88
|
+
* at the same size. The ceiling is a deck with no tonal step between a
|
|
89
|
+
* heading and its detail; the upgrade is a darker grey `{ light, dark }`
|
|
90
|
+
* pair in the base palette (one AA on white and on `#252525`), set here.
|
|
80
91
|
*/
|
|
81
|
-
export const
|
|
82
|
-
paper:
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
},
|
|
89
|
-
inverse: {
|
|
90
|
-
paper: DefaultTheme.black,
|
|
91
|
-
ink: DefaultTheme.white,
|
|
92
|
-
muted: MEDIUM_GREY,
|
|
93
|
-
hairline: MEDIUM_GREY,
|
|
94
|
-
zoneStroke: MEDIUM_GREY,
|
|
95
|
-
},
|
|
92
|
+
export const SLIDE_PALETTE = {
|
|
93
|
+
paper: DefaultTheme.NoteBackgroundColorMap['White'],
|
|
94
|
+
ink: DefaultTheme.black,
|
|
95
|
+
muted: DefaultTheme.black,
|
|
96
|
+
rule: MEDIUM_GREY,
|
|
97
|
+
hairline: NOTE_GREY,
|
|
98
|
+
zoneStroke: MEDIUM_GREY,
|
|
96
99
|
};
|
|
97
100
|
/** Stroke widths, model units. */
|
|
98
101
|
export const SLIDE_HAIRLINE_WIDTH = 2;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import type { ChromeWording, TranslationParams } from '../../../affine-shared/services/index.js';
|
|
2
|
-
import { type SlideTextRole
|
|
2
|
+
import { type SlideTextRole } from './consts.js';
|
|
3
3
|
/**
|
|
4
4
|
* The slide masks, as DATA: a mask is the list of its zones, and one builder
|
|
5
5
|
* (`build.ts`) projects every mask into a frame, its elements and its preview.
|
|
@@ -76,7 +76,6 @@ export type SlideMask = {
|
|
|
76
76
|
name: ChromeWording;
|
|
77
77
|
/** Plain English search words besides the name (`Template.keywords`). */
|
|
78
78
|
keywords: string[];
|
|
79
|
-
variant: SlideVariant;
|
|
80
79
|
zones: SlideZone[];
|
|
81
80
|
};
|
|
82
81
|
/** Every mask, in the panel's order: a deck reads top to bottom. */
|
|
@@ -53,7 +53,6 @@ const cover = {
|
|
|
53
53
|
id: 'cover',
|
|
54
54
|
name: SLIDE_NAME_COVER,
|
|
55
55
|
keywords: ['cover', 'title', 'opening', 'first slide', 'pitch'],
|
|
56
|
-
variant: 'paper',
|
|
57
56
|
zones: [
|
|
58
57
|
text('caption', SLIDE_SEED_EYEBROW, M, 330, CONTENT, {
|
|
59
58
|
...centred,
|
|
@@ -67,7 +66,6 @@ const coverImage = {
|
|
|
67
66
|
id: 'cover-image',
|
|
68
67
|
name: SLIDE_NAME_COVER_IMAGE,
|
|
69
68
|
keywords: ['cover', 'title', 'tagline', 'picture', 'photo', 'hero'],
|
|
70
|
-
variant: 'paper',
|
|
71
69
|
zones: [
|
|
72
70
|
text('display', SLIDE_SEED_COVER_TITLE, M, 330, 620, { lines: 2 }),
|
|
73
71
|
text('body', SLIDE_SEED_SUBTITLE, M, 500, 620, { lines: 2, ...muted }),
|
|
@@ -78,7 +76,6 @@ const section = {
|
|
|
78
76
|
id: 'section',
|
|
79
77
|
name: SLIDE_NAME_SECTION,
|
|
80
78
|
keywords: ['section', 'divider', 'chapter', 'break', 'part'],
|
|
81
|
-
variant: 'inverse',
|
|
82
79
|
zones: [
|
|
83
80
|
text('display', SLIDE_SEED_SECTION_TITLE, M, 600, CONTENT),
|
|
84
81
|
text('body', SLIDE_SEED_SECTION_SUBTITLE, M, 690, CONTENT, muted),
|
|
@@ -88,7 +85,6 @@ const statement = {
|
|
|
88
85
|
id: 'statement',
|
|
89
86
|
name: SLIDE_NAME_STATEMENT,
|
|
90
87
|
keywords: ['statement', 'big idea', 'headline', 'message', 'claim'],
|
|
91
|
-
variant: 'inverse',
|
|
92
88
|
zones: [
|
|
93
89
|
text('caption', SLIDE_SEED_SUBTITLE, M, 300, CONTENT, muted),
|
|
94
90
|
text('display', SLIDE_SEED_STATEMENT, M, 340, 1100, { lines: 3 }),
|
|
@@ -98,7 +94,6 @@ const agenda = {
|
|
|
98
94
|
id: 'agenda',
|
|
99
95
|
name: SLIDE_NAME_AGENDA,
|
|
100
96
|
keywords: ['agenda', 'contents', 'outline', 'summary', 'plan'],
|
|
101
|
-
variant: 'paper',
|
|
102
97
|
zones: [
|
|
103
98
|
title(SLIDE_SEED_AGENDA_TITLE),
|
|
104
99
|
...[0, 1, 2, 3, 4].flatMap(i => {
|
|
@@ -115,7 +110,6 @@ const textImage = {
|
|
|
115
110
|
id: 'text-image',
|
|
116
111
|
name: SLIDE_NAME_TEXT_IMAGE,
|
|
117
112
|
keywords: ['text', 'picture', 'photo', 'split', 'describe', 'half'],
|
|
118
|
-
variant: 'paper',
|
|
119
113
|
zones: [
|
|
120
114
|
title(SLIDE_SEED_TITLE, { w: 720 }),
|
|
121
115
|
text('heading', SLIDE_SEED_HEADING, M, 240, 720, muted),
|
|
@@ -129,7 +123,6 @@ const fullImage = {
|
|
|
129
123
|
id: 'full-image',
|
|
130
124
|
name: SLIDE_NAME_FULL_IMAGE,
|
|
131
125
|
keywords: ['picture', 'photo', 'screenshot', 'visual', 'caption'],
|
|
132
|
-
variant: 'paper',
|
|
133
126
|
zones: [
|
|
134
127
|
title(),
|
|
135
128
|
image(M, 160, CONTENT, 600),
|
|
@@ -143,7 +136,6 @@ const twoColumns = {
|
|
|
143
136
|
id: 'two-columns',
|
|
144
137
|
name: SLIDE_NAME_TWO_COLUMNS,
|
|
145
138
|
keywords: ['columns', 'compare', 'versus', 'before after', 'pros cons'],
|
|
146
|
-
variant: 'paper',
|
|
147
139
|
zones: [
|
|
148
140
|
title(),
|
|
149
141
|
...columns(2).flatMap(({ x, w }) => [
|
|
@@ -156,7 +148,6 @@ const threeColumns = {
|
|
|
156
148
|
id: 'three-columns',
|
|
157
149
|
name: SLIDE_NAME_THREE_COLUMNS,
|
|
158
150
|
keywords: ['columns', 'three points', 'pillars', 'ideas', 'list'],
|
|
159
|
-
variant: 'paper',
|
|
160
151
|
zones: [
|
|
161
152
|
title(),
|
|
162
153
|
...columns(3).flatMap(({ x, w }, i) => [
|
|
@@ -170,7 +161,6 @@ const sixPoints = {
|
|
|
170
161
|
id: 'six-points',
|
|
171
162
|
name: SLIDE_NAME_SIX_POINTS,
|
|
172
163
|
keywords: ['grid', 'points', 'features', 'benefits', 'list'],
|
|
173
|
-
variant: 'paper',
|
|
174
164
|
zones: [
|
|
175
165
|
title(),
|
|
176
166
|
...[240, 530].flatMap(y => columns(3).flatMap(({ x, w }) => [
|
|
@@ -183,7 +173,6 @@ const imageCards = {
|
|
|
183
173
|
id: 'image-cards',
|
|
184
174
|
name: SLIDE_NAME_IMAGE_CARDS,
|
|
185
175
|
keywords: ['cards', 'pictures', 'gallery', 'products', 'features'],
|
|
186
|
-
variant: 'paper',
|
|
187
176
|
zones: [
|
|
188
177
|
title(),
|
|
189
178
|
...columns(3).flatMap(({ x, w }) => [
|
|
@@ -197,7 +186,6 @@ const keyFigures = {
|
|
|
197
186
|
id: 'key-figures',
|
|
198
187
|
name: SLIDE_NAME_KEY_FIGURES,
|
|
199
188
|
keywords: ['metrics', 'kpi', 'numbers', 'statistics', 'data', 'results'],
|
|
200
|
-
variant: 'paper',
|
|
201
189
|
zones: [
|
|
202
190
|
title(),
|
|
203
191
|
...columns(3).flatMap(({ x, w }) => [
|
|
@@ -211,7 +199,6 @@ const timeline = {
|
|
|
211
199
|
id: 'timeline',
|
|
212
200
|
name: SLIDE_NAME_TIMELINE,
|
|
213
201
|
keywords: ['timeline', 'milestones', 'history', 'schedule', 'dates'],
|
|
214
|
-
variant: 'paper',
|
|
215
202
|
zones: [
|
|
216
203
|
title(),
|
|
217
204
|
line([M, 470], [M + CONTENT, 470]),
|
|
@@ -235,7 +222,6 @@ const roadmap = {
|
|
|
235
222
|
id: 'roadmap',
|
|
236
223
|
name: SLIDE_NAME_ROADMAP,
|
|
237
224
|
keywords: ['roadmap', 'plan', 'quarters', 'gantt', 'milestones'],
|
|
238
|
-
variant: 'paper',
|
|
239
225
|
zones: [
|
|
240
226
|
title(),
|
|
241
227
|
...columns(4, 0).flatMap(({ x, w }, i) => [
|
|
@@ -258,7 +244,6 @@ const process = {
|
|
|
258
244
|
id: 'process',
|
|
259
245
|
name: SLIDE_NAME_PROCESS,
|
|
260
246
|
keywords: ['process', 'steps', 'flow', 'workflow', 'how it works'],
|
|
261
|
-
variant: 'paper',
|
|
262
247
|
zones: [
|
|
263
248
|
title(),
|
|
264
249
|
...columns(5, 57).flatMap(({ x, w }, i, all) => [
|
|
@@ -289,7 +274,6 @@ const matrix = {
|
|
|
289
274
|
'prioritization',
|
|
290
275
|
'value effort',
|
|
291
276
|
],
|
|
292
|
-
variant: 'paper',
|
|
293
277
|
zones: [
|
|
294
278
|
title(),
|
|
295
279
|
line([260, 780], [260, 210], true),
|
|
@@ -310,7 +294,6 @@ const venn = {
|
|
|
310
294
|
id: 'venn',
|
|
311
295
|
name: SLIDE_NAME_VENN,
|
|
312
296
|
keywords: ['venn', 'overlap', 'intersection', 'circles', 'sweet spot'],
|
|
313
|
-
variant: 'paper',
|
|
314
297
|
zones: [
|
|
315
298
|
title(),
|
|
316
299
|
card(400, 200, 520, 520, { shape: 'ellipse', stroke: 'muted' }),
|
|
@@ -328,7 +311,6 @@ const marketSize = {
|
|
|
328
311
|
id: 'market-size',
|
|
329
312
|
name: SLIDE_NAME_MARKET_SIZE,
|
|
330
313
|
keywords: ['market', 'tam sam som', 'opportunity', 'sizing', 'circles'],
|
|
331
|
-
variant: 'paper',
|
|
332
314
|
zones: [
|
|
333
315
|
title(),
|
|
334
316
|
...[
|
|
@@ -368,7 +350,6 @@ const orgChart = {
|
|
|
368
350
|
'reporting',
|
|
369
351
|
'structure',
|
|
370
352
|
],
|
|
371
|
-
variant: 'paper',
|
|
372
353
|
zones: [
|
|
373
354
|
title(),
|
|
374
355
|
...person(650, 220),
|
|
@@ -384,7 +365,6 @@ const pricing = {
|
|
|
384
365
|
id: 'pricing',
|
|
385
366
|
name: SLIDE_NAME_PRICING,
|
|
386
367
|
keywords: ['pricing', 'plans', 'tiers', 'offer', 'packages'],
|
|
387
|
-
variant: 'paper',
|
|
388
368
|
zones: [
|
|
389
369
|
title(SLIDE_SEED_TITLE, centred),
|
|
390
370
|
...columns(3).flatMap(({ x, w }) => [
|
|
@@ -400,7 +380,6 @@ const logoWall = {
|
|
|
400
380
|
id: 'logo-wall',
|
|
401
381
|
name: SLIDE_NAME_LOGO_WALL,
|
|
402
382
|
keywords: ['logos', 'clients', 'partners', 'customers', 'trusted by'],
|
|
403
|
-
variant: 'paper',
|
|
404
383
|
zones: [
|
|
405
384
|
title(SLIDE_SEED_TITLE, centred),
|
|
406
385
|
...[300, 480].flatMap(y => columns(5, 52).map(({ x, w }) => image(x, y, w, 120, { label: SLIDE_SEED_LOGO }))),
|
|
@@ -410,7 +389,6 @@ const quote = {
|
|
|
410
389
|
id: 'quote',
|
|
411
390
|
name: SLIDE_NAME_QUOTE,
|
|
412
391
|
keywords: ['quote', 'citation', 'testimonial', 'voice', 'customer'],
|
|
413
|
-
variant: 'inverse',
|
|
414
392
|
zones: [
|
|
415
393
|
text('title', SLIDE_SEED_QUOTE, 200, 300, 1200, { lines: 3, ...centred }),
|
|
416
394
|
text('body', SLIDE_SEED_QUOTE_AUTHOR, 200, 520, 1200, {
|
|
@@ -423,7 +401,6 @@ const testimonials = {
|
|
|
423
401
|
id: 'testimonials',
|
|
424
402
|
name: SLIDE_NAME_TESTIMONIALS,
|
|
425
403
|
keywords: ['testimonials', 'quotes', 'reviews', 'customers', 'clients'],
|
|
426
|
-
variant: 'paper',
|
|
427
404
|
zones: [
|
|
428
405
|
title(SLIDE_SEED_TESTIMONIALS_TITLE, centred),
|
|
429
406
|
...columns(3).flatMap(({ x, w }) => [
|
|
@@ -440,7 +417,6 @@ const team = {
|
|
|
440
417
|
id: 'team',
|
|
441
418
|
name: SLIDE_NAME_TEAM,
|
|
442
419
|
keywords: ['team', 'people', 'staff', 'leadership', 'about us'],
|
|
443
|
-
variant: 'paper',
|
|
444
420
|
zones: [
|
|
445
421
|
title(SLIDE_SEED_TEAM_TITLE, centred),
|
|
446
422
|
...columns(4).flatMap(({ x, w }) => [
|
|
@@ -454,7 +430,6 @@ const contact = {
|
|
|
454
430
|
id: 'contact',
|
|
455
431
|
name: SLIDE_NAME_CONTACT,
|
|
456
432
|
keywords: ['contact', 'address', 'email', 'phone', 'closing', 'thank you'],
|
|
457
|
-
variant: 'paper',
|
|
458
433
|
zones: [
|
|
459
434
|
image(0, 0, 640, SLIDE_HEIGHT),
|
|
460
435
|
text('title', SLIDE_SEED_CONTACT_TITLE, 736, TITLE_Y, 768),
|
|
@@ -503,7 +478,6 @@ const gantt = {
|
|
|
503
478
|
id: 'gantt',
|
|
504
479
|
name: SLIDE_NAME_GANTT,
|
|
505
480
|
keywords: ['gantt', 'plan', 'schedule', 'tasks', 'months', 'timeline'],
|
|
506
|
-
variant: 'paper',
|
|
507
481
|
zones: [
|
|
508
482
|
title(),
|
|
509
483
|
...columns(6, 0).flatMap(({ x, w }, i) => [
|
|
@@ -521,7 +495,6 @@ const chartText = {
|
|
|
521
495
|
id: 'chart-text',
|
|
522
496
|
name: SLIDE_NAME_CHART_TEXT,
|
|
523
497
|
keywords: ['chart', 'graph', 'data', 'figures', 'explain', 'bar', 'line'],
|
|
524
|
-
variant: 'paper',
|
|
525
498
|
zones: [
|
|
526
499
|
title(SLIDE_SEED_TITLE, { w: 760 }),
|
|
527
500
|
text('body', SLIDE_SEED_BODY, M, 680, 700, { lines: 3, ...muted }),
|
|
@@ -532,7 +505,6 @@ const threeCharts = {
|
|
|
532
505
|
id: 'three-charts',
|
|
533
506
|
name: SLIDE_NAME_THREE_CHARTS,
|
|
534
507
|
keywords: ['charts', 'graphs', 'pie', 'donut', 'compare', 'data'],
|
|
535
|
-
variant: 'paper',
|
|
536
508
|
zones: [
|
|
537
509
|
title(SLIDE_SEED_TITLE, centred),
|
|
538
510
|
...columns(3).flatMap(({ x, w }) => [
|
|
@@ -549,7 +521,6 @@ const collage = {
|
|
|
549
521
|
id: 'collage',
|
|
550
522
|
name: SLIDE_NAME_COLLAGE,
|
|
551
523
|
keywords: ['collage', 'photos', 'pictures', 'gallery', 'text', 'mosaic'],
|
|
552
|
-
variant: 'paper',
|
|
553
524
|
zones: [
|
|
554
525
|
title(SLIDE_SEED_TITLE, { w: 560 }),
|
|
555
526
|
text('body', SLIDE_SEED_BODY, M, 640, 560, { lines: 4, ...muted }),
|
|
@@ -562,7 +533,6 @@ const bento = {
|
|
|
562
533
|
id: 'bento',
|
|
563
534
|
name: SLIDE_NAME_BENTO,
|
|
564
535
|
keywords: ['bento', 'photos', 'pictures', 'collage', 'mosaic', 'gallery'],
|
|
565
|
-
variant: 'paper',
|
|
566
536
|
zones: [
|
|
567
537
|
image(M, 80, 940, 350),
|
|
568
538
|
image(1076, 80, 428, 350),
|
|
@@ -574,7 +544,6 @@ const imageGrid = {
|
|
|
574
544
|
id: 'image-grid',
|
|
575
545
|
name: SLIDE_NAME_IMAGE_GRID,
|
|
576
546
|
keywords: ['grid', 'photos', 'pictures', 'gallery', 'six', 'mosaic'],
|
|
577
|
-
variant: 'paper',
|
|
578
547
|
zones: [80, 470].flatMap(y => columns(3, 40).map(({ x, w }) => image(x, y, w, 350))),
|
|
579
548
|
};
|
|
580
549
|
/** A key-figure card: the number, then what it measures. */
|
|
@@ -604,7 +573,6 @@ const featureBento = {
|
|
|
604
573
|
id: 'feature-bento',
|
|
605
574
|
name: SLIDE_NAME_FEATURE_BENTO,
|
|
606
575
|
keywords: ['bento', 'features', 'metrics', 'kpi', 'product', 'highlights'],
|
|
607
|
-
variant: 'paper',
|
|
608
576
|
zones: [
|
|
609
577
|
...featureCard(M, 80, 520, 500),
|
|
610
578
|
...figureCard(660, 80, 844, 190),
|
|
@@ -617,7 +585,6 @@ const phone = {
|
|
|
617
585
|
id: 'phone',
|
|
618
586
|
name: SLIDE_NAME_PHONE,
|
|
619
587
|
keywords: ['phone', 'mobile', 'mockup', 'app', 'device', 'screen'],
|
|
620
|
-
variant: 'paper',
|
|
621
588
|
zones: [
|
|
622
589
|
title(SLIDE_SEED_TITLE, { w: 760 }),
|
|
623
590
|
text('body', SLIDE_SEED_BODY, M, 700, 760, { lines: 2, ...muted }),
|
|
@@ -628,7 +595,6 @@ const tablet = {
|
|
|
628
595
|
id: 'tablet',
|
|
629
596
|
name: SLIDE_NAME_TABLET,
|
|
630
597
|
keywords: ['tablet', 'mockup', 'app', 'device', 'screen', 'laptop'],
|
|
631
|
-
variant: 'paper',
|
|
632
598
|
zones: [
|
|
633
599
|
title(SLIDE_SEED_TITLE, { w: 700 }),
|
|
634
600
|
text('body', SLIDE_SEED_BODY, M, 680, 700, { lines: 3, ...muted }),
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { notifyLinkedDocSwitchedToEmbed } from '../../../affine-components/notification/index.js';
|
|
2
|
+
import { LINKED_DOC_NOTE_STYLE } from '../../../affine-shared/consts/index.js';
|
|
2
3
|
import { ActionPlacement, DocDisplayMetaProvider, TOOLBAR_CARD_VIEW, TOOLBAR_DELETE, TOOLBAR_EMBED_VIEW, TOOLBAR_INLINE_VIEW, toolbarActionLabel, translateKey, UNTITLED_DOC_LABEL, } from '../../../affine-shared/services/index.js';
|
|
3
4
|
import { cloneReferenceInfoWithoutAliases, isInsideBlockByFlavour, } from '../../../affine-shared/utils/index.js';
|
|
4
5
|
import { DeleteIcon } from '@blocksuite/icons/lit';
|
|
@@ -57,7 +58,7 @@ export const builtinInlineReferenceToolbarConfig = {
|
|
|
57
58
|
// Clears
|
|
58
59
|
ctx.reset();
|
|
59
60
|
const index = parent.children.indexOf(model);
|
|
60
|
-
const blockId = ctx.store.addBlock('affine:embed-linked-doc', referenceInfo, parent, index + 1);
|
|
61
|
+
const blockId = ctx.store.addBlock('affine:embed-linked-doc', { ...referenceInfo, style: LINKED_DOC_NOTE_STYLE }, parent, index + 1);
|
|
61
62
|
const totalTextLength = inlineEditor.yTextLength;
|
|
62
63
|
const inlineTextLength = selfInlineRange.length;
|
|
63
64
|
if (totalTextLength === inlineTextLength) {
|
|
@@ -4,6 +4,15 @@ export declare const EDGELESS_BLOCK_CHILD_PADDING = 24;
|
|
|
4
4
|
export declare const EDGELESS_BLOCK_CHILD_BORDER_WIDTH = 2;
|
|
5
5
|
export declare const PAGE_HEADER_HEIGHT = 53;
|
|
6
6
|
export declare const EMBED_CARD_MIN_WIDTH = 450;
|
|
7
|
+
/**
|
|
8
|
+
* The style of a page's `affine:embed-linked-doc` card the library places in
|
|
9
|
+
* a note when no one chose one: the one-line card ("Small horizontal style").
|
|
10
|
+
* Product owner, labre recette 3 P2-7b (ADR-0045 amended 2026-10-27): the
|
|
11
|
+
* default view of a child page's card or of a link to a page is the line. A
|
|
12
|
+
* creation site writes it, never the model's default (`horizontal`), which
|
|
13
|
+
* every stored card already carries. Canvas cards keep their own style.
|
|
14
|
+
*/
|
|
15
|
+
export declare const LINKED_DOC_NOTE_STYLE = "list";
|
|
7
16
|
/**
|
|
8
17
|
* The smallest a thing you TAP may be, in CSS pixels.
|
|
9
18
|
*
|
|
@@ -6,6 +6,15 @@ export const EDGELESS_BLOCK_CHILD_BORDER_WIDTH = 2;
|
|
|
6
6
|
// In AFFiNE, to avoid the option element to be covered by the header, we need to reserve the space for the header
|
|
7
7
|
export const PAGE_HEADER_HEIGHT = 53;
|
|
8
8
|
export const EMBED_CARD_MIN_WIDTH = 450;
|
|
9
|
+
/**
|
|
10
|
+
* The style of a page's `affine:embed-linked-doc` card the library places in
|
|
11
|
+
* a note when no one chose one: the one-line card ("Small horizontal style").
|
|
12
|
+
* Product owner, labre recette 3 P2-7b (ADR-0045 amended 2026-10-27): the
|
|
13
|
+
* default view of a child page's card or of a link to a page is the line. A
|
|
14
|
+
* creation site writes it, never the model's default (`horizontal`), which
|
|
15
|
+
* every stored card already carries. Canvas cards keep their own style.
|
|
16
|
+
*/
|
|
17
|
+
export const LINKED_DOC_NOTE_STYLE = 'list';
|
|
9
18
|
/**
|
|
10
19
|
* The smallest a thing you TAP may be, in CSS pixels.
|
|
11
20
|
*
|
|
@@ -24,7 +24,8 @@ export interface AssetRef {
|
|
|
24
24
|
*
|
|
25
25
|
* - `kind`: `image` for an image block, `file` for an attachment card.
|
|
26
26
|
* - `mode`: `insert` adds new blocks; `replace` swaps the picture of one
|
|
27
|
-
* existing image (one ref is used, the
|
|
27
|
+
* existing image, or the file of one attachment card (one ref is used, the
|
|
28
|
+
* first).
|
|
28
29
|
* - `multiple`: whether more than one ref is welcome (the image insertions).
|
|
29
30
|
* - `docId`: the document the result lands in, so the host can attach the
|
|
30
31
|
* asset to that page (a guest of the page must be able to read it).
|
|
@@ -51,11 +52,11 @@ export interface AssetPickerService {
|
|
|
51
52
|
export declare const AssetPickerProvider: import("../../global/di/types.js").ServiceIdentifier<AssetPickerService> & (<U extends AssetPickerService = AssetPickerService>(variant: import("../../global/di/types.js").ServiceVariant) => import("../../global/di/types.js").ServiceIdentifier<U>);
|
|
52
53
|
/**
|
|
53
54
|
* Host seam: the asset dialog. Present, the slash menu's Image, Attachment
|
|
54
|
-
* and PDF, the mobile keyboard toolbar's Image and Attachment,
|
|
55
|
-
*
|
|
56
|
-
* "Replace"
|
|
57
|
-
*
|
|
58
|
-
* through it.
|
|
55
|
+
* and PDF, the mobile keyboard toolbar's Image and Attachment, the canvas's
|
|
56
|
+
* image and file buttons and its "Add file" tool, and the attachment card's
|
|
57
|
+
* "Replace" open it, and the image toolbar gains "Replace". Absent, every
|
|
58
|
+
* one of those opens the system file chooser as before, and the image
|
|
59
|
+
* toolbar has no "Replace". Pasting and dropping files never go through it.
|
|
59
60
|
*
|
|
60
61
|
* `di.override`, like `FrameTemplateExtension`, so a later registration
|
|
61
62
|
* always wins and registering twice never throws at boot.
|
|
@@ -2,11 +2,11 @@ import { createIdentifier } from '../../global/di/index.js';
|
|
|
2
2
|
export const AssetPickerProvider = createIdentifier('AffineAssetPicker');
|
|
3
3
|
/**
|
|
4
4
|
* Host seam: the asset dialog. Present, the slash menu's Image, Attachment
|
|
5
|
-
* and PDF, the mobile keyboard toolbar's Image and Attachment,
|
|
6
|
-
*
|
|
7
|
-
* "Replace"
|
|
8
|
-
*
|
|
9
|
-
* through it.
|
|
5
|
+
* and PDF, the mobile keyboard toolbar's Image and Attachment, the canvas's
|
|
6
|
+
* image and file buttons and its "Add file" tool, and the attachment card's
|
|
7
|
+
* "Replace" open it, and the image toolbar gains "Replace". Absent, every
|
|
8
|
+
* one of those opens the system file chooser as before, and the image
|
|
9
|
+
* toolbar has no "Replace". Pasting and dropping files never go through it.
|
|
10
10
|
*
|
|
11
11
|
* `di.override`, like `FrameTemplateExtension`, so a later registration
|
|
12
12
|
* always wins and registering twice never throws at boot.
|
|
@@ -119,6 +119,15 @@ export interface TitleBandService {
|
|
|
119
119
|
* on a row). Absent, there is no "+".
|
|
120
120
|
*/
|
|
121
121
|
add?(docId: string): void;
|
|
122
|
+
/**
|
|
123
|
+
* Configure one property (recette 3, 0.61): a right-click on a chip's name
|
|
124
|
+
* asks the host to open the menu its own panel opens for that property
|
|
125
|
+
* (name, type, options, visibility, order, delete), under `anchor`, the
|
|
126
|
+
* name the reader clicked. The band then keeps the browser's menu from
|
|
127
|
+
* showing. Not on a read-only document, nor for a touch long-press, which
|
|
128
|
+
* stays the browser's. Absent, a right-click on a name is the browser's.
|
|
129
|
+
*/
|
|
130
|
+
configure?(docId: string, propertyId: string, anchor: HTMLElement): void;
|
|
122
131
|
/**
|
|
123
132
|
* Whether the band is collapsed for this document. The host decides where
|
|
124
133
|
* that is remembered (the Labre app: per device, REQ-PR-6). Absent, the
|
|
@@ -138,6 +147,16 @@ export interface TitleBandService {
|
|
|
138
147
|
* the host's reading of the document. Absent or empty, no row.
|
|
139
148
|
*/
|
|
140
149
|
notShown$?(docId: string): ReadonlySignal<readonly TitleBandNotShownPage[]>;
|
|
150
|
+
/**
|
|
151
|
+
* The ids of the child pages of document `docId` in the host's page tree
|
|
152
|
+
* (labre ADR-0045, amended 2026-10-27). A linked-doc card or a synced-doc
|
|
153
|
+
* embed of one of them, in that document, is the child's own card: it is
|
|
154
|
+
* drawn with the plain page (or canvas) icon, without the link arrow an
|
|
155
|
+
* inline `@` reference keeps. Read inside the card's icon computation, so
|
|
156
|
+
* a move redraws it. The library never computes a parent or a child.
|
|
157
|
+
* Absent, every card keeps the arrow (0.59).
|
|
158
|
+
*/
|
|
159
|
+
children$?(docId: string): ReadonlySignal<readonly string[]>;
|
|
141
160
|
}
|
|
142
161
|
export declare const TitleBandProvider: import("../../global/di/types.js").ServiceIdentifier<TitleBandService> & (<U extends TitleBandService = TitleBandService>(variant: import("../../global/di/types.js").ServiceVariant) => import("../../global/di/types.js").ServiceIdentifier<U>);
|
|
143
162
|
/**
|
|
@@ -52,29 +52,29 @@ let AffineEdgelessZoomToolbarWidget = (() => {
|
|
|
52
52
|
__esDecorate(this, null, __hide_decorators, { kind: "accessor", name: "_hide", static: false, private: false, access: { has: obj => "_hide" in obj, get: obj => obj._hide, set: (obj, value) => { obj._hide = value; } }, metadata: _metadata }, __hide_initializers, __hide_extraInitializers);
|
|
53
53
|
if (_metadata) Object.defineProperty(this, Symbol.metadata, { enumerable: true, configurable: true, writable: true, value: _metadata });
|
|
54
54
|
}
|
|
55
|
-
static { this.styles = css `
|
|
56
|
-
:host {
|
|
57
|
-
position: absolute;
|
|
58
|
-
bottom: 20px;
|
|
59
|
-
left: 12px;
|
|
60
|
-
z-index: var(--affine-z-index-popover);
|
|
61
|
-
display: flex;
|
|
62
|
-
justify-content: center;
|
|
63
|
-
-webkit-user-select: none;
|
|
64
|
-
user-select: none;
|
|
65
|
-
}
|
|
66
|
-
|
|
67
|
-
@container viewport (width <= 1200px) {
|
|
68
|
-
edgeless-zoom-toolbar {
|
|
69
|
-
display: none;
|
|
70
|
-
}
|
|
71
|
-
}
|
|
72
|
-
|
|
73
|
-
@container viewport (width > 1200px) {
|
|
74
|
-
zoom-bar-toggle-button {
|
|
75
|
-
display: none;
|
|
76
|
-
}
|
|
77
|
-
}
|
|
55
|
+
static { this.styles = css `
|
|
56
|
+
:host {
|
|
57
|
+
position: absolute;
|
|
58
|
+
bottom: 20px;
|
|
59
|
+
left: 12px;
|
|
60
|
+
z-index: var(--affine-z-index-popover);
|
|
61
|
+
display: flex;
|
|
62
|
+
justify-content: center;
|
|
63
|
+
-webkit-user-select: none;
|
|
64
|
+
user-select: none;
|
|
65
|
+
}
|
|
66
|
+
|
|
67
|
+
@container viewport (width <= 1200px) {
|
|
68
|
+
edgeless-zoom-toolbar {
|
|
69
|
+
display: none;
|
|
70
|
+
}
|
|
71
|
+
}
|
|
72
|
+
|
|
73
|
+
@container viewport (width > 1200px) {
|
|
74
|
+
zoom-bar-toggle-button {
|
|
75
|
+
display: none;
|
|
76
|
+
}
|
|
77
|
+
}
|
|
78
78
|
`; }
|
|
79
79
|
get edgeless() {
|
|
80
80
|
return this.block;
|
|
@@ -105,9 +105,9 @@ let AffineEdgelessZoomToolbarWidget = (() => {
|
|
|
105
105
|
if (this._hide || !this.edgeless) {
|
|
106
106
|
return nothing;
|
|
107
107
|
}
|
|
108
|
-
return html `
|
|
109
|
-
<edgeless-zoom-toolbar .std=${this.std}></edgeless-zoom-toolbar>
|
|
110
|
-
<zoom-bar-toggle-button .std=${this.std}></zoom-bar-toggle-button>
|
|
108
|
+
return html `
|
|
109
|
+
<edgeless-zoom-toolbar .std=${this.std}></edgeless-zoom-toolbar>
|
|
110
|
+
<zoom-bar-toggle-button .std=${this.std}></zoom-bar-toggle-button>
|
|
111
111
|
`;
|
|
112
112
|
}
|
|
113
113
|
#_hide_accessor_storage = __runInitializers(this, __hide_initializers, false);
|