A saved view of a collection: how it shows (type), which records, in
which order (query, Cardbox.Query's wire format), and the options of
its type.
| Type | Shown with | Options |
|---|---|---|
table | Masu | columns (field keys, in order), hidden, widths (%{key => px}) |
board | Narabe | group_by (a select, status, person or checkbox field), hidden_groups, card_fields |
list | Narabe | fields |
calendar | Koyomi | date_field (a date field) |
chart | Fude | kind, x (and its unit), y, color, title (see Cardbox.Fude) |
canvas | Hakushi | layout (%{record_id => %{"x" => x, "y" => y}}), edges (a relation field) |
A view with no owner is shared with everyone who has the collection;
a view with an owner (a person's id) is theirs.
An app adds types of its own (use Cardbox, views: ["timeline"]), whose
options its Cardbox.check_view/3 checks, and draws them itself: a
view of any type has its query, and list/3 of it gives its records.
Summary
Types
Functions
@spec types() :: [String.t()]
Cardbox's types of views.