Manta Developers
GitHub
Menu

@manta-eu/react/goal-bar

Reference for @manta-eu/react/goal-bar as it is on main.

Type Aliases

GoalBarMilestone

GoalBarMilestone = object

Properties

date?

optional date?: Date

label?

optional label?: string

value

value: number


GoalBarProjection

GoalBarProjection = object

Properties

change

change: number

How far it moves the goal from now, in the goal’s unit; negative for a goal that aims lower.

label

label: string

steps?

optional steps?: readonly GoalBarStep[]


GoalBarProps

GoalBarProps = object

Properties

baseline

baseline: number

className?

optional className?: string

formatDate?

optional formatDate?: (date) => string

Parameters
date

Date

Returns

string

formatValue

formatValue: (value) => string

Parameters
value

number

Returns

string

optional header?: boolean

label

label: string

milestones?

optional milestones?: readonly GoalBarMilestone[]

now

now: number

projection?

optional projection?: GoalBarProjection

startDate?

optional startDate?: Date

status?

optional status?: GoalBarStatus

target

target: number

The track’s end; a target below the baseline is a goal that aims lower.

targetDate?

optional targetDate?: Date

today?

optional today?: Date

todayMark?

optional todayMark?: GoalBarTodayMark

Where Today stands: pace (the default) places it by time between startDate and targetDate, so a dot short of it is behind a steady pace; now marks now with Today’s rule and word in place of its dot.

words?

optional words?: Partial<GoalBarWords>


GoalBarStatus

GoalBarStatus = object

Properties

label

label: string

variant

variant: StatusVariant


GoalBarStep

GoalBarStep = object

Properties

approved?

optional approved?: boolean

Decided but not yet measured, such as an approved plan: lightly filled.

change

change: number

label

label: string

note?

optional note?: string


GoalBarTodayMark

GoalBarTodayMark = "pace" | "now"

Where Today stands on the track: by time between the start and target dates (pace), or at now (now).


GoalBarWords

GoalBarWords = object

Properties

by

by: string

milestone

milestone: string

now

now: string

pace

pace: string

startedAt

startedAt: string

takesItTo

takesItTo: string

target

target: string

today

today: string

Functions

GoalBar()

GoalBar(props): Element

Parameters

props

GoalBarProps

Returns

Element