From 5c272f2598b5b5daa5bfa0855f91dfcc62e6cce2 Mon Sep 17 00:00:00 2001 From: jasmussen Date: Mon, 1 Nov 2021 09:06:45 +0100 Subject: [PATCH 1/3] Fix dropdown indicator. --- packages/block-library/src/navigation/editor.scss | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/packages/block-library/src/navigation/editor.scss b/packages/block-library/src/navigation/editor.scss index 60d65922fcbcd..add25b7058382 100644 --- a/packages/block-library/src/navigation/editor.scss +++ b/packages/block-library/src/navigation/editor.scss @@ -20,6 +20,15 @@ } } +// The following rule affects the positioning of the dropdown arrow indicator. +// On the frontend, this element is inline, which makes it look correct. In the editor, +// the label is block, which causes the dropdown indicator to wrap onto a new line. +// Therefore we set it to inline-block. +.wp-block-navigation-item__label { + display: inline-block; +} + + /** * Submenus. */ From 2109476219555639504e0dc9e3515e3c5143f11d Mon Sep 17 00:00:00 2001 From: Joen A <1204802+jasmussen@users.noreply.github.com> Date: Mon, 1 Nov 2021 11:40:30 +0100 Subject: [PATCH 2/3] Update packages/block-library/src/navigation/editor.scss Co-authored-by: Aaron Robertshaw <60436221+aaronrobertshaw@users.noreply.github.com> --- packages/block-library/src/navigation/editor.scss | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/block-library/src/navigation/editor.scss b/packages/block-library/src/navigation/editor.scss index add25b7058382..a20fad7c8b26d 100644 --- a/packages/block-library/src/navigation/editor.scss +++ b/packages/block-library/src/navigation/editor.scss @@ -25,7 +25,7 @@ // the label is block, which causes the dropdown indicator to wrap onto a new line. // Therefore we set it to inline-block. .wp-block-navigation-item__label { - display: inline-block; + display: inline; } From 475f6c730d18e9251118520a22a5664f6296af7f Mon Sep 17 00:00:00 2001 From: jasmussen Date: Mon, 1 Nov 2021 11:41:19 +0100 Subject: [PATCH 3/3] Polish comment. --- packages/block-library/src/navigation/editor.scss | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/block-library/src/navigation/editor.scss b/packages/block-library/src/navigation/editor.scss index a20fad7c8b26d..00fac191dcc94 100644 --- a/packages/block-library/src/navigation/editor.scss +++ b/packages/block-library/src/navigation/editor.scss @@ -23,7 +23,7 @@ // The following rule affects the positioning of the dropdown arrow indicator. // On the frontend, this element is inline, which makes it look correct. In the editor, // the label is block, which causes the dropdown indicator to wrap onto a new line. -// Therefore we set it to inline-block. +// Therefore we explicitly set it to inline even in the block editor. .wp-block-navigation-item__label { display: inline; }