diff --git a/lib/www/client/source/package-lock.json b/lib/www/client/source/package-lock.json index 97dbf38..a154d66 100644 --- a/lib/www/client/source/package-lock.json +++ b/lib/www/client/source/package-lock.json @@ -18,7 +18,7 @@ "leaflet-realtime": "^2.2.0", "leaflet.markercluster": "^1.4.1", "marked": "^2.0.3", - "plotly.js-dist": "^2.5.0", + "plotly.js-dist": "^2.27.0", "suncalc": "^1.8.0", "typeface-roboto": "0.0.75", "vue": "^2.6.12", @@ -10317,9 +10317,9 @@ } }, "node_modules/plotly.js-dist": { - "version": "2.11.1", - "resolved": "https://registry.npmjs.org/plotly.js-dist/-/plotly.js-dist-2.11.1.tgz", - "integrity": "sha512-TubG71bBueWRMkQQMGlG8/0q753x5LLXzEHieUt9s0M/nD7WpnjC7sEwH+flhN6dOLqQ2wGlOb8Z4A3ah4IDWg==" + "version": "2.27.0", + "resolved": "https://registry.npmjs.org/plotly.js-dist/-/plotly.js-dist-2.27.0.tgz", + "integrity": "sha512-SuuIF6zpJpW+9ssgXghMdcaJ9mp06SATykpxBVSrX9PpX9YZpCg6oo/79WvjYUVHf33QreJ4csAJU3o5Ll32cQ==" }, "node_modules/pnp-webpack-plugin": { "version": "1.7.0", @@ -23254,9 +23254,9 @@ } }, "plotly.js-dist": { - "version": "2.11.1", - "resolved": "https://registry.npmjs.org/plotly.js-dist/-/plotly.js-dist-2.11.1.tgz", - "integrity": "sha512-TubG71bBueWRMkQQMGlG8/0q753x5LLXzEHieUt9s0M/nD7WpnjC7sEwH+flhN6dOLqQ2wGlOb8Z4A3ah4IDWg==" + "version": "2.27.0", + "resolved": "https://registry.npmjs.org/plotly.js-dist/-/plotly.js-dist-2.27.0.tgz", + "integrity": "sha512-SuuIF6zpJpW+9ssgXghMdcaJ9mp06SATykpxBVSrX9PpX9YZpCg6oo/79WvjYUVHf33QreJ4csAJU3o5Ll32cQ==" }, "pnp-webpack-plugin": { "version": "1.7.0", diff --git a/lib/www/client/source/package.json b/lib/www/client/source/package.json index 1156617..be41964 100644 --- a/lib/www/client/source/package.json +++ b/lib/www/client/source/package.json @@ -16,7 +16,7 @@ "leaflet-realtime": "^2.2.0", "leaflet.markercluster": "^1.4.1", "marked": "^2.0.3", - "plotly.js-dist": "^2.5.0", + "plotly.js-dist": "^2.27.0", "suncalc": "^1.8.0", "typeface-roboto": "0.0.75", "vue": "^2.6.12", diff --git a/lib/www/client/source/src/components/graphs/project/sequence/inline-crossline.vue b/lib/www/client/source/src/components/graphs/project/sequence/inline-crossline.vue new file mode 100644 index 0000000..3848f5e --- /dev/null +++ b/lib/www/client/source/src/components/graphs/project/sequence/inline-crossline.vue @@ -0,0 +1,290 @@ + + + + + diff --git a/lib/www/client/source/src/components/graphs/project/sequence/shotpoint-timing.vue b/lib/www/client/source/src/components/graphs/project/sequence/shotpoint-timing.vue new file mode 100644 index 0000000..af87d8c --- /dev/null +++ b/lib/www/client/source/src/components/graphs/project/sequence/shotpoint-timing.vue @@ -0,0 +1,196 @@ + + + + + diff --git a/lib/www/client/source/src/lib/unpack.js b/lib/www/client/source/src/lib/unpack.js index 0e5450b..0a4facf 100644 --- a/lib/www/client/source/src/lib/unpack.js +++ b/lib/www/client/source/src/lib/unpack.js @@ -1,4 +1,33 @@ - +/** Unpacks attributes from array items. + * + * At it simplest, given an array of objects, + * the call unpack(rows, "x") returns an array + * of the "x" attribute of every item in rows. + * + * `key` may also be: + * + * - a function with the signature + * (Object) => any + * the result of applying the function to + * the object will be used as the unpacked + * value. + * + * - an array of strings, functions or other + * arrays. In this case, it does a recursive + * fold operation. NOTE: it mutates `key`. + * + */ export default function unpack(rows, key) { - return rows && rows.map( row => row[key] ); + if (typeof key === "function") { + return rows && rows.map( row => key(row) ); + } else if (Array.isArray(key)) { + const car = key.shift(); + if (key.length) { + return unpack(unpack(rows, car), key); + } else { + return unpack(rows, car); + } + } else { + return rows && rows.map( row => row?.[key] ); + } }; diff --git a/lib/www/client/source/src/views/Log.vue b/lib/www/client/source/src/views/Log.vue index 709d09a..7fe91d4 100644 --- a/lib/www/client/source/src/views/Log.vue +++ b/lib/www/client/source/src/views/Log.vue @@ -33,6 +33,17 @@ + + mdi-format-list-numbered + +