Skip to content

Commit 25549c7

Browse files
committed
Revert "applied fix for select2#1172 - Clear button overlaps text"
This reverts commit fd07c11.
1 parent 06c82f2 commit 25549c7

2 files changed

Lines changed: 3 additions & 9 deletions

File tree

select2.css

Lines changed: 3 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -81,10 +81,6 @@ Version: @@ver@@ Timestamp: @@timestamp@@
8181
background-image: linear-gradient(top, #eeeeee 0%,#ffffff 90%);
8282
}
8383

84-
.select2-container.select2-allowclear .select2-choice span {
85-
margin-right: 42px;
86-
}
87-
8884
.select2-container .select2-choice span {
8985
margin-right: 26px;
9086
display: block;
@@ -98,11 +94,11 @@ Version: @@ver@@ Timestamp: @@timestamp@@
9894
}
9995

10096
.select2-container .select2-choice abbr {
101-
display: inline-block;
97+
display: block;
10298
width: 12px;
10399
height: 12px;
104100
position: absolute;
105-
right: 24px;
101+
right: 26px;
106102
top: 8px;
107103

108104
font-size: 1px;
@@ -175,7 +171,7 @@ Version: @@ver@@ Timestamp: @@timestamp@@
175171
}
176172

177173
.select2-container .select2-choice div {
178-
display: inline-block;
174+
display: block;
179175
width: 18px;
180176
height: 100%;
181177
position: absolute;

select2.js

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1944,7 +1944,6 @@ the specific language governing permissions and limitations under the Apache Lic
19441944

19451945
this.selection.addClass("select2-default");
19461946

1947-
this.container.removeClass("select2-allowclear");
19481947
this.selection.find("abbr").hide();
19491948
}
19501949
},
@@ -2023,7 +2022,6 @@ the specific language governing permissions and limitations under the Apache Lic
20232022
this.selection.removeClass("select2-default");
20242023

20252024
if (this.opts.allowClear && this.getPlaceholder() !== undefined) {
2026-
this.container.addClass("select2-allowclear");
20272025
this.selection.find("abbr").show();
20282026
}
20292027
},

0 commit comments

Comments
 (0)