From 647567f6b51e30a694dd57655a0126dc245922f0 Mon Sep 17 00:00:00 2001 From: Sam Rose Date: Thu, 7 Mar 2024 21:23:58 +0000 Subject: [PATCH] Making a start. --- package-lock.json | 793 +++------------------------------------------ package.json | 2 +- src/Grid.ts | 8 +- src/Leaf.ts | 2 +- src/Partitioner.ts | 27 +- src/Positioner.ts | 2 +- src/Stack.ts | 16 +- test-utils.ts | 28 +- tests.ts | 2 +- 9 files changed, 95 insertions(+), 785 deletions(-) diff --git a/package-lock.json b/package-lock.json index b43b5c4..255d6d1 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,12 +1,12 @@ { "name": "pixijs-layout", - "version": "0.1.11", + "version": "0.1.18", "lockfileVersion": 3, "requires": true, "packages": { "": { "name": "pixijs-layout", - "version": "0.1.11", + "version": "0.1.18", "license": "MIT", "devDependencies": { "@mapbox/node-pre-gyp": "^1.0.11", @@ -20,7 +20,7 @@ "typescript": "^5.1.6" }, "peerDependencies": { - "pixi.js-legacy": "^7.3.2" + "pixi.js": "8.0.0" } }, "node_modules/@ampproject/remapping": { @@ -1051,499 +1051,12 @@ "integrity": "sha512-3wdGidZyq5PB084XLES5TpOSRA3wjXAlIWMhum2kRcv/41Sn2emQ0dycQW4uZXLejwKvg6EsvbdlVL+FYEct7A==", "dev": true }, - "node_modules/@pixi/accessibility": { - "version": "7.3.2", - "resolved": "https://registry.npmjs.org/@pixi/accessibility/-/accessibility-7.3.2.tgz", - "integrity": "sha512-MdkU22HTauRvq9cMeWZIQGaDDa86sr+m12rKNdLV+FaDQgP/AhP+qCVpK7IKeJa9BrWGXaYMw/vueij7HkyDSA==", - "peer": true, - "peerDependencies": { - "@pixi/core": "7.3.2", - "@pixi/display": "7.3.2", - "@pixi/events": "7.3.2" - } - }, - "node_modules/@pixi/app": { - "version": "7.3.2", - "resolved": "https://registry.npmjs.org/@pixi/app/-/app-7.3.2.tgz", - "integrity": "sha512-3YRFSMvAxDebAz3/JJv+2jzbPkT8cHC0IHmmLRN8krDL1pZV+YjMLgMwN/Oeyv5TSbwNqnrF5su5whNkRaxeZQ==", - "peer": true, - "peerDependencies": { - "@pixi/core": "7.3.2", - "@pixi/display": "7.3.2" - } - }, - "node_modules/@pixi/assets": { - "version": "7.3.2", - "resolved": "https://registry.npmjs.org/@pixi/assets/-/assets-7.3.2.tgz", - "integrity": "sha512-yteq6ptAxA09EcwU9D9hl7qr5yWIqy+c2PsXkTDkc76vTAwIamLY3KxLq2aR5y1U4L4O6aHFJd26uNhHcuTPmw==", - "peer": true, - "dependencies": { - "@types/css-font-loading-module": "^0.0.7" - }, - "peerDependencies": { - "@pixi/core": "7.3.2", - "@pixi/utils": "7.3.2" - } - }, - "node_modules/@pixi/canvas-display": { - "version": "7.3.2", - "resolved": "https://registry.npmjs.org/@pixi/canvas-display/-/canvas-display-7.3.2.tgz", - "integrity": "sha512-VqeZ/6kwhzwaDWbdFD532HD9eDYu7h7ny8JfFDxGpdgzfhTVed/4mpYfSD6OmLxGcnnNhAUEc2QfS+hgamTKZg==", - "peer": true, - "peerDependencies": { - "@pixi/display": "7.3.2" - } - }, - "node_modules/@pixi/canvas-extract": { - "version": "7.3.2", - "resolved": "https://registry.npmjs.org/@pixi/canvas-extract/-/canvas-extract-7.3.2.tgz", - "integrity": "sha512-d96oQQlNNfeEV4cmN3MJV4vcn0xBVN8WVvTahQTtGqX+0FphLoe5G/4y/l5V3tyOy5OaRZ4l2mXw6RS9wfBcFA==", - "peer": true, - "peerDependencies": { - "@pixi/canvas-renderer": "7.3.2", - "@pixi/core": "7.3.2", - "@pixi/display": "7.3.2", - "@pixi/extract": "7.3.2" - } - }, - "node_modules/@pixi/canvas-graphics": { - "version": "7.3.2", - "resolved": "https://registry.npmjs.org/@pixi/canvas-graphics/-/canvas-graphics-7.3.2.tgz", - "integrity": "sha512-r/nPcriocJXqbiieWHpXWGL+5KcQPZGFDkJR28bGDKX6XBv0h7hhY1zX15bKa9zhbGK+MXrahSMYr6I+bLCAow==", - "peer": true, - "peerDependencies": { - "@pixi/canvas-display": "7.3.2", - "@pixi/canvas-renderer": "7.3.2", - "@pixi/core": "7.3.2", - "@pixi/graphics": "7.3.2" - } - }, - "node_modules/@pixi/canvas-mesh": { - "version": "7.3.2", - "resolved": "https://registry.npmjs.org/@pixi/canvas-mesh/-/canvas-mesh-7.3.2.tgz", - "integrity": "sha512-z97rrQS/rZ0bC+laB5Id7LCFl9WBU7UPb6tJflFL6iIBQrtAFmfvfjLfXWEXJk/1AcbN6W61AD6I2EEbBEG2Rw==", - "peer": true, - "peerDependencies": { - "@pixi/canvas-display": "7.3.2", - "@pixi/canvas-renderer": "7.3.2", - "@pixi/core": "7.3.2", - "@pixi/mesh": "7.3.2", - "@pixi/mesh-extras": "7.3.2" - } - }, - "node_modules/@pixi/canvas-particle-container": { - "version": "7.3.2", - "resolved": "https://registry.npmjs.org/@pixi/canvas-particle-container/-/canvas-particle-container-7.3.2.tgz", - "integrity": "sha512-qk7gw8ILrRvl8N6+CkGzrsNp1fBOUmPRxJlb3tfAn9dNOITwKCszysZHoMFNZy1rIpbe6oPgHNZ3/okSSHsw1A==", - "peer": true, - "peerDependencies": { - "@pixi/particle-container": "7.3.2" - } - }, - "node_modules/@pixi/canvas-prepare": { - "version": "7.3.2", - "resolved": "https://registry.npmjs.org/@pixi/canvas-prepare/-/canvas-prepare-7.3.2.tgz", - "integrity": "sha512-btUzzPv1/tKI/QIzbdA8wMk0W7QXdb5dYntX64UIqh1lU2QAzHlOJmCQ1QzJGKKiuSnxZLPCXo7UGogNENf/5A==", - "peer": true, - "peerDependencies": { - "@pixi/canvas-renderer": "7.3.2", - "@pixi/core": "7.3.2", - "@pixi/prepare": "7.3.2" - } - }, - "node_modules/@pixi/canvas-renderer": { - "version": "7.3.2", - "resolved": "https://registry.npmjs.org/@pixi/canvas-renderer/-/canvas-renderer-7.3.2.tgz", - "integrity": "sha512-LnZefvP8OhAagHQP3NvE03JYiJJkLucHd9Wdx7n7rcR8l2GYWqEPPtxgC7z+ZmWWFXTGXZJwGGRVj/RUPJWKdQ==", - "peer": true, - "peerDependencies": { - "@pixi/core": "7.3.2" - } - }, - "node_modules/@pixi/canvas-sprite": { - "version": "7.3.2", - "resolved": "https://registry.npmjs.org/@pixi/canvas-sprite/-/canvas-sprite-7.3.2.tgz", - "integrity": "sha512-MwBt9zJHMQONK//cApnMIGl5PO+iHDh8BfqoETUocEPKWLTS0CWeP0Sj05n+014wpqIQfpmpzkBLGiw3C1m2Dw==", - "peer": true, - "peerDependencies": { - "@pixi/canvas-display": "7.3.2", - "@pixi/canvas-renderer": "7.3.2", - "@pixi/core": "7.3.2", - "@pixi/sprite": "7.3.2" - } - }, - "node_modules/@pixi/canvas-sprite-tiling": { - "version": "7.3.2", - "resolved": "https://registry.npmjs.org/@pixi/canvas-sprite-tiling/-/canvas-sprite-tiling-7.3.2.tgz", - "integrity": "sha512-8d1uugMYBkTQ4tfGu4bcuM2E6o7RQmPdX2BwyD1gYcS1lUHx888tV2Fe8hBL4yiEcIY7dzsfoGWvvhRSKTh5oQ==", - "peer": true, - "peerDependencies": { - "@pixi/canvas-renderer": "7.3.2", - "@pixi/canvas-sprite": "7.3.2", - "@pixi/core": "7.3.2", - "@pixi/sprite-tiling": "7.3.2" - } - }, - "node_modules/@pixi/canvas-text": { - "version": "7.3.2", - "resolved": "https://registry.npmjs.org/@pixi/canvas-text/-/canvas-text-7.3.2.tgz", - "integrity": "sha512-DI4nu2efdjZq9XciewwkdiMzp7jPhFy/Dhz233nXT5B3KeR/2IOetUIHvam9n12aPmrLhhdVR+NYD8omIm8UXg==", - "peer": true, - "peerDependencies": { - "@pixi/canvas-sprite": "7.3.2", - "@pixi/sprite": "7.3.2", - "@pixi/text": "7.3.2" - } - }, - "node_modules/@pixi/color": { - "version": "7.3.2", - "resolved": "https://registry.npmjs.org/@pixi/color/-/color-7.3.2.tgz", - "integrity": "sha512-jur5PvdOtUBEUTjmPudW5qdQq6yYGlVGsi3HyhasJw14bN+GKJwiCKgIsyrsiNL5HBUXmje4ICwQohf6BqKqxA==", - "peer": true, - "dependencies": { - "@pixi/colord": "^2.9.6" - } - }, "node_modules/@pixi/colord": { "version": "2.9.6", "resolved": "https://registry.npmjs.org/@pixi/colord/-/colord-2.9.6.tgz", "integrity": "sha512-nezytU2pw587fQstUu1AsJZDVEynjskwOL+kibwcdxsMBFqPsFFNA7xl0ii/gXuDi6M0xj3mfRJj8pBSc2jCfA==", "peer": true }, - "node_modules/@pixi/compressed-textures": { - "version": "7.3.2", - "resolved": "https://registry.npmjs.org/@pixi/compressed-textures/-/compressed-textures-7.3.2.tgz", - "integrity": "sha512-J3ENMHDPQO6CJRei55gqI0WmiZJIK6SgsW5AEkShT0aAe5miEBSomv70pXw/58ru+4/Hx8cXjamsGt4aQB2D0Q==", - "peer": true, - "peerDependencies": { - "@pixi/assets": "7.3.2", - "@pixi/core": "7.3.2" - } - }, - "node_modules/@pixi/constants": { - "version": "7.3.2", - "resolved": "https://registry.npmjs.org/@pixi/constants/-/constants-7.3.2.tgz", - "integrity": "sha512-Q8W3ncsFxmfgC5EtokpG92qJZabd+Dl+pbQAdHwiPY3v+8UNq77u4VN2qtl1Z04864hCcg7AStIYEDrzqTLF6Q==", - "peer": true - }, - "node_modules/@pixi/core": { - "version": "7.3.2", - "resolved": "https://registry.npmjs.org/@pixi/core/-/core-7.3.2.tgz", - "integrity": "sha512-Pta3ee8MtJ3yKxGXzglBWgwbEOKMB6Eth+FpLTjL0rgxiqTB550YX6jsNEQQAzcGjCBlO3rC/IF57UZ2go/X6w==", - "peer": true, - "dependencies": { - "@pixi/color": "7.3.2", - "@pixi/constants": "7.3.2", - "@pixi/extensions": "7.3.2", - "@pixi/math": "7.3.2", - "@pixi/runner": "7.3.2", - "@pixi/settings": "7.3.2", - "@pixi/ticker": "7.3.2", - "@pixi/utils": "7.3.2", - "@types/offscreencanvas": "^2019.6.4" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/pixijs" - } - }, - "node_modules/@pixi/display": { - "version": "7.3.2", - "resolved": "https://registry.npmjs.org/@pixi/display/-/display-7.3.2.tgz", - "integrity": "sha512-cY5AnZ3TWt5GYGx4e5AQ2/2U9kP+RorBg/O30amJ+8e9bFk9rS8cjh/DDq/hc4lql96BkXAInTl40eHnAML5lQ==", - "peer": true, - "peerDependencies": { - "@pixi/core": "7.3.2" - } - }, - "node_modules/@pixi/events": { - "version": "7.3.2", - "resolved": "https://registry.npmjs.org/@pixi/events/-/events-7.3.2.tgz", - "integrity": "sha512-Moca9epu8jk1wIQCdVYjhz2pD9Ol21m50wvWUKvpgt9yM/AjkCLSDt8HO/PmTpavDrkhx5pVVWeDDA6FyUNaGA==", - "peer": true, - "peerDependencies": { - "@pixi/core": "7.3.2", - "@pixi/display": "7.3.2" - } - }, - "node_modules/@pixi/extensions": { - "version": "7.3.2", - "resolved": "https://registry.npmjs.org/@pixi/extensions/-/extensions-7.3.2.tgz", - "integrity": "sha512-Qw84ADfvmVu4Mwj+zTik/IEEK9lWS5n4trbrpQCcEZ+Mb8oRAXWvKz199mi1s7+LaZXDqeCY1yr2PHQaFf1KBA==", - "peer": true - }, - "node_modules/@pixi/extract": { - "version": "7.3.2", - "resolved": "https://registry.npmjs.org/@pixi/extract/-/extract-7.3.2.tgz", - "integrity": "sha512-KsoflvQZV/XD8A8xbtRnmI4reYekbI4MOi7ilwQe5tMz6O1mO7IzrSukxkSMD02f6SpbAqbi7a1EayTjvY0ECQ==", - "peer": true, - "peerDependencies": { - "@pixi/core": "7.3.2" - } - }, - "node_modules/@pixi/filter-alpha": { - "version": "7.3.2", - "resolved": "https://registry.npmjs.org/@pixi/filter-alpha/-/filter-alpha-7.3.2.tgz", - "integrity": "sha512-nZMdn310wH5ZK1slwv3X4qT8eLoAGO7SgYGCy5IsMtpCtNObzE9XA4tAfhXrjihyzPS9KvszgAbnv1Qpfh0/uw==", - "peer": true, - "peerDependencies": { - "@pixi/core": "7.3.2" - } - }, - "node_modules/@pixi/filter-blur": { - "version": "7.3.2", - "resolved": "https://registry.npmjs.org/@pixi/filter-blur/-/filter-blur-7.3.2.tgz", - "integrity": "sha512-unu3zhwHMhN+iAe7Td2rK40i2UJ2GOhzWK+6jcU3ZkMOsFCT5kgBoMRTejeQVcvCs6GoYK8imbkE7mXt05Vj6A==", - "peer": true, - "peerDependencies": { - "@pixi/core": "7.3.2" - } - }, - "node_modules/@pixi/filter-color-matrix": { - "version": "7.3.2", - "resolved": "https://registry.npmjs.org/@pixi/filter-color-matrix/-/filter-color-matrix-7.3.2.tgz", - "integrity": "sha512-rbyjes/9SMoV9jjPiK0sLMkmLfN8D17GoTJIfq/KLv1x9646W5fL2QSKkN04UkZ+020ndWvIOxK1S97tvRyCfg==", - "peer": true, - "peerDependencies": { - "@pixi/core": "7.3.2" - } - }, - "node_modules/@pixi/filter-displacement": { - "version": "7.3.2", - "resolved": "https://registry.npmjs.org/@pixi/filter-displacement/-/filter-displacement-7.3.2.tgz", - "integrity": "sha512-ZHl7Sfb8JYd9Z6j96OHCC0NhMKhhXJRE5AbkSDohjEMVCK1BV5rDGAHV8WVt/2MJ/j83CXUpydzyMhdM4lMchg==", - "peer": true, - "peerDependencies": { - "@pixi/core": "7.3.2" - } - }, - "node_modules/@pixi/filter-fxaa": { - "version": "7.3.2", - "resolved": "https://registry.npmjs.org/@pixi/filter-fxaa/-/filter-fxaa-7.3.2.tgz", - "integrity": "sha512-9brtlxDnQTZk2XiFBKdBK9e+8CX9LdxxcL7LRpjEyiHuAPvTlQgu9B85LrJ4GzWKqJJKaIIZBzhIoiCLUnfeXg==", - "peer": true, - "peerDependencies": { - "@pixi/core": "7.3.2" - } - }, - "node_modules/@pixi/filter-noise": { - "version": "7.3.2", - "resolved": "https://registry.npmjs.org/@pixi/filter-noise/-/filter-noise-7.3.2.tgz", - "integrity": "sha512-F8GQQ20n7tCjThX6GCXckiXz2YffOCxicTJ0oat9aVDZh+sVsAxYX0aKSdHh0hhv18F0yuc6tPsSL5DYb63xFg==", - "peer": true, - "peerDependencies": { - "@pixi/core": "7.3.2" - } - }, - "node_modules/@pixi/graphics": { - "version": "7.3.2", - "resolved": "https://registry.npmjs.org/@pixi/graphics/-/graphics-7.3.2.tgz", - "integrity": "sha512-PhU6j1yub4tH/s+/gqByzgZ3mLv1mfb6iGXbquycg3+WypcxHZn0opFtI/axsazaQ9SEaWxw1m3i40WG5ANH5g==", - "peer": true, - "peerDependencies": { - "@pixi/core": "7.3.2", - "@pixi/display": "7.3.2", - "@pixi/sprite": "7.3.2" - } - }, - "node_modules/@pixi/math": { - "version": "7.3.2", - "resolved": "https://registry.npmjs.org/@pixi/math/-/math-7.3.2.tgz", - "integrity": "sha512-dutoZ0IVJ5ME7UtYNo2szu4D7qsgtJB7e3ylujBVu7BOP2e710BVtFwFSFV768N14h9H5roGnuzVoDiJac2u+w==", - "peer": true - }, - "node_modules/@pixi/mesh": { - "version": "7.3.2", - "resolved": "https://registry.npmjs.org/@pixi/mesh/-/mesh-7.3.2.tgz", - "integrity": "sha512-LFkt7ELYXQLgbgHpjl68j6JD5ejUwma8zoPn2gqSBbY+6pK/phjvV1Wkh76muF46VvNulgXF0+qLIDdCsfrDaA==", - "peer": true, - "peerDependencies": { - "@pixi/core": "7.3.2", - "@pixi/display": "7.3.2" - } - }, - "node_modules/@pixi/mesh-extras": { - "version": "7.3.2", - "resolved": "https://registry.npmjs.org/@pixi/mesh-extras/-/mesh-extras-7.3.2.tgz", - "integrity": "sha512-s/tg9TsTZZxLEdCDKWnBChDGkc041HCTP7ykJv4fEROzb9B0lskULYyvv+/YNNKa2Ugb9WnkMknpOdOXCpjyyg==", - "peer": true, - "peerDependencies": { - "@pixi/core": "7.3.2", - "@pixi/mesh": "7.3.2" - } - }, - "node_modules/@pixi/mixin-cache-as-bitmap": { - "version": "7.3.2", - "resolved": "https://registry.npmjs.org/@pixi/mixin-cache-as-bitmap/-/mixin-cache-as-bitmap-7.3.2.tgz", - "integrity": "sha512-bZRlyUN5+9kCUjn67V0IFtYIrbmx9Vs4sMOmXyrX3Q4B4gPLE46IzZz3v0IVaTjp32udlQztfJalIaWbuqgb3A==", - "peer": true, - "peerDependencies": { - "@pixi/core": "7.3.2", - "@pixi/display": "7.3.2", - "@pixi/sprite": "7.3.2" - } - }, - "node_modules/@pixi/mixin-get-child-by-name": { - "version": "7.3.2", - "resolved": "https://registry.npmjs.org/@pixi/mixin-get-child-by-name/-/mixin-get-child-by-name-7.3.2.tgz", - "integrity": "sha512-mbUi3WxXrkViH7qOgjk4fu2BN36NwNb7u+Fy1J5dS8Bntj57ZVKmEV9PbUy0zYjXE8rVmeAvSu/2kbn5n9UutQ==", - "peer": true, - "peerDependencies": { - "@pixi/display": "7.3.2" - } - }, - "node_modules/@pixi/mixin-get-global-position": { - "version": "7.3.2", - "resolved": "https://registry.npmjs.org/@pixi/mixin-get-global-position/-/mixin-get-global-position-7.3.2.tgz", - "integrity": "sha512-1nhWbBgmw6rK7yQJxzeI9yjKYYEkM5i3pee8qVu4YWo3b1xWVQA7osQG7aGM/4qywDkXaA1ZvciA5hfg6f4Q5Q==", - "peer": true, - "peerDependencies": { - "@pixi/core": "7.3.2", - "@pixi/display": "7.3.2" - } - }, - "node_modules/@pixi/particle-container": { - "version": "7.3.2", - "resolved": "https://registry.npmjs.org/@pixi/particle-container/-/particle-container-7.3.2.tgz", - "integrity": "sha512-JYc4j4z97KmxyLp+1Lg0SNi8hy6RxcBBNQGk+CSLNXeDWxx3hykT5gj/ORX1eXyzHh1ZCG1XzeVS9Yr8QhlFHA==", - "peer": true, - "peerDependencies": { - "@pixi/core": "7.3.2", - "@pixi/display": "7.3.2", - "@pixi/sprite": "7.3.2" - } - }, - "node_modules/@pixi/prepare": { - "version": "7.3.2", - "resolved": "https://registry.npmjs.org/@pixi/prepare/-/prepare-7.3.2.tgz", - "integrity": "sha512-aLPAXSYLUhMwxzJtn9m0TSZe+dQlZCt09QNBqYbSi8LZId54QMDyvfBb4zBOJZrD2xAZgYL5RIJuKHwZtFX6lQ==", - "peer": true, - "peerDependencies": { - "@pixi/core": "7.3.2", - "@pixi/display": "7.3.2", - "@pixi/graphics": "7.3.2", - "@pixi/text": "7.3.2" - } - }, - "node_modules/@pixi/runner": { - "version": "7.3.2", - "resolved": "https://registry.npmjs.org/@pixi/runner/-/runner-7.3.2.tgz", - "integrity": "sha512-maKotoKJCQiQGBJwfM+iYdQKjrPN/Tn9+72F4WIf706zp/5vKoxW688Rsktg5BX4Mcn7ZkZvcJYTxj2Mv87lFA==", - "peer": true - }, - "node_modules/@pixi/settings": { - "version": "7.3.2", - "resolved": "https://registry.npmjs.org/@pixi/settings/-/settings-7.3.2.tgz", - "integrity": "sha512-vtxzuARDTbFe0fRYSqB53B+mPpX7v+QjjnCUmVMVvZiWr3QcngMWVml6c6dQDln7IakWoKZRrNG4FpggvDgLVg==", - "peer": true, - "dependencies": { - "@pixi/constants": "7.3.2", - "@types/css-font-loading-module": "^0.0.7", - "ismobilejs": "^1.1.0" - } - }, - "node_modules/@pixi/sprite": { - "version": "7.3.2", - "resolved": "https://registry.npmjs.org/@pixi/sprite/-/sprite-7.3.2.tgz", - "integrity": "sha512-IpWTKXExJNXVcY7ITopJ+JW48DahdbCo/81D2IYzBImq3jyiJM2Km5EoJgvAM5ZQ3Ev3KPPIBzYLD+HoPWcxdw==", - "peer": true, - "peerDependencies": { - "@pixi/core": "7.3.2", - "@pixi/display": "7.3.2" - } - }, - "node_modules/@pixi/sprite-animated": { - "version": "7.3.2", - "resolved": "https://registry.npmjs.org/@pixi/sprite-animated/-/sprite-animated-7.3.2.tgz", - "integrity": "sha512-j9pyUe4cefxE9wecNfbWQyL5fBQKvCGYaOA0DE1X46ukBHrIuhA8u3jg2X3N3r4IcbVvxpWFYDrDsWXWeiBmSw==", - "peer": true, - "peerDependencies": { - "@pixi/core": "7.3.2", - "@pixi/sprite": "7.3.2" - } - }, - "node_modules/@pixi/sprite-tiling": { - "version": "7.3.2", - "resolved": "https://registry.npmjs.org/@pixi/sprite-tiling/-/sprite-tiling-7.3.2.tgz", - "integrity": "sha512-tWVVb/rMIx5AczfUrVxa0dZaIufP5C0IOL7IGfFUDQqDu5JSAUC0mwLe4F12jAXBVsqYhCGYx5bIHbPiI5vcSQ==", - "peer": true, - "peerDependencies": { - "@pixi/core": "7.3.2", - "@pixi/display": "7.3.2", - "@pixi/sprite": "7.3.2" - } - }, - "node_modules/@pixi/spritesheet": { - "version": "7.3.2", - "resolved": "https://registry.npmjs.org/@pixi/spritesheet/-/spritesheet-7.3.2.tgz", - "integrity": "sha512-UkwqrPYDqrEdK5ub9qn/9VBvt5caA8ffV5iYR6ssCvrpaQovBKmS+b5pr/BYf8xNTExDpR3OmPIo8iDEYWWLuw==", - "peer": true, - "peerDependencies": { - "@pixi/assets": "7.3.2", - "@pixi/core": "7.3.2" - } - }, - "node_modules/@pixi/text": { - "version": "7.3.2", - "resolved": "https://registry.npmjs.org/@pixi/text/-/text-7.3.2.tgz", - "integrity": "sha512-LdtNj+K5tPB/0UcDcO52M/C7xhwFTGFhtdF42fPhRuJawM23M3zm1Y8PapXv+mury+IxCHT1w30YlAi0qTVpKQ==", - "peer": true, - "peerDependencies": { - "@pixi/core": "7.3.2", - "@pixi/sprite": "7.3.2" - } - }, - "node_modules/@pixi/text-bitmap": { - "version": "7.3.2", - "resolved": "https://registry.npmjs.org/@pixi/text-bitmap/-/text-bitmap-7.3.2.tgz", - "integrity": "sha512-p8KLgtZSPowWU/Zj+GVtfsUT8uGYo4TtKKYbLoWuxkRA5Pc1+4C9/rV/EOSFfoZIdW5C+iFg5VxRgBllUQf+aA==", - "peer": true, - "peerDependencies": { - "@pixi/assets": "7.3.2", - "@pixi/core": "7.3.2", - "@pixi/display": "7.3.2", - "@pixi/mesh": "7.3.2", - "@pixi/text": "7.3.2" - } - }, - "node_modules/@pixi/text-html": { - "version": "7.3.2", - "resolved": "https://registry.npmjs.org/@pixi/text-html/-/text-html-7.3.2.tgz", - "integrity": "sha512-IYhBWEPOvqUtlHkS5/c1Hseuricj5jrrGd21ivcvHmcnK/x2m+CRGvvzeBp1mqoYBnDbQVrD2wSXSe4Dv9tEJA==", - "peer": true, - "peerDependencies": { - "@pixi/core": "7.3.2", - "@pixi/display": "7.3.2", - "@pixi/sprite": "7.3.2", - "@pixi/text": "7.3.2" - } - }, - "node_modules/@pixi/ticker": { - "version": "7.3.2", - "resolved": "https://registry.npmjs.org/@pixi/ticker/-/ticker-7.3.2.tgz", - "integrity": "sha512-5kIPhBeXwDJohCzKzJJ6T7f1oAGbHAgeiwOjlTO+9lNXUX8ZPj0407V3syuF+64kFqJzIBCznBRpI+fmT4c9SA==", - "peer": true, - "dependencies": { - "@pixi/extensions": "7.3.2", - "@pixi/settings": "7.3.2", - "@pixi/utils": "7.3.2" - } - }, - "node_modules/@pixi/utils": { - "version": "7.3.2", - "resolved": "https://registry.npmjs.org/@pixi/utils/-/utils-7.3.2.tgz", - "integrity": "sha512-KhNvj9YcY7Zi2dTKZgDpx8C6OxKKR541vwtG6JgdBZZYDeMBOIghN2Vi5zn4diW5BhDfHBmdSJ1wZXEtE2MDwg==", - "peer": true, - "dependencies": { - "@pixi/color": "7.3.2", - "@pixi/constants": "7.3.2", - "@pixi/settings": "7.3.2", - "@types/earcut": "^2.1.0", - "earcut": "^2.2.4", - "eventemitter3": "^4.0.0", - "url": "^0.11.0" - } - }, "node_modules/@sinclair/typebox": { "version": "0.27.8", "resolved": "https://registry.npmjs.org/@sinclair/typebox/-/typebox-0.27.8.tgz", @@ -1642,16 +1155,10 @@ "@babel/types": "^7.20.7" } }, - "node_modules/@types/css-font-loading-module": { - "version": "0.0.7", - "resolved": "https://registry.npmjs.org/@types/css-font-loading-module/-/css-font-loading-module-0.0.7.tgz", - "integrity": "sha512-nl09VhutdjINdWyXxHWN/w9zlNCfr60JUqJbd24YXUuCwgeL0TpFSdElCwb6cxfB6ybE19Gjj4g0jsgkXxKv1Q==", - "peer": true - }, "node_modules/@types/earcut": { - "version": "2.1.3", - "resolved": "https://registry.npmjs.org/@types/earcut/-/earcut-2.1.3.tgz", - "integrity": "sha512-pskpibEbm73+7nA9RqxGEnAiALRO92DdoSVxasyjGrqzEndaSDjFG73GCtstMzhdOowZMItVw2fhTdxVrY221w==", + "version": "2.1.4", + "resolved": "https://registry.npmjs.org/@types/earcut/-/earcut-2.1.4.tgz", + "integrity": "sha512-qp3m9PPz4gULB9MhjGID7wpo3gJ4bTGXm7ltNDsmOvsPduTeHp8wSW9YckBj3mljeOh4F0m2z/0JKAALRKbmLQ==", "peer": true }, "node_modules/@types/graceful-fs": { @@ -1714,12 +1221,6 @@ "integrity": "sha512-rt40Nk13II9JwQBdeYqmbn2Q6IVTA5uPhvSO+JVqdXw/6/4glI6oR9ezty/A9Hg5u7JH4OmYmuQ+XvjKm0Datg==", "dev": true }, - "node_modules/@types/offscreencanvas": { - "version": "2019.7.2", - "resolved": "https://registry.npmjs.org/@types/offscreencanvas/-/offscreencanvas-2019.7.2.tgz", - "integrity": "sha512-ujCjOxeA07IbEBQYAkoOI+XFw5sT3nhWJ/xZfPR6reJppDG7iPQPZacQiLTtWH1b3a2NYXWlxvYqa40y/LAixQ==", - "peer": true - }, "node_modules/@types/stack-utils": { "version": "2.0.1", "resolved": "https://registry.npmjs.org/@types/stack-utils/-/stack-utils-2.0.1.tgz", @@ -1747,6 +1248,21 @@ "integrity": "sha512-iO9ZQHkZxHn4mSakYV0vFHAVDyEOIJQrV2uZ06HxEPcx+mt8swXoZHIbaaJ2crJYFfErySgktuTZ3BeLz+XmFA==", "dev": true }, + "node_modules/@webgpu/types": { + "version": "0.1.40", + "resolved": "https://registry.npmjs.org/@webgpu/types/-/types-0.1.40.tgz", + "integrity": "sha512-/BBkHLS6/eQjyWhY2H7Dx5DHcVrS2ICj9owvSRdgtQT6KcafLZA86tPze0xAOsd4FbsYKCUBUQyNi87q7gV7kw==", + "peer": true + }, + "node_modules/@xmldom/xmldom": { + "version": "0.8.10", + "resolved": "https://registry.npmjs.org/@xmldom/xmldom/-/xmldom-0.8.10.tgz", + "integrity": "sha512-2WALfTl4xo2SkGCYRt6rDTFfk9R1czmBvUQy12gK2KuRKIpWEhcbbzy8EZXtz/jkRqHX8bFEc6FC1HjX4TUWYw==", + "peer": true, + "engines": { + "node": ">=10.0.0" + } + }, "node_modules/abab": { "version": "2.0.6", "resolved": "https://registry.npmjs.org/abab/-/abab-2.0.6.tgz", @@ -2072,20 +1588,6 @@ "integrity": "sha512-E+XQCRwSbaaiChtv6k6Dwgc+bx+Bs6vuKJHHl5kox/BaKbhiXzqQOwK4cO22yElGp2OCmjwVhT3HmxgyPGnJfQ==", "dev": true }, - "node_modules/call-bind": { - "version": "1.0.5", - "resolved": "https://registry.npmjs.org/call-bind/-/call-bind-1.0.5.tgz", - "integrity": "sha512-C3nQxfFZxFRVoJoGKKI8y3MOEo129NQ+FgQ08iye+Mk4zNZZGdjfs06bVTr+DBSlA66Q2VEcMki/cUCP4SercQ==", - "peer": true, - "dependencies": { - "function-bind": "^1.1.2", - "get-intrinsic": "^1.2.1", - "set-function-length": "^1.1.1" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, "node_modules/callsites": { "version": "3.1.0", "resolved": "https://registry.npmjs.org/callsites/-/callsites-3.1.0.tgz", @@ -2365,20 +1867,6 @@ "node": ">=0.10.0" } }, - "node_modules/define-data-property": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/define-data-property/-/define-data-property-1.1.1.tgz", - "integrity": "sha512-E7uGkTzkk1d0ByLeSc6ZsFS79Axg+m1P/VsgYsxHgiuc3tFSj+MjMIwe90FC4lOAZzNBdY7kkO2P2wKdsQ1vgQ==", - "peer": true, - "dependencies": { - "get-intrinsic": "^1.2.1", - "gopd": "^1.0.1", - "has-property-descriptors": "^1.0.0" - }, - "engines": { - "node": ">= 0.4" - } - }, "node_modules/delayed-stream": { "version": "1.0.0", "resolved": "https://registry.npmjs.org/delayed-stream/-/delayed-stream-1.0.0.tgz", @@ -2563,12 +2051,6 @@ "node": ">=0.10.0" } }, - "node_modules/eventemitter3": { - "version": "4.0.7", - "resolved": "https://registry.npmjs.org/eventemitter3/-/eventemitter3-4.0.7.tgz", - "integrity": "sha512-8guHBZCwKnFhYdHr2ysuRWErTwhoN2X8XELRlrRwpmfeY2jjuUN4taQMsULKUVo1K4DvZl+0pgfyoysHxvmvEw==", - "peer": true - }, "node_modules/execa": { "version": "5.1.1", "resolved": "https://registry.npmjs.org/execa/-/execa-5.1.1.tgz", @@ -2726,6 +2208,7 @@ "version": "1.1.2", "resolved": "https://registry.npmjs.org/function-bind/-/function-bind-1.1.2.tgz", "integrity": "sha512-7XHNxH7qX9xG5mIwxkhumTox/MIRNcOgDrxWsMt2pAr23WHp6MrRlN7FBSFpCpr+oVO0F744iUgR82nJMfG2SA==", + "dev": true, "funding": { "url": "https://github.com/sponsors/ljharb" } @@ -2768,21 +2251,6 @@ "node": "6.* || 8.* || >= 10.*" } }, - "node_modules/get-intrinsic": { - "version": "1.2.2", - "resolved": "https://registry.npmjs.org/get-intrinsic/-/get-intrinsic-1.2.2.tgz", - "integrity": "sha512-0gSo4ml/0j98Y3lngkFEot/zhiCeWsbYIlZ+uZOVgzLyLaUw7wxUL+nCTP0XJvJg1AXulJRI3UJi8GsbDuxdGA==", - "peer": true, - "dependencies": { - "function-bind": "^1.1.2", - "has-proto": "^1.0.1", - "has-symbols": "^1.0.3", - "hasown": "^2.0.0" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, "node_modules/get-package-type": { "version": "0.1.0", "resolved": "https://registry.npmjs.org/get-package-type/-/get-package-type-0.1.0.tgz", @@ -2833,18 +2301,6 @@ "node": ">=4" } }, - "node_modules/gopd": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/gopd/-/gopd-1.0.1.tgz", - "integrity": "sha512-d65bNlIadxvpb/A2abVdlqKqV563juRnZ1Wtk6s1sIR8uNsXR70xqIzVqxVf1eTqDunwT2MkczEeaezCKTZhwA==", - "peer": true, - "dependencies": { - "get-intrinsic": "^1.1.3" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, "node_modules/graceful-fs": { "version": "4.2.11", "resolved": "https://registry.npmjs.org/graceful-fs/-/graceful-fs-4.2.11.tgz", @@ -2872,60 +2328,12 @@ "node": ">=8" } }, - "node_modules/has-property-descriptors": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/has-property-descriptors/-/has-property-descriptors-1.0.1.tgz", - "integrity": "sha512-VsX8eaIewvas0xnvinAe9bw4WfIeODpGYikiWYLH+dma0Jw6KHYqWiWfhQlgOVK8D6PvjubK5Uc4P0iIhIcNVg==", - "peer": true, - "dependencies": { - "get-intrinsic": "^1.2.2" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/has-proto": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/has-proto/-/has-proto-1.0.1.tgz", - "integrity": "sha512-7qE+iP+O+bgF9clE5+UoBFzE65mlBiVj3tKCrlNQ0Ogwm0BjpT/gK4SlLYDMybDh5I3TCTKnPPa0oMG7JDYrhg==", - "peer": true, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/has-symbols": { - "version": "1.0.3", - "resolved": "https://registry.npmjs.org/has-symbols/-/has-symbols-1.0.3.tgz", - "integrity": "sha512-l3LCuF6MgDNwTDKkdYGEihYjt5pRPbEg46rtlmnSPlUbgmB8LOIrKJbYYFBSbnPaJexMKtiPO8hmeRjRz2Td+A==", - "peer": true, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, "node_modules/has-unicode": { "version": "2.0.1", "resolved": "https://registry.npmjs.org/has-unicode/-/has-unicode-2.0.1.tgz", "integrity": "sha512-8Rf9Y83NBReMnx0gFzA8JImQACstCYWUplepDa9xprwwtmgEZUF0h/i5xSA625zB/I37EtrswSST6OXxwaaIJQ==", "dev": true }, - "node_modules/hasown": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/hasown/-/hasown-2.0.0.tgz", - "integrity": "sha512-vUptKVTpIJhcczKBbgnS+RtcuYMB8+oNzPK2/Hp3hanz8JmpATdmmgLgSaadVREkDm+e2giHwY3ZRkyjSIDDFA==", - "peer": true, - "dependencies": { - "function-bind": "^1.1.2" - }, - "engines": { - "node": ">= 0.4" - } - }, "node_modules/html-encoding-sniffer": { "version": "3.0.0", "resolved": "https://registry.npmjs.org/html-encoding-sniffer/-/html-encoding-sniffer-3.0.0.tgz", @@ -4304,15 +3712,6 @@ "node": ">=0.10.0" } }, - "node_modules/object-inspect": { - "version": "1.13.1", - "resolved": "https://registry.npmjs.org/object-inspect/-/object-inspect-1.13.1.tgz", - "integrity": "sha512-5qoj1RUiKOMsCCNLV1CBiPYE10sziTsnmNxkAI/rZhiD63CF7IqdFGC/XzjWjpSgLf0LxXX3bDFIh0E18f6UhQ==", - "peer": true, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, "node_modules/once": { "version": "1.4.0", "resolved": "https://registry.npmjs.org/once/-/once-1.4.0.tgz", @@ -4406,6 +3805,12 @@ "url": "https://github.com/sponsors/sindresorhus" } }, + "node_modules/parse-svg-path": { + "version": "0.1.2", + "resolved": "https://registry.npmjs.org/parse-svg-path/-/parse-svg-path-0.1.2.tgz", + "integrity": "sha512-JyPSBnkTJ0AI8GGJLfMXvKq42cj5c006fnLz6fXy6zfoVjJizi8BNTpu8on8ziI1cKy9d9DGNuY17Ce7wuejpQ==", + "peer": true + }, "node_modules/parse5": { "version": "7.1.2", "resolved": "https://registry.npmjs.org/parse5/-/parse5-7.1.2.tgz", @@ -4479,69 +3884,33 @@ } }, "node_modules/pixi.js": { - "version": "7.3.2", - "resolved": "https://registry.npmjs.org/pixi.js/-/pixi.js-7.3.2.tgz", - "integrity": "sha512-GJickUrT3UcBInGT1CU6cv2oktCdocE5QM74CD3t+weiJPPWIzleNlp7zrBR5QIDdU6bEO8CUgUXH2Y9QvlCMw==", + "version": "8.0.0", + "resolved": "https://registry.npmjs.org/pixi.js/-/pixi.js-8.0.0.tgz", + "integrity": "sha512-MX8cNEomyluT6EwVinMY+AKW37AKIDFi0DPWvQ59vU1P8jZpKy/tj+uyns8iyjK+F5wtc04AF/p9CH03iAO2lw==", "peer": true, "dependencies": { - "@pixi/accessibility": "7.3.2", - "@pixi/app": "7.3.2", - "@pixi/assets": "7.3.2", - "@pixi/compressed-textures": "7.3.2", - "@pixi/core": "7.3.2", - "@pixi/display": "7.3.2", - "@pixi/events": "7.3.2", - "@pixi/extensions": "7.3.2", - "@pixi/extract": "7.3.2", - "@pixi/filter-alpha": "7.3.2", - "@pixi/filter-blur": "7.3.2", - "@pixi/filter-color-matrix": "7.3.2", - "@pixi/filter-displacement": "7.3.2", - "@pixi/filter-fxaa": "7.3.2", - "@pixi/filter-noise": "7.3.2", - "@pixi/graphics": "7.3.2", - "@pixi/mesh": "7.3.2", - "@pixi/mesh-extras": "7.3.2", - "@pixi/mixin-cache-as-bitmap": "7.3.2", - "@pixi/mixin-get-child-by-name": "7.3.2", - "@pixi/mixin-get-global-position": "7.3.2", - "@pixi/particle-container": "7.3.2", - "@pixi/prepare": "7.3.2", - "@pixi/sprite": "7.3.2", - "@pixi/sprite-animated": "7.3.2", - "@pixi/sprite-tiling": "7.3.2", - "@pixi/spritesheet": "7.3.2", - "@pixi/text": "7.3.2", - "@pixi/text-bitmap": "7.3.2", - "@pixi/text-html": "7.3.2" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/pixijs" + "@pixi/colord": "^2.9.6", + "@types/css-font-loading-module": "^0.0.12", + "@types/earcut": "^2.1.4", + "@webgpu/types": "^0.1.40", + "@xmldom/xmldom": "^0.8.10", + "earcut": "^2.2.4", + "eventemitter3": "^5.0.1", + "ismobilejs": "^1.1.1", + "parse-svg-path": "^0.1.2" } }, - "node_modules/pixi.js-legacy": { - "version": "7.3.2", - "resolved": "https://registry.npmjs.org/pixi.js-legacy/-/pixi.js-legacy-7.3.2.tgz", - "integrity": "sha512-10nZf8jG0z7GJmg0cy53wWYzVDVCbMOMKTyhKm+NrWX8XmbIbsodYWAg1IdabnVbWKKg+zLX1dL+Wn6TakEeqw==", - "peer": true, - "dependencies": { - "@pixi/canvas-display": "7.3.2", - "@pixi/canvas-extract": "7.3.2", - "@pixi/canvas-graphics": "7.3.2", - "@pixi/canvas-mesh": "7.3.2", - "@pixi/canvas-particle-container": "7.3.2", - "@pixi/canvas-prepare": "7.3.2", - "@pixi/canvas-renderer": "7.3.2", - "@pixi/canvas-sprite": "7.3.2", - "@pixi/canvas-sprite-tiling": "7.3.2", - "@pixi/canvas-text": "7.3.2", - "pixi.js": "7.3.2" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/pixijs" - } + "node_modules/pixi.js/node_modules/@types/css-font-loading-module": { + "version": "0.0.12", + "resolved": "https://registry.npmjs.org/@types/css-font-loading-module/-/css-font-loading-module-0.0.12.tgz", + "integrity": "sha512-x2tZZYkSxXqWvTDgveSynfjq/T2HyiZHXb00j/+gy19yp70PHCizM48XFdjBCWH7eHBD0R5i/pw9yMBP/BH5uA==", + "peer": true + }, + "node_modules/pixi.js/node_modules/eventemitter3": { + "version": "5.0.1", + "resolved": "https://registry.npmjs.org/eventemitter3/-/eventemitter3-5.0.1.tgz", + "integrity": "sha512-GWkBvjiSZK87ELrYOSESUYeVIc9mvLLf/nXalMOS5dYrgZq9o5OVkbZAVM06CVxYsCwH9BDZFPlQTlPA1j4ahA==", + "peer": true }, "node_modules/pkg-dir": { "version": "4.2.0", @@ -4615,12 +3984,6 @@ "integrity": "sha512-E/ZsdU4HLs/68gYzgGTkMicWTLPdAftJLfJFlLUAAKZGkStNU72sZjT66SnMDVOfOWY/YAoiD7Jxa9iHvngcag==", "dev": true }, - "node_modules/punycode": { - "version": "1.4.1", - "resolved": "https://registry.npmjs.org/punycode/-/punycode-1.4.1.tgz", - "integrity": "sha512-jmYNElW7yvO7TV33CjSmvSiE2yco3bV2czu/OzDKdMNVZQWfxCblURLhf+47syQRBntjfLdd/H0egrzIG+oaFQ==", - "peer": true - }, "node_modules/pure-rand": { "version": "6.0.2", "resolved": "https://registry.npmjs.org/pure-rand/-/pure-rand-6.0.2.tgz", @@ -4637,21 +4000,6 @@ } ] }, - "node_modules/qs": { - "version": "6.11.2", - "resolved": "https://registry.npmjs.org/qs/-/qs-6.11.2.tgz", - "integrity": "sha512-tDNIz22aBzCDxLtVH++VnTfzxlfeK5CbqohpSqpJgj1Wg/cQbStNAz3NuqCs5vV+pjBsK4x4pN9HlVh7rcYRiA==", - "peer": true, - "dependencies": { - "side-channel": "^1.0.4" - }, - "engines": { - "node": ">=0.6" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, "node_modules/querystringify": { "version": "2.2.0", "resolved": "https://registry.npmjs.org/querystringify/-/querystringify-2.2.0.tgz", @@ -4808,21 +4156,6 @@ "integrity": "sha512-KiKBS8AnWGEyLzofFfmvKwpdPzqiy16LvQfK3yv/fVH7Bj13/wl3JSR1J+rfgRE9q7xUJK4qvgS8raSOeLUehw==", "dev": true }, - "node_modules/set-function-length": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/set-function-length/-/set-function-length-1.1.1.tgz", - "integrity": "sha512-VoaqjbBJKiWtg4yRcKBQ7g7wnGnLV3M8oLvVWwOk2PdYY6PEFegR1vezXR0tw6fZGF9csVakIRjrJiy2veSBFQ==", - "peer": true, - "dependencies": { - "define-data-property": "^1.1.1", - "get-intrinsic": "^1.2.1", - "gopd": "^1.0.1", - "has-property-descriptors": "^1.0.0" - }, - "engines": { - "node": ">= 0.4" - } - }, "node_modules/shebang-command": { "version": "2.0.0", "resolved": "https://registry.npmjs.org/shebang-command/-/shebang-command-2.0.0.tgz", @@ -4844,20 +4177,6 @@ "node": ">=8" } }, - "node_modules/side-channel": { - "version": "1.0.4", - "resolved": "https://registry.npmjs.org/side-channel/-/side-channel-1.0.4.tgz", - "integrity": "sha512-q5XPytqFEIKHkGdiMIrY10mvLRvnQh42/+GoBlFW3b2LXLE2xxJpZFdm94we0BaoV3RwJyGqg5wS7epxTv0Zvw==", - "peer": true, - "dependencies": { - "call-bind": "^1.0.0", - "get-intrinsic": "^1.0.2", - "object-inspect": "^1.9.0" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, "node_modules/signal-exit": { "version": "3.0.7", "resolved": "https://registry.npmjs.org/signal-exit/-/signal-exit-3.0.7.tgz", @@ -5341,16 +4660,6 @@ "browserslist": ">= 4.21.0" } }, - "node_modules/url": { - "version": "0.11.3", - "resolved": "https://registry.npmjs.org/url/-/url-0.11.3.tgz", - "integrity": "sha512-6hxOLGfZASQK/cijlZnZJTq8OXAkt/3YGfQX45vvMYXpZoo8NdWZcY73K108Jf759lS1Bv/8wXnHDTSz17dSRw==", - "peer": true, - "dependencies": { - "punycode": "^1.4.1", - "qs": "^6.11.2" - } - }, "node_modules/url-parse": { "version": "1.5.10", "resolved": "https://registry.npmjs.org/url-parse/-/url-parse-1.5.10.tgz", diff --git a/package.json b/package.json index 1603578..489085c 100644 --- a/package.json +++ b/package.json @@ -26,7 +26,7 @@ "typescript": "^5.1.6" }, "peerDependencies": { - "pixi.js-legacy": "^7.3.2" + "pixi.js": "8.0.0" }, "files": [ "out" diff --git a/src/Grid.ts b/src/Grid.ts index 36ebbdc..123575c 100644 --- a/src/Grid.ts +++ b/src/Grid.ts @@ -1,14 +1,14 @@ -import { Container, DisplayObject, Rectangle } from "pixi.js-legacy"; +import { Container, Rectangle } from "pixi.js"; import Partitioner from "./Partitioner"; -export function Grid(...objects: DisplayObject[]): GridComponent { +export function Grid(...objects: Container[]): GridComponent { return new GridComponent(...objects); } export class GridComponent extends Partitioner { _centerLastRow: boolean = false; - constructor(...children: DisplayObject[]) { + constructor(...children: Container[]) { super(...children); } @@ -26,7 +26,7 @@ export class GridComponent extends Partitioner { return 1; } - *partition(objects: DisplayObject[], space: Rectangle): Generator { + *partition(objects: Container[], space: Rectangle): Generator { let containers = objects as Container[]; let factors = []; diff --git a/src/Leaf.ts b/src/Leaf.ts index 5f67947..8860167 100644 --- a/src/Leaf.ts +++ b/src/Leaf.ts @@ -1,4 +1,4 @@ -import { Rectangle, Container } from "pixi.js-legacy"; +import { Rectangle, Container } from "pixi.js"; import Positioner from "./Positioner"; import { getDimension } from "./utils"; diff --git a/src/Partitioner.ts b/src/Partitioner.ts index 184cfb6..e70009e 100644 --- a/src/Partitioner.ts +++ b/src/Partitioner.ts @@ -1,4 +1,4 @@ -import { Container, DisplayObject, Graphics, Rectangle } from "pixi.js-legacy"; +import { Container, Graphics, Rectangle } from "pixi.js"; import Positioner from "./Positioner"; import { Leaf, LeafComponent } from "./Leaf"; @@ -7,10 +7,10 @@ export default abstract class Partitioner implements Positioner { protected _debug: boolean = false; - protected _group: DisplayObject[]; + protected _group: Container[]; protected _space: Rectangle | null = null; - constructor(...children: DisplayObject[]) { + constructor(...children: Container[]) { super(); this._group = children; this.sortableChildren = true; @@ -41,11 +41,11 @@ export default abstract class Partitioner } abstract partition( - objects: DisplayObject[], + objects: Container[], space: Rectangle, ): IterableIterator; - override addChild(...children: U): U[0] { + override addChild(...children: U): U[0] { if (children.length === 0) { throw new Error("Cannot add zero children"); } @@ -58,13 +58,13 @@ export default abstract class Partitioner return firstChild; } - override addChildAt(child: U, index: number): U { + override addChildAt = (child: U, index: number): U => { this._group.splice(index, 0, child); this.refresh(); return child; - } + }; - override removeChild(...children: U): U[0] { + override removeChild(...children: U): U[0] { if (children.length === 0) { throw new Error("Cannot remove zero children"); } @@ -80,7 +80,7 @@ export default abstract class Partitioner return firstChild; } - override removeChildAt(index: number): DisplayObject { + override removeChildAt = (index: number): U => { if (index < 0 || index >= this._group.length) { throw new Error("Index out of bounds"); } @@ -88,20 +88,21 @@ export default abstract class Partitioner let child = this._group[index]!; this._group.splice(index, 1); this.refresh(); + // @ts-ignore return child; - } + }; - override removeChildren( + override removeChildren = ( beginIndex?: number | undefined, endIndex?: number | undefined, - ): DisplayObject[] { + ): Container[] => { let children = this._group.splice( beginIndex ?? 0, endIndex ?? this._group.length, ); this.refresh(); return children; - } + }; refresh(): void { if (this._space) { diff --git a/src/Positioner.ts b/src/Positioner.ts index 1431192..f048eb4 100644 --- a/src/Positioner.ts +++ b/src/Positioner.ts @@ -1,4 +1,4 @@ -import { Rectangle } from "pixi.js-legacy"; +import { Rectangle } from "pixi.js"; export default interface Positioner { arrange(screen: Rectangle): void; diff --git a/src/Stack.ts b/src/Stack.ts index 330de6a..c6fa435 100644 --- a/src/Stack.ts +++ b/src/Stack.ts @@ -1,4 +1,4 @@ -import { DisplayObject, Rectangle } from "pixi.js-legacy"; +import { Container, Rectangle } from "pixi.js"; import Partitioner from "./Partitioner"; enum Direction { @@ -7,15 +7,15 @@ enum Direction { Auto, } -export function Stack(...objects: DisplayObject[]): StackComponent { +export function Stack(...objects: Container[]): StackComponent { return new StackComponent(...objects); } -export function HStack(...objects: DisplayObject[]): StackComponent { +export function HStack(...objects: Container[]): StackComponent { return new StackComponent(...objects).horizontal(); } -export function VStack(...objects: DisplayObject[]): StackComponent { +export function VStack(...objects: Container[]): StackComponent { return new StackComponent(...objects).vertical(); } @@ -24,7 +24,7 @@ export class StackComponent extends Partitioner { private _proportions: number[]; private _direction: Direction = Direction.Auto; - constructor(...children: DisplayObject[]) { + constructor(...children: Container[]) { super(...children); this._proportions = children.map(() => 1 / children.length); } @@ -56,7 +56,7 @@ export class StackComponent extends Partitioner { } *horizontalPartition( - objects: DisplayObject[], + objects: Container[], space: Rectangle, ): Generator { let i = 0; @@ -72,7 +72,7 @@ export class StackComponent extends Partitioner { } *verticalPartition( - objects: DisplayObject[], + objects: Container[], space: Rectangle, ): Generator { let i = 0; @@ -87,7 +87,7 @@ export class StackComponent extends Partitioner { } } - *partition(objects: DisplayObject[], space: Rectangle): Generator { + *partition(objects: Container[], space: Rectangle): Generator { let direction = this._direction; if (direction === Direction.Auto) { direction = diff --git a/test-utils.ts b/test-utils.ts index 59109d4..6779966 100644 --- a/test-utils.ts +++ b/test-utils.ts @@ -1,5 +1,5 @@ import { expect } from "@jest/globals"; -import * as PIXI from "pixi.js-legacy"; +import { Application, Renderer, Graphics, Container } from "pixi.js"; import fs from "fs"; import Positioner from "./src/Positioner"; @@ -11,8 +11,8 @@ export function circle({ x?: number; y?: number; radius?: number; -} = {}): PIXI.Graphics { - let circle = new PIXI.Graphics(); +} = {}): Graphics { + let circle = new Graphics(); circle.beginFill(0xff0000); circle.drawCircle(x ?? 0, y ?? 0, radius ?? 50); circle.endFill(); @@ -31,14 +31,14 @@ export function rect({ width?: number; height?: number; center?: boolean; -} = {}): PIXI.Graphics { +} = {}): Graphics { x = x ?? 0; y = y ?? 0; width = width ?? 50; height = height ?? 50; center = center ?? false; - let rect = new PIXI.Graphics(); + let rect = new Graphics(); if (center) { rect.pivot.x = width / 2; @@ -50,15 +50,15 @@ export function rect({ return rect; } -function innerTest(name: string, cb: (app: PIXI.Application) => void) { +async function innerTest(name: string, cb: (app: Application) => void) { let canvas = document.createElement("canvas"); canvas.width = 800; canvas.height = 600; document.body.appendChild(canvas); - let app = new PIXI.Application({ + let app = new Application>(); + await app.init({ autoStart: false, - forceCanvas: true, view: canvas, resizeTo: canvas, backgroundColor: 0xffffff, @@ -92,17 +92,17 @@ function innerTest(name: string, cb: (app: PIXI.Application) => void) { document.body.removeChild(canvas); } -export function appTest(name: string, cb: (app: PIXI.Application) => void) { - it(name, () => innerTest(name, cb)); +export function appTest(name: string, cb: (app: Application) => void) { + it(name, async () => await innerTest(name, cb)); } -appTest.only = (name: string, cb: (app: PIXI.Application) => void) => { - it.only(name, () => innerTest(name, cb)); +appTest.only = (name: string, cb: (app: Application) => void) => { + it.only(name, async () => await innerTest(name, cb)); }; export async function componentTest( name: string, - cb: (app: PIXI.Application) => Positioner & PIXI.DisplayObject, + cb: (app: Application) => Positioner & Container, ) { appTest(name, (app) => { let layout = cb(app); @@ -113,7 +113,7 @@ export async function componentTest( componentTest.only = ( name: string, - cb: (app: PIXI.Application) => Positioner & PIXI.DisplayObject, + cb: (app: Application) => Positioner & Container, ) => { appTest.only(name, (app) => { let layout = cb(app); diff --git a/tests.ts b/tests.ts index e78569a..7d2ed99 100644 --- a/tests.ts +++ b/tests.ts @@ -1,4 +1,4 @@ -import { Container } from "pixi.js-legacy"; +import { Container } from "pixi.js"; import { Grid, HStack, Stack, VStack } from "./src"; import { componentTest, circle, appTest, rect } from "./test-utils";