Composition / foldkit-mixins-builder

BuilderView

namespace · packages/mixins-builder/src/index.ts:576

const BuilderView = { inputs, submodel, parts, assemble, narrow, define }

In the guides

Members

BuilderView.inputs

function · packages/mixins-builder/src/index.ts:578

inputs(inputs?: BuilderViewInputs): BuilderViewInputs

What the drawn Builder is drawn with, typed where a form's controls entry cannot be.

BuilderView.submodel

function · packages/mixins-builder/src/index.ts:584

submodel(
  view: BuilderSlotView,
): Submodel.View<Model, Message, BuilderViewInputs>

The drawn Builder as a Submodel view, for bundle.pipe(Bundle.withView(...)) or builder.inputWith(...), drawn with BuilderView.inputs(...).

BuilderView.parts

function · packages/mixins-builder/src/index.ts:605

parts(
  builder: BuilderLike,
  options?: {
    readonly settings?: SettingsLook
  },
): BuilderParts

The Builder's parts, each drawn again only when what it reads changed, with its Behaviors (the layers' keyboard, the canvas's pointer, the shortcuts) declared with it. Place them with assemble.

BuilderView.assemble

function · packages/mixins-builder/src/index.ts:1704

assemble(
  render: SlotView.AssemblyRender<typeof BuilderSlots, BuilderInput, Message>,
): BuilderSlotView

A layout of your own: render places the parts with draw, around anything else you draw with its h. Styles and Behaviors attach to the result as to define's.

BuilderView.narrow

function · packages/mixins-builder/src/index.ts:1716

narrow(width: string, options?: {
    readonly layer?: Placement;
}): NamedStyle<Slots.Contract<{ readonly root: Slot.UnnamedSlot<Capability.Capability<"Container", readonly [Capability.Capability<"Interactive", readonly [Capability.Capability<"Base", readonly []>]>]>, readonly Slot.EventName[], readonly Slot.AttributeName[], readonly Slot.RequirementName[], boolean>; readonly regions: Slot.UnnamedSlot<Capability.Capability<"Container", readonly [Capability.Capability<"Interactive", readonly [Capability.Capability<"Base", readonly []>]>]>, readonly Slot.EventName[], readonly Slot.AttributeName[], readonly Slot.RequirementName[], boolean>; readonly start: Slot.UnnamedSlot<Capability.Capability<"Container", readonly [Capability.Capability<"Interactive", readonly [Capability.Capability<"Base", readonly []>]>]>, readonly Slot.EventName[], readonly Slot.AttributeName[], readonly Slot.RequirementName[], boolean>; readonly bar: Slot.UnnamedSlot<Capability.Capability<"Container", readonly [Capability.Capability<"Interactive", readonly [Capability.Capability<"Base", readonly []>]>]>, readonly Slot.EventName[], readonly Slot.AttributeName[], readonly Slot.RequirementName[], boolean>; readonly stage: Slot.UnnamedSlot<Capability.Capability<"Container", readonly [Capability.Capability<"Interactive", readonly [Capability.Capability<"Base", readonly []>]>]>, readonly Slot.EventName[], readonly Slot.AttributeName[], readonly Slot.RequirementName[], boolean>; readonly end: Slot.UnnamedSlot<Capability.Capability<"Container", readonly [Capability.Capability<"Inte …;

The narrow layout, below width of the Builder itself (its root is the container builder): the panels' tabs show, and only the panel the Builder's panel names; selecting a node chooses Settings. In the app layer by default, so it outranks an application's own placing of the panels; pass layer to put it elsewhere.

BuilderView.define

function · packages/mixins-builder/src/index.ts:1737

define(
  builder: BuilderLike,
  options?: {
    readonly settings?: SettingsLook
  },
): BuilderSlotView

The Builder drawn with every part, in the default layout.