Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

add support for general highlighting of concordance tokens based on a specified positional attribute value (or values) #5372

Open
tomachalek opened this issue Oct 6, 2022 · 0 comments
Assignees

Comments

@tomachalek
Copy link
Member

  1. in models/concordance/actions, define a new action HighlightTokensMatchingPosAttr where payload should contain at least a list of values (Array<string>) and positional attribute name (e.g. lemma).
  2. add something like shadowLines:Array<Line> to the ConcordanceModelState
  3. see the method changePage and use the initial part where const args is created and a respective ajax action is triggered and define a new method (e.g. loadShadowLines) which will replace all the args URL attributes (do not confuse with the constant args above) by the value of the positional attribute defined by the action from (1)
  4. create a side-effect action HighlightTokensMatchingPosAttrDone which (once shadowLines are loaded) will go through all the "shadow" lines and compare respective values with the ones provided by action (1). In case of a match, go to the exact same position in lines and add some CSS class to highlight a matching token
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants