diff --git a/src/plugins/notebook/components/notebook-menu-switcher.vue b/src/plugins/notebook/components/notebook-menu-switcher.vue index ed1b04bfae..88f43be8f1 100644 --- a/src/plugins/notebook/components/notebook-menu-switcher.vue +++ b/src/plugins/notebook/components/notebook-menu-switcher.vue @@ -40,6 +40,18 @@ export default { default() { return {}; } + }, + ignoreLink: { + type: Boolean, + default() { + return false; + } + }, + objectPath: { + type: Array, + default() { + return null; + } } }, data() { @@ -97,17 +109,27 @@ export default { this.showMenu = false; }, snapshot(notebook) { - let element = document.getElementsByClassName("l-shell__main-container")[0]; - const bounds = this.openmct.time.bounds(); - const objectPath = this.openmct.router.path; - const snapshotMeta = { - bounds, - link: window.location.href, - objectPath, - openmct: this.openmct - }; + this.hideMenu(); - this.notebookSnapshot.capture(snapshotMeta, notebook.type, element); + this.$nextTick(() => { + const element = document.querySelector('.c-overlay__contents') + || document.getElementsByClassName('l-shell__main-container')[0]; + + const bounds = this.openmct.time.bounds(); + const link = !this.ignoreLink + ? window.location.href + : null; + + const objectPath = this.objectPath || this.openmct.router.path; + const snapshotMeta = { + bounds, + link, + objectPath, + openmct: this.openmct + }; + + this.notebookSnapshot.capture(snapshotMeta, notebook.type, element); + }); } } } diff --git a/src/plugins/plot/res/templates/stacked-plot.html b/src/plugins/plot/res/templates/stacked-plot.html index 2ec6e0b491..6e69859339 100644 --- a/src/plugins/plot/res/templates/stacked-plot.html +++ b/src/plugins/plot/res/templates/stacked-plot.html @@ -21,7 +21,7 @@ -->
-
+