How to use the @patternfly/react-charts.ChartThemeVariant.light function in @patternfly/react-charts

To help you get started, we’ve selected a few @patternfly/react-charts 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 patternfly / patternfly-react / packages / patternfly-4 / react-integration / demo-app-ts / src / components / demos / DonutUtilizationChartDemo / DonutUtilizationSimpleRightGreenDemo.tsx View on Github external
data={{ x: 'Storage capacity', y: used }}
            height={300}
            labels={({ datum }) => (datum.x ? `${datum.x}: ${datum.y}%` : null)}
            legendData={[{ name: `Storage capacity: ${spacer}${used}%` }, { name: 'Unused' }]}
            legendOrientation="vertical"
            legendPosition="bottom"
            padding={{
              bottom: 75, // Adjusted to accommodate legend
              left: 8,
              right: 8,
              top: 8
            }}
            subTitle="of 100 GBps"
            title={`${used}%`}
            themeColor={ChartThemeColor.green}
            themeVariant={ChartThemeVariant.light}
            thresholds={[{ value: 60 }, { value: 90 }]}
            width={230}
          />
        
      
    );
  }
}
github patternfly / patternfly-react / packages / patternfly-4 / react-integration / demo-app-ts / src / components / demos / DonutChartDemo / DonutRightAlignedLegendColorDemo.tsx View on Github external
render() {
    return (
      <div>
        <div style="{{">
           `${datum.x}: ${datum.y}%`}
            legendData={[{ name: 'Cats: 35' }, { name: 'Dogs: 55' }, { name: 'Birds: 10' }]}
            legendOrientation="vertical"
            legendPosition="right"
            subTitle="Pets"
            title="100"
            themeColor={ChartThemeColor.multi}
            themeVariant={ChartThemeVariant.light}
            width={350}
          /&gt;
        </div>
      </div>
    );
  }
}
github patternfly / patternfly-react / packages / patternfly-4 / react-integration / demo-app-ts / src / components / demos / DonutUtilizationChartDemo / DonutUtilizationGreenStaticRightDemo.tsx View on Github external
legendPosition="bottom"
            width={230}
          &gt;
             (datum.x ? `${datum.x}: ${datum.y}%` : null)}
              legendData={[
                { name: `Storage capacity: ${used}%` },
                { name: 'Warning threshold at 60%' },
                { name: 'Danger threshold at 90%' }
              ]}
              legendOrientation="vertical"
              subTitle="of 100 GBps"
              title={`${used}%`}
              themeColor={ChartThemeColor.green}
              themeVariant={ChartThemeVariant.light}
              thresholds={[{ value: 60 }, { value: 90 }]}
            /&gt;
          
        
      
    );
  }
}
github openshift / console / frontend / packages / noobaa-storage-plugin / src / components / capacity-card / capacity-card-body.tsx View on Github external
}
  const totalHumanized = humanizeBinaryBytesWithoutB(totalUsage, null, totalUsage ? null : 'MiB');
  return (
    <div>
      <div>
         `${datum.x}: ${humanizePercentage(totalUsage ? datum.y : 0).string}`}
          themeColor={ChartThemeColor.multi}
          themeVariant={ChartThemeVariant.light}
          title={totalHumanized.string}
        /&gt;
      </div>
    </div>
  );
};