Skip to content

feat(core): implement NavigateAction handler#1490

Merged
kitelev merged 1 commit intomainfrom
feat/core-implement-navigateaction-handler
Jan 7, 2026
Merged

feat(core): implement NavigateAction handler#1490
kitelev merged 1 commit intomainfrom
feat/core-implement-navigateaction-handler

Conversation

@kitelev
Copy link
Copy Markdown
Owner

@kitelev kitelev commented Jan 7, 2026

Summary

Implements NavigateAction handler for RDF-driven action execution:

  • Navigate to asset by direct URI (extracts UUID, looks up file via findFileByUID)
  • Navigate to first result of SPARQL SELECT query
  • Handle ASK queries (navigate to current asset if query returns true)
  • Works in both UI and headless (CLI) modes

Implementation Details

  • Added fileSystem parameter (type IFileSystemMetadataProvider) to ActionInterpreter constructor
  • Added resolveAssetUri() private method to extract UUID from URI and look up file path
  • Handler supports:
    • Direct URIs like https://exocortex.my/assets/uuid
    • SPARQL SELECT queries (navigates to first result's subject)
    • SPARQL ASK queries (navigates to current asset if query returns true)

Test Plan

  • Unit tests: 7 new tests covering all scenarios
  • Build: No errors
  • Lint: No new errors in changed files
  • All existing tests pass

Test Coverage

Test Case Status
Navigate to asset by direct URI
Navigate to first result of SPARQL SELECT query
Return error when SPARQL query returns no results
Return error when asset not found for direct URI
Work in headless (CLI) mode
Handle ASK queries
Extract UUID from URI correctly

Closes #1407

@kitelev kitelev enabled auto-merge (squash) January 7, 2026 00:24
Implements NavigateAction handler for RDF-driven action execution:
- Navigate to asset by direct URI (extracts UUID, looks up file)
- Navigate to first result of SPARQL SELECT query
- Handle ASK queries (navigate to current asset if query returns true)
- Works in both UI and headless (CLI) modes

Implementation:
- Add fileSystem parameter to ActionInterpreter constructor
- Add resolveAssetUri() method to extract UUID from URI and look up file
- Add 7 comprehensive tests covering all use cases

Closes #1407
@kitelev kitelev force-pushed the feat/core-implement-navigateaction-handler branch from 2e10c3a to 085ae1a Compare January 7, 2026 00:31
@kitelev kitelev merged commit aed45e0 into main Jan 7, 2026
21 of 22 checks passed
@kitelev kitelev deleted the feat/core-implement-navigateaction-handler branch January 7, 2026 00:37
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.

[Core] Implement NavigateAction handler

1 participant