Skip to content

Support for Expert Assistant inline action links#6864

Merged
Steve-Mcl merged 11 commits intomainfrom
6816-action-links
Mar 18, 2026
Merged

Support for Expert Assistant inline action links#6864
Steve-Mcl merged 11 commits intomainfrom
6816-action-links

Conversation

@Steve-Mcl
Copy link
Copy Markdown
Contributor

Description

This pull request adds support for assistant action links in the immersive editor context.

Assistant action link handling:

  • Added logic in AnswerWrapper.vue to detect and handle clicks on assistant action links in the immersive editor, parsing parameters and dispatching the invokeAction Vuex action only for supported actions. [1] [2] [3]
  • Introduced the invokeAction action in the assistant Vuex module to facilitate action invocation via messaging.

Sanitization and link identification:

  • Enhanced the sanitize function in String.js to recognize and preserve custom assistant action links (nr-assistant://), adding data attributes for action and parameters, and preventing unsafe modifications. [1] [2]
  • Updated RichContent.vue to pass supportedActions to sanitize, enabling proper identification of action links during content rendering. [1] [2]
  • Connected supportedActions state to components to ensure only valid actions are processed and rendered. [1] [2]

These changes collectively enable secure, context-aware assistant action invocation from answer content in the immersive editor, while maintaining robust sanitization and validation of action links.

Related Issue(s)

closes #6816

Checklist

  • I have read the contribution guidelines
  • Suitable unit/system level tests have been added and they pass
  • Documentation has been updated
    • Upgrade instructions
    • Configuration details
    • Concepts
  • Changes flowforge.yml?
    • Issue/PR raised on FlowFuse/helm to update ConfigMap Template
    • Issue/PR raised on FlowFuse/CloudProject to update values for Staging/Production
  • Link to Changelog Entry PR, or note why one is not needed.

Labels

  • Includes a DB migration? -> add the area:migration label

@codecov
Copy link
Copy Markdown

codecov bot commented Mar 13, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 76.62%. Comparing base (b8758ac) to head (870f924).
⚠️ Report is 12 commits behind head on main.

Additional details and impacted files
@@           Coverage Diff           @@
##             main    #6864   +/-   ##
=======================================
  Coverage   76.62%   76.62%           
=======================================
  Files         399      399           
  Lines       20165    20165           
  Branches     4856     4856           
=======================================
  Hits        15452    15452           
  Misses       4713     4713           
Flag Coverage Δ
backend 76.62% <ø> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

Base automatically changed from expert/scalability to main March 18, 2026 15:42
@Steve-Mcl
Copy link
Copy Markdown
Contributor Author

@cstns I have merged all, updated & answered your query on the review - GTG?

@cstns
Copy link
Copy Markdown
Contributor

cstns commented Mar 18, 2026

yes, gtg! marked my comment as resolved

@Steve-Mcl Steve-Mcl merged commit 1a05eda into main Mar 18, 2026
30 checks passed
@Steve-Mcl Steve-Mcl deleted the 6816-action-links branch March 18, 2026 16:04
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Support custom Node-RED hyperlinks in Expert output MD and issue action/command to Assistant

2 participants