Options
All
  • Public
  • Public/Protected
  • All
Menu

Class LimitedColorPicker

Intended to return a color that is the same base color as another course that has the same ID, but differently interpolated. This allows related courses to have similar colors, eg the Lecture would be red, and the Recitation would be pale red.

Hierarchy

  • LimitedColorPicker

Index

Constructors

Properties

Methods

Constructors

constructor

Properties

S

S: number

S is the current basecolor's index.

colorscales

colorscales: any

A table of ColorScale with key coursecode (string) and value ColorScale.

colorset

colorset: string[]

An array of base colors to choose from.

Methods

copy

pickColor

  • pickColor(coursecode: string, sectionid: string): string
  • Pick a color for a given course and section.

    Parameters

    • coursecode: string

      If a color has already been allocated for a coursecode, this will pick a related color.

    • sectionid: string

      The sectionid determines how interpolated a color is chosen.

    Returns string

    A HexColor-compatible string.

Generated using TypeDoc