cinemascience / cinema_components

A JavaScript library for building Cinema viewers
Other
2 stars 5 forks source link

String Queries and Multi-Brushing #20

Closed miketynes closed 2 years ago

miketynes commented 2 years ago

String Queries and Multi-Brushing

Features added

  1. Ability to use query expressions for string variables. Inputs to the string query boxes shown below are interpreted as regex.
  2. Multiple brushes per PCoord Axis. This was necessary to enable string queries without fundamentally changing how queries work.
image

Notes/questions:

  1. The multiple brush implementation is based on that found here.
  2. The brush-on-read filterSelection method was only changed enough to prevent breaking it. It was not given support for multiple-brushes or regex searching. If this is desired I can add it.
  3. I did not modify this method to support multiple brushes since, as far as I can tell, it is not used anywhere across cinema_components, cinema_explorer or cinema_bandit. This means I can't test any changes I make. Am I missing something? Or should this function be removed?
  4. Please let me know if you have suggestions for this cosmetic issue.