2020-10-30 20:34:04 +00:00
|
|
|
// Copyright 2018-2020 Signal Messenger, LLC
|
|
|
|
// SPDX-License-Identifier: AGPL-3.0-only
|
|
|
|
|
2018-07-07 00:48:14 +00:00
|
|
|
/* global $: false */
|
|
|
|
|
2018-07-03 22:33:50 +00:00
|
|
|
// Add version
|
|
|
|
$('.version').text(`v${window.getVersion()}`);
|
|
|
|
|
|
|
|
// Add debugging metadata - environment if not production, app instance name
|
|
|
|
const states = [];
|
|
|
|
|
|
|
|
if (window.getEnvironment() !== 'production') {
|
|
|
|
states.push(window.getEnvironment());
|
|
|
|
}
|
|
|
|
if (window.getAppInstance()) {
|
|
|
|
states.push(window.getAppInstance());
|
|
|
|
}
|
|
|
|
|
|
|
|
$('.environment').text(states.join(' - '));
|
|
|
|
|
|
|
|
// Install the 'dismiss with escape key' handler
|
2019-11-07 21:36:16 +00:00
|
|
|
$(document).on('keydown', e => {
|
2018-07-03 22:33:50 +00:00
|
|
|
if (e.keyCode === 27) {
|
|
|
|
window.closeAbout();
|
|
|
|
}
|
|
|
|
});
|
|
|
|
|
2020-09-16 16:40:15 +00:00
|
|
|
// Localize the acknowledgment and privacy strings
|
|
|
|
$('.acknowledgments').text(window.i18n('softwareAcknowledgments'));
|
2018-07-03 22:33:50 +00:00
|
|
|
$('.privacy').text(window.i18n('privacyPolicy'));
|