Page MenuHomeElementl

[dagit] Preserve `view` value in Asset breadcrumbs
ClosedPublic

Authored by dish on Apr 23 2021, 8:04 PM.

Details

Summary

When using breadcrumbs on Asset directory pages, the view isn't preserved and it jumps to a flattened (but filtered) list that is not accessible through normal navigational means. I think it would be more correct to preserve the directory view, so that using the breadcrumbs keeps you in the same context.

Test Plan

View assets, switch to directory view. Go into a couple levels, then use breadcrumbs to jump back out. Verify that directory view remains.

Diff Detail

Repository
R1 dagster
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

dish requested review of this revision.Apr 23 2021, 8:14 PM

one thought here...

one user in #dagster-support was asking for a way to make the view selection sticky... maybe we could read/write to localStorage for the view and then just use the explicit url parameter on AssetEntryRoot and AssetCatalogRoot to set the localStorage value?

one user in #dagster-support was asking for a way to make the view selection sticky... maybe we could read/write to localStorage for the view and then just use the explicit url parameter on AssetEntryRoot and AssetCatalogRoot to set the localStorage value?

Yep, we can definitely do that.

Use localStorage instead of URL params

It seems like we can *just* use localStorage here, and no URL parameter at all. The URL param would be useful if I needed to link to a specific view, but I'm not sure that's really necessary since people would more likely be linking to specific assets. Lmk what you think.

yeah, that makes sense to me.

This revision is now accepted and ready to land.Apr 26 2021, 3:16 PM