Skip to main content

Documentation Index

Fetch the complete documentation index at: https://docs.velt.dev/llms.txt

Use this file to discover all available pages before exploring further.

New to wireframes? Start with UI Customization Concepts and the Template Variables overview.

Overview

The Area feature draws rectangle “area annotations” used to highlight regions of the page (often paired with a comment). Variables below are available inside <velt-area-pin-portal-wireframe> via three forms:
You want to…UseExample
Display a value as text<velt-data field="var" /><velt-data field="componentConfig.areaPinAnnotation.from.name" />
Hide / show conditionallyvelt-if="{var}"velt-if="{componentConfig.selected}"
Toggle a CSS classvelt-class="'cls': {var}"velt-class="'is-resizing': {componentConfig.isResizing}"
This feature uses the flat-config access pattern — variables are referenced via the explicit componentConfig.<path> form.

Component Config

VariableTypeDescriptionExample
componentConfig.areaPinAnnotationAreaAnnotationThe area annotation data — geometry, colour, author, and metadata.<velt-data field="componentConfig.areaPinAnnotation.from.name" />
componentConfig.areaPinAnnotationOnResizeAreaAnnotationMid-resize snapshot of the annotation.Internal — set during resize.
componentConfig.commentPinAnnotationCommentAnnotationOptional linked comment annotation.<velt-data field="componentConfig.commentPinAnnotation.comments.length" />
componentConfig.userUserCurrently identified end-user.<velt-data field="componentConfig.user.name" />
componentConfig.selectedbooleanPin is currently selected.velt-class="'is-selected': {componentConfig.selected}"
componentConfig.hideAreaAnnotationbooleanHide the area visual.velt-class="'is-hidden': {componentConfig.hideAreaAnnotation}"
componentConfig.areaAnnotationColorstringBorder / overlay colour (default '#625DF5').Internal — used to compute inline style.
componentConfig.areaPropertiesAreaPropertyGeometry data — top / left / width / height.Internal — used to compute inline style.
componentConfig.isResizingbooleanUser is currently resizing this pin.velt-class="'is-resizing': {componentConfig.isResizing}"
componentConfig.resizingOffset.topnumberVertical resize-handle offset.Internal — used to compute inline style.
componentConfig.resizingOffset.leftnumberHorizontal resize-handle offset.Internal — used to compute inline style.
componentConfig.offsetTopnumberVertical position offset.Internal — used to compute inline style.
componentConfig.offsetLeftnumberHorizontal position offset.Internal — used to compute inline style.

Type Reference

Types referenced by the variables above:
TypeDescription
UserIdentified end-user object.
CommentAnnotationLinked comment-annotation thread (when the area is paired with a comment).
AreaAnnotationArea-annotation data — geometry (top, left, width, height), colour, author, and metadata.
AreaPropertyGeometry shape used by componentConfig.areaProperties.

Subcomponents

The Area feature has three customer-facing primitives. Only area-pin-portal registers a wireframe tag.

area-pin-portal

The rendered area-pin overlay — the only Area primitive with a wireframe tag.
  • Public element: <velt-area-pin-portal>
  • Wireframe tag: <velt-area-pin-portal-wireframe>
PropertyValue
Extra variablesNone — the portal sees the full componentConfig shown above.
<VeltAreaPinPortalWireframe
  velt-class="'is-selected': {componentConfig.selected}, 'is-resizing': {componentConfig.isResizing}, 'is-hidden': {componentConfig.hideAreaAnnotation}">
  <div className="my-area-pin">
    <span className="my-area-pin__author">
      <velt-data field="componentConfig.areaPinAnnotation.from.name" />
    </span>
  </div>
</VeltAreaPinPortalWireframe>

area-tool

The trigger to draw a new area.
  • Public element: <velt-area-tool>
PropertyValue
Wireframe tagNo <velt-...-wireframe> registration available on this primitive.

area-container

The per-document container that orchestrates all area pins.
  • Public element: <velt-area-container>
PropertyValue
Wireframe tagNo <velt-...-wireframe> registration available on this primitive.

Putting it together

A typical area pin that highlights its selected state, dims while hidden, and shows a resize affordance while the user drags:
<VeltAreaPinPortalWireframe
  velt-class="'is-selected': {componentConfig.selected}, 'is-hidden': {componentConfig.hideAreaAnnotation}, 'is-resizing': {componentConfig.isResizing}">
  <div className="my-area-pin">
    <span className="my-area-pin__author">
      <velt-data field="componentConfig.areaPinAnnotation.from.name" />
    </span>
    <span
      className="my-area-pin__resize-handle"
      velt-if="{componentConfig.selected}" />
  </div>
</VeltAreaPinPortalWireframe>