ghost 4.25.0 → 4.25.1

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.
@@ -281,6 +281,18 @@
281
281
  background: var(--ghost-accent-color, #1292EE);
282
282
  }
283
283
 
284
+ .post-content blockquote.kg-blockquote-alt {
285
+ font-size: 2rem;
286
+ line-height: 1.7;
287
+ text-align: center;
288
+ color: #738a94;
289
+ padding: 1rem 6rem 1.5rem;
290
+ }
291
+
292
+ .post-content blockquote.kg-blockquote-alt::before {
293
+ display: none;
294
+ }
295
+
284
296
  .post-content :not(.kg-card):not([id]) + .kg-card {
285
297
  margin-top: 40px;
286
298
  }
@@ -569,6 +581,56 @@
569
581
  color: #fff;
570
582
  }
571
583
 
584
+ .kg-callout-card {
585
+ display: flex;
586
+ padding: 20px 28px;
587
+ border-radius: 3px;
588
+ }
589
+
590
+ .kg-callout-card-grey {
591
+ background: rgba(124, 139, 154, 0.13);
592
+ }
593
+
594
+ .kg-callout-card-white {
595
+ background: transparent;
596
+ box-shadow: inset 0 0 0 1px rgba(124, 139, 154, 0.25);
597
+ }
598
+
599
+ .kg-callout-card-blue {
600
+ background: rgba(33, 172, 232, 0.12);
601
+ }
602
+
603
+ .kg-callout-card-green {
604
+ background: rgba(52, 183, 67, 0.12);
605
+ }
606
+
607
+ .kg-callout-card-yellow {
608
+ background: rgba(240, 165, 15, 0.13);
609
+ }
610
+
611
+ .kg-callout-card-red {
612
+ background: rgba(209, 46, 46, 0.11);
613
+ }
614
+
615
+ .kg-callout-card-pink {
616
+ background: rgba(225, 71, 174, 0.11);
617
+ }
618
+
619
+ .kg-callout-card-purple {
620
+ background: rgba(135, 85, 236, 0.12);
621
+ }
622
+
623
+ .kg-callout-card-accent {
624
+ background: var(--ghost-accent-color);
625
+ color: #fff;
626
+ }
627
+
628
+ .kg-callout-emoji {
629
+ padding-right: 16px;
630
+ line-height: 1.3;
631
+ font-size: 1.25em;
632
+ }
633
+
572
634
  .kg-width-full.kg-card-hascaption {
573
635
  display: grid;
574
636
  grid-template-columns: inherit;
@@ -6,6 +6,9 @@
6
6
 
7
7
  const {metaData} = require('../services/proxy');
8
8
  const {SafeString} = require('../services/rendering');
9
+ const logging = require('@tryghost/logging');
10
+ const sentry = require('../../shared/sentry');
11
+ const errors = require('@tryghost/errors');
9
12
 
10
13
  const {getMetaDataUrl} = metaData;
11
14
 
@@ -13,7 +16,21 @@ module.exports = function url(options) {
13
16
  const absolute = options && options.hash.absolute && options.hash.absolute !== 'false';
14
17
  let outputUrl = getMetaDataUrl(this, absolute);
15
18
 
16
- outputUrl = encodeURI(decodeURI(outputUrl));
19
+ try {
20
+ outputUrl = encodeURI(decodeURI(outputUrl));
21
+ } catch (err) {
22
+ // Happens when the outputURL contains an invalid URI character like "%%" or "%80"
23
+
24
+ // Send the error not to be blind to these
25
+ const error = new errors.IncorrectUsageError({
26
+ message: `The url "${outputUrl}" couldn't be escaped correctly`,
27
+ err: err
28
+ });
29
+ sentry.captureException(error);
30
+ logging.error(error);
31
+
32
+ return new SafeString('');
33
+ }
17
34
 
18
35
  return new SafeString(outputUrl);
19
36
  };
@@ -0,0 +1,29 @@
1
+ blockquote.kg-blockquote-alt {
2
+ background: none;
3
+ font-size: 2.4rem;
4
+ line-height: 1.7;
5
+ text-align: center;
6
+ color: var(--color-midgrey);
7
+ padding: 1rem 8rem 1.5rem;
8
+ border: 0 none;
9
+ }
10
+
11
+ blockquote.kg-blockquote-alt::before {
12
+ display: none;
13
+ }
14
+
15
+ @media (max-width: 800px) {
16
+ blockquote.kg-blockquote-alt {
17
+ font-size: 2.2rem;
18
+ padding-left: 6rem;
19
+ padding-right: 6rem;
20
+ }
21
+ }
22
+
23
+ @media (max-width: 600px) {
24
+ blockquote.kg-blockquote-alt {
25
+ font-size: 2rem;
26
+ padding-left: 3rem;
27
+ padding-right: 3rem;
28
+ }
29
+ }
@@ -1,6 +1,6 @@
1
1
  .kg-callout-card {
2
2
  display: flex;
3
- padding: 20px 28px;
3
+ padding: 1.2em 1.6em;
4
4
  border-radius: 3px;
5
5
  }
6
6
 
@@ -42,8 +42,17 @@
42
42
  color: #fff;
43
43
  }
44
44
 
45
+ .kg-callout-card-accent a {
46
+ color: #fff;
47
+ }
48
+
45
49
  .kg-callout-emoji {
46
- padding-right: 16px;
47
- line-height: 1.6;
48
- font-size: 2rem;
50
+ padding-right: .8em;
51
+ line-height: 1.3em;
52
+ font-size: 1.2em;
49
53
  }
54
+
55
+ .kg-callout-text {
56
+ font-size: .95em;
57
+ line-height: 1.5em;
58
+ }
@@ -1,8 +1,26 @@
1
1
  .kg-toggle-card[data-kg-toggle-state="close"] .kg-toggle-content{
2
- visibility: hidden;
2
+ height: auto;
3
+ opacity: 1;
4
+ transition: opacity 1s ease, top .35s ease;
5
+ top: 0;
6
+ position: relative;
7
+ }
8
+
9
+ .kg-toggle-content {
10
+ height: 0;
11
+ overflow: hidden;
12
+ transition: opacity .5s ease, top .35s ease;
3
13
  opacity: 0;
4
- max-height: 0;
5
- padding-top: 0px;
14
+ top: -0.5em;
15
+ position: relative;
16
+ }
17
+
18
+ .kg-toggle-content p:first-of-type {
19
+ margin-top: 0.5em;
20
+ }
21
+
22
+ .kg-toggle-content p {
23
+ font-size: 0.95em;
6
24
  }
7
25
 
8
26
  .kg-toggle-card[data-kg-toggle-state="close"] svg {
@@ -13,11 +31,10 @@
13
31
  background: transparent;
14
32
  box-shadow: inset 0 0 0 1px rgba(124, 139, 154, 0.25);
15
33
  border-radius: 4px;
16
- padding: 20px;
34
+ padding: 1.2em;
17
35
  }
18
36
 
19
37
  .kg-toggle-heading {
20
- font-weight: 600;
21
38
  cursor: pointer;
22
39
  display: flex;
23
40
  justify-content: space-between;
@@ -30,29 +47,21 @@
30
47
  display: flex;
31
48
  justify-content: center;
32
49
  align-items: center;
33
- margin-left: 16px;
50
+ margin-left: 1em;
51
+ background: none;
52
+ border: 0;
34
53
  }
35
54
 
36
55
  .kg-toggle-heading svg {
37
56
  width: 14px;
38
57
  color: rgba(124, 139, 154, 0.5);
39
- transition: transform 0.3s;
58
+ transition: all 0.3s;
40
59
  transform: rotate(-180deg);
41
60
  }
42
61
 
43
62
  .kg-toggle-heading-text {
44
63
  margin-top: 0;
45
64
  margin-bottom: 0;
46
- }
47
-
48
- .kg-toggle-content {
49
- transition: all .3s;
50
- padding-top: 1.5rem;
51
- max-height: 100vh;
52
- overflow: hidden;
53
- opacity: 1;
54
- }
55
-
56
- .kg-toggle-content > *+* {
57
-
58
- }
65
+ line-height: 1.3em;
66
+ font-size: 1.1em;
67
+ }
@@ -112,7 +112,7 @@ module.exports = function setupSiteApp(options = {}) {
112
112
 
113
113
  // Card assets
114
114
  siteApp.use(mw.servePublicFile('built', 'public/cards.min.css', 'text/css', constants.ONE_YEAR_S));
115
- siteApp.use(mw.servePublicFile('built', 'public/cards.min.js', 'text/js', constants.ONE_YEAR_S));
115
+ siteApp.use(mw.servePublicFile('built', 'public/cards.min.js', 'application/javascript', constants.ONE_YEAR_S));
116
116
 
117
117
  // Serve blog images using the storage adapter
118
118
  siteApp.use(STATIC_IMAGE_URL_PREFIX, mw.handleImageSizes, storage.getStorage('images').serve());
@@ -157,6 +157,16 @@ blockquote {
157
157
  letter-spacing: -0.2px;
158
158
  }
159
159
 
160
+ blockquote.kg-blockquote-alt {
161
+ border-left: 0 none;
162
+ padding-left: 50px;
163
+ padding-right: 50px;
164
+ margin-bottom: 2.5em;
165
+ text-align: center;
166
+ font-size: 1.2em;
167
+ color: #999999;
168
+ }
169
+
160
170
  blockquote p {
161
171
  margin: 0.8em 0;
162
172
  font-size: 1em;
@@ -894,6 +904,11 @@ figure blockquote p {
894
904
  padding-left: 15px !important;
895
905
  }
896
906
 
907
+ table.body blockquote.kg-blockquote-alt {
908
+ padding-left: 50px !important;
909
+ margin-bottom: 2.5em !important;
910
+ }
911
+
897
912
  table.body blockquote + * {
898
913
  margin-top: 1.5em !important;
899
914
  }
@@ -1,6 +1,7 @@
1
1
  const errors = require('@tryghost/errors');
2
2
  const tpl = require('@tryghost/tpl');
3
3
  const logging = require('@tryghost/logging');
4
+ const sentry = require('../../shared/sentry');
4
5
  const {extract, hasProvider} = require('oembed-parser');
5
6
  const cheerio = require('cheerio');
6
7
  const _ = require('lodash');
@@ -128,7 +129,14 @@ class OEmbed {
128
129
  const response = await this.externalRequest(url, {cookieJar});
129
130
 
130
131
  const html = response.body;
131
- scraperResponse = await metascraper({html, url});
132
+ try {
133
+ scraperResponse = await metascraper({html, url});
134
+ } catch (err) {
135
+ // Log to avoid being blind to errors happenning in metascraper
136
+ sentry.captureException(err);
137
+ logging.error(err);
138
+ return this.unknownProvider(url);
139
+ }
132
140
 
133
141
  const metadata = Object.assign({}, scraperResponse, {
134
142
  thumbnail: scraperResponse.image,
@@ -41,7 +41,7 @@
41
41
 
42
42
 
43
43
  <link rel="stylesheet" href="assets/vendor.min-987af30228885bce50f05c4723fe6f53.css">
44
- <link rel="stylesheet" href="assets/ghost.min-043bb7480a0810109b130f13b2a4235e.css" title="light">
44
+ <link rel="stylesheet" href="assets/ghost.min-ee5bd95a831378b4c8ccefb37d26eac0.css" title="light">
45
45
 
46
46
 
47
47
 
@@ -59,8 +59,8 @@
59
59
  <div id="ember-basic-dropdown-wormhole"></div>
60
60
 
61
61
 
62
- <script src="assets/vendor.min-d1234c632a54502777c34e50752fa3fc.js"></script>
63
- <script src="assets/ghost.min-bc72f685c1c9adc9885925c1412435a5.js"></script>
62
+ <script src="assets/vendor.min-6fc912d1248c906f95efad2cb3eebb7d.js"></script>
63
+ <script src="assets/ghost.min-3441c3282e390002626a2dc1d7586185.js"></script>
64
64
 
65
65
  </body>
66
66
  </html>
@@ -41,7 +41,7 @@
41
41
 
42
42
 
43
43
  <link rel="stylesheet" href="assets/vendor.min-987af30228885bce50f05c4723fe6f53.css">
44
- <link rel="stylesheet" href="assets/ghost.min-043bb7480a0810109b130f13b2a4235e.css" title="light">
44
+ <link rel="stylesheet" href="assets/ghost.min-ee5bd95a831378b4c8ccefb37d26eac0.css" title="light">
45
45
 
46
46
 
47
47
 
@@ -59,8 +59,8 @@
59
59
  <div id="ember-basic-dropdown-wormhole"></div>
60
60
 
61
61
 
62
- <script src="assets/vendor.min-d1234c632a54502777c34e50752fa3fc.js"></script>
63
- <script src="assets/ghost.min-bc72f685c1c9adc9885925c1412435a5.js"></script>
62
+ <script src="assets/vendor.min-6fc912d1248c906f95efad2cb3eebb7d.js"></script>
63
+ <script src="assets/ghost.min-3441c3282e390002626a2dc1d7586185.js"></script>
64
64
 
65
65
  </body>
66
66
  </html>
@@ -40,7 +40,8 @@ const ALPHA_FEATURES = [
40
40
  'audioCard',
41
41
  'videoCard',
42
42
  'productCard',
43
- 'quoteStyles'
43
+ 'quoteStyles',
44
+ 'beforeAfterCard'
44
45
  ];
45
46
 
46
47
  module.exports.GA_KEYS = [...GA_FEATURES];
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "ghost",
3
- "version": "4.25.0",
3
+ "version": "4.25.1",
4
4
  "description": "The professional publishing platform",
5
5
  "author": "Ghost Foundation",
6
6
  "homepage": "https://ghost.org",
@@ -55,52 +55,52 @@
55
55
  "dependencies": {
56
56
  "@nexes/nql": "0.6.0",
57
57
  "@sentry/node": "6.15.0",
58
- "@tryghost/adapter-manager": "0.2.18",
58
+ "@tryghost/adapter-manager": "0.2.24",
59
59
  "@tryghost/admin-api-schema": "2.6.1",
60
- "@tryghost/bookshelf-plugins": "0.3.4",
61
- "@tryghost/bootstrap-socket": "0.2.13",
60
+ "@tryghost/bookshelf-plugins": "0.3.5",
61
+ "@tryghost/bootstrap-socket": "0.2.14",
62
62
  "@tryghost/color-utils": "0.1.5",
63
63
  "@tryghost/config-url-helpers": "0.1.3",
64
64
  "@tryghost/constants": "1.0.0",
65
65
  "@tryghost/custom-theme-settings-service": "0.3.1",
66
66
  "@tryghost/debug": "0.1.9",
67
- "@tryghost/email-analytics-provider-mailgun": "1.0.5",
68
- "@tryghost/email-analytics-service": "1.0.4",
67
+ "@tryghost/email-analytics-provider-mailgun": "1.0.6",
68
+ "@tryghost/email-analytics-service": "1.0.5",
69
69
  "@tryghost/errors": "1.0.4",
70
70
  "@tryghost/express-dynamic-redirects": "0.2.2",
71
71
  "@tryghost/helpers": "1.1.54",
72
- "@tryghost/image-transform": "1.0.18",
73
- "@tryghost/job-manager": "0.8.13",
72
+ "@tryghost/image-transform": "1.0.24",
73
+ "@tryghost/job-manager": "0.8.16",
74
74
  "@tryghost/kg-card-factory": "3.1.0",
75
75
  "@tryghost/kg-default-atoms": "3.1.0",
76
- "@tryghost/kg-default-cards": "5.9.0",
76
+ "@tryghost/kg-default-cards": "5.9.2",
77
77
  "@tryghost/kg-markdown-html-renderer": "5.1.0",
78
78
  "@tryghost/kg-mobiledoc-html-renderer": "5.3.0",
79
- "@tryghost/limit-service": "1.0.0",
80
- "@tryghost/logging": "1.0.1",
79
+ "@tryghost/limit-service": "1.0.6",
80
+ "@tryghost/logging": "1.0.2",
81
81
  "@tryghost/magic-link": "1.0.14",
82
- "@tryghost/members-api": "2.8.2",
83
- "@tryghost/members-csv": "1.1.8",
84
- "@tryghost/members-importer": "0.3.4",
82
+ "@tryghost/members-api": "2.8.4",
83
+ "@tryghost/members-csv": "1.2.0",
84
+ "@tryghost/members-importer": "0.3.5",
85
85
  "@tryghost/members-offers": "0.10.3",
86
- "@tryghost/members-ssr": "1.0.15",
86
+ "@tryghost/members-ssr": "1.0.16",
87
87
  "@tryghost/metrics": "1.0.1",
88
- "@tryghost/minifier": "0.1.1",
88
+ "@tryghost/minifier": "0.1.7",
89
89
  "@tryghost/mw-session-from-token": "0.1.26",
90
- "@tryghost/nodemailer": "0.3.7",
91
- "@tryghost/package-json": "1.0.6",
90
+ "@tryghost/nodemailer": "0.3.8",
91
+ "@tryghost/package-json": "1.0.12",
92
92
  "@tryghost/promise": "0.1.13",
93
- "@tryghost/request": "0.1.9",
93
+ "@tryghost/request": "0.1.10",
94
94
  "@tryghost/root-utils": "0.3.7",
95
95
  "@tryghost/security": "0.2.13",
96
- "@tryghost/session-service": "0.1.28",
96
+ "@tryghost/session-service": "0.1.34",
97
97
  "@tryghost/settings-path-manager": "0.1.2",
98
98
  "@tryghost/social-urls": "0.1.27",
99
99
  "@tryghost/string": "0.1.21",
100
100
  "@tryghost/tpl": "0.1.8",
101
101
  "@tryghost/update-check-service": "0.2.5",
102
102
  "@tryghost/url-utils": "2.0.4",
103
- "@tryghost/validator": "0.1.8",
103
+ "@tryghost/validator": "0.1.9",
104
104
  "@tryghost/version": "0.1.7",
105
105
  "@tryghost/vhost-middleware": "1.0.19",
106
106
  "@tryghost/zip": "1.1.18",
@@ -130,7 +130,7 @@
130
130
  "ghost-storage-base": "1.0.0",
131
131
  "glob": "7.2.0",
132
132
  "got": "9.6.0",
133
- "gscan": "4.15.0",
133
+ "gscan": "4.15.2",
134
134
  "html-to-text": "5.1.1",
135
135
  "image-size": "1.0.0",
136
136
  "intl": "1.2.5",
@@ -145,15 +145,15 @@
145
145
  "lodash": "4.17.21",
146
146
  "luxon": "2.1.1",
147
147
  "mailgun-js": "0.22.0",
148
- "metascraper": "5.25.2",
149
- "metascraper-author": "5.25.2",
150
- "metascraper-description": "5.25.2",
151
- "metascraper-image": "5.25.2",
152
- "metascraper-logo": "5.25.2",
153
- "metascraper-logo-favicon": "5.25.2",
154
- "metascraper-publisher": "5.25.2",
155
- "metascraper-title": "5.25.2",
156
- "metascraper-url": "5.25.2",
148
+ "metascraper": "5.25.4",
149
+ "metascraper-author": "5.25.4",
150
+ "metascraper-description": "5.25.4",
151
+ "metascraper-image": "5.25.4",
152
+ "metascraper-logo": "5.25.4",
153
+ "metascraper-logo-favicon": "5.25.4",
154
+ "metascraper-publisher": "5.25.4",
155
+ "metascraper-title": "5.25.4",
156
+ "metascraper-url": "5.25.4",
157
157
  "moment": "2.24.0",
158
158
  "moment-timezone": "0.5.23",
159
159
  "multer": "1.4.3",
@@ -174,7 +174,7 @@
174
174
  "xml": "1.0.1"
175
175
  },
176
176
  "optionalDependencies": {
177
- "@tryghost/html-to-mobiledoc": "1.4.0",
177
+ "@tryghost/html-to-mobiledoc": "1.4.1",
178
178
  "sqlite3": "5.0.2"
179
179
  },
180
180
  "devDependencies": {
@@ -183,7 +183,7 @@
183
183
  "coffeescript": "2.6.1",
184
184
  "cssnano": "5.0.12",
185
185
  "eslint": "7.32.0",
186
- "eslint-plugin-ghost": "2.10.0",
186
+ "eslint-plugin-ghost": "2.11.0",
187
187
  "grunt": "1.4.1",
188
188
  "grunt-bg-shell": "2.3.3",
189
189
  "grunt-contrib-clean": "2.0.0",