Skip to content

Allowance Piggy

v1.0

A family pocket-money app in puffy clay: drag the week's coins into spend, save and give jars, approve chores and watch the piggy fill toward each goal.

$69

Page address: /

Built in

What you get
  • Light and darkUses your theme colors
  • Desktop, tablet, and phoneThe screens it is built for
  • Packages…
  • Code size…
  • Light on battery30 fps, idle when still
  • Pauses when hiddenOff-screen or other tab
  • Reduce motionCalm for people who ask

Checked on every change

Security checked Dec 3
  • Type checkTypeScript strict
  • Lint and formatESLint · Prettier
  • Tests and buildLight and dark screenshots
  • Security auditNo high or critical advisories
  • Package ageEvery version public 7+ days
  • Idle CPUUnder half a core at rest, ≤ 30 fps

Code

allowance-piggyReact
  • allowance-piggy.tsxThe page: the sections in order.
  • content.tsEvery word and number: brand, nav links, each section's copy and lists.
  • theme.tsThe colors as CSS variables, and the shared class strings.
  • README.mdHow to install it, and where to change the text, colors and form.
  • pagesOne file per page: the sections it shows, in order.
    • chores.tsxThe chores: filter by status (in the address, so Back keeps it) and by the picked kid, add, edit, mark done, approve and delete.
    • goals.tsxThe goals: each kid's goals in the order they save for them, with add money, mark bought, reorder, edit and delete.
    • jars.tsxThe jars: allowance day, then each kid's three jars with add, spend and move, and their split rule.
    • kids.tsxThe kids: everyone's card, and one kid's page (#/kids/<id>) with tabs for their jars, chores, goals and activity.
    • money.tsxEvery money entry: filter by kind and jar (in the address, so Back keeps them) and by the picked kid, add one, or delete one to put the jars back.
    • overview.tsxThe overview: allowance day for the picked kid, the family bank, chores waiting for a yes, savings per month, everyone's jars, goals and recent money.
    • reports.tsxThe reports: totals for the range, saved / spent / given per month, giving by cause and chores done per week, for everyone or the picked kid.
    • settings.tsxThe settings page: the family (name, payday, chore approval, the split for new kids, the parents) and Appearance (style, theme and language).
    • sign-in.tsxThe sign-in page (#/sign-in): a sunny clay card with the piggy and the tagline beside the form, over the backdrop, without the top bar and dock.
  • sectionsOne file per page section.
    • account-menu.tsxThe account menu under the avatar in the top bar: who is signed in, Settings and Sign out; the arrow keys move through it, Escape, Tab or a click outside closes it.
    • allowance-pile.tsxAllowance day, the app's signature: the week's allowance as a pile of coins you drag into the Spend, Save and Give jars; each coin drops in with a bounce and fills its jar, then Pay saves it.
    • appearance.tsxSettings → Appearance: the style (Glass or Solid) and the theme (System, Dark or Light), each choice shown as a small preview, and the language (System or one of locales/list.ts).
    • chore-dialog.tsxAdd or edit a chore: what it is, who does it, what it pays, how often, when it is due and its picture.
    • chore-row.tsxOne chore as a clay row: its picture, who does it, what it pays, and the next step (mark done, approve or send back).
    • dock.tsxThe dock: a floating clay tray of puffy gold coins in different sizes, one per page; the current coin lifts, wears the pink ring and spins once when you arrive.
    • goal-card.tsxOne savings goal as a wide clay row: the piggy filling up, how far along, and add money, mark bought, reorder, edit and delete.
    • goal-dialog.tsxAdd or edit a savings goal, and add money to one from the kid's Save jar.
    • kid-card.tsxOne kid as a clay card that opens their page: badge, age, allowance and their three jars.
    • kid-dialog.tsxAdd or edit a kid: name, age, weekly allowance, their badge color and ears, and how their money splits into the jars.
    • money-dialog.tsxAdd money in, a spend, a gift to a cause or a move between jars, for one kid.
    • sign-in-form.tsxThe sign-in form: email and password with their errors under them, show or hide the password, keep me signed in, and the demo account to fill in; a wrong pair says so above the fields.
    • top-bar.tsxThe top bar: the piggy logo, the kid picker (everyone or one kid, kept in the address so it survives Back), search, the theme switch and the account menu; the bar frosts once the page scrolls.
    • txn-row.tsxOne money entry: what happened, whose jar, when, and the amount in (+) or out (−).
  • partsWhat several sections share.
    • buildWhat several sections share.
      • cardsWhat several sections share.
        • burst.tsThe burst card style: cards spread out from the middle of the page, the nearest first.
      • rowsWhat several sections share.
        • odo.tsxThe odo row motion: each row on screen rises 6px from faint while every number rolls digit by digit to its value.
      • core.tsxThe page's build-in: on first load and on every page switch the cards arrive in the app's card style and their contents build: bars grow, lines draw, rings fill, the list rows on screen ripple in in the app's row motion, numbers count. The two picks are wired in ./index.ts.
      • index.tsThe app's two build-in picks, wired here and nowhere else: its card style (cards/) and its row motion (rows/). npm run new-app copies only the two it is given (--cards, --rows).
    • appearance.tsHow the app looks right now: dark or light, Glass or Solid, from Settings → Appearance, the page around it and the Style setting.
    • avatar.tsxA person's initials in a round clay badge; a kid's badge wears the drawn ears they picked, in their color.
    • backdrop.tsxThe Glass style's backdrop: soft puffs of clay color behind the cards (a pink one, a mint one, a little gold coin glow), faded out in Solid; with followBackground it paints your background instead.
    • charts.tsxThe charts: stacked month bars, a smooth weekly line and a giving donut, flat inside their clay cards and painted in the chart shades.
    • clay-jar.tsxA drawn clay jar (Spend, Save or Give) whose coins fill it to its amount; a new coin drops in with a bounce and the jar squishes.
    • command-palette.tsxThe command palette (⌘K or Ctrl K): type to find a page or an action, then Enter.
    • confirm.tsxA yes-or-no dialog before something that can't be undone (deleting a kid, a chore, a goal).
    • dialog.tsxA centered modal dialog (a form, a confirm): rises in, plays its way out, Escape or a tap outside closes it, and the focus goes back where it was.
    • field.tsxA labeled form field (a text input or a select) with its error line under it, tied together for screen readers.
    • format.tsHow numbers and dates are written: by Intl, the current language's way ("1,240", "1.240"; "Nov 19", "19 nov."). Add a helper here when a page needs money, times or a list.
    • icons.tsxThe logo and the chunky line icons, drawn on a 24-unit grid with round ends.
    • language.tsThe app's language: the words every page reads (useWords), how dates and numbers are written (parts/format.ts) and the reading direction. Picked in Settings → Appearance (or System: the page's own language) and kept in this browser; English is built in, any other language loads only when it shows (locales/list.ts).
    • moments.tsThe animations the sidebar, the sign-in card, menus, dialogs, the phone sheet and toasts play, timed by their moments in theme.ts.
    • motion.tsMotion helpers: the reduced-motion check, live, and run-once-in-view.
    • page-head.tsxA page's heading row: the puffy title, one line under it and the page's main action on the end.
    • piggy.tsxA drawn clay piggy bank that fills with gold as a goal is saved; when the goal is reached it wiggles and pops a few coins.
    • router.tsThe page switcher: reads the app's page from the address hash (#/settings, #/?status=open).
    • save.tsRuns a save through the fake API: on success the loads it changed come in again and a toast says so; on failure the toast says why.
    • scroll-to-view.tsScrolls an element into view moving only its own scroll container, never the page around it.
    • select-box.tsxA native select dressed to match the app: no browser arrow, a drawn chevron instead.
    • session.tsWhether someone is signed in: a first visit is signed in as the demo account; Sign out holds until the next sign-in, and a sign-in without Keep me signed in lasts only this tab.
    • states.tsxThe data states every page shares: a calm skeleton while loading, an error with Try again, and an empty note with a way out.
    • store.tsThe app-wide state several parts share: the theme mode and style (kept in the browser) and the toasts.
    • ticker.tsxA number that counts up while its page builds in, and rolls to its new value whenever it changes.
    • toasts.tsxThe toasts: short notes that confirm what just happened, at the bottom end.
    • use-api.tsLoads data through the fake API with loading, error and retry, remembering each answer so a page you come back to shows at once.
    • use-dialog.tsOpens and closes a native <dialog> as a modal; on close it plays its way out first (data-closing), so dialogs, sheets and the palette never vanish in one frame.
  • dataThe pretend data and the fake API: swap it for your backend.
    • account.tsThe demo account: who is signed in (the account menu shows them) and the email and password the sign-in page takes.
    • api.tsThe fake API: every page loads and saves through these functions, so wiring a real backend happens here only.
    • family.tsThe pretend family: the kids with their jars and split rules, the chores, the savings goals and the family settings. Money is in cents.
    • history.tsThe pretend money history: every deposit, spend, transfer and gift of the last ten weeks, and the monthly and weekly totals the reports draw. Money is in cents.
  • localesEvery word the app shows, one JSON file a language; list.ts names them.
    • en.jsonOne language's words, with the keys of en.json.
    • es.jsonOne language's words, with the keys of en.json.
    • list.tsThe languages the app offers, in the picker's order: one JSON file each, en.json the source. To remove one, delete its file and its line; to add one, copy es.json, translate it and add a line. English is built in; the rest load only when picked. TypeScript checks each file has en.json's keys, scripts/check/check-locales.mjs the rest (no extra keys, plural forms, {slots}).

allowance-piggy.tsx

The page: the sections in order.

Loading…
Good for
Parents running allowances, chores and savings goals for two or three kids, in a toy-like look kids enjoy too.
How it works
Coins drag from the allowance pile into clay jars that bounce and fill; chores pay by each kid's split and the piggy wiggles at a goal.
How to use
Edit words in content.ts and colors in theme.ts, and swap the bodies in data/api.ts for calls to your backend.