Merge branch 'staging' into eunknown

pull/1/head
yflory 4 years ago
commit fe9d39c66b

Binary file not shown.

After

Width:  |  Height:  |  Size: 367 KiB

@ -8,7 +8,7 @@ define([
return function () { return function () {
var adminEmail = Config.adminEmail && Config.adminEmail !== 'i.did.not.read.my.config@cryptpad.fr'; var adminEmail = Config.adminEmail && Config.adminEmail !== 'i.did.not.read.my.config@cryptpad.fr';
var adminMailbox = Config.supportMailbox; var adminMailbox = Config.supportMailbox && LocalStore.isLoggedIn();
return h('div#cp-main', [ return h('div#cp-main', [
Pages.infopageTopbar(), Pages.infopageTopbar(),
h('div.container.cp-container', [ h('div.container.cp-container', [
@ -34,7 +34,7 @@ define([
) )
) )
) : undefined, ) : undefined,
(adminMailbox && LocalStore.isLoggedIn()) ? h('div.col-12.col-sm-6.col-md-3.col-lg-3', adminMailbox ? h('div.col-12.col-sm-6.col-md-3.col-lg-3',
h('a.card', {href : "/support/"}, h('a.card', {href : "/support/"},
h('div.card-body', h('div.card-body',
h('p', [ h('p', [

@ -7,7 +7,6 @@ define([
'/customize/pages.js', '/customize/pages.js',
'/api/config', '/api/config',
], function ($, h, Msg, AppConfig, LocalStore, Pages, Config) { ], function ($, h, Msg, AppConfig, LocalStore, Pages, Config) {
var origin = encodeURIComponent(window.location.hostname);
var accounts = { var accounts = {
donateURL: AppConfig.donateURL || "https://opencollective.com/cryptpad/", donateURL: AppConfig.donateURL || "https://opencollective.com/cryptpad/",
upgradeURL: AppConfig.upgradeURL upgradeURL: AppConfig.upgradeURL

@ -133,8 +133,8 @@ define([
]), ]),
blocks, blocks,
]), ]),
]),
Pages.infopageFooter(), Pages.infopageFooter(),
]),
]; ];
}; };
}); });

@ -64,19 +64,23 @@ define([
h('div.col-md-6.order-md-1.small-logos', [ h('div.col-md-6.order-md-1.small-logos', [
h('img', { h('img', {
src: '/customize/images/logo_ngi.png?' + urlArgs, src: '/customize/images/logo_ngi.png?' + urlArgs,
alt: 'Logo NGI Trust' alt: 'NGI Award 2019'
}), }),
h('img', { h('img', {
src: '/customize/images/logo_nlnet.svg?' + urlArgs, src: '/customize/images/logo_nlnet.svg?' + urlArgs,
alt: 'Logo NLNet Foundation' alt: 'NLNet Foundation logo'
}), }),
h('img', { h('img', {
src: '/customize/images/logo_bpifrance.svg?' + urlArgs, src: '/customize/images/logo_bpifrance.svg?' + urlArgs,
alt: 'Logo BPI France' alt: 'BPI France logo'
}), }),
h('img', { h('img', {
src: '/customize/images/logo_moss.jpg?' + urlArgs, src: '/customize/images/logo_moss.jpg?' + urlArgs,
alt: 'Logo Mozilla Open Source Support' alt: 'Mozilla Open Source Support logo'
}),
h('img', {
src: '/customize/images/logo_ngi_trust.png?' + urlArgs,
alt: 'NGI Trust logo'
}), }),
]), ]),
]), ]),

@ -60,7 +60,7 @@
@colortheme_alertify-cancel: @colortheme_modal-bg; @colortheme_alertify-cancel: @colortheme_modal-bg;
@colortheme_alertify-cancel-border: #949494; @colortheme_alertify-cancel-border: #949494;
@colortheme_notification-log: fade(@colortheme_logo-1, 90%); @colortheme_notification-log: fade(@colortheme_logo-2, 90%);
@colortheme_notification-color: #fff;; @colortheme_notification-color: #fff;;
@colortheme_notification-warn: rgba(205, 37, 50, 0.8); @colortheme_notification-warn: rgba(205, 37, 50, 0.8);

@ -54,6 +54,8 @@
height: unset !important; height: unset !important;
max-height: 140px; // 6 lines max-height: 140px; // 6 lines
padding: 3px 5px; padding: 3px 5px;
user-select: text;
-webkit-user-select: text; // fix for iOS (can't type in contenteditable if user-select none)
} }
margin-bottom: 5px; margin-bottom: 5px;
} }

@ -37,6 +37,16 @@ body {
margin: 0; margin: 0;
font-size: 16px; font-size: 16px;
font-family: @colortheme_font; font-family: @colortheme_font;
#cp-main {
display: flex;
flex-flow: column;
min-height: 100vh;
& > .cp-container {
flex: 1;
}
}
.cp-container { .cp-container {
font-size: 16px; font-size: 16px;
padding-top: @infopages_padding; padding-top: @infopages_padding;
@ -121,6 +131,8 @@ body {
background-color: @footer-color; background-color: @footer-color;
padding-top: 20px; padding-top: 20px;
align-self: normal; // override align-items:center from parent in index.html
.container { .container {
margin-bottom: 20px; margin-bottom: 20px;
a { a {

@ -94,6 +94,7 @@
flex-flow: column; flex-flow: column;
flex: 1; flex: 1;
min-width: 0; min-width: 0;
color: @colortheme_base;
.cp-app-contacts-name { .cp-app-contacts-name {
white-space: nowrap; white-space: nowrap;
} }
@ -113,7 +114,7 @@
width: 20px; width: 20px;
text-align: center; text-align: center;
&:hover { &:hover {
color: darken(@msg-color, 20%); color: @cryptpad_text_col;
} }
} }

@ -38,6 +38,19 @@
p:empty { p:empty {
display: none; display: none;
} }
nav {
display: flex;
align-items: center;
justify-content: flex-end;
}
@media screen and (max-width: 600px) {
nav .btn-danger {
line-height: inherit;
}
}
} }
.cp-register-det { .cp-register-det {

@ -659,7 +659,16 @@ define([
// Put in the following function the RPC queries that should also work in filepicker // Put in the following function the RPC queries that should also work in filepicker
var _sframeChan = sframeChan;
var addCommonRpc = function (sframeChan, safe) { var addCommonRpc = function (sframeChan, safe) {
// Send UI.log and UI.warn commands from the secureiframe to the normal iframe
sframeChan.on('EV_ALERTIFY_LOG', function (msg) {
_sframeChan.event('EV_ALERTIFY_LOG', msg);
});
sframeChan.on('EV_ALERTIFY_WARN', function (msg) {
_sframeChan.event('EV_ALERTIFY_WARN', msg);
});
Cryptpad.universal.onEvent.reg(function (data) { Cryptpad.universal.onEvent.reg(function (data) {
sframeChan.event('EV_UNIVERSAL_EVENT', data); sframeChan.event('EV_UNIVERSAL_EVENT', data);
}); });

@ -851,6 +851,14 @@ define([
Feedback.init(feedback); Feedback.init(feedback);
} catch (e) { Feedback.init(false); } } catch (e) { Feedback.init(false); }
if (privateData.secureIframe) {
UI.log = function (msg) { ctx.sframeChan.event('EV_ALERTIFY_LOG', msg); };
UI.warn = function (msg) { ctx.sframeChan.event('EV_ALERTIFY_WARN', msg); };
} else {
ctx.sframeChan.on('EV_ALERTIFY_LOG', function (msg) { UI.log(msg); });
ctx.sframeChan.on('EV_ALERTIFY_WARN', function (msg) { UI.warn(msg); });
}
try { try {
var forbidden = privateData.disabledApp; var forbidden = privateData.disabledApp;
if (forbidden) { if (forbidden) {

@ -102,6 +102,7 @@ define([
password: config.data.password, password: config.data.password,
isTemplate: isTemplate, isTemplate: isTemplate,
file: config.data.file, file: config.data.file,
secureIframe: true,
}; };
for (var k in additionalPriv) { metaObj.priv[k] = additionalPriv[k]; } for (var k in additionalPriv) { metaObj.priv[k] = additionalPriv[k]; }

Loading…
Cancel
Save