How to use the @swim/color.Color.transparent function in @swim/color

To help you get started, we’ve selected a few @swim/color examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github swimos / transit / ui / main / map / VehiclePopoverViewController.ts View on Github external
// chart container
    const accelChartContainer = chartsContainer.append("div");
    accelChartContainer.className('chartContainer');

    // speed chart
    const accelChartCanvas = accelChartContainer.append("canvas").height(200);
    const accelerationChart = new ChartView()
      .bottomAxis("time")
      .leftAxis("linear")
      .bottomGesture(false)
      .leftDomainPadding([0.1, 0.1])
      .topGutter(0)
      .rightGutter(0)
      .bottomGutter(0)
      .leftGutter(-1)
      .domainColor(Color.transparent(0))
      .tickMarkColor(Color.transparent(0));
    
      accelChartCanvas.append(accelerationChart);    

    this._accelerationPlot = new LineGraphView()
      .stroke(colorAgency)
      .strokeWidth(1);

    accelerationChart.addPlot(this._accelerationPlot);       

    // headerRow.append("span").key("routeTitle").text(vehicle.routeTitle);

    //console.info('vehicle', vehicle);
    // TODO: layout popover
  }
github swimos / transit / ui / main / map / VehiclePopoverViewController.ts View on Github external
const speedChartContainer = chartsContainer.append("div");
    speedChartContainer.className('chartContainer');

    // speed chart
    const speedChartCanvas = speedChartContainer.append("canvas").height(200);
    this._speedChart = new ChartView()
      .bottomAxis("time")
      .leftAxis("linear")
      .bottomGesture(false)
      .leftDomainPadding([0.1, 0.1])
      .topGutter(0)
      .rightGutter(0)
      .bottomGutter(0)
      .leftGutter(-1)
      .domainColor(Color.transparent(0))
      .tickMarkColor(Color.transparent(0));
    
    speedChartCanvas.append(this._speedChart);    

    this._speedPlot = new LineGraphView()
      .stroke(colorAgency)
      .strokeWidth(1);

    this._speedChart.addPlot(this._speedPlot);    
    
    // acceleration chart title
    const accelChartTitle = chartsContainer.append("h3").text("Acceleration");
    accelChartTitle.className("chartTitle");

    // chart container
    const accelChartContainer = chartsContainer.append("div");
    accelChartContainer.className('chartContainer');

@swim/color

RGB and HSL color types with color-space-aware operators, conversions, and parsers

Apache-2.0
Latest version published 5 years ago

Package Health Score

61 / 100
Full package analysis

Similar packages