Skip to content

Commit

Permalink
Fix primefaces#1040: Refactor Floating Label CSS.
Browse files Browse the repository at this point in the history
  • Loading branch information
melloware committed Oct 10, 2019
1 parent 3c07302 commit 656c857
Show file tree
Hide file tree
Showing 3 changed files with 20 additions and 38 deletions.
20 changes: 20 additions & 0 deletions src/components/common/Common.css
Original file line number Diff line number Diff line change
Expand Up @@ -176,4 +176,24 @@ button {

.p-toggleable-content-exit-done {
display: none;
}

/* Floating Label */
.p-float-label {
display: block;
position:relative;
}

.p-float-label label {
font-weight:normal;
position:absolute;
pointer-events:none;
left: .25em;
top: 50%;
margin-top: -.5em;
transition: 0.3s ease all;
-moz-transition: 0.3s ease all;
-webkit-transition: 0.3s ease all;
color: #898989;
line-height: 1;
}
19 changes: 0 additions & 19 deletions src/components/inputtext/InputText.css
Original file line number Diff line number Diff line change
Expand Up @@ -89,25 +89,6 @@
}

/* Floating Label */
.p-float-label {
display: block;
position:relative;
}

.p-float-label label {
font-weight:normal;
position:absolute;
pointer-events:none;
left: .25em;
top: 50%;
margin-top: -.5em;
transition: 0.3s ease all;
-moz-transition: 0.3s ease all;
-webkit-transition: 0.3s ease all;
color: #898989;
line-height: 1;
}

.p-float-label input:focus ~ label,
.p-float-label input.p-filled ~ label,
.p-float-label .p-inputwrapper-focus ~ label,
Expand Down
19 changes: 0 additions & 19 deletions src/components/inputtextarea/InputTextarea.css
Original file line number Diff line number Diff line change
Expand Up @@ -8,25 +8,6 @@
}

/* Floating Label */
.p-float-label {
display: block;
position:relative;
}

.p-float-label label {
font-weight:normal;
position:absolute;
pointer-events:none;
left: .25em;
top: 50%;
margin-top: -.5em;
transition: 0.3s ease all;
-moz-transition: 0.3s ease all;
-webkit-transition: 0.3s ease all;
color: #898989;
line-height: 1;
}

.p-float-label textarea:focus ~ label,
.p-float-label textarea.p-filled ~ label,
.p-float-label .p-inputwrapper-focus ~ label,
Expand Down

0 comments on commit 656c857

Please sign in to comment.