Change style on file rename input to avoid weird Chrome behaviour

This commit is contained in:
James Allen 2014-08-12 12:46:05 +01:00
parent f902cfdcf6
commit 93f2969be5
2 changed files with 30 additions and 16 deletions

View file

@ -115,14 +115,15 @@ script(type='text/ng-template', id='entityListItemTemplate')
span(
ng-hide="entity.renaming"
) {{ entity.name }}
input(
ng-if="permissions.write",
ng-show="entity.renaming",
ng-model="inputs.name",
ng-blur="finishRenaming()",
select-name-when="entity.renaming",
on-enter="finishRenaming()"
)
span.rename-input
input(
ng-if="permissions.write",
ng-show="entity.renaming",
ng-model="inputs.name",
ng-blur="finishRenaming()",
select-name-when="entity.renaming",
on-enter="finishRenaming()"
)
span.dropdown(
ng-show="entity.selected",
@ -197,14 +198,15 @@ script(type='text/ng-template', id='entityListItemTemplate')
span(
ng-hide="entity.renaming"
) {{ entity.name }}
input(
ng-if="permissions.write",
ng-show="entity.renaming",
ng-model="inputs.name",
ng-blur="finishRenaming()",
select-name-when="entity.renaming",
on-enter="finishRenaming()"
)
span.rename-input
input(
ng-if="permissions.write",
ng-show="entity.renaming",
ng-model="inputs.name",
ng-blur="finishRenaming()",
select-name-when="entity.renaming",
on-enter="finishRenaming()"
)
span.dropdown(
ng-if="permissions.write"

View file

@ -31,6 +31,7 @@ aside#file-tree {
li {
line-height: 2.6;
position: relative;
.entity-name {
color: @gray-darker;
@ -85,6 +86,17 @@ aside#file-tree {
padding: 0 12px;
}
}
.rename-input {
display: block;
position: absolute;
top: 1px;
left: 44px;
right: 32px;
input {
width: 100%;
}
}
}
}