@shotstack/shotstack-canvas 1.3.9 → 1.4.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.
@@ -419,7 +419,8 @@ var FontRegistry = class _FontRegistry {
419
419
  return this.hb;
420
420
  }
421
421
  key(desc) {
422
- return `${desc.family}__${desc.weight ?? "400"}__${desc.style ?? "normal"}`;
422
+ const normalizedStyle = desc.style === "oblique" ? "italic" : desc.style ?? "normal";
423
+ return `${desc.family}__${desc.weight ?? "400"}__${normalizedStyle}`;
423
424
  }
424
425
  async registerFromBytes(bytes, desc) {
425
426
  try {
@@ -380,7 +380,8 @@ var FontRegistry = class _FontRegistry {
380
380
  return this.hb;
381
381
  }
382
382
  key(desc) {
383
- return `${desc.family}__${desc.weight ?? "400"}__${desc.style ?? "normal"}`;
383
+ const normalizedStyle = desc.style === "oblique" ? "italic" : desc.style ?? "normal";
384
+ return `${desc.family}__${desc.weight ?? "400"}__${normalizedStyle}`;
384
385
  }
385
386
  async registerFromBytes(bytes, desc) {
386
387
  try {
package/dist/entry.web.js CHANGED
@@ -383,7 +383,8 @@ var _FontRegistry = class _FontRegistry {
383
383
  return this.hb;
384
384
  }
385
385
  key(desc) {
386
- return `${desc.family}__${desc.weight ?? "400"}__${desc.style ?? "normal"}`;
386
+ const normalizedStyle = desc.style === "oblique" ? "italic" : desc.style ?? "normal";
387
+ return `${desc.family}__${desc.weight ?? "400"}__${normalizedStyle}`;
387
388
  }
388
389
  async registerFromBytes(bytes, desc) {
389
390
  try {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@shotstack/shotstack-canvas",
3
- "version": "1.3.9",
3
+ "version": "1.4.0",
4
4
  "description": "Text layout & animation engine (HarfBuzz) for Node & Web - fully self-contained.",
5
5
  "type": "module",
6
6
  "main": "./dist/entry.node.cjs",