blockly > icons > MutatorIcon

icons.MutatorIcon class

An icon that allows the user to change the shape of the block.

For example, it could be used to add additional fields or inputs to the block.

Signature:

export declare class MutatorIcon extends Icon implements IHasBubble 

Extends: Icon

Implements: IHasBubble

Constructors

Constructor Modifiers Description
(constructor)(flyoutBlockTypes, sourceBlock) Constructs a new instance of the MutatorIcon class

Properties

Property Modifiers Type Description
sourceBlock

protected

readonly

BlockSvg
TYPE

static

readonly

IconType<MutatorIcon> The type string used to identify this icon.
WEIGHT

static

readonly

(not declared) The weight this icon has relative to other icons. Icons with more positive weight values are rendered farther toward the end of the block.

Methods

Method Modifiers Description
applyColour()
bubbleIsVisible()
dispose()
findParentWs(workspace) static Returns the parent workspace of a workspace that is inside a mini workspace bubble, taking into account whether the workspace is a flyout.
getSize()
getType()
getWeight()
getWorkspace()
initView(pointerdownListener)
isClickableInFlyout()
onClick()
onLocationChange(blockOrigin)
reconnect(connectionChild, block, inputName) static Reconnects the given connection to the mutated input on the given block.
setBubbleVisible(visible)
updateCollapsed()