From 4d16cd595b6c33f28d5e0f3606b14b9fbefcb6ab Mon Sep 17 00:00:00 2001 From: Gilad Gray Date: Wed, 15 Mar 2017 11:37:54 -0700 Subject: [PATCH] only update scroll position when page changes (#840) this solves the overscroll issue we had previously (cuz page doesn't change) while also ensuring that the active section is always visible when the page loads. sidebar scrolls the active _page_ into view so you can see the entire layout, rather than just the active section! --- packages/docs/src/components/styleguide.tsx | 28 +++++++++++++-------- 1 file changed, 17 insertions(+), 11 deletions(-) diff --git a/packages/docs/src/components/styleguide.tsx b/packages/docs/src/components/styleguide.tsx index 35f28f3ce0..cf2ecbc6ca 100644 --- a/packages/docs/src/components/styleguide.tsx +++ b/packages/docs/src/components/styleguide.tsx @@ -146,7 +146,8 @@ export class Styleguide extends React.Component { @@ -168,8 +169,13 @@ export class Styleguide extends React.Component outerBounds.bottom) { @@ -219,6 +221,10 @@ export class Styleguide extends React.Component