Commit 183da668 authored by cynddl's avatar cynddl

Improve pipeline for static assets (yarn+webpack+postcss) 😇

parent 7426dcc9
{
"name": "lqdn-rp",
"version": "0.1.0",
"description": "Revue de presse de La Quadrature du Net",
"main": "index.js",
"repository": "gitlab@git.laquadrature.net:la-quadrature-du-net/rpteam/rp.git",
"author": "Luc Rocher <luc@rocher.lc>",
"license": "MIT",
"dependencies": {
"bootstrap": "4.0.0-alpha.6",
"font-awesome": "^4.7.0",
"postcss-font-magician": "^1.6.1"
},
"devDependencies": {
"css-loader": "^0.28.0",
"extract-text-webpack-plugin": "beta",
"file-loader": "^0.11.1",
"node-sass": "^4.5.2",
"postcss": "^5.2.17",
"postcss-cssnext": "^2.10.0",
"postcss-import": "^9.1.0",
"postcss-loader": "^1.3.3",
"url-loader": "^0.5.8",
"webpack": "^2.4.1",
"webpack-dev-server": "2"
}
}
module.exports = {
plugins: {
'postcss-import': {},
'postcss-cssnext': {
browsers: ['last 2 versions', '> 5%'],
},
},
};
......@@ -14,6 +14,7 @@ STATIC_ROOT = os.path.join(BASE_DIR, "static", "static_root")
# by collectstatic
STATICFILES_DIRS = (
os.path.join(BASE_DIR, "static", "build"),
os.path.join(BASE_DIR, "static", "dist"),
)
MEDIA_URL = "/media/"
......
This diff is collapsed.
This diff is collapsed.
* {
font-family: FiraSansRegular;
font-size: 16px;
}
h1, h2 {
font-family: SansusWebissimoRegular;
}
h1 {
font-size: 42px;
}
h2 {
font-size: 35px;
}
h3 {
font-size: 18px;
font-family: FiraSansMedium;
}
@media only screen and (min-width: 768px) {
section.container-fluid {
padding-left: 10%;
padding-right: 10%;
}
section:last-of-type {
padding-bottom: 90px;
}
.container-fluid .navbar-header {
margin-left: 10%;
}
}
.text-center {
margin-top: 0;
margin-bottom: O;
}
.page-header {
border: none;
margin-top: 8px;
margin-bottom: 8px;
}
.page-header hr {
border-color: #ccd3dd;
}
.page-header h1 span {
text-transform: uppercase;
}
.page-header h2 span,
.page-header h1 span {
font-family: inherit;
font-size: inherit;
}
.strike-through h2,
.strike-through h1 {
overflow: hidden;
margin-bottom: 28px;
margin-top: 28px;
}
.strike-through h2 span,
.strike-through h1 span {
position: relative;
}
.strike-through h2 span:before,
.strike-through h2 span:after,
.strike-through h1 span:before,
.strike-through h1 span:after {
content: "";
position: absolute;
border-bottom: 1px solid #497ed5;
width: 600px;
height: 8px;
top: 50%;
margin-top: -10px;
}
.light-blue .strike-through h2 span:before,
.light-blue .strike-through h2 span:after,
.light-blue .strike-through h1 span:before,
.light-blue .strike-through h1 span:after {
border-color: #2f5188;
}
.strike-through h2 span:before,
.strike-through h1 span:before {
right: 100%;
margin-right: 15px;
}
.strike-through h2 span:after,
.strike-through h1 span:after {
left: 100%;
margin-left: 15px;
}
.navbar-default {
background-color: white;
color: #3b68b0;
margin-bottom: 0px;
min-height: 35px;
border: none;
border-radius: 0px;
}
.navbar-default .navbar-nav > li > a {
color: #3b68b0;
font-size: 18px;
font-family: FiraSansBook;
}
.navbar-default:not(#up-bar) .navbar-nav > li > a.on,
.navbar-default:not(#up-bar) .navbar-nav > li > a:hover {
color: #3b68b0;
font-family: FiraSansMedium;
font-size: 18px;
}
section {
padding-bottom: 24px;
padding-top: 24px;
}
.dark-blue, .dark-blue .navbar-nav > li > a {
background-color: #2f5188;
color: #ffffff;
}
nav.dark-blue {
/*padding-right: 5%;*/
}
#up-bar, #up-bar > .navbar-nav, #up-bar > .navbar-nav > li, #up-bar > .navbar-nav > li > a {
height: 38px;
}
#up-bar > .navbar-nav > li > a {
padding-top: 7px;
padding-bottom: 7px;
}
.navbar-brand {
padding: 0;
z-index: 1000;
position: absolute;
}
.dark-blue .navbar-nav > li > a,
.navbar-nav.blue > li > a {
font-weight: bold;
font-size: 13px;
}
.dark-blue .navbar-nav > li > a:hover,
.navbar-nav.blue > li > a:hover {
color: #ffffff;
}
.dark-blue .navbar-nav > li > a:hover {
font-size: 13px;
}
.navbar-nav.blue > li > a:hover {
font-size: 18px;
}
.blue {
background-color: #3b68b0;
color: #ffffff;
}
.navbar-nav.blue > li > a {
background-color: #3b68b0;
color: #ffffff;
font-size: 18px;
padding-left: 5px;
padding-right: 5px;
}
.light-blue {
background-color: #497ed5;
color: #ffffff;
}
@media only screen and (min-width: 768px) {
.white {
background-repeat: no-repeat;
background-position: bottom left, bottom right, bottom, top left, top right;
background-color: #ebf3ff;
color: #3b68b0;
background-size: 25%, 25%, 100% 26px, 30%, 30%;
}
}
@media only screen and (max-width: 767px) {
.white {
background-image: linear-gradient(white 0px, #497ed5 0px), url('/static/img/left.png'), url('/static/img/right.png');
background-repeat: no-repeat;
background-position: bottom, top left, top right;
background-color: #ebf3ff;
color: #3b68b0;
background-size: 100% 26px, 30%, 30%;
}
}
.white {
padding-bottom: 52px;
}
.sky-blue {
background-color: #dde5f1;
color: #3b68b0;
}
.white-pure {
background-color: #ffffff;
color: #3b68b0;
padding: 34px;
}
.nav-white, .nav-white .navbar-nav > li > a {
background-color: #ffffff;
color: #3b68b0;
}
.btn {
border-radius: 0px;
padding-left: 38px;
padding-right: 38px;
font-family: FiraSansRegular;
}
.btn-lg {
font-size: 20px;
height: 60px;
line-height: 25px;
padding-top: 15px;
}
.btn em {
font-size: 28px;
font-family: SansusWebissimoRegular;
}
.btn-default,
.btn-default:hover {
color: #2f5188;
background-color: #ffffff;
}
.btn-icon {
padding-left: 15px;
}
.btn-icon:after {
vertical-align: top;
}
.btn-modal .btn-icon-right:after,
.dark-blue .btn-icon-right:after,
.blue .btn-icon-right:after,
.light-blue .btn-icon-right:after {
content: url('/static/img/arrow_right-white.png');
}
.btn-accordions .btn-icon-right:after {
content: url('/static/img/arrow_right_lightblue.png');
}
.btn-accordions:hover .btn-icon-right:after {
content: url('/static/img/arrow_right-white.png');
}
.btn-bottom .btn-icon-top:after {
content: url('/static/img/arrow_up_darkblue.png');
vertical-align: bottom;
}
.btn-bottom .btn-icon-pig:after {
content: url('/static/img/cochon-01.png');
vertical-align: top;
position: relative;
top: -5px;
}
.btn-lg .btn-icon {
max-height: 60px;
max-width: 60px;
line-height: 25px;
}
.pull-right.btn-default .btn-icon {
padding-left: 0px;
padding-right: 15px;
}
.btn-modal {
color: #ffffff;
background-color: #497ed5;
}
.btn-modal:hover {
color: #ffffff;
}
.btn-accordions {
background-color: #DDE5F1;
color: #497ED5 !important;
border: solid 2px #497ED5;
}
.btn-accordions:hover {
background-color: #3B68B0;
color: #DDE5F1 !important;
border: solid 2px #497ED5;
}
.light-blue .btn-default {
color: #ffffff;
background-color: #497ed5;
border: solid 2px #3b68b0;
}
.light-blue .btn-default:hover {
color: #ffffff;
background-color: #3b68b0;
border: solid 2px #3b68b0;
}
.blue .btn-default {
color: #ffffff;
background-color: #3b68b0;
border: solid 2px #2f5188;
}
.blue .btn-default:hover {
color: #ffffff;
background-color: #2f5188;
border: solid 2px #2f5188;
}
.dark-blue .btn-default {
color: #ffffff;
background-color: #2f5188;
border: solid 2px #497ed5;
}
.dark-blue .btn-default:hover {
color: #ffffff;
background-color: #497ed5;
border: solid 2px #497ed5;
}
.media-object {
float: left;
}
#progress-bar {
margin-bottom: 15px;
max-height: 96px;
}
#progress-bar > div {
background-color: #dde5f1;
padding: 8px;
}
#video {
padding: 0px;
padding-right: 15px;
}
#video video {
width: 100%;
}
#donation {
background-color: #fff;
padding: 23px;
}
#contreparties {
font-size: 15px;
}
#contreparties .well {
padding: 20px;
}
#contreparties > div {
margin-top: 0px;
}
#contreparties img {
width: 70px;
height: 70px;
margin-right: 12px;
}
#contreparties img:first-of-type {
margin-left: 25px;
}
#contreparties h3 {
font-size: 22px;
font-family: FiraSansSemiBold;
overflow: visible;
white-space: nowrap;
}
#contreparties .well + div {
padding: 0px;
}
.img-list > div {
padding: 0px;
}
.img-list .media-body {
vertical-align: middle;
height: 70px;
}
.img-list small {
font-size: 11px;
}
section {
margin: 0px !important;
}
em {
font-style: normal;
font-weight: bold;
font-family: FiraSansSemiBold;
font-size: 18px;
}
.text-block > div:last-child {
margin-bottom: 60px;
}
.row-img img {
width: 200px;
height: 200px;
}
.row-img > div > div {
width: 200px;
height: 200px;
margin-left: auto;
margin-right: auto;
}
.btn-bottom {
position: relative;
margin-top: -60px;
top: 0px;
width: 100%;
height: 0px;
}
p.avant {
color: #3B68B0;
font-family: FiraSansRegular;
width: 85%;
}
p.apres {
color: #3B68B0;
font-family: FiraSansRegular;
width: 85%;
}
h4 {
font-family: FiraSansSemiBold;
font-size: 22px;
margin-top: 20px;
margin-bottom: 20px;
}
.list-questions a {
font-size: 24px;
}
.panel-default {
border-radius: 0px;
padding: 0px !important;
border: none;
}
.panel-default .panel-body {
background-color: #dde5f1;
color: #3B68B0;
padding: 34px;
}
.panel-default .panel-body.white-pure {
background-color: #ffffff;
color: #3B68B0;
}
.panel-body {
height: 100%;
}
.panel-body > div {
vertical-align: middle;
display: inline-block;
}
.panel-default .panel-footer {
background-color: #dde5f1;
border: none;
border-radius: 0px;
padding: 0px 50px 34px;
}
.panel-default .panel-heading,
.panel-default label.panel-heading {
color: #fff;
background-color: #3B68B0;
display: block;
font-family: FiraSansRegular;
font-size: 18px;
line-height: 50px;
width: 100%;
border-radius: 0;
border: none;
}
.panel-default > .panel-heading label {
font-size: 18px;
display: block;
padding: 0 25px;
}
.merci {
border-bottom: 1px solid #3B68B0 ;
}
.input {
width : 100%;
background-color: white;
}
.subtitle {
font-weight: bold;
font-family: FiraSansBook;
color: #2f5188;
}
.relayer {
margin-bottom: 30px;
}
textarea.form-control.bold {
font-size: 20px;
}
.well, .well-lg, .well-sm {
border-radius: 0px;
box-shadow: none;
border: 0px;
}
.well {
padding: 34px;