@modelform/react-native 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.
- package/dist/{chunk-24ABPZKO.js → chunk-IHOP6IEA.js} +223 -139
- package/dist/{chunk-IMXL2SZA.mjs → chunk-WABOXGET.mjs} +85 -1
- package/dist/core/authoring.d.ts +2 -2
- package/dist/core/index.js +2 -2
- package/dist/core/index.mjs +1 -1
- package/dist/index.js +162 -162
- package/dist/index.mjs +1 -1
- package/package.json +1 -1
|
@@ -664,7 +664,80 @@ function formatDate(ms, format3 = "YYYY-MM-DD HH:mm:ss") {
|
|
|
664
664
|
};
|
|
665
665
|
return format3.replace(/YYYY|YY|MM|DD|HH|mm|ss|SSS/g, (t) => tokens[t]);
|
|
666
666
|
}
|
|
667
|
+
var operandName = (o) => o == null ? void 0 : typeof o === "object" ? (o.matcher?.options ?? o.fixed)?.toString() : String(o);
|
|
668
|
+
var OPERATORS = {
|
|
669
|
+
"+": (a, b) => a + b,
|
|
670
|
+
"-": (a, b) => a - b,
|
|
671
|
+
"*": (a, b) => a * b,
|
|
672
|
+
"/": (a, b) => a / b,
|
|
673
|
+
"%": (a, b) => a % b,
|
|
674
|
+
"^": (a, b) => a ** b
|
|
675
|
+
};
|
|
676
|
+
var ROW_REDUCERS = {
|
|
677
|
+
sum: { label: "Total", fn: (vs) => vs.length ? vs.reduce((a, b) => a + b, 0) : null },
|
|
678
|
+
mean: { label: "Mean", fn: (vs) => vs.length ? vs.reduce((a, b) => a + b, 0) / vs.length : null },
|
|
679
|
+
min: { label: "Min", fn: (vs) => vs.length ? Math.min(...vs) : null },
|
|
680
|
+
max: { label: "Max", fn: (vs) => vs.length ? Math.max(...vs) : null },
|
|
681
|
+
first: { label: "First", fn: (vs) => vs[0] ?? null },
|
|
682
|
+
last: { label: "Last", fn: (vs) => vs.at(-1) ?? null },
|
|
683
|
+
count: { label: "Count", fn: (vs) => vs.length },
|
|
684
|
+
range: { label: "Range", fn: (vs) => vs.length ? Math.max(...vs) - Math.min(...vs) : null }
|
|
685
|
+
};
|
|
686
|
+
var asNumber = (v) => {
|
|
687
|
+
if (v == null || v === "" || typeof v === "boolean") return v === true ? 1 : v === false ? 0 : null;
|
|
688
|
+
const n = Number(v);
|
|
689
|
+
return Number.isFinite(n) ? n : null;
|
|
690
|
+
};
|
|
691
|
+
function calculate(frame, multiple, options) {
|
|
692
|
+
const rows = frame.fields[0]?.values.length ?? 0;
|
|
693
|
+
const find = (name) => frame.fields.find((f) => f.name === name || fieldDisplayName(f, frame, multiple) === name);
|
|
694
|
+
const mode = options.mode ?? "reduceRow";
|
|
695
|
+
if (mode === "binary") {
|
|
696
|
+
const { left, right, operator = "*" } = options.binary ?? {};
|
|
697
|
+
const op = OPERATORS[operator];
|
|
698
|
+
const [l, r] = [operandName(left), operandName(right)];
|
|
699
|
+
if (!op || l == null || r == null) return;
|
|
700
|
+
const side = (name) => {
|
|
701
|
+
const f = find(name);
|
|
702
|
+
if (f) return (i) => asNumber(f.values[i]);
|
|
703
|
+
const n = asNumber(name);
|
|
704
|
+
return n == null ? void 0 : () => n;
|
|
705
|
+
};
|
|
706
|
+
const [a, b] = [side(l), side(r)];
|
|
707
|
+
if (!a || !b) return;
|
|
708
|
+
const values = Array.from({ length: rows }, (_, i) => {
|
|
709
|
+
const [x, y] = [a(i), b(i)];
|
|
710
|
+
if (x == null || y == null) return null;
|
|
711
|
+
const v = op(x, y);
|
|
712
|
+
return Number.isFinite(v) ? v : null;
|
|
713
|
+
});
|
|
714
|
+
return { name: options.alias || `${l} ${operator} ${r}`, type: "number", values };
|
|
715
|
+
}
|
|
716
|
+
if (mode === "reduceRow") {
|
|
717
|
+
const { reducer = "sum", include } = options.reduce ?? {};
|
|
718
|
+
const red = ROW_REDUCERS[reducer];
|
|
719
|
+
if (!red) return;
|
|
720
|
+
const fields = include?.length ? include.map(find).filter((f) => !!f) : frame.fields.filter((f) => f.type === "number");
|
|
721
|
+
if (!fields.length) return;
|
|
722
|
+
const values = Array.from({ length: rows }, (_, i) => red.fn(fields.map((f) => asNumber(f.values[i])).filter((v) => v != null)));
|
|
723
|
+
return { name: options.alias || red.label, type: "number", values };
|
|
724
|
+
}
|
|
725
|
+
}
|
|
667
726
|
var TRANSFORMERS = {
|
|
727
|
+
// A field computed per row: from two fields, or a field and a number (binary), or across fields
|
|
728
|
+
// (reduceRow). Several frames are joined on time first, as Grafana does, so the entries of one
|
|
729
|
+
// Save (which share a time) meet in one row: yield ÷ dose per shot. A row missing a value, or a
|
|
730
|
+
// division by zero, gives null.
|
|
731
|
+
calculateField: (frames, options) => {
|
|
732
|
+
const joined = frames.length > 1 ? TRANSFORMERS.joinByField(frames, {}) : frames;
|
|
733
|
+
const multiple = joined.length > 1;
|
|
734
|
+
return joined.map((frame) => {
|
|
735
|
+
const field2 = calculate(frame, multiple, options);
|
|
736
|
+
if (!field2) return frame;
|
|
737
|
+
const time = frame.fields.find((f) => f.type === "time");
|
|
738
|
+
return { ...frame, fields: options.replaceFields ? [...time ? [time] : [], field2] : [...frame.fields, field2] };
|
|
739
|
+
});
|
|
740
|
+
},
|
|
668
741
|
convertFieldType: (frames, { conversions = [] }) => frames.map((frame) => ({
|
|
669
742
|
...frame,
|
|
670
743
|
fields: frame.fields.map((f) => {
|
|
@@ -12437,7 +12510,18 @@ Chart panels read the app's entries with \`"datasource": { "type": "modelform-lo
|
|
|
12437
12510
|
|
|
12438
12511
|
Units and ranges go in \`"fieldConfig": { "defaults": { "unit": "\u2026", "min", "max", "decimals" } }\`. Units are Grafana's, e.g. "percent", "masskg", "lengthkm", "s", or "suffix: <text>" for anything else (\`"suffix: glasses"\`). Don't use trend, xychart or geomap panels.
|
|
12439
12512
|
|
|
12440
|
-
|
|
12513
|
+
To chart a value worked out from inputs saved together on one form, e.g. a ratio, query each input as its own target and add a \`calculateField\` transformation. Series are joined on time first, so the values of one save meet in one row:
|
|
12514
|
+
|
|
12515
|
+
\`\`\`
|
|
12516
|
+
"targets": [ { "refId": "A", "metric": "yield" }, { "refId": "B", "metric": "dose" } ],
|
|
12517
|
+
"transformations": [ { "id": "calculateField", "options": { "mode": "binary", "alias": "Ratio", "replaceFields": true,
|
|
12518
|
+
"binary": { "left": "yield", "operator": "/", "right": "dose" } } } ]
|
|
12519
|
+
\`\`\`
|
|
12520
|
+
|
|
12521
|
+
- \`left\` and \`right\` are a target's metric (its \`alias\` if it has one) or a number; operators are + - * / % ^. \`"replaceFields": true\` keeps only the result; leave it out to chart the inputs beside it.
|
|
12522
|
+
- \`"mode": "reduceRow"\` with \`"reduce": { "reducer": "sum" | "mean" | "min" | "max", "include": ["<metric>", \u2026] }\` combines several inputs instead, e.g. a total of three scores.
|
|
12523
|
+
- Give both targets the same \`aggregate\` and \`bucket\`, or neither. A save missing either value has no result.
|
|
12524
|
+
- It doesn't work for fields inside an input-group (weight \xD7 reps per set): every item of a save shares one time. Chart what's recorded there instead, or add a field for the combined value, and say which you did in the sentence before the JSON.
|
|
12441
12525
|
|
|
12442
12526
|
`;
|
|
12443
12527
|
var AUTHORING_GUIDE = `# modelform templates
|
package/dist/core/authoring.d.ts
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import type { Dashboard, DocumentKind } from './schema';
|
|
2
2
|
import { type AppTemplate } from './templates';
|
|
3
3
|
/** How to write forms and dashboards, for an assistant: the part of the guide that applies to one document. */
|
|
4
|
-
export declare const DOCUMENT_GUIDE = "## Documents\n\nA document is a subset of Grafana's dashboard JSON: `{ \"kind\": \"form\" | \"dashboard\", \"title\": \"\u2026\", \"panels\": [ \u2026 ] }`, and dashboards add `\"time\": { \"from\": \"now-30d\", \"to\": \"now\" }`.\n\nEvery panel has an `id` (a number, unique in its document), a `type`, a `title`, and a `gridPos` `{ \"x\", \"y\", \"w\", \"h\" }` on a 24-column grid: `w: 24` is full width, `w: 12` half. Stack panels top to bottom with no gaps or overlaps (each `y` is the previous `y + h` unless they sit side by side). On phones panels show full width in that order.\n\nA `\"row\"` panel (`h: 1`, no options) is a section heading for the panels under it, in forms and dashboards.\n\n## Forms\n\nForms hold input panels. Each records to a `metric` (lowercase words joined with dashes, e.g. `\"body-weight\"`), and charts read entries by that metric. Two inputs never share a metric. Use `h: 3` for inputs.\n\n| type | what | options besides metric |\n|---|---|---|\n| input-number | a number typed or stepped with + and \u2212 | unit, step (1 by default: whole numbers only; give 0.1 for decimals, e.g. a weight), min, max |\n| input-slider | a value dragged along a range | min, max, step, unit, labels (text spread along the track) |\n| input-select | one of a set of choices | choices: [{ \"label\", \"value\" }], multi (allow several) |\n| input-toggle | yes or no (records 1 or 0) | |\n| input-rating | a score, e.g. 1 to 5 | min, max |\n| input-text | free text | placeholder, suggest (offer earlier values) |\n| input-counter | taps that add up, e.g. glasses of water | increment, unit |\n| input-duration | a length of time, recorded in seconds | placeholder |\n\nA form can set `\"localOnly\": true` (beside `\"kind\"`) to keep what it records on the device where it's recorded: it's never synced to an account, other devices or assistants. Use it only when asked, e.g. for a private journal.\n\nAny input (not counter) can also take `required: true`, `default` (a value, or `\"last\"` for the last one saved), and `record: \"always\"` to record its value on every save even when it wasn't changed.\n\n`input-group` repeats fields once per item, for things like the sets of a workout or the dishes of a meal. Give it `h: 12` and options `{ \"itemTitle\": \"Set\", \"titleFrom\": \"<a field's metric>\", \"start\": 1 | \"last\", \"min\", \"max\", \"fields\": [ { \"type\": \"input-\u2026\", \"title\", \"span\": 1\u201324, \"options\": { \"metric\", \u2026 } } ] }`. Fields can be any input but input-counter.\n\n## Dashboards\n\nChart panels read the app's entries with `\"datasource\": { \"type\": \"modelform-local\" }` and `\"targets\": [ { \"refId\": \"A\", \"metric\": \"\u2026\" } ]` (refIds A, B, C\u2026 for more series). A target can also have:\n\n- `aggregate`: \"sum\", \"avg\", \"min\", \"max\", \"count\" or \"last\", with `bucket`: \"1h\", \"1d\", \"1w\" or \"1M\". Without them each entry is a point.\n- `groupBy`: \"text\" for one series per text or choice value; `{ \"field\": \"<metric>\" }` for one series per value of another input saved at the same time (in an input-group, of the same item, e.g. weight per exercise).\n- `alias`: the series name. `fillZero: false` leaves empty buckets out.\n\n| type | use for | h |\n|---|---|---|\n| timeseries | values over time | 7\u20138 |\n| barchart | totals per day, week or category | 7\u20138 |\n| stat | one big number; `\"options\": { \"reduceOptions\": { \"calcs\": [\"lastNotNull\" or \"mean\" or \"sum\"] } }` | 4 |\n| gauge, bargauge | a value against a range (set min and max) | 5\u20136 |\n| piechart | how a total splits, e.g. by choice with groupBy \"text\" and aggregate \"count\" | 8 |\n| table | rows of values | 8 |\n| text | markdown notes: `\"options\": { \"content\": \"\u2026\" }`, no targets | 3\u20134 |\n\nUnits and ranges go in `\"fieldConfig\": { \"defaults\": { \"unit\": \"\u2026\", \"min\", \"max\", \"decimals\" } }`. Units are Grafana's, e.g. \"percent\", \"masskg\", \"lengthkm\", \"s\", or \"suffix: <text>\" for anything else (`\"suffix: glasses\"`). Don't use trend, xychart or geomap panels.\n\
|
|
4
|
+
export declare const DOCUMENT_GUIDE = "## Documents\n\nA document is a subset of Grafana's dashboard JSON: `{ \"kind\": \"form\" | \"dashboard\", \"title\": \"\u2026\", \"panels\": [ \u2026 ] }`, and dashboards add `\"time\": { \"from\": \"now-30d\", \"to\": \"now\" }`.\n\nEvery panel has an `id` (a number, unique in its document), a `type`, a `title`, and a `gridPos` `{ \"x\", \"y\", \"w\", \"h\" }` on a 24-column grid: `w: 24` is full width, `w: 12` half. Stack panels top to bottom with no gaps or overlaps (each `y` is the previous `y + h` unless they sit side by side). On phones panels show full width in that order.\n\nA `\"row\"` panel (`h: 1`, no options) is a section heading for the panels under it, in forms and dashboards.\n\n## Forms\n\nForms hold input panels. Each records to a `metric` (lowercase words joined with dashes, e.g. `\"body-weight\"`), and charts read entries by that metric. Two inputs never share a metric. Use `h: 3` for inputs.\n\n| type | what | options besides metric |\n|---|---|---|\n| input-number | a number typed or stepped with + and \u2212 | unit, step (1 by default: whole numbers only; give 0.1 for decimals, e.g. a weight), min, max |\n| input-slider | a value dragged along a range | min, max, step, unit, labels (text spread along the track) |\n| input-select | one of a set of choices | choices: [{ \"label\", \"value\" }], multi (allow several) |\n| input-toggle | yes or no (records 1 or 0) | |\n| input-rating | a score, e.g. 1 to 5 | min, max |\n| input-text | free text | placeholder, suggest (offer earlier values) |\n| input-counter | taps that add up, e.g. glasses of water | increment, unit |\n| input-duration | a length of time, recorded in seconds | placeholder |\n\nA form can set `\"localOnly\": true` (beside `\"kind\"`) to keep what it records on the device where it's recorded: it's never synced to an account, other devices or assistants. Use it only when asked, e.g. for a private journal.\n\nAny input (not counter) can also take `required: true`, `default` (a value, or `\"last\"` for the last one saved), and `record: \"always\"` to record its value on every save even when it wasn't changed.\n\n`input-group` repeats fields once per item, for things like the sets of a workout or the dishes of a meal. Give it `h: 12` and options `{ \"itemTitle\": \"Set\", \"titleFrom\": \"<a field's metric>\", \"start\": 1 | \"last\", \"min\", \"max\", \"fields\": [ { \"type\": \"input-\u2026\", \"title\", \"span\": 1\u201324, \"options\": { \"metric\", \u2026 } } ] }`. Fields can be any input but input-counter.\n\n## Dashboards\n\nChart panels read the app's entries with `\"datasource\": { \"type\": \"modelform-local\" }` and `\"targets\": [ { \"refId\": \"A\", \"metric\": \"\u2026\" } ]` (refIds A, B, C\u2026 for more series). A target can also have:\n\n- `aggregate`: \"sum\", \"avg\", \"min\", \"max\", \"count\" or \"last\", with `bucket`: \"1h\", \"1d\", \"1w\" or \"1M\". Without them each entry is a point.\n- `groupBy`: \"text\" for one series per text or choice value; `{ \"field\": \"<metric>\" }` for one series per value of another input saved at the same time (in an input-group, of the same item, e.g. weight per exercise).\n- `alias`: the series name. `fillZero: false` leaves empty buckets out.\n\n| type | use for | h |\n|---|---|---|\n| timeseries | values over time | 7\u20138 |\n| barchart | totals per day, week or category | 7\u20138 |\n| stat | one big number; `\"options\": { \"reduceOptions\": { \"calcs\": [\"lastNotNull\" or \"mean\" or \"sum\"] } }` | 4 |\n| gauge, bargauge | a value against a range (set min and max) | 5\u20136 |\n| piechart | how a total splits, e.g. by choice with groupBy \"text\" and aggregate \"count\" | 8 |\n| table | rows of values | 8 |\n| text | markdown notes: `\"options\": { \"content\": \"\u2026\" }`, no targets | 3\u20134 |\n\nUnits and ranges go in `\"fieldConfig\": { \"defaults\": { \"unit\": \"\u2026\", \"min\", \"max\", \"decimals\" } }`. Units are Grafana's, e.g. \"percent\", \"masskg\", \"lengthkm\", \"s\", or \"suffix: <text>\" for anything else (`\"suffix: glasses\"`). Don't use trend, xychart or geomap panels.\n\nTo chart a value worked out from inputs saved together on one form, e.g. a ratio, query each input as its own target and add a `calculateField` transformation. Series are joined on time first, so the values of one save meet in one row:\n\n```\n\"targets\": [ { \"refId\": \"A\", \"metric\": \"yield\" }, { \"refId\": \"B\", \"metric\": \"dose\" } ],\n\"transformations\": [ { \"id\": \"calculateField\", \"options\": { \"mode\": \"binary\", \"alias\": \"Ratio\", \"replaceFields\": true,\n \"binary\": { \"left\": \"yield\", \"operator\": \"/\", \"right\": \"dose\" } } } ]\n```\n\n- `left` and `right` are a target's metric (its `alias` if it has one) or a number; operators are + - * / % ^. `\"replaceFields\": true` keeps only the result; leave it out to chart the inputs beside it.\n- `\"mode\": \"reduceRow\"` with `\"reduce\": { \"reducer\": \"sum\" | \"mean\" | \"min\" | \"max\", \"include\": [\"<metric>\", \u2026] }` combines several inputs instead, e.g. a total of three scores.\n- Give both targets the same `aggregate` and `bucket`, or neither. A save missing either value has no result.\n- It doesn't work for fields inside an input-group (weight \u00D7 reps per set): every item of a save shares one time. Chart what's recorded there instead, or add a field for the combined value, and say which you did in the sentence before the JSON.\n\n";
|
|
5
5
|
/** How to write a modelform template, for an assistant. Kept next to the format so they change together. */
|
|
6
|
-
export declare const AUTHORING_GUIDE = "# modelform templates\n\nA template is JSON that adds forms (for recording entries) and dashboards (for charting them) to an app, plus tabs to show them.\n\n```\n{\n \"$modelform\": \"template\",\n \"version\": 1,\n \"title\": \"Short name\",\n \"description\": \"One sentence on what it's for.\",\n \"documents\": [ { \"kind\": \"form\" | \"dashboard\", \"id\": \"letters-digits-dashes\", \"dashboard\": { ...document } } ],\n \"tabs\": [ ...tabs ]\n}\n```\n\nEach document's `kind` matches its entry in `documents`.\n\n## Documents\n\nA document is a subset of Grafana's dashboard JSON: `{ \"kind\": \"form\" | \"dashboard\", \"title\": \"\u2026\", \"panels\": [ \u2026 ] }`, and dashboards add `\"time\": { \"from\": \"now-30d\", \"to\": \"now\" }`.\n\nEvery panel has an `id` (a number, unique in its document), a `type`, a `title`, and a `gridPos` `{ \"x\", \"y\", \"w\", \"h\" }` on a 24-column grid: `w: 24` is full width, `w: 12` half. Stack panels top to bottom with no gaps or overlaps (each `y` is the previous `y + h` unless they sit side by side). On phones panels show full width in that order.\n\nA `\"row\"` panel (`h: 1`, no options) is a section heading for the panels under it, in forms and dashboards.\n\n## Forms\n\nForms hold input panels. Each records to a `metric` (lowercase words joined with dashes, e.g. `\"body-weight\"`), and charts read entries by that metric. Two inputs never share a metric. Use `h: 3` for inputs.\n\n| type | what | options besides metric |\n|---|---|---|\n| input-number | a number typed or stepped with + and \u2212 | unit, step (1 by default: whole numbers only; give 0.1 for decimals, e.g. a weight), min, max |\n| input-slider | a value dragged along a range | min, max, step, unit, labels (text spread along the track) |\n| input-select | one of a set of choices | choices: [{ \"label\", \"value\" }], multi (allow several) |\n| input-toggle | yes or no (records 1 or 0) | |\n| input-rating | a score, e.g. 1 to 5 | min, max |\n| input-text | free text | placeholder, suggest (offer earlier values) |\n| input-counter | taps that add up, e.g. glasses of water | increment, unit |\n| input-duration | a length of time, recorded in seconds | placeholder |\n\nA form can set `\"localOnly\": true` (beside `\"kind\"`) to keep what it records on the device where it's recorded: it's never synced to an account, other devices or assistants. Use it only when asked, e.g. for a private journal.\n\nAny input (not counter) can also take `required: true`, `default` (a value, or `\"last\"` for the last one saved), and `record: \"always\"` to record its value on every save even when it wasn't changed.\n\n`input-group` repeats fields once per item, for things like the sets of a workout or the dishes of a meal. Give it `h: 12` and options `{ \"itemTitle\": \"Set\", \"titleFrom\": \"<a field's metric>\", \"start\": 1 | \"last\", \"min\", \"max\", \"fields\": [ { \"type\": \"input-\u2026\", \"title\", \"span\": 1\u201324, \"options\": { \"metric\", \u2026 } } ] }`. Fields can be any input but input-counter.\n\n## Dashboards\n\nChart panels read the app's entries with `\"datasource\": { \"type\": \"modelform-local\" }` and `\"targets\": [ { \"refId\": \"A\", \"metric\": \"\u2026\" } ]` (refIds A, B, C\u2026 for more series). A target can also have:\n\n- `aggregate`: \"sum\", \"avg\", \"min\", \"max\", \"count\" or \"last\", with `bucket`: \"1h\", \"1d\", \"1w\" or \"1M\". Without them each entry is a point.\n- `groupBy`: \"text\" for one series per text or choice value; `{ \"field\": \"<metric>\" }` for one series per value of another input saved at the same time (in an input-group, of the same item, e.g. weight per exercise).\n- `alias`: the series name. `fillZero: false` leaves empty buckets out.\n\n| type | use for | h |\n|---|---|---|\n| timeseries | values over time | 7\u20138 |\n| barchart | totals per day, week or category | 7\u20138 |\n| stat | one big number; `\"options\": { \"reduceOptions\": { \"calcs\": [\"lastNotNull\" or \"mean\" or \"sum\"] } }` | 4 |\n| gauge, bargauge | a value against a range (set min and max) | 5\u20136 |\n| piechart | how a total splits, e.g. by choice with groupBy \"text\" and aggregate \"count\" | 8 |\n| table | rows of values | 8 |\n| text | markdown notes: `\"options\": { \"content\": \"\u2026\" }`, no targets | 3\u20134 |\n\nUnits and ranges go in `\"fieldConfig\": { \"defaults\": { \"unit\": \"\u2026\", \"min\", \"max\", \"decimals\" } }`. Units are Grafana's, e.g. \"percent\", \"masskg\", \"lengthkm\", \"s\", or \"suffix: <text>\" for anything else (`\"suffix: glasses\"`). Don't use trend, xychart or geomap panels.\n\
|
|
6
|
+
export declare const AUTHORING_GUIDE = "# modelform templates\n\nA template is JSON that adds forms (for recording entries) and dashboards (for charting them) to an app, plus tabs to show them.\n\n```\n{\n \"$modelform\": \"template\",\n \"version\": 1,\n \"title\": \"Short name\",\n \"description\": \"One sentence on what it's for.\",\n \"documents\": [ { \"kind\": \"form\" | \"dashboard\", \"id\": \"letters-digits-dashes\", \"dashboard\": { ...document } } ],\n \"tabs\": [ ...tabs ]\n}\n```\n\nEach document's `kind` matches its entry in `documents`.\n\n## Documents\n\nA document is a subset of Grafana's dashboard JSON: `{ \"kind\": \"form\" | \"dashboard\", \"title\": \"\u2026\", \"panels\": [ \u2026 ] }`, and dashboards add `\"time\": { \"from\": \"now-30d\", \"to\": \"now\" }`.\n\nEvery panel has an `id` (a number, unique in its document), a `type`, a `title`, and a `gridPos` `{ \"x\", \"y\", \"w\", \"h\" }` on a 24-column grid: `w: 24` is full width, `w: 12` half. Stack panels top to bottom with no gaps or overlaps (each `y` is the previous `y + h` unless they sit side by side). On phones panels show full width in that order.\n\nA `\"row\"` panel (`h: 1`, no options) is a section heading for the panels under it, in forms and dashboards.\n\n## Forms\n\nForms hold input panels. Each records to a `metric` (lowercase words joined with dashes, e.g. `\"body-weight\"`), and charts read entries by that metric. Two inputs never share a metric. Use `h: 3` for inputs.\n\n| type | what | options besides metric |\n|---|---|---|\n| input-number | a number typed or stepped with + and \u2212 | unit, step (1 by default: whole numbers only; give 0.1 for decimals, e.g. a weight), min, max |\n| input-slider | a value dragged along a range | min, max, step, unit, labels (text spread along the track) |\n| input-select | one of a set of choices | choices: [{ \"label\", \"value\" }], multi (allow several) |\n| input-toggle | yes or no (records 1 or 0) | |\n| input-rating | a score, e.g. 1 to 5 | min, max |\n| input-text | free text | placeholder, suggest (offer earlier values) |\n| input-counter | taps that add up, e.g. glasses of water | increment, unit |\n| input-duration | a length of time, recorded in seconds | placeholder |\n\nA form can set `\"localOnly\": true` (beside `\"kind\"`) to keep what it records on the device where it's recorded: it's never synced to an account, other devices or assistants. Use it only when asked, e.g. for a private journal.\n\nAny input (not counter) can also take `required: true`, `default` (a value, or `\"last\"` for the last one saved), and `record: \"always\"` to record its value on every save even when it wasn't changed.\n\n`input-group` repeats fields once per item, for things like the sets of a workout or the dishes of a meal. Give it `h: 12` and options `{ \"itemTitle\": \"Set\", \"titleFrom\": \"<a field's metric>\", \"start\": 1 | \"last\", \"min\", \"max\", \"fields\": [ { \"type\": \"input-\u2026\", \"title\", \"span\": 1\u201324, \"options\": { \"metric\", \u2026 } } ] }`. Fields can be any input but input-counter.\n\n## Dashboards\n\nChart panels read the app's entries with `\"datasource\": { \"type\": \"modelform-local\" }` and `\"targets\": [ { \"refId\": \"A\", \"metric\": \"\u2026\" } ]` (refIds A, B, C\u2026 for more series). A target can also have:\n\n- `aggregate`: \"sum\", \"avg\", \"min\", \"max\", \"count\" or \"last\", with `bucket`: \"1h\", \"1d\", \"1w\" or \"1M\". Without them each entry is a point.\n- `groupBy`: \"text\" for one series per text or choice value; `{ \"field\": \"<metric>\" }` for one series per value of another input saved at the same time (in an input-group, of the same item, e.g. weight per exercise).\n- `alias`: the series name. `fillZero: false` leaves empty buckets out.\n\n| type | use for | h |\n|---|---|---|\n| timeseries | values over time | 7\u20138 |\n| barchart | totals per day, week or category | 7\u20138 |\n| stat | one big number; `\"options\": { \"reduceOptions\": { \"calcs\": [\"lastNotNull\" or \"mean\" or \"sum\"] } }` | 4 |\n| gauge, bargauge | a value against a range (set min and max) | 5\u20136 |\n| piechart | how a total splits, e.g. by choice with groupBy \"text\" and aggregate \"count\" | 8 |\n| table | rows of values | 8 |\n| text | markdown notes: `\"options\": { \"content\": \"\u2026\" }`, no targets | 3\u20134 |\n\nUnits and ranges go in `\"fieldConfig\": { \"defaults\": { \"unit\": \"\u2026\", \"min\", \"max\", \"decimals\" } }`. Units are Grafana's, e.g. \"percent\", \"masskg\", \"lengthkm\", \"s\", or \"suffix: <text>\" for anything else (`\"suffix: glasses\"`). Don't use trend, xychart or geomap panels.\n\nTo chart a value worked out from inputs saved together on one form, e.g. a ratio, query each input as its own target and add a `calculateField` transformation. Series are joined on time first, so the values of one save meet in one row:\n\n```\n\"targets\": [ { \"refId\": \"A\", \"metric\": \"yield\" }, { \"refId\": \"B\", \"metric\": \"dose\" } ],\n\"transformations\": [ { \"id\": \"calculateField\", \"options\": { \"mode\": \"binary\", \"alias\": \"Ratio\", \"replaceFields\": true,\n \"binary\": { \"left\": \"yield\", \"operator\": \"/\", \"right\": \"dose\" } } } ]\n```\n\n- `left` and `right` are a target's metric (its `alias` if it has one) or a number; operators are + - * / % ^. `\"replaceFields\": true` keeps only the result; leave it out to chart the inputs beside it.\n- `\"mode\": \"reduceRow\"` with `\"reduce\": { \"reducer\": \"sum\" | \"mean\" | \"min\" | \"max\", \"include\": [\"<metric>\", \u2026] }` combines several inputs instead, e.g. a total of three scores.\n- Give both targets the same `aggregate` and `bucket`, or neither. A save missing either value has no result.\n- It doesn't work for fields inside an input-group (weight \u00D7 reps per set): every item of a save shares one time. Chart what's recorded there instead, or add a field for the combined value, and say which you did in the sentence before the JSON.\n\n## Tabs\n\n`{ \"id\": \"\u2026\", \"title\": \"\u2026\", \"icon\": \"\u2026\", \"screen\": \u2026 }`, where the screen is one of:\n\n- `{ \"type\": \"forms\", \"forms\": [\"<form id>\", \u2026] }`\n- `{ \"type\": \"dashboard\", \"dashboard\": \"<dashboard id>\" }`\n- `{ \"type\": \"menu\", \"items\": [ { \"form\": \"<id>\" } or { \"dashboard\": \"<id>\", \"description\": \"\u2026\" } ] }`\n\nUsually one tab for the forms and one per dashboard.\n";
|
|
7
7
|
/** The example the guide ends with, for tests and editors. */
|
|
8
8
|
export declare const EXAMPLE_TEMPLATE: AppTemplate;
|
|
9
9
|
export interface PromptContext {
|
package/dist/core/index.js
CHANGED
|
@@ -252,7 +252,7 @@
|
|
|
252
252
|
|
|
253
253
|
|
|
254
254
|
|
|
255
|
-
var
|
|
255
|
+
var _chunkIHOP6IEAjs = require('../chunk-IHOP6IEA.js');
|
|
256
256
|
|
|
257
257
|
|
|
258
258
|
|
|
@@ -507,4 +507,4 @@ var _chunk24ABPZKOjs = require('../chunk-24ABPZKO.js');
|
|
|
507
507
|
|
|
508
508
|
|
|
509
509
|
|
|
510
|
-
exports.ALL = _chunk24ABPZKOjs.ALL; exports.AUTHORING_GUIDE = _chunk24ABPZKOjs.AUTHORING_GUIDE; exports.BUNDLE_ACCEPT = _chunk24ABPZKOjs.BUNDLE_ACCEPT; exports.BUNDLE_TYPE = _chunk24ABPZKOjs.BUNDLE_TYPE; exports.CANVAS_GAP = _chunk24ABPZKOjs.CANVAS_GAP; exports.CANVAS_ROW_HEADER = _chunk24ABPZKOjs.CANVAS_ROW_HEADER; exports.ConfigLoader = _chunk24ABPZKOjs.ConfigLoader; exports.DASHBOARD_DS = _chunk24ABPZKOjs.DASHBOARD_DS; exports.DEFAULT_GAZETTEER = _chunk24ABPZKOjs.DEFAULT_GAZETTEER; exports.DICTATION_TYPES = _chunk24ABPZKOjs.DICTATION_TYPES; exports.DOCUMENT_GUIDE = _chunk24ABPZKOjs.DOCUMENT_GUIDE; exports.EDITABLE_VARIABLE_TYPES = _chunk24ABPZKOjs.EDITABLE_VARIABLE_TYPES; exports.EXAMPLE_TEMPLATE = _chunk24ABPZKOjs.EXAMPLE_TEMPLATE; exports.GRID_COLUMNS = _chunk24ABPZKOjs.GRID_COLUMNS; exports.GROUP_FIELD_TYPES = _chunk24ABPZKOjs.GROUP_FIELD_TYPES; exports.GrafanaClient = _chunk24ABPZKOjs.GrafanaClient; exports.GrafanaDataSource = _chunk24ABPZKOjs.GrafanaDataSource; exports.GrafanaError = _chunk24ABPZKOjs.GrafanaError; exports.HttpConfigFiles = _chunk24ABPZKOjs.HttpConfigFiles; exports.INPUT_GROUP = _chunk24ABPZKOjs.INPUT_GROUP; exports.INPUT_OPTION_KEYS = _chunk24ABPZKOjs.INPUT_OPTION_KEYS; exports.INPUT_TYPES = _chunk24ABPZKOjs.INPUT_TYPES; exports.LOCAL_DATASOURCE_TYPE = _chunk24ABPZKOjs.LOCAL_DATASOURCE_TYPE; exports.LocalDataSource = _chunk24ABPZKOjs.LocalDataSource; exports.MANIFEST_VERSION = _chunk24ABPZKOjs.MANIFEST_VERSION; exports.MAPPING_TYPES = _chunk24ABPZKOjs.MAPPING_TYPES; exports.MemoryEntryStore = _chunk24ABPZKOjs.MemoryEntryStore; exports.NAMED_COLORS = _chunk24ABPZKOjs.NAMED_COLORS; exports.OPTION_CATEGORIES = _chunk24ABPZKOjs.OPTION_CATEGORIES; exports.OVERRIDE_MATCHERS = _chunk24ABPZKOjs.OVERRIDE_MATCHERS; exports.PANEL_TYPES = _chunk24ABPZKOjs.PANEL_TYPES; exports.REDUCER_LABELS = _chunk24ABPZKOjs.REDUCER_LABELS; exports.REFRESH_CHOICES = _chunk24ABPZKOjs.REFRESH_CHOICES; exports.RELATIVE_RANGES = _chunk24ABPZKOjs.RELATIVE_RANGES; exports.SERIES_PALETTE = _chunk24ABPZKOjs.SERIES_PALETTE; exports.SNIPPET_VERSION = _chunk24ABPZKOjs.SNIPPET_VERSION; exports.SPECIAL_MATCHES = _chunk24ABPZKOjs.SPECIAL_MATCHES; exports.SaveConflictError = _chunk24ABPZKOjs.SaveConflictError; exports.TEMPLATE_VERSION = _chunk24ABPZKOjs.TEMPLATE_VERSION; exports.TIME_PRESETS = _chunk24ABPZKOjs.TIME_PRESETS; exports.UNIT_CHOICES = _chunk24ABPZKOjs.UNIT_CHOICES; exports.addTime = _chunk24ABPZKOjs.addTime; exports.appSchema = _chunk24ABPZKOjs.appSchema; exports.applyDashboardLink = _chunk24ABPZKOjs.applyDashboardLink; exports.applyJsonEdits = _chunk24ABPZKOjs.applyJsonEdits; exports.applyTemplate = _chunk24ABPZKOjs.applyTemplate; exports.applyTransformations = _chunk24ABPZKOjs.applyTransformations; exports.assembleBundle = _chunk24ABPZKOjs.assembleBundle; exports.assembleFromResponse = _chunk24ABPZKOjs.assembleFromResponse; exports.buildFrames = _chunk24ABPZKOjs.buildFrames; exports.bundleFromFiles = _chunk24ABPZKOjs.bundleFromFiles; exports.bundleRoot = _chunk24ABPZKOjs.bundleRoot; exports.calculateInterval = _chunk24ABPZKOjs.calculateInterval; exports.checkFiles = _chunk24ABPZKOjs.checkFiles; exports.choicesOf = _chunk24ABPZKOjs.choicesOf; exports.cleanDashboard = _chunk24ABPZKOjs.cleanDashboard; exports.cleanPanelOptions = _chunk24ABPZKOjs.cleanPanelOptions; exports.collapseRow = _chunk24ABPZKOjs.collapseRow; exports.compactGrid = _chunk24ABPZKOjs.compactGrid; exports.copyPanels = _chunk24ABPZKOjs.copyPanels; exports.dashboardSchema = _chunk24ABPZKOjs.dashboardSchema; exports.dashboardSchemaIssues = _chunk24ABPZKOjs.dashboardSchemaIssues; exports.dashboardSourceIds = _chunk24ABPZKOjs.dashboardSourceIds; exports.defaultFetchJson = _chunk24ABPZKOjs.defaultFetchJson; exports.describeRange = _chunk24ABPZKOjs.describeRange; exports.dictationHints = _chunk24ABPZKOjs.dictationHints; exports.diffJson = _chunk24ABPZKOjs.diffJson; exports.documentChanges = _chunk24ABPZKOjs.documentChanges; exports.documentIdFor = _chunk24ABPZKOjs.documentIdFor; exports.documentKind = _chunk24ABPZKOjs.documentKind; exports.documentPrompt = _chunk24ABPZKOjs.documentPrompt; exports.documentUses = _chunk24ABPZKOjs.documentUses; exports.dropTarget = _chunk24ABPZKOjs.dropTarget; exports.duplicatePanel = _chunk24ABPZKOjs.duplicatePanel; exports.entriesSavedWith = _chunk24ABPZKOjs.entriesSavedWith; exports.entriesToItems = _chunk24ABPZKOjs.entriesToItems; exports.entryToInputValue = _chunk24ABPZKOjs.entryToInputValue; exports.expandRow = _chunk24ABPZKOjs.expandRow; exports.fetchBundle = _chunk24ABPZKOjs.fetchBundle; exports.fetchJsonWithToken = _chunk24ABPZKOjs.fetchJsonWithToken; exports.fieldDisplayName = _chunk24ABPZKOjs.fieldDisplayName; exports.fieldMatches = _chunk24ABPZKOjs.fieldMatches; exports.fillForm = _chunk24ABPZKOjs.fillForm; exports.fillHints = _chunk24ABPZKOjs.fillHints; exports.fillPrompt = _chunk24ABPZKOjs.fillPrompt; exports.fillSchema = _chunk24ABPZKOjs.fillSchema; exports.fixDocumentPrompt = _chunk24ABPZKOjs.fixDocumentPrompt; exports.fixTemplatePrompt = _chunk24ABPZKOjs.fixTemplatePrompt; exports.formatClock = _chunk24ABPZKOjs.formatClock; exports.formatDisplay = _chunk24ABPZKOjs.formatDisplay; exports.formatDuration = _chunk24ABPZKOjs.formatDuration; exports.formatJsonText = _chunk24ABPZKOjs.formatJsonText; exports.formatLocalDateTime = _chunk24ABPZKOjs.formatLocalDateTime; exports.formatValue = _chunk24ABPZKOjs.formatValue; exports.frameLength = _chunk24ABPZKOjs.frameLength; exports.framesToOptions = _chunk24ABPZKOjs.framesToOptions; exports.fromWire = _chunk24ABPZKOjs.fromWire; exports.getPath = _chunk24ABPZKOjs.getPath; exports.gridOffsetPx = _chunk24ABPZKOjs.gridOffsetPx; exports.gridUnitsToPx = _chunk24ABPZKOjs.gridUnitsToPx; exports.groupField = _chunk24ABPZKOjs.groupField; exports.groupFields = _chunk24ABPZKOjs.groupFields; exports.groupProblems = _chunk24ABPZKOjs.groupProblems; exports.groupToEntries = _chunk24ABPZKOjs.groupToEntries; exports.httpFetchJson = _chunk24ABPZKOjs.httpFetchJson; exports.initialVariableValues = _chunk24ABPZKOjs.initialVariableValues; exports.inputGroups = _chunk24ABPZKOjs.inputGroups; exports.inputPanels = _chunk24ABPZKOjs.inputPanels; exports.inputProblem = _chunk24ABPZKOjs.inputProblem; exports.insertPanel = _chunk24ABPZKOjs.insertPanel; exports.interpolate = _chunk24ABPZKOjs.interpolate; exports.interpolateDeep = _chunk24ABPZKOjs.interpolateDeep; exports.isBundleResponse = _chunk24ABPZKOjs.isBundleResponse; exports.isEditableVariableType = _chunk24ABPZKOjs.isEditableVariableType; exports.isEmptyItem = _chunk24ABPZKOjs.isEmptyItem; exports.isFormPanelType = _chunk24ABPZKOjs.isFormPanelType; exports.isInputGroup = _chunk24ABPZKOjs.isInputGroup; exports.isInputPanel = _chunk24ABPZKOjs.isInputPanel; exports.isInputType = _chunk24ABPZKOjs.isInputType; exports.isLocalDatasource = _chunk24ABPZKOjs.isLocalDatasource; exports.isReducer = _chunk24ABPZKOjs.isReducer; exports.isRow = _chunk24ABPZKOjs.isRow; exports.isSqlDatasource = _chunk24ABPZKOjs.isSqlDatasource; exports.jsonFromAnswer = _chunk24ABPZKOjs.jsonFromAnswer; exports.layoutCanvas = _chunk24ABPZKOjs.layoutCanvas; exports.layoutDashboard = _chunk24ABPZKOjs.layoutDashboard; exports.lineColumn = _chunk24ABPZKOjs.lineColumn; exports.loadGazetteer = _chunk24ABPZKOjs.loadGazetteer; exports.locate = _chunk24ABPZKOjs.locate; exports.makeTemplate = _chunk24ABPZKOjs.makeTemplate; exports.manifestSchemaIssues = _chunk24ABPZKOjs.manifestSchemaIssues; exports.mappedResult = _chunk24ABPZKOjs.mappedResult; exports.mappingProblem = _chunk24ABPZKOjs.mappingProblem; exports.mappingRow = _chunk24ABPZKOjs.mappingRow; exports.mappingRows = _chunk24ABPZKOjs.mappingRows; exports.matchChoices = _chunk24ABPZKOjs.matchChoices; exports.metricChanges = _chunk24ABPZKOjs.metricChanges; exports.modelFiller = _chunk24ABPZKOjs.modelFiller; exports.movePanel = _chunk24ABPZKOjs.movePanel; exports.newDocument = _chunk24ABPZKOjs.newDocument; exports.newPanel = _chunk24ABPZKOjs.newPanel; exports.newSaveId = _chunk24ABPZKOjs.newSaveId; exports.newVariable = _chunk24ABPZKOjs.newVariable; exports.nextPanelId = _chunk24ABPZKOjs.nextPanelId; exports.normalizeRef = _chunk24ABPZKOjs.normalizeRef; exports.numberFields = _chunk24ABPZKOjs.numberFields; exports.optionValue = _chunk24ABPZKOjs.optionValue; exports.overrideProperties = _chunk24ABPZKOjs.overrideProperties; exports.panelEdits = _chunk24ABPZKOjs.panelEdits; exports.panelHasQueries = _chunk24ABPZKOjs.panelHasQueries; exports.panelKey = _chunk24ABPZKOjs.panelKey; exports.panelMetrics = _chunk24ABPZKOjs.panelMetrics; exports.panelOptions = _chunk24ABPZKOjs.panelOptions; exports.panelOverrides = _chunk24ABPZKOjs.panelOverrides; exports.panelSize = _chunk24ABPZKOjs.panelSize; exports.panelSpan = _chunk24ABPZKOjs.panelSpan; exports.parseClockDigits = _chunk24ABPZKOjs.parseClockDigits; exports.parseDashboardLink = _chunk24ABPZKOjs.parseDashboardLink; exports.parseDuration = _chunk24ABPZKOjs.parseDuration; exports.parseFillAnswer = _chunk24ABPZKOjs.parseFillAnswer; exports.parseGazetteer = _chunk24ABPZKOjs.parseGazetteer; exports.parseJsonText = _chunk24ABPZKOjs.parseJsonText; exports.parseLocalDateTime = _chunk24ABPZKOjs.parseLocalDateTime; exports.parseRange = _chunk24ABPZKOjs.parseRange; exports.parseSnippet = _chunk24ABPZKOjs.parseSnippet; exports.parseSpokenDuration = _chunk24ABPZKOjs.parseSpokenDuration; exports.parseSpokenNumber = _chunk24ABPZKOjs.parseSpokenNumber; exports.parseSpokenYesNo = _chunk24ABPZKOjs.parseSpokenYesNo; exports.parseTemplate = _chunk24ABPZKOjs.parseTemplate; exports.parseTime = _chunk24ABPZKOjs.parseTime; exports.pasteSnippet = _chunk24ABPZKOjs.pasteSnippet; exports.placePanel = _chunk24ABPZKOjs.placePanel; exports.plainInputPanels = _chunk24ABPZKOjs.plainInputPanels; exports.pointerToPath = _chunk24ABPZKOjs.pointerToPath; exports.prepareDashboard = _chunk24ABPZKOjs.prepareDashboard; exports.previewPaste = _chunk24ABPZKOjs.previewPaste; exports.queryPanel = _chunk24ABPZKOjs.queryPanel; exports.queryParam = _chunk24ABPZKOjs.queryParam; exports.readConfigFiles = _chunk24ABPZKOjs.readConfigFiles; exports.readDocumentAnswer = _chunk24ABPZKOjs.readDocumentAnswer; exports.readFill = _chunk24ABPZKOjs.readFill; exports.readTemplateAnswer = _chunk24ABPZKOjs.readTemplateAnswer; exports.readingOrder = _chunk24ABPZKOjs.readingOrder; exports.reduce = _chunk24ABPZKOjs.reduce; exports.refineOptions = _chunk24ABPZKOjs.refineOptions; exports.refreshedVariables = _chunk24ABPZKOjs.refreshedVariables; exports.removeDocumentFromManifest = _chunk24ABPZKOjs.removeDocumentFromManifest; exports.removePanel = _chunk24ABPZKOjs.removePanel; exports.renameDocumentInManifest = _chunk24ABPZKOjs.renameDocumentInManifest; exports.renameMetrics = _chunk24ABPZKOjs.renameMetrics; exports.renameVariableInPanels = _chunk24ABPZKOjs.renameVariableInPanels; exports.repack = _chunk24ABPZKOjs.repack; exports.repeatOptions = _chunk24ABPZKOjs.repeatOptions; exports.requiredManifestVersion = _chunk24ABPZKOjs.requiredManifestVersion; exports.resizePanel = _chunk24ABPZKOjs.resizePanel; exports.resolveColor = _chunk24ABPZKOjs.resolveColor; exports.resolveFieldConfig = _chunk24ABPZKOjs.resolveFieldConfig; exports.resolveLinks = _chunk24ABPZKOjs.resolveLinks; exports.resolveTimezone = _chunk24ABPZKOjs.resolveTimezone; exports.resolveUrl = _chunk24ABPZKOjs.resolveUrl; exports.resolveVariables = _chunk24ABPZKOjs.resolveVariables; exports.revalidateBundle = _chunk24ABPZKOjs.revalidateBundle; exports.rowsToMappings = _chunk24ABPZKOjs.rowsToMappings; exports.ruleFill = _chunk24ABPZKOjs.ruleFill; exports.ruleFiller = _chunk24ABPZKOjs.ruleFiller; exports.sameSave = _chunk24ABPZKOjs.sameSave; exports.sampleEntries = _chunk24ABPZKOjs.sampleEntries; exports.screenDocuments = _chunk24ABPZKOjs.screenDocuments; exports.screenOfType = _chunk24ABPZKOjs.screenOfType; exports.selectValue = _chunk24ABPZKOjs.selectValue; exports.seriesColor = _chunk24ABPZKOjs.seriesColor; exports.setHiddenOnPhones = _chunk24ABPZKOjs.setHiddenOnPhones; exports.setJsonValue = _chunk24ABPZKOjs.setJsonValue; exports.setOption = _chunk24ABPZKOjs.setOption; exports.setOptionValue = _chunk24ABPZKOjs.setOptionValue; exports.setOverrides = _chunk24ABPZKOjs.setOverrides; exports.settleLayout = _chunk24ABPZKOjs.settleLayout; exports.snapToGrid = _chunk24ABPZKOjs.snapToGrid; exports.splitPath = _chunk24ABPZKOjs.splitPath; exports.spokenValue = _chunk24ABPZKOjs.spokenValue; exports.startOf = _chunk24ABPZKOjs.startOf; exports.stringifyCompact = _chunk24ABPZKOjs.stringifyCompact; exports.tabIdFor = _chunk24ABPZKOjs.tabIdFor; exports.takesDictation = _chunk24ABPZKOjs.takesDictation; exports.templateNeeds = _chunk24ABPZKOjs.templateNeeds; exports.templatePrompt = _chunk24ABPZKOjs.templatePrompt; exports.textSuggestions = _chunk24ABPZKOjs.textSuggestions; exports.thresholdStep = _chunk24ABPZKOjs.thresholdStep; exports.timeExprError = _chunk24ABPZKOjs.timeExprError; exports.timeField = _chunk24ABPZKOjs.timeField; exports.toEntries = _chunk24ABPZKOjs.toEntries; exports.toMillis = _chunk24ABPZKOjs.toMillis; exports.toSeries = _chunk24ABPZKOjs.toSeries; exports.toXYSeries = _chunk24ABPZKOjs.toXYSeries; exports.uniqueNames = _chunk24ABPZKOjs.uniqueNames; exports.validateBundle = _chunk24ABPZKOjs.validateBundle; exports.validateDashboard = _chunk24ABPZKOjs.validateDashboard; exports.validateManifest = _chunk24ABPZKOjs.validateManifest; exports.valueColor = _chunk24ABPZKOjs.valueColor; exports.valueText = _chunk24ABPZKOjs.valueText; exports.variableDependents = _chunk24ABPZKOjs.variableDependents; exports.variableInfo = _chunk24ABPZKOjs.variableInfo; exports.variableNameError = _chunk24ABPZKOjs.variableNameError; exports.variableOptions = _chunk24ABPZKOjs.variableOptions; exports.variableOrder = _chunk24ABPZKOjs.variableOrder; exports.variableReferences = _chunk24ABPZKOjs.variableReferences; exports.variableUses = _chunk24ABPZKOjs.variableUses; exports.variableWithCurrent = _chunk24ABPZKOjs.variableWithCurrent; exports.variableWithFlags = _chunk24ABPZKOjs.variableWithFlags; exports.variableWithQuery = _chunk24ABPZKOjs.variableWithQuery; exports.variableWithType = _chunk24ABPZKOjs.variableWithType; exports.visibleVariables = _chunk24ABPZKOjs.visibleVariables; exports.zoomRange = _chunk24ABPZKOjs.zoomRange;
|
|
510
|
+
exports.ALL = _chunkIHOP6IEAjs.ALL; exports.AUTHORING_GUIDE = _chunkIHOP6IEAjs.AUTHORING_GUIDE; exports.BUNDLE_ACCEPT = _chunkIHOP6IEAjs.BUNDLE_ACCEPT; exports.BUNDLE_TYPE = _chunkIHOP6IEAjs.BUNDLE_TYPE; exports.CANVAS_GAP = _chunkIHOP6IEAjs.CANVAS_GAP; exports.CANVAS_ROW_HEADER = _chunkIHOP6IEAjs.CANVAS_ROW_HEADER; exports.ConfigLoader = _chunkIHOP6IEAjs.ConfigLoader; exports.DASHBOARD_DS = _chunkIHOP6IEAjs.DASHBOARD_DS; exports.DEFAULT_GAZETTEER = _chunkIHOP6IEAjs.DEFAULT_GAZETTEER; exports.DICTATION_TYPES = _chunkIHOP6IEAjs.DICTATION_TYPES; exports.DOCUMENT_GUIDE = _chunkIHOP6IEAjs.DOCUMENT_GUIDE; exports.EDITABLE_VARIABLE_TYPES = _chunkIHOP6IEAjs.EDITABLE_VARIABLE_TYPES; exports.EXAMPLE_TEMPLATE = _chunkIHOP6IEAjs.EXAMPLE_TEMPLATE; exports.GRID_COLUMNS = _chunkIHOP6IEAjs.GRID_COLUMNS; exports.GROUP_FIELD_TYPES = _chunkIHOP6IEAjs.GROUP_FIELD_TYPES; exports.GrafanaClient = _chunkIHOP6IEAjs.GrafanaClient; exports.GrafanaDataSource = _chunkIHOP6IEAjs.GrafanaDataSource; exports.GrafanaError = _chunkIHOP6IEAjs.GrafanaError; exports.HttpConfigFiles = _chunkIHOP6IEAjs.HttpConfigFiles; exports.INPUT_GROUP = _chunkIHOP6IEAjs.INPUT_GROUP; exports.INPUT_OPTION_KEYS = _chunkIHOP6IEAjs.INPUT_OPTION_KEYS; exports.INPUT_TYPES = _chunkIHOP6IEAjs.INPUT_TYPES; exports.LOCAL_DATASOURCE_TYPE = _chunkIHOP6IEAjs.LOCAL_DATASOURCE_TYPE; exports.LocalDataSource = _chunkIHOP6IEAjs.LocalDataSource; exports.MANIFEST_VERSION = _chunkIHOP6IEAjs.MANIFEST_VERSION; exports.MAPPING_TYPES = _chunkIHOP6IEAjs.MAPPING_TYPES; exports.MemoryEntryStore = _chunkIHOP6IEAjs.MemoryEntryStore; exports.NAMED_COLORS = _chunkIHOP6IEAjs.NAMED_COLORS; exports.OPTION_CATEGORIES = _chunkIHOP6IEAjs.OPTION_CATEGORIES; exports.OVERRIDE_MATCHERS = _chunkIHOP6IEAjs.OVERRIDE_MATCHERS; exports.PANEL_TYPES = _chunkIHOP6IEAjs.PANEL_TYPES; exports.REDUCER_LABELS = _chunkIHOP6IEAjs.REDUCER_LABELS; exports.REFRESH_CHOICES = _chunkIHOP6IEAjs.REFRESH_CHOICES; exports.RELATIVE_RANGES = _chunkIHOP6IEAjs.RELATIVE_RANGES; exports.SERIES_PALETTE = _chunkIHOP6IEAjs.SERIES_PALETTE; exports.SNIPPET_VERSION = _chunkIHOP6IEAjs.SNIPPET_VERSION; exports.SPECIAL_MATCHES = _chunkIHOP6IEAjs.SPECIAL_MATCHES; exports.SaveConflictError = _chunkIHOP6IEAjs.SaveConflictError; exports.TEMPLATE_VERSION = _chunkIHOP6IEAjs.TEMPLATE_VERSION; exports.TIME_PRESETS = _chunkIHOP6IEAjs.TIME_PRESETS; exports.UNIT_CHOICES = _chunkIHOP6IEAjs.UNIT_CHOICES; exports.addTime = _chunkIHOP6IEAjs.addTime; exports.appSchema = _chunkIHOP6IEAjs.appSchema; exports.applyDashboardLink = _chunkIHOP6IEAjs.applyDashboardLink; exports.applyJsonEdits = _chunkIHOP6IEAjs.applyJsonEdits; exports.applyTemplate = _chunkIHOP6IEAjs.applyTemplate; exports.applyTransformations = _chunkIHOP6IEAjs.applyTransformations; exports.assembleBundle = _chunkIHOP6IEAjs.assembleBundle; exports.assembleFromResponse = _chunkIHOP6IEAjs.assembleFromResponse; exports.buildFrames = _chunkIHOP6IEAjs.buildFrames; exports.bundleFromFiles = _chunkIHOP6IEAjs.bundleFromFiles; exports.bundleRoot = _chunkIHOP6IEAjs.bundleRoot; exports.calculateInterval = _chunkIHOP6IEAjs.calculateInterval; exports.checkFiles = _chunkIHOP6IEAjs.checkFiles; exports.choicesOf = _chunkIHOP6IEAjs.choicesOf; exports.cleanDashboard = _chunkIHOP6IEAjs.cleanDashboard; exports.cleanPanelOptions = _chunkIHOP6IEAjs.cleanPanelOptions; exports.collapseRow = _chunkIHOP6IEAjs.collapseRow; exports.compactGrid = _chunkIHOP6IEAjs.compactGrid; exports.copyPanels = _chunkIHOP6IEAjs.copyPanels; exports.dashboardSchema = _chunkIHOP6IEAjs.dashboardSchema; exports.dashboardSchemaIssues = _chunkIHOP6IEAjs.dashboardSchemaIssues; exports.dashboardSourceIds = _chunkIHOP6IEAjs.dashboardSourceIds; exports.defaultFetchJson = _chunkIHOP6IEAjs.defaultFetchJson; exports.describeRange = _chunkIHOP6IEAjs.describeRange; exports.dictationHints = _chunkIHOP6IEAjs.dictationHints; exports.diffJson = _chunkIHOP6IEAjs.diffJson; exports.documentChanges = _chunkIHOP6IEAjs.documentChanges; exports.documentIdFor = _chunkIHOP6IEAjs.documentIdFor; exports.documentKind = _chunkIHOP6IEAjs.documentKind; exports.documentPrompt = _chunkIHOP6IEAjs.documentPrompt; exports.documentUses = _chunkIHOP6IEAjs.documentUses; exports.dropTarget = _chunkIHOP6IEAjs.dropTarget; exports.duplicatePanel = _chunkIHOP6IEAjs.duplicatePanel; exports.entriesSavedWith = _chunkIHOP6IEAjs.entriesSavedWith; exports.entriesToItems = _chunkIHOP6IEAjs.entriesToItems; exports.entryToInputValue = _chunkIHOP6IEAjs.entryToInputValue; exports.expandRow = _chunkIHOP6IEAjs.expandRow; exports.fetchBundle = _chunkIHOP6IEAjs.fetchBundle; exports.fetchJsonWithToken = _chunkIHOP6IEAjs.fetchJsonWithToken; exports.fieldDisplayName = _chunkIHOP6IEAjs.fieldDisplayName; exports.fieldMatches = _chunkIHOP6IEAjs.fieldMatches; exports.fillForm = _chunkIHOP6IEAjs.fillForm; exports.fillHints = _chunkIHOP6IEAjs.fillHints; exports.fillPrompt = _chunkIHOP6IEAjs.fillPrompt; exports.fillSchema = _chunkIHOP6IEAjs.fillSchema; exports.fixDocumentPrompt = _chunkIHOP6IEAjs.fixDocumentPrompt; exports.fixTemplatePrompt = _chunkIHOP6IEAjs.fixTemplatePrompt; exports.formatClock = _chunkIHOP6IEAjs.formatClock; exports.formatDisplay = _chunkIHOP6IEAjs.formatDisplay; exports.formatDuration = _chunkIHOP6IEAjs.formatDuration; exports.formatJsonText = _chunkIHOP6IEAjs.formatJsonText; exports.formatLocalDateTime = _chunkIHOP6IEAjs.formatLocalDateTime; exports.formatValue = _chunkIHOP6IEAjs.formatValue; exports.frameLength = _chunkIHOP6IEAjs.frameLength; exports.framesToOptions = _chunkIHOP6IEAjs.framesToOptions; exports.fromWire = _chunkIHOP6IEAjs.fromWire; exports.getPath = _chunkIHOP6IEAjs.getPath; exports.gridOffsetPx = _chunkIHOP6IEAjs.gridOffsetPx; exports.gridUnitsToPx = _chunkIHOP6IEAjs.gridUnitsToPx; exports.groupField = _chunkIHOP6IEAjs.groupField; exports.groupFields = _chunkIHOP6IEAjs.groupFields; exports.groupProblems = _chunkIHOP6IEAjs.groupProblems; exports.groupToEntries = _chunkIHOP6IEAjs.groupToEntries; exports.httpFetchJson = _chunkIHOP6IEAjs.httpFetchJson; exports.initialVariableValues = _chunkIHOP6IEAjs.initialVariableValues; exports.inputGroups = _chunkIHOP6IEAjs.inputGroups; exports.inputPanels = _chunkIHOP6IEAjs.inputPanels; exports.inputProblem = _chunkIHOP6IEAjs.inputProblem; exports.insertPanel = _chunkIHOP6IEAjs.insertPanel; exports.interpolate = _chunkIHOP6IEAjs.interpolate; exports.interpolateDeep = _chunkIHOP6IEAjs.interpolateDeep; exports.isBundleResponse = _chunkIHOP6IEAjs.isBundleResponse; exports.isEditableVariableType = _chunkIHOP6IEAjs.isEditableVariableType; exports.isEmptyItem = _chunkIHOP6IEAjs.isEmptyItem; exports.isFormPanelType = _chunkIHOP6IEAjs.isFormPanelType; exports.isInputGroup = _chunkIHOP6IEAjs.isInputGroup; exports.isInputPanel = _chunkIHOP6IEAjs.isInputPanel; exports.isInputType = _chunkIHOP6IEAjs.isInputType; exports.isLocalDatasource = _chunkIHOP6IEAjs.isLocalDatasource; exports.isReducer = _chunkIHOP6IEAjs.isReducer; exports.isRow = _chunkIHOP6IEAjs.isRow; exports.isSqlDatasource = _chunkIHOP6IEAjs.isSqlDatasource; exports.jsonFromAnswer = _chunkIHOP6IEAjs.jsonFromAnswer; exports.layoutCanvas = _chunkIHOP6IEAjs.layoutCanvas; exports.layoutDashboard = _chunkIHOP6IEAjs.layoutDashboard; exports.lineColumn = _chunkIHOP6IEAjs.lineColumn; exports.loadGazetteer = _chunkIHOP6IEAjs.loadGazetteer; exports.locate = _chunkIHOP6IEAjs.locate; exports.makeTemplate = _chunkIHOP6IEAjs.makeTemplate; exports.manifestSchemaIssues = _chunkIHOP6IEAjs.manifestSchemaIssues; exports.mappedResult = _chunkIHOP6IEAjs.mappedResult; exports.mappingProblem = _chunkIHOP6IEAjs.mappingProblem; exports.mappingRow = _chunkIHOP6IEAjs.mappingRow; exports.mappingRows = _chunkIHOP6IEAjs.mappingRows; exports.matchChoices = _chunkIHOP6IEAjs.matchChoices; exports.metricChanges = _chunkIHOP6IEAjs.metricChanges; exports.modelFiller = _chunkIHOP6IEAjs.modelFiller; exports.movePanel = _chunkIHOP6IEAjs.movePanel; exports.newDocument = _chunkIHOP6IEAjs.newDocument; exports.newPanel = _chunkIHOP6IEAjs.newPanel; exports.newSaveId = _chunkIHOP6IEAjs.newSaveId; exports.newVariable = _chunkIHOP6IEAjs.newVariable; exports.nextPanelId = _chunkIHOP6IEAjs.nextPanelId; exports.normalizeRef = _chunkIHOP6IEAjs.normalizeRef; exports.numberFields = _chunkIHOP6IEAjs.numberFields; exports.optionValue = _chunkIHOP6IEAjs.optionValue; exports.overrideProperties = _chunkIHOP6IEAjs.overrideProperties; exports.panelEdits = _chunkIHOP6IEAjs.panelEdits; exports.panelHasQueries = _chunkIHOP6IEAjs.panelHasQueries; exports.panelKey = _chunkIHOP6IEAjs.panelKey; exports.panelMetrics = _chunkIHOP6IEAjs.panelMetrics; exports.panelOptions = _chunkIHOP6IEAjs.panelOptions; exports.panelOverrides = _chunkIHOP6IEAjs.panelOverrides; exports.panelSize = _chunkIHOP6IEAjs.panelSize; exports.panelSpan = _chunkIHOP6IEAjs.panelSpan; exports.parseClockDigits = _chunkIHOP6IEAjs.parseClockDigits; exports.parseDashboardLink = _chunkIHOP6IEAjs.parseDashboardLink; exports.parseDuration = _chunkIHOP6IEAjs.parseDuration; exports.parseFillAnswer = _chunkIHOP6IEAjs.parseFillAnswer; exports.parseGazetteer = _chunkIHOP6IEAjs.parseGazetteer; exports.parseJsonText = _chunkIHOP6IEAjs.parseJsonText; exports.parseLocalDateTime = _chunkIHOP6IEAjs.parseLocalDateTime; exports.parseRange = _chunkIHOP6IEAjs.parseRange; exports.parseSnippet = _chunkIHOP6IEAjs.parseSnippet; exports.parseSpokenDuration = _chunkIHOP6IEAjs.parseSpokenDuration; exports.parseSpokenNumber = _chunkIHOP6IEAjs.parseSpokenNumber; exports.parseSpokenYesNo = _chunkIHOP6IEAjs.parseSpokenYesNo; exports.parseTemplate = _chunkIHOP6IEAjs.parseTemplate; exports.parseTime = _chunkIHOP6IEAjs.parseTime; exports.pasteSnippet = _chunkIHOP6IEAjs.pasteSnippet; exports.placePanel = _chunkIHOP6IEAjs.placePanel; exports.plainInputPanels = _chunkIHOP6IEAjs.plainInputPanels; exports.pointerToPath = _chunkIHOP6IEAjs.pointerToPath; exports.prepareDashboard = _chunkIHOP6IEAjs.prepareDashboard; exports.previewPaste = _chunkIHOP6IEAjs.previewPaste; exports.queryPanel = _chunkIHOP6IEAjs.queryPanel; exports.queryParam = _chunkIHOP6IEAjs.queryParam; exports.readConfigFiles = _chunkIHOP6IEAjs.readConfigFiles; exports.readDocumentAnswer = _chunkIHOP6IEAjs.readDocumentAnswer; exports.readFill = _chunkIHOP6IEAjs.readFill; exports.readTemplateAnswer = _chunkIHOP6IEAjs.readTemplateAnswer; exports.readingOrder = _chunkIHOP6IEAjs.readingOrder; exports.reduce = _chunkIHOP6IEAjs.reduce; exports.refineOptions = _chunkIHOP6IEAjs.refineOptions; exports.refreshedVariables = _chunkIHOP6IEAjs.refreshedVariables; exports.removeDocumentFromManifest = _chunkIHOP6IEAjs.removeDocumentFromManifest; exports.removePanel = _chunkIHOP6IEAjs.removePanel; exports.renameDocumentInManifest = _chunkIHOP6IEAjs.renameDocumentInManifest; exports.renameMetrics = _chunkIHOP6IEAjs.renameMetrics; exports.renameVariableInPanels = _chunkIHOP6IEAjs.renameVariableInPanels; exports.repack = _chunkIHOP6IEAjs.repack; exports.repeatOptions = _chunkIHOP6IEAjs.repeatOptions; exports.requiredManifestVersion = _chunkIHOP6IEAjs.requiredManifestVersion; exports.resizePanel = _chunkIHOP6IEAjs.resizePanel; exports.resolveColor = _chunkIHOP6IEAjs.resolveColor; exports.resolveFieldConfig = _chunkIHOP6IEAjs.resolveFieldConfig; exports.resolveLinks = _chunkIHOP6IEAjs.resolveLinks; exports.resolveTimezone = _chunkIHOP6IEAjs.resolveTimezone; exports.resolveUrl = _chunkIHOP6IEAjs.resolveUrl; exports.resolveVariables = _chunkIHOP6IEAjs.resolveVariables; exports.revalidateBundle = _chunkIHOP6IEAjs.revalidateBundle; exports.rowsToMappings = _chunkIHOP6IEAjs.rowsToMappings; exports.ruleFill = _chunkIHOP6IEAjs.ruleFill; exports.ruleFiller = _chunkIHOP6IEAjs.ruleFiller; exports.sameSave = _chunkIHOP6IEAjs.sameSave; exports.sampleEntries = _chunkIHOP6IEAjs.sampleEntries; exports.screenDocuments = _chunkIHOP6IEAjs.screenDocuments; exports.screenOfType = _chunkIHOP6IEAjs.screenOfType; exports.selectValue = _chunkIHOP6IEAjs.selectValue; exports.seriesColor = _chunkIHOP6IEAjs.seriesColor; exports.setHiddenOnPhones = _chunkIHOP6IEAjs.setHiddenOnPhones; exports.setJsonValue = _chunkIHOP6IEAjs.setJsonValue; exports.setOption = _chunkIHOP6IEAjs.setOption; exports.setOptionValue = _chunkIHOP6IEAjs.setOptionValue; exports.setOverrides = _chunkIHOP6IEAjs.setOverrides; exports.settleLayout = _chunkIHOP6IEAjs.settleLayout; exports.snapToGrid = _chunkIHOP6IEAjs.snapToGrid; exports.splitPath = _chunkIHOP6IEAjs.splitPath; exports.spokenValue = _chunkIHOP6IEAjs.spokenValue; exports.startOf = _chunkIHOP6IEAjs.startOf; exports.stringifyCompact = _chunkIHOP6IEAjs.stringifyCompact; exports.tabIdFor = _chunkIHOP6IEAjs.tabIdFor; exports.takesDictation = _chunkIHOP6IEAjs.takesDictation; exports.templateNeeds = _chunkIHOP6IEAjs.templateNeeds; exports.templatePrompt = _chunkIHOP6IEAjs.templatePrompt; exports.textSuggestions = _chunkIHOP6IEAjs.textSuggestions; exports.thresholdStep = _chunkIHOP6IEAjs.thresholdStep; exports.timeExprError = _chunkIHOP6IEAjs.timeExprError; exports.timeField = _chunkIHOP6IEAjs.timeField; exports.toEntries = _chunkIHOP6IEAjs.toEntries; exports.toMillis = _chunkIHOP6IEAjs.toMillis; exports.toSeries = _chunkIHOP6IEAjs.toSeries; exports.toXYSeries = _chunkIHOP6IEAjs.toXYSeries; exports.uniqueNames = _chunkIHOP6IEAjs.uniqueNames; exports.validateBundle = _chunkIHOP6IEAjs.validateBundle; exports.validateDashboard = _chunkIHOP6IEAjs.validateDashboard; exports.validateManifest = _chunkIHOP6IEAjs.validateManifest; exports.valueColor = _chunkIHOP6IEAjs.valueColor; exports.valueText = _chunkIHOP6IEAjs.valueText; exports.variableDependents = _chunkIHOP6IEAjs.variableDependents; exports.variableInfo = _chunkIHOP6IEAjs.variableInfo; exports.variableNameError = _chunkIHOP6IEAjs.variableNameError; exports.variableOptions = _chunkIHOP6IEAjs.variableOptions; exports.variableOrder = _chunkIHOP6IEAjs.variableOrder; exports.variableReferences = _chunkIHOP6IEAjs.variableReferences; exports.variableUses = _chunkIHOP6IEAjs.variableUses; exports.variableWithCurrent = _chunkIHOP6IEAjs.variableWithCurrent; exports.variableWithFlags = _chunkIHOP6IEAjs.variableWithFlags; exports.variableWithQuery = _chunkIHOP6IEAjs.variableWithQuery; exports.variableWithType = _chunkIHOP6IEAjs.variableWithType; exports.visibleVariables = _chunkIHOP6IEAjs.visibleVariables; exports.zoomRange = _chunkIHOP6IEAjs.zoomRange;
|