scaife-viewer / frontend

Skeleton, Widgets, and other frontend packages for the Scaife Viewer
0 stars 3 forks source link

Add regions of interest highlighting #75

Closed pletcher closed 11 months ago

pletcher commented 1 year ago

This feature adds bidirectional highlighting (to-from the folio image) when regions of interest are available for text and/or scholia.

I think this is almost ready. I still need to map clicking on the ROI in the folio image to selecting the scholion in the sidebar, and there's some weird behavior when clicking scholia now that we've added additional data: it seems like clicking a scholion in the folio will also highlight other regions of interest?

I'll need to investigate where they're coming from.

scholia-highlights

pletcher commented 1 year ago

I think this is basically ready to go, but I'd love to confirm that the interactions and highlight colors work as expected.

CI is failing on yarn install:

error Your lockfile needs to be updated, but yarn was run with `--frozen-lockfile`.
info Visit https://yarnpkg.com/en/docs/cli/install for documentation about this command.
Error: The process '/usr/local/bin/yarn' failed with exit code 1
    at ExecState._setResult (/home/runner/work/_actions/bahmutov/npm-install/v1.4.3/dist/index.js:936:25)
    at ExecState.CheckComplete (/home/runner/work/_actions/bahmutov/npm-install/v1.4.3/dist/index.js:919:18)
    at ChildProcess.<anonymous> (/home/runner/work/_actions/bahmutov/npm-install/v1.4.3/dist/index.js:819:27)
    at ChildProcess.emit (events.js:314:20)
    at maybeClose (internal/child_process.js:1022:16)
    at Process.ChildProcess._handle.onexit (internal/child_process.js:287:5)
Error: The process '/usr/local/bin/yarn' failed with exit code 1
pletcher commented 1 year ago

Okay, I believe the latest changes have fixed the bugs identified in the demo earlier this week.

I've added a couple of comments -- it looks like there's some git cleanup from rebasing. Definitely my bad, but not sure if it's necessary to fix manually since we can just squash these down?

jacobwegner commented 1 year ago

@pletcher: Thanks for the update!

I do see some of the "rebase noise" you're talking about, and I think I remember you were using a newer Yarn version that we were working through some issues with earlier in the year.

I'll pull this branch and take a look tomorrow.

jacobwegner commented 1 year ago

@pletcher I've been pulled over to other things for Beyond Translation and scaife.perseus.org, but hope to circle back here after our meeting today.

I apologize for the continued delay!

pletcher commented 1 year ago

No problem!

pletcher commented 1 year ago

Sorry that took a bit, but I fixed the minor bugs that showed up in the demo this morning and cleaned up the selection state on the highlighter. Thanks in advance for the review!