Pals

Characters that live on your page. Put one inside an element and it does the rest.

Characters 18

Bitbug

pal="bitbug"

A lime beetle that crawls along the real outline of your letters.

Hello, world.
<!-- once, anywhere on the page -->
<script src="https://cdn.jsdelivr.net/npm/piixpal@0.4/piixpal.min.js"></script>

<h1>
  Hello, world.
  <piix-pal pal="bitbug"></piix-pal>
</h1>
Options
speed
walking speed multiplier
edge
"text" (glyph outline) or "box" (top edge)
at
starting spot, 0–1
poke it
flips onto its back, legs flailing

Boing

pal="boing"

A jelly drop that bounces on your footer and lands with a splat.

<!-- once, anywhere on the page -->
<script src="https://cdn.jsdelivr.net/npm/piixpal@0.4/piixpal.min.js"></script>

<footer>
  …
  <piix-pal pal="boing"></piix-pal>
</footer>
Options
energy
jump height multiplier
at
starting spot, 0–1
poke it
does a big spinning jump. Drag and throw it, too

Moss

pal="moss"

A mushroom that sits on your text reading its book, ignoring you (mostly).

Some light reading for a slow afternoon.

<!-- once, anywhere on the page -->
<script src="https://cdn.jsdelivr.net/npm/piixpal@0.4/piixpal.min.js"></script>

<p>
  Some light reading.
  <piix-pal pal="moss"></piix-pal>
</p>
Options
at
where it sits, 0–1 (default .85)
edge
"text" or "box"
poke it
turns its back on you. Three pokes and it moves

Lurk

pal="lurk"

A shy creature that peeks over the edge of your cards.

<!-- once, anywhere on the page -->
<script src="https://cdn.jsdelivr.net/npm/piixpal@0.4/piixpal.min.js"></script>

<div class="card">
  …
  <piix-pal pal="lurk"></piix-pal>
</div>
Options
at
where along the edge it first appears, 0–1
poke it
"eep!" It ducks and pops up somewhere else

Thread

pal="thread"

A spider that dangles from your nav on a long thread.

<!-- once, anywhere on the page -->
<script src="https://cdn.jsdelivr.net/npm/piixpal@0.4/piixpal.min.js"></script>

<nav>
  …
  <piix-pal pal="thread" length="90"></piix-pal>
</nav>
Options
length
thread length in px (default 70)
at
where along the edge, 0–1
silk
thread colour
poke it
yo-yos on its thread

Pip

pal="pip"

A round bird that hops between your buttons and perches on them.

<!-- once, anywhere on the page -->
<script src="https://cdn.jsdelivr.net/npm/piixpal@0.4/piixpal.min.js"></script>

<a class="btn">Sign up</a>
<a class="btn">Log in</a>
<piix-pal pal="pip" on=".btn"></piix-pal>
Options
on
selector for perches, e.g. ".btn"
poke it
takes off

Bumble

pal="bumble"

A fuzzy bee that buzzes about your element.

hive
<!-- once, anywhere on the page -->
<script src="https://cdn.jsdelivr.net/npm/piixpal@0.4/piixpal.min.js"></script>

<div class="hive">
  <piix-pal pal="bumble"></piix-pal>
</div>
Options
at
where it naps, 0–1
poke it
does a loop-the-loop

Shel

pal="shel"

A snail that creeps along your text, leaving a shiny trail.

Slow and steady.

<!-- once, anywhere on the page -->
<script src="https://cdn.jsdelivr.net/npm/piixpal@0.4/piixpal.min.js"></script>

<h2>
  Slow and steady.
  <piix-pal pal="shel"></piix-pal>
</h2>
Options
speed
creeping speed multiplier
edge
"text" or "box"
poke it
hides in its shell, then peeks out

Gecko

pal="gecko"

A gecko that climbs up and around the sides of your cards.

<!-- once, anywhere on the page -->
<script src="https://cdn.jsdelivr.net/npm/piixpal@0.4/piixpal.min.js"></script>

<div class="card">
  …
  <piix-pal pal="gecko"></piix-pal>
</div>
Options
speed
walking speed multiplier
at
starting point around the border, 0–1
poke it
sprints the other way round

Mole

pal="mole"

Whack-a-mole: it pops out of your element, you bop it.

<!-- once, anywhere on the page -->
<script src="https://cdn.jsdelivr.net/npm/piixpal@0.4/piixpal.min.js"></script>

<section>
  …
  <piix-pal pal="mole"></piix-pal>
</section>
Options
piix:bonk
event with detail.count, for keeping score
poke it
bonk! Stars, then back underground. Fires piix:bonk with a count

Balloon

pal="balloon"

A balloon with a face, tied to your element, bobbing in the breeze.

<!-- once, anywhere on the page -->
<script src="https://cdn.jsdelivr.net/npm/piixpal@0.4/piixpal.min.js"></script>

<div class="cta">
  …
  <piix-pal pal="balloon"></piix-pal>
</div>
Options
length
string length in px
at
where it is tied, 0–1
silk
string colour
poke it
pops (and thuds), then slowly re-inflates

Para

pal="para"

A parachutist who drops onto your section when it scrolls into view.

Landing zone

<!-- once, anywhere on the page -->
<script src="https://cdn.jsdelivr.net/npm/piixpal@0.4/piixpal.min.js"></script>

<h2>
  Landing zone
  <piix-pal pal="para"></piix-pal>
</h2>
Options
at
landing spot, 0–1
poke it
goes back up for another jump

Roomba

pal="roomba"

A robot vacuum that sweeps along your footer, very seriously.

<!-- once, anywhere on the page -->
<script src="https://cdn.jsdelivr.net/npm/piixpal@0.4/piixpal.min.js"></script>

<footer>
  …
  <piix-pal pal="roomba"></piix-pal>
</footer>
Options
speed
cleaning speed multiplier
poke it
spins in confusion

Kitty

pal="kitty"

A black cat that lounges on your element and swats at the cursor.

Nap spot

<!-- once, anywhere on the page -->
<script src="https://cdn.jsdelivr.net/npm/piixpal@0.4/piixpal.min.js"></script>

<h2>
  Nap spot
  <piix-pal pal="kitty"></piix-pal>
</h2>
Options
at
where it lies, 0–1
edge
"text" or "box"
poke it
purrs (hearts)

Hiss

pal="hiss"

A snake that slithers along your headings.

Hello, world.
<!-- once, anywhere on the page -->
<script src="https://cdn.jsdelivr.net/npm/piixpal@0.4/piixpal.min.js"></script>

<h1>
  Hello, world.
  <piix-pal pal="hiss"></piix-pal>
</h1>
Options
speed
slithering speed
poke it
flips over

Pinch

pal="pinch"

A crab that walks sideways along your text.

Sideways.
<!-- once, anywhere on the page -->
<script src="https://cdn.jsdelivr.net/npm/piixpal@0.4/piixpal.min.js"></script>

<h1>
  Sideways.
  <piix-pal pal="pinch"></piix-pal>
</h1>
Options
speed
scuttling speed
poke it
flips onto its back

Shibe

pal="shibe"

A shiba that lounges on your text, tail wagging.

Much nap

<!-- once, anywhere on the page -->
<script src="https://cdn.jsdelivr.net/npm/piixpal@0.4/piixpal.min.js"></script>

<h2>
  Much nap
  <piix-pal pal="shibe"></piix-pal>
</h2>
Options
at
where it lies, 0–1
poke it
happy face, tongue out

Capy

pal="capy"

A capybara with a yuzu on its head, completely unbothered.

Some light reading for a slow afternoon.

<!-- once, anywhere on the page -->
<script src="https://cdn.jsdelivr.net/npm/piixpal@0.4/piixpal.min.js"></script>

<p>
  Unbothered.
  <piix-pal pal="capy"></piix-pal>
</p>
Options
at
where it sits, 0–1
poke it
calmly turns to face the other way

Interactions 10

Peeper

pal="peeper"

Guards your inputs: follows the caret, covers its eyes for passwords.

<!-- once, anywhere on the page -->
<script src="https://cdn.jsdelivr.net/npm/piixpal@0.4/piixpal.min.js"></script>

<label>
  Email <input type="email" required>
  <piix-pal pal="peeper"></piix-pal>
</label>
Options
on
the input (or put it inside the label / wrapper)
poke it
a heart (or a polite "...")

Scrolly

pal="scrolly"

A little runner on a reading-progress bar.

Scroll this page: Scrolly runs along the bar at the bottom of this box.

<!-- once, anywhere on the page -->
<script src="https://cdn.jsdelivr.net/npm/piixpal@0.4/piixpal.min.js"></script>

<piix-pal pal="scrolly"></piix-pal>
Options
side
"bottom" or "top"
color
bar colour
box
CSS selector: run along that element instead of the screen
poke it
scrolls you back to the top

Echo

pal="echo"

A copycat cursor that replays your moves half a second late.

Move around and click inside this box: Echo follows you half a second late.

<!-- once, anywhere on the page -->
<script src="https://cdn.jsdelivr.net/npm/piixpal@0.4/piixpal.min.js"></script>

<piix-pal pal="echo"></piix-pal>
Options
delay
seconds behind (default 0.5)
box
CSS selector to only follow inside one element
poke it
cannot be poked: it never catches clicks

Snip

pal="snip"

A highlighter that hops to whatever text you select.

Select a few words in this sentence, then copy them.

<!-- once, anywhere on the page -->
<script src="https://cdn.jsdelivr.net/npm/piixpal@0.4/piixpal.min.js"></script>

<article>
  …
  <piix-pal pal="snip"></piix-pal>
</article>
Options
on
the text to watch (on="body" watches the whole page)
poke it
a heart

Beep

pal="beep"

A robot that panics when someone ticks “I’m not a robot”.

<!-- once, anywhere on the page -->
<script src="https://cdn.jsdelivr.net/npm/piixpal@0.4/piixpal.min.js"></script>

<label>
  <input type="checkbox"> I’m not a robot
  <piix-pal pal="beep"></piix-pal>
</label>
Options
on
the checkbox or the label that holds it
poke it
a nervous "?"

Router

pal="router"

A Wi-Fi router whose signal bars follow your cursor.

<!-- once, anywhere on the page -->
<script src="https://cdn.jsdelivr.net/npm/piixpal@0.4/piixpal.min.js"></script>

<piix-pal pal="router"></piix-pal>
Options
at
where it sits, 0–1
poke it
a heart at full bars

Termi

pal="termi"

A tiny terminal that types out your lines, one character at a time.

<!-- once, anywhere on the page -->
<script src="https://cdn.jsdelivr.net/npm/piixpal@0.4/piixpal.min.js"></script>

<piix-pal pal="termi"
  lines="git push|deploying…|✓ live"></piix-pal>
Options
lines
what to type, separated by |
speed
typing speed
poke it
skips to the next line

Frog

pal="frog"

A frog that snaps its tongue at your cursor.

<!-- once, anywhere on the page -->
<script src="https://cdn.jsdelivr.net/npm/piixpal@0.4/piixpal.min.js"></script>

<piix-pal pal="frog"></piix-pal>
Options
at
where it sits, 0–1
poke it
hops along

Penguin

pal="penguin"

A penguin that belly-slides along your element.

<!-- once, anywhere on the page -->
<script src="https://cdn.jsdelivr.net/npm/piixpal@0.4/piixpal.min.js"></script>

<piix-pal pal="penguin"></piix-pal>
Options
edge
"text" or "box"
poke it
slips and spins

Rocket

pal="rocket"

Sits on your Deploy button. Click it: countdown, lift-off, landing.

Deploy
<!-- once, anywhere on the page -->
<script src="https://cdn.jsdelivr.net/npm/piixpal@0.4/piixpal.min.js"></script>

<button class="deploy">
  Deploy
  <piix-pal pal="rocket"></piix-pal>
</button>
Options
at
where it sits, 0–1
poke it
3, 2, 1, lift-off

Toys 6

Ball

pal="ball"

A beach ball you can throw around your page.

Throw me

<!-- once, anywhere on the page -->
<script src="https://cdn.jsdelivr.net/npm/piixpal@0.4/piixpal.min.js"></script>

<h2>
  Throw me
  <piix-pal pal="ball"></piix-pal>
</h2>
Options
land
CSS selector for surfaces it can land on
at
starting spot, 0–1
box
CSS selector to keep it inside one element (leave out to roam the whole page)
poke it
a little kick into the air

Duck

pal="duck"

A rubber duck you can throw. It squeaks when it lands.

Throw me

<!-- once, anywhere on the page -->
<script src="https://cdn.jsdelivr.net/npm/piixpal@0.4/piixpal.min.js"></script>

<h2>
  Throw me
  <piix-pal pal="duck"></piix-pal>
</h2>
Options
land
CSS selector for surfaces it can land on
at
starting spot, 0–1
box
CSS selector to keep it inside one element (leave out to roam the whole page)
poke it
a little kick into the air

Dice

pal="dice"

Throw it and it lands on a random face.

Throw me

<!-- once, anywhere on the page -->
<script src="https://cdn.jsdelivr.net/npm/piixpal@0.4/piixpal.min.js"></script>

<h2>
  Throw me
  <piix-pal pal="dice"></piix-pal>
</h2>
Options
land
CSS selector for surfaces it can land on
at
starting spot, 0–1
box
CSS selector to keep it inside one element (leave out to roam the whole page)
poke it
a little kick into the air

Pebble

pal="pebble"

A heavy rock that lands with a thud every pal hears.

Throw me

<!-- once, anywhere on the page -->
<script src="https://cdn.jsdelivr.net/npm/piixpal@0.4/piixpal.min.js"></script>

<h2>
  Throw me
  <piix-pal pal="pebble"></piix-pal>
</h2>
Options
land
CSS selector for surfaces it can land on
at
starting spot, 0–1
box
CSS selector to keep it inside one element (leave out to roam the whole page)
poke it
a little kick into the air

Cube

pal="cube"

A jelly cube that bounces high and wobbles.

Throw me

<!-- once, anywhere on the page -->
<script src="https://cdn.jsdelivr.net/npm/piixpal@0.4/piixpal.min.js"></script>

<h2>
  Throw me
  <piix-pal pal="cube"></piix-pal>
</h2>
Options
land
CSS selector for surfaces it can land on
at
starting spot, 0–1
box
CSS selector to keep it inside one element (leave out to roam the whole page)
poke it
a little kick into the air

Can

pal="can"

A soda can that rolls off the edge of everything.

Throw me

<!-- once, anywhere on the page -->
<script src="https://cdn.jsdelivr.net/npm/piixpal@0.4/piixpal.min.js"></script>

<h2>
  Throw me
  <piix-pal pal="can"></piix-pal>
</h2>
Options
land
CSS selector for surfaces it can land on
at
starting spot, 0–1
box
CSS selector to keep it inside one element (leave out to roam the whole page)
poke it
a little kick into the air

Groups 8

Ducks

pal="ducks"

A mother duck and her ducklings.

<!-- once, anywhere on the page -->
<script src="https://cdn.jsdelivr.net/npm/piixpal@0.4/piixpal.min.js"></script>

<piix-pal pal="ducks" count="4"></piix-pal>
Options
count
number of ducklings (default 4)
poke it
a duckling hops; the mother starts a quack chorus

Ants

pal="ants"

A marching line of ants, some carrying crumbs.

<!-- once, anywhere on the page -->
<script src="https://cdn.jsdelivr.net/npm/piixpal@0.4/piixpal.min.js"></script>

<piix-pal pal="ants" count="9"></piix-pal>
Options
count
number of ants (default 7)
speed
marching speed
poke it
they all jump

Fish

pal="fish"

A school of fish that swims inside any box and flees your cursor.

<!-- once, anywhere on the page -->
<script src="https://cdn.jsdelivr.net/npm/piixpal@0.4/piixpal.min.js"></script>

<div class="tank">
  <piix-pal pal="fish" count="9"></piix-pal>
</div>
Options
count
number of fish (default 7)
poke it
that fish darts off

Sparrows

pal="sparrows"

Birds on a wire that scatter when you get close.

<!-- once, anywhere on the page -->
<script src="https://cdn.jsdelivr.net/npm/piixpal@0.4/piixpal.min.js"></script>

<hr>
<piix-pal pal="sparrows" on="hr" count="7"></piix-pal>
Options
count
number of birds (default 6)
poke it
the whole row loops the sky and lands back

Choir

pal="choir"

A choir who sway and sing in perfect time from a shared score.

<!-- once, anywhere on the page -->
<script src="https://cdn.jsdelivr.net/npm/piixpal@0.4/piixpal.min.js"></script>

<piix-pal pal="choir" count="4" bpm="96"></piix-pal>
Options
count
number of singers (default 4)
bpm
tempo (default 96)
poke it
that singer takes a solo; again to rejoin

Fireflies

pal="fireflies"

Soft blinking lights drifting around an element.

<!-- once, anywhere on the page -->
<script src="https://cdn.jsdelivr.net/npm/piixpal@0.4/piixpal.min.js"></script>

<section class="dark">
  <piix-pal pal="fireflies" count="12"></piix-pal>
</section>
Options
count
number of fireflies (default 9)
poke it
they burst away and drift back

Sheep

pal="sheep"

Sheep trot along and jump the fence one at a time, forever.

<!-- once, anywhere on the page -->
<script src="https://cdn.jsdelivr.net/npm/piixpal@0.4/piixpal.min.js"></script>

<div class="loading">
  <piix-pal pal="sheep"></piix-pal>
</div>
Options
count
number of sheep (default 3)
speed
trotting speed
poke it
hearts

Bees

pal="bees"

Worker bees buzzing round their hive.

hive
<!-- once, anywhere on the page -->
<script src="https://cdn.jsdelivr.net/npm/piixpal@0.4/piixpal.min.js"></script>

<div class="hive">
  <piix-pal pal="bees"></piix-pal>
</div>
Options
count
number of bees (default 6)
at
where the hive is, 0–1
poke it
toggles the chase