Skip to content

Commit 3a7b906

Browse files
committed
Use UnCSS to Remove Unused Classes
* Remove unused classes using the uncss tools.
1 parent ee4000f commit 3a7b906

File tree

1 file changed

+25
-211
lines changed

1 file changed

+25
-211
lines changed

.github/workflows/newsletter_template.html

Lines changed: 25 additions & 211 deletions
Original file line numberDiff line numberDiff line change
@@ -20,27 +20,9 @@
2020
<title>{{ post.title }}</title>
2121

2222
<style type="text/css">
23-
p {
24-
margin: 10px 0;
25-
padding: 0;
26-
}
2723
table {
2824
border-collapse: collapse;
2925
}
30-
h1 {
31-
display: block;
32-
margin: 0.75rem 0 0 0;
33-
padding: 0;
34-
}
35-
h2,
36-
h3,
37-
h4,
38-
h5,
39-
h6 {
40-
display: block;
41-
margin: 0.5rem 0 0 0;
42-
padding: 0;
43-
}
4426
img,
4527
a img {
4628
border: 0;
@@ -56,9 +38,6 @@
5638
padding: 0;
5739
width: 100%;
5840
}
59-
.mcnPreviewText {
60-
display: none !important;
61-
}
6241
#outlook a {
6342
padding: 0;
6443
}
@@ -69,69 +48,29 @@
6948
mso-table-lspace: 0pt;
7049
mso-table-rspace: 0pt;
7150
}
72-
.ReadMsgBody {
73-
width: 100%;
74-
}
75-
.ExternalClass {
76-
width: 100%;
77-
}
7851
p,
7952
a,
80-
li,
81-
td,
82-
blockquote {
53+
td {
8354
mso-line-height-rule: exactly;
8455
font-family: Helvetica;
8556
margin: 0.5rem 0;
8657
}
87-
a[href^='tel'],
88-
a[href^='sms'] {
89-
color: inherit;
90-
cursor: default;
91-
text-decoration: none;
92-
}
93-
p,
9458
a,
95-
li,
9659
td,
9760
body,
98-
table,
99-
blockquote {
61+
table {
10062
-ms-text-size-adjust: 100%;
10163
-webkit-text-size-adjust: 100%;
10264
}
103-
.ExternalClass,
104-
.ExternalClass p,
105-
.ExternalClass td,
106-
.ExternalClass div,
107-
.ExternalClass span,
108-
.ExternalClass font {
109-
line-height: 100%;
110-
}
111-
a[x-apple-data-detectors] {
112-
color: inherit !important;
113-
text-decoration: none !important;
114-
font-size: inherit !important;
115-
font-family: inherit !important;
116-
font-weight: inherit !important;
117-
line-height: inherit !important;
118-
}
11965
.templateContainer {
12066
max-width: 600px !important;
12167
}
122-
a.mcnButton {
123-
display: block;
124-
}
125-
.mcnImage,
126-
.mcnRetinaImage {
68+
.mcnImage {
12769
vertical-align: bottom;
12870
}
12971
.mcnTextContent {
13072
word-break: break-word;
13173
}
132-
.mcnTextContent img {
133-
height: auto !important;
134-
}
13574
.mcnDividerBlock {
13675
table-layout: fixed !important;
13776
}
@@ -151,6 +90,9 @@
15190
line-height: 125%;
15291
letter-spacing: normal;
15392
text-align: left;
93+
display: block;
94+
margin: 0.75rem 0 0 0;
95+
padding: 0;
15496
}
15597
h2 {
15698
color: #202020;
@@ -161,6 +103,9 @@
161103
line-height: 125%;
162104
letter-spacing: normal;
163105
text-align: left;
106+
display: block;
107+
margin: 0.5rem 0 0 0;
108+
padding: 0;
164109
}
165110
h3 {
166111
color: #202020;
@@ -171,6 +116,9 @@
171116
line-height: 125%;
172117
letter-spacing: normal;
173118
text-align: left;
119+
display: block;
120+
margin: 0.5rem 0 0 0;
121+
padding: 0;
174122
}
175123
h4 {
176124
color: #202020;
@@ -181,6 +129,9 @@
181129
line-height: 125%;
182130
letter-spacing: normal;
183131
text-align: left;
132+
display: block;
133+
margin: 0.5rem 0 0 0;
134+
padding: 0;
184135
}
185136
#templatePreheader {
186137
background-color: #fafafa;
@@ -193,16 +144,14 @@
193144
padding-top: 9px;
194145
padding-bottom: 9px;
195146
}
196-
#templatePreheader .mcnTextContent,
197-
#templatePreheader .mcnTextContent p {
147+
#templatePreheader .mcnTextContent {
198148
color: #656565;
199149
font-family: Helvetica;
200150
font-size: 12px;
201151
line-height: 150%;
202152
text-align: left;
203153
}
204-
#templatePreheader .mcnTextContent a,
205-
#templatePreheader .mcnTextContent p a {
154+
#templatePreheader .mcnTextContent a {
206155
color: #656565;
207156
font-weight: normal;
208157
text-decoration: underline;
@@ -224,6 +173,8 @@
224173
font-size: 16px;
225174
line-height: 150%;
226175
text-align: left;
176+
margin: 10px 0;
177+
padding: 0;
227178
}
228179
p a {
229180
color: #007c89;
@@ -241,20 +192,6 @@
241192
padding-top: 9px;
242193
padding-bottom: 9px;
243194
}
244-
#templateBody .mcnTextContent,
245-
#templateBody .mcnTextContent p {
246-
color: #202020;
247-
font-family: Helvetica;
248-
font-size: 16px;
249-
line-height: 150%;
250-
text-align: left;
251-
}
252-
#templateBody .mcnTextContent a,
253-
#templateBody .mcnTextContent p a {
254-
color: #007c89;
255-
font-weight: normal;
256-
text-decoration: underline;
257-
}
258195
#templateFooter {
259196
background-color: #fafafa;
260197
background-image: none;
@@ -266,16 +203,14 @@
266203
padding-top: 9px;
267204
padding-bottom: 9px;
268205
}
269-
#templateFooter .mcnTextContent,
270-
#templateFooter .mcnTextContent p {
206+
#templateFooter .mcnTextContent {
271207
color: #656565;
272208
font-family: Helvetica;
273209
font-size: 12px;
274210
line-height: 150%;
275211
text-align: center;
276212
}
277-
#templateFooter .mcnTextContent a,
278-
#templateFooter .mcnTextContent p a {
213+
#templateFooter .mcnTextContent a {
279214
color: #656565;
280215
font-weight: normal;
281216
text-decoration: underline;
@@ -302,157 +237,36 @@
302237
min-width: 100% !important;
303238
}
304239
}
305-
@media only screen and (max-width: 480px) {
306-
.mcnRetinaImage {
307-
max-width: 100% !important;
308-
}
309-
}
310240
@media only screen and (max-width: 480px) {
311241
.mcnImage {
312242
width: 100% !important;
313243
}
314244
}
315245
@media only screen and (max-width: 480px) {
316-
.mcnCartContainer,
317-
.mcnCaptionTopContent,
318-
.mcnRecContentContainer,
319-
.mcnCaptionBottomContent,
320-
.mcnTextContentContainer,
321-
.mcnBoxedTextContentContainer,
322-
.mcnImageGroupContentContainer,
323-
.mcnCaptionLeftTextContentContainer,
324-
.mcnCaptionRightTextContentContainer,
325-
.mcnCaptionLeftImageContentContainer,
326-
.mcnCaptionRightImageContentContainer,
327-
.mcnImageCardLeftTextContentContainer,
328-
.mcnImageCardRightTextContentContainer,
329-
.mcnImageCardLeftImageContentContainer,
330-
.mcnImageCardRightImageContentContainer {
246+
.mcnTextContentContainer {
331247
max-width: 100% !important;
332248
width: 100% !important;
333249
}
334250
}
335251
@media only screen and (max-width: 480px) {
336-
.mcnBoxedTextContentContainer {
337-
min-width: 100% !important;
338-
}
339-
}
340-
@media only screen and (max-width: 480px) {
341-
.mcnImageGroupContent {
342-
padding: 9px !important;
343-
}
344-
}
345-
@media only screen and (max-width: 480px) {
346-
.mcnCaptionLeftContentOuter .mcnTextContent,
347-
.mcnCaptionRightContentOuter .mcnTextContent {
348-
padding-top: 9px !important;
349-
}
350-
}
351-
@media only screen and (max-width: 480px) {
352-
.mcnImageCardTopImageContent,
353-
.mcnCaptionBottomContent:last-child .mcnCaptionBottomImageContent,
354-
.mcnCaptionBlockInner .mcnCaptionTopContent:last-child .mcnTextContent {
355-
padding-top: 18px !important;
356-
}
357-
}
358-
@media only screen and (max-width: 480px) {
359-
.mcnImageCardBottomImageContent {
360-
padding-bottom: 9px !important;
361-
}
362-
}
363-
@media only screen and (max-width: 480px) {
364-
.mcnImageGroupBlockInner {
365-
padding-top: 0 !important;
366-
padding-bottom: 0 !important;
367-
}
368-
}
369-
@media only screen and (max-width: 480px) {
370-
.mcnImageGroupBlockOuter {
371-
padding-top: 9px !important;
372-
padding-bottom: 9px !important;
373-
}
374-
}
375-
@media only screen and (max-width: 480px) {
376-
.mcnTextContent,
377-
.mcnBoxedTextContentColumn {
252+
.mcnTextContent {
378253
padding-right: 18px !important;
379254
padding-left: 18px !important;
380255
}
381256
}
382-
@media only screen and (max-width: 480px) {
383-
.mcnImageCardLeftImageContent,
384-
.mcnImageCardRightImageContent {
385-
padding-right: 18px !important;
386-
padding-bottom: 0 !important;
387-
padding-left: 18px !important;
388-
}
389-
}
390-
@media only screen and (max-width: 480px) {
391-
.mcpreview-image-uploader {
392-
display: none !important;
393-
width: 100% !important;
394-
}
395-
}
396-
@media only screen and (max-width: 480px) {
397-
h1 {
398-
font-size: 22px !important;
399-
line-height: 125% !important;
400-
}
401-
}
402-
@media only screen and (max-width: 480px) {
403-
h2 {
404-
font-size: 20px !important;
405-
line-height: 125% !important;
406-
}
407-
}
408-
@media only screen and (max-width: 480px) {
409-
h3 {
410-
font-size: 18px !important;
411-
line-height: 125% !important;
412-
}
413-
}
414-
@media only screen and (max-width: 480px) {
415-
h4 {
416-
font-size: 16px !important;
417-
line-height: 150% !important;
418-
}
419-
}
420-
@media only screen and (max-width: 480px) {
421-
.mcnBoxedTextContentContainer .mcnTextContent,
422-
.mcnBoxedTextContentContainer .mcnTextContent p {
423-
font-size: 14px !important;
424-
line-height: 150% !important;
425-
}
426-
}
427257
@media only screen and (max-width: 480px) {
428258
#templatePreheader {
429259
display: block !important;
430260
}
431261
}
432262
@media only screen and (max-width: 480px) {
433-
#templatePreheader .mcnTextContent,
434-
#templatePreheader .mcnTextContent p {
263+
#templatePreheader .mcnTextContent {
435264
font-size: 14px !important;
436265
line-height: 150% !important;
437266
}
438267
}
439268
@media only screen and (max-width: 480px) {
440-
#templateHeader .mcnTextContent,
441-
#templateHeader .mcnTextContent p {
442-
font-size: 16px !important;
443-
line-height: 150% !important;
444-
}
445-
}
446-
@media only screen and (max-width: 480px) {
447-
#templateBody .mcnTextContent,
448-
#templateBody .mcnTextContent p {
449-
font-size: 16px !important;
450-
line-height: 150% !important;
451-
}
452-
}
453-
@media only screen and (max-width: 480px) {
454-
#templateFooter .mcnTextContent,
455-
#templateFooter .mcnTextContent p {
269+
#templateFooter .mcnTextContent {
456270
font-size: 14px !important;
457271
line-height: 150% !important;
458272
}

0 commit comments

Comments
 (0)