fika-editor 3.6.1 → 3.6.3
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/dist/embed/agentic-manifest.json +3 -3
- package/dist/embed/fika-embed.css +1 -1
- package/dist/embed/fika-embed.js +5 -5
- package/dist/types/configs/theme.d.ts +2 -0
- package/dist/types/embed/inferViewport.d.ts +4 -4
- package/dist/types/store/slides.d.ts +4 -0
- package/dist/types/types/slides.d.ts +2 -0
- package/dist/types/utils/textFit.d.ts +13 -0
- package/package.json +1 -1
|
@@ -7,6 +7,8 @@ export interface PresetTheme {
|
|
|
7
7
|
background: string;
|
|
8
8
|
fontColor: string;
|
|
9
9
|
featureFontColor?: string;
|
|
10
|
+
/** Optional heading ink, kept distinct from readable body copy. */
|
|
11
|
+
headingFontColor?: string;
|
|
10
12
|
/** Retain pale panels and accent roles when restyling host-authored decks. */
|
|
11
13
|
preserveColorRoles?: boolean;
|
|
12
14
|
fontname: string;
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
import type { Slide } from '../types/slides';
|
|
2
2
|
import type { FikaDeckViewport } from './agentic/types';
|
|
3
3
|
/**
|
|
4
|
-
* Recover
|
|
4
|
+
* Recover a missing coordinate space from element bounds.
|
|
5
5
|
*
|
|
6
6
|
* Agent/import pipelines often author at 1280×720. Remounting those slides on
|
|
7
|
-
* the 1000×16:9 default
|
|
8
|
-
*
|
|
9
|
-
*
|
|
7
|
+
* the 1000×16:9 default overflows the canvas. An explicit viewport owns the
|
|
8
|
+
* coordinate space: off-canvas elements and decorative bleed must not resize
|
|
9
|
+
* every page. Only infer dimensions when the document does not supply them.
|
|
10
10
|
*/
|
|
11
11
|
export declare function inferViewportFromSlides(slides: Slide[], existing?: Partial<FikaDeckViewport>): FikaDeckViewport | undefined;
|
|
@@ -90,6 +90,7 @@ export declare const useSlidesStore: import("zustand").UseBoundStore<Omit<import
|
|
|
90
90
|
setState(nextStateOrUpdater: Partial<SlidesStore> | ((state: {
|
|
91
91
|
title: string;
|
|
92
92
|
theme: {
|
|
93
|
+
headingFontColor?: string;
|
|
93
94
|
backgroundColor: string;
|
|
94
95
|
themeColors: string[];
|
|
95
96
|
fontColor: string;
|
|
@@ -1782,6 +1783,7 @@ export declare const useSlidesStore: import("zustand").UseBoundStore<Omit<import
|
|
|
1782
1783
|
skeleton?: boolean;
|
|
1783
1784
|
}[];
|
|
1784
1785
|
theme: {
|
|
1786
|
+
headingFontColor?: string;
|
|
1785
1787
|
backgroundColor?: string;
|
|
1786
1788
|
themeColors?: string[];
|
|
1787
1789
|
fontColor?: string;
|
|
@@ -1845,6 +1847,7 @@ export declare const useSlidesStore: import("zustand").UseBoundStore<Omit<import
|
|
|
1845
1847
|
setState(nextStateOrUpdater: ((state: {
|
|
1846
1848
|
title: string;
|
|
1847
1849
|
theme: {
|
|
1850
|
+
headingFontColor?: string;
|
|
1848
1851
|
backgroundColor: string;
|
|
1849
1852
|
themeColors: string[];
|
|
1850
1853
|
fontColor: string;
|
|
@@ -3537,6 +3540,7 @@ export declare const useSlidesStore: import("zustand").UseBoundStore<Omit<import
|
|
|
3537
3540
|
skeleton?: boolean;
|
|
3538
3541
|
}[];
|
|
3539
3542
|
theme: {
|
|
3543
|
+
headingFontColor?: string;
|
|
3540
3544
|
backgroundColor?: string;
|
|
3541
3545
|
themeColors?: string[];
|
|
3542
3546
|
fontColor?: string;
|
|
@@ -634,6 +634,8 @@ export interface Slide {
|
|
|
634
634
|
* Slide theme (background, accent colors, default font).
|
|
635
635
|
*/
|
|
636
636
|
export interface SlideTheme {
|
|
637
|
+
/** Optional ink for title and item-title text when generating more slides. */
|
|
638
|
+
headingFontColor?: string;
|
|
637
639
|
backgroundColor: string;
|
|
638
640
|
themeColors: string[];
|
|
639
641
|
fontColor: string;
|
|
@@ -58,6 +58,13 @@ export interface TextFitBlock {
|
|
|
58
58
|
whiteSpace?: 'pre-wrap';
|
|
59
59
|
/** Authored font size in px (its largest run, to stay safe). */
|
|
60
60
|
size: number;
|
|
61
|
+
/** Paragraph properties are independent of the largest inline font. */
|
|
62
|
+
paragraphSize?: number;
|
|
63
|
+
paragraphIndent?: number;
|
|
64
|
+
lineHeight?: number;
|
|
65
|
+
lineHeightPx?: number;
|
|
66
|
+
marginTop?: number;
|
|
67
|
+
marginBottom?: number;
|
|
61
68
|
bold?: boolean;
|
|
62
69
|
italic?: boolean;
|
|
63
70
|
fontFamily: string;
|
|
@@ -156,6 +163,12 @@ export declare const lineBoxHeight: (runs: TextFitRun[], sizeScale: number, line
|
|
|
156
163
|
* item occupies exactly the chip width.
|
|
157
164
|
*/
|
|
158
165
|
export declare const MATH_PLACEHOLDER = "\uFFFC";
|
|
166
|
+
export declare const fixedLineMetrics: (block: TextFitBlock, runs: TextFitRun[], scale: number) => {
|
|
167
|
+
ascent: number;
|
|
168
|
+
descent: number;
|
|
169
|
+
};
|
|
170
|
+
export declare const blockLineBoxHeight: (block: TextFitBlock, runs: TextFitRun[], scale: number, fallback: number) => number;
|
|
171
|
+
export declare const paragraphGap: (previous: TextFitBlock | undefined, block: TextFitBlock, fallback: number) => number;
|
|
159
172
|
/**
|
|
160
173
|
* Live ProseMirror uses `white-space: break-spaces`: the space after the last
|
|
161
174
|
* word on a line still occupies width, so the wrap column is one space
|