@promptctl/rich-js 0.16.0 → 0.18.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.
Files changed (206) hide show
  1. package/README.md +14 -27
  2. package/package.json +7 -3
  3. package/dist/core/box.d.ts +0 -144
  4. package/dist/core/box.js +0 -391
  5. package/dist/core/cells.d.ts +0 -148
  6. package/dist/core/cells.js +0 -266
  7. package/dist/core/color.d.ts +0 -229
  8. package/dist/core/color.js +0 -992
  9. package/dist/core/console.d.ts +0 -142
  10. package/dist/core/console.js +0 -477
  11. package/dist/core/emoji.d.ts +0 -24
  12. package/dist/core/emoji.js +0 -391
  13. package/dist/core/export-html.d.ts +0 -24
  14. package/dist/core/export-html.js +0 -106
  15. package/dist/core/export-lines.d.ts +0 -121
  16. package/dist/core/export-lines.js +0 -141
  17. package/dist/core/highlighter.d.ts +0 -33
  18. package/dist/core/highlighter.js +0 -124
  19. package/dist/core/json.d.ts +0 -27
  20. package/dist/core/json.js +0 -53
  21. package/dist/core/markup.d.ts +0 -97
  22. package/dist/core/markup.js +0 -619
  23. package/dist/core/measure.d.ts +0 -27
  24. package/dist/core/measure.js +0 -61
  25. package/dist/core/oklch.d.ts +0 -161
  26. package/dist/core/oklch.js +0 -312
  27. package/dist/core/osc8.d.ts +0 -68
  28. package/dist/core/osc8.js +0 -90
  29. package/dist/core/pretty.d.ts +0 -141
  30. package/dist/core/pretty.js +0 -472
  31. package/dist/core/protocol.d.ts +0 -137
  32. package/dist/core/protocol.js +0 -101
  33. package/dist/core/render.d.ts +0 -69
  34. package/dist/core/render.js +0 -140
  35. package/dist/core/segment.d.ts +0 -142
  36. package/dist/core/segment.js +0 -433
  37. package/dist/core/spinnerData.d.ts +0 -10
  38. package/dist/core/spinnerData.js +0 -115
  39. package/dist/core/strip.d.ts +0 -139
  40. package/dist/core/strip.js +0 -302
  41. package/dist/core/style.d.ts +0 -149
  42. package/dist/core/style.js +0 -741
  43. package/dist/core/subscription.d.ts +0 -12
  44. package/dist/core/subscription.js +0 -12
  45. package/dist/core/text.d.ts +0 -255
  46. package/dist/core/text.js +0 -990
  47. package/dist/core/wrap.d.ts +0 -41
  48. package/dist/core/wrap.js +0 -127
  49. package/dist/host/host-stream.d.ts +0 -30
  50. package/dist/host/host-stream.js +0 -35
  51. package/dist/host/index.d.ts +0 -3
  52. package/dist/host/index.js +0 -2
  53. package/dist/host/terminal-host.d.ts +0 -143
  54. package/dist/host/terminal-host.js +0 -132
  55. package/dist/index.d.ts +0 -87
  56. package/dist/index.js +0 -104
  57. package/dist/node/prompt.d.ts +0 -21
  58. package/dist/node/prompt.js +0 -30
  59. package/dist/node/save.d.ts +0 -17
  60. package/dist/node/save.js +0 -21
  61. package/dist/node/terminal-host.d.ts +0 -84
  62. package/dist/node/terminal-host.js +0 -160
  63. package/dist/node/traceback.d.ts +0 -27
  64. package/dist/node/traceback.js +0 -112
  65. package/dist/renderables/align.d.ts +0 -16
  66. package/dist/renderables/align.js +0 -46
  67. package/dist/renderables/columns.d.ts +0 -61
  68. package/dist/renderables/columns.js +0 -168
  69. package/dist/renderables/constrain.d.ts +0 -15
  70. package/dist/renderables/constrain.js +0 -37
  71. package/dist/renderables/flexStrip.d.ts +0 -41
  72. package/dist/renderables/flexStrip.js +0 -200
  73. package/dist/renderables/group.d.ts +0 -11
  74. package/dist/renderables/group.js +0 -15
  75. package/dist/renderables/layout.d.ts +0 -92
  76. package/dist/renderables/layout.js +0 -315
  77. package/dist/renderables/live.d.ts +0 -47
  78. package/dist/renderables/live.js +0 -131
  79. package/dist/renderables/markdown.d.ts +0 -24
  80. package/dist/renderables/markdown.js +0 -182
  81. package/dist/renderables/padding.d.ts +0 -38
  82. package/dist/renderables/padding.js +0 -140
  83. package/dist/renderables/panel.d.ts +0 -116
  84. package/dist/renderables/panel.js +0 -322
  85. package/dist/renderables/progress.d.ts +0 -90
  86. package/dist/renderables/progress.js +0 -241
  87. package/dist/renderables/progressBar.d.ts +0 -31
  88. package/dist/renderables/progressBar.js +0 -52
  89. package/dist/renderables/prompt.d.ts +0 -49
  90. package/dist/renderables/prompt.js +0 -125
  91. package/dist/renderables/rule.d.ts +0 -24
  92. package/dist/renderables/rule.js +0 -90
  93. package/dist/renderables/spinner.d.ts +0 -29
  94. package/dist/renderables/spinner.js +0 -64
  95. package/dist/renderables/status.d.ts +0 -23
  96. package/dist/renderables/status.js +0 -60
  97. package/dist/renderables/syntax.d.ts +0 -35
  98. package/dist/renderables/syntax.js +0 -114
  99. package/dist/renderables/table.d.ts +0 -182
  100. package/dist/renderables/table.js +0 -697
  101. package/dist/renderables/traceback.d.ts +0 -31
  102. package/dist/renderables/traceback.js +0 -109
  103. package/dist/renderables/tree.d.ts +0 -54
  104. package/dist/renderables/tree.js +0 -159
  105. package/dist/template-bindings/color-funcs.d.ts +0 -87
  106. package/dist/template-bindings/color-funcs.js +0 -219
  107. package/dist/template-bindings/helpers.d.ts +0 -24
  108. package/dist/template-bindings/helpers.js +0 -48
  109. package/dist/template-bindings/index.d.ts +0 -107
  110. package/dist/template-bindings/index.js +0 -144
  111. package/dist/template-bindings/palette-funcs.d.ts +0 -94
  112. package/dist/template-bindings/palette-funcs.js +0 -151
  113. package/dist/template-bindings/style-funcs.d.ts +0 -28
  114. package/dist/template-bindings/style-funcs.js +0 -151
  115. package/dist/themes/buildPalette.d.ts +0 -36
  116. package/dist/themes/buildPalette.js +0 -56
  117. package/dist/themes/colorMath.d.ts +0 -82
  118. package/dist/themes/colorMath.js +0 -254
  119. package/dist/themes/colorRef.d.ts +0 -51
  120. package/dist/themes/colorRef.js +0 -96
  121. package/dist/themes/data/atom-one-dark.d.ts +0 -3
  122. package/dist/themes/data/atom-one-dark.js +0 -158
  123. package/dist/themes/data/atom-one-light.d.ts +0 -3
  124. package/dist/themes/data/atom-one-light.js +0 -158
  125. package/dist/themes/data/catppuccin-frappe.d.ts +0 -3
  126. package/dist/themes/data/catppuccin-frappe.js +0 -158
  127. package/dist/themes/data/catppuccin-latte.d.ts +0 -3
  128. package/dist/themes/data/catppuccin-latte.js +0 -158
  129. package/dist/themes/data/catppuccin-macchiato.d.ts +0 -3
  130. package/dist/themes/data/catppuccin-macchiato.js +0 -158
  131. package/dist/themes/data/catppuccin-mocha.d.ts +0 -3
  132. package/dist/themes/data/catppuccin-mocha.js +0 -158
  133. package/dist/themes/data/cyberpunk.d.ts +0 -17
  134. package/dist/themes/data/cyberpunk.js +0 -191
  135. package/dist/themes/data/default.d.ts +0 -3
  136. package/dist/themes/data/default.js +0 -158
  137. package/dist/themes/data/dracula.d.ts +0 -3
  138. package/dist/themes/data/dracula.js +0 -158
  139. package/dist/themes/data/flexoki.d.ts +0 -3
  140. package/dist/themes/data/flexoki.js +0 -158
  141. package/dist/themes/data/gruvbox.d.ts +0 -3
  142. package/dist/themes/data/gruvbox.js +0 -158
  143. package/dist/themes/data/index.d.ts +0 -35
  144. package/dist/themes/data/index.js +0 -64
  145. package/dist/themes/data/monokai.d.ts +0 -3
  146. package/dist/themes/data/monokai.js +0 -158
  147. package/dist/themes/data/nord.d.ts +0 -3
  148. package/dist/themes/data/nord.js +0 -158
  149. package/dist/themes/data/rose-pine-dawn.d.ts +0 -3
  150. package/dist/themes/data/rose-pine-dawn.js +0 -158
  151. package/dist/themes/data/rose-pine-moon.d.ts +0 -3
  152. package/dist/themes/data/rose-pine-moon.js +0 -158
  153. package/dist/themes/data/rose-pine.d.ts +0 -3
  154. package/dist/themes/data/rose-pine.js +0 -158
  155. package/dist/themes/data/solarized-dark.d.ts +0 -3
  156. package/dist/themes/data/solarized-dark.js +0 -158
  157. package/dist/themes/data/solarized-light.d.ts +0 -3
  158. package/dist/themes/data/solarized-light.js +0 -158
  159. package/dist/themes/data/svg-export.d.ts +0 -3
  160. package/dist/themes/data/svg-export.js +0 -158
  161. package/dist/themes/data/textual-ansi.d.ts +0 -3
  162. package/dist/themes/data/textual-ansi.js +0 -158
  163. package/dist/themes/data/textual-dark.d.ts +0 -3
  164. package/dist/themes/data/textual-dark.js +0 -158
  165. package/dist/themes/data/textual-light.d.ts +0 -3
  166. package/dist/themes/data/textual-light.js +0 -158
  167. package/dist/themes/data/tokyo-night.d.ts +0 -3
  168. package/dist/themes/data/tokyo-night.js +0 -158
  169. package/dist/themes/data/types.d.ts +0 -15
  170. package/dist/themes/data/types.js +0 -1
  171. package/dist/themes/palette.d.ts +0 -21
  172. package/dist/themes/palette.js +0 -28
  173. package/dist/themes/ramp.d.ts +0 -83
  174. package/dist/themes/ramp.js +0 -122
  175. package/dist/themes/registry.d.ts +0 -43
  176. package/dist/themes/registry.js +0 -82
  177. package/dist/themes/terminalThemes.d.ts +0 -54
  178. package/dist/themes/terminalThemes.js +0 -68
  179. package/dist/themes/transpose.d.ts +0 -87
  180. package/dist/themes/transpose.js +0 -138
  181. package/dist/widgets/button.d.ts +0 -49
  182. package/dist/widgets/button.js +0 -206
  183. package/dist/widgets/checkbox.d.ts +0 -41
  184. package/dist/widgets/checkbox.js +0 -155
  185. package/dist/widgets/dropdown.d.ts +0 -67
  186. package/dist/widgets/dropdown.js +0 -453
  187. package/dist/widgets/event-router.d.ts +0 -78
  188. package/dist/widgets/event-router.js +0 -622
  189. package/dist/widgets/focus-manager.d.ts +0 -26
  190. package/dist/widgets/focus-manager.js +0 -193
  191. package/dist/widgets/index.d.ts +0 -22
  192. package/dist/widgets/index.js +0 -15
  193. package/dist/widgets/screen.d.ts +0 -98
  194. package/dist/widgets/screen.js +0 -542
  195. package/dist/widgets/slider.d.ts +0 -57
  196. package/dist/widgets/slider.js +0 -270
  197. package/dist/widgets/static-item.d.ts +0 -40
  198. package/dist/widgets/static-item.js +0 -60
  199. package/dist/widgets/text-input.d.ts +0 -274
  200. package/dist/widgets/text-input.js +0 -1162
  201. package/dist/widgets/toggle.d.ts +0 -44
  202. package/dist/widgets/toggle.js +0 -179
  203. package/dist/widgets/types.d.ts +0 -108
  204. package/dist/widgets/types.js +0 -31
  205. package/dist/widgets/widget-base.d.ts +0 -42
  206. package/dist/widgets/widget-base.js +0 -173
@@ -1,12 +0,0 @@
1
- /**
2
- * Unsubscribe — the shape every `on…()` in this library hands back.
3
- *
4
- * [LAW:decomposition] It lives in `core/` because two subsystems that must not
5
- * depend on each other both need it: `host/` returns one from `onData` and
6
- * `onResize`, `widgets/` returns one from `onChange`, `onSubmit`, `onKey` and
7
- * `onMouse`. Either home above this tier would make the other import a
8
- * subsystem it has no business knowing about — the extraction of `src/host/`
9
- * out of `src/widgets/` is what surfaced that, since the type was sitting in
10
- * `widgets/types.ts` and the host seam was importing it from there.
11
- */
12
- export type Unsubscribe = () => void;
@@ -1,12 +0,0 @@
1
- /**
2
- * Unsubscribe — the shape every `on…()` in this library hands back.
3
- *
4
- * [LAW:decomposition] It lives in `core/` because two subsystems that must not
5
- * depend on each other both need it: `host/` returns one from `onData` and
6
- * `onResize`, `widgets/` returns one from `onChange`, `onSubmit`, `onKey` and
7
- * `onMouse`. Either home above this tier would make the other import a
8
- * subsystem it has no business knowing about — the extraction of `src/host/`
9
- * out of `src/widgets/` is what surfaced that, since the type was sitting in
10
- * `widgets/types.ts` and the host seam was importing it from there.
11
- */
12
- export {};
@@ -1,255 +0,0 @@
1
- /**
2
- * RichText — styled text with spans. The primary text type for the library.
3
- */
4
- import { Segment } from "./segment.js";
5
- import { Style } from "./style.js";
6
- import type { Renderable, Measurable, RenderOptions } from "./protocol.js";
7
- export declare class Span {
8
- readonly start: number;
9
- readonly end: number;
10
- readonly style: string | Style;
11
- constructor(start: number, end: number, style: string | Style);
12
- get hasLength(): boolean;
13
- toString(): string;
14
- split(offset: number): [Span, Span | undefined];
15
- move(delta: number): Span;
16
- rightCrop(offset: number): Span;
17
- extend(count: number): Span;
18
- }
19
- export interface RichTextOptions {
20
- style?: string | Style;
21
- justify?: "left" | "center" | "right" | "full";
22
- overflow?: "fold" | "crop" | "ellipsis";
23
- end?: string;
24
- tabSize?: number;
25
- noWrap?: boolean;
26
- }
27
- export declare class RichText implements Renderable, Measurable {
28
- private _text;
29
- private _spans;
30
- private _style;
31
- private _justify;
32
- private _overflow;
33
- private _end;
34
- private _tabSize;
35
- private _noWrap;
36
- constructor(text?: string, options?: RichTextOptions);
37
- get plain(): string;
38
- set plain(value: string);
39
- get length(): number;
40
- get cellLength(): number;
41
- get hasContent(): boolean;
42
- /** The base style every span layers over: a `Style`, or a name resolved at render. */
43
- get style(): string | Style;
44
- set style(value: string | Style);
45
- get justify(): "left" | "center" | "right" | "full" | undefined;
46
- set justify(value: "left" | "center" | "right" | "full" | undefined);
47
- get overflow(): "fold" | "crop" | "ellipsis" | undefined;
48
- set overflow(value: "fold" | "crop" | "ellipsis" | undefined);
49
- get end(): string;
50
- set end(value: string);
51
- get noWrap(): boolean;
52
- set noWrap(value: boolean);
53
- get spans(): readonly Span[];
54
- /**
55
- * This text's own style, spans aside, as the render drawing it resolves it.
56
- * A name the render's theme does not define resolves to no style, because
57
- * text forgives a missing name.
58
- */
59
- resolvedStyle(options: RenderOptions): Style;
60
- /**
61
- * The style of the cell-column at the named edge — base style merged with
62
- * any spans covering the leftmost (side="left") or rightmost (side="right")
63
- * character.
64
- *
65
- * [LAW:locality-or-seam] Used by `Joiner`s to paint the transition between
66
- * adjacent `Strip` items. Joiners only ever need the column adjacent to
67
- * them, so the cell type exposes that column rather than constraining its
68
- * interior to be uniform. For RichText with uniform styling, both edges
69
- * return the same style; for RichText with edge variation, each edge
70
- * accurately reports the column the joiner actually meets.
71
- *
72
- * Position is by character index (not cell column). For wide-character
73
- * text, the last character occupies the rightmost cell column — the bg
74
- * of that character covers both columns, so character-index lookup gives
75
- * the correct edge color.
76
- *
77
- * Takes the render's options because the edge is reported as it will be
78
- * drawn, and a style name draws as whatever the render's theme says.
79
- */
80
- edgeStyle(side: "left" | "right", options: RenderOptions): Style;
81
- append(content: string | RichText, style?: string | Style): this;
82
- contains(needle: string | RichText): boolean;
83
- at(index: number): RichText;
84
- slice(start?: number, end?: number): RichText;
85
- /**
86
- * The one way a span enters this text. [LAW:single-enforcer] An empty style
87
- * adds nothing, as the reference's `if style:` has it, and every other style
88
- * is admitted as given.
89
- */
90
- private _addSpan;
91
- stylize(style: string | Style, start?: number, end?: number): this;
92
- highlightRegex(pattern: RegExp, style?: string | Style): number;
93
- highlightWords(words: string[], style: string | Style, options?: {
94
- caseSensitive?: boolean;
95
- }): number;
96
- copy(): RichText;
97
- blankCopy(text?: string): RichText;
98
- split(separator?: string): RichText[];
99
- divide(offsets: number[]): RichText[];
100
- rstrip(): this;
101
- pad(count: number, char?: string): this;
102
- padLeft(count: number, char?: string): this;
103
- padRight(count: number, char?: string): this;
104
- setLength(length: number): this;
105
- extendStyle(count: number): this;
106
- /**
107
- * Truncate to a fixed cell-column width, in one of three modes.
108
- *
109
- * - `mode: "right"` (default) \u2014 drop characters from the right; append
110
- * `marker` (if any) at the cut.
111
- * - `mode: "left"` \u2014 drop characters from the left; prepend `marker` at
112
- * the cut.
113
- * - `mode: "middle"` \u2014 keep equal halves from both ends; place `marker`
114
- * in the middle.
115
- *
116
- * Marker default is `"\u2026"`. Pass `marker: ""` for raw cropping without an
117
- * indicator glyph.
118
- *
119
- * Spans are preserved through the cut: characters that survive keep their
120
- * styling; the marker (if any) is inserted as plain text with no span.
121
- * Use `stylize(...)` on the result to color the marker if needed.
122
- *
123
- * [LAW:dataflow-not-control-flow] mode/marker/width all flow as values;
124
- * the walk is the same shape regardless. No "if truncated then rebuild"
125
- * branch \u2014 the unchanged path just early-returns when content fits.
126
- */
127
- truncate(width: number, options?: {
128
- mode?: "right" | "left" | "middle";
129
- marker?: string;
130
- }): this;
131
- private _cropRightTo;
132
- private _cropLeftTo;
133
- /** Number of char-index code units that fit within `targetWidth` cell columns from the left. */
134
- private _cellPrefixCharLength;
135
- /** Char-index at which the suffix of `targetWidth` cell columns starts. */
136
- private _cellSuffixStartCharIndex;
137
- align(justify: "left" | "center" | "right", width: number): this;
138
- removeSuffix(suffix: string): this;
139
- appendTokens(tokens: Array<[string, (string | Style)?]>): this;
140
- static assemble(parts: Array<string | [string, (string | Style)?] | RichText>, options?: {
141
- style?: string | Style;
142
- }): RichText;
143
- static styled(text: string, style: string | Style): RichText;
144
- /**
145
- * Concatenate a sequence of `RichText` fragments into a single `RichText`,
146
- * flattening each fragment's wrapping `style` onto a span over that
147
- * fragment's range so downstream rendering preserves the original styling.
148
- *
149
- * Designed for the template engine's `RichText[]` output: a top-level
150
- * `{{ red "x" }}{{ blue "y" }}` evaluates to two fragments — one with
151
- * wrapping `style = red`, one with `blue` — and consumers that want a
152
- * single styled string for downstream rendering need both styles
153
- * preserved as spans on the concatenated result. The plain `append()`
154
- * propagates spans only, so this static does the additional work of
155
- * lifting `frag.style` into a span before appending.
156
- *
157
- * Empty input → empty `RichText` with `end: ""`. Caller can override
158
- * `end` (defaults to `""` — the engine-output case rarely wants a
159
- * trailing newline added by the container).
160
- */
161
- static fromFragments(fragments: readonly RichText[], options?: {
162
- end?: string;
163
- }): RichText;
164
- render(options: RenderOptions): Iterable<Segment>;
165
- measure(options: RenderOptions): {
166
- minimum: number;
167
- maximum: number;
168
- };
169
- private _expandTabs;
170
- /**
171
- * The rendered text cut at every span edge, each piece carrying the base
172
- * style plus every span covering it.
173
- *
174
- * Walked span-first rather than piece-first, and that direction is the whole
175
- * performance argument. The pieces are cut at the span edges themselves, so
176
- * a span covers a piece exactly when it covers the piece's first character —
177
- * which makes each span's run of pieces a contiguous range it can be written
178
- * into once, instead of a question every piece asks of every span. The
179
- * piece-first form charged `spans x pieces`, and the pieces are themselves
180
- * cut by the spans, so anything styling densely paid the square in ordinary
181
- * use: 8,000 one-character spans took 211ms where 1,000 took 3.2ms. Every
182
- * `Highlighter` over a large value reaches that, and so does `Pretty`, whose
183
- * indent guides emit a span per indent character.
184
- *
185
- * Span-first is also what keeps the composition honest, for free. `Style.add`
186
- * is order-dependent and the last writer wins, so the pieces have to fold
187
- * their styles in `_spans` order — which iterating `_spans` is, and which a
188
- * sweep ordered by position would have had to reconstruct.
189
- *
190
- * [LAW:dataflow-not-control-flow] A span covering nothing — empty, reversed,
191
- * or entirely past the text — still cuts the text where its edges land, as it
192
- * always did, and then folds into no piece at all: its range comes out empty
193
- * and no case handles it.
194
- */
195
- private _buildSegments;
196
- /**
197
- * The pieces one logical line wrapped into, each placed in a canvas
198
- * `maxWidth` wide, as Rich's `Lines.justify` places them — pinned block for
199
- * block against the reference in `test/core/text-justify.test.ts`.
200
- *
201
- * It is handed the whole wrapped line because `full` is the one mode a
202
- * piece cannot answer alone: the reference leaves a paragraph's last line
203
- * ragged, so where the piece sits decides its answer where the other three
204
- * modes need only the piece itself. The set that decides "last" is this one
205
- * and not the whole render — `Text.wrap` calls `Lines.justify` once per
206
- * *logical* line — and `Segment.divide` already handed it over whole.
207
- */
208
- private _justifyLines;
209
- /**
210
- * One line placed in a canvas `maxWidth` wide.
211
- *
212
- * Centre and right align on the line's *content*. The whitespace a wrap
213
- * leaves on the end of the line it closed is the break's own padding, not
214
- * text, and aligning around it pushes the text half a gap off true — a
215
- * centred title that wraps drifts left on every line that happens to end in
216
- * a space. Left keeps that whitespace, because there it is already on the
217
- * side the padding goes.
218
- *
219
- * `undefined` is not `"left"`: it is Rich's `"default"`, which places the
220
- * line without padding it at all. That distinction is what lets a soft-wrapped
221
- * `Console.print` leave its lines at their natural width.
222
- */
223
- private _justifyLine;
224
- /**
225
- * One line of a wrapped paragraph, its gaps widened until it fills the
226
- * canvas — what `justify: "full"` promises, and what the reference's
227
- * `Lines.justify` does to every line of a paragraph but the last.
228
- *
229
- * Slack goes in a cell at a time, starting at the rightmost gap and walking
230
- * left, round and round until the line is full. That order is the
231
- * reference's own, and what it decides is where an odd cell lands when the
232
- * slack will not divide evenly: the right-hand gaps take it.
233
- *
234
- * The words come from the line's *text* split on a single space, with the
235
- * blank a trailing separator leaves behind dropped — `Text.split` and
236
- * `String.prototype.split` agree on that list, empty words and all. Two
237
- * consequences read as bugs until you know whose they are: a run of n
238
- * spaces is n gaps rather than one, so spacing an author widened stretches
239
- * instead of collapsing, and the whitespace a wrap left hanging is a gap
240
- * like the rest, which is why a filled line does not keep it. Both are
241
- * pinned in `text-justify.golden.txt`, by the `uneven` and `sentence`
242
- * blocks respectively.
243
- */
244
- private _fillLine;
245
- /**
246
- * One wrapped line cut to the canvas.
247
- *
248
- * Everything reaching here already survived wrapping, so the only text still
249
- * too wide is text no break could help: a word longer than the canvas under
250
- * a non-folding overflow method, a glyph wider than the budget, or a canvas
251
- * with no cells at all. That is what makes the overflow method a last
252
- * resort rather than the first thing a long cell meets.
253
- */
254
- private _fitLine;
255
- }