three-gamepad-controls 0.12.0 → 0.12.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.
Files changed (2) hide show
  1. package/README.md +21 -16
  2. package/package.json +1 -1
package/README.md CHANGED
@@ -4,48 +4,53 @@ Gamepad support for [Three.js](https://threejs.org) controls, built on top of [W
4
4
 
5
5
  ## Architecture
6
6
 
7
- ```mermaid
8
- flowchart TD
9
- GamepadManager["GamepadManager<br/>(internal polling and active device lifecycle)"]
10
- GamepadInput["GamepadInput<br/>(public low-level input state)"]
11
- GamepadControls["GamepadControls<br/>(abstract Three.js wrapper base)"]
12
- Wrappers["Specific wrappers<br/>(Orbit, Map, Fly, Transform, etc.)"]
13
-
14
- GamepadManager --> GamepadInput
15
- GamepadInput --> GamepadControls
16
- GamepadControls --> Wrappers
17
- ```
7
+ <p align="center">
8
+ <img src="./assets/architecture-diagram.webp" width="800" alt="Architecture diagram" />
9
+ </p>
18
10
 
19
11
  ## 📦 Installation
20
12
 
21
13
  npm:
22
14
 
23
15
  ```bash
24
- npm i three-gamepad-controls
16
+ npm i three three-gamepad-controls
17
+ npm i -D @types/three # optional: for TypeScript projects
25
18
  ```
26
19
 
27
20
  pnpm:
28
21
 
29
22
  ```bash
30
- pnpm add three-gamepad-controls
23
+ pnpm add three three-gamepad-controls
24
+ pnpm add -D @types/three # optional: for TypeScript projects
31
25
  ```
32
26
 
33
27
  Yarn:
34
28
 
35
29
  ```bash
36
- yarn add three-gamepad-controls
30
+ yarn add three three-gamepad-controls
31
+ yarn add -D @types/three # optional: for TypeScript projects
37
32
  ```
38
33
 
39
34
  Deno:
40
35
 
36
+ When using `deno.json`, Deno stores dependencies in `imports` and does not separate `devDependencies`; `-D` only applies when writing to `package.json`.
37
+
38
+ ```bash
39
+ # deno.json
40
+ deno add three @types/three three-gamepad-controls
41
+ ```
42
+
41
43
  ```bash
42
- deno add npm:three-gamepad-controls
44
+ # package.json
45
+ deno add --package-json three three-gamepad-controls
46
+ deno add --package-json -D @types/three # optional: for TypeScript projects
43
47
  ```
44
48
 
45
49
  Bun:
46
50
 
47
51
  ```bash
48
- bun add three-gamepad-controls
52
+ bun add three three-gamepad-controls
53
+ bun add -d @types/three # optional: for TypeScript projects
49
54
  ```
50
55
 
51
56
  ## 📖 Documentation
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "three-gamepad-controls",
3
3
  "description": "Gamepad support for Three.js controls.",
4
- "version": "0.12.0",
4
+ "version": "0.12.1",
5
5
  "homepage": "https://github.com/luckasnix/three-gamepad-controls#readme",
6
6
  "author": {
7
7
  "name": "Kasnix",