netcreateorg / netcreate-2018

Please report bugs, problems, ideas in the project Issues page: https://github.com/netcreateorg/netcreate-2018/issues
Other
11 stars 2 forks source link

Feature: Collapse Filter #264

Closed benloh closed 1 year ago

benloh commented 1 year ago

This adds a new "Collapse" panel to the "FILTER" feature, addressing #248.

The collapse function will:

  1. Keep any matching nodes or edges visible
  2. Remove any non-matching nodes or edges
  3. Recalculate node sizes and edge weights accounting for the removed nodes and edges.

The functionality matches the Highlight and Filter functions. Any nodes or edges matched on the Highlight and Filter functions will also match on the Collapse function. This way you can click back and forth between the three methods to explore the effect of the different functions on the same search.

Other fixes:

@jdanish please give this a whirl to see if it meets your goals.

TO DO

jdanish commented 1 year ago

At a glance, awesome!! Need to think about help text and appreciate @kalanicraig take on that.

One bug / error: it appears that collapses always reduces node degrees to 1 and then they do not re-set. For example, pick nodes that contain J:

Highlight works, all other nodes fade but size acts as if they are there Filter works, all other nodes disappear but size acts as if they are there Collapse removes all else, size fall to 1 Highlight again shows the correct things, but nodes remain small

BL EDIT: Moved to #268

jdanish commented 1 year ago

Minor remaining issue is move between collapse and filter / highlight which should re-calculate degrees but does not.

Will keep testing while waiting on the other to-dos but looking good.

benloh commented 1 year ago

@jdanish All issues fixed. Please pull latest, confirm, and approve the merge request.

jdanish commented 1 year ago

Edited to change update comment.

Two minor things: 1) Nodes table, put updated next to the provenance? 2) We probably need to make the filter panel scroll if needed since I am just barely hitting the edge on my screen and if any fields are added ...

I'll test a bit more before signing off but looking good!! @benloh

jdanish commented 1 year ago

If you click on highlight, then filter, then collapse, then back and forth the collapse shows things as faded and not hidden.

I don't have the pattern fully down yet, but I think it is going between edge and node tables once something is selected.

Screenshot 2023-06-01 at 8 09 29 PM
jdanish commented 1 year ago

Type field seems broken? Also label should be uppercase.

Screenshot 2023-06-01 at 9 23 25 PM
benloh commented 1 year ago

Nodes table, put updated next to the provenance?

So the order is Tags, Notes, Provenance, then Updated and Comments?

If you click on highlight, then filter, then collapse, then back and forth the collapse shows things as faded and not hidden.

Yeah, I need to refine the state changing when going back and forth. That was one of the big things I wanted to fix.

Type field seems broken? Also label should be uppercase.

This might be an issue with your template? The labels are defined from the template.

jdanish commented 1 year ago
  1. Select nodes table and collapse
  2. Select label and type c
  3. nodes table update correctly
  4. Click edges, rows are red (shouldn't be)
  5. Click on nodes (red)
jdanish commented 1 year ago

Nodes table, put updated next to the provenance?

So the order is Tags, Notes, Provenance, then Updated and Comments?

That works - the main thing for me is that updated is tied to provenance. Long-term I assume we'll want this to be in the template (the order).

If you click on highlight, then filter, then collapse, then back and forth the collapse shows things as faded and not hidden.

Yeah, I need to refine the state changing when going back and forth. That was one of the big things I wanted to fix.

Cool.

Type field seems broken? Also label should be uppercase.

This might be an issue with your template? The labels are defined from the template.

This is your template! But I changed it and now it does as expected. Thanks!

jdanish commented 1 year ago

Sorry, to clarify - the capitalization in the focus template Label was in the template. The Type doesn't work - does that work for you?

benloh commented 1 year ago

Sorry, to clarify - the capitalization in the focus template Label was in the template. The Type doesn't work - does that work for you?

Type doesn't work on my demo focus db because there are no types defined. But it does work on your ItestTeam db.

jdanish commented 1 year ago

@benloh merge away!

benloh commented 1 year ago