html-crush 5.1.17 → 5.1.19

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.
package/CHANGELOG.md CHANGED
@@ -3,45 +3,21 @@
3
3
  All notable changes to this project will be documented in this file.
4
4
  See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
5
5
 
6
- # 5.1.0 (2022-08-12)
7
-
8
- ### Features
9
-
10
- - export types ([11b5fb9](https://github.com/codsen/codsen/commit/11b5fb936ce20e0a77c3a09806773e1cd7695c50))
11
-
12
6
  ## [5.0.22](https://github.com/codsen/codsen/compare/html-crush@5.0.21...html-crush@5.0.22) (2022-08-02)
13
7
 
14
- ### Bug Fixes
8
+ ### Fixed
15
9
 
16
10
  - export Opts and Res types ([a91c313](https://github.com/codsen/codsen/commit/a91c31378be43a93a51893d3383a3b53cb2bc5f0))
17
11
 
18
12
  ## 5.0.16 (2022-04-18)
19
13
 
20
- ### Bug Fixes
14
+ ### Fixed
21
15
 
22
16
  - tweak types ([104a64a](https://github.com/codsen/codsen/commit/104a64ab783c05af4ae8bd3eb653742eb95d0cd2))
23
17
 
24
- ## 5.0.10 (2021-12-24)
25
-
26
- ### Bug Fixes
27
-
28
- - add missing extension ([147bd6e](https://github.com/codsen/codsen/commit/147bd6ec2a2d44c09749f0fba0ca3e3d9c52da94))
29
-
30
- ## 5.0.9 (2021-12-24)
31
-
32
- ### Bug Fixes
33
-
34
- - add missing extension ([147bd6e](https://github.com/codsen/codsen/commit/147bd6ec2a2d44c09749f0fba0ca3e3d9c52da94))
35
-
36
- ## 5.0.8 (2021-12-24)
37
-
38
- ### Bug Fixes
39
-
40
- - add missing extension ([147bd6e](https://github.com/codsen/codsen/commit/147bd6ec2a2d44c09749f0fba0ca3e3d9c52da94))
41
-
42
18
  ## 5.0.0 (2021-09-09)
43
19
 
44
- ### Bug Fixes
20
+ ### Fixed
45
21
 
46
22
  - tweaks to the line length calculation ([4ec1fe2](https://github.com/codsen/codsen/commit/4ec1fe224f8e2c32e94c085afb8cf517cc806a8c))
47
23
 
@@ -68,7 +44,7 @@ See [Conventional Commits](https://conventionalcommits.org) for commit guideline
68
44
 
69
45
  ## 4.1.5 (2021-03-28)
70
46
 
71
- ### Bug Fixes
47
+ ### Fixed
72
48
 
73
49
  - retain the same type of line endings as the input ([b171628](https://github.com/codsen/codsen/commit/b171628d3fc1c0909af61530c1bcaf970c310159))
74
50
 
@@ -80,7 +56,7 @@ See [Conventional Commits](https://conventionalcommits.org) for commit guideline
80
56
 
81
57
  ## 4.0.1 (2021-01-28)
82
58
 
83
- ### Bug Fixes
59
+ ### Fixed
84
60
 
85
61
  - add testStats to npmignore ([f3c84e9](https://github.com/codsen/codsen/commit/f3c84e95afc5514214312f913692d85b2e12eb29))
86
62
  - correct the line length calculation around inline tags ([073f7a5](https://github.com/codsen/codsen/commit/073f7a5a2bb3f8ce0460e674deed9cf1eff63409))
@@ -97,13 +73,13 @@ See [Conventional Commits](https://conventionalcommits.org) for commit guideline
97
73
 
98
74
  ## 2.0.5 (2020-09-15)
99
75
 
100
- ### Bug Fixes
76
+ ### Fixed
101
77
 
102
78
  - improve CRLF line ending recognition ([ff3e3e7](https://gitlab.com/codsen/codsen/commit/ff3e3e7d7943a52e2339fb78e0cbd4677b72a11a))
103
79
 
104
80
  ## 2.0.0 (2020-07-04)
105
81
 
106
- ### Bug Fixes
82
+ ### Fixed
107
83
 
108
84
  - fix typo in the output, in log.timeTakenInMilliseconds ([48debda](https://gitlab.com/codsen/codsen/commit/48debda98858aa83d6f7df4a3b7f85895756d67e))
109
85
 
@@ -126,7 +102,7 @@ See [Conventional Commits](https://conventionalcommits.org) for commit guideline
126
102
 
127
103
  ## 1.9.35 (2020-05-24)
128
104
 
129
- ### Bug Fixes
105
+ ### Fixed
130
106
 
131
107
  - fixes the pre, code, CDATA and other code chunk skipping ([ec0408a](https://gitlab.com/codsen/codsen/commit/ec0408afee0b1a09cd711549cab6fefdc55efde8)), closes [#29](https://gitlab.com/codsen/codsen/issues/29)
132
108
 
@@ -152,19 +128,19 @@ That's now implemented.
152
128
 
153
129
  ## 1.8.5 (2019-09-04)
154
130
 
155
- ### Bug Fixes
131
+ ### Fixed
156
132
 
157
133
  - stop breaking `<!--<![endif]-->` into two parts, in front of `<![endif]` ([af421c7](https://gitlab.com/codsen/codsen/commit/af421c7))
158
134
 
159
135
  ## 1.8.3 (2019-08-24)
160
136
 
161
- ### Bug Fixes
137
+ ### Fixed
162
138
 
163
139
  - adding one more breaking point for insurance, thanks Mark Robbins ([b21651b](https://gitlab.com/codsen/codsen/commit/b21651b))
164
140
 
165
141
  ## 1.8.0 (2019-08-08)
166
142
 
167
- ### Bug Fixes
143
+ ### Fixed
168
144
 
169
145
  - previously inner tag whitespace removal was too lax, risking false positives ([ab59492](https://gitlab.com/codsen/codsen/commit/ab59492))
170
146
  - update the program's name on throw error reports ([abd093a](https://gitlab.com/codsen/codsen/commit/abd093a))
@@ -181,7 +157,7 @@ That's now implemented.
181
157
 
182
158
  ## 1.6.0 (2019-07-15)
183
159
 
184
- ### Bug Fixes
160
+ ### Fixed
185
161
 
186
162
  - Fix the rare cases where state of being within style tag was not terminated properly ([fefc206](https://gitlab.com/codsen/codsen/commit/fefc206)), closes [#11](https://gitlab.com/codsen/codsen/issues/11)
187
163
 
@@ -223,51 +199,51 @@ That's now implemented.
223
199
 
224
200
  ## 1.0.11 (2019-04-06)
225
201
 
226
- ### Bug Fixes
202
+ ### Fixed
227
203
 
228
204
  - Algorithm improvement not to break in front of `</a>` to prevent accidentally adding new spaces ([8939654](https://gitlab.com/codsen/codsen/commit/8939654))
229
205
 
230
206
  ## 0.8.0 (2019-01-20)
231
207
 
232
- - Various documentation and setup tweaks after we migrated to monorepo
233
- - Setup refresh: updated dependencies and all config files using automated tools
208
+ - Various documentation and setup tweaks after we migrated to monorepo
209
+ - Setup refresh: updated dependencies and all config files using automated tools
234
210
 
235
211
  ## 0.7.0 (2019-01-11)
236
212
 
237
- - Add one more tag before which there will be a line break ([4f00871](https://gitlab.com/codsen/codsen/tree/master/packages/html-crush/commits/4f00871))
213
+ - Add one more tag before which there will be a line break ([4f00871](https://gitlab.com/codsen/codsen/tree/master/packages/html-crush/commits/4f00871))
238
214
 
239
215
  ## 0.6.0 (2018-12-26)
240
216
 
241
- - Add licence block at the top of built files in dist/ folder ([cb2c259](https://gitlab.com/codsen/codsen/tree/master/packages/html-crush/commits/cb2c259))
242
- - Add more logging for doNothing state ([25262e5](https://gitlab.com/codsen/codsen/tree/master/packages/html-crush/commits/25262e5))
243
- - Do not touch CDATA blocks ([920e9d9](https://gitlab.com/codsen/codsen/tree/master/packages/html-crush/commits/920e9d9))
244
- - Don't minify script tags contents ([557e8fa](https://gitlab.com/codsen/codsen/tree/master/packages/html-crush/commits/557e8fa))
245
- - Don't touch code within pre-code blocks ([d32c092](https://gitlab.com/codsen/codsen/tree/master/packages/html-crush/commits/d32c092))
246
- - Fetch a handful of real websites and minify them for tests ([f7e8153](https://gitlab.com/codsen/codsen/tree/master/packages/html-crush/commits/f7e8153))
247
- - Remove whitespace within `<script>` blocks, in front of `</script>` ([d1efb20](https://gitlab.com/codsen/codsen/tree/master/packages/html-crush/commits/d1efb20))
248
- - Treat the whitespace in front of `<script>` ([75d85dc](https://gitlab.com/codsen/codsen/tree/master/packages/html-crush/commits/75d85dc))
217
+ - Add licence block at the top of built files in dist/ folder ([cb2c259](https://gitlab.com/codsen/codsen/tree/master/packages/html-crush/commits/cb2c259))
218
+ - Add more logging for doNothing state ([25262e5](https://gitlab.com/codsen/codsen/tree/master/packages/html-crush/commits/25262e5))
219
+ - Do not touch CDATA blocks ([920e9d9](https://gitlab.com/codsen/codsen/tree/master/packages/html-crush/commits/920e9d9))
220
+ - Don't minify script tags contents ([557e8fa](https://gitlab.com/codsen/codsen/tree/master/packages/html-crush/commits/557e8fa))
221
+ - Don't touch code within pre-code blocks ([d32c092](https://gitlab.com/codsen/codsen/tree/master/packages/html-crush/commits/d32c092))
222
+ - Fetch a handful of real websites and minify them for tests ([f7e8153](https://gitlab.com/codsen/codsen/tree/master/packages/html-crush/commits/f7e8153))
223
+ - Remove whitespace within `<script>` blocks, in front of `</script>` ([d1efb20](https://gitlab.com/codsen/codsen/tree/master/packages/html-crush/commits/d1efb20))
224
+ - Treat the whitespace in front of `<script>` ([75d85dc](https://gitlab.com/codsen/codsen/tree/master/packages/html-crush/commits/75d85dc))
249
225
 
250
226
  ## 0.5.0 (2018-12-14)
251
227
 
252
- - Added licence banner at the top of each built file (all files in `dist/` folder)
253
- - Improved readme file
228
+ - Added licence banner at the top of each built file (all files in `dist/` folder)
229
+ - Improved readme file
254
230
 
255
231
  ## 0.4.0 (2018-12-13)
256
232
 
257
- - Delete whitespace within `<script>` tag, before closing `</script>`.
258
- - Added unit tests minifying a handful of real-world websites. If URL fetch succeeds and source HTML is a string and not an empty-one, we minify with couple settings and measure, are results less than or equal to the original sources.
233
+ - Delete whitespace within `<script>` tag, before closing `</script>`.
234
+ - Added unit tests minifying a handful of real-world websites. If URL fetch succeeds and source HTML is a string and not an empty-one, we minify with couple settings and measure, are results less than or equal to the original sources.
259
235
 
260
236
  ## 0.3.0 (2018-12-12)
261
237
 
262
- - Improvements to whitespace control in front of `<script>` tag when some options are on.
238
+ - Improvements to whitespace control in front of `<script>` tag when some options are on.
263
239
 
264
240
  ## 0.2.0 (2018-12-11)
265
241
 
266
- - Program will not touch:
242
+ - Program will not touch:
267
243
  - CDATA blocks
268
244
  - `<pre><code>...</code></pre>` blocks
269
245
  - `<script>` tag contents
270
246
 
271
247
  ## 0.1.0 (2018-12-10)
272
248
 
273
- - First public release
249
+ - First public release
@@ -1,13 +1,13 @@
1
1
  /**
2
2
  * @name html-crush
3
3
  * @fileoverview Minify email templates
4
- * @version 5.1.17
4
+ * @version 5.1.19
5
5
  * @author Roy Revelt, Codsen Ltd
6
6
  * @license MIT
7
7
  * {@link https://codsen.com/os/html-crush/}
8
8
  */
9
9
 
10
- import{rApply as ne}from"ranges-apply";import{Ranges as le}from"ranges-push";import{matchLeft as oe,matchRight as F,matchRightIncl as X}from"string-match-left-right";import{expander as _}from"string-range-expander";import{left as G,right as a}from"string-left-right";var Y="5.1.17";var ge=Y,$=new le({limitToBeAddedWhitespace:!0}),te={lineLengthLimit:500,removeIndentations:!0,removeLineBreaks:!1,removeHTMLComments:!1,removeCSSComments:!0,reportProgressFunc:null,reportProgressFuncFrom:0,reportProgressFuncTo:100,breakToTheLeftOf:["</td","<html","</html","<head","</head","<meta","<link","<table","<script","<\/script","<!DOCTYPE","<style","</style","<title","<body","@media","</body","<!--[if","<!--<![endif","<![endif]"],mindTheInlineTags:["a","abbr","acronym","audio","b","bdi","bdo","big","br","button","canvas","cite","code","data","datalist","del","dfn","em","embed","i","iframe","img","input","ins","kbd","label","map","mark","meter","noscript","object","output","picture","progress","q","ruby","s","samp","script","select","slot","small","span","strong","sub","sup","svg","template","textarea","time","u","tt","var","video","wbr"]};function N(n){return typeof n=="string"}function A(n){return typeof n=="string"&&n.toUpperCase()!==n.toLowerCase()}function ce(n,E){let W=Date.now();if(!N(n))throw n===void 0?new Error("html-crush: [THROW_ID_01] the first input argument is completely missing! It should be given as string."):new Error(`html-crush: [THROW_ID_02] the first input argument must be string! It was given as "${typeof n}", equal to:
10
+ import{rApply as ne}from"ranges-apply";import{Ranges as le}from"ranges-push";import{matchLeft as oe,matchRight as F,matchRightIncl as X}from"string-match-left-right";import{expander as _}from"string-range-expander";import{left as G,right as a}from"string-left-right";var Y="5.1.19";var ge=Y,$=new le({limitToBeAddedWhitespace:!0}),te={lineLengthLimit:500,removeIndentations:!0,removeLineBreaks:!1,removeHTMLComments:!1,removeCSSComments:!0,reportProgressFunc:null,reportProgressFuncFrom:0,reportProgressFuncTo:100,breakToTheLeftOf:["</td","<html","</html","<head","</head","<meta","<link","<table","<script","<\/script","<!DOCTYPE","<style","</style","<title","<body","@media","</body","<!--[if","<!--<![endif","<![endif]"],mindTheInlineTags:["a","abbr","acronym","audio","b","bdi","bdo","big","br","button","canvas","cite","code","data","datalist","del","dfn","em","embed","i","iframe","img","input","ins","kbd","label","map","mark","meter","noscript","object","output","picture","progress","q","ruby","s","samp","script","select","slot","small","span","strong","sub","sup","svg","template","textarea","time","u","tt","var","video","wbr"]};function N(n){return typeof n=="string"}function A(n){return typeof n=="string"&&n.toUpperCase()!==n.toLowerCase()}function ce(n,E){let W=Date.now();if(!N(n))throw n===void 0?new Error("html-crush: [THROW_ID_01] the first input argument is completely missing! It should be given as string."):new Error(`html-crush: [THROW_ID_02] the first input argument must be string! It was given as "${typeof n}", equal to:
11
11
  ${JSON.stringify(n,null,4)}`);if(E&&typeof E!="object")throw new Error(`html-crush: [THROW_ID_03] the second input argument, options object, should be a plain object but it was given as type ${typeof E}, equal to ${JSON.stringify(E,null,4)}`);if(E&&Array.isArray(E.breakToTheLeftOf)&&E.breakToTheLeftOf.length){for(let e=0,w=E.breakToTheLeftOf.length;e<w;e++)if(!N(E.breakToTheLeftOf[e]))throw new TypeError(`html-crush: [THROW_ID_05] the resolvedOpts.breakToTheLeftOf array contains non-string elements! For example, element at index ${e} is of a type "${typeof E.breakToTheLeftOf[e]}" and is equal to:
12
12
  ${JSON.stringify(E.breakToTheLeftOf[e],null,4)}`)}let l={...te,...E};typeof l.removeHTMLComments=="boolean"&&(l.removeHTMLComments=l.removeHTMLComments?1:0);let v="";Array.isArray(l.breakToTheLeftOf)&&l.breakToTheLeftOf.length&&(v=[...new Set(l.breakToTheLeftOf.map(e=>e[0]))].join(""));let L={removeHTMLComments:!1,removeCSSComments:!1},p=null,i=null,S=!1,m=0,H=0,g=!1,O=!1,c=null,f=null,V=null,U=null,u,t=null,s=null,r=null,T=null,D=null,M=null,P=">};",I="<",K="!",q=">",z="<",B="{},:;<>~+",k=B,J=B,C=!0,h=n.length,Q=Math.floor(h/2),x=.01,j;l.reportProgressFunc&&(j=Math.floor(l.reportProgressFuncTo-(l.reportProgressFuncTo-l.reportProgressFuncFrom)*x-l.reportProgressFuncFrom));let d,R=0,b=`
13
13
  `;if(n.includes(`\r
@@ -1,7 +1,7 @@
1
1
  /**
2
2
  * @name html-crush
3
3
  * @fileoverview Minify email templates
4
- * @version 5.1.17
4
+ * @version 5.1.19
5
5
  * @author Roy Revelt, Codsen Ltd
6
6
  * @license MIT
7
7
  * {@link https://codsen.com/os/html-crush/}
@@ -24,7 +24,7 @@ ${JSON.stringify(a.ifLeftSideIncludesThisThenCropTightly,null,4)}. Now, that arr
24
24
  \r`.includes(e[a])||n&&e[a]===K)return a;return null}function D(e,t=0){return oi({str:e,idx:t,stopAtNewlines:!1,stopAtRawNbsp:!1})}function si({str:e,idx:t,stopAtNewlines:r,stopAtRawNbsp:n}){if(typeof e!="string"||!e.length||((!t||typeof t!="number")&&(t=0),t<1))return null;if(e[~-t]&&(e[~-t].trim()||r&&`
25
25
  \r`.includes(e[~-t])||n&&e[~-t]===K))return~-t;if(e[t-2]&&(e[t-2].trim()||r&&`
26
26
  \r`.includes(e[t-2])||n&&e[t-2]===K))return t-2;for(let a=t;a--;)if(e[a]&&(e[a].trim()||r&&`
27
- \r`.includes(e[a])||n&&e[a]===K))return a;return null}function de(e,t=0){return si({str:e,idx:t,stopAtNewlines:!1,stopAtRawNbsp:!1})}var zt="5.1.17";var ai=zt,E=new et({limitToBeAddedWhitespace:!0}),Zt={lineLengthLimit:500,removeIndentations:!0,removeLineBreaks:!1,removeHTMLComments:!1,removeCSSComments:!0,reportProgressFunc:null,reportProgressFuncFrom:0,reportProgressFuncTo:100,breakToTheLeftOf:["</td","<html","</html","<head","</head","<meta","<link","<table","<script","<\/script","<!DOCTYPE","<style","</style","<title","<body","@media","</body","<!--[if","<!--<![endif","<![endif]"],mindTheInlineTags:["a","abbr","acronym","audio","b","bdi","bdo","big","br","button","canvas","cite","code","data","datalist","del","dfn","em","embed","i","iframe","img","input","ins","kbd","label","map","mark","meter","noscript","object","output","picture","progress","q","ruby","s","samp","script","select","slot","small","span","strong","sub","sup","svg","template","textarea","time","u","tt","var","video","wbr"]};function Y(e){return typeof e=="string"}function X(e){return typeof e=="string"&&e.toUpperCase()!==e.toLowerCase()}function ui(e,t){let r=Date.now();if(!Y(e))throw e===void 0?new Error("html-crush: [THROW_ID_01] the first input argument is completely missing! It should be given as string."):new Error(`html-crush: [THROW_ID_02] the first input argument must be string! It was given as "${typeof e}", equal to:
27
+ \r`.includes(e[a])||n&&e[a]===K))return a;return null}function de(e,t=0){return si({str:e,idx:t,stopAtNewlines:!1,stopAtRawNbsp:!1})}var zt="5.1.19";var ai=zt,E=new et({limitToBeAddedWhitespace:!0}),Zt={lineLengthLimit:500,removeIndentations:!0,removeLineBreaks:!1,removeHTMLComments:!1,removeCSSComments:!0,reportProgressFunc:null,reportProgressFuncFrom:0,reportProgressFuncTo:100,breakToTheLeftOf:["</td","<html","</html","<head","</head","<meta","<link","<table","<script","<\/script","<!DOCTYPE","<style","</style","<title","<body","@media","</body","<!--[if","<!--<![endif","<![endif]"],mindTheInlineTags:["a","abbr","acronym","audio","b","bdi","bdo","big","br","button","canvas","cite","code","data","datalist","del","dfn","em","embed","i","iframe","img","input","ins","kbd","label","map","mark","meter","noscript","object","output","picture","progress","q","ruby","s","samp","script","select","slot","small","span","strong","sub","sup","svg","template","textarea","time","u","tt","var","video","wbr"]};function Y(e){return typeof e=="string"}function X(e){return typeof e=="string"&&e.toUpperCase()!==e.toLowerCase()}function ui(e,t){let r=Date.now();if(!Y(e))throw e===void 0?new Error("html-crush: [THROW_ID_01] the first input argument is completely missing! It should be given as string."):new Error(`html-crush: [THROW_ID_02] the first input argument must be string! It was given as "${typeof e}", equal to:
28
28
  ${JSON.stringify(e,null,4)}`);if(t&&typeof t!="object")throw new Error(`html-crush: [THROW_ID_03] the second input argument, options object, should be a plain object but it was given as type ${typeof t}, equal to ${JSON.stringify(t,null,4)}`);if(t&&Array.isArray(t.breakToTheLeftOf)&&t.breakToTheLeftOf.length){for(let i=0,Q=t.breakToTheLeftOf.length;i<Q;i++)if(!Y(t.breakToTheLeftOf[i]))throw new TypeError(`html-crush: [THROW_ID_05] the resolvedOpts.breakToTheLeftOf array contains non-string elements! For example, element at index ${i} is of a type "${typeof t.breakToTheLeftOf[i]}" and is equal to:
29
29
  ${JSON.stringify(t.breakToTheLeftOf[i],null,4)}`)}let n=S(S({},Zt),t);typeof n.removeHTMLComments=="boolean"&&(n.removeHTMLComments=n.removeHTMLComments?1:0);let a="";Array.isArray(n.breakToTheLeftOf)&&n.breakToTheLeftOf.length&&(a=[...new Set(n.breakToTheLeftOf.map(i=>i[0]))].join(""));let o={removeHTMLComments:!1,removeCSSComments:!1},u=null,l=null,c=!1,s=0,d=0,p=!1,T=!1,f=null,m=null,w=null,L=null,b,h=null,$=null,y=null,A=null,I=null,V=null,z=">};",Z="<",Qt="!",en=">",tn="<",We="{},:;<>~+",be=We,Te=We,j=!0,v=e.length,nn=Math.floor(v/2),je=.01,Je;n.reportProgressFunc&&(Je=Math.floor(n.reportProgressFuncTo-(n.reportProgressFuncTo-n.reportProgressFuncFrom)*je-n.reportProgressFuncFrom));let R,oe=0,C=`
30
30
  `;if(e.includes(`\r
@@ -42,7 +42,7 @@ ${JSON.stringify(t.breakToTheLeftOf[i],null,4)}`)}let n=S(S({},Zt),t);typeof n.r
42
42
  /**
43
43
  * @name arrayiffy-if-string
44
44
  * @fileoverview Put non-empty strings into arrays, turn empty-ones into empty arrays. Bypass everything else.
45
- * @version 4.1.1
45
+ * @version 4.1.3
46
46
  * @author Roy Revelt, Codsen Ltd
47
47
  * @license MIT
48
48
  * {@link https://codsen.com/os/arrayiffy-if-string/}
@@ -50,7 +50,7 @@ ${JSON.stringify(t.breakToTheLeftOf[i],null,4)}`)}let n=S(S({},Zt),t);typeof n.r
50
50
  /**
51
51
  * @name ranges-apply
52
52
  * @fileoverview Take an array of string index ranges, delete/replace the string according to them
53
- * @version 6.2.7
53
+ * @version 6.2.9
54
54
  * @author Roy Revelt, Codsen Ltd
55
55
  * @license MIT
56
56
  * {@link https://codsen.com/os/ranges-apply/}
@@ -58,7 +58,7 @@ ${JSON.stringify(t.breakToTheLeftOf[i],null,4)}`)}let n=S(S({},Zt),t);typeof n.r
58
58
  /**
59
59
  * @name ranges-merge
60
60
  * @fileoverview Merge and sort string index ranges
61
- * @version 8.2.2
61
+ * @version 8.2.4
62
62
  * @author Roy Revelt, Codsen Ltd
63
63
  * @license MIT
64
64
  * {@link https://codsen.com/os/ranges-merge/}
@@ -66,7 +66,7 @@ ${JSON.stringify(t.breakToTheLeftOf[i],null,4)}`)}let n=S(S({},Zt),t);typeof n.r
66
66
  /**
67
67
  * @name ranges-push
68
68
  * @fileoverview Gather string index ranges
69
- * @version 6.2.2
69
+ * @version 6.2.4
70
70
  * @author Roy Revelt, Codsen Ltd
71
71
  * @license MIT
72
72
  * {@link https://codsen.com/os/ranges-push/}
@@ -74,7 +74,7 @@ ${JSON.stringify(t.breakToTheLeftOf[i],null,4)}`)}let n=S(S({},Zt),t);typeof n.r
74
74
  /**
75
75
  * @name ranges-sort
76
76
  * @fileoverview Sort string index ranges
77
- * @version 5.1.1
77
+ * @version 5.1.3
78
78
  * @author Roy Revelt, Codsen Ltd
79
79
  * @license MIT
80
80
  * {@link https://codsen.com/os/ranges-sort/}
@@ -82,7 +82,7 @@ ${JSON.stringify(t.breakToTheLeftOf[i],null,4)}`)}let n=S(S({},Zt),t);typeof n.r
82
82
  /**
83
83
  * @name string-collapse-leading-whitespace
84
84
  * @fileoverview Collapse the leading and trailing whitespace of a string
85
- * @version 6.1.2
85
+ * @version 6.1.4
86
86
  * @author Roy Revelt, Codsen Ltd
87
87
  * @license MIT
88
88
  * {@link https://codsen.com/os/string-collapse-leading-whitespace/}
@@ -90,7 +90,7 @@ ${JSON.stringify(t.breakToTheLeftOf[i],null,4)}`)}let n=S(S({},Zt),t);typeof n.r
90
90
  /**
91
91
  * @name string-left-right
92
92
  * @fileoverview Looks up the first non-whitespace character to the left/right of a given index
93
- * @version 5.1.2
93
+ * @version 5.1.4
94
94
  * @author Roy Revelt, Codsen Ltd
95
95
  * @license MIT
96
96
  * {@link https://codsen.com/os/string-left-right/}
@@ -98,7 +98,7 @@ ${JSON.stringify(t.breakToTheLeftOf[i],null,4)}`)}let n=S(S({},Zt),t);typeof n.r
98
98
  /**
99
99
  * @name string-match-left-right
100
100
  * @fileoverview Match substrings on the left or right of a given index, ignoring whitespace
101
- * @version 8.2.2
101
+ * @version 8.2.4
102
102
  * @author Roy Revelt, Codsen Ltd
103
103
  * @license MIT
104
104
  * {@link https://codsen.com/os/string-match-left-right/}
@@ -106,7 +106,7 @@ ${JSON.stringify(t.breakToTheLeftOf[i],null,4)}`)}let n=S(S({},Zt),t);typeof n.r
106
106
  /**
107
107
  * @name string-range-expander
108
108
  * @fileoverview Expands string index ranges within whitespace boundaries until letters are met
109
- * @version 3.1.1
109
+ * @version 3.1.3
110
110
  * @author Roy Revelt, Codsen Ltd
111
111
  * @license MIT
112
112
  * {@link https://codsen.com/os/string-range-expander/}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "html-crush",
3
- "version": "5.1.17",
3
+ "version": "5.1.19",
4
4
  "description": "Minify email templates",
5
5
  "keywords": [
6
6
  "breaks",
@@ -78,11 +78,11 @@
78
78
  }
79
79
  },
80
80
  "dependencies": {
81
- "ranges-apply": "^6.2.7",
82
- "ranges-push": "^6.2.2",
83
- "string-left-right": "^5.1.2",
84
- "string-match-left-right": "^8.2.2",
85
- "string-range-expander": "^3.1.1",
86
- "test-mixer": "^3.1.1"
81
+ "ranges-apply": "^6.2.9",
82
+ "ranges-push": "^6.2.4",
83
+ "string-left-right": "^5.1.4",
84
+ "string-match-left-right": "^8.2.4",
85
+ "string-range-expander": "^3.1.3",
86
+ "test-mixer": "^3.1.3"
87
87
  }
88
88
  }
@@ -1,21 +0,0 @@
1
- /* eslint-disable no-unused-vars */
2
- // Quick Take
3
-
4
- import { strict as assert } from "assert";
5
-
6
- import { crush, defaults, version } from "../dist/html-crush.esm.js";
7
-
8
- assert.equal(
9
- crush(
10
- `<table width="100" border="0" cellpadding="0" cellspacing="0">
11
- <tr>
12
- <td>
13
- hi
14
- </td>
15
- </tr>
16
- </table>`,
17
- { removeLineBreaks: true }
18
- ).result,
19
- `<table width="100" border="0" cellpadding="0" cellspacing="0"><tr><td> hi
20
- </td></tr></table>`
21
- );