From fde1edd508ec478f7203f526a646eeccfcb9ba15 Mon Sep 17 00:00:00 2001 From: David Benque Date: Fri, 8 Dec 2023 15:10:19 +0000 Subject: [PATCH 1/3] Clean old // XXX comments - either removed or changed the comment type --- customize.dist/src/less2/include/alertify.less | 2 +- customize.dist/src/less2/include/markdown.less | 2 +- customize.dist/src/less2/include/toolbar-history.less | 1 - customize.dist/src/less2/include/toolbar.less | 1 - lib/challenge-commands/totp.js | 2 +- lib/storage/file.js | 2 +- www/admin/app-admin.less | 4 ++-- www/common/common-interface.js | 4 ++-- www/common/common-ui-elements.js | 4 ++-- www/common/media-tag.js | 2 +- www/common/outer/http-command.js | 2 +- www/common/proxy-manager.js | 2 +- www/common/sframe-common.js | 2 +- www/convert/inner.js | 6 +++--- www/teams/app-team.less | 2 +- 15 files changed, 18 insertions(+), 20 deletions(-) diff --git a/customize.dist/src/less2/include/alertify.less b/customize.dist/src/less2/include/alertify.less index 0280d62e2..f01e69a37 100644 --- a/customize.dist/src/less2/include/alertify.less +++ b/customize.dist/src/less2/include/alertify.less @@ -497,7 +497,7 @@ overflow-x: auto; } } - // XXX this might not be the best place for this. + // this might not be the best place for this. // I just put it next to other "share" styles // --Aaron #cp-qr-container { diff --git a/customize.dist/src/less2/include/markdown.less b/customize.dist/src/less2/include/markdown.less index 33ea1ee78..16e6654ed 100644 --- a/customize.dist/src/less2/include/markdown.less +++ b/customize.dist/src/less2/include/markdown.less @@ -132,7 +132,7 @@ text { &.taskText { &[class*="doneText"], &[class*="activeText"] { - fill: #444 !important; // XXX PR to mermaid or find a suitable variable + fill: #444 !important; // TODO PR to mermaid or find a suitable variable } } &.titleText { diff --git a/customize.dist/src/less2/include/toolbar-history.less b/customize.dist/src/less2/include/toolbar-history.less index 2acd36731..d2c854034 100644 --- a/customize.dist/src/less2/include/toolbar-history.less +++ b/customize.dist/src/less2/include/toolbar-history.less @@ -106,7 +106,6 @@ margin-right: 5px; } &:hover { - // XXX DB: check hover in light/dark themes background-color: fade(@cp_toolbar-fg, 30%); } &:disabled { diff --git a/customize.dist/src/less2/include/toolbar.less b/customize.dist/src/less2/include/toolbar.less index 5b0a66433..7d3f1ab90 100644 --- a/customize.dist/src/less2/include/toolbar.less +++ b/customize.dist/src/less2/include/toolbar.less @@ -21,7 +21,6 @@ @bg-color: @colortheme_apps[default], // color of the toolbar background ) { @toolbar-bg-color: @bg-color; - // XXX: check contrasts of app colors used as btn background @toolbar-bg-color-light: lighten(@bg-color, 30%); @toolbar-bg-color-fade: fade(@toolbar-bg-color-light, 60%); }; diff --git a/lib/challenge-commands/totp.js b/lib/challenge-commands/totp.js index 0ad8d15ef..769643c61 100644 --- a/lib/challenge-commands/totp.js +++ b/lib/challenge-commands/totp.js @@ -61,7 +61,7 @@ var decode32 = S => { }; -// XXX Decide expire time +// Decide expire time // Allow user settings? var EXPIRATION = 7 * 24 * 3600 * 1000; // Sessions are valid 7 days diff --git a/lib/storage/file.js b/lib/storage/file.js index 8a5a8fd62..e22c3be85 100644 --- a/lib/storage/file.js +++ b/lib/storage/file.js @@ -804,7 +804,7 @@ var unarchiveChannel = function (env, channelName, cb) { } if (exists) { w.abort(); - return CB("UNARCHIVE_METADATA_CONFLICT"); // XXX + return CB("UNARCHIVE_METADATA_CONFLICT"); } })); }).nThen(function (w) { diff --git a/www/admin/app-admin.less b/www/admin/app-admin.less index 28efad7e7..f674160ca 100644 --- a/www/admin/app-admin.less +++ b/www/admin/app-admin.less @@ -354,14 +354,14 @@ table.cp-block-stats, table.cp-pin-list, table.cp-document-stats { - @color: #777; // XXX + @color: #777; // TODO use a colotheme variable border: 1px solid @color; margin: 15px; td, pre { color: @cryptpad_text_col; } td, th { - max-width: 60vw; // XXX + max-width: 60vw; border: 1px solid @color; padding: 5px; .scroll { diff --git a/www/common/common-interface.js b/www/common/common-interface.js index aa1e4d39d..c08eafded 100644 --- a/www/common/common-interface.js +++ b/www/common/common-interface.js @@ -1047,9 +1047,9 @@ define([ window.parent.location = href; }); if (exitable) { - // XXX if true or function, ALSO add a button to leave + // if true or function, ALSO add a button to leave $(window).focus(); - $(window).keydown(function (e) { // XXX what if they don't have a keyboard? + $(window).keydown(function (e) { // what if they don't have a keyboard? if (e.which === 27) { e.preventDefault(); e.stopPropagation(); diff --git a/www/common/common-ui-elements.js b/www/common/common-ui-elements.js index 6f1175cee..afd9f0c06 100644 --- a/www/common/common-ui-elements.js +++ b/www/common/common-ui-elements.js @@ -2878,7 +2878,7 @@ define([ if (err.type === 'EEXPIRED') { msg = Messages.expiredError; if (err.loaded) { - // XXX You can still use the current version in read-only mode by pressing Esc. + // You can still use the current version in read-only mode by pressing Esc. // what if they don't have a keyboard (ie. mobile) msg += Messages.errorCopy; } @@ -2902,7 +2902,7 @@ define([ }); } if (err.message && (err.message !== "PASSWORD_CHANGE" || viewer)) { - // XXX If readonly, tell the viewer that their link won't work with the new password + // If readonly, tell the viewer that their link won't work with the new password UI.errorLoadingScreen(UI.getDestroyedPlaceholder(err.message, false), exitable, exitable); return; diff --git a/www/common/media-tag.js b/www/common/media-tag.js index cf14ee700..5e126f0ac 100644 --- a/www/common/media-tag.js +++ b/www/common/media-tag.js @@ -7,7 +7,7 @@ var factory = function () { var Promise = window.Promise; var cache; var cypherChunkLength = 131088; - var sendCredentials = window.sendCredentials || false; // XXX SSO find a logical place to infer whether this should be set + var sendCredentials = window.sendCredentials || false; // SSO find a logical place to infer whether this should be set // Save a blob on the file system var saveFile = function (blob, url, fileName) { diff --git a/www/common/outer/http-command.js b/www/common/outer/http-command.js index d95fec94f..03d59ddfa 100644 --- a/www/common/outer/http-command.js +++ b/www/common/outer/http-command.js @@ -23,7 +23,7 @@ define([ }).then(response => { if (response.ok) { - return void response.text().then(result => { CB(void 0, Util.tryParse(result)); }); // XXX checkup error when using .json() + return void response.text().then(result => { CB(void 0, Util.tryParse(result)); }); // checkup error when using .json() //return void response.json().then(result => { CB(void 0, result); }); } diff --git a/www/common/proxy-manager.js b/www/common/proxy-manager.js index 7ef7332d5..f09ac87b5 100644 --- a/www/common/proxy-manager.js +++ b/www/common/proxy-manager.js @@ -1254,7 +1254,7 @@ define([ var data = userObject.getFileData(fileId); if (!data) { return; } // Don't pin pads owned by someone else - //if (_ownedByOther(Env, data.owners)) { return; } // XXX + //if (_ownedByOther(Env, data.owners)) { return; } // Pin onlyoffice checkpoints if (data.lastVersion) { var otherChan = Hash.hrefToHexChannelId(data.lastVersion); diff --git a/www/common/sframe-common.js b/www/common/sframe-common.js index 565950770..48be2403b 100644 --- a/www/common/sframe-common.js +++ b/www/common/sframe-common.js @@ -910,7 +910,7 @@ define([ ctx.sframeChan.on('EV_LOADING_ERROR', function (err) { var msg = err; if (err === 'DELETED' || (err && err.type === 'EDELETED')) { - // XXX You can still use the current version in read-only mode by pressing Esc. + // You can still use the current version in read-only mode by pressing Esc. // what if they don't have a keyboard (ie. mobile) if (err.type && err.message) { msg = UI.getDestroyedPlaceholderMessage(err.message, false, true); diff --git a/www/convert/inner.js b/www/convert/inner.js index c7e01ce6c..c5f1a7cbb 100644 --- a/www/convert/inner.js +++ b/www/convert/inner.js @@ -296,9 +296,9 @@ define([ }, }; - Messages.convertPage = "Convert"; // XXX 4.11.0 - Messages.convert_hint = "Pick the file you want to convert. The list of output format will be visible afterwards."; // XXX 4.11.0 - Messages.convert_unsupported = "UNSUPPORTED FILE TYPE :("; // XXX + Messages.convertPage = "Convert"; // TODO: hard-coded text since 4.11.0 + Messages.convert_hint = "Pick the file you want to convert. The list of output format will be visible afterwards."; + Messages.convert_unsupported = "UNSUPPORTED FILE TYPE :("; var createToolbar = function () { var displayed = ['useradmin', 'newpad', 'limit', 'pageTitle', 'notifications']; diff --git a/www/teams/app-team.less b/www/teams/app-team.less index bdfaf50b1..db1efa29b 100644 --- a/www/teams/app-team.less +++ b/www/teams/app-team.less @@ -293,7 +293,7 @@ } } - .cp-teams-invite-uses { // XXX + .cp-teams-invite-uses { input { margin-bottom: 0px !important; margin-right: 10px; From 3593b44e9fcacbc28614207f8556eccf131239c1 Mon Sep 17 00:00:00 2001 From: David Benque Date: Tue, 12 Dec 2023 15:24:49 +0000 Subject: [PATCH 2/3] Remove //XXX --- www/calendar/app-calendar.less | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/www/calendar/app-calendar.less b/www/calendar/app-calendar.less index 232f3467d..85fc68991 100644 --- a/www/calendar/app-calendar.less +++ b/www/calendar/app-calendar.less @@ -534,7 +534,7 @@ color: @cp_toolbar-fg; border-color: @cp_toolbar-fg; &:hover { - background-color: fade(@cp_toolbar-fg, 50%); //XXX check light theme + background-color: fade(@cp_toolbar-fg, 50%); cursor: pointer; } } From 84a1d968721f873fdfd2a7503ec4b56457488961 Mon Sep 17 00:00:00 2001 From: David Benque Date: Tue, 12 Dec 2023 15:31:41 +0000 Subject: [PATCH 3/3] Convert // XXX comments to // NEXT These things will be considered for the next release cycle in this case it is QR code for the share modal --- www/common/inner/share.js | 10 +++++----- www/common/outer/async-store.js | 2 +- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/www/common/inner/share.js b/www/common/inner/share.js index b3576f0a7..ed0415fd7 100644 --- a/www/common/inner/share.js +++ b/www/common/inner/share.js @@ -511,7 +511,7 @@ define([ return container; }; - Messages.share_toggleQR = "Click to toggle QR code visibility"; // XXX + Messages.share_toggleQR = "Click to toggle QR code visibility"; // NEXT var getQRTab = function (Env, data, opts, _cb) { var qr = getQRCode(opts.getLinkValue()); @@ -525,7 +525,7 @@ define([ className: 'primary cp-bar', name: Messages.share_bar, onClick: function () { - UI.warn("OOPS: NOT IMPLEMENTED"); // XXX + UI.warn("OOPS: NOT IMPLEMENTED"); // NEXT return true; }, }, @@ -794,7 +794,7 @@ define([ return $rights; }; - Messages.share_QRCategory = "QR"; // XXX + Messages.share_QRCategory = "QR"; // NEXT // In the share modal, tabs need to share data between themselves. // To do so we're using "opts" to store data and functions @@ -854,7 +854,7 @@ define([ title: Messages.share_linkCategory, icon: "fa fa-link", active: !contactsActive, - }, window.CP_DEV_MODE ? { // XXX enable for all + }, window.CP_DEV_MODE ? { // NEXT enable for all getTab: getQRTab, title: Messages.share_QRCategory, icon: 'fa fa-qrcode', @@ -1056,7 +1056,7 @@ define([ active: !hasFriends, }]; - // XXX add QR code generation for files + // NEXT add QR code generation for files if (ApiConfig.enableEmbedding) { tabs.push({ getTab: getFileEmbedTab, diff --git a/www/common/outer/async-store.js b/www/common/outer/async-store.js index fe4e07784..97e1dd10c 100644 --- a/www/common/outer/async-store.js +++ b/www/common/outer/async-store.js @@ -251,7 +251,7 @@ define([ list.push(userChannel); if (store.data && store.data.blockId) { - //list.push(`${store.data.blockId}#block`); // XXX 5.5.0? + //list.push(`${store.data.blockId}#block`); // NEXT 5.7.0? } list.sort();