Skip to content

LabelConfig

Example

ts
{
  color: '#555',
  fontFamily: 'Arial',
  fontSize: 12,
  fontWeight: 'normal',
  fontVariant: 'normal',
  fontStyle: 'normal'
}

Properties

color

  • Type: string
  • Default: '#555'

Specify the label text color using a CSS color string.

fontFamily

  • Type: string
  • Default: 'Arial'

fontSize

  • Type: number
  • Default: 12

Font size in pixels.

fontWeight

  • Type: 'normal' | 'bold' | 'bolder' | 'lighter' | number
  • Default: 'normal'

fontVariant

  • Type: 'normal' | 'small-caps'
  • Default: 'normal'

fontStyle

  • Type: 'normal' | 'italic' | 'oblique'
  • Default: 'normal'

TypeScript

ts
interface LabelConfig {
  color?: string;
  fontFamily?: string;
  fontSize?: number;
  fontWeight?: FontWeight;
  fontVariant?: FontVariant;
  fontStyle?: FontStyle;
}

React Candlesticks is available on npm and GitHub under the MIT License.