@cube-drone/marquee-html-renderer 0.2.0 → 0.3.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/dist/render.js CHANGED
@@ -315,6 +315,14 @@ function directive(name, attrs, nodes, ctx) {
315
315
  }
316
316
  case "table":
317
317
  return renderTable(attrs, nodes, ctx);
318
+ case "center":
319
+ case "right":
320
+ case "left":
321
+ // The <center> tag, back from the dead in directive clothing - plus
322
+ // its siblings: right for symmetry, left as the un-aligner (useful
323
+ // only inside the other two, which is exactly when you want it).
324
+ // Physical directions, deliberately: predictable beats logical.
325
+ return `<div class="mq-${name}">${inner}</div>`;
318
326
  }
319
327
  // Unknown vocabulary: a container renders its children with an affordance
320
328
  // that something wrapped them; a leaf renders the inert placeholder.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@cube-drone/marquee-html-renderer",
3
- "version": "0.2.0",
3
+ "version": "0.3.0",
4
4
  "description": "Reference static HTML renderer for the Marquee markup language",
5
5
  "license": "MPL-2.0",
6
6
  "repository": {
@@ -35,12 +35,12 @@
35
35
  "prepack": "npm run build"
36
36
  },
37
37
  "dependencies": {
38
- "@cube-drone/marquee-parser": "^0.2.0"
38
+ "@cube-drone/marquee-parser": "^0.3.0"
39
39
  },
40
40
  "devDependencies": {
41
- "@cube-drone/marquee-css": "^0.2.0",
42
- "@cube-drone/marquee-fonts": "^0.2.0",
43
- "@cube-drone/marquee-turbolink": "^0.2.0",
41
+ "@cube-drone/marquee-css": "^0.3.0",
42
+ "@cube-drone/marquee-fonts": "^0.3.0",
43
+ "@cube-drone/marquee-turbolink": "^0.3.0",
44
44
  "@types/node": "^24.0.0",
45
45
  "typescript": "^5.9.0"
46
46
  }
package/src/render.ts CHANGED
@@ -349,6 +349,14 @@ function directive(name: string, attrs: Attrs, nodes: Node[], ctx: Ctx): string
349
349
  }
350
350
  case "table":
351
351
  return renderTable(attrs, nodes, ctx);
352
+ case "center":
353
+ case "right":
354
+ case "left":
355
+ // The <center> tag, back from the dead in directive clothing - plus
356
+ // its siblings: right for symmetry, left as the un-aligner (useful
357
+ // only inside the other two, which is exactly when you want it).
358
+ // Physical directions, deliberately: predictable beats logical.
359
+ return `<div class="mq-${name}">${inner}</div>`;
352
360
  }
353
361
  // Unknown vocabulary: a container renders its children with an affordance
354
362
  // that something wrapped them; a leaf renders the inert placeholder.