Toolbar and footer
The chrome the host draws around a surface: the toolbar an environment declares as data, the footer it renders as JSX, and the view channel between them.
@internote/canvas-sdk#Functions
<V, S = unknown>(options: ViewChannelOptions<V, S>): ViewChannel<V>(items: ToolbarItem[], environmentName: string): ToolbarItem[](name: string, where: ViewHolder, channel: ViewChannel<unknown>): ToolbarItem[]All three environments that grant exploration built the same list themselves and said so in a comment — "the graph's trio, for the same reason", "the graph's and the geo's trio, for the same reason". The ids, the icon, the wording and the rule that reset is dead until there is something to reset are the same answer every time, and a reader moving between two environments should not meet two vocabularies for one gesture.
It was a trio until the bar became the SCENE's and carried every environment's items at once: zoom in and zoom out are what the wheel and the pinch already do, so three environments' worth of them was six buttons duplicating a gesture in a bar that had to fit the reading column. The reset stays because it is the one thing no gesture does.
name prefixes the item ids, which must be unique within an environment's contribution.
#Interfaces
itemsToolbarItem[]systemToolbarSystemStatealignleadingtrailing'leading'busybooleandisabledbooleaniconstringidstringlabelstringonPress() => voidtextlabel so the caption stays short ("Run") while the tooltip explains ("Sign in to run code").stringtype'button'variantnormalsubtle'normal'idstringtype'separator'exitPresent() => voidisPresentingbooleanrequestPresent() => voidstepnumberstepCountnumberactivebooleandisabledbooleaniconstringidstringlabelstringonToggle() => voidtype'toggle'currentV | nullglideto. release clears the stored view on arrival, handing the frame back to the author.voidhasExploredbooleanrecordexplored false also records it as the authored frame — the target reset glides back to.voidresetvoidcreateViewChannel: its view's shape, where it lives, and how two blend.glideMsnumberlerpt of the way between. Called every frame of a glide, so it is also where an environment says what "between" means for its own geometry — the short way round a sphere, a zoom that moves in levels.(from: V, to: V, t: number) => Vread(session: S | undefined) => V | undefinedwriteview is undefined.(session: S | undefined, view: V | undefined) => SidentityEnvironmentIdentitystorageCanvasStorage#Types
ToolbarButtonItem | ToolbarToggleItem | ToolbarSeparatorItem | ToolbarLabelItem