remove // XXX related to translations

pull/1/head
David Benqué 5 years ago
parent 0eb89871cf
commit 09d1ddf825

@ -315,8 +315,6 @@ define([
} }
}; };
Messages.comments_notification = 'Replies to your comment "{0}" in <b>{1}</b>'; // XXX
Messages.unknownPad = "Unknown pad"; // XXX
handlers['COMMENT_REPLY'] = function(common, data) { handlers['COMMENT_REPLY'] = function(common, data) {
var content = data.content; var content = data.content;
var msg = content.msg; var msg = content.msg;
@ -344,7 +342,6 @@ define([
} }
}; };
Messages.mentions_notification = '{0} has mentionned you in <b>{1}</b>'; // XXX
handlers['MENTION'] = function(common, data) { handlers['MENTION'] = function(common, data) {
var content = data.content; var content = data.content;
var msg = content.msg; var msg = content.msg;

@ -154,11 +154,6 @@ define([
selection.addRange(range); selection.addRange(range);
}; };
Messages.comments_deleted = "Comment deleted by its author"; // XXX
Messages.comments_edited = "Edited"; // XXX
Messages.comments_submit = "Submit"; // XXX
Messages.comments_reply = "Reply"; // XXX
Messages.comments_resolve = "Resolve"; // XXX
var getCommentForm = function(Env, reply, _cb, editContent) { var getCommentForm = function(Env, reply, _cb, editContent) {
var cb = Util.once(_cb); var cb = Util.once(_cb);
var userData = Env.metadataMgr.getUserData(); var userData = Env.metadataMgr.getUserData();
@ -783,8 +778,6 @@ define([
var applicable = Env.editor.plugins.comments.isApplicable(); var applicable = Env.editor.plugins.comments.isApplicable();
if (!applicable) { if (!applicable) {
// Abort if our selection contains a comment // Abort if our selection contains a comment
console.error("Can't add a comment here");
// XXX show error
UI.warn(Messages.comments_error); UI.warn(Messages.comments_error);
return; return;
} }

@ -65,8 +65,7 @@ define([
ChainPad, ChainPad,
AppConfig, AppConfig,
Test Test
) ) {
{
var DiffDom = window.diffDOM; var DiffDom = window.diffDOM;
var slice = function(coll) { var slice = function(coll) {
@ -287,15 +286,13 @@ define([
// Don't remote the "active" class of our comments // Don't remote the "active" class of our comments
if (info.node && info.node.tagName === 'COMMENT') { if (info.node && info.node.tagName === 'COMMENT') {
if (info.diff.action === 'removeAttribute' && if (info.diff.action === 'removeAttribute' && ['class'].indexOf(info.diff.name) !== -1) {
['class'].indexOf(info.diff.name) !== -1) {
return true; return true;
} }
} }
if (info.node && info.node.tagName === 'BODY') { if (info.node && info.node.tagName === 'BODY') {
if (info.diff.action === 'removeAttribute' && if (info.diff.action === 'removeAttribute' && ['class', 'spellcheck'].indexOf(info.diff.name) !== -1) {
['class', 'spellcheck'].indexOf(info.diff.name) !== -1) {
return true; return true;
} }
} }
@ -404,8 +401,7 @@ define([
}; };
framework._.sfCommon.getAttribute(['pad', 'showToolbar'], function(err, data) { framework._.sfCommon.getAttribute(['pad', 'showToolbar'], function(err, data) {
if (($(window).height() >= 800 || $(window).width() >= 800) && if (($(window).height() >= 800 || $(window).width() >= 800) &&
(typeof(data) === "undefined" || data)) { $('.cke_toolbox_main').show(); } (typeof(data) === "undefined" || data)) { $('.cke_toolbox_main').show(); } else { $('.cke_toolbox_main').hide(); }
else { $('.cke_toolbox_main').hide(); }
var $collapse = framework._.sfCommon.createButton('toggle', true, cfg, onClick); var $collapse = framework._.sfCommon.createButton('toggle', true, cfg, onClick);
framework._.toolbar.$rightside.append($collapse); framework._.toolbar.$rightside.append($collapse);
}); });
@ -485,8 +481,8 @@ define([
var $a; var $a;
for (var i = 0; i < mut.addedNodes.length; i++) { for (var i = 0; i < mut.addedNodes.length; i++) {
$a = $(mut.addedNodes[i]); $a = $(mut.addedNodes[i]);
if ($a.is('p') && $a.find('> span:empty').length if ($a.is('p') && $a.find('> span:empty').length &&
&& $a.find('> br').length && $a.children().length === 2) { $a.find('> br').length && $a.children().length === 2) {
$a.find('> span').append($a.find('> br')); $a.find('> span').append($a.find('> br'));
} }
} }
@ -947,7 +943,6 @@ define([
'import': Messages.pad_mediatagImport, 'import': Messages.pad_mediatagImport,
options: Messages.pad_mediatagOptions options: Messages.pad_mediatagOptions
}; };
Messages.comments_comment = "COMMENT"; // XXX
Ckeditor._commentsTranslations = { Ckeditor._commentsTranslations = {
comment: Messages.comments_comment, comment: Messages.comments_comment,
}; };
@ -1048,8 +1043,7 @@ define([
test.pass(); test.pass();
} }
}, 500); }, 500);
} else } else {
{
test.fail("Not all expected a elements found for document at " + window.top.location + "."); test.fail("Not all expected a elements found for document at " + window.top.location + ".");
} }
} }

@ -36,8 +36,7 @@ define([
ApiConfig, ApiConfig,
Backup, Backup,
Feedback Feedback
) ) {
{
var saveAs = window.saveAs; var saveAs = window.saveAs;
var APP = window.APP = {}; var APP = window.APP = {};
@ -186,7 +185,8 @@ define([
var $input = $('<input>', { var $input = $('<input>', {
'type': 'text', 'type': 'text',
'id': 'cp-settings-displayname', 'id': 'cp-settings-displayname',
'placeholder': Messages.anonymous}).appendTo($inputBlock); 'placeholder': Messages.anonymous
}).appendTo($inputBlock);
var $save = $('<button>', { 'class': 'btn btn-primary' }).text(Messages.settings_save).appendTo($inputBlock); var $save = $('<button>', { 'class': 'btn btn-primary' }).text(Messages.settings_save).appendTo($inputBlock);
var $ok = $('<span>', { 'class': 'fa fa-check', title: Messages.saved }).hide().appendTo($div); var $ok = $('<span>', { 'class': 'fa fa-check', title: Messages.saved }).hide().appendTo($div);
var $spinner = $('<span>', { 'class': 'fa fa-spinner fa-pulse' }).hide().appendTo($div); var $spinner = $('<span>', { 'class': 'fa fa-spinner fa-pulse' }).hide().appendTo($div);
@ -866,7 +866,8 @@ define([
if (err) { return void console.error(err); } if (err) { return void console.error(err); }
var sjson = JSON.stringify(data); var sjson = JSON.stringify(data);
UI.prompt(Messages.exportPrompt, UI.prompt(Messages.exportPrompt,
Util.fixFileName(suggestion) + '.json', function (filename) { Util.fixFileName(suggestion) + '.json',
function(filename) {
if (!(typeof(filename) === 'string' && filename)) { return; } if (!(typeof(filename) === 'string' && filename)) { return; }
var blob = new Blob([sjson], { type: "application/json;charset=utf-8" }); var blob = new Blob([sjson], { type: "application/json;charset=utf-8" });
saveAs(blob, filename); saveAs(blob, filename);
@ -922,7 +923,8 @@ define([
if (err) { return void console.error(err); } if (err) { return void console.error(err); }
if (data.error) { return void console.error(data.error); } if (data.error) { return void console.error(data.error); }
UI.prompt(Messages.settings_backup2Confirm, UI.prompt(Messages.settings_backup2Confirm,
Util.fixFileName(suggestion) + '.zip', function (filename) { Util.fixFileName(suggestion) + '.zip',
function(filename) {
if (!(typeof(filename) === 'string' && filename)) { return; } if (!(typeof(filename) === 'string' && filename)) { return; }
todo(data, filename); todo(data, filename);
}); });
@ -1276,12 +1278,6 @@ define([
return $div; return $div;
}; };
// XXX Messages.settings_padNotifTitle
// XXX Messages.settings_padNotifHint
// XXX Messages.settings_padNotifCheckbox ("disable comments notifications")
Messages.settings_padNotifTitle = "Comments notifications"; // XXX
Messages.settings_padNotifHint = "Block notifications when someone replies to one of your comments"; // XXX
Messages.settings_padNotifCheckbox = "Disable comment notifications";
makeBlock('pad-notif', function(cb) { makeBlock('pad-notif', function(cb) {
var $cbox = $(UI.createCheckbox('cp-settings-pad-notif', var $cbox = $(UI.createCheckbox('cp-settings-pad-notif',
Messages.settings_padNotifCheckbox, Messages.settings_padNotifCheckbox,

Loading…
Cancel
Save