myst-frontmatter
Advanced tools
Comparing version 1.0.3 to 1.0.4
@@ -109,2 +109,4 @@ import type { CreditRole } from 'credit-roles'; | ||
short_title?: string; | ||
banner?: string | null; | ||
bannerOptimized?: string; | ||
authors?: Author[]; | ||
@@ -149,3 +151,5 @@ venue?: Venue; | ||
thumbnailOptimized?: string; | ||
banner?: string | null; | ||
bannerOptimized?: string; | ||
}; | ||
//# sourceMappingURL=types.d.ts.map |
@@ -12,2 +12,4 @@ import { doi } from 'doi-utils'; | ||
'description', | ||
'banner', | ||
'bannerOptimized', | ||
'authors', | ||
@@ -45,2 +47,4 @@ 'venue', | ||
'thumbnailOptimized', | ||
'banner', | ||
'bannerOptimized', | ||
].concat(PROJECT_FRONTMATTER_KEYS); | ||
@@ -591,2 +595,14 @@ // These keys only exist on the project. | ||
} | ||
if (value.banner === null) { | ||
// It is possible for the banner to explicitly be null. | ||
// This means not to look to the images in a page. | ||
output.banner = null; | ||
} | ||
else if (defined(value.banner)) { | ||
output.banner = validateString(value.banner, incrementOptions('banner', opts)); | ||
} | ||
if (defined(value.bannerOptimized)) { | ||
// No validation, this is expected to be set programmatically | ||
output.bannerOptimized = value.bannerOptimized; | ||
} | ||
if (defined(value.authors)) { | ||
@@ -764,2 +780,14 @@ let authors = value.authors; | ||
} | ||
if (value.banner === null) { | ||
// It is possible for the banner to explicitly be null. | ||
// This means not to look to the images in a page. | ||
output.banner = null; | ||
} | ||
else if (defined(value.banner)) { | ||
output.banner = validateString(value.banner, incrementOptions('banner', opts)); | ||
} | ||
if (defined(value.bannerOptimized)) { | ||
// No validation, this is expected to be set programmatically | ||
output.bannerOptimized = value.bannerOptimized; | ||
} | ||
return output; | ||
@@ -766,0 +794,0 @@ } |
{ | ||
"name": "myst-frontmatter", | ||
"version": "1.0.3", | ||
"version": "1.0.4", | ||
"sideEffects": false, | ||
@@ -5,0 +5,0 @@ "license": "MIT", |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
102951
3152