@graphlearning/graphl-flow 0.1.0 → 0.2.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 CHANGED
@@ -101,6 +101,10 @@ ratio to the text; a small scene stops growing at 4×. Keep scenes legible: the
101
101
  fails any fixture whose smallest body text renders under 24px in the 4K frame (12px at 1080p). If a
102
102
  diagram hits that, split the slide or trim bullets — a denser scene can only get smaller.
103
103
 
104
+ **Focus.** `<Scene scene={…} focus="driver" />` singles out one node — any id, a table row or a code
105
+ line included — with a ring and a glow in its own tone. It is drawn with box-shadow, so it moves
106
+ nothing: every section of a course can focus a different node on the same scene without a jump.
107
+
104
108
  **Fit.** `Scene` fills its parent and scales the scene to fit, centred, with a 4% margin. The scale
105
109
  depends only on the parent's size and the scene's natural size, so the same scene in the same frame
106
110
  always lands on the same pixels. The view is locked (no zoom/pan); page scroll passes through and text
package/dist/Scene.d.ts CHANGED
@@ -1,10 +1,15 @@
1
1
  import type { Scene as SceneModel, ThemeKey } from './types';
2
2
  /**
3
+ * `focus` names one node (any id, a table row or a code line included) to single out: it gets a
4
+ * ring and a glow, drawn with box-shadow so the layout — and therefore the fit — never moves. That is
5
+ * what lets every section of a course focus a different node on the same scene without a jump.
6
+ *
3
7
  * Fills its parent (give the parent a size) and scales the scene's natural box to fit, centred.
4
8
  * The viewport is locked: no wheel or drag handlers, so page scroll passes through and text stays
5
9
  * selectable. `data-fit="ready"` marks the first fit after fonts load with edges routed — what a recorder waits on.
6
10
  */
7
- export declare function Scene({ scene, theme: key }: {
11
+ export declare function Scene({ scene, theme: key, focus }: {
8
12
  scene: SceneModel;
9
13
  theme?: ThemeKey;
14
+ focus?: string;
10
15
  }): import("react").JSX.Element;