Skip to content

Commit 04c5aa7

Browse files
committed
docs: link Plotly/ECharts to their OSS docs; trim chart-datum comment
- analytics.md: make the Plotly and ECharts chart-library references links to plotly.com/javascript and echarts.apache.org; minor wording tidy (hardcode). - charts/types.ts: trim the ChartClickDatum doc comment. Co-authored-by: Isaac Signed-off-by: Atila Fassina <atila@fassina.eu>
1 parent 5c8114a commit 04c5aa7

2 files changed

Lines changed: 4 additions & 6 deletions

File tree

docs/docs/plugins/analytics.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -558,7 +558,7 @@ createApp({
558558
});
559559
```
560560

561-
This is **pure response decoration**: the injected metadata never enters the cache key and never changes the SQL. With it wired, every metric `result` message carries a `metadata` field scoped to the requested columns; without it, the message is byte-identical to a plain `/query` result and the hook's `metadata` is `undefined`. Because the metadata rides on the payload, the client never has to import the generated file or hard-code a format string — it is **payload-carried and client-agnostic**.
561+
This is **pure response decoration**: the injected metadata never enters the cache key and never changes the SQL. With it wired, every metric `result` message carries a `metadata` field scoped to the requested columns; without it, the message is byte-identical to a plain `/query` result and the hook's `metadata` is `undefined`. Because the metadata rides on the payload, the client never has to import the generated file or hardcode a format string — it is **payload-carried and client-agnostic**.
562562

563563
### Format utilities
564564

@@ -614,7 +614,7 @@ function RevenueTable() {
614614

615615
Because `metadata[col].format` is just a string on the payload, the same spec drives axis ticks and tooltips in any chart library.
616616

617-
**Plotly** — pass the spec straight through as a d3 `tickformat` / `hovertemplate` (Plotly axes speak d3-format):
617+
**[Plotly](https://plotly.com/javascript/)** — pass the spec straight through as a d3 `tickformat` / `hovertemplate` (Plotly axes speak d3-format):
618618

619619
```tsx
620620
import Plot from "react-plotly.js";
@@ -650,7 +650,7 @@ function RevenuePlot() {
650650
}
651651
```
652652

653-
**ECharts** — use the format spec inside `axisLabel.formatter` / `tooltip.formatter` via `formatValue`:
653+
**[ECharts](https://echarts.apache.org/)** — use the format spec inside `axisLabel.formatter` / `tooltip.formatter` via `formatValue`:
654654

655655
```tsx
656656
import ReactECharts from "echarts-for-react";

packages/appkit-ui/src/react/charts/types.ts

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -117,9 +117,7 @@ export interface ChartBaseProps {
117117
/**
118118
* A normalized description of a clicked chart element.
119119
*
120-
* This is the public, ECharts-free shape emitted by chart click handlers. It is
121-
* the single boundary that keeps ECharts event types out of appkit-ui's public
122-
* API — consumers should read the strongly-typed fields below and reach for
120+
* Consumers should read the strongly-typed fields below and reach for
123121
* {@link ChartClickDatum.raw} only when they knowingly opt into unsupported
124122
* internals.
125123
*

0 commit comments

Comments
 (0)