Usage
Signature:
interface CLegendItemElement
Typescript Import Format
//To typecheck the element APIs, import as below.
import { CLegendItemElement } from "oj-c/legend-item";
//For the transpiled javascript to load the element's module, import as below
import "oj-c/legend-item";
For additional information visit:
Attributes
-
border-color :string
-
The border color of the marker. Only applies if symbolType is "marker" or "lineWithMarker
- Default Value:
""
-
categories :Array.<string>
-
An array of categories for the legend item. Legend items currently only support a single category.
- Default Value:
[]
-
color :string
-
The color of the legend symbol (line or marker). When symbolType is "lineWithMarker", this attribute defines the line color and the markerColor attribute defines the marker color.
-
drilling :"inherit"|"off"|"on"
-
Whether drilling is enabled on the legend item. Drillable objects will show a pointer cursor on hover and fire ojDrill event on click. To enable drilling for all legend items at once, use the drilling attribute in the top level.
- Default Value:
"inherit"
Supported Values:
Value Description inheritThe drilling behavior is inherited from legend. offThe legend item will not be drillable. onThe legend item will be drillable. -
line-style :"dotted"|"dashed"|"solid"
-
The line style. Only applies when the symbolType is "line" or "lineWithMarker".
- Default Value:
"solid"
Supported Values:
Value Description dashedLine will have dashed strokes. dottedLine will have dotted strokes. solidLine will have a solid stroke. -
line-width :number
-
The line width in pixels. Only applies when the symbolType is "line" or "lineWithMarker.
-
marker-color :string
-
The color of the marker, if different than the line color. Only applies if the symbolType is "lineWithMarker".
-
marker-shape :"circle"|"diamond"|"ellipse"|"human"|"plus"|"rectangle"|"square"|"star"|"triangleDown"|"triangleUp"
-
The shape of the marker. Only applies if symbolType is "marker" or "lineWithMarker". Does not apply if a custom image is specified.
- Default Value:
"square"
Supported Values:
Value Description circleThe marker will be of circular shape. diamondThe marker will be of diamond shape. ellipseThe marker will be of ellipse shape. humanThe marker will be of human shape. plusThe marker will be of plus shape. rectangleThe marker will be of rectangular shape. squareThe marker will be of square shape. starThe marker will be of star shape. triangleDownThe marker will be of triangular shape facing down. triangleUpThe marker will be of triangular shape facing up. -
short-desc :string
-
The description of this legend item. This is used for accessibility and for customizing the tooltip text.
-
source :string
-
The URI of the image of the legend symbol.
-
symbol-type :"line"|"lineWithMarker"|"image"|"marker"
-
The type of legend symbol to display.
- Default Value:
"marker"
Supported Values:
Value Description imageThe legend symbol will be an image. lineThe legend symbol will be a line. lineWithMarkerThe legend symbol will be a line and a marker. markerThe legend symbol will be a marker. -
text* :string
-
The legend item text. Also used as item aria label if short-desc is not provided.