diff --git a/customize.dist/src/less2/include/alertify.less b/customize.dist/src/less2/include/alertify.less index ebc0b1383..fd340f8d2 100644 --- a/customize.dist/src/less2/include/alertify.less +++ b/customize.dist/src/less2/include/alertify.less @@ -204,7 +204,16 @@ } span.cp-password-container { + display: flex; + align-items: center; margin-bottom: 15px; + justify-content: space-between; + & > * { + margin-bottom: 0 !important; + } + button { + margin: 0 !important; + } } input[type="checkbox"], input[type="radio"] { @@ -220,85 +229,84 @@ } } - nav { - - text-align: right; - - button:not(.btn):not(.pure-button):not(.md-button):not(.mdl-button) { - - background-color: @colortheme_alertify-cancel; - box-sizing: border-box; - position: relative; - outline: 0; - display: inline-block; - align-items: center; - padding: 0 6px; - margin: 6px 8px; - line-height: 36px; - min-height: 36px; - white-space: nowrap; - min-width: 88px; - text-align: center; - text-transform: uppercase; - font-size: 14px; - text-decoration: none; - cursor: pointer; - border-radius: 0; - - color: @alertify-btn-fg; - border: 1px solid @colortheme_alertify-cancel-border; - - &.safe, &.danger { - color: @colortheme_old-base; - white-space: normal; - font-weight: bold; - } - &.danger { - background-color: @colortheme_alertify-red; - border-color: @colortheme_alertify-red-border; - color: @colortheme_alertify-red-color; - &:hover, &:active { - background-color: contrast(@colortheme_modal-bg, darken(@colortheme_alertify-red, 10%), lighten(@colortheme_alertify-red, 10%)); - } - } - - &.safe { - background-color: @colortheme_alertify-green; - border-color: @colortheme_alertify-green-border; - color: @colortheme_alertify-green-color; - &:hover, &:active { - background-color: contrast(@colortheme_modal-bg, darken(@colortheme_alertify-green, 10%), lighten(@colortheme_alertify-green, 10%)); - } + button:not(.btn):not(.pure-button):not(.md-button):not(.mdl-button) { + + background-color: @colortheme_alertify-cancel; + box-sizing: border-box; + position: relative; + outline: 0; + display: inline-block; + align-items: center; + padding: 0 6px; + margin: 6px 8px; + line-height: 36px; + min-height: 36px; + white-space: nowrap; + min-width: 88px; + text-align: center; + text-transform: uppercase; + font-size: 14px; + text-decoration: none; + cursor: pointer; + border-radius: 0; + + color: @alertify-btn-fg; + border: 1px solid @colortheme_alertify-cancel-border; + + &.safe, &.danger { + color: @colortheme_old-base; + white-space: normal; + font-weight: bold; + } + &.danger { + background-color: @colortheme_alertify-red; + border-color: @colortheme_alertify-red-border; + color: @colortheme_alertify-red-color; + &:hover, &:active { + background-color: contrast(@colortheme_modal-bg, darken(@colortheme_alertify-red, 10%), lighten(@colortheme_alertify-red, 10%)); } + } - &.primary { - background-color: @colortheme_alertify-primary; - color: @colortheme_alertify-primary-text; - border-color: @colortheme_alertify-primary-border; - font-weight: bold; - &:hover, &:active { - background-color: contrast(@colortheme_modal-bg, darken(@colortheme_alertify-primary, 10%), lighten(@colortheme_alertify-primary, 10%)); - } + &.safe { + background-color: @colortheme_alertify-green; + border-color: @colortheme_alertify-green-border; + color: @colortheme_alertify-green-color; + &:hover, &:active { + background-color: contrast(@colortheme_modal-bg, darken(@colortheme_alertify-green, 10%), lighten(@colortheme_alertify-green, 10%)); } + } + &.primary { + background-color: @colortheme_alertify-primary; + color: @colortheme_alertify-primary-text; + border-color: @colortheme_alertify-primary-border; + font-weight: bold; &:hover, &:active { - background-color: contrast(@colortheme_modal-bg, darken(@colortheme_alertify-cancel, 10%), lighten(@colortheme_alertify-cancel, 10%)); + background-color: contrast(@colortheme_modal-bg, darken(@colortheme_alertify-primary, 10%), lighten(@colortheme_alertify-primary, 10%)); } + } - &:focus { - //border: 1px dotted @alertify-base; - box-shadow: 0px 0px 5px @colortheme_alertify-primary; - outline: none; - } - &::-moz-focus-inner { - border: 0; - } + &:hover, &:active { + background-color: contrast(@colortheme_modal-bg, darken(@colortheme_alertify-cancel, 10%), lighten(@colortheme_alertify-cancel, 10%)); } - button.btn { - margin: 6px 4px; + &:focus { + //border: 1px dotted @alertify-base; + box-shadow: 0px 0px 5px @colortheme_alertify-primary; + outline: none; + } + &::-moz-focus-inner { + border: 0; } } + + button.btn { + margin: 6px 4px; + } + + nav { + text-align: right; + } } } diff --git a/customize.dist/src/less2/include/password-input.less b/customize.dist/src/less2/include/password-input.less index 015f364aa..8836476fd 100644 --- a/customize.dist/src/less2/include/password-input.less +++ b/customize.dist/src/less2/include/password-input.less @@ -5,7 +5,6 @@ input { flex: 1; min-width: 0; - margin-bottom: 0 !important; // Override margin from alertify } label, .fa { margin-left: 10px; diff --git a/customize.dist/translations/messages.fr.js b/customize.dist/translations/messages.fr.js index 23fe16f91..838dfcd2b 100644 --- a/customize.dist/translations/messages.fr.js +++ b/customize.dist/translations/messages.fr.js @@ -1117,6 +1117,16 @@ define(function () { out.password_submit = "Valider"; out.password_show = "Afficher"; + // Change password in pad properties + out.properties_addPassword = "Ajouter un mot de passe"; + out.properties_changePassword = "Modifier le mot de passe"; + out.properties_confirmNew = "Êtes-vous sûr ? Ajouter un mot de passe changera l'URL de ce pad. Les utilisateurs ne connaissant pas le nouveau mot de passe perdront l'accès au pad."; + out.properties_confirmChange = "Êtes-vous sûr ? Les utilisateurs ne connaissant pas le nouveau mot de passe perdront l'accès au pad."; + out.properties_passwordError = "Une erreur est survenue lors de la modification du mot de passe. Veuillez réessayer."; + out.properties_passwordWarning = "Le mot de passe a été modifié avec succès mais nous n'avons pas réussi à mettre à jour votre CryptDrive avec les nouvelles informations. Vous devrez peut-être supprimer manuellement l'ancienne version de ce pad.
Appuyez sur OK pour recharger le pad et mettre à jour vos droits d'accès."; + out.properties_passwordSuccess = "Le mot de passe a été modifié avec succès.
Appuyez sur OK pour mettre à jour vos droits d'accès."; + out.properties_changePasswordButton = "Valider"; + // New share modal out.share_linkCategory = "Partage"; out.share_linkAccess = "Droits d'accès"; diff --git a/customize.dist/translations/messages.js b/customize.dist/translations/messages.js index 02ed5859c..16e837a35 100644 --- a/customize.dist/translations/messages.js +++ b/customize.dist/translations/messages.js @@ -1155,13 +1155,23 @@ define(function () { out.creation_newPadModalDescriptionAdvanced = "You can check the box (or press Space to change its value) if you want to display the pad creation screen (for owned pads, expiring pads, etc.)."; out.creation_newPadModalAdvanced = "Display the pad creation screen"; - // Password prompt on the loadind screen + // Password prompt on the loading screen out.password_info = "The pad you're trying to open is protected with a password. Enter the correct password to access its content."; out.password_error = "Pad not found!
This error can be caused by two factors: either the password in invalid, or the pad has been deleted from the server."; out.password_placeholder = "Type the password here..."; out.password_submit = "Submit"; out.password_show = "Show"; + // Change password in pad properties + out.properties_addPassword = "Add a password"; + out.properties_changePassword = "Change the password"; + out.properties_confirmNew = "Are you sure? Adding a password will change this pad's URL. Users without the password will lose access to this pad"; + out.properties_confirmChange = "Are you sure? Users without the new password will lose access to this pad"; + out.properties_passwordError = "An error occured while trying to change the password. Please try again."; + out.properties_passwordWarning = "The password was successfully changed but we were unable to update your CryptDrive with the new data. You may have to remove the old version of the pad manually.
Press OK to reload and update your acces rights."; + out.properties_passwordSuccess = "The password was successfully changed.
Press OK to reload and update your access rights."; + out.properties_changePasswordButton = "Submit"; + // New share modal out.share_linkCategory = "Share link"; out.share_linkAccess = "Access rights"; diff --git a/www/common/common-ui-elements.js b/www/common/common-ui-elements.js index 8e0a7b9e4..e138e7efb 100644 --- a/www/common/common-ui-elements.js +++ b/www/common/common-ui-elements.js @@ -136,12 +136,6 @@ define([ $d.append(UI.dialog.selectable(owners, { id: 'cp-app-prop-owners', })); - /* TODO - if (owned) { - var $deleteOwned = $('button').text(Messages.fc_delete_owned).click(function () { - }); - $d.append($deleteOwned); - }*/ var expire = Messages.creation_expireFalse; if (data.expire && typeof (data.expire) === "number") { @@ -153,11 +147,12 @@ define([ id: 'cp-app-prop-expire', })); - if (typeof data.password !== "undefined") { + var hasPassword = typeof data.password !== "undefined"; + if (hasPassword) { $('