How klinecharts/pro works
KLineChart Pro is a configurable financial-chart UI built on KLineChart. The user selects a symbol and period, views chart data, and can adjust indicators, drawing overlays, appearance, timezone, and capture a screenshot. The main chart component coordinates the chart engine and its widgets; data access is abstracted behind a datafeed. The excerpts establish the component wiring and several widget interactions, but do not show the full chart-data request path or DefaultDatafeed implementation, so those links are not asserted.
Main entry points: ChartProComponent.tsx Chart component · index.ts Public API · index.tsx Drawing toolbar · DefaultDatafeed.ts Default datafeed
Components 19
Chart runtime
- Public API
src/index.ts - Chart interface
src/KLineChartPro.tsx - Chart component
src/ChartProComponent.tsx - KLineChart engine
- Default datafeed
src/DefaultDatafeed.ts
Chart controls
- Period bar
src/widget/period-bar/index.tsx - Symbol search
src/widget/symbol-search-modal/index.tsx - Indicator controls
src/widget/indicator-modal/index.tsx - Indicator settings
src/widget/indicator-setting-modal/index.tsx - Chart settings
src/widget/setting-modal/index.tsx - Timezone controls
src/widget/timezone-modal/index.tsx - Screenshot dialog
src/widget/screenshot-modal/index.tsx
Drawing tools
- Drawing toolbar
src/widget/drawing-bar/index.tsx - Drawing overlays
src/extension - Drawing icons
src/widget/drawing-bar/icons
Shared services
- UI components
src/component - Localization
src/i18n/index.ts
Other components
- Chart user
- Market data service
Connections 20
- Chart user → Public API: configures
- Public API → Chart interface: exports
src/index.ts - Public API → Drawing overlays: registers
src/index.ts - Public API → Default datafeed: exports
src/index.ts - Chart interface → Chart component: creates
src/KLineChartPro.tsx - Chart component → KLineChart engine: initializes
src/ChartProComponent.tsx - Chart component → Symbol search: renders
src/ChartProComponent.tsx - Chart component → Indicator controls: renders
src/ChartProComponent.tsx - Chart component → Indicator settings: renders
src/ChartProComponent.tsx - Chart component → Screenshot dialog: renders
src/ChartProComponent.tsx - Chart component → Period bar: uses
- Chart component → Drawing toolbar: uses
- Chart component → Chart settings: uses
- Chart component → Timezone controls: uses
- Drawing toolbar → Drawing icons: renders
src/widget/drawing-bar/index.tsx - Drawing toolbar → Drawing overlays: selects
- Chart component → UI components: uses
src/ChartProComponent.tsx - Chart component → Localization: uses
- Symbol search → Default datafeed: searches
src/widget/symbol-search-modal/index.tsx - Default datafeed → Market data service: fetches data