pomium 1.0.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/README.md +96 -0
- package/assets/atlases.json +38 -0
- package/assets/desktop/char_01_desktop.json +783 -0
- package/assets/desktop/char_01_desktop.webp +0 -0
- package/assets/desktop/char_02_desktop.json +783 -0
- package/assets/desktop/char_02_desktop.webp +0 -0
- package/assets/desktop/char_03_desktop.json +783 -0
- package/assets/desktop/char_03_desktop.webp +0 -0
- package/assets/desktop/char_04_desktop.json +783 -0
- package/assets/desktop/char_04_desktop.webp +0 -0
- package/assets/desktop/char_05_desktop.json +783 -0
- package/assets/desktop/char_05_desktop.webp +0 -0
- package/assets/desktop/char_06_desktop.json +783 -0
- package/assets/desktop/char_06_desktop.webp +0 -0
- package/assets/desktop/char_07_desktop.json +783 -0
- package/assets/desktop/char_07_desktop.webp +0 -0
- package/assets/desktop/char_08_desktop.json +783 -0
- package/assets/desktop/char_08_desktop.webp +0 -0
- package/assets/desktop/char_09_desktop.json +783 -0
- package/assets/desktop/char_09_desktop.webp +0 -0
- package/assets/desktop/char_10_desktop.json +783 -0
- package/assets/desktop/char_10_desktop.webp +0 -0
- package/assets/desktop/shockwave_desktop.json +151 -0
- package/assets/desktop/shockwave_desktop.webp +0 -0
- package/assets/mobile/char_01_mobile.json +783 -0
- package/assets/mobile/char_01_mobile.webp +0 -0
- package/assets/mobile/char_02_mobile.json +783 -0
- package/assets/mobile/char_02_mobile.webp +0 -0
- package/assets/mobile/char_03_mobile.json +783 -0
- package/assets/mobile/char_03_mobile.webp +0 -0
- package/assets/mobile/char_04_mobile.json +783 -0
- package/assets/mobile/char_04_mobile.webp +0 -0
- package/assets/mobile/char_05_mobile.json +783 -0
- package/assets/mobile/char_05_mobile.webp +0 -0
- package/assets/mobile/char_06_mobile.json +783 -0
- package/assets/mobile/char_06_mobile.webp +0 -0
- package/assets/mobile/char_07_mobile.json +783 -0
- package/assets/mobile/char_07_mobile.webp +0 -0
- package/assets/mobile/char_08_mobile.json +783 -0
- package/assets/mobile/char_08_mobile.webp +0 -0
- package/assets/mobile/char_09_mobile.json +783 -0
- package/assets/mobile/char_09_mobile.webp +0 -0
- package/assets/mobile/char_10_mobile.json +783 -0
- package/assets/mobile/char_10_mobile.webp +0 -0
- package/assets/mobile/shockwave_mobile.json +151 -0
- package/assets/mobile/shockwave_mobile.webp +0 -0
- package/bin/pomium.js +20 -0
- package/package.json +32 -0
- package/src/main.js +114 -0
- package/src/pom/atlas-loader.js +21 -0
- package/src/pom/atlas.js +83 -0
- package/src/pom/config.js +41 -0
- package/src/pom/coords.js +10 -0
- package/src/pom/engine.js +103 -0
- package/src/pom/geometry.js +43 -0
- package/src/pom/index.js +173 -0
- package/src/pom/loop.js +68 -0
- package/src/pom/overlay.js +42 -0
- package/src/pom/package.json +1 -0
- package/src/pom/render.js +32 -0
- package/src/pom/sprites.js +66 -0
- package/src/renderer/index.html +25 -0
- package/src/renderer/renderer.js +197 -0
- package/src/renderer/styles.css +148 -0
- package/src/webview-preload.js +68 -0
package/README.md
ADDED
|
@@ -0,0 +1,96 @@
|
|
|
1
|
+
# Pomium
|
|
2
|
+
|
|
3
|
+
A Chromium-based desktop browser (built on Electron) where every click
|
|
4
|
+
spawns a pair of Pomeranians.
|
|
5
|
+
|
|
6
|
+
Click anywhere — a page, the tab strip, the address bar — and a pair of
|
|
7
|
+
photoreal Poms sweeps across the window behind a fire shockwave. Hold and
|
|
8
|
+
drag to stream them continuously. The OS window itself jolts on every
|
|
9
|
+
spawn and settles back to rest once the animation ends, and it keeps
|
|
10
|
+
jolting for as long as a drag-stream is running.
|
|
11
|
+
|
|
12
|
+

|
|
13
|
+
|
|
14
|
+
## Install
|
|
15
|
+
|
|
16
|
+
Just want to use Pomium? Download it from the [latest release](https://github.com/DigasNikas/pomium/releases) and follow [`docs/install.md`](docs/install.md). Both installers are unsigned, and that guide walks through the warning your OS will show and exactly what to click past it.
|
|
17
|
+
|
|
18
|
+
Already have Node? `npm install -g pomium` skips both installers and their first-run warnings, at the cost of pulling the full Electron runtime through npm instead. Same guide covers it.
|
|
19
|
+
|
|
20
|
+
The instructions below are for running Pomium from source, which is what you want if you're developing it, not installing it.
|
|
21
|
+
|
|
22
|
+
## Run
|
|
23
|
+
|
|
24
|
+
```sh
|
|
25
|
+
npm install
|
|
26
|
+
npm start
|
|
27
|
+
```
|
|
28
|
+
|
|
29
|
+
## How it works
|
|
30
|
+
|
|
31
|
+
- `src/main.js` — Electron main process. Opens the browser window and
|
|
32
|
+
handles `pom-shake` IPC messages by moving the OS window (`setBounds`)
|
|
33
|
+
on every spawn, remembering its resting position so it settles back
|
|
34
|
+
correctly rather than drifting.
|
|
35
|
+
- `src/renderer/` — the browser chrome: tab strip, address bar, nav
|
|
36
|
+
buttons, a `<webview>` per tab, and the wiring that forwards pointer
|
|
37
|
+
events (from the chrome itself and from pages) into the pom engine and
|
|
38
|
+
the shake IPC.
|
|
39
|
+
- `src/webview-preload.js` — injected into every page loaded in a
|
|
40
|
+
`<webview>`; forwards press, move and release events from the page to
|
|
41
|
+
the host chrome, since a webview is a separate frame the host can't see
|
|
42
|
+
into directly.
|
|
43
|
+
- `src/pom/` — the animation engine, ported with no browser-specific
|
|
44
|
+
dependencies: `config.js`, `geometry.js`, `sprites.js`, `engine.js`,
|
|
45
|
+
`atlas.js`, `atlas-loader.js`, `loop.js`, `render.js`, `overlay.js`,
|
|
46
|
+
`coords.js`, and `index.js` tying them together. The overlay is a single
|
|
47
|
+
canvas spanning the whole window, painted above the browser chrome, with
|
|
48
|
+
`pointer-events: none` so every click still reaches whatever it landed
|
|
49
|
+
on underneath. The canvas keeps the rotation component of the camera
|
|
50
|
+
shake, since the OS window can't rotate — position goes to the window,
|
|
51
|
+
rotation stays on the canvas.
|
|
52
|
+
|
|
53
|
+
## Artwork
|
|
54
|
+
|
|
55
|
+
The Pomeranian and shockwave spritesheets live in `assets/` as 44
|
|
56
|
+
committed atlas files (JSON + WebP pairs across desktop and mobile tiers,
|
|
57
|
+
only the desktop tier is used) plus the `atlases.json` manifest that names
|
|
58
|
+
them. They're vendored from screen.toys, art by shapiro500
|
|
59
|
+
(https://www.instagram.com/shapiro500/), and carry no posted licence.
|
|
60
|
+
Because they're committed, a fresh clone runs with no fetch step.
|
|
61
|
+
`scripts/fetch-assets.sh` isn't needed for that — it exists as the
|
|
62
|
+
provenance record for where the files came from, and to re-fetch or
|
|
63
|
+
update them from screen.toys if they ever change.
|
|
64
|
+
|
|
65
|
+
## Tests
|
|
66
|
+
|
|
67
|
+
```sh
|
|
68
|
+
npm test
|
|
69
|
+
```
|
|
70
|
+
|
|
71
|
+
Runs 68 tests via `node --test`, no dependencies beyond Node itself. They
|
|
72
|
+
cover the engine's maths (velocity, jitter, depth), sprite lifecycle,
|
|
73
|
+
atlas parsing, cache eviction, render-argument construction, and
|
|
74
|
+
coordinate translation — everything in `src/pom/` that doesn't need a
|
|
75
|
+
real window to exercise.
|
|
76
|
+
|
|
77
|
+
They do not cover DOM assembly, file I/O for loading atlases off disk, the
|
|
78
|
+
IPC plumbing between webview, host chrome, and main process, or the
|
|
79
|
+
window-shake handler in `src/main.js`. See `docs/manual-verification.md`
|
|
80
|
+
for the checklist that covers those, and for what to expect from each
|
|
81
|
+
item — that checklist has not been run against this build; it's a
|
|
82
|
+
handover for whoever tests it next.
|
|
83
|
+
|
|
84
|
+
## Known limitations
|
|
85
|
+
|
|
86
|
+
- The window does not shake while maximised or fullscreen — `setBounds`
|
|
87
|
+
fights the OS window manager in that state, so shaking is skipped
|
|
88
|
+
outright rather than fighting it.
|
|
89
|
+
- While a drag-stream is running, the window shakes continuously, which
|
|
90
|
+
makes drag-to-select on a page impractical for the duration. This is a
|
|
91
|
+
side effect of shaking on every spawn, not a bug.
|
|
92
|
+
- Single window, no bookmarks/history/downloads UI.
|
|
93
|
+
- The installers are unsigned, so every recipient has to click through a
|
|
94
|
+
first-run OS warning — see `docs/install.md` for exactly what to click.
|
|
95
|
+
- No auto-update — a new version means downloading and running the
|
|
96
|
+
installer again, or `npm install -g pomium` again for the npm path.
|
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
{
|
|
2
|
+
"source": "https://screen.toys/poms/",
|
|
3
|
+
"note": "Art by shapiro500 (https://www.instagram.com/shapiro500/), no posted licence. Committed to this repo; scripts/fetch-assets.sh re-fetches them from screen.toys. Requires the author's permission, or replacement with original or licensed frames, before any store submission.",
|
|
4
|
+
"tiers": {
|
|
5
|
+
"desktop": {
|
|
6
|
+
"suffix": "desktop",
|
|
7
|
+
"characters": [
|
|
8
|
+
"char_01",
|
|
9
|
+
"char_02",
|
|
10
|
+
"char_03",
|
|
11
|
+
"char_04",
|
|
12
|
+
"char_05",
|
|
13
|
+
"char_06",
|
|
14
|
+
"char_07",
|
|
15
|
+
"char_08",
|
|
16
|
+
"char_09",
|
|
17
|
+
"char_10"
|
|
18
|
+
],
|
|
19
|
+
"shockwave": "shockwave"
|
|
20
|
+
},
|
|
21
|
+
"mobile": {
|
|
22
|
+
"suffix": "mobile",
|
|
23
|
+
"characters": [
|
|
24
|
+
"char_01",
|
|
25
|
+
"char_02",
|
|
26
|
+
"char_03",
|
|
27
|
+
"char_04",
|
|
28
|
+
"char_05",
|
|
29
|
+
"char_06",
|
|
30
|
+
"char_07",
|
|
31
|
+
"char_08",
|
|
32
|
+
"char_09",
|
|
33
|
+
"char_10"
|
|
34
|
+
],
|
|
35
|
+
"shockwave": "shockwave"
|
|
36
|
+
}
|
|
37
|
+
}
|
|
38
|
+
}
|