Rollups & the Portion dial

Two Property kinds for food and anything made of parts. A Rollup totals up an Entry's sub-entries (the calories of a dish = the sum of its ingredients). A Portion dial scales a whole food's macros at once — half a banana, 150 g of rice — with one slider.


Two Property kinds work together to make food tracking feel right: a Rollup adds your parts up into a total, and a Portion dial scales a whole food at once. Both are built for the dish-and-ingredients world that Sub-entries opened up, but each is useful on its own.

Rollup — total up your sub-entries

A Rollup is a read-only Property that shows one number rolled up from an Entry's sub-entries: the sum of every ingredient's calories, the average set's reps, the count of items. It watches the sub-entries and recomputes the instant they change — add an ingredient and the total moves on its own.

The headline case is a dish that totals its ingredients:

🍕  Margherita pizza
   🔥 Σ Ingredient kcal   573
   Ingredients
   ⠿  Pizza crust   130 g   🔥 350
   ⠿  Tomato sauce   40 g   🔥  25
   ⠿  Mozzarella     60 g   🔥 180
   ⠿  Olive oil       2 g   🔥  18

Edit the mozzarella, or add a drizzle of oil, and the 573 updates itself.

Add a Rollup

  1. In the Type builder, add a Property and pick Rollup from the Computed group.
  2. Choose three things: the child Type to total (e.g. Food — a dish's ingredients are just Food entries), the field on it (Calories), and the operationSum, Average, Min, Max, or Count.
  3. That's it. Every Entry of this Type now shows the live total on its card, its page, and the table.

It never double-counts. A Rollup stores nothing of its own — it's just a live view of numbers that already live on the ingredients. So your daily calories stay correct whether you count the dish or its parts.

The Portion dial — scale a whole food at once

A whole banana is about 105 calories. But you might eat half (≈ 53) or two (≈ 210). A Portion dial captures how much you ate and scales every macro together — set it to ½ and the calories, protein, carbs, and fat all halve at once.

🍌  Banana            🔥 53
   Portion  [ 0.5× ]
   🥩 0.7   🍞 14   🥑 0.2

It works two ways, your choice per food:

  • Servings — a multiplier. Good for countable things: ½ a banana, 2 eggs.
  • Grams — the real weight. Good for weighed things: 150 g of chicken, 40 g of oats. (Macros are read per 100 g, the way nutrition labels are written.)

Either way the dial remembers your reference amount, so it can scale up and back down.

Add a Portion dial

  1. In the Type builder, add a Property and pick Portion.
  2. Choose which number fields it scales (Calories, Protein, Carbs, Fat) and the unit (Servings or Grams).
  3. On any Entry, type the amount into the dial — it reads like any number field, no buttons — and every field it controls follows instantly.

The number you see is always what you actually ate — it's the real, counted value, so your daily and weekly totals reflect your true intake. Edit a macro directly and the dial quietly keeps itself consistent.

A field can be driven by at most one Portion dial, and the dial only ever scales the fields you chose — nothing else moves.