@anvpx/motion-build 0.1.35 → 0.1.36
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/lint/index.d.ts
CHANGED
|
@@ -9,6 +9,7 @@ import { minHoldRule } from "./min-hold.ts";
|
|
|
9
9
|
import { flatMotionRule, holdAfterAccentRule, transitionEaseMismatchRule, unsupportedMotionRule } from "./motion-craft.ts";
|
|
10
10
|
import { narrationPaceRule } from "./narration-pace.ts";
|
|
11
11
|
import { overlayFitRule, overlayStackRule, overlayTargetRule } from "./overlays.ts";
|
|
12
|
+
import { plateOverCaptionRule } from "./plate-over-caption.ts";
|
|
12
13
|
import { readingTimeRule } from "./reading-time.ts";
|
|
13
14
|
import { safeZone9x16Rule } from "./safe-zone-9x16.ts";
|
|
14
15
|
import { textFloorRule } from "./text-floor.ts";
|
|
@@ -18,7 +19,7 @@ import { duplicatedEmphasisRule, lineLengthRule, offGridSpacingRule, typeDensity
|
|
|
18
19
|
import type { LintInput, LintResult, LintRule } from "./types.ts";
|
|
19
20
|
import { wordsOnScreenRule } from "./words-on-screen.ts";
|
|
20
21
|
export type { LintFinding, LintInput, LintResult, LintRule, PlatformMarginLookup, PlatformMargins, } from "./types.ts";
|
|
21
|
-
export { contentOverflowRule, duplicatedEmphasisRule, fadeDeckRule, flatMotionRule, flowEdgeLabelRule, flowTextSizeRule, flowWordBreakRule, holdAfterAccentRule, hookFirstRule, linearEaseRule, lineLengthRule, longHoldRule, minHoldRule, narrationPaceRule, offGridSpacingRule, overlayFitRule, overlayStackRule, overlayTargetRule, readingTimeRule, safeZone9x16Rule, spanNeedsTwoBodiesRule, textFloorRule, transitionEaseMismatchRule, transitionImplementedRule, transitionLengthRule, typeDensityRule, unsupportedMotionRule, wordsOnScreenRule, };
|
|
22
|
+
export { contentOverflowRule, duplicatedEmphasisRule, fadeDeckRule, flatMotionRule, flowEdgeLabelRule, flowTextSizeRule, flowWordBreakRule, holdAfterAccentRule, hookFirstRule, linearEaseRule, lineLengthRule, longHoldRule, minHoldRule, narrationPaceRule, offGridSpacingRule, overlayFitRule, overlayStackRule, overlayTargetRule, plateOverCaptionRule, readingTimeRule, safeZone9x16Rule, spanNeedsTwoBodiesRule, textFloorRule, transitionEaseMismatchRule, transitionImplementedRule, transitionLengthRule, typeDensityRule, unsupportedMotionRule, wordsOnScreenRule, };
|
|
22
23
|
/**
|
|
23
24
|
* All rules, in report order. Contrast lives in theme tokens.
|
|
24
25
|
* Craft rules (motion-craft, type-grid) run after the timing and layout
|
package/dist/lint/index.js
CHANGED
|
@@ -9,6 +9,7 @@ import { minHoldRule } from "./min-hold.js";
|
|
|
9
9
|
import { flatMotionRule, holdAfterAccentRule, transitionEaseMismatchRule, unsupportedMotionRule, } from "./motion-craft.js";
|
|
10
10
|
import { narrationPaceRule } from "./narration-pace.js";
|
|
11
11
|
import { overlayFitRule, overlayStackRule, overlayTargetRule } from "./overlays.js";
|
|
12
|
+
import { plateOverCaptionRule } from "./plate-over-caption.js";
|
|
12
13
|
import { readingTimeRule } from "./reading-time.js";
|
|
13
14
|
import { safeZone9x16Rule } from "./safe-zone-9x16.js";
|
|
14
15
|
import { textFloorRule } from "./text-floor.js";
|
|
@@ -16,7 +17,7 @@ import { transitionImplementedRule } from "./transition-implemented.js";
|
|
|
16
17
|
import { transitionLengthRule } from "./transition-length.js";
|
|
17
18
|
import { duplicatedEmphasisRule, lineLengthRule, offGridSpacingRule, typeDensityRule, } from "./type-grid.js";
|
|
18
19
|
import { wordsOnScreenRule } from "./words-on-screen.js";
|
|
19
|
-
export { contentOverflowRule, duplicatedEmphasisRule, fadeDeckRule, flatMotionRule, flowEdgeLabelRule, flowTextSizeRule, flowWordBreakRule, holdAfterAccentRule, hookFirstRule, linearEaseRule, lineLengthRule, longHoldRule, minHoldRule, narrationPaceRule, offGridSpacingRule, overlayFitRule, overlayStackRule, overlayTargetRule, readingTimeRule, safeZone9x16Rule, spanNeedsTwoBodiesRule, textFloorRule, transitionEaseMismatchRule, transitionImplementedRule, transitionLengthRule, typeDensityRule, unsupportedMotionRule, wordsOnScreenRule, };
|
|
20
|
+
export { contentOverflowRule, duplicatedEmphasisRule, fadeDeckRule, flatMotionRule, flowEdgeLabelRule, flowTextSizeRule, flowWordBreakRule, holdAfterAccentRule, hookFirstRule, linearEaseRule, lineLengthRule, longHoldRule, minHoldRule, narrationPaceRule, offGridSpacingRule, overlayFitRule, overlayStackRule, overlayTargetRule, plateOverCaptionRule, readingTimeRule, safeZone9x16Rule, spanNeedsTwoBodiesRule, textFloorRule, transitionEaseMismatchRule, transitionImplementedRule, transitionLengthRule, typeDensityRule, unsupportedMotionRule, wordsOnScreenRule, };
|
|
20
21
|
/**
|
|
21
22
|
* All rules, in report order. Contrast lives in theme tokens.
|
|
22
23
|
* Craft rules (motion-craft, type-grid) run after the timing and layout
|
|
@@ -42,6 +43,7 @@ export const LINT_RULES = [
|
|
|
42
43
|
hookFirstRule,
|
|
43
44
|
safeZone9x16Rule,
|
|
44
45
|
contentOverflowRule,
|
|
46
|
+
plateOverCaptionRule,
|
|
45
47
|
fadeDeckRule,
|
|
46
48
|
flatMotionRule,
|
|
47
49
|
unsupportedMotionRule,
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import type { LintRule } from "./types.ts";
|
|
2
|
+
/**
|
|
3
|
+
* A name plate on the left will cover a picture that sits on the left's mirror: a
|
|
4
|
+
* `media-frame` with `layout: "right"` puts its own caption where the plate lands.
|
|
5
|
+
* Found by rendering the presenter layout in round 56, not by reading the catalog —
|
|
6
|
+
* the prop to fix it (`lower-third` `align`) already existed and nothing said to use it.
|
|
7
|
+
*/
|
|
8
|
+
export declare const plateOverCaptionRule: LintRule;
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* A name plate on the left will cover a picture that sits on the left's mirror: a
|
|
3
|
+
* `media-frame` with `layout: "right"` puts its own caption where the plate lands.
|
|
4
|
+
* Found by rendering the presenter layout in round 56, not by reading the catalog —
|
|
5
|
+
* the prop to fix it (`lower-third` `align`) already existed and nothing said to use it.
|
|
6
|
+
*/
|
|
7
|
+
export const plateOverCaptionRule = ({ storyboard }) => {
|
|
8
|
+
const rightFrames = new Set(storyboard.scenes
|
|
9
|
+
.filter((scene) => scene.type === "media-frame" && scene.props?.layout === "right")
|
|
10
|
+
.map((scene) => scene.id));
|
|
11
|
+
if (rightFrames.size === 0)
|
|
12
|
+
return [];
|
|
13
|
+
const findings = [];
|
|
14
|
+
storyboard.scenes.forEach((scene, index) => {
|
|
15
|
+
if (scene.type !== "lower-third")
|
|
16
|
+
return;
|
|
17
|
+
const align = scene.props?.align ?? "left";
|
|
18
|
+
if (align === "right")
|
|
19
|
+
return;
|
|
20
|
+
const over = typeof scene.over === "string" ? scene.over : undefined;
|
|
21
|
+
if (over === undefined || !rightFrames.has(over))
|
|
22
|
+
return;
|
|
23
|
+
findings.push({
|
|
24
|
+
severity: "warning",
|
|
25
|
+
path: `/scenes/${index}/props/align`,
|
|
26
|
+
message: `plate "${scene.id}" sits where the caption of "${over}" sits`,
|
|
27
|
+
suggestion: 'set props.align to "right" so the plate clears the framed picture',
|
|
28
|
+
});
|
|
29
|
+
});
|
|
30
|
+
return findings;
|
|
31
|
+
};
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@anvpx/motion-build",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.36",
|
|
4
4
|
"description": "Storyboard compiler for @anvpx/motion: validation, scene emission and HyperFrames project output.",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"author": "anvpx",
|
|
@@ -31,9 +31,9 @@
|
|
|
31
31
|
"@fontsource/jetbrains-mono": "5.3.0",
|
|
32
32
|
"@fontsource/source-serif-4": "5.3.1",
|
|
33
33
|
"@fontsource/space-grotesk": "5.3.0",
|
|
34
|
-
"@anvpx/motion-scenes": "0.1.
|
|
35
|
-
"@anvpx/motion-schema": "0.1.
|
|
36
|
-
"@anvpx/motion-themes": "0.1.
|
|
34
|
+
"@anvpx/motion-scenes": "0.1.36",
|
|
35
|
+
"@anvpx/motion-schema": "0.1.36",
|
|
36
|
+
"@anvpx/motion-themes": "0.1.36",
|
|
37
37
|
"postprocessing": "6.39.5",
|
|
38
38
|
"three": "0.186.0"
|
|
39
39
|
},
|