moleculemaker / digital-molecule-maker

Digital Molecule Maker web application for the Molecule Maker Lab Institute
MIT License
1 stars 0 forks source link

Dynamic sizing (2/4) #165

Closed GalMunGral closed 7 months ago

GalMunGral commented 7 months ago

A simple layout algorithm for dmm-molecule-svg to accommodate different molecule sizes.

Mock block sets for testing:

TEST_2_BLOCK Screenshot 2024-02-27 at 4 20 46 PM

TEST_4_BLOCK Screenshot 2024-02-27 at 4 20 49 PM

TEST_5_BLOCK Screenshot 2024-02-27 at 4 20 56 PM

GalMunGral commented 7 months ago

LGTM 👍 works as advertised!

Thank you for cleaning up some of the hardcoding/assumptions here, @GalMunGral 🎉

I wonder if there is any way to auto-detect this variable without needing the extra URL parameter? e.g. assume 2 blocks unless the user adds a third, assume 3 blocks until the user adds a fourth, etc

Thanks! Per our discussion on Slack, this is technically feasible. I'll relay this suggestion to @jplaney, @em1lyc and @matthewberry.