cldellow / datasette-ui-extras

Add editing UI and other power-user features to Datasette.
Apache License 2.0
12 stars 1 forks source link

datasette-cluster-map has weird flex interaction with facets #46

Closed cldellow closed 1 year ago

cldellow commented 1 year ago

eg http://localhost:8001/geonames/geonames?country__exact=US&population__gt=500000&_facet=updated_at looks like

Selection_404

cldellow commented 1 year ago

I think this bit of code is doing the insertion: https://github.com/simonw/datasette-cluster-map/blob/795d25ad9ff6cba0307191f44fecc8f8070bef5c/datasette_cluster_map/static/datasette-cluster-map.js#L292-L295

We should probably wrap the .table-wrapper div in its own div so plugins that do this aren't part of the flex row

cldellow commented 1 year ago

Even if this works, I think there's still a (series of?) race conditions -- we need our code to run first, and our domready handler to run first to wrap things.

If that works, maybe that's fine & we'll just add a @tryfirst to our hook