New home page

pull/1/head
David Benqué 4 years ago
parent e0fb26ebc1
commit 0ef1cf0c23

File diff suppressed because one or more lines are too long

After

Width:  |  Height:  |  Size: 26 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 217 KiB

@ -70,7 +70,7 @@ define([
}); });
UI.addTooltips(); UI.addTooltips();
/* /* // XXX remove this commented code?
var more = icons.length < 4? undefined: h('div.bs-callout.cp-callout-more', [ var more = icons.length < 4? undefined: h('div.bs-callout.cp-callout-more', [
h('div.cp-callout-more-lessmsg.cp-hidden', [ h('div.cp-callout-more-lessmsg.cp-hidden', [
"see less ", "see less ",
@ -109,38 +109,52 @@ define([
Feedback.send('HOME_SUPPORT_CRYPTPAD'); Feedback.send('HOME_SUPPORT_CRYPTPAD');
}); });
var blocks = h('div.container',[ Msg.home_privacy_title = "Private by design"; // XXX
h('div.row.justify-content-sm-center',[ Msg.home_privacy_text = "CryptPad is built to enable collaboration while keeping data private. All information including documents, chats, and files is encrypted and decrypted by your browser. This means nothing is readable outside of the session where you are logged in. Even the service administrators do not have access to your information."; // XXX
h('div.col-12.col-sm-4.cp-index-block.cp-index-block-host', h('div', [ Msg.home_host_title = "About this instance"; // XXX
Pages.setHTML(h('span'), Msg.home_host), // XXX adjust Msg.home_host, remove link to Github
h('div.cp-img-container', [ Msg.home_opensource_title = "Open Source"; // XXX
h('img.agpl', { Msg.home_opensource = 'Anyone can host CryptPad and offer the service in a personal or professional capacity. The source code is available on <a href="https://github.com/xwiki-labs/cryptpad">Github</a>.'; // XXX
src: "/customize/images/AGPL.png", Msg.home_support_title = "Support CryptPad"; // XXX
title: Msg.home_host_agpl Msg.home_support = "<p>CryptPad does not profit from user's data. This is part of a vision for online services that respect privacy. Instead of pretending to be \"free\" like the big platforms, CryptPad aims to build a sustainable model: funded willingly by users instead of making profits from personal information.</p><p>You can support the project by making a one-time or recurring donation through our Open Collective. Our budget is transparent and updates are published regularly. There are also a number of <a href=\"https://docs.cryptpad.fr/en/how_to_contribute.html\" rel=\"noopener noreferrer\" target=\"_blank\">non-financial ways to contribute</a>.</p>" // XXX
}),
h('a.img', { var blocks = [
href: 'https://blog.cryptpad.fr/2018/11/13/CryptPad-receives-NGI-Startup-Award/', h('div.row.cp-index-section', [
target: '_blank' h('div.col-sm-6',
}, h('img.ngi', { h('img.img-fluid', {
src: "/customize/images/ngi.png", src:'/customize/images/shredder.png',
title: Msg.home_ngi alt:'illustration, a shredder destroys a sheet of paper and antoher one reconstructs it'
})) })
),
h('div.col-sm-6', [
h('h2', Msg.home_privacy_title),
h('p', Msg.home_privacy_text)
]) ])
])), ]),
h('div.col-12.col-sm-4.cp-index-block.cp-index-block-product', h('div', [ h('div.row.cp-index-section',
Msg.home_product h('div.col-sm-12', [
])), h('h2', Msg.home_host_title),
AppConfig.disableCrowdfundingMessages ? undefined : h('div.col-12.col-sm-4.cp-index-block.cp-index-block-help', h('div', [ Pages.setHTML(h('p'), Msg.home_host) // XXX remove link and .setHTML from this key
Msg.crowdfunding_home1,
h('br'),
Msg.crowdfunding_home2,
h('br'),
crowdFunding,
_link
])),
]) ])
]); ),
Msg.main_catch_phrase = "Collaboration suite,<br>encrypted and open-source"; // XXX h('div.row.cp-index-section', [
h('div.col-sm-6', [
h('h2', Msg.home_opensource_title),
Pages.setHTML(h('p'), Msg.home_opensource),
h('img.small-logo', {
src: '/customize/images/AGPLv3_Logo.svg',
alt: 'APGL3 License Logo'
})
]),
h('div.col-sm-6', [
h('h2', Msg.home_support_title),
Pages.setHTML(h('span'), Msg.home_support),
crowdFunding
])
])
]
Msg.main_catch_phrase = "Collaboration suite,<br>encrypted and open-source"; // XXX existing key
return [ return [
h('div#cp-main', [ h('div#cp-main', [
Pages.infopageTopbar(), Pages.infopageTopbar(),
@ -153,10 +167,12 @@ define([
]), ]),
h('div.col-md-5.cp-app-grid', [ h('div.col-md-5.cp-app-grid', [
icons, icons,
// XXX remove this commented code?
//more //more
]) ])
]), ]),
blocks, blocks,
// XXX remove this commented code?
/*h('div.row', [ /*h('div.row', [
h('div.cp-crowdfunding', [ h('div.cp-crowdfunding', [
crowdFunding crowdFunding

@ -21,6 +21,7 @@ body {
// Basic setup for info pages, this should be used at the global level // Basic setup for info pages, this should be used at the global level
background-color: @colortheme_info-background; background-color: @colortheme_info-background;
color: @cryptpad_text_col;
a { a {
color: @colortheme_logo-2; color: @colortheme_logo-2;
&:visited { color: darken(@colortheme_logo-2, 5%); } &:visited { color: darken(@colortheme_logo-2, 5%); }

@ -4,13 +4,7 @@
&.cp-page-index { &.cp-page-index {
.infopages_main(); .infopages_main();
@background_lighter: rgba(0,0,0,0.1);
@background_darker: rgba(0,0,0,0.4);
#cp-main { #cp-main {
color: #FFF;
background: @colortheme_info-background;
background-size: cover;
background-position: center;
min-height: 100vh; min-height: 100vh;
display: flex; display: flex;
flex-direction: column; flex-direction: column;
@ -200,45 +194,27 @@
} }
} }
} }
// XX not applied
.cp-index-block-help { #cp-main {
.cp-container {
.row.cp-index-section {
margin: 50px 0px;
.small-logo {
max-width: 40%;
}
button { button {
outline: none; outline: none;
background-color: @colortheme_logo-2; background-color: @colortheme_logo-2;
color: @colortheme_base; color: @colortheme_base;
border: none; border: none;
padding: 10px 20px; padding: 10px 20px;
border-radius: 44px; border-radius: 0px;
cursor: pointer; cursor: pointer;
&:hover { &:hover {
background-color: lighten(@colortheme_logo-2, 3%); background-color: lighten(@colortheme_logo-2, 3%);
} }
} }
} }
.cp-index-block {
min-height: 100%;
& > div {
background: rgba(0,0,0,0.5);
margin: 0 5px;
padding: 15px 10px;
height: 100%;
display: flex;
flex-flow: column;
justify-content: space-evenly;
}
.cp-img-container {
display: flex;
}
img, a.img {
margin: auto;
background: white;
&.agpl {
max-height: 50px;
}
&.ngi {
max-height: 100px;
}
} }
} }

Loading…
Cancel
Save