cronus-theme 2.0.89 → 2.0.90

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (240) hide show
  1. package/Gulpfile.js +4 -3
  2. package/README.md +1 -12
  3. package/default/b2b.yaml +2 -1
  4. package/default/b2c.yaml +2 -1
  5. package/default/catalog.yaml +2 -1
  6. package/default/login.yaml +2 -1
  7. package/default/templates/emails/basicmail/basicmail.mustache +2 -2
  8. package/default/templates/emails/basicmail/basicmailFooter.mustache +1 -1
  9. package/default/templates/emails/basicmail/basicmailHeader.mustache +1 -1
  10. package/default/templates/emails/footerText.mustache +12 -12
  11. package/default/templates/emails/ordermail/orderLines.mustache +5 -5
  12. package/default/templates/emails/ordermail/ordermail.mustache +1 -1
  13. package/default/templates/emails/ordermail/ordermailDcOrder.mustache +1 -1
  14. package/default/templates/emails/ordermail/ordermailDetails.mustache +17 -17
  15. package/default/templates/emails/ordermail/ordermailFooter.mustache +1 -1
  16. package/default/templates/emails/ordermail/ordermailHeader.mustache +5 -5
  17. package/default/templates/emails/ordermail/ordermailIntro.mustache +1 -1
  18. package/default/templates/emails/ordermail/ordermailIntroText.mustache +1 -1
  19. package/default/templates/emails/ordermail/ordermailItem.mustache +1 -1
  20. package/default/templates/emails/ordermail/ordermailItemHeadline.mustache +1 -1
  21. package/default/templates/emails/ordermail/ordermailItemList.mustache +1 -1
  22. package/default/templates/shop/item_statistics_account.mustache +1 -1
  23. package/default/website.yaml +2 -1
  24. package/package.json +1 -1
  25. package/child/404_de.html +0 -32
  26. package/child/404_en.html +0 -32
  27. package/child/Gulpfile.js +0 -463
  28. package/child/build/doc/doc.css +0 -21873
  29. package/child/build/favicons/android-chrome-192x192.png +0 -0
  30. package/child/build/favicons/android-chrome-512x512.png +0 -0
  31. package/child/build/favicons/apple-touch-icon.png +0 -0
  32. package/child/build/favicons/browserconfig.xml +0 -9
  33. package/child/build/favicons/favicon-16x16.png +0 -0
  34. package/child/build/favicons/favicon-32x32.png +0 -0
  35. package/child/build/favicons/favicon.ico +0 -0
  36. package/child/build/favicons/faviconData.json +0 -1
  37. package/child/build/favicons/mstile-144x144.png +0 -0
  38. package/child/build/favicons/mstile-150x150.png +0 -0
  39. package/child/build/favicons/mstile-310x150.png +0 -0
  40. package/child/build/favicons/mstile-310x310.png +0 -0
  41. package/child/build/favicons/mstile-70x70.png +0 -0
  42. package/child/build/favicons/safari-pinned-tab.svg +0 -36
  43. package/child/build/favicons/site.webmanifest +0 -19
  44. package/child/child.yaml +0 -137
  45. package/child/ck_styles.js +0 -90
  46. package/child/config.json +0 -37
  47. package/child/dist/css/addons/errorPages.css +0 -1
  48. package/child/dist/css/addons/fck.css +0 -1
  49. package/child/dist/css/addons/kss.css +0 -1
  50. package/child/dist/css/child.css +0 -1
  51. package/child/dist/css/child1734010270.css +0 -1
  52. package/child/dist/css/doc.css +0 -1
  53. package/child/dist/css/doc1734010270.css +0 -1
  54. package/child/dist/favicons/android-chrome-192x192.png +0 -0
  55. package/child/dist/favicons/android-chrome-512x512.png +0 -0
  56. package/child/dist/favicons/apple-touch-icon.png +0 -0
  57. package/child/dist/favicons/browserconfig.xml +0 -9
  58. package/child/dist/favicons/favicon-16x16.png +0 -0
  59. package/child/dist/favicons/favicon-32x32.png +0 -0
  60. package/child/dist/favicons/favicon.ico +0 -0
  61. package/child/dist/favicons/faviconData.json +0 -1
  62. package/child/dist/favicons/mstile-144x144.png +0 -0
  63. package/child/dist/favicons/mstile-150x150.png +0 -0
  64. package/child/dist/favicons/mstile-310x150.png +0 -0
  65. package/child/dist/favicons/mstile-310x310.png +0 -0
  66. package/child/dist/favicons/mstile-70x70.png +0 -0
  67. package/child/dist/favicons/safari-pinned-tab.svg +0 -36
  68. package/child/dist/favicons/site.webmanifest +0 -19
  69. package/child/dist/fonts/barlow-600.woff +0 -0
  70. package/child/dist/fonts/barlow-600.woff2 +0 -0
  71. package/child/dist/fonts/barlow-700.woff +0 -0
  72. package/child/dist/fonts/barlow-700.woff2 +0 -0
  73. package/child/dist/fonts/barlow-regular.woff +0 -0
  74. package/child/dist/fonts/barlow-regular.woff2 +0 -0
  75. package/child/dist/fonts/icons1689843011.woff +0 -0
  76. package/child/dist/fonts/icons1689843011.woff2 +0 -0
  77. package/child/dist/fonts/icons1689843343.woff +0 -0
  78. package/child/dist/fonts/icons1689843343.woff2 +0 -0
  79. package/child/dist/fonts/icons1734010270.woff +0 -0
  80. package/child/dist/fonts/icons1734010270.woff2 +0 -0
  81. package/child/dist/js/child.js +0 -2
  82. package/child/dist/js/child.js.map +0 -7
  83. package/child/dist/js/child1734010270.js +0 -2
  84. package/child/dist/snippets/css/child.html +0 -1
  85. package/child/dist/snippets/css/doc.html +0 -1
  86. package/child/dist/snippets/faviconmarkup.html +0 -9
  87. package/child/dist/snippets/iconfont.html +0 -1
  88. package/child/dist/snippets/js/child.html +0 -1
  89. package/child/frontend.php +0 -266
  90. package/child/homepage.md +0 -1
  91. package/child/kss-config.json +0 -17
  92. package/child/package.json +0 -65
  93. package/child/sample.jpg +0 -0
  94. package/child/src/favicon/favicon.svg +0 -1
  95. package/child/src/fonts/barlow-600.woff +0 -0
  96. package/child/src/fonts/barlow-600.woff2 +0 -0
  97. package/child/src/fonts/barlow-700.woff +0 -0
  98. package/child/src/fonts/barlow-700.woff2 +0 -0
  99. package/child/src/fonts/barlow-regular.woff +0 -0
  100. package/child/src/fonts/barlow-regular.woff2 +0 -0
  101. package/child/src/fonts/icons1689843011.woff +0 -0
  102. package/child/src/fonts/icons1689843011.woff2 +0 -0
  103. package/child/src/fonts/icons1689843343.woff +0 -0
  104. package/child/src/fonts/icons1689843343.woff2 +0 -0
  105. package/child/src/icons/icons1734010270.woff +0 -0
  106. package/child/src/icons/icons1734010270.woff2 +0 -0
  107. package/child/src/js/child.js +0 -0
  108. package/child/src/scss/_print.scss +0 -5
  109. package/child/src/scss/addons/errorPages.scss +0 -109
  110. package/child/src/scss/addons/fck.scss +0 -6
  111. package/child/src/scss/addons/kss.scss +0 -108
  112. package/child/src/scss/base/_fonts.scss +0 -27
  113. package/child/src/scss/base/_icons.scss +0 -968
  114. package/child/src/scss/base/_variables.scss +0 -0
  115. package/child/src/scss/child.scss +0 -11
  116. package/child/src/scss/doc.scss +0 -2
  117. package/child/src/scss/mixins/_breakpoints.scss +0 -127
  118. package/child/src/scss/mixins/_functions.scss +0 -273
  119. package/child/src/scss/mixins/_grid.scss +0 -85
  120. package/child/src/scss/mixins/_mixins.scss +0 -3
  121. package/child/src/scss/template/_icons.scss +0 -33
  122. package/child/src/snippets/faviconmarkup.html +0 -0
  123. package/child/src/snippets/includeCSS.html +0 -1
  124. package/child/src/snippets/includeFont.html +0 -1
  125. package/child/src/snippets/includeJS.html +0 -1
  126. package/child/styleguide/index.html +0 -119
  127. package/child/styleguide/item-base-button-link.html +0 -191
  128. package/child/styleguide/item-base-buttons.html +0 -244
  129. package/child/styleguide/item-base-fake-tables.html +0 -221
  130. package/child/styleguide/item-base-icons.html +0 -290
  131. package/child/styleguide/item-base-lists.html +0 -216
  132. package/child/styleguide/item-base-tables.html +0 -221
  133. package/child/styleguide/item-base-tags-group.html +0 -209
  134. package/child/styleguide/item-base-tags.html +0 -224
  135. package/child/styleguide/item-base.html +0 -171
  136. package/child/styleguide/item-colors-background.html +0 -305
  137. package/child/styleguide/item-colors-border.html +0 -263
  138. package/child/styleguide/item-colors-font.html +0 -304
  139. package/child/styleguide/item-colors.html +0 -159
  140. package/child/styleguide/item-components-action-icon.html +0 -244
  141. package/child/styleguide/item-components-actionbox.html +0 -195
  142. package/child/styleguide/item-components-alerts.html +0 -244
  143. package/child/styleguide/item-components-breadcrumb.html +0 -209
  144. package/child/styleguide/item-components-custom-select.html +0 -588
  145. package/child/styleguide/item-components-filegallery.html +0 -223
  146. package/child/styleguide/item-components-iconbar.html +0 -378
  147. package/child/styleguide/item-components-iconbox.html +0 -197
  148. package/child/styleguide/item-components-iconlist.html +0 -205
  149. package/child/styleguide/item-components-modals.html +0 -319
  150. package/child/styleguide/item-components-pagination.html +0 -215
  151. package/child/styleguide/item-components-processbar.html +0 -225
  152. package/child/styleguide/item-components-radio-list.html +0 -297
  153. package/child/styleguide/item-components-rating.html +0 -213
  154. package/child/styleguide/item-components-scrollbar.html +0 -327
  155. package/child/styleguide/item-components-searchbar.html +0 -204
  156. package/child/styleguide/item-components-share-links.html +0 -209
  157. package/child/styleguide/item-components-tags-group.html +0 -209
  158. package/child/styleguide/item-components-tags.html +0 -254
  159. package/child/styleguide/item-components-trust-infobar.html +0 -205
  160. package/child/styleguide/item-components-trustbar.html +0 -213
  161. package/child/styleguide/item-components-trustlist.html +0 -211
  162. package/child/styleguide/item-components.html +0 -261
  163. package/child/styleguide/item-form-checkboxes-switch.html +0 -195
  164. package/child/styleguide/item-form-checkboxes.html +0 -195
  165. package/child/styleguide/item-form-file-input.html +0 -252
  166. package/child/styleguide/item-form-infield-input-groups.html +0 -215
  167. package/child/styleguide/item-form-input-groups-addons.html +0 -286
  168. package/child/styleguide/item-form-input-groups.html +0 -210
  169. package/child/styleguide/item-form-inputs.html +0 -398
  170. package/child/styleguide/item-form-label-left-input-groups.html +0 -201
  171. package/child/styleguide/item-form-radioboxes-switch.html +0 -211
  172. package/child/styleguide/item-form.html +0 -189
  173. package/child/styleguide/item-navigations-mainnav.html +0 -239
  174. package/child/styleguide/item-navigations-nav.html +0 -215
  175. package/child/styleguide/item-navigations-navgroup.html +0 -538
  176. package/child/styleguide/item-navigations-subnav.html +0 -295
  177. package/child/styleguide/item-navigations-toggle-navigation.html +0 -216
  178. package/child/styleguide/item-navigations.html +0 -171
  179. package/child/styleguide/item-shop-accountbox.html +0 -318
  180. package/child/styleguide/item-shop-amount-lines.html +0 -243
  181. package/child/styleguide/item-shop-attributes-icons.html +0 -205
  182. package/child/styleguide/item-shop-categorybox.html +0 -227
  183. package/child/styleguide/item-shop-categorylist-itempreview.html +0 -247
  184. package/child/styleguide/item-shop-categorylist.html +0 -257
  185. package/child/styleguide/item-shop-checkout-buttons.html +0 -205
  186. package/child/styleguide/item-shop-filter.html +0 -707
  187. package/child/styleguide/item-shop-history-list-item.html +0 -213
  188. package/child/styleguide/item-shop-inventory.html +0 -300
  189. package/child/styleguide/item-shop-list-type-switch.html +0 -207
  190. package/child/styleguide/item-shop-order-history-list.html +0 -254
  191. package/child/styleguide/item-shop-orderboxsummary.html +0 -267
  192. package/child/styleguide/item-shop-orderbutton.html +0 -297
  193. package/child/styleguide/item-shop-orderitemlist.html +0 -263
  194. package/child/styleguide/item-shop-prices-list-graduated.html +0 -247
  195. package/child/styleguide/item-shop-prices-list.html +0 -217
  196. package/child/styleguide/item-shop-prices.html +0 -199
  197. package/child/styleguide/item-shop-promotions.html +0 -201
  198. package/child/styleguide/item-shop-quantity-spinner.html +0 -366
  199. package/child/styleguide/item-shop-sorting.html +0 -271
  200. package/child/styleguide/item-shop-state.html +0 -279
  201. package/child/styleguide/item-shop-variantselection.html +0 -199
  202. package/child/styleguide/item-shop.html +0 -243
  203. package/child/styleguide/item-siteparts-filegallery.html +0 -223
  204. package/child/styleguide/item-siteparts-scrollbar.html +0 -294
  205. package/child/styleguide/item-siteparts-slidecontent.html +0 -217
  206. package/child/styleguide/item-siteparts.html +0 -159
  207. package/child/styleguide/item-structure-containers.html +0 -234
  208. package/child/styleguide/item-structure-grid.html +0 -373
  209. package/child/styleguide/item-structure-margins.html +0 -307
  210. package/child/styleguide/item-structure-paddings.html +0 -307
  211. package/child/styleguide/item-structure.html +0 -165
  212. package/child/styleguide/item-typo-alignment-transform.html +0 -274
  213. package/child/styleguide/item-typo-headlines.html +0 -225
  214. package/child/styleguide/item-typo-link-with-icon.html +0 -254
  215. package/child/styleguide/item-typo-links.html +0 -224
  216. package/child/styleguide/item-typo-text.html +0 -214
  217. package/child/styleguide/item-typo.html +0 -165
  218. package/child/styleguide/kss-assets/WARNING.txt +0 -2
  219. package/child/styleguide/kss-assets/github-fork--black.png +0 -0
  220. package/child/styleguide/kss-assets/kss-fullscreen.js +0 -60
  221. package/child/styleguide/kss-assets/kss-guides.js +0 -27
  222. package/child/styleguide/kss-assets/kss-markup.js +0 -42
  223. package/child/styleguide/kss-assets/kss.css +0 -1
  224. package/child/styleguide/kss-assets/kss.js +0 -53
  225. package/child/styleguide/kss-assets/kss.scss +0 -746
  226. package/child/styleguide/kss-assets/noise-low.png +0 -0
  227. package/child/styleguide/kss-assets/sample-inline.png +0 -0
  228. package/child/styleguide/kss-assets/sample-inline.svg +0 -3
  229. package/child/styleguide/kss-assets/sample.png +0 -0
  230. package/child/styleguide/kss-assets/sample.svg +0 -3
  231. package/child/styleguide/kss-assets/scrollspy.js +0 -147
  232. package/child/styleguide/section-base.html +0 -784
  233. package/child/styleguide/section-colors.html +0 -743
  234. package/child/styleguide/section-components.html +0 -3375
  235. package/child/styleguide/section-form.html +0 -1383
  236. package/child/styleguide/section-navigations.html +0 -1194
  237. package/child/styleguide/section-shop.html +0 -3333
  238. package/child/styleguide/section-siteparts.html +0 -605
  239. package/child/styleguide/section-structure.html +0 -1002
  240. package/child/styleguide/section-typo.html +0 -698
