Skip to content
import { createSpikeSymbol, updateSpikeSymbol } from "@arcgis/core/smartMapping/renderers/support/spikeUtils.js";
Since
ArcGIS Maps SDK for JavaScript 4.33

This module provides utility functions for creating and updating spike symbols for size renderers generated with a spike theme.

Functions

createSpikeSymbol

Function

Creates a spike symbol for use in size renderers generated with a spike theme.

Signature
createSpikeSymbol (symbolInfo: SymbolInfo): CIMSymbol
Parameters
ParameterTypeDescriptionRequired
symbolInfo

An object containing properties of the symbol to create.

Returns
CIMSymbol

Returns a spike symbol.

updateSpikeSymbol

Function

Updates the properties of a spike symbol. This is typically used to update the color and size of the symbol.

Signature
updateSpikeSymbol (symbol: CIMSymbol, symbolInfo: Partial<SymbolInfo>): CIMSymbol
Parameters
ParameterTypeDescriptionRequired
symbol

The spike symbol to update.

symbolInfo

An object containing properties of the symbol to update.

Returns
CIMSymbol

Returns the updated spike symbol.

Type definitions

SymbolInfo

Type definition

color

Property
Type
Color

The color of the symbol.

strokeColor

Property
Type
Color | undefined

The color of the symbol stroke.

baseWidth

Property
Type
number | undefined

The base width of the symbol in points.

strokeWidth

Property
Type
number | undefined

The stroke width of the symbol in points.

defaultHeight

Property
Type
number | undefined

The default height of the symbol.

primitiveOverrides

Property
Type
CIMPrimitiveOverride[] | null | undefined

The primitive overrides for the symbol.

symbolStyle

Property
Type
SpikeSymbolStyle | undefined

The style of the symbol.

SpikeSymbolStyle

Type definition
Type
"triangle-solid-fill-open-outline" | "triangle-solid-fill-closed-outline" | "triangle-solid-fill-open" | "triangle-solid-fill-closed" | "triangle-gradient-fill-open-outline" | "triangle-gradient-fill-closed-outline" | "triangle-gradient-fill-open" | "triangle-gradient-fill-closed" | "triangle-open-outline" | "triangle-closed-outline"