@cascivo/charts 0.17.0 → 0.18.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/dist/index.d.ts +30 -2
  2. package/package.json +3 -3
package/dist/index.d.ts CHANGED
@@ -2004,12 +2004,18 @@ interface SparklineBaseProps {
2004
2004
  * 120px rather than a container-filling chart. Pass a number to change it. The
2005
2005
  * catalogue-wide "omit for a responsive chart" note does not apply to this chart.
2006
2006
  *
2007
- * @defaultValue `80`
2007
+ * @defaultValue `120`
2008
2008
  * @see the component manifest
2009
2009
  */
2010
2010
  width?: number;
2011
2011
  height?: number;
2012
2012
  color?: string;
2013
+ /**
2014
+ * Show dot at last data point
2015
+ *
2016
+ * @defaultValue `true`
2017
+ * @see the component manifest
2018
+ */
2013
2019
  endDot?: boolean;
2014
2020
  }
2015
2021
  /**
@@ -2118,6 +2124,23 @@ interface KpiProps {
2118
2124
  sparkline?: readonly number[];
2119
2125
  className?: string;
2120
2126
  }
2127
+ /**
2128
+ * A metric tile with its own card chrome: label, then value and delta on one line, then an
2129
+ * optional sparkline below.
2130
+ *
2131
+ * ## `Kpi` or `Stat`? Pick one per app.
2132
+ *
2133
+ * `Stat` (`@cascivo/react`) is the sibling tile, and they are **not two skins of one
2134
+ * component**. `Kpi` takes a numeric `delta` and formats it for you (sign, arrow, colour,
2135
+ * unit) and always brings card chrome. `Stat` takes a pre-formatted `string` delta, stacks
2136
+ * value → delta → help text, puts its `visual` in a trailing slot, and is layout-only unless
2137
+ * you set `card`.
2138
+ *
2139
+ * `<Stat card>` matches this component's **chrome** — surface, border, radius, padding — and
2140
+ * not its layout, so a `Stat` row and a `Kpi` row in one app still read as two tile designs
2141
+ * (2026-08-14 report §6). Use `Kpi` when you have a numeric delta and a sparkline; use `Stat`
2142
+ * otherwise; do not mix them.
2143
+ */
2121
2144
  declare function Kpi({
2122
2145
  value,
2123
2146
  label,
@@ -2299,7 +2322,12 @@ interface ComboChartProps {
2299
2322
  line: ComboChartPoint[];
2300
2323
  title: string;
2301
2324
  description?: string;
2302
- /** Measure the line on its own right-hand axis (use when the two metrics differ in scale). */
2325
+ /**
2326
+ * Render line on a secondary right y-axis
2327
+ *
2328
+ * @defaultValue `false`
2329
+ * @see the component manifest
2330
+ */
2303
2331
  secondAxis?: boolean;
2304
2332
  /** Legend label for the bar series. Defaults to `'Bars'`. */
2305
2333
  barsLabel?: string;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@cascivo/charts",
3
- "version": "0.17.0",
3
+ "version": "0.18.0",
4
4
  "private": false,
5
5
  "description": "Chart components built from scratch — scales, shapes, and signal-driven rendering, zero dependencies. Colors come from @cascivo/themes; components from @cascivo/react. Docs offline: npx @cascivo/docs",
6
6
  "keywords": [
@@ -45,8 +45,8 @@
45
45
  "provenance": true
46
46
  },
47
47
  "dependencies": {
48
- "@cascivo/core": "^0.17.0",
49
- "@cascivo/i18n": "^0.17.0"
48
+ "@cascivo/core": "^0.18.0",
49
+ "@cascivo/i18n": "^0.18.0"
50
50
  },
51
51
  "devDependencies": {
52
52
  "@preact/signals": "^2",