Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Retain Resized Panel Size in LocalStorage (between loads) #466

Closed
philcockfield opened this issue Sep 20, 2016 · 12 comments
Closed

Retain Resized Panel Size in LocalStorage (between loads) #466

philcockfield opened this issue Sep 20, 2016 · 12 comments

Comments

@philcockfield
Copy link
Contributor

Would be great if the action-logger panel, and the index panel, didn't not lose their size between page loads.

image

@arunoda
Copy link
Member

arunoda commented Sep 20, 2016

Yeah. This is a pretty cool feature.
This is the place we are doing this: https://github.com/kadirahq/storybook-ui/
If you are looking to send a PR :)

@gnarf
Copy link
Contributor

gnarf commented Oct 27, 2016

I would love a way to set the default height of that split differently as well

@gnarf
Copy link
Contributor

gnarf commented Oct 28, 2016

I'd be happy to contribute to getting this feature, if you can point me at the bits of code that might help me set the initial height of these -- I tried looking for anything involving this split and got a bit lost

@usulpro
Copy link
Member

usulpro commented Oct 29, 2016

to set the default height of that split differently as well

I agree, it is a good idea. I guess it could be included within the themes support implementation?
#428 (comment)

@thani-sh
Copy link
Contributor

@gnarf that would be awesome! here's what you'll need:

The split pane component
https://github.com/kadirahq/react-split-pane

Storybook UI code
https://github.com/kadirahq/storybook-ui/blob/master/src/modules/ui/components/layout/index.js#L71,L111

@thani-sh
Copy link
Contributor

@usulpro theme support might take a while. Most probably Storybook v3.
I've opened an issue on storybook-options addon repo. I'll try to add some more info there soon.

@usulpro
Copy link
Member

usulpro commented Apr 26, 2017

duplicates #869

@andrespch
Copy link

is there anyway to get the size of the pane within a story?

@Hypnosphi
Copy link
Member

Do window.innerHeight and window.innerWidth work for you?

@Hypnosphi
Copy link
Member

As for the issue itself, I believe it's fixed with 3e38843

@andrespch
Copy link

I'll check that out @Hypnosphi , thanks for the help, I'm coming from the iOS world so even the most basic stuff is still a mystery :) I guess we can use window because the story in embedded in a iFrame? or is it not really related?

@GreatState
Copy link

I'm getting this on a deployed site. Any ideas why?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests