Documentation

Custom item types

Design reusable templates for the small building blocks of your material — problems, concepts, examples — from a fixed set of primitives, without turning the workspace into a low-code builder.

What an item type is

An item is the smallest reusable unit of content in Didaxi — a single problem, definition, example, or note. An item type is the template that decides what an item of that kind contains and how it renders once it is embedded in a document.

Name and description are creator-facing metadata: they help you recognize and manage the type inside the workspace and are never shown to readers unless you opt in. Everything a reader sees is controlled by the type's parts, attributes, and display settings.

Parts — the content blocks

Parts are the ordered building blocks an author fills in when creating an item. You assemble a type from a fixed set of primitives, so every item of that type stays structurally consistent.

Each part carries an access level, so a single item can mix openly visible content with gated content. A Problem type, for example, might expose its statement publicly while reserving the full solution for entitled readers.

  • Rich text — formatted prose with inline math.
  • Image — a referenced asset from the workspace library.
  • External video — an embedded YouTube or Vimeo link.
  • Divider — a visual separator with no content of its own.
  • Group — a repeatable container (e.g. a list of hints or answer choices) whose child parts repeat as a set.
  • Access level per part: public, registered, or entitled.

Attributes — typed metadata

Attributes are typed fields attached to an item rather than free-form content — useful for classification, difficulty, or provenance that you may later want to filter on or display consistently.

An attribute can be optional in documents and can allow a per-document override, so the same item can carry a default value that a specific document adjusts.

  • Value types: text, number, or boolean.
  • Placement decides whether the value renders inline with the item or as separate metadata.
  • Example: a `difficulty` number and a `source` text field on a Problem type.

Display label & numbering

The display label is shown above the embedded item in a document. It is separate from the type name: leave it empty to show nothing, use plain text for a static caption, or include a single numbering token to join document-flow numbering.

  • Empty — renders nothing above the item.
  • `Problem` — a static label, shown verbatim.
  • `Problem {n}` — contextual numbering: `Problem 1`, `Problem 2`, … as items appear in the document.
  • `Section {N}` — `{N}` uses upper-scope numbering (it opens or advances a numbering scope).
  • `Task {n!}` — `{n!}` steps a local-only counter that does not affect the shared sequence.

Counter keys

A counter key is only needed when a display label uses numbering. Item types that share the same key share one sequence within a document, so numbering can be either independent or unified across several types.

Example: give both a Problem type and an Exercise type the counter key `problem`, and they number together as one running sequence; give them different keys and they number independently.

Item title templates

A type can pre-fill the title of a new item when it is first opened for creation. The template is resolved once at the start of editing; the author can freely change the title afterwards. A template can be a single token or mix tokens with text.

  • `{date:yyyyMMdd}` and `{date:yyyyMMddHHmmss}` insert a timestamp.
  • `{rand:N}` inserts a random uppercase string of length N, e.g. `{rand:4}`.
  • Tokens need no prefix: `{date:yyyyMMddHHmmss}` is valid on its own.

Deleting an item type

A custom item type can only be deleted while no item uses it — this protects existing documents from losing their structure. The editor shows exactly how many items still reference the type and links to each one, so you can reassign or remove them first.

Built-in system types cannot be deleted. Once the last item is detached, the delete action unblocks.

Continue reading

4 min read

Didaxi overview

The product model, the main content layers, and the logic behind reusable educational publishing.

5 min read

Topics and tags

How structural classification and flexible labels work together without restricting future content reuse.