storybookjs / addon-design-assets

Design asset preview for storybook
MIT License
6 stars 3 forks source link

[addon-design-assets] Web View in Panel is not 100% Height #2

Open mosherc opened 3 years ago

mosherc commented 3 years ago

Describe the bug Design Assets panel does not show the full content of the web view.

To Reproduce Steps to reproduce the behavior:

  1. Add addon design-assets
  2. Add a random web page to parameters.assets array in default export
  3. Go to story
  4. See web view in panel is cut off

Expected behavior Web view inside panel takes up 100% of the height.

Screenshots image

Code snippets

export default {
  title: 'Molecules/Modal',
  component: Modal,
  parameters: {
    assets: [
      'https://developer.mozilla.org/en-US/docs/Web/Accessibility/ARIA/ARIA_Live_Regions', // link to a webpage
    ],
  },
} as Meta;

System System: OS: macOS 11.1 CPU: (8) x64 Apple M1 Binaries: Node: 10.16.3 - ~/.nodenv/versions/10.16.3/bin/node Yarn: 1.22.4 - ~/.nodenv/versions/10.16.3/bin/yarn npm: 6.9.0 - ~/.nodenv/versions/10.16.3/bin/npm Browsers: Chrome: 88.0.4324.150 Firefox: 80.0 Safari: 14.0.2 npmPackages: @storybook/addon-a11y: ^6.1.10 => 6.1.17 @storybook/addon-actions: ^6.1.16 => 6.1.17 @storybook/addon-design-assets: ^6.1.17 => 6.1.17 @storybook/addon-essentials: ^6.1.9 => 6.1.17 @storybook/addon-jest: ^6.1.17 => 6.1.17 @storybook/addon-storysource: ^6.1.9 => 6.1.17 @storybook/react: ^6.1.9 => 6.1.17 @storybook/source-loader: ^6.1.9 => 6.1.17 @storybook/theming: ^6.1.9 => 6.1.17

Additional context Adding height: 100%; to this div fixes it: image image

shilman commented 3 years ago

I recommend https://github.com/pocka/storybook-addon-designs

@ndelangen @winkerVSbecks @phated should we deprecate addon-design-assets. i believe it was created as a sample addon, but this was long before the recent addons documentation overhaul. WDYT?

mosherc commented 3 years ago

@shilman I actually decided to do that, works pretty well so far and has a few extra things in its api.

I was surprised that I couldn't find anyone else with this bug, but I see you only have 4500 weekly downloads on npm so not a lot of usage.

winkerVSbecks commented 3 years ago

@shilman had a chat with @domyen and @jonniebigodes. Yea, makes sense to deprecate this. We're going to drop the chapter that references to this from the Intro to Storybook guide too.