reuse code assign attributes to a remote link

pull/1/head
ansuz 4 years ago
parent 110aaf04ea
commit 3d78fa7d6f

@ -12,6 +12,7 @@ define([
'/support/ui.js', '/support/ui.js',
'/api/config', '/api/config',
'/customize/application_config.js', '/customize/application_config.js',
'/customize/pages.js',
'css!/bower_components/bootstrap/dist/css/bootstrap.min.css', 'css!/bower_components/bootstrap/dist/css/bootstrap.min.css',
'css!/bower_components/components-font-awesome/css/font-awesome.min.css', 'css!/bower_components/components-font-awesome/css/font-awesome.min.css',
@ -29,7 +30,8 @@ define([
h, h,
Support, Support,
ApiConfig, ApiConfig,
AppConfig AppConfig,
Pages
) )
{ {
var APP = window.APP = {}; var APP = window.APP = {};
@ -168,11 +170,7 @@ define([
create['form'] = function () { create['form'] = function () {
var key = 'form'; var key = 'form';
var $div = makeBlock(key, true); // Msg.support_formHint, .support_formTitle, .support_formButton var $div = makeBlock(key, true); // Msg.support_formHint, .support_formTitle, .support_formButton
$div.find('a').attr({ Pages.externalLink($div.find('a')[0], 'https://docs.cryptpad.fr/en/user_guide/index.html');
rel: 'noopener noreferrer',
target: '_blank',
href: 'https://docs.cryptpad.fr/en/user_guide/index.html',
});
var form = APP.support.makeForm(); var form = APP.support.makeForm();

Loading…
Cancel
Save