package/child/Gulpfile.js DELETED
@@ -1,463 +0,0 @@
1
- const yargs = require('yargs');
2
- const shopconfig = require('./config.json');
3
- let type = shopconfig.type;
4
-
5
- const argv = yargs
6
- .option('print-config', {
7
- alias: 'p',
8
- description: 'print config comment with config keys and exit',
9
- type: 'boolean',
10
- default: false
11
- })
12
- .option('type', {
13
- alias: 't',
14
- description: 'Set type to use',
15
- type: 'string'
16
- })
17
- .option('layoutcode', {
18
- alias: 'l',
19
- description: 'Set layoutcode to use',
20
- type: 'string'
21
- })
22
- .argv;
23
-
24
- if (typeof argv.type !== 'undefined') {
25
- type = argv.type;
26
- }
27
-
28
- if (argv['print-config']) {
29
- console.log(shopconfig.__comment);
30
- process.exit(0);
31
- }
32
-
33
- const config = shopconfig;
34
-
35
- const layoutcode = config.layout.code;
36
- const layoutpath = "/layout/frontend/" + layoutcode + "/";
37
- let srcdir = config.layout.src;
38
- let builddir = config.layout.build;
39
- let distdir = config.layout.dist;
40
- const iconfontName = config.icons.name;
41
- const favicon = config.favicon;
42
- const browserSyncOptions = shopconfig.browsersync;
43
- const faviconColor = favicon.color.toLowerCase();
44
- const faviconBackground = favicon.background.toLowerCase();
45
- const timestamp = Math.round(Date.now() / 1000).toString();
46
-
47
- let nameIconfont = iconfontName;
48
- let browserSyncProxy = browserSyncOptions.proxy;
49
-
50
- if(config.browserSyncProxy && config.browserSyncProxy !== ""){
51
- browserSyncProxy = config.browserSyncProxy;
52
- }
53
-
54
- console.log("layoutcode: " + config.layout.code);
55
- console.log("timestamp: " + timestamp);
56
- console.log("srcdir: " + srcdir);
57
- console.log("builddir: " + builddir);
58
- console.log("distdir: " + distdir);
59
- console.log("proxy: " + browserSyncProxy);
60
-
61
- const gulp = require('gulp');
62
- const sass = require('gulp-dart-sass');
63
- const sourcemaps = require('gulp-sourcemaps');
64
- const clean = require('gulp-clean');
65
- const iconfont = require('gulp-iconfont');
66
- const iconfontCss = require('gulp-iconfont-css');
67
- const minifyCSS = require('dc-gulp-clean-css');
68
- const realFavicon = require('gulp-real-favicon');
69
- const fs = require('fs');
70
- const autoprefixer = require('gulp-autoprefixer');
71
- const replace = require('gulp-replace');
72
- const git = require('gulp-git');
73
- const gulpEsbuild = require("gulp-esbuild");
74
- const rename = require("gulp-rename");
75
- const tap = require("gulp-tap");
76
- const template = require("gulp-template");
77
- const run = require('gulp-run');
78
- const browserSyncServer = require('browser-sync').create();
79
-
80
- function cleanDist() {
81
- return gulp.src(
82
- distdir,
83
- builddir + "/css",
84
- builddir + "/snippets"
85
- )
86
- .on('error', onErrorHide)
87
- .pipe(clean());
88
- }
89
-
90
- function cleanIcons() {
91
- return gulp.src(
92
- srcdir + "/icons"
93
- )
94
- .on('error', onErrorHide)
95
- .pipe(clean());
96
- }
97
-
98
- function copy() {
99
- return gulp.src(srcdir + '/fonts/**/*')
100
- .pipe(gulp.dest(distdir + '/fonts/')),
101
- gulp.src(srcdir + '/images/**/*')
102
- .pipe(gulp.dest(distdir + '/images/')),
103
- gulp.src(srcdir + '/icons/**/*')
104
- .pipe(gulp.dest(distdir + '/fonts/')),
105
- gulp.src(builddir + '/favicons/**/*')
106
- .pipe(gulp.dest(distdir + '/favicons/'));
107
- }
108
-
109
- function sassSourcemaps() {
110
- if (browserSyncOptions.start) {
111
- return gulp.src([
112
- srcdir + "/scss/*.scss"
113
- ])
114
- .pipe(sourcemaps.init())
115
- .pipe(sass({
116
- includePaths: ["node_modules"]
117
- }).on('error', sass.logError))
118
- .pipe(sourcemaps.write("."))
119
- .pipe(gulp.dest(distdir + '/css/'))
120
- .pipe(browserSyncServer.stream());
121
- } else {
122
- return gulp.src([
123
- srcdir + "/scss/*.scss"
124
- ])
125
- .pipe(sourcemaps.init())
126
- .pipe(sass({
127
- includePaths: ["node_modules"]
128
- }).on('error', sass.logError))
129
- .pipe(sourcemaps.write("."))
130
- .pipe(gulp.dest(distdir + '/css'));
131
- }
132
- }
133
-
134
- function sassStyle() {
135
- return gulp.src([
136
- srcdir + "/scss/*.scss"
137
- ])
138
- .pipe(sass({
139
- includePaths: ["node_modules"]
140
- }).on('error', sass.logError))
141
- .pipe(gulp.dest(distdir + '/css'));
142
- }
143
-
144
- function sassAddons() {
145
- return gulp.src(srcdir + "/scss/addons/*.scss")
146
- .pipe(sass({
147
- includePaths: ["node_modules"]
148
- }).on('error', sass.logError))
149
- .pipe(replace('../fonts/', '../../fonts/'))
150
- .pipe(gulp.dest(distdir + "/css/addons"));
151
- }
152
-
153
- function autoprefixCSS() {
154
- return gulp.src(distdir + '/css/*.css')
155
- .pipe(autoprefixer()).on('error', onError)
156
- .pipe(gulp.dest(distdir + '/css'));
157
- }
158
-
159
- function minifyStyleCSS() {
160
- return gulp.src(distdir + '/css/**/*.css')
161
- .pipe(minifyCSS({level: {1: {specialComments: 0}}}))
162
- .pipe(gulp.dest(distdir + '/css'));
163
- }
164
-
165
- function renameCSSFiles() {
166
- return gulp.src(distdir + '/css/*.css')
167
- .pipe(rename({
168
- suffix: timestamp
169
- }))
170
- .pipe(gulp.dest(distdir + '/css'));
171
- }
172
-
173
- function renameJSFiles() {
174
- return gulp.src(distdir + '/js/*.js')
175
- .pipe(rename({
176
- suffix: timestamp
177
- }))
178
- .pipe(gulp.dest(distdir + '/js'));
179
- }
180
-
181
- function generateIconfont() {
182
- return gulp.src(config.icons.src)
183
- .pipe(iconfontCss({
184
- fontName: nameIconfont,
185
- path: config.icons.template,
186
- targetPath: config.icons.buildScss,
187
- fontPath: config.icons.fontPath,
188
- }).on('error', onError))
189
- .pipe(iconfont({
190
- fontName: nameIconfont,
191
- prependUnicode: true,
192
- formats: ['woff', 'woff2'],
193
- fontSize: 1000
194
- }).on('error', onError))
195
- .pipe(gulp.dest(srcdir + '/icons/'));
196
- }
197
-
198
- function generateIconfontTimestamp() {
199
- nameIconfont = nameIconfont + timestamp;
200
- return gulp.src(config.icons.src)
201
- .pipe(iconfontCss({
202
- fontName: nameIconfont,
203
- path: config.icons.template,
204
- targetPath: config.icons.buildScss,
205
- fontPath: config.icons.fontPath,
206
- }).on('error', onError))
207
- .pipe(iconfont({
208
- fontName: nameIconfont,
209
- prependUnicode: true,
210
- formats: ['woff', 'woff2'],
211
- fontSize: 1000
212
- }).on('error', onError))
213
- .pipe(gulp.dest(srcdir + '/icons/'));
214
- }
215
-
216
- function generateFontHtml() {
217
- return gulp.src([
218
- srcdir + "/snippets/includeFont.html"
219
- ])
220
- .pipe(replace('%linkIconfontWoff2%', layoutpath + distdir + "/fonts/" + nameIconfont))
221
- .on('error', onError)
222
- .pipe(rename("iconfont.html"))
223
- .pipe(gulp.dest(distdir + "/snippets/"));
224
- }
225
-
226
- function generateCSSHtml() {
227
- return gulp.src([
228
- distdir + "/css/*.css"
229
- ])
230
- .pipe(
231
- tap(function (file) {
232
- let fileName = file.basename.replace(/\.[^/.]+$/, "");
233
- let htmlName = fileName.replace(timestamp, "");
234
- gulp.src(srcdir + '/snippets/includeCSS.html')
235
- .pipe(template())
236
- .pipe(replace('%linkCSS%', layoutpath + distdir + "/css/" + fileName))
237
- .pipe(rename(htmlName + ".html"))
238
- .pipe(gulp.dest(distdir + "/snippets/css"));
239
-
240
- })
241
- );
242
- }
243
-
244
- function generateJSHtml() {
245
- return gulp.src([
246
- distdir + "/js/*.js"
247
- ])
248
- .pipe(tap(function (file) {
249
- let fileName = file.basename.replace(/\.[^/.]+$/, "");
250
- let htmlName = fileName.replace(timestamp, "");
251
- gulp.src(srcdir + '/snippets/includeJS.html')
252
- .pipe(template())
253
- .pipe(replace('%linkJS%', layoutpath + distdir + "/js/" + fileName))
254
- .pipe(rename(htmlName + ".html"))
255
- .pipe(gulp.dest(distdir + "/snippets/js"));
256
-
257
- }));
258
- }
259
-
260
- function generateFaviconHtml() {
261
- return gulp.src(srcdir + "/snippets/faviconmarkup.html")
262
- .pipe(realFavicon.injectFaviconMarkups(JSON.parse(fs.readFileSync(builddir + favicon.distdir + "/faviconData.json")).favicon.html_code))
263
- .pipe(replace('<html><head>', ''))
264
- .pipe(replace('</head><body></body></html>', ''))
265
- .pipe(replace('./layout/frontend/', '/layout/frontend/'))
266
- .pipe(gulp.dest(distdir + "/snippets/"));
267
- }
268
-
269
- const esbuild = (options) => {
270
- let baseOptions = {
271
- bundle: true,
272
- target: [
273
- 'firefox100',
274
- 'chrome100',
275
- 'edge100',
276
- 'safari15',
277
- 'ios14'
278
- ]
279
- }
280
- return gulp.src(
281
- srcdir + '/js/*.js',
282
- srcdir + '/js/*.ts'
283
- )
284
- .pipe(gulpEsbuild({...baseOptions, ...options}))
285
- .on('error', onError)
286
- .pipe(gulp.dest(distdir + '/js'));
287
- }
288
-
289
- function esbuildSourcemaps() {
290
- return esbuild({
291
- sourcemap: true,
292
- });
293
- }
294
-
295
- function esbuildPublic() {
296
- return esbuild({
297
- sourcemap: true,
298
- minify: true
299
- });
300
- }
301
-
302
- function watchFiles() {
303
- gulp.watch([
304
- srcdir + "/scss/**/*.scss"
305
- ], gulp.series(
306
- gulp.parallel(sassSourcemaps)
307
- ));
308
- gulp.watch([
309
- srcdir + "/js/**/*.js",
310
- srcdir + "/js/**/*.ts"
311
- ], gulp.series(
312
- esbuildSourcemaps,
313
- browsersyncReload
314
- ));
315
- }
316
-
317
- function onError(err) {
318
- console.error(err);
319
- this.emit('end');
320
- }
321
-
322
- function onErrorHide(err) {
323
- this.emit('end');
324
- }
325
-
326
- function browsersyncServe(cb) {
327
- if (browserSyncOptions.start) {
328
- browserSyncServer.init({
329
- port: browserSyncOptions.port,
330
- open: browserSyncOptions.open,
331
- proxy: browserSyncProxy
332
- });
333
- cb();
334
- }else{
335
- cb();
336
- }
337
- }
338
-
339
- function browsersyncReload(cb) {
340
- if (browserSyncOptions.start) {
341
- browserSyncServer.reload();
342
- }
343
- cb();
344
- }
345
-
346
- // TASKS
347
-
348
- gulp.task('default', gulp.series(
349
- gulp.parallel(
350
- cleanIcons,
351
- cleanDist
352
- ),
353
- gulp.parallel(
354
- browsersyncServe,
355
- generateIconfont
356
- ),
357
- gulp.parallel(
358
- copy,
359
- sassSourcemaps,
360
- sassAddons,
361
- esbuildSourcemaps
362
- ),
363
- gulp.parallel(
364
- generateCSSHtml,
365
- generateJSHtml,
366
- generateFontHtml,
367
- generateFaviconHtml
368
- ),
369
- watchFiles
370
- ));
371
-
372
- gulp.task('public', gulp.series(
373
- gulp.parallel(
374
- cleanIcons,
375
- cleanDist
376
- ),
377
- generateIconfontTimestamp,
378
- gulp.parallel(
379
- copy,
380
- sassStyle,
381
- sassAddons,
382
- esbuildPublic
383
- ),
384
- autoprefixCSS,
385
- minifyStyleCSS,
386
- gulp.parallel(
387
- renameCSSFiles,
388
- renameJSFiles
389
- ),
390
- gulp.parallel(
391
- generateCSSHtml,
392
- generateJSHtml,
393
- generateFontHtml,
394
- generateFaviconHtml
395
- )
396
- ));
397
-
398
- gulp.task('generate-favicon', function (done) {
399
- realFavicon.generateFavicon({
400
- masterPicture: srcdir + "/" + favicon.masterpicture_path + "/" + favicon.masterpicture_filename,
401
- dest: builddir + favicon.distdir + '/',
402
- iconsPath: layoutpath + distdir + favicon.distdir + '/',
403
- design: {
404
- ios: {
405
- pictureAspect: 'backgroundAndMargin',
406
- backgroundColor: faviconBackground,
407
- margin: '18%',
408
- assets: {
409
- ios6AndPriorIcons: false,
410
- ios7AndLaterIcons: false,
411
- precomposedIcons: false,
412
- declareOnlyDefaultIcon: true
413
- }
414
- },
415
- desktopBrowser: {
416
- design: 'raw'
417
- },
418
- windows: {
419
- pictureAspect: 'noChange',
420
- backgroundColor: faviconBackground,
421
- onConflict: 'override',
422
- assets: {
423
- windows80Ie10Tile: false,
424
- windows10Ie11EdgeTiles: {
425
- small: false,
426
- medium: true,
427
- big: false,
428
- rectangle: false
429
- }
430
- }
431
- },
432
- androidChrome: {
433
- pictureAspect: 'noChange',
434
- themeColor: faviconBackground,
435
- manifest: {
436
- name: favicon.title,
437
- display: 'standalone',
438
- orientation: 'notSet',
439
- onConflict: 'override',
440
- declared: true
441
- },
442
- assets: {
443
- legacyIcon: false,
444
- lowResolutionIcons: false
445
- }
446
- },
447
- safariPinnedTab: {
448
- pictureAspect: 'silhouette',
449
- themeColor: faviconColor
450
- }
451
- },
452
- settings: {
453
- scalingAlgorithm: 'Mitchell',
454
- errorOnImageTooSmall: false,
455
- readmeFile: false,
456
- htmlCodeFile: false,
457
- usePathAsIs: false
458
- },
459
- markupFile: builddir + "/favicons/faviconData.json"
460
- }, function () {
461
- done();
462
- });
463
- });