@open-slot-ui/pixi 0.0.1
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/LICENSE +34 -0
- package/README.md +49 -0
- package/dist/index.cjs +3982 -0
- package/dist/index.cjs.map +1 -0
- package/dist/index.d.cts +933 -0
- package/dist/index.d.ts +933 -0
- package/dist/index.js +3954 -0
- package/dist/index.js.map +1 -0
- package/package.json +68 -0
package/LICENSE
ADDED
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
MIT License
|
|
2
|
+
|
|
3
|
+
Copyright (c) 2026 schmooky and the open-ui contributors
|
|
4
|
+
|
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
|
+
of this software and associated documentation files (the "Software"), to deal
|
|
7
|
+
in the Software without restriction, including without limitation the rights
|
|
8
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
9
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
10
|
+
furnished to do so, subject to the following conditions:
|
|
11
|
+
|
|
12
|
+
The above copyright notice and this permission notice shall be included in all
|
|
13
|
+
copies or substantial portions of the Software.
|
|
14
|
+
|
|
15
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
17
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
18
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
21
|
+
SOFTWARE.
|
|
22
|
+
|
|
23
|
+
---
|
|
24
|
+
|
|
25
|
+
## Bundled software
|
|
26
|
+
|
|
27
|
+
This package's distributed bundle includes the following third-party software:
|
|
28
|
+
|
|
29
|
+
### pixi-text-counter
|
|
30
|
+
|
|
31
|
+
The mechanical-reel value counter is compiled into this package's `dist`.
|
|
32
|
+
|
|
33
|
+
MIT License — Copyright (c) schmooky
|
|
34
|
+
https://github.com/schmooky/pixi-text-counter
|
package/README.md
ADDED
|
@@ -0,0 +1,49 @@
|
|
|
1
|
+
# @open-slot-ui/pixi
|
|
2
|
+
|
|
3
|
+
The **PixiJS v8 renderer** for [open-ui](https://github.com/schmooky/open-ui) — a biased,
|
|
4
|
+
themeable UI library for slot games. Mount a complete, responsive, themeable HUD onto your
|
|
5
|
+
existing Pixi scene in **one call**, then drive its look and behavior with plain, typed,
|
|
6
|
+
string-literal options.
|
|
7
|
+
|
|
8
|
+
```bash
|
|
9
|
+
pnpm add @open-slot-ui/core @open-slot-ui/pixi pixi.js
|
|
10
|
+
```
|
|
11
|
+
|
|
12
|
+
> `pixi.js@^8` is a **peer dependency** — `@open-slot-ui/pixi` binds to *your* single Pixi
|
|
13
|
+
> instance, it never bundles its own.
|
|
14
|
+
|
|
15
|
+
## Usage
|
|
16
|
+
|
|
17
|
+
```ts
|
|
18
|
+
import { mountHud } from '@open-slot-ui/pixi';
|
|
19
|
+
|
|
20
|
+
const hud = mountHud(app, {
|
|
21
|
+
theme: 'neon', // 'default' | 'midnight' | 'neon' | 'light'
|
|
22
|
+
turbo: { modes: 3 }, // 2-mode toggle or 3-mode switcher
|
|
23
|
+
autoplay: { mode: 'options' }, // 'options' drawer, or 'infinite'
|
|
24
|
+
spin: { press: 'hold-to-spin' }, // 'tap', or hold-to-turbo-spin
|
|
25
|
+
});
|
|
26
|
+
|
|
27
|
+
hud.on('spinRequested', () => game.spin()); // events out
|
|
28
|
+
hud.ui.spin.busy(); // commands in
|
|
29
|
+
hud.setBalance(1234);
|
|
30
|
+
```
|
|
31
|
+
|
|
32
|
+
That's the whole integration. The HUD owns its layout, theming, animation, responsive
|
|
33
|
+
reflow and teardown — you own the game. The model, state machines, theme tokens and layout
|
|
34
|
+
all live in the zero-dependency [`@open-slot-ui/core`](https://www.npmjs.com/package/@open-slot-ui/core);
|
|
35
|
+
this package is the thin view + controller binding that mounts a single `Container`.
|
|
36
|
+
|
|
37
|
+
See the [main README](https://github.com/schmooky/open-ui#readme) for the full configuration
|
|
38
|
+
surface and the [Charter](https://github.com/schmooky/open-ui/blob/main/CHARTER.md) for the
|
|
39
|
+
doctrine.
|
|
40
|
+
|
|
41
|
+
## Bundled software
|
|
42
|
+
|
|
43
|
+
The mechanical-reel value counter ([`pixi-text-counter`](https://github.com/schmooky/pixi-text-counter),
|
|
44
|
+
MIT © schmooky) is compiled into this package's `dist`, so there is no extra runtime
|
|
45
|
+
dependency to install. See [LICENSE](./LICENSE) for the attribution notice.
|
|
46
|
+
|
|
47
|
+
## License
|
|
48
|
+
|
|
49
|
+
[MIT](./LICENSE) © schmooky and the open-ui contributors.
|