MCPcopy
hub / github.com/britecharts/britecharts

github.com/britecharts/britecharts @2.18.4 sqlite

repository ↗ · DeepWiki ↗ · release 2.18.4 ↗
773 symbols 1,715 edges 110 files 363 documented · 47%
README

Britecharts

Britecharts is a client-side reusable Charting Library based on D3.js v5 that offers easy and intuitive use of charts and components that can be composed together to create amazing visualizations.

Build Status npm version License PRs Welcome All Contributors Twitter Follow

[![Bar Chart][barchartimg]][barchartdemo] [![Line Chart][linechartimg]][linechartdemo] [![Donut Chart][donutchartimg]][donutchartdemo]
[![Stacked Bar Chart][stackedbarchartimg]][stackedbarchartdemo] [![Stacked Area Chart][stackedareachartlargeimg]][stackedareachartdemo] [![Grouped Bar Chart][groupedbarchartimg]][groupedbarchartdemo]
[![Sparkline Chart][sparklinechartimg]][sparklinechartdemo] [![Legend Chart][legendchartimg]][donutchartdemo] [![Brush Chart][brushchartimg]][brushchartdemo]

Britecharts components have been written in ES2016 with a Test Driven methodology, so they are fully tested, and we are committed to keeping them that way.

Key Features

  • Reusability
  • Composability
  • Great design

Usage

The typical use of Britecharts involves creating a chart using its simple API, then rendering it on a container which has previously had data applied to it. The code will look like this:

barChart
    .width(500)
    .height(300);

barContainer.datum(dataset).call(barChart);

API

All the components expose some common API methods like width, height, and margin. Additionally, each chart or component can expose specific methods you can find in the documentation:

  • API, [Demo][linechartdemo] Line Chart
  • API, [Demo][barchartdemo] Bar Chart
  • API, [Demo][donutchartdemo] Donut Chart
  • API, [Demo][stackedbarchartdemo] Stacked Bar Chart
  • [API][40], [Demo][groupedbarchartdemo] Grouped Bar Chart
  • [API][43], [Demo][bulletchartdemo] Bullet Chart
  • API, [Demo][brushchartdemo] Brush Chart
  • [API][41], [Demo][scatterplotdemo] Scatter Plot
  • API, [Demo][sparklinechartdemo] Sparkline Chart
  • API, [Demo][stackedareachartdemo] Stacked Area Chart
  • API, [Demo][stepchartdemo] Step Chart
  • API, [Demo][barchartdemo] Mini Tooltip
  • API, [Demo][linechartdemo] Tooltip
  • API, [Demo][donutchartdemo] Legend

Installation

Britecharts components are distributed in UMD modules, each one exposing a D3.js component written with the Reusable API pattern. To use any of the Britecharts modules, you will need to require the chart in your JS file using AMD/CommonJS modules or adding a script tag with the src pointing to the file. You would also need to load the d3-selection submodule to select the chart container.

   npm install britecharts d3-selection

You can also load Britecharts from our [CDN][cdnhome] as we do in this [demo][cdndemo] page or play around in our [JSBin][jsbinsandbox] and [CodePen][codependemos] demo projects.

They also provide some minimal CSS styling, that can be loaded independently or as a bundle. Check our [Styling Britecharts tutorial][stylingbritecharts] to see more options.

See Also

Community Roadmap

This project is in active development. We want your input about what is important, for that, add your votes using the 👍 reaction: * Top Feature Requests * Documentation Requests * Top Bugs

To give your feedback, you can open a new issue. You can also find us in the [D3.js slack group][d3slack], in the #britecharts channel. If you want to help, you can check the contributing guide.

If you work with Angular, check out [ngx-britecharts][angularwrapper] and their [demos][angularwrapperdemos]. We are also preparing a wrapper for React, and we will be talking about it on our [twitter][twitter].

Acknowledgments

[Sun Dai][sunsdribble] designs Britecharts, and two books inspired the code, Developing a D3.js Edge and Mastering D3.js. It also leveraged a significant number of examples and articles from the D3.js community overall.

Contributors ✨

Thanks goes to these wonderful people (emoji key):

Daler Asrorov 💻 📖 🤔 🚧 👀 ⚠️ Ryan Wholey 💻 📖 🤔 🚧 👀 ⚠️ jchen85 💻 🤔 🚧 👀 ⚠️ Marcos Gómez 💻 ajdani 🐛 💻 🚧 shayh 💻 Jay Clark 💻
Brendan Ratter 💻 🤔 Rajesh 💻 Alexis Crespo 💻 Gago 💻 🖋 🤔 🚇 🚧 👀 🔧 ⚠️

This project follows the all-contributors specification. Contributions of any kind are welcome!

License

Copyright 2019 Eventbrite

Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at

https://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.

Read more in the license document

Core symbols most depended-on inside this repo

a
called by 132
src/doc/template/static/scripts/docstrap.lib.js
c
called by 49
src/doc/template/static/scripts/docstrap.lib.js
_
called by 43
src/doc/template/static/scripts/docstrap.lib.js
b
called by 40
src/doc/template/static/scripts/docstrap.lib.js
generate
called by 32
src/doc/template/publish.js
e
called by 31
src/doc/template/static/scripts/docstrap.lib.js
d
called by 26
src/doc/template/static/scripts/docstrap.lib.js
i
called by 23
src/doc/template/static/scripts/docstrap.lib.js

Shape

Function 773

Languages

TypeScript100%

Modules by API surface

src/doc/template/static/scripts/prettify/jquery.min.js65 symbols
src/doc/template/static/scripts/docstrap.lib.js51 symbols
src/charts/stacked-area.js45 symbols
src/charts/line.js42 symbols
src/doc/template/static/scripts/sunlight.js40 symbols
src/charts/stacked-bar.js37 symbols
src/charts/bar.js37 symbols
src/charts/grouped-bar.js35 symbols
src/charts/scatter-plot.js31 symbols
src/charts/donut.js29 symbols
src/charts/tooltip.js22 symbols
sandbox/sandbox.js22 symbols

Dependencies from manifests, versioned

babel-core6.26.3 · 1×
babel-eslint7.2.3 · 1×
babel-istanbul0.12.2 · 1×
babel-loader7.1.2 · 1×
babel-polyfill6.26.0 · 1×
babel-preset-es20156.18.0 · 1×
babel-preset-stage-06.5.0 · 1×
base-640.1.0 · 1×
brace0.10.0 · 1×
concurrently4.1.0 · 1×
css-loader3.0.0 · 1×
d35.16.0 · 1×

For agents

$ claude mcp add britecharts \
  -- python -m otcore.mcp_server <graph>

⬇ download graph artifact