Merge pull request #3735 from sam-at-work/fix-centered-addon-ie11

Fix centered addon for IE11
This commit is contained in:
Filipp Riabchun 2018-06-16 15:23:14 +03:00 committed by GitHub
commit 12b41f1caf
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
6 changed files with 10 additions and 10 deletions

View File

@ -7,11 +7,11 @@ const styles = {
right: 0,
display: 'flex',
alignItems: 'center',
justifyContent: 'center',
overflow: 'auto',
},
innerStyle: {
margin: 'auto',
maxHeight: '100%', // Hack for centering correctly in IE11
},
};

View File

@ -13,7 +13,7 @@ exports[`Storyshots Addon|Centered centered component 1`] = `
>
<div
ng-reflect-ng-style="[object Object]"
style="margin: auto;"
style="margin: auto; max-height: 100%;"
>
<storybook-app-root>
<div
@ -89,7 +89,7 @@ exports[`Storyshots Addon|Centered centered template 1`] = `
>
<div
ng-reflect-ng-style="[object Object]"
style="margin: auto;"
style="margin: auto; max-height: 100%;"
>
<storybook-button-component
_nghost-c6=""

View File

@ -644,10 +644,10 @@ exports[`Storyshots Lifecycle logging 1`] = `
exports[`Storyshots Some really long story kind description with text 1`] = `
<div
style="position:fixed;top:0;left:0;bottom:0;right:0;display:flex;align-items:center;justify-content:center;overflow:auto"
style="position:fixed;top:0;left:0;bottom:0;right:0;display:flex;align-items:center;overflow:auto"
>
<div
style="margin:auto"
style="margin:auto;max-height:100%"
>
<button
class="css-1qwzad5"

View File

@ -7,7 +7,7 @@ exports[`Storyshots Addons|Centered button in center 1`] = `
>
<div
id="sb-addon-centered-inner"
style="margin: auto;"
style="margin: auto; max-height: 100%;"
>
<button>
I am a Button !

View File

@ -2,10 +2,10 @@
exports[`Storyshots Addons|Centered story 1 1`] = `
<div
style="position:fixed;top:0;left:0;bottom:0;right:0;display:flex;align-items:center;justify-content:center;overflow:auto"
style="position:fixed;top:0;left:0;bottom:0;right:0;display:flex;align-items:center;overflow:auto"
>
<div
style="margin:auto"
style="margin:auto;max-height:100%"
>
<button>
This story should be centered

View File

@ -5,13 +5,13 @@ exports[`Storyshots Addon|Centered rounded 1`] = `
style="position: fixed; top: 0px; left: 0px; bottom: 0px; right: 0px; display: flex; overflow: auto;"
>
<div
style="margin: auto;"
style="margin: auto; max-height: 100%;"
>
<div
style="position: fixed; top: 0px; left: 0px; bottom: 0px; right: 0px; display: flex; overflow: auto;"
>
<div
style="margin: auto;"
style="margin: auto; max-height: 100%;"
>
<button
class="button rounded"