Line

You are reading the unreleased docs (next). See latest (v0.9)

ui/client/features/notes/domain/NoteText

Pure (DOMAIN-001): the words of the Notes screen, for the states of docs/design/mocks/ia-notes-states.html.

Cockpit client (features), next. Source: ui/client/features/notes/domain/NoteText.ts.

Type Aliases#

Indicator#

Indicator = object

Defined in: ui/client/features/notes/domain/NoteText.ts:13

Properties#

icon

icon: string

Defined in: ui/client/features/notes/domain/NoteText.ts:13

text

text: string

Defined in: ui/client/features/notes/domain/NoteText.ts:13

tone

tone: "idle" | "busy" | "ok" | "warn" | "bad"

Defined in: ui/client/features/notes/domain/NoteText.ts:13

Variables#

STATUS_LABEL#

const STATUS_LABEL: Record<NoteStatus, string>

Defined in: ui/client/features/notes/domain/NoteText.ts:4

Functions#

clock()#

clock(iso): string

Defined in: ui/client/features/notes/domain/NoteText.ts:7

"12:41" from an ISO time; empty when it does not parse.

Parameters#

iso

string

Returns#

string


failureHint()#

failureHint(code): string

Defined in: ui/client/features/notes/domain/NoteText.ts:51

What Retry can do about it: the hint under the indicator.

Parameters#

code

string

Returns#

string


failureReason()#

failureReason(code, message): string

Defined in: ui/client/features/notes/domain/NoteText.ts:35

The short reason after "Not saved": the server's code in plain words, else its message.

Parameters#

code

string

message

string

Returns#

string


indicatorOf()#

indicatorOf(save, dirty, readOnly): Indicator

Defined in: ui/client/features/notes/domain/NoteText.ts:16

The save indicator: Saving / Saved on this machine / Unsaved / Not saved / Changed in another tab.

Parameters#

save

SaveState

dirty

boolean

readOnly

boolean

Returns#

Indicator


rowTitle()#

rowTitle(row): string

Defined in: ui/client/features/notes/domain/NoteText.ts:57

Parameters#

row

NoteRow

Returns#

string


statusTag()#

statusTag(status, planStale): object

Defined in: ui/client/features/notes/domain/NoteText.ts:62

The tag beside a row or the editor title: "Draft", "Plan ready", "Plan out of date", "Ran".

Parameters#

status

NoteStatus

planStale

boolean

Returns#

object

label

label: string

tone

tone: "ready" | "draft" | "stale" | "run"