@sharpee/text-blocks 0.9.113 → 1.0.8

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/guards.d.ts CHANGED
@@ -10,7 +10,7 @@ import type { TextContent, IDecoration, ITextBlock } from './types';
10
10
  * @example
11
11
  * const content: TextContent = getContent();
12
12
  * if (isDecoration(content)) {
13
- * console.log(content.type); // TypeScript knows this is IDecoration
13
+ * console.log(content.className); // TypeScript knows this is IDecoration
14
14
  * }
15
15
  */
16
16
  export declare function isDecoration(content: TextContent): content is IDecoration;
@@ -50,7 +50,7 @@ export declare function isActionBlock(block: ITextBlock): boolean;
50
50
  * @example
51
51
  * const text = extractPlainText([
52
52
  * 'You take ',
53
- * { type: 'item', content: ['the sword'] },
53
+ * { className: 'sharpee-item', content: ['the sword'] },
54
54
  * '.'
55
55
  * ]);
56
56
  * // Returns: "You take the sword."
package/guards.js CHANGED
@@ -18,11 +18,11 @@ exports.extractPlainText = extractPlainText;
18
18
  * @example
19
19
  * const content: TextContent = getContent();
20
20
  * if (isDecoration(content)) {
21
- * console.log(content.type); // TypeScript knows this is IDecoration
21
+ * console.log(content.className); // TypeScript knows this is IDecoration
22
22
  * }
23
23
  */
24
24
  function isDecoration(content) {
25
- return typeof content === 'object' && content !== null && 'type' in content && 'content' in content;
25
+ return typeof content === 'object' && content !== null && 'className' in content && 'content' in content;
26
26
  }
27
27
  /**
28
28
  * Check if a value is a valid TextBlock.
@@ -75,7 +75,7 @@ function isActionBlock(block) {
75
75
  * @example
76
76
  * const text = extractPlainText([
77
77
  * 'You take ',
78
- * { type: 'item', content: ['the sword'] },
78
+ * { className: 'sharpee-item', content: ['the sword'] },
79
79
  * '.'
80
80
  * ]);
81
81
  * // Returns: "You take the sword."
package/guards.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"guards.js","sourceRoot":"","sources":["../../../repos/sharpee/packages/text-blocks/src/guards.ts"],"names":[],"mappings":";AAAA;;;;GAIG;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,CAAC,CAAC;AACxC,CAAC;AAED;;;;;;;;;;GAUG;AACH,SAAgB,gBAAgB,CAAC,OAAmC;IAClE,OAAO,OAAO;SACX,GAAG,CAAC,CAAC,IAAI,EAAE,EAAE;QACZ,IAAI,OAAO,IAAI,KAAK,QAAQ,EAAE,CAAC;YAC7B,OAAO,IAAI,CAAC;QACd,CAAC;QACD,OAAO,gBAAgB,CAAC,IAAI,CAAC,OAAO,CAAC,CAAC;IACxC,CAAC,CAAC;SACD,IAAI,CAAC,EAAE,CAAC,CAAC;AACd,CAAC"}
package/index.d.ts CHANGED
@@ -12,7 +12,7 @@
12
12
  * @see ADR-091: Text Decorations
13
13
  */
14
14
  export type { TextContent, IDecoration, ITextBlock } from './types.js';
15
- export { CORE_DECORATION_TYPES, CORE_BLOCK_KEYS } from './types.js';
15
+ export { CORE_BLOCK_KEYS } from './types.js';
16
16
  export { CORE_BLOCK_KEYS as BLOCK_KEYS } from './types.js';
17
17
  export { isDecoration, isTextBlock, hasKeyPrefix, isStatusBlock, isRoomBlock, isActionBlock, extractPlainText, } from './guards.js';
18
18
  export declare const BLOCK_KEY_PREFIXES: {
package/index.d.ts.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../repos/sharpee/packages/text-blocks/src/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;GAYG;AAGH,YAAY,EAAE,WAAW,EAAE,WAAW,EAAE,UAAU,EAAE,MAAM,YAAY,CAAC;AAGvE,OAAO,EAAE,qBAAqB,EAAE,eAAe,EAAE,MAAM,YAAY,CAAC;AAGpE,OAAO,EAAE,eAAe,IAAI,UAAU,EAAE,MAAM,YAAY,CAAC;AAG3D,OAAO,EACL,YAAY,EACZ,WAAW,EACX,YAAY,EACZ,aAAa,EACb,WAAW,EACX,aAAa,EACb,gBAAgB,GACjB,MAAM,aAAa,CAAC;AAGrB,eAAO,MAAM,kBAAkB;;;;CAIrB,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../repos/sharpee/packages/text-blocks/src/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;GAYG;AAGH,YAAY,EAAE,WAAW,EAAE,WAAW,EAAE,UAAU,EAAE,MAAM,YAAY,CAAC;AAIvE,OAAO,EAAE,eAAe,EAAE,MAAM,YAAY,CAAC;AAG7C,OAAO,EAAE,eAAe,IAAI,UAAU,EAAE,MAAM,YAAY,CAAC;AAG3D,OAAO,EACL,YAAY,EACZ,WAAW,EACX,YAAY,EACZ,aAAa,EACb,WAAW,EACX,aAAa,EACb,gBAAgB,GACjB,MAAM,aAAa,CAAC;AAGrB,eAAO,MAAM,kBAAkB;;;;CAIrB,CAAC"}
package/index.js CHANGED
@@ -13,10 +13,10 @@
13
13
  * @see ADR-091: Text Decorations
14
14
  */
15
15
  Object.defineProperty(exports, "__esModule", { value: true });
16
- exports.BLOCK_KEY_PREFIXES = exports.extractPlainText = exports.isActionBlock = exports.isRoomBlock = exports.isStatusBlock = exports.hasKeyPrefix = exports.isTextBlock = exports.isDecoration = exports.BLOCK_KEYS = exports.CORE_BLOCK_KEYS = exports.CORE_DECORATION_TYPES = void 0;
17
- // Constants
16
+ exports.BLOCK_KEY_PREFIXES = exports.extractPlainText = exports.isActionBlock = exports.isRoomBlock = exports.isStatusBlock = exports.hasKeyPrefix = exports.isTextBlock = exports.isDecoration = exports.BLOCK_KEYS = exports.CORE_BLOCK_KEYS = void 0;
17
+ // Constants — `CORE_DECORATION_TYPES` removed per ADR-174 (vocabulary
18
+ // now lives in `@sharpee/engine/src/prose-pipeline/decorations/platform-vocabulary.ts`).
18
19
  var types_js_1 = require("./types.js");
19
- Object.defineProperty(exports, "CORE_DECORATION_TYPES", { enumerable: true, get: function () { return types_js_1.CORE_DECORATION_TYPES; } });
20
20
  Object.defineProperty(exports, "CORE_BLOCK_KEYS", { enumerable: true, get: function () { return types_js_1.CORE_BLOCK_KEYS; } });
21
21
  // Alias for text-service compatibility
22
22
  var types_js_2 = require("./types.js");
package/index.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../repos/sharpee/packages/text-blocks/src/index.ts"],"names":[],"mappings":";AAAA;;;;;;;;;;;;GAYG;;;AAKH,YAAY;AACZ,uCAAoE;AAA3D,iHAAA,qBAAqB,OAAA;AAAE,2GAAA,eAAe,OAAA;AAE/C,uCAAuC;AACvC,uCAA2D;AAAlD,sGAAA,eAAe,OAAc;AAEtC,4BAA4B;AAC5B,yCAQqB;AAPnB,yGAAA,YAAY,OAAA;AACZ,wGAAA,WAAW,OAAA;AACX,yGAAA,YAAY,OAAA;AACZ,0GAAA,aAAa,OAAA;AACb,wGAAA,WAAW,OAAA;AACX,0GAAA,aAAa,OAAA;AACb,6GAAA,gBAAgB,OAAA;AAGlB,iCAAiC;AACpB,QAAA,kBAAkB,GAAG;IAChC,MAAM,EAAE,SAAS;IACjB,IAAI,EAAE,OAAO;IACb,MAAM,EAAE,SAAS;CACT,CAAC"}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../repos/sharpee/packages/text-blocks/src/index.ts"],"names":[],"mappings":";AAAA;;;;;;;;;;;;GAYG;;;AAKH,sEAAsE;AACtE,yFAAyF;AACzF,uCAA6C;AAApC,2GAAA,eAAe,OAAA;AAExB,uCAAuC;AACvC,uCAA2D;AAAlD,sGAAA,eAAe,OAAc;AAEtC,4BAA4B;AAC5B,yCAQqB;AAPnB,yGAAA,YAAY,OAAA;AACZ,wGAAA,WAAW,OAAA;AACX,yGAAA,YAAY,OAAA;AACZ,0GAAA,aAAa,OAAA;AACb,wGAAA,WAAW,OAAA;AACX,0GAAA,aAAa,OAAA;AACb,6GAAA,gBAAgB,OAAA;AAGlB,iCAAiC;AACpB,QAAA,kBAAkB,GAAG;IAChC,MAAM,EAAE,SAAS;IACjB,IAAI,EAAE,OAAO;IACb,MAAM,EAAE,SAAS;CACT,CAAC"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@sharpee/text-blocks",
3
- "version": "0.9.113",
3
+ "version": "1.0.8",
4
4
  "description": "Pure interfaces for structured text output (ITextBlock, IDecoration)",
5
5
  "main": "./index.js",
6
6
  "types": "./index.d.ts",
package/types.d.ts CHANGED
@@ -14,48 +14,61 @@
14
14
  * // Plain text
15
15
  * const plain: TextContent = "You take the sword.";
16
16
  *
17
- * // Decorated content
17
+ * // Decorated content (post ADR-174)
18
18
  * const decorated: TextContent = {
19
- * type: 'item',
19
+ * className: 'sharpee-item',
20
20
  * content: ['brass lantern']
21
21
  * };
22
22
  */
23
23
  export type TextContent = string | IDecoration;
24
24
  /**
25
- * Decorated content with semantic type.
25
+ * Decorated content with a final, fully-resolved CSS class name.
26
26
  *
27
- * The `type` field is an open string to support:
28
- * - Core types: 'em', 'strong', 'item', 'room', 'npc', 'command', 'direction'
29
- * - Presentational: 'underline', 'strikethrough', 'super', 'sub'
30
- * - Story-defined: 'photopia.red', 'dungeo.thief', etc.
27
+ * Per ADR-174, the bracket parser resolves bracketed names against a
28
+ * closed platform vocabulary at parse time:
29
+ * - Platform names (e.g. `em`, `item`, `color-red`) become
30
+ * `sharpee-{name}` and are styled by the platform CSS bundle.
31
+ * - Author names pass through verbatim and the story owns their CSS.
32
+ *
33
+ * Renderers translate `IDecoration` to their target output (HTML span
34
+ * for browser, ANSI for terminal, ignored for audio).
31
35
  *
32
36
  * @example
33
- * // Emphasis
34
- * { type: 'em', content: ['carefully'] }
37
+ * // Platform emphasis (resolved from `[em:carefully]`)
38
+ * { className: 'sharpee-em', content: ['carefully'] }
39
+ *
40
+ * // Platform item name
41
+ * { className: 'sharpee-item', content: ['brass lantern'] }
35
42
  *
36
- * // Item name
37
- * { type: 'item', content: ['brass lantern'] }
43
+ * // Author class
44
+ * { className: 'thief-taunt', content: ["You'll regret this."] }
38
45
  *
39
46
  * // Nested decorations
40
- * { type: 'item', content: [
41
- * { type: 'em', content: ['glowing'] },
47
+ * { className: 'sharpee-item', content: [
48
+ * { className: 'sharpee-em', content: ['glowing'] },
42
49
  * ' lantern'
43
50
  * ]}
44
- *
45
- * // Story-defined color (Photopia pattern)
46
- * { type: 'photopia.red', content: ['The light was red, like always.'] }
47
51
  */
48
52
  export interface IDecoration {
49
53
  /**
50
- * Semantic type of the decoration.
51
- * Open string to allow story extensions.
54
+ * Final, fully-resolved CSS class name. Already prefixed with
55
+ * `sharpee-` for platform-vocabulary names; bare for author names.
56
+ * @see ADR-174 §Wire shape
52
57
  */
53
- readonly type: string;
58
+ readonly className: string;
54
59
  /**
55
60
  * Content within the decoration.
56
61
  * Can contain nested decorations or plain strings.
57
62
  */
58
63
  readonly content: ReadonlyArray<TextContent>;
64
+ /**
65
+ * Optional value carried by a parameterized decoration (ADR-183) —
66
+ * e.g. the width `%` for `sharpee-center`, the level for
67
+ * `sharpee-indent`. Renderers emit it as a `data-value` attribute,
68
+ * never as an inline style. Absent for non-parameterized decorations.
69
+ * @see ADR-183 §3 — Wire + render
70
+ */
71
+ readonly value?: string;
59
72
  }
60
73
  /**
61
74
  * A block of text output with semantic key (channel).
@@ -77,7 +90,7 @@ export interface IDecoration {
77
90
  * // Room name block
78
91
  * {
79
92
  * key: 'room.name',
80
- * content: [{ type: 'room', content: ['West of House'] }]
93
+ * content: [{ className: 'sharpee-room', content: ['West of House'] }]
81
94
  * }
82
95
  *
83
96
  * // Action result with decorated item
@@ -85,7 +98,7 @@ export interface IDecoration {
85
98
  * key: 'action.result',
86
99
  * content: [
87
100
  * 'You take ',
88
- * { type: 'item', content: ['the brass lantern'] },
101
+ * { className: 'sharpee-item', content: ['the brass lantern'] },
89
102
  * '.'
90
103
  * ]
91
104
  * }
@@ -106,35 +119,29 @@ export interface ITextBlock {
106
119
  * Block content - array of plain strings and decorations.
107
120
  */
108
121
  readonly content: ReadonlyArray<TextContent>;
122
+ /**
123
+ * Visual continuation hint. When `true`, the renderer must collapse
124
+ * the paragraph margin between this block and its predecessor so the
125
+ * two lines appear flush (no inter-line gap beyond `line-height`).
126
+ *
127
+ * Used to express multi-line content where every line is its own
128
+ * block (so blocks carry no intra-content `\n`), while preserving
129
+ * the tight visual stacking that single-block-with-newlines used to
130
+ * provide. Invariant: a `tight` block must not appear first in a
131
+ * packet — the renderer relies on a predecessor to collapse against.
132
+ */
133
+ readonly tight?: boolean;
134
+ /**
135
+ * Optional semantic CSS class applied to the rendered element by the
136
+ * browser main-channel renderer (in addition to `main-entry`). Used
137
+ * for content with its own visual identity — game banner pieces
138
+ * (`game-title`, `story-version`, `platform-version`, `sub-title`,
139
+ * `author-list`, `banner-spacer`), and similar future categories.
140
+ * Author classes (no `sharpee-` prefix) flow through unchanged so
141
+ * stories can define their own.
142
+ */
143
+ readonly className?: string;
109
144
  }
110
- /**
111
- * Core decoration types defined by the platform.
112
- * Stories can extend with custom types.
113
- */
114
- export declare const CORE_DECORATION_TYPES: {
115
- /** Emphasis (typically italic) */
116
- readonly EM: "em";
117
- /** Strong emphasis (typically bold) */
118
- readonly STRONG: "strong";
119
- /** Item/object name */
120
- readonly ITEM: "item";
121
- /** Room/location name */
122
- readonly ROOM: "room";
123
- /** NPC/character name */
124
- readonly NPC: "npc";
125
- /** Suggested command */
126
- readonly COMMAND: "command";
127
- /** Exit direction */
128
- readonly DIRECTION: "direction";
129
- /** Underlined text */
130
- readonly UNDERLINE: "underline";
131
- /** Struck-through text */
132
- readonly STRIKETHROUGH: "strikethrough";
133
- /** Superscript */
134
- readonly SUPER: "super";
135
- /** Subscript */
136
- readonly SUB: "sub";
137
- };
138
145
  /**
139
146
  * Core block keys defined by the platform.
140
147
  * Stories can emit custom keys.
package/types.d.ts.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../repos/sharpee/packages/text-blocks/src/types.ts"],"names":[],"mappings":"AAAA;;;;;;;;GAQG;AAEH;;;;;;;;;;;;GAYG;AACH,MAAM,MAAM,WAAW,GAAG,MAAM,GAAG,WAAW,CAAC;AAE/C;;;;;;;;;;;;;;;;;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AE,aAAa,CAAC,WAAW,CAAC,CAAC;IAE7C;;;;;;OAMG;IACH,QAAQ,CAAC,KAAK,CAAC,EAAE,MAAM,CAAC;CACzB;AAED;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAsCG;AACH,MAAM,WAAW,UAAU;IACzB;;;OAGG;IACH,QAAQ,CAAC,GAAG,EAAE,MAAM,CAAC;IAErB;;OAEG;IACH,QAAQ,CAAC,OAAO,EAAE,aAAa,CAAC,WAAW,CAAC,CAAC;IAE7C;;;;;;;;;;OAUG;IACH,QAAQ,CAAC,KAAK,CAAC,EAAE,OAAO,CAAC;IAEzB;;;;;;;;OAQG;IACH,QAAQ,CAAC,SAAS,CAAC,EAAE,MAAM,CAAC;CAC7B;AAED;;;GAGG;AACH,eAAO,MAAM,eAAe;IAC1B,iBAAiB;;IAEjB,uBAAuB;;IAEvB,4BAA4B;;IAE5B,4BAA4B;;IAE5B,6BAA6B;;IAE7B,gCAAgC;;IAEhC,iCAAiC;;IAEjC,8BAA8B;;IAE9B,mBAAmB;;IAEnB,qBAAqB;;IAErB,yBAAyB;;IAEzB,0BAA0B;;CAElB,CAAC"}
package/types.js CHANGED
@@ -9,35 +9,7 @@
9
9
  * @see ADR-091: Text Decorations
10
10
  */
11
11
  Object.defineProperty(exports, "__esModule", { value: true });
12
- exports.CORE_BLOCK_KEYS = exports.CORE_DECORATION_TYPES = void 0;
13
- /**
14
- * Core decoration types defined by the platform.
15
- * Stories can extend with custom types.
16
- */
17
- exports.CORE_DECORATION_TYPES = {
18
- /** Emphasis (typically italic) */
19
- EM: 'em',
20
- /** Strong emphasis (typically bold) */
21
- STRONG: 'strong',
22
- /** Item/object name */
23
- ITEM: 'item',
24
- /** Room/location name */
25
- ROOM: 'room',
26
- /** NPC/character name */
27
- NPC: 'npc',
28
- /** Suggested command */
29
- COMMAND: 'command',
30
- /** Exit direction */
31
- DIRECTION: 'direction',
32
- /** Underlined text */
33
- UNDERLINE: 'underline',
34
- /** Struck-through text */
35
- STRIKETHROUGH: 'strikethrough',
36
- /** Superscript */
37
- SUPER: 'super',
38
- /** Subscript */
39
- SUB: 'sub',
40
- };
12
+ exports.CORE_BLOCK_KEYS = void 0;
41
13
  /**
42
14
  * Core block keys defined by the platform.
43
15
  * Stories can emit custom keys.
package/types.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"types.js","sourceRoot":"","sources":["../../../repos/sharpee/packages/text-blocks/src/types.ts"],"names":[],"mappings":";AAAA;;;;;;;;GAQG;;;AA2GH;;;GAGG;AACU,QAAA,qBAAqB,GAAG;IACnC,kCAAkC;IAClC,EAAE,EAAE,IAAI;IACR,uCAAuC;IACvC,MAAM,EAAE,QAAQ;IAChB,uBAAuB;IACvB,IAAI,EAAE,MAAM;IACZ,yBAAyB;IACzB,IAAI,EAAE,MAAM;IACZ,yBAAyB;IACzB,GAAG,EAAE,KAAK;IACV,wBAAwB;IACxB,OAAO,EAAE,SAAS;IAClB,qBAAqB;IACrB,SAAS,EAAE,WAAW;IACtB,sBAAsB;IACtB,SAAS,EAAE,WAAW;IACtB,0BAA0B;IAC1B,aAAa,EAAE,eAAe;IAC9B,kBAAkB;IAClB,KAAK,EAAE,OAAO;IACd,gBAAgB;IAChB,GAAG,EAAE,KAAK;CACF,CAAC;AAEX;;;GAGG;AACU,QAAA,eAAe,GAAG;IAC7B,iBAAiB;IACjB,SAAS,EAAE,WAAW;IACtB,uBAAuB;IACvB,gBAAgB,EAAE,kBAAkB;IACpC,4BAA4B;IAC5B,aAAa,EAAE,eAAe;IAC9B,4BAA4B;IAC5B,aAAa,EAAE,eAAe;IAC9B,6BAA6B;IAC7B,cAAc,EAAE,gBAAgB;IAChC,gCAAgC;IAChC,WAAW,EAAE,aAAa;IAC1B,iCAAiC;IACjC,YAAY,EAAE,cAAc;IAC5B,8BAA8B;IAC9B,YAAY,EAAE,cAAc;IAC5B,mBAAmB;IACnB,KAAK,EAAE,OAAO;IACd,qBAAqB;IACrB,MAAM,EAAE,QAAQ;IAChB,yBAAyB;IACzB,YAAY,EAAE,cAAc;IAC5B,0BAA0B;IAC1B,WAAW,EAAE,aAAa;CAClB,CAAC"}
1
+ {"version":3,"file":"types.js","sourceRoot":"","sources":["../../../repos/sharpee/packages/text-blocks/src/types.ts"],"names":[],"mappings":";AAAA;;;;;;;;GAQG;;;AAiJH;;;GAGG;AACU,QAAA,eAAe,GAAG;IAC7B,iBAAiB;IACjB,SAAS,EAAE,WAAW;IACtB,uBAAuB;IACvB,gBAAgB,EAAE,kBAAkB;IACpC,4BAA4B;IAC5B,aAAa,EAAE,eAAe;IAC9B,4BAA4B;IAC5B,aAAa,EAAE,eAAe;IAC9B,6BAA6B;IAC7B,cAAc,EAAE,gBAAgB;IAChC,gCAAgC;IAChC,WAAW,EAAE,aAAa;IAC1B,iCAAiC;IACjC,YAAY,EAAE,cAAc;IAC5B,8BAA8B;IAC9B,YAAY,EAAE,cAAc;IAC5B,mBAAmB;IACnB,KAAK,EAAE,OAAO;IACd,qBAAqB;IACrB,MAAM,EAAE,QAAQ;IAChB,yBAAyB;IACzB,YAAY,EAAE,cAAc;IAC5B,0BAA0B;IAC1B,WAAW,EAAE,aAAa;CAClB,CAAC"}