KodeKarsa UI

Charts

Line Chart

Up to four smooth lines you can read point by point with the pointer, touch, or arrow keys. New data morphs the lines instead of redrawing them.

src/components/charts/line-chart.tsxNo ui-sdk

Comparison and a metric switch

Pendaftaran per bulan, tahun ini dan tahun lalu
LabelTahun iniTahun lalu
Jan180140
Feb210152
Mar196150
Apr260171
Mei248180
Jun301176
Jul322198
Agu310205
Sep355210
Okt390232
Nov372240
Des428251

Geser kursor, sentuh, atau fokus lalu tekan panah untuk membaca setiap bulan.

Three apps

Pengguna aktif per minggu, tiga aplikasi
LabelKasirPasienArmada
M1420300120
M2480320150
M3510360170
M4560350210
M5590400220
M6650430260
M7700420290
M8740470300
M9810500340
M10880520360

Import

tsx
import { LineChart } from "@/components/charts/line-chart";

Guidelines

  • Labels at the end of each line replace a legend.
  • Use dashed for a previous period or a target, and area to bring the first line forward.
  • Swap in data with the same number of points so the lines morph smoothly.
  • The chart is an invisible native slider: Tab to focus, arrows to move between points, and each point is announced.