add password FAQ links to share modal tabs
This commit is contained in:
parent
f3b1761d0d
commit
951a59f3ea
@ -1033,11 +1033,14 @@ define([
|
|||||||
var parsedHref = Hash.parsePadUrl(href);
|
var parsedHref = Hash.parsePadUrl(href);
|
||||||
var hasPassword = parsedHref.hashData.password;
|
var hasPassword = parsedHref.hashData.password;
|
||||||
|
|
||||||
var faqLink = h('a', {href: '#'}, Messages.passwordFaqLink);
|
var makeFaqLink = function () {
|
||||||
$(faqLink).click(function () {
|
var link = h('a', {href: '#'}, Messages.passwordFaqLink);
|
||||||
console.log(config.origin + "/faq.html#security-pad_password");
|
$(link).click(function () {
|
||||||
common.openURL(config.origin + "/faq.html#security-pad_password");
|
common.openURL(config.origin + "/faq.html#security-pad_password");
|
||||||
});
|
});
|
||||||
|
return link;
|
||||||
|
};
|
||||||
|
|
||||||
|
|
||||||
var parsed = Hash.parsePadUrl(pathname);
|
var parsed = Hash.parsePadUrl(pathname);
|
||||||
var canPresent = ['code', 'slide'].indexOf(parsed.type) !== -1;
|
var canPresent = ['code', 'slide'].indexOf(parsed.type) !== -1;
|
||||||
@ -1098,8 +1101,11 @@ define([
|
|||||||
|
|
||||||
// Show alert if the pad is password protected
|
// Show alert if the pad is password protected
|
||||||
if (hasPassword) {
|
if (hasPassword) {
|
||||||
linkContent.push(h('div.alert.alert-primary', [h('i.fa.fa-lock'),
|
linkContent.push(h('div.alert.alert-primary', [
|
||||||
' ', Messages.share_linkPasswordAlert]))
|
h('i.fa.fa-lock'), ' ',
|
||||||
|
Messages.share_linkPasswordAlert, ' ',
|
||||||
|
makeFaqLink()
|
||||||
|
]))
|
||||||
};
|
};
|
||||||
|
|
||||||
var link = h('div.cp-share-modal', linkContent);
|
var link = h('div.cp-share-modal', linkContent);
|
||||||
@ -1173,8 +1179,11 @@ define([
|
|||||||
|
|
||||||
// Show alert if the pad is password protected
|
// Show alert if the pad is password protected
|
||||||
if (hasPassword) {
|
if (hasPassword) {
|
||||||
$contactsContent.append(h('div.alert.alert-primary', [h('i.fa.fa-unlock'),
|
$contactsContent.append(h('div.alert.alert-primary', [
|
||||||
' ', Messages.share_contactPasswordAlert]))
|
h('i.fa.fa-lock'), ' ',
|
||||||
|
Messages.share_contactPasswordAlert, ' ',
|
||||||
|
makeFaqLink()
|
||||||
|
]))
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
@ -1200,12 +1209,11 @@ define([
|
|||||||
];
|
];
|
||||||
|
|
||||||
// Show alert if the pad is password protected
|
// Show alert if the pad is password protected
|
||||||
//
|
|
||||||
if (hasPassword) {
|
if (hasPassword) {
|
||||||
embedContent.push(h('div.alert.alert-primary', [
|
embedContent.push(h('div.alert.alert-primary', [
|
||||||
h('i.fa.fa-lock'), ' ',
|
h('i.fa.fa-lock'), ' ',
|
||||||
Messages.share_embedPasswordAlert, ' ',
|
Messages.share_embedPasswordAlert, ' ',
|
||||||
faqLink
|
makeFaqLink()
|
||||||
]))
|
]))
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user