Table of contents

Public class

Signature
class HighlightShapeUtil extends ShapeUtil<TLHighlightShape> {}
References

ShapeUtil, TLHighlightShape

Source

packages/tldraw/src/lib/shapes/highlight/HighlightShapeUtil.tsx


Properties

hideResizeHandles

Public property

Signature
hideResizeHandles: (shape: TLHighlightShape) => boolean
References

TLHighlightShape


hideRotateHandle

Public property

Signature
hideRotateHandle: (shape: TLHighlightShape) => boolean
References

TLHighlightShape


hideSelectionBoundsFg

Public property

Signature
hideSelectionBoundsFg: (shape: TLHighlightShape) => boolean
References

TLHighlightShape


migrations

Public static property

Signature
static migrations: import('@tldraw/editor').TLShapePropsMigrations
References

TLShapePropsMigrations


onResize

Public property

Signature
onResize: TLOnResizeHandler<TLHighlightShape>
References

TLOnResizeHandler, TLHighlightShape


props

Public static property

Signature
static props: {
  color: import('@tldraw/editor').EnumStyleProp<
    | 'black'
    | 'blue'
    | 'green'
    | 'grey'
    | 'light-blue'
    | 'light-green'
    | 'light-red'
    | 'light-violet'
    | 'orange'
    | 'red'
    | 'violet'
    | 'white'
    | 'yellow'
  >
  isComplete: import('@tldraw/editor').Validator<boolean>
  isPen: import('@tldraw/editor').Validator<boolean>
  segments: import('@tldraw/editor').ArrayOfValidator<{
    points: import('@tldraw/editor').VecModel[]
    type: 'free' | 'straight'
  }>
  size: import('@tldraw/editor').EnumStyleProp<'l' | 'm' | 's' | 'xl'>
}
References

EnumStyleProp, Validator, ArrayOfValidator, VecModel


type

Public static property

Signature
static type: 'highlight'

Methods

backgroundComponent()

Public method

Signature
backgroundComponent(
  shape: TLHighlightShape
): import('react/jsx-runtime').JSX.Element
Parameters
NameDescription

shape

TLHighlightShape
Returns
import('react/jsx-runtime').JSX.Element
References

TLHighlightShape


component()

Public method

Signature
component(shape: TLHighlightShape): import('react/jsx-runtime').JSX.Element
Parameters
NameDescription

shape

TLHighlightShape
Returns
import('react/jsx-runtime').JSX.Element
References

TLHighlightShape


getDefaultProps()

Public method

Signature
getDefaultProps(): TLHighlightShape['props']
References

TLHighlightShape


getGeometry()

Public method

Signature
getGeometry(shape: TLHighlightShape): Circle2d | Polygon2d
Parameters
NameDescription

shape

TLHighlightShape
Returns
Circle2d | Polygon2d
References

TLHighlightShape, Circle2d, Polygon2d


indicator()

Public method

Signature
indicator(shape: TLHighlightShape): import('react/jsx-runtime').JSX.Element
Parameters
NameDescription

shape

TLHighlightShape
Returns
import('react/jsx-runtime').JSX.Element
References

TLHighlightShape


toBackgroundSvg()

Public method

Signature
toBackgroundSvg(
  shape: TLHighlightShape
): import('react/jsx-runtime').JSX.Element
Parameters
NameDescription

shape

TLHighlightShape
Returns
import('react/jsx-runtime').JSX.Element
References

TLHighlightShape


toSvg()

Public method

Signature
toSvg(shape: TLHighlightShape): import('react/jsx-runtime').JSX.Element
Parameters
NameDescription

shape

TLHighlightShape
Returns
import('react/jsx-runtime').JSX.Element
References

TLHighlightShape


HighlightShapeToolHighlightToolbarItem