mirror of
https://github.com/the-djmaze/snappymail.git
synced 2026-07-13 03:27:39 +03:00
Small bugfix for the folder editor popup
This commit is contained in:
parent
72b481f9c4
commit
72815f842e
3 changed files with 4 additions and 10 deletions
|
|
@ -485,10 +485,6 @@ export class FolderModel extends AbstractModel {
|
||||||
showScreenPopup(FolderPopupView, [this]);
|
showScreenPopup(FolderPopupView, [this]);
|
||||||
}
|
}
|
||||||
|
|
||||||
unedit() {
|
|
||||||
this.editing(false);
|
|
||||||
}
|
|
||||||
|
|
||||||
rename() {
|
rename() {
|
||||||
const folder = this,
|
const folder = this,
|
||||||
nameToEdit = folder.nameForEdit().trim();
|
nameToEdit = folder.nameForEdit().trim();
|
||||||
|
|
@ -520,8 +516,6 @@ export class FolderModel extends AbstractModel {
|
||||||
+ '.\n' + error.message);
|
+ '.\n' + error.message);
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
folder.editing(false);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
|
||||||
|
|
@ -13,8 +13,8 @@ export class FolderPopupView extends AbstractViewPopup {
|
||||||
this.ACL = ko.observableArray();
|
this.ACL = ko.observableArray();
|
||||||
}
|
}
|
||||||
|
|
||||||
onClose() {
|
afterHide() {
|
||||||
this.folder().unedit();
|
this.folder().editing(false);
|
||||||
}
|
}
|
||||||
|
|
||||||
submitForm(form) {
|
submitForm(form) {
|
||||||
|
|
@ -32,7 +32,7 @@ export class FolderPopupView extends AbstractViewPopup {
|
||||||
}, {
|
}, {
|
||||||
folder: folder.fullName
|
folder: folder.fullName
|
||||||
});
|
});
|
||||||
!folder.type() && folder.exists && folder.selectable() && folder.editing(true);
|
folder.editing(!folder.type() && folder.exists && folder.selectable());
|
||||||
this.folder(folder);
|
this.folder(folder);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -8,7 +8,7 @@
|
||||||
<label data-i18n="GLOBAL/NAME"></label>
|
<label data-i18n="GLOBAL/NAME"></label>
|
||||||
<input name="folder" type="text"
|
<input name="folder" type="text"
|
||||||
autocomplete="off" autocorrect="off" autocapitalize="off" spellcheck="false"
|
autocomplete="off" autocorrect="off" autocapitalize="off" spellcheck="false"
|
||||||
required="" data-bind="textInput: nameForEdit, hasfocus: editing">
|
required="" data-bind="textInput: nameForEdit">
|
||||||
</div>
|
</div>
|
||||||
<div class="control-group">
|
<div class="control-group">
|
||||||
<label data-i18n="POPUPS_FILTER/SELECT_FIELD_SIZE"></label>
|
<label data-i18n="POPUPS_FILTER/SELECT_FIELD_SIZE"></label>
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue