suiss/ui · Chart
Line Chart Dots
A weight trend with a dot at every monthly reading and a fixed value axis on the right.
Line Chart Dots is an open-source chart from suiss/ui for React, React Native, SwiftUI and Jetpack Compose. The @esuiss/ui CLI copies its source into your project, so you own the code.
A health-style weight card with a dot on every monthly reading and a fixed value axis on the right. The dots make it clear where measurements actually exist, so use this variant when readings are sparse or irregular.
Installation
CLI
Works in any project with a components.json. See Installation for the one-line registry setup. Or use the suiss/ui CLI:
Manual
- Install the dependencies:
-
Copy the source into
components/charts/line-chart-dots.tsx:
- Update the import paths to match your project.
Usage
Replace the list of readings in chartData and rename weight in the data, the line and chartConfig. Set the value axis domain and ticks to a range that suits your numbers, and change the unit in the tooltip formatter.
Notes
The headline value and the change below it are hard-coded text, so update them along with the data or compute them from it.

Ten monthly weights drawn with type="linear" and a dot on every reading, plus a larger dot for the touched point. A value axis on the right covers a fixed range, and the tooltip formats values in kilograms. The header shows the latest weight and the change since January as static text.
Installation
The CLI also adds what it builds on: Card, Chart, Text.
Manual
-
Target iOS 17 or later.
-
Copy the theme files every view uses:
- Copy the source and every file it uses:
- Add the files to your app target.
- Set
minSdkto 24 or higher and add the dependencies:
- Copy the theme files every view uses:
- Copy the source and every file it uses:
- Update the
com.esuiss.uipackage names to match your project.
Usage
Replace the weight array in chartData and update the header text to match. Adjust the YAxis domain and ticks for your range. The component takes no props.
