From bb95d5cad403a81b831f9c6ea362b728c8e9c1b0 Mon Sep 17 00:00:00 2001 From: Vit Rozkovec Date: Wed, 16 Aug 2023 08:46:31 +0200 Subject: [PATCH] Fix float classes (#999) * Update BootstrapNavigationToolbar.html - fix float classes https://getbootstrap.com/docs/5.1/utilities/float/ pull-left -> float-start pull-right -> float-end * Replace float classes: pull-left -> float-start, pull-left -> float-end (cherry picked from commit 95302834bf7527a03f858bfc9b3df95c1eae07f2) --- .../markup/html/bootstrap/behavior/AlignmentBehavior.java | 4 ++-- .../core/markup/html/bootstrap/block/QuoteBehavior.java | 2 +- .../de/agilecoders/wicket/core/util/AttributesTest.java | 4 ++-- .../html/bootstrap/table/sort/BootstrapOrderByBorder.html | 2 +- .../table/toolbars/BootstrapNavigationToolbar.html | 6 +++--- 5 files changed, 9 insertions(+), 9 deletions(-) diff --git a/bootstrap-core/src/main/java/de/agilecoders/wicket/core/markup/html/bootstrap/behavior/AlignmentBehavior.java b/bootstrap-core/src/main/java/de/agilecoders/wicket/core/markup/html/bootstrap/behavior/AlignmentBehavior.java index f95c4f30d..67d04d630 100644 --- a/bootstrap-core/src/main/java/de/agilecoders/wicket/core/markup/html/bootstrap/behavior/AlignmentBehavior.java +++ b/bootstrap-core/src/main/java/de/agilecoders/wicket/core/markup/html/bootstrap/behavior/AlignmentBehavior.java @@ -37,8 +37,8 @@ public class AlignmentBehavior extends BootstrapBaseBehavior { * TODO miha: add documentation. */ public enum Alignment implements ICssClassNameProvider { - RIGHT("pull-right"), - LEFT("pull-left"), + RIGHT("float-end"), + LEFT("float-start"), NONE(""); private String className; diff --git a/bootstrap-core/src/main/java/de/agilecoders/wicket/core/markup/html/bootstrap/block/QuoteBehavior.java b/bootstrap-core/src/main/java/de/agilecoders/wicket/core/markup/html/bootstrap/block/QuoteBehavior.java index ea4c00f07..1cc8670b1 100644 --- a/bootstrap-core/src/main/java/de/agilecoders/wicket/core/markup/html/bootstrap/block/QuoteBehavior.java +++ b/bootstrap-core/src/main/java/de/agilecoders/wicket/core/markup/html/bootstrap/block/QuoteBehavior.java @@ -58,7 +58,7 @@ public void onComponentTag(Component component, ComponentTag tag) { * @return this component's instance */ public final QuoteBehavior pullRight() { - pullRight.setObject("pull-right"); + pullRight.setObject("float-end"); return this; } diff --git a/bootstrap-core/src/test/java/de/agilecoders/wicket/core/util/AttributesTest.java b/bootstrap-core/src/test/java/de/agilecoders/wicket/core/util/AttributesTest.java index fe9846275..e26a9a57b 100644 --- a/bootstrap-core/src/test/java/de/agilecoders/wicket/core/util/AttributesTest.java +++ b/bootstrap-core/src/test/java/de/agilecoders/wicket/core/util/AttributesTest.java @@ -48,9 +48,9 @@ void nullClassNameThrowsException() { @Test void removeClass() { ComponentTag tag = new ComponentTag("span", XmlTag.TagType.OPEN_CLOSE); - tag.put("class", "class1 pull-right class2"); + tag.put("class", "class1 float-end class2"); - Attributes.removeClass(tag, "pull-right"); + Attributes.removeClass(tag, "float-end"); assertThat(tag.getAttribute("class"), is(equalTo("class1 class2"))); } diff --git a/bootstrap-extensions/src/main/java/de/agilecoders/wicket/extensions/markup/html/bootstrap/table/sort/BootstrapOrderByBorder.html b/bootstrap-extensions/src/main/java/de/agilecoders/wicket/extensions/markup/html/bootstrap/table/sort/BootstrapOrderByBorder.html index 23ae0678f..ebb39f1ac 100644 --- a/bootstrap-extensions/src/main/java/de/agilecoders/wicket/extensions/markup/html/bootstrap/table/sort/BootstrapOrderByBorder.html +++ b/bootstrap-extensions/src/main/java/de/agilecoders/wicket/extensions/markup/html/bootstrap/table/sort/BootstrapOrderByBorder.html @@ -1,6 +1,6 @@ -   +   \ No newline at end of file diff --git a/bootstrap-extensions/src/main/java/de/agilecoders/wicket/extensions/markup/html/bootstrap/table/toolbars/BootstrapNavigationToolbar.html b/bootstrap-extensions/src/main/java/de/agilecoders/wicket/extensions/markup/html/bootstrap/table/toolbars/BootstrapNavigationToolbar.html index b906c1adc..6f0a6e601 100644 --- a/bootstrap-extensions/src/main/java/de/agilecoders/wicket/extensions/markup/html/bootstrap/table/toolbars/BootstrapNavigationToolbar.html +++ b/bootstrap-extensions/src/main/java/de/agilecoders/wicket/extensions/markup/html/bootstrap/table/toolbars/BootstrapNavigationToolbar.html @@ -18,8 +18,8 @@ -
[navigator-label]
-
    [navigator]
+
[navigator-label]
+
    [navigator]
-
\ No newline at end of file +