From 610cf9951ebe81dd9104083f92f8861354ca98f1 Mon Sep 17 00:00:00 2001 From: "Matthew Riley MacPherson (tofumatt)" Date: Wed, 10 Oct 2018 01:28:50 +0100 Subject: [PATCH 1/3] fix: Fix inserter misalignment regression Fix #10453 --- packages/components/src/popover/style.scss | 10 --------- .../nux/src/components/dot-tip/style.scss | 21 ++++++++++++++++++- 2 files changed, 20 insertions(+), 11 deletions(-) diff --git a/packages/components/src/popover/style.scss b/packages/components/src/popover/style.scss index 4dbb346d94e2e7..e0f43cbc44373c 100644 --- a/packages/components/src/popover/style.scss +++ b/packages/components/src/popover/style.scss @@ -170,11 +170,6 @@ $arrow-size: 8px; } .components-popover:not(.is-mobile):not(.is-middle).is-right & { - /*!rtl:ignore*/ - margin-left: 0; - } - - .components-popover.edit-post-more-menu__content:not(.is-mobile):not(.is-middle).is-right & { /*!rtl:ignore*/ margin-left: -12px; } @@ -186,11 +181,6 @@ $arrow-size: 8px; } .components-popover:not(.is-mobile):not(.is-middle).is-left & { - /*!rtl:ignore*/ - margin-right: 0; - } - - .components-popover.edit-post-more-menu__content:not(.is-mobile):not(.is-middle).is-left & { /*!rtl:ignore*/ margin-right: -12px; } diff --git a/packages/nux/src/components/dot-tip/style.scss b/packages/nux/src/components/dot-tip/style.scss index 73db96374b9feb..e8e25b423830ca 100644 --- a/packages/nux/src/components/dot-tip/style.scss +++ b/packages/nux/src/components/dot-tip/style.scss @@ -82,7 +82,6 @@ $dot-scale: 3; // How much the pulse animation should scale up by in size &:not(.is-mobile).is-left, &:not(.is-mobile).is-center, &:not(.is-mobile).is-right { - // Position tips above popovers z-index: z-index(".nux-dot-tip"); @@ -99,4 +98,24 @@ $dot-scale: 3; // How much the pulse animation should scale up by in size } } } + + &.components-popover:not(.is-mobile):not(.is-middle).is-right .components-popover__content { + /*!rtl:ignore*/ + margin-left: 0; + } + + &.components-popover:not(.is-mobile):not(.is-middle).is-left .components-popover__content { + /*!rtl:ignore*/ + margin-right: 0; + } + + &.components-popover.edit-post-more-menu__content:not(.is-mobile):not(.is-middle).is-right .components-popover__content { + /*!rtl:ignore*/ + margin-left: -12px; + } + + &.components-popover.edit-post-more-menu__content:not(.is-mobile):not(.is-middle).is-left .components-popover__content { + /*!rtl:ignore*/ + margin-right: -12px; + } } From b2a58af506fd20f7f4993e87c83b03c250d6d2b7 Mon Sep 17 00:00:00 2001 From: "Matthew Riley MacPherson (tofumatt)" Date: Wed, 10 Oct 2018 11:29:46 +0100 Subject: [PATCH 2/3] Use better margin --- packages/components/src/popover/style.scss | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/packages/components/src/popover/style.scss b/packages/components/src/popover/style.scss index e0f43cbc44373c..31c04f0c95f86a 100644 --- a/packages/components/src/popover/style.scss +++ b/packages/components/src/popover/style.scss @@ -171,7 +171,7 @@ $arrow-size: 8px; .components-popover:not(.is-mobile):not(.is-middle).is-right & { /*!rtl:ignore*/ - margin-left: -12px; + margin-left: -$grid-size-large; } .components-popover:not(.is-mobile).is-left & { @@ -182,7 +182,7 @@ $arrow-size: 8px; .components-popover:not(.is-mobile):not(.is-middle).is-left & { /*!rtl:ignore*/ - margin-right: -12px; + margin-right: -$grid-size-large; } } From 34b02687649d5298b1c48bd3a5faf6dff1a80340 Mon Sep 17 00:00:00 2001 From: "Matthew Riley MacPherson (tofumatt)" Date: Wed, 10 Oct 2018 12:11:18 +0100 Subject: [PATCH 3/3] Use 24px again! --- packages/components/src/popover/style.scss | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/packages/components/src/popover/style.scss b/packages/components/src/popover/style.scss index 31c04f0c95f86a..6401b40654a17c 100644 --- a/packages/components/src/popover/style.scss +++ b/packages/components/src/popover/style.scss @@ -171,7 +171,7 @@ $arrow-size: 8px; .components-popover:not(.is-mobile):not(.is-middle).is-right & { /*!rtl:ignore*/ - margin-left: -$grid-size-large; + margin-left: -24px; } .components-popover:not(.is-mobile).is-left & { @@ -182,7 +182,7 @@ $arrow-size: 8px; .components-popover:not(.is-mobile):not(.is-middle).is-left & { /*!rtl:ignore*/ - margin-right: -$grid-size-large; + margin-right: -24px; } }