@bicharts/chart-host 0.6.64 → 0.6.66

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.
@@ -1107,7 +1107,16 @@ function resolveOptions(p4) {
1107
1107
  // blank must arrive as ABSENT, not as an empty string, because the chart's fallback is
1108
1108
  // `options.cardBackgroundColor || <its own choice>` and "" would satisfy a truthiness
1109
1109
  // test in some hands while painting nothing in others.
1110
- cardBackgroundColor: p4.cardBackgroundColor || void 0
1110
+ cardBackgroundColor: p4.cardBackgroundColor || void 0,
1111
+ // A reader's on / off, or UNSET - never filled with false, for the flipIntervalMs reason: the
1112
+ // default is the chart's (on only where its request asked for drop lines), and a host that
1113
+ // turned unset into false would make that default unreachable. Pane choices arrive as text.
1114
+ hoverDropLines: (() => {
1115
+ const v = p4.hoverDropLines;
1116
+ if (typeof v === "boolean") return v;
1117
+ const s2 = v == null ? "" : String(v).trim().toLowerCase();
1118
+ return s2 === "on" || s2 === "true" || s2 === "1" ? true : s2 === "off" || s2 === "false" || s2 === "0" ? false : void 0;
1119
+ })()
1111
1120
  };
1112
1121
  }
1113
1122
 
@@ -1763,7 +1772,7 @@ function Fn(n, s2) {
1763
1772
  return { iso: o4, unmatched: I2, matchedRows: N, totalRows: n.length };
1764
1773
  }
1765
1774
 
1766
- // ../shape-core/dist/chunk-TBB6BEZ7.mjs
1775
+ // ../shape-core/dist/chunk-OPDY2YEA.mjs
1767
1776
  var import_papaparse = __toESM(require_papaparse_min(), 1);
1768
1777
  /*! @bicharts/shape-core — Apache-2.0. Bundled reference data: GeoNames (https://www.geonames.org/) CC BY 4.0; US Census/TIGER (public domain). Full text: NOTICE in this package. */
1769
1778
  var ze = { "north-america": "AG AI AW BB BL BM BQ BS BZ CA CR CU CW DM DO GD GL GP GT HN HT JM KN KY LC MF MQ MS MX NI PA PM PR SV SX TC TT US VC VG VI", "south-america": "AR BO BR CL CO EC FK GF GY PE PY SR UY VE", europe: "AD AL AT AX BA BE BG BY CH CY CZ DE DK EE ES FI FO FR GB GG GI GR HR HU IE IM IS IT JE LI LT LU LV MC MD ME MK MT NL NO PL PT RO RS RU SE SI SJ SK SM UA VA", africa: "AO BF BI BJ BW CD CF CG CI CM CV DJ DZ EG EH ER ET GA GH GM GN GQ GW KE KM LR LS LY MA MG ML MR MU MW MZ NA NE NG RE RW SC SD SH SL SN SO SS ST SZ TD TG TN TZ UG YT ZA ZM ZW", asia: "AE AF AM AZ BD BH BN BT CC CN CX GE HK ID IL IN IO IQ IR JO JP KG KH KP KR KW KZ LA LB LK MM MN MO MV MY NP OM PH PK PS QA SA SG SY TH TJ TL TM TR TW UZ VN YE", oceania: "AS AU CK FJ FM GU KI MH MP NC NF NR NU NZ PF PG PN PW SB TK TO TV UM VU WF WS", antarctica: "AQ BV GS HM TF" };
@@ -1869,7 +1878,7 @@ var Yt = new RegExp([String.raw`\bisMeasure\b`, String.raw`\bdataType\b`, String
1869
1878
  /*! @bicharts/shape-core — Apache-2.0. Bundled reference data: GeoNames (https://www.geonames.org/) CC BY 4.0; US Census/TIGER (public domain). Full text: NOTICE in this package. */
1870
1879
  var Z3 = 2;
1871
1880
  var me2 = 400;
1872
- function ee3(t) {
1881
+ function te(t) {
1873
1882
  return !!k(t);
1874
1883
  }
1875
1884
  function F3(t) {
@@ -1883,8 +1892,8 @@ function F3(t) {
1883
1892
  }
1884
1893
  function A2(t) {
1885
1894
  let e = F3(t);
1886
- if (e.length === 0 || te(t) < 95) return false;
1887
- let n = e.filter((u4) => ee3(u4) && !t3(u4)).length, o4 = e.filter((u4) => !ee3(u4) && !!t3(u4)).length;
1895
+ if (e.length === 0 || ne2(t) < 95) return false;
1896
+ let n = e.filter((u4) => te(u4) && !t3(u4)).length, o4 = e.filter((u4) => !te(u4) && !!t3(u4)).length;
1888
1897
  return n >= 1 && n >= o4;
1889
1898
  }
1890
1899
  function ce3(t, e) {
@@ -1892,11 +1901,11 @@ function ce3(t, e) {
1892
1901
  let n = k(t);
1893
1902
  return n ? e === "world" ? true : G3.has(n) : false;
1894
1903
  }
1895
- function te(t) {
1904
+ function ne2(t) {
1896
1905
  let e = F3(t);
1897
1906
  if (e.length === 0) return 0;
1898
1907
  let n = 0;
1899
- for (let o4 of e) ee3(o4) && n++;
1908
+ for (let o4 of e) te(o4) && n++;
1900
1909
  return Math.round(n / e.length * 1e3) / 10;
1901
1910
  }
1902
1911
  function z2(t) {
@@ -1906,7 +1915,7 @@ function z2(t) {
1906
1915
  for (let o4 of e) t3(o4) && n++;
1907
1916
  return Math.round(n / e.length * 1e3) / 10;
1908
1917
  }
1909
- function re2(t) {
1918
+ function oe2(t) {
1910
1919
  let e = /* @__PURE__ */ new Set();
1911
1920
  for (let n of t) {
1912
1921
  if (n == null) continue;
@@ -1915,15 +1924,15 @@ function re2(t) {
1915
1924
  }
1916
1925
  return Array.from(e);
1917
1926
  }
1918
- function ne2(t) {
1919
- let e = re2(t);
1927
+ function re2(t) {
1928
+ let e = oe2(t);
1920
1929
  if (e.length === 0) return 0;
1921
1930
  let n = 0;
1922
1931
  for (let o4 of e) r3(o4).length > 0 && n++;
1923
1932
  return Math.round(n / e.length * 1e3) / 10;
1924
1933
  }
1925
1934
  function de(t, e) {
1926
- return y(e, fn) ? true : re2(t).some((n) => /^\d{5}(-\d{4})?$/.test(n.replace(/\.0+$/, "")));
1935
+ return y(e, fn) ? true : oe2(t).some((n) => /^\d{5}(-\d{4})?$/.test(n.replace(/\.0+$/, "")));
1927
1936
  }
1928
1937
  function Bn2(t, e) {
1929
1938
  let n = F3(t);
@@ -1932,54 +1941,54 @@ function Bn2(t, e) {
1932
1941
  for (let u4 of n) j3(u4, e) && o4++;
1933
1942
  return Math.round(o4 / n.length * 1e3) / 10;
1934
1943
  }
1935
- function J5(t, e) {
1944
+ function ee3(t, e) {
1936
1945
  let n = 0;
1937
1946
  for (let o4 of F3(t)) e(o4) && n++;
1938
1947
  return n;
1939
1948
  }
1940
1949
  function jn(t, e) {
1941
1950
  let n = 0;
1942
- for (let o4 of re2(t)) e(o4) && n++;
1951
+ for (let o4 of oe2(t)) e(o4) && n++;
1943
1952
  return n;
1944
1953
  }
1945
1954
  function Yn3(t, e, n, o4, u4) {
1946
- let l2 = [], a3 = [], i = {}, b4 = {}, E4 = new Set(t), y2 = (s2) => e.map((c2) => c2[s2]);
1955
+ let l2 = [], a3 = [], i = {}, h4 = {}, C2 = new Set(t), y2 = (s2) => e.map((d2) => d2[s2]);
1947
1956
  for (let s2 of ["city", "country"]) {
1948
- let c2 = n?.[s2];
1949
- c2 && E4.has(c2) && (i[s2] = c2);
1957
+ let d2 = n?.[s2];
1958
+ d2 && C2.has(d2) && (i[s2] = d2);
1950
1959
  }
1951
1960
  let g5 = new Set(u4 ?? t);
1952
1961
  for (let s2 of ["lat", "lon"]) {
1953
- let c2 = n?.[s2];
1954
- c2 && g5.has(c2) && (i[s2] = c2);
1962
+ let d2 = n?.[s2];
1963
+ d2 && g5.has(d2) && (i[s2] = d2);
1955
1964
  }
1956
1965
  let f4 = n?.zip;
1957
- if (f4 && E4.has(f4)) {
1958
- let s2 = y2(f4), c2 = ne2(s2);
1959
- c2 < 95 ? a3.push(`zip=${f4} (only ${c2}% of values read as ZIPs)`) : de(s2, f4) ? i.zip = f4 : a3.push(`zip=${f4} (all values are 3-4 digits with nothing to say they are postal)`);
1966
+ if (f4 && C2.has(f4)) {
1967
+ let s2 = y2(f4), d2 = re2(s2);
1968
+ d2 < 95 ? a3.push(`zip=${f4} (only ${d2}% of values read as ZIPs)`) : de(s2, f4) ? i.zip = f4 : a3.push(`zip=${f4} (all values are 3-4 digits with nothing to say they are postal)`);
1960
1969
  }
1961
- let d2 = n?.state;
1962
- if (d2 && E4.has(d2)) {
1963
- let s2 = y2(d2), c2 = F3(s2);
1964
- c2.length > 0 && c2.every((S2) => ce3(S2, o4)) ? a3.push(`state=${d2} (every value is "CA", which is both Canada and California)`) : A2(s2) ? (a3.push(`state=${d2} (every value is a country, not a state)`), i.country || (i.country = d2)) : z2(s2) < 95 ? a3.push(`state=${d2} (only ${z2(s2)}% of values are states/provinces)`) : i.state = d2;
1970
+ let c2 = n?.state;
1971
+ if (c2 && C2.has(c2)) {
1972
+ let s2 = y2(c2), d2 = F3(s2);
1973
+ d2.length > 0 && d2.every((S2) => ce3(S2, o4)) ? a3.push(`state=${c2} (every value is "CA", which is both Canada and California)`) : A2(s2) ? (a3.push(`state=${c2} (every value is a country, not a state)`), i.country || (i.country = c2)) : z2(s2) < 95 ? a3.push(`state=${c2} (only ${z2(s2)}% of values are states/provinces)`) : i.state = c2;
1965
1974
  }
1966
- let p4 = new Set(Object.values(i).filter(Boolean)), h4 = t.filter((s2) => !p4.has(s2) && !s2.startsWith("__"));
1975
+ let p4 = new Set(Object.values(i).filter(Boolean)), b4 = t.filter((s2) => !p4.has(s2) && !s2.startsWith("__"));
1967
1976
  if (!i.state) {
1968
1977
  let s2 = null;
1969
- for (let c2 of h4) {
1970
- let S2 = y2(c2);
1978
+ for (let d2 of b4) {
1979
+ let S2 = y2(d2);
1971
1980
  if (A2(S2)) continue;
1972
- let P4 = z2(S2);
1973
- if (P4 < 95) continue;
1974
- let K3 = J5(S2, (D2) => !!t3(D2)), Ne = J5(S2, (D2) => !!t3(D2) && !ce3(D2, o4));
1975
- K3 < Z3 && Ne < 1 || (!s2 || P4 > s2.pct) && (s2 = { name: c2, pct: P4 });
1981
+ let _4 = z2(S2);
1982
+ if (_4 < 95) continue;
1983
+ let H2 = ee3(S2, (D2) => !!t3(D2)), Ne = ee3(S2, (D2) => !!t3(D2) && !ce3(D2, o4));
1984
+ H2 < Z3 && Ne < 1 || (!s2 || _4 > s2.pct) && (s2 = { name: d2, pct: _4 });
1976
1985
  }
1977
1986
  s2 && (i.state = s2.name, p4.add(s2.name), l2.push(`state=${s2.name} (${s2.pct}% states/provinces)`));
1978
1987
  }
1979
- if (!i.zip) for (let s2 of h4) {
1988
+ if (!i.zip) for (let s2 of b4) {
1980
1989
  if (p4.has(s2)) continue;
1981
- let c2 = y2(s2), S2 = ne2(c2);
1982
- if (!(S2 < 95) && de(c2, s2) && !(jn(c2, (P4) => r3(P4).length > 0) < Z3)) {
1990
+ let d2 = y2(s2), S2 = re2(d2);
1991
+ if (!(S2 < 95) && de(d2, s2) && !(jn(d2, (_4) => r3(_4).length > 0) < Z3)) {
1983
1992
  i.zip = s2, p4.add(s2), l2.push(`zip=${s2} (${S2}% ZIP codes)`);
1984
1993
  break;
1985
1994
  }
@@ -1987,31 +1996,31 @@ function Yn3(t, e, n, o4, u4) {
1987
1996
  let T = i.country;
1988
1997
  if (!T || !A2(y2(T))) {
1989
1998
  let s2 = null;
1990
- for (let c2 of h4) {
1991
- if (p4.has(c2) || !A2(y2(c2))) continue;
1992
- let S2 = te(y2(c2));
1993
- (!s2 || S2 > s2.pct) && (s2 = { name: c2, pct: S2 });
1999
+ for (let d2 of b4) {
2000
+ if (p4.has(d2) || !A2(y2(d2))) continue;
2001
+ let S2 = ne2(y2(d2));
2002
+ (!s2 || S2 > s2.pct) && (s2 = { name: d2, pct: S2 });
1994
2003
  }
1995
- s2 && (T && (a3.push(`country=${T} (only ${te(y2(T))}% of values are country identifiers; using ${s2.name} instead)`), b4.country = T), i.country = s2.name, p4.add(s2.name), l2.push(`country=${s2.name}`));
2004
+ s2 && (T && (a3.push(`country=${T} (only ${ne2(y2(T))}% of values are country identifiers; using ${s2.name} instead)`), h4.country = T), i.country = s2.name, p4.add(s2.name), l2.push(`country=${s2.name}`));
1996
2005
  }
1997
2006
  if (!i.city) {
1998
2007
  let s2 = null;
1999
- for (let c2 of h4) {
2000
- if (p4.has(c2)) continue;
2001
- let S2 = y2(c2), P4 = Bn2(S2, o4);
2002
- P4 < D3 || J5(S2, (K3) => j3(K3, o4)) < Z3 || (!s2 || P4 > s2.pct) && (s2 = { name: c2, pct: P4 });
2008
+ for (let d2 of b4) {
2009
+ if (p4.has(d2)) continue;
2010
+ let S2 = y2(d2), _4 = Bn2(S2, o4);
2011
+ _4 < D3 || ee3(S2, (H2) => j3(H2, o4)) < Z3 || (!s2 || _4 > s2.pct) && (s2 = { name: d2, pct: _4 });
2003
2012
  }
2004
2013
  s2 && (i.city = s2.name, l2.push(`city=${s2.name} (${s2.pct}% known cities)`));
2005
2014
  }
2006
2015
  let L4 = i.country ? y2(i.country) : [], R4 = !!i.country && A2(L4), M2 = R4 ? new Set(L4.map((s2) => k(s2 == null ? null : String(s2))).filter(Boolean)).size : 0, x3 = R4 && M2 >= 2, w3 = !!(i.lat && i.lon) && e.some((s2) => {
2007
- let c2 = +String(s2[i.lat] ?? "").trim(), S2 = +String(s2[i.lon] ?? "").trim();
2008
- return isFinite(c2) && isFinite(S2) && c2 >= -90 && c2 <= 90 && S2 >= -180 && S2 <= 180 && String(s2[i.lat] ?? "").trim() !== "" && String(s2[i.lon] ?? "").trim() !== "";
2016
+ let d2 = +String(s2[i.lat] ?? "").trim(), S2 = +String(s2[i.lon] ?? "").trim();
2017
+ return isFinite(d2) && isFinite(S2) && d2 >= -90 && d2 <= 90 && S2 >= -180 && S2 <= 180 && String(s2[i.lat] ?? "").trim() !== "" && String(s2[i.lon] ?? "").trim() !== "";
2009
2018
  });
2010
- return i.lat && i.lon && !w3 && a3.push(`lat/lon=${i.lat}/${i.lon} (no row holds a usable coordinate pair)`), i.country && !x3 && !(i.city || i.state || i.zip || w3) && a3.push(R4 ? `country=${i.country} (every row resolves to the same country - nothing to place apart)` : `country=${i.country} (values are not country identifiers)`), { bind: !!(i.city || i.state || i.zip || x3 || w3) ? i : null, backfilled: l2, refused: a3, ...Object.keys(b4).length ? { labelFallback: b4 } : {} };
2019
+ return i.lat && i.lon && !w3 && a3.push(`lat/lon=${i.lat}/${i.lon} (no row holds a usable coordinate pair)`), i.country && !x3 && !(i.city || i.state || i.zip || w3) && a3.push(R4 ? `country=${i.country} (every row resolves to the same country - nothing to place apart)` : `country=${i.country} (values are not country identifiers)`), { bind: !!(i.city || i.state || i.zip || x3 || w3) ? i : null, backfilled: l2, refused: a3, ...Object.keys(h4).length ? { labelFallback: h4 } : {} };
2011
2020
  }
2012
2021
  var r = (t, ...e) => ({ part: t, langs: Object.freeze(e) });
2013
- var oe2 = Object.freeze({ jaar: r("year", "nl"), kwartaal: r("quarter", "nl"), maand: r("month", "nl"), dag: r("day", "nl", "sv", "da", "nb"), jahr: r("year", "de"), quartal: r("quarter", "de"), monat: r("month", "de"), tag: r("day", "de"), ann\u00E9e: r("year", "fr"), mois: r("month", "fr"), jour: r("day", "fr"), trimestre: r("quarter", "fr", "es", "pt", "it"), a\u00F1o: r("year", "es"), mes: r("month", "es"), d\u00EDa: r("day", "es"), ano: r("year", "pt"), m\u00EAs: r("month", "pt"), dia: r("day", "pt"), anno: r("year", "it"), mese: r("month", "it"), giorno: r("day", "it"), \u0433\u043E\u0434: r("year", "ru"), \u043C\u0435\u0441\u044F\u0446: r("month", "ru"), \u0440\u0456\u043A: r("year", "uk"), \u043C\u0456\u0441\u044F\u0446\u044C: r("month", "uk"), \u043A\u0432\u0430\u0440\u0442\u0430\u043B: r("quarter", "ru", "uk"), \u0434\u0435\u043D\u044C: r("day", "ru", "uk"), rok: r("year", "pl", "cs", "sk"), kwarta\u0142: r("quarter", "pl"), miesi\u0105c: r("month", "pl"), dzie\u0144: r("day", "pl"), \u010Dtvrtlet\u00ED: r("quarter", "cs"), m\u011Bs\u00EDc: r("month", "cs"), den: r("day", "cs"), \u0161tvr\u0165rok: r("quarter", "sk"), mesiac: r("month", "sk"), de\u0148: r("day", "sk"), \u00E5r: r("year", "sv", "da", "nb"), kvartal: r("quarter", "sv", "da", "nb"), m\u00E5nad: r("month", "sv"), m\u00E5ned: r("month", "da", "nb"), vuosi: r("year", "fi"), vuosinelj\u00E4nnes: r("quarter", "fi"), kuukausi: r("month", "fi"), p\u00E4iv\u00E4: r("day", "fi"), \u00E9v: r("year", "hu"), negyed\u00E9v: r("quarter", "hu"), h\u00F3nap: r("month", "hu"), nap: r("day", "hu"), y\u0131l: r("year", "tr"), \u00E7eyrek: r("quarter", "tr"), ay: r("month", "tr"), g\u00FCn: r("day", "tr"), \u03AD\u03C4\u03BF\u03C2: r("year", "el"), \u03C4\u03C1\u03AF\u03BC\u03B7\u03BD\u03BF: r("quarter", "el"), \u03BC\u03AE\u03BD\u03B1\u03C2: r("month", "el"), \u03B7\u03BC\u03AD\u03C1\u03B1: r("day", "el"), an: r("year", "ro"), trimestru: r("quarter", "ro"), lun\u0103: r("month", "ro"), zi: r("day", "ro"), godina: r("year", "hr"), tromjese\u010Dje: r("quarter", "hr"), mjesec: r("month", "hr"), dan: r("day", "hr"), \u5E74: r("year", "ja", "zh"), \u56DB\u534A\u671F: r("quarter", "ja"), \u5B63\u5EA6: r("quarter", "zh"), \u6708: r("month", "ja", "zh"), \u65E5: r("day", "ja", "zh"), \uC5F0\uB3C4: r("year", "ko"), \uBD84\uAE30: r("quarter", "ko"), \uC6D4: r("month", "ko"), \uC77C: r("day", "ko"), tahun: r("year", "id"), kuartal: r("quarter", "id"), triwulan: r("quarter", "id"), bulan: r("month", "id"), hari: r("day", "id"), n\u0103m: r("year", "vi"), qu\u00FD: r("quarter", "vi"), th\u00E1ng: r("month", "vi"), ng\u00E0y: r("day", "vi"), \u0E1B\u0E35: r("year", "th"), \u0E44\u0E15\u0E23\u0E21\u0E32\u0E2A: r("quarter", "th"), \u0E40\u0E14\u0E37\u0E2D\u0E19: r("month", "th"), \u0E27\u0E31\u0E19: r("day", "th"), \u0627\u0644\u0633\u0646\u0629: r("year", "ar"), \u0633\u0646\u0629: r("year", "ar"), \u0627\u0644\u0639\u0627\u0645: r("year", "ar"), \u0639\u0627\u0645: r("year", "ar"), \u0627\u0644\u0631\u0628\u0639: r("quarter", "ar"), \u0631\u0628\u0639: r("quarter", "ar"), "\u0631\u0628\u0639 \u0627\u0644\u0633\u0646\u0629": r("quarter", "ar"), \u0627\u0644\u0634\u0647\u0631: r("month", "ar"), \u0634\u0647\u0631: r("month", "ar"), \u0627\u0644\u064A\u0648\u0645: r("day", "ar"), \u064A\u0648\u0645: r("day", "ar"), \u05E9\u05E0\u05D4: r("year", "he"), \u05E8\u05D1\u05E2\u05D5\u05DF: r("quarter", "he"), \u05D7\u05D5\u05D3\u05E9: r("month", "he"), \u05D9\u05D5\u05DD: r("day", "he"), \u0935\u0930\u094D\u0937: r("year", "hi"), \u0938\u093E\u0932: r("year", "hi"), \u0924\u093F\u092E\u093E\u0939\u0940: r("quarter", "hi"), \u092E\u0939\u0940\u0928\u093E: r("month", "hi"), \u092E\u093E\u0939: r("month", "hi"), \u0926\u093F\u0928: r("day", "hi"), \u0633\u0627\u0644: r("year", "fa"), \u0645\u0627\u0647: r("month", "fa"), \u0631\u0648\u0632: r("day", "fa") });
2014
- var Qn2 = Object.freeze(Array.from(new Set(Object.values(oe2).flatMap((t) => t.langs))));
2022
+ var ie2 = Object.freeze({ jaar: r("year", "nl"), kwartaal: r("quarter", "nl"), maand: r("month", "nl"), dag: r("day", "nl", "sv", "da", "nb"), jahr: r("year", "de"), quartal: r("quarter", "de"), monat: r("month", "de"), tag: r("day", "de"), ann\u00E9e: r("year", "fr"), mois: r("month", "fr"), jour: r("day", "fr"), trimestre: r("quarter", "fr", "es", "pt", "it"), a\u00F1o: r("year", "es"), mes: r("month", "es"), d\u00EDa: r("day", "es"), ano: r("year", "pt"), m\u00EAs: r("month", "pt"), dia: r("day", "pt"), anno: r("year", "it"), mese: r("month", "it"), giorno: r("day", "it"), \u0433\u043E\u0434: r("year", "ru"), \u043C\u0435\u0441\u044F\u0446: r("month", "ru"), \u0440\u0456\u043A: r("year", "uk"), \u043C\u0456\u0441\u044F\u0446\u044C: r("month", "uk"), \u043A\u0432\u0430\u0440\u0442\u0430\u043B: r("quarter", "ru", "uk"), \u0434\u0435\u043D\u044C: r("day", "ru", "uk"), rok: r("year", "pl", "cs", "sk"), kwarta\u0142: r("quarter", "pl"), miesi\u0105c: r("month", "pl"), dzie\u0144: r("day", "pl"), \u010Dtvrtlet\u00ED: r("quarter", "cs"), m\u011Bs\u00EDc: r("month", "cs"), den: r("day", "cs"), \u0161tvr\u0165rok: r("quarter", "sk"), mesiac: r("month", "sk"), de\u0148: r("day", "sk"), \u00E5r: r("year", "sv", "da", "nb"), kvartal: r("quarter", "sv", "da", "nb"), m\u00E5nad: r("month", "sv"), m\u00E5ned: r("month", "da", "nb"), vuosi: r("year", "fi"), vuosinelj\u00E4nnes: r("quarter", "fi"), kuukausi: r("month", "fi"), p\u00E4iv\u00E4: r("day", "fi"), \u00E9v: r("year", "hu"), negyed\u00E9v: r("quarter", "hu"), h\u00F3nap: r("month", "hu"), nap: r("day", "hu"), y\u0131l: r("year", "tr"), \u00E7eyrek: r("quarter", "tr"), ay: r("month", "tr"), g\u00FCn: r("day", "tr"), \u03AD\u03C4\u03BF\u03C2: r("year", "el"), \u03C4\u03C1\u03AF\u03BC\u03B7\u03BD\u03BF: r("quarter", "el"), \u03BC\u03AE\u03BD\u03B1\u03C2: r("month", "el"), \u03B7\u03BC\u03AD\u03C1\u03B1: r("day", "el"), an: r("year", "ro"), trimestru: r("quarter", "ro"), lun\u0103: r("month", "ro"), zi: r("day", "ro"), godina: r("year", "hr"), tromjese\u010Dje: r("quarter", "hr"), mjesec: r("month", "hr"), dan: r("day", "hr"), \u5E74: r("year", "ja", "zh"), \u56DB\u534A\u671F: r("quarter", "ja"), \u5B63\u5EA6: r("quarter", "zh"), \u6708: r("month", "ja", "zh"), \u65E5: r("day", "ja", "zh"), \uC5F0\uB3C4: r("year", "ko"), \uBD84\uAE30: r("quarter", "ko"), \uC6D4: r("month", "ko"), \uC77C: r("day", "ko"), tahun: r("year", "id"), kuartal: r("quarter", "id"), triwulan: r("quarter", "id"), bulan: r("month", "id"), hari: r("day", "id"), n\u0103m: r("year", "vi"), qu\u00FD: r("quarter", "vi"), th\u00E1ng: r("month", "vi"), ng\u00E0y: r("day", "vi"), \u0E1B\u0E35: r("year", "th"), \u0E44\u0E15\u0E23\u0E21\u0E32\u0E2A: r("quarter", "th"), \u0E40\u0E14\u0E37\u0E2D\u0E19: r("month", "th"), \u0E27\u0E31\u0E19: r("day", "th"), \u0627\u0644\u0633\u0646\u0629: r("year", "ar"), \u0633\u0646\u0629: r("year", "ar"), \u0627\u0644\u0639\u0627\u0645: r("year", "ar"), \u0639\u0627\u0645: r("year", "ar"), \u0627\u0644\u0631\u0628\u0639: r("quarter", "ar"), \u0631\u0628\u0639: r("quarter", "ar"), "\u0631\u0628\u0639 \u0627\u0644\u0633\u0646\u0629": r("quarter", "ar"), \u0627\u0644\u0634\u0647\u0631: r("month", "ar"), \u0634\u0647\u0631: r("month", "ar"), \u0627\u0644\u064A\u0648\u0645: r("day", "ar"), \u064A\u0648\u0645: r("day", "ar"), \u05E9\u05E0\u05D4: r("year", "he"), \u05E8\u05D1\u05E2\u05D5\u05DF: r("quarter", "he"), \u05D7\u05D5\u05D3\u05E9: r("month", "he"), \u05D9\u05D5\u05DD: r("day", "he"), \u0935\u0930\u094D\u0937: r("year", "hi"), \u0938\u093E\u0932: r("year", "hi"), \u0924\u093F\u092E\u093E\u0939\u0940: r("quarter", "hi"), \u092E\u0939\u0940\u0928\u093E: r("month", "hi"), \u092E\u093E\u0939: r("month", "hi"), \u0926\u093F\u0928: r("day", "hi"), \u0633\u0627\u0644: r("year", "fa"), \u0645\u0627\u0647: r("month", "fa"), \u0631\u0648\u0632: r("day", "fa") });
2023
+ var Qn2 = Object.freeze(Array.from(new Set(Object.values(ie2).flatMap((t) => t.langs))));
2015
2024
  var fe = Object.freeze(["fa", "ar", "he", "th"]);
2016
2025
  var Rr = Object.freeze({ integer: "number", decimal: "number", double: "number", datetime: "date", date: "date", boolean: "boolean", string: "text" });
2017
2026
  var Or = Object.freeze({ RENDER_START: "render-start", RENDER_OK: "render-ok", RENDER_ERROR: "render-error", VIEW: "view", VIEW_VERDICT: "view-verdict" });
package/dist/index.mjs CHANGED
@@ -122,7 +122,7 @@ import {
122
122
  toSourceRows,
123
123
  unpinScrolledAxis,
124
124
  valuePlacementFlag
125
- } from "./chunk-VPGFFVWA.mjs";
125
+ } from "./chunk-CXDTSQBJ.mjs";
126
126
  import "./chunk-A2GMXZP7.mjs";
127
127
  import {
128
128
  ACTIVE_TICK_CLASS,
@@ -212,6 +212,11 @@ var OPTIONS_VOCABULARY = Object.freeze({
212
212
  flipIntervalMs: entry({ timing: "live", default: "", min: 0, max: FLIP_INTERVAL_MAX_MS }),
213
213
  /** Which way a face turns, for any chart that turns between faces: side to side, or top to bottom. */
214
214
  flipDirection: entry({ timing: "live", default: FLIP_DIRECTION_DEFAULT, values: ["horizontal", "vertical"] }),
215
+ /**
216
+ * Hover drop lines on a 3D chart. BLANK - "the chart's own" - is the default: off, unless the request
217
+ * that made the chart asked for them. "on" / "off" is a reader's choice and wins either way.
218
+ */
219
+ hoverDropLines: entry({ timing: "live", default: "", values: ["", "on", "off"] }),
215
220
  // ---- the next generated chart ----
216
221
  levelOfDetail: entry({ timing: "next-generate", default: "", values: ["", "High", "Medium", "Low"], wire: "clientHints" }),
217
222
  favorLimitTo: entry({ timing: "next-generate", default: "", values: ["", "latest", "top / greatest", "bottom / smallest", "most common", "outliers"], wire: "clientHints" }),
@@ -2661,13 +2666,13 @@ function latePickupKeepsMarker(outcome) {
2661
2666
  return outcome === "transport";
2662
2667
  }
2663
2668
  function pollGiveUpKeepsMarker(outcome, m2) {
2664
- return outcome === "window-closed" && !!m2 && !isBlindMarker(m2);
2669
+ return (outcome === "window-closed" || outcome === "unreachable") && !!m2 && !isBlindMarker(m2);
2665
2670
  }
2666
2671
  function pendingRecoveryRemainingMs(m2, nowMs) {
2667
2672
  return Math.max(0, m2.t + PENDING_RECOVERY_WINDOW_MS - nowMs);
2668
2673
  }
2669
- function transportFailureShouldRecover(headersReceived, genNew) {
2670
- return headersReceived && genNew;
2674
+ function transportFailureShouldRecover(_headersReceived, genNew) {
2675
+ return genNew;
2671
2676
  }
2672
2677
  var TRANSPORT_LOST_CHECKING_MESSAGE = "The connection dropped while your chart was being generated - checking whether it finished on the server...";
2673
2678
  var GENERATION_CANCELLED_MESSAGE = "The connection dropped before the chart finished - nothing was charged. Generate again.";
@@ -2678,6 +2683,37 @@ function generationCancelledMessage(serverMessage) {
2678
2683
  const s2 = String(serverMessage ?? "").trim();
2679
2684
  return s2 !== "" ? s2 : GENERATION_CANCELLED_MESSAGE;
2680
2685
  }
2686
+ function recoveryFinalOutcome(r2) {
2687
+ if (!r2) return null;
2688
+ const o3 = String(r2.pollOutcome ?? "").trim().toLowerCase();
2689
+ if (r2.isGenerationCancelled === true || r2.isPollFinal === true && o3 === "cancelled") return "cancelled";
2690
+ if (r2.isPollFinal === true) return o3 === "not-received" ? "not-received" : "failed";
2691
+ if (r2.isPollFinal == null && r2.isVersionNotFound === true) {
2692
+ const c2 = String(r2.errorCode ?? "").trim().toUpperCase();
2693
+ if (c2 === "GENERATION_NOT_RECEIVED") return "not-received";
2694
+ if (c2 === "GENERATION_FAILED") return "failed";
2695
+ if (c2 === "GENERATION_CANCELLED") return "cancelled";
2696
+ }
2697
+ return null;
2698
+ }
2699
+ function recoveryProvesNothingCharged(o3) {
2700
+ return o3 === "cancelled" || o3 === "not-received";
2701
+ }
2702
+ function recoveryGiveUpRefunds(outcome) {
2703
+ return outcome === "window-closed" || outcome === "hard-error" || outcome === "unreachable";
2704
+ }
2705
+ var PENDING_RECOVERY_UNREACHABLE_POLLS = 3;
2706
+ function recoveryLooksUnreachable(transportFailuresInARow, everAnswered) {
2707
+ return !everAnswered && transportFailuresInARow >= PENDING_RECOVERY_UNREACHABLE_POLLS;
2708
+ }
2709
+ var GENERATION_NOT_RECEIVED_MESSAGE = "The charting service has no record of that request, so nothing was generated and nothing was charged. Generate again.";
2710
+ var GENERATION_FAILED_MESSAGE = "That chart didn't finish on the server, so there's nothing to show. Generate again.";
2711
+ var RECOVERY_UNREACHABLE_MESSAGE = "We couldn't reach the charting service to check on your chart - it may be offline, or blocked on this network. Try again in a moment.";
2712
+ function recoveryFinalMessage(o3, serverMessage) {
2713
+ const s2 = String(serverMessage ?? "").trim();
2714
+ if (s2 !== "") return s2;
2715
+ return o3 === "cancelled" ? GENERATION_CANCELLED_MESSAGE : o3 === "not-received" ? GENERATION_NOT_RECEIVED_MESSAGE : GENERATION_FAILED_MESSAGE;
2716
+ }
2681
2717
 
2682
2718
  // src/chartPick.ts
2683
2719
  function reconcileChartPick(pick, offered, autoLabel) {
@@ -2856,6 +2892,8 @@ export {
2856
2892
  FLIP_INTERVAL_MIN_MS,
2857
2893
  FLIP_MODE_DEFAULT,
2858
2894
  GENERATION_CANCELLED_MESSAGE,
2895
+ GENERATION_FAILED_MESSAGE,
2896
+ GENERATION_NOT_RECEIVED_MESSAGE,
2859
2897
  GEO_POINT_PRECISIONS,
2860
2898
  GLYPH_SAMPLE_N,
2861
2899
  HOST_CONTAINER_CLASS,
@@ -2889,6 +2927,7 @@ export {
2889
2927
  PENDING_RECOVERY_POLL_MS,
2890
2928
  PENDING_RECOVERY_SLOW_PHASE_MS,
2891
2929
  PENDING_RECOVERY_SLOW_POLL_MS,
2930
+ PENDING_RECOVERY_UNREACHABLE_POLLS,
2892
2931
  PENDING_RECOVERY_WINDOW_MS,
2893
2932
  PHANTOM_FRACTION,
2894
2933
  PILL_MIN_ALPHA,
@@ -2897,6 +2936,7 @@ export {
2897
2936
  PRODUCT_FEEDBACK_MAX_CHARS,
2898
2937
  PRODUCT_FEEDBACK_MIN_CHARS,
2899
2938
  QUALIFY_REFUSAL_UNSPECIFIED,
2939
+ RECOVERY_UNREACHABLE_MESSAGE,
2900
2940
  ROW_IDX_ATTR,
2901
2941
  SAME_SHADE_DELTA_E,
2902
2942
  SCROLL_SLACK_PX,
@@ -3049,8 +3089,13 @@ export {
3049
3089
  reconcileChartPick,
3050
3090
  reconcileModelPick,
3051
3091
  recoveryAnswerIsCancelled,
3092
+ recoveryFinalMessage,
3093
+ recoveryFinalOutcome,
3094
+ recoveryGiveUpRefunds,
3095
+ recoveryLooksUnreachable,
3052
3096
  recoveryOwnsTheSentence,
3053
3097
  recoveryPollRunning,
3098
+ recoveryProvesNothingCharged,
3054
3099
  refusalIsSelectable,
3055
3100
  registerCityTable,
3056
3101
  registerGeo,
package/dist/react.mjs CHANGED
@@ -22,7 +22,7 @@ import {
22
22
  loadGeo,
23
23
  syncMemberSelection,
24
24
  toSourceRows
25
- } from "./chunk-VPGFFVWA.mjs";
25
+ } from "./chunk-CXDTSQBJ.mjs";
26
26
  import "./chunk-A2GMXZP7.mjs";
27
27
  import "./chunk-WNGJUPEI.mjs";
28
28
  import "./chunk-GHODWOAL.mjs";
@@ -151,6 +151,7 @@ export interface RenderOptions {
151
151
  flipIntervalMs?: number;
152
152
  flipMode?: FlipMode;
153
153
  flipDirection?: FlipDirection;
154
+ hoverDropLines?: boolean;
154
155
  cardBackgroundColor?: string;
155
156
  onSelect?: (rowIdxs: number[]) => void;
156
157
  /**
@@ -41,7 +41,7 @@ export { pinScrolledAxis, unpinScrolledAxis, type AxisPinReport } from "./fitDom
41
41
  export { MIN_DELTA_E, pickDistinctColorFromSeed, buildPalette, buildPaletteFromSeed, orderMostDistinct, LEGIBLE_LIGHTNESS, type PaletteResult, type SeedForSlot, type PaletteOptions, } from "./palette";
42
42
  export { deltaEHex } from "./deltaE";
43
43
  export { resolveAutoColorScale, autoRampMinStep, autoRampCanvas, AUTO_RAMP_CLASSES, AUTO_RAMP_DRAWN_OPACITY, AUTO_RAMP_MIN_STEP_DELTA_E, type AutoColorScale, type AutoColorScaleInput } from "./autoRamp";
44
- export { PENDING_RECOVERY_WINDOW_MS, PENDING_RECOVERY_POLL_MS, PENDING_RECOVERY_FIRST_POLL_MS, PENDING_RECOVERY_FAST_PHASE_MS, PENDING_RECOVERY_MID_POLL_MS, PENDING_RECOVERY_SLOW_PHASE_MS, PENDING_RECOVERY_SLOW_POLL_MS, pendingRecoveryNextDelayMs, encodePendingGenerate, parsePendingGenerate, markerArmedBlind, isBlindMarker, servedCorrelationProves, sameMarker, decidePendingRecovery, recoveryPollRunning, recoveryOwnsTheSentence, latePickupAction, latePickupKeepsMarker, pollGiveUpKeepsMarker, pendingRecoveryRemainingMs, transportFailureShouldRecover, TRANSPORT_LOST_CHECKING_MESSAGE, GENERATION_CANCELLED_MESSAGE, recoveryAnswerIsCancelled, generationCancelledMessage, type PendingGenerateMarker, type PendingRecoveryDecision, type LatePickupAction, } from "./pendingGenerate";
44
+ export { PENDING_RECOVERY_WINDOW_MS, PENDING_RECOVERY_POLL_MS, PENDING_RECOVERY_FIRST_POLL_MS, PENDING_RECOVERY_FAST_PHASE_MS, PENDING_RECOVERY_MID_POLL_MS, PENDING_RECOVERY_SLOW_PHASE_MS, PENDING_RECOVERY_SLOW_POLL_MS, pendingRecoveryNextDelayMs, encodePendingGenerate, parsePendingGenerate, markerArmedBlind, isBlindMarker, servedCorrelationProves, sameMarker, decidePendingRecovery, recoveryPollRunning, recoveryOwnsTheSentence, latePickupAction, latePickupKeepsMarker, pollGiveUpKeepsMarker, pendingRecoveryRemainingMs, transportFailureShouldRecover, TRANSPORT_LOST_CHECKING_MESSAGE, GENERATION_CANCELLED_MESSAGE, recoveryAnswerIsCancelled, generationCancelledMessage, recoveryFinalOutcome, recoveryProvesNothingCharged, recoveryGiveUpRefunds, recoveryLooksUnreachable, recoveryFinalMessage, PENDING_RECOVERY_UNREACHABLE_POLLS, GENERATION_NOT_RECEIVED_MESSAGE, GENERATION_FAILED_MESSAGE, RECOVERY_UNREACHABLE_MESSAGE, type PendingGenerateMarker, type PendingRecoveryDecision, type LatePickupAction, type RecoveryFinalOutcome, } from "./pendingGenerate";
45
45
  export { stripJsComments } from "./codeComments";
46
46
  export { reconcileChartPick, type ChartPickReconciliation } from "./chartPick";
47
47
  export { isDuplicateGenerate, armGenerateGuard, DUPLICATE_GENERATE_WINDOW_MS, type GenerateGuardKey, type GenerateGuardState, } from "./duplicateGenerateGuard";
@@ -60,6 +60,11 @@ export declare const OPTIONS_VOCABULARY: Readonly<{
60
60
  flipIntervalMs: OptionVocabularyEntry;
61
61
  /** Which way a face turns, for any chart that turns between faces: side to side, or top to bottom. */
62
62
  flipDirection: OptionVocabularyEntry;
63
+ /**
64
+ * Hover drop lines on a 3D chart. BLANK - "the chart's own" - is the default: off, unless the request
65
+ * that made the chart asked for them. "on" / "off" is a reader's choice and wins either way.
66
+ */
67
+ hoverDropLines: OptionVocabularyEntry;
63
68
  levelOfDetail: OptionVocabularyEntry;
64
69
  favorLimitTo: OptionVocabularyEntry;
65
70
  /** 0 asks for no limit, and travels as absent (`wireLimitCount`): any value the server receives is a limit. */
@@ -147,20 +147,23 @@ export declare function latePickupAction(m: PendingGenerateMarker | null | undef
147
147
  */
148
148
  export declare function latePickupKeepsMarker(outcome: "found" | "not-yet" | "hard-error" | "transport"): boolean;
149
149
  /**
150
- * When the 15-minute poll runs out ("window-closed"), the marker STAYS for the next mount's late
151
- * pickup, as long as it carries a correlation. A definitive refusal ("hard-error") still clears it.
150
+ * When the 15-minute poll runs out ("window-closed"), or stops because no check could reach the
151
+ * service ("unreachable"), the marker STAYS for the next mount's late pickup, as long as it carries a
152
+ * correlation. A definitive refusal ("hard-error") or a final answer still clears it.
152
153
  */
153
154
  export declare function pollGiveUpKeepsMarker(outcome: string, m: PendingGenerateMarker | null | undefined): boolean;
154
155
  /** Milliseconds left in the recovery window from `nowMs`, floored at 0. */
155
156
  export declare function pendingRecoveryRemainingMs(m: PendingGenerateMarker, nowMs: number): number;
156
157
  /**
157
158
  * Whether a transport failure on a generate should hand off to the recovery poll (true) or fall back
158
- * to the ordinary retry (false). The discriminator is whether the service ACCEPTED the request: a
159
- * streaming endpoint commits its 200 headers the moment it starts, so headers-received plus a later
160
- * failure means the generate is running server-side and a retry would make a SECOND chart. No
161
- * headers means the service never saw it, and retrying is the right move.
159
+ * to the ordinary retry (false). A REAL GENERATE ALWAYS RECOVERS (2026-10-04). "No response headers"
160
+ * used to mean "the service never saw it", and behind a buffering proxy it never did: the proxy held
161
+ * the headers and the heartbeats while the service finished and charged (seen in production: every
162
+ * pre-header loss in a week had reached the server). A retry made a second chart; a
163
+ * poll by correlation costs nothing, and the server now says when nothing was received.
164
+ * `headersReceived` stays in the signature and decides nothing.
162
165
  */
163
- export declare function transportFailureShouldRecover(headersReceived: boolean, genNew: boolean): boolean;
166
+ export declare function transportFailureShouldRecover(_headersReceived: boolean, genNew: boolean): boolean;
164
167
  /**
165
168
  * WHAT A HOST SAYS THE MOMENT A GENERATE'S CONNECTION DROPS - before it knows anything else.
166
169
  *
@@ -189,3 +192,38 @@ export declare function recoveryAnswerIsCancelled(r: {
189
192
  } | null | undefined): boolean;
190
193
  /** The banner for a cancelled generation: the server's own sentence when it sent one, else the same words. */
191
194
  export declare function generationCancelledMessage(serverMessage: string | null | undefined): string;
195
+ /**
196
+ * THE RECOVERY POLL'S FINAL ANSWERS (2026-10-04). A server that knows the generation ended without a
197
+ * chart says so with `isPollFinal` and names the ending in `pollOutcome`; isVersionNotFound rides
198
+ * beside it for older hosts, so this is read FIRST. null = not final. A final answer with an outcome
199
+ * this build does not know reads as "failed": it is final, and it claims nothing about charges.
200
+ */
201
+ export type RecoveryFinalOutcome = "cancelled" | "failed" | "not-received";
202
+ export declare function recoveryFinalOutcome(r: {
203
+ isPollFinal?: boolean | null;
204
+ pollOutcome?: string | null;
205
+ isGenerationCancelled?: boolean | null;
206
+ isVersionNotFound?: boolean | null;
207
+ errorCode?: string | null;
208
+ } | null | undefined): RecoveryFinalOutcome | null;
209
+ /** Did the server PROVE nothing was charged? Only a cancel and a request it never received do; a
210
+ * failed generation's charge is its own, and a host claims nothing about it. */
211
+ export declare function recoveryProvesNothingCharged(o: string | null | undefined): boolean;
212
+ /** Does a recovery that ended this way send the refund? Only when it ended with NOTHING PAINTED and
213
+ * nothing proven - the window closed, the poll itself was refused, or the service could not be
214
+ * reached. The server holds the refund until the row exists and declines a painted chart (recover,
215
+ * then refund). Never for a final answer. */
216
+ export declare function recoveryGiveUpRefunds(outcome: string): boolean;
217
+ /** Polls in a row that could not reach the service, with no answer yet, that end the recovery as
218
+ * "unreachable" rather than waiting out the window (~32 s on the shared cadence). */
219
+ export declare const PENDING_RECOVERY_UNREACHABLE_POLLS = 3;
220
+ export declare function recoveryLooksUnreachable(transportFailuresInARow: number, everAnswered: boolean): boolean;
221
+ /** The server's words for the final answers, for a server that sent none and for a host that
222
+ * localises by code. */
223
+ export declare const GENERATION_NOT_RECEIVED_MESSAGE = "The charting service has no record of that request, so nothing was generated and nothing was charged. Generate again.";
224
+ export declare const GENERATION_FAILED_MESSAGE = "That chart didn't finish on the server, so there's nothing to show. Generate again.";
225
+ /** Neither the generate's answer nor any check reached us. Claims nothing about a charge: behind a
226
+ * proxy the generate may have arrived when the checks did not. */
227
+ export declare const RECOVERY_UNREACHABLE_MESSAGE = "We couldn't reach the charting service to check on your chart - it may be offline, or blocked on this network. Try again in a moment.";
228
+ /** The sentence for a final answer: the server's own when it sent one, else the same words. */
229
+ export declare function recoveryFinalMessage(o: RecoveryFinalOutcome, serverMessage: string | null | undefined): string;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@bicharts/chart-host",
3
- "version": "0.6.64",
3
+ "version": "0.6.66",
4
4
  "description": "Run a BIC-generated D3 chart in any web host: compiles the generated render() function, applies the shared option defaults, resolves mark clicks (through tooltip overlays), owns the selection affordance, and translates row indices between cross-filtered charts. The same contract the BIC Power BI visual implements, minus Power BI. React bindings at @bicharts/chart-host/react.",
5
5
  "license": "Apache-2.0",
6
6
  "type": "module",