commands/timestamps#

Functions#

groupstampByDefault()#

groupstampByDefault(manifest, timeline, editor): boolean

Defined in: commands/timestamps.ts:107

Whether a timestamp made on the timeline timeline of manifest is a groupstamp unless the command says otherwise: on a group member, when it is made above a timeline editor (the arranger at the top level, a bundle editor, a group editor; editor the innermost editor open, null for none), and never when made in a timeline editor or on a timeline that is no group’s member. The editor gives the result to add as groupstamp; add itself, which knows no editor, takes false where none is given.

Parameters#

manifest#

Manifest

timeline#

string

editor#

EditorKind | null

Returns#

boolean


importedManifest()#

importedManifest(manifest, minter?): Manifest

Defined in: commands/timestamps.ts:230

A manifest as the editor imports it: one without a graphical object has every root given its default timestamps (withDefaultTimestamps, in root order, their IDs minted by minter, a fresh one by default), its graphical object completed and the whole in canonical order; one with a graphical object, which states its own timestamps, is returned as it is. The add of a block carries the manifest, so the journal holds these IDs.

Parameters#

manifest#

Manifest

minter?#

IdMinter = ...

Returns#

Manifest


isGroupMember()#

isGroupMember(manifest, timeline): boolean

Defined in: commands/timestamps.ts:94

Whether the timeline timeline of manifest is a member of some group (groupsHolding).

Parameters#

manifest#

Manifest

timeline#

string

Returns#

boolean


readDisplay()#

readDisplay<W>(value, words, path): Problem | W[]

Defined in: commands/timestamps.ts:75

A display given to a command, as stored: a list of the display words words (a named timestamp’s TIMESTAMP_DISPLAY, an alignment anchor’s ANCHOR_DISPLAY), each at most once, in any order, stored in the canonical order of words. Anything else is invalid_value at path.

Type Parameters#

W#

W extends string

Parameters#

value#

unknown

words#

readonly W[]

path#

readonly PathSegment[]

Returns#

Problem | W[]


readGroupstamp()#

readGroupstamp(value, manifest, timeline, path): boolean | Problem

Defined in: commands/timestamps.ts:123

Whether a timestamp on timeline is a groupstamp, as a command gives it: true or false (invalid_value for anything else), true only on a group member, a match timestamp included, refused as invalid_value at path elsewhere. A groupstamp’s line extends across every member of each group having its timeline as a member; their coordinates and lines derive from the group and are never stored.

Parameters#

value#

unknown

manifest#

Manifest

timeline#

string

path#

readonly PathSegment[]

Returns#

boolean | Problem


readTimestampCoordinate()#

readTimestampCoordinate(value, timeline, path): Problem | JsonNumber | readonly [JsonNumber, JsonNumber]

Defined in: commands/timestamps.ts:41

A named timestamp’s coordinate given to a command, as stored: a bare value on the own axis of timeline, the timeline it lies on (invalid_coordinate where it does not read as the axis’s number type), from 0 to the timeline’s length, or from 0 where the length is unknown (invalid_value before its start or after its end).

Parameters#

value#

unknown

timeline#

{ }

path#

readonly PathSegment[]

Returns#

Problem | JsonNumber | readonly [JsonNumber, JsonNumber]


withDefaultTimestamps()#

withDefaultTimestamps(manifest, timeline, groupstamp, mint): Manifest

Defined in: commands/timestamps.ts:177

manifest with the default timestamps of timeline: origin at the zero of its number type and, where its length is known, length at its length, each given the ID mint gives and appended to its named timestamps. A new root’s (groupstamp false) show their wedge and coordinate. A child timeline joining a group is given them as groupstamps (groupstamp true), which also show their line across the frame (cross_section); a timestamp of the timeline already named origin or length at that coordinate (compared by value) is made a groupstamp instead, cross_section added to its display, and none is added for it.

Parameters#

manifest#

Manifest

timeline#

{ }

groupstamp#

boolean

mint#

Mint

Returns#

Manifest


withGroupstampsOnMembers()#

withGroupstampsOnMembers(manifest): Manifest

Defined in: commands/timestamps.ts:146

manifest with every groupstamp whose timeline is no group’s member any more (a group removed, a member left its group) made an ordinary timestamp (groupstamp: false), so that a command ending a membership is never refused for the groupstamps it leaves; manifest itself when there is none. Applied to every manifest a command settles, never on reading a file.

Parameters#

manifest#

Manifest

Returns#

Manifest