Popper & Butter
A toaster who launches his best friend into the sky. One tag brings both of them.
Popper & Butter
<!-- once, anywhere on the page --> <script src="https://cdn.jsdelivr.net/npm/piixpal@0.4/piixpal.min.js"></script> <h2> … <piix-pal pal="popper"></piix-pal> </h2>
<!-- just popper (the shared engine loads itself, once) --> <script src="https://cdn.jsdelivr.net/npm/piixpal@0.4/dist/c/popper.min.js"></script> <h2> … <piix-pal pal="popper"></piix-pal> </h2>
<!-- attaches itself to the first h2: nothing else to add --> <script src="https://cdn.jsdelivr.net/npm/piixpal@0.4/dist/c/popper.min.js" data-pals="popper@h2"></script>
await import("https://cdn.jsdelivr.net/npm/piixpal@0.4/dist/c/popper.min.js");
Piixpal.add("popper", "h2");
// npm install piixpal
import { PiixPal } from "piixpal/react";
<h1>
Hello
<PiixPal pal="popper" />
</h1>
npx shadcn@latest add https://piixpal.dvkk.dev/r/popper.json
import { Popper } from "@/components/piixpal/popper";
<h1>
Hello
<Popper />
</h1>
// main.js: app.use(Piixpal) from "piixpal/vue" <h1> Hello <piix-pal pal="popper" /> </h1>
<script>import Piixpal from "piixpal/svelte";</script> <Piixpal /> <h1>Hello <piix-pal pal="popper"></piix-pal></h1>
Options
at- where Popper stands, 0–1
poke Popper- pops her out now
poke Butter- hearts
How it plays
- Butter waits in the slot while Popper hums.
- Pop: she flies up, spinning.
- At the top a parachute opens and she drifts down, swaying.
- She lands, walks back and hops in. Again.
It loops with a little randomness, never blocks a click, and stands still for people who prefer less motion. Put the tag inside the element they should live on, or point at one with on="selector".