Closed camdendotlol closed 1 year ago
The thumbnails look much better, but I'm seeing some new errors in the console when I try this our on my local machine:
also, I see these errors when looking at an individual page:
also, I see these errors when looking at an individual page:
Those errors have been in my console for a while, long before this PR. It looks like it's connected to our use of the prefixUrl
option in OpenSeaDragon, which tells it where to fetch some UI images. The images are currently in the repo, but it doesn't look like we're actually using them. I'll go ahead and delete them and add the line suggested in https://github.com/openseadragon/openseadragon/issues/210#issuecomment-23445225. It removes the 404 errors and doesn't cause any noticeable UI changes.
The thumbnails look much better, but I'm seeing some new errors in the console when I try this our on my local machine:
This seems to have been a bug with Storybook and its @storybook/addon-styling
plugin. We just upgraded both a month ago, but in the past month Storybook has gone from 7.2 to 7.4 and the styling plugin has been deprecated and replaced. The issue seems to be fixed after upgrading Storybook and replacing the styling plugin with the new recommended one.
Side question: Do we use Puppeteer? I notice it's in the package.json
- it's a pretty hefty dependency so I'd like to remove it if we're not using it.
Thanks! Go ahead and remove puppeteer, we aren't using it since Storybook got in the mix.
Summary
DocumentActions
to calculate thumbnail URLs based on the ratio between the width and height of the canvas, ignoring anythumbnail
items in the manifest@storybook/addon-styling
package with the styling addon du jour@storybook/addon-styling-webpack
showNavigationControl
to false in OpenSeaDragon to disable trying to load unused iconsThis PR also removes a bunch of unneeded dependencies, reducing bundle size by somewhere around 30-50%.
npm
was included as a dependency for some reason - removing it cut 400kB off the bundle size with no side effectsnpm-run-all
, which was no longer usedScreenshots
Before
After
Testing
fr640
and Taos are good for testing this, becausefr640
's canvases are tall and Taos's are wide. Both look good to me.