-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathgulpfile.js
145 lines (139 loc) · 6.24 KB
/
gulpfile.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
'use strict';
let gulp = require('gulp');
let pipeline = require('readable-stream').pipeline;
let header = require('gulp-header');
let rename = require('gulp-rename');
let sass = require('gulp-sass')(require('sass'));
let sourcemaps = require('gulp-sourcemaps');
let twig = require('gulp-twig');
gulp.task('sass', function () {
// TODO: Bring back sourcemap without breaking the pipeline.
return gulp.src('./scss/**/*.scss')
.pipe(header('$debug: true;\n'))
.pipe(sass({includePaths: ['node_modules'], outputStyle: 'expanded'}))
.pipe(gulp.dest('./demo'))
.pipe(header('$debug: false;\n'))
.pipe(sass({includePaths: ['node_modules'], outputStyle: 'compressed'}))
.pipe(rename({ basename: 'de2023', suffix: '.min' }))
.pipe(gulp.dest('./dist'));
});
gulp.task('twig', function () {
return gulp.src(['./templates/[^_]*.twig', '!templates'])
.pipe(twig({extname: false, data: {
link: {
a22b: "https://alexanderchristiaanjacob.com/",
deidee: "https://deidee.nl/",
facebook: 'https://www.facebook.com/deideecom',
linkedin: 'https://www.linkedin.com/company/deidee',
twitter: 'https://twitter.com/deideenl'
},
dejade: (function() {
let r = Math.round(127 * Math.random());
let g = Math.round(Math.random() * 128 + 127);
let b = Math.round(191 * Math.random());
return 'rgb(' + r + ', ' + g + ', ' + b + ')';
}),
heticoon: {
data: [
[0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0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0,0,0,1,0,0,0,0,0,0,0,0]],
size: 48,
random: 3
},
logos: [
'mimesia',
'allrgb',
'e-overheid',
'morerecoffee',
'dopewebsites',
'dova',
'sentrading',
'periodicsystem',
'nederland',
'internet',
'netplasticism',
'utterlyrandom',
'unst',
'deidee'
],
product_groups: [
{
title: 'Publiek',
description: 'Informatieve en/of commerciële producten die een eigen website hebben en door consumenten te gebruiken zijn.',
products: [
'delogo',
'detint',
'devlag',
'hetwachtwoord',
'demoji'
]
},
{
title: 'Opensource',
description: 'Producten die wij als opensourcepakket aanbieden zijn te vinden op GitHub. Hier is geen speciale toegang, maar wel technische kennis voor nodig.',
products: [
'deimage',
'hetpalet',
'hetthema',
'hetcanvas',
'dejade',
'dedate',
'detijd',
'desass',
'deflex',
'dehtml'
]
},
{
title: 'Intern',
description: 'Sommige producten gebruiken wij (vooralsnog) alleen intern. Deze staan op GitLab en kunnen door aangewezen personen worden benaderd.',
products: [
'decake',
'dedocumentatie'
]
}
],
products: {
delogo: {},
demoji: {},
hetwachtwoord: {}
},
nav: {
web: 'Web',
beeldmerken: 'beeldmerken',
diensten: 'diensten',
products: 'producten',
vragen: 'vragen',
clients: 'opdrachtgevers',
contact: 'contact'
},
client_logos: [
'vv',
'galeriehelder',
'dpi',
'soemo-fine-arts',
'thefashionweek'
]
}}))
.pipe(gulp.dest('demo'));
});
gulp.task('sass:watch', function () {
gulp.watch('./scss/**/*.scss', gulp.series('sass'));
});
gulp.task('default', gulp.series('sass', 'twig'));