From c48ddb08a97e7f6eb846a790c611c3d103faf75c Mon Sep 17 00:00:00 2001 From: Richard Knoll Date: Wed, 8 May 2024 10:01:01 -0700 Subject: [PATCH] fix help link in monaco flyout (#10008) --- webapp/src/monacoFlyout.tsx | 15 +++++++++++---- 1 file changed, 11 insertions(+), 4 deletions(-) diff --git a/webapp/src/monacoFlyout.tsx b/webapp/src/monacoFlyout.tsx index 474ec8451902..5f7d6a595b08 100644 --- a/webapp/src/monacoFlyout.tsx +++ b/webapp/src/monacoFlyout.tsx @@ -6,6 +6,7 @@ import * as workspace from "./workspace"; import * as data from "./data"; import * as auth from "./auth"; import { HELP_IMAGE_URI } from "../../pxteditor"; +import * as pxtblockly from "../../pxtblocks"; import ISettingsProps = pxt.editor.ISettingsProps; @@ -353,7 +354,11 @@ export class MonacoFlyout extends data.Component { + pxtblockly.external.openHelpUrl(helpUrl); + }; const qName = this.getQName(block) || this.getSnippetName(block); const selected = qName == this.state.selectedBlock; @@ -385,9 +390,11 @@ export class MonacoFlyout extends data.Component{description}
{snippet ? snippet : `${qName}(${params ? params.map(p => `${p.name}`).join(", ") : ""})`} - {helpUrl && - - } + {helpUrl && + + + + }
{params &&
{params.map((p, i) => {