Add mastodon and display admin email in the contact page

pull/1/head
yflory 6 years ago
parent e777ab362e
commit f9fc154979

@ -0,0 +1,4 @@
<svg xmlns="http://www.w3.org/2000/svg" width="61.076954mm" height="65.47831mm" viewBox="0 0 216.4144 232.00976">
<path fill="#2b90d9" d="M211.80734 139.0875c-3.18125 16.36625-28.4925 34.2775-57.5625 37.74875-15.15875 1.80875-30.08375 3.47125-45.99875 2.74125-26.0275-1.1925-46.565-6.2125-46.565-6.2125 0 2.53375.15625 4.94625.46875 7.2025 3.38375 25.68625 25.47 27.225 46.39125 27.9425 21.11625.7225 39.91875-5.20625 39.91875-5.20625l.8675 19.09s-14.77 7.93125-41.08125 9.39c-14.50875.7975-32.52375-.365-53.50625-5.91875C9.23234 213.82 1.40609 165.31125.20859 116.09125c-.365-14.61375-.14-28.39375-.14-39.91875 0-50.33 32.97625-65.0825 32.97625-65.0825C49.67234 3.45375 78.20359.2425 107.86484 0h.72875c29.66125.2425 58.21125 3.45375 74.8375 11.09 0 0 32.975 14.7525 32.975 65.0825 0 0 .41375 37.13375-4.59875 62.915"/>
<path fill="#fff" d="M177.50984 80.077v60.94125h-24.14375v-59.15c0-12.46875-5.24625-18.7975-15.74-18.7975-11.6025 0-17.4175 7.5075-17.4175 22.3525v32.37625H96.20734V85.42325c0-14.845-5.81625-22.3525-17.41875-22.3525-10.49375 0-15.74 6.32875-15.74 18.7975v59.15H38.90484V80.077c0-12.455 3.17125-22.3525 9.54125-29.675 6.56875-7.3225 15.17125-11.07625 25.85-11.07625 12.355 0 21.71125 4.74875 27.8975 14.2475l6.01375 10.08125 6.015-10.08125c6.185-9.49875 15.54125-14.2475 27.8975-14.2475 10.6775 0 19.28 3.75375 25.85 11.07625 6.36875 7.3225 9.54 17.22 9.54 29.675"/>
</svg>

After

Width:  |  Height:  |  Size: 1.4 KiB

@ -68,7 +68,7 @@ define([
languageSelector() languageSelector()
]) ])
], ''), ], ''),
footerCol('footer_applications', [ /*footerCol('footer_applications', [
footLink('/drive/', 'main_drive'), footLink('/drive/', 'main_drive'),
footLink('/pad/', 'main_richText'), footLink('/pad/', 'main_richText'),
footLink('/code/', 'main_code'), footLink('/code/', 'main_code'),
@ -76,19 +76,31 @@ define([
footLink('/poll/', 'main_poll'), footLink('/poll/', 'main_poll'),
footLink('/kanban/', 'main_kanban'), footLink('/kanban/', 'main_kanban'),
footLink('/whiteboard/', null, Msg.type.whiteboard) footLink('/whiteboard/', null, Msg.type.whiteboard)
]),*/
footerCol('footer_product', [
footLink('/faq.html', 'faq_link'),
footLink('https://github.com/xwiki-labs/cryptpad', null, 'GitHub'),
footLink('https://opencollective.com/cryptpad/contribute/', null, 'Donate'),
footLink('https://github.com/xwiki-labs/cryptpad', 'footer_install'),
]), ]),
footerCol('footer_aboutUs', [ footerCol('footer_aboutUs', [
footLink('https://blog.cryptpad.fr', 'blog'), /*footLink('https://blog.cryptpad.fr', 'blog'),
footLink('https://labs.xwiki.com', null, 'XWiki Labs'), footLink('https://labs.xwiki.com', null, 'XWiki Labs'),*/
footLink('http://www.xwiki.com', null, 'XWiki SAS'), footLink('http://www.xwiki.com', null, 'XWiki SAS'),
footLink('https://www.open-paas.org', null, 'OpenPaaS') footLink('https://www.open-paas.org', null, 'OpenPaaS'),
footLink('/about.html', 'footer_team'),
footLink('/contact.html', 'contact'),
]),
footerCol('footer_legal', [
footLink('/terms.html', 'footer_tos'),
footLink('/privacy.html', 'privacy'),
]), ]),
footerCol('footer_contact', [ /*footerCol('footer_contact', [
footLink('https://riot.im/app/#/room/#cryptpad:matrix.org', null, 'Chat'), footLink('https://riot.im/app/#/room/#cryptpad:matrix.org', null, 'Chat'),
footLink('https://twitter.com/cryptpad', null, 'Twitter'), footLink('https://twitter.com/cryptpad', null, 'Twitter'),
footLink('https://github.com/xwiki-labs/cryptpad', null, 'GitHub'), footLink('https://github.com/xwiki-labs/cryptpad', null, 'GitHub'),
footLink('/contact.html', null, 'Email') footLink('/contact.html', null, 'Email')
]) ])*/
]) ])
]), ]),
h('div.cp-version-footer', "CryptPad v2.19.0 (Tapir)") h('div.cp-version-footer', "CryptPad v2.19.0 (Tapir)")
@ -132,12 +144,12 @@ define([
button, button,
h('div.collapse.navbar-collapse.justify-content-end#menuCollapse', [ h('div.collapse.navbar-collapse.justify-content-end#menuCollapse', [
//h('a.nav-item.nav-link', { href: '/what-is-cryptpad.html'}, Msg.topbar_whatIsCryptpad), // Moved the FAQ //h('a.nav-item.nav-link', { href: '/what-is-cryptpad.html'}, Msg.topbar_whatIsCryptpad), // Moved the FAQ
h('a.nav-item.nav-link', { href: '/faq.html'}, Msg.faq_link), //h('a.nav-item.nav-link', { href: '/faq.html'}, Msg.faq_link),
h('a.nav-item.nav-link', { href: 'https://blog.cryptpad.fr/'}, Msg.blog), h('a.nav-item.nav-link', { href: 'https://blog.cryptpad.fr/'}, Msg.blog),
h('a.nav-item.nav-link', { href: '/features.html'}, Msg.features), h('a.nav-item.nav-link', { href: '/features.html'}, Msg.features),
h('a.nav-item.nav-link', { href: '/privacy.html'}, Msg.privacy), h('a.nav-item.nav-link', { href: '/privacy.html'}, Msg.privacy),
h('a.nav-item.nav-link', { href: '/contact.html'}, Msg.contact), //h('a.nav-item.nav-link', { href: '/contact.html'}, Msg.contact),
h('a.nav-item.nav-link', { href: '/about.html'}, Msg.about), //h('a.nav-item.nav-link', { href: '/about.html'}, Msg.about),
].concat(rightLinks)) ].concat(rightLinks))
); );
}; };

@ -1,8 +1,9 @@
define([ define([
'/api/config',
'/common/hyperscript.js', '/common/hyperscript.js',
'/customize/messages.js', '/customize/messages.js',
'/customize/pages.js' '/customize/pages.js'
], function (h, Msg, Pages) { ], function (Config, h, Msg, Pages) {
return function () { return function () {
return h('div#cp-main', [ return h('div#cp-main', [
Pages.infopageTopbar(), Pages.infopageTopbar(),
@ -12,35 +13,72 @@ define([
) )
]), ]),
h('div.container.cp-container', [ h('div.container.cp-container', [
Config.adminEmail !== 'i.did.not.read.my.config@cryptpad.fr' ? h('div.row.cp-iconCont.align-items-center', [
h('div.col-12',
Pages.setHTML(h('h4.text-center'), Msg.contact_admin)
),
h('div.col-12.col-sm-6.col-md-3.col-lg-3',
h('a.card', {href : "mailto:"+Config.adminEmail},
h('div.card-body',
h('p', [
h('img', {src: '/customize/images/email.svg'}),
Msg.contact_email || 'Email'
])
)
)
),
]) : undefined,
h('div.row.cp-iconCont.align-items-center', [ h('div.row.cp-iconCont.align-items-center', [
h('div.col-12', h('div.col-12',
Pages.setHTML(h('h4.text-center'), Msg.main_about_p26) Pages.setHTML(h('h4.text-center'), Msg.contact_dev)
), ),
h('div.col-12.col-sm-6.col-md-3.col-lg-3', h('div.col-12.col-sm-6.col-md-3.col-lg-3',
h('a.card', {href : "https://twitter.com/cryptpad"}, h('a.card', {href : "https://twitter.com/cryptpad"},
h('div.card-body', h('div.card-body',
Pages.setHTML(h('p'), Msg.main_about_p22) h('p', [
h('img', {src: '/customize/images/twitter.svg'}),
Msg.contact_devTwitter || 'Twitter'
])
)
)
),
h('div.col-12.col-sm-6.col-md-3.col-lg-3',
h('a.card', {href : "https://social.weho.st/@cryptpad"},
h('div.card-body',
h('p', [
h('img', {src: '/customize/images/mastodon.svg'}),
Msg.contact_devMastodon || 'Mastodon'
])
) )
) )
), ),
h('div.col-12.col-sm-6.col-md-3.col-lg-3', h('div.col-12.col-sm-6.col-md-3.col-lg-3',
h('a.card', {href : "https://github.com/xwiki-labs/cryptpad/issues/"}, h('a.card', {href : "https://github.com/xwiki-labs/cryptpad/issues/"},
h('div.card-body', h('div.card-body',
Pages.setHTML(h('p'), Msg.main_about_p23) h('p', [
h('img', {src: '/customize/images/issue.svg'}),
Msg.contact_devBug || 'Bug report'
])
) )
) )
), ),
h('div.col-12.col-sm-6.col-md-3.col-lg-3', h('div.col-12.col-sm-6.col-md-3.col-lg-3',
h('a.card', {href : "https://riot.im/app/#/room/#cryptpad:matrix.org"}, h('a.card', {href : "https://riot.im/app/#/room/#cryptpad:matrix.org"},
h('div.card-body', h('div.card-body',
Pages.setHTML(h('p'), Msg.main_about_p24) h('p', [
h('img', {src: '/customize/images/sayhi.svg'}),
Msg.contact_devChat || 'Chat'
])
) )
) )
), ),
h('div.col-12.col-sm-6.col-md-3.col-lg-3', h('div.col-12.col-sm-6.col-md-3.col-lg-3',
h('a.card', {href : "mailto:research@xwiki.com"}, h('a.card', {href : "mailto:contact@cryptpad.fr"},
h('div.card-body', h('div.card-body',
Pages.setHTML(h('p'), Msg.main_about_p25) h('p', [
h('img', {src: '/customize/images/email.svg'}),
Msg.contact_email || 'Email'
])
) )
) )
), ),

@ -19,10 +19,8 @@
} }
div { div {
.card { .card {
padding: 4em 1em 0.5em 1em;
box-shadow: 0 5px 15px rgba(69,145,196, 0.3); box-shadow: 0 5px 15px rgba(69,145,196, 0.3);
border-color: #fff; border-color: #fff;
text-align: center;
margin-bottom: 1em; margin-bottom: 1em;
&:hover, &:focus { &:hover, &:focus {
text-decoration: none; text-decoration: none;
@ -40,37 +38,17 @@
@media (max-width: 335px) { @media (max-width: 335px) {
min-height: 162px; min-height: 162px;
} }
} img {
&:nth-child(2) { max-width: 50px;
.card { margin-bottom: 10px;
background-image: url(/customize/images/twitter.svg);
background-repeat: no-repeat;
background-position: 50% 10%;
background-size: 3rem;
}
}
&:nth-child(3) {
.card {
background-image: url(/customize/images/issue.svg);
background-repeat: no-repeat;
background-position: 50% 10%;
background-size: 3rem;
} }
} p {
&:nth-child(4) { display: flex;
.card { flex-flow: column;
background-image: url(/customize/images/sayhi.svg); justify-content: center;
background-repeat: no-repeat; align-items: center;
background-position: 50% 10%; margin: 0;
background-size: 3rem; height: 100%;
}
}
&:nth-child(5) {
.card {
background-image: url(/customize/images/email.svg);
background-repeat: no-repeat;
background-position: 50% 10%;
background-size: 3rem;
} }
} }
} }

@ -18,6 +18,11 @@ try {
console.log("You can customize the configuration by copying config/config.example.js to config/config.js"); console.log("You can customize the configuration by copying config/config.example.js to config/config.js");
config = require('./config/config.example'); config = require('./config/config.example');
} }
if (config.adminEmail === 'i.did.not.read.my.config@cryptpad.fr') {
console.log("You can configure the administrator email (adminEmail) in your config/config.js file");
}
var websocketPort = config.websocketPort || config.httpPort; var websocketPort = config.websocketPort || config.httpPort;
var useSecureWebsockets = config.useSecureWebsockets || false; var useSecureWebsockets = config.useSecureWebsockets || false;

Loading…
Cancel
Save