How soundar24/singledivui works
SingleDivUI is a browser charting library that renders line, bar, area, bubble, and scatter charts with CSS backgrounds and a single root DIV. The documented workflow is that a developer constructs a Chart for a DOM element with type, data, and options; Chart builds graph scales and a type-specific series, then applies generated styles to the page. The graph preserves the separate chart orchestration, axis/scaling, and series-rendering stages. README documents the chart-type and CSS customization capabilities; source excerpts show the core dispatch and rendering relationships, but not stylesheet imports or every style implementation.
Main entry points: series.js Series dispatch · chart.js Chart API · util.js Shared utilities · graph.js Graph layout
Components 14
Chart API
- Chart API
src/Chart/chart.js
Axes and scales
- Graph layout
src/Chart/graph.js - Linear scale
src/Chart/linear-scale.js
Chart renderers
- Series dispatch
src/Chart/series.js - Line renderer
src/Chart/line.js - Area renderer
src/Chart/area.js - Bar renderer
src/Chart/bar.js - Bubble renderer
src/Chart/bubble.js - Scatter renderer
src/Chart/scatter.js
DOM and styles
- DOM utilities
src/Base/dom-utill.js - Shared utilities
src/Base/util.js - Chart CSS
src/Chart/styles
Other components
- Developer
- Browser DOM
Connections 20
- Developer → Chart API: creates chart
README.md - Chart API → Graph layout: builds layout
src/Chart/chart.js - Chart API → Series dispatch: builds series
src/Chart/chart.js - Chart API → DOM utilities: injects styles
src/Chart/chart.js - Graph layout → Linear scale: generates scales
src/Chart/graph.js - Graph layout → DOM utilities: measures labels
src/Chart/graph.js - Graph layout → Shared utilities: converts settings
src/Chart/graph.js - Series dispatch → Line renderer: dispatches line
src/Chart/series.js - Series dispatch → Area renderer: dispatches area
src/Chart/series.js - Series dispatch → Bar renderer: dispatches bar
src/Chart/series.js - Series dispatch → Bubble renderer: dispatches bubble
src/Chart/series.js - Series dispatch → Scatter renderer: dispatches scatter
src/Chart/series.js - Series dispatch → Shared utilities: converts properties
src/Chart/series.js - Area renderer → Line renderer: delegates rendering
src/Chart/area.js - Scatter renderer → Bubble renderer: delegates rendering
src/Chart/scatter.js - Line renderer → Shared utilities: calculates positions
src/Chart/line.js - Bar renderer → Shared utilities: calculates positions
src/Chart/bar.js - Bubble renderer → Shared utilities: calculates positions
src/Chart/bubble.js - DOM utilities → Browser DOM: updates DOM
src/Base/dom-utill.js - Chart API → Chart CSS: uses chart styling