Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

myst-frontmatter

Package Overview
Dependencies
Maintainers
3
Versions
78
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

myst-frontmatter - npm Package Compare versions

Comparing version 1.1.33 to 1.1.34

dist/downloads/index.d.ts

1

dist/exports/types.d.ts

@@ -17,2 +17,3 @@ export declare enum ExportFormats {

export type Export = {
id?: string;
format?: ExportFormats;

@@ -19,0 +20,0 @@ template?: string | null;

@@ -8,2 +8,3 @@ import type { ValidationOptions } from 'simple-validators';

export declare function validateExportsList(input: any, opts: ValidationOptions): Export[] | undefined;
export declare function validateExportFormat(input: any, opts: ValidationOptions): ExportFormats | undefined;
export declare function articlesWithFile(articles?: ExportArticle[]): {

@@ -10,0 +11,0 @@ file: string;

5

dist/exports/validators.js

@@ -69,3 +69,3 @@ import { defined, incrementOptions, validateBoolean, validateEnum, validateList, validateNumber, validateObjectKeys, validateString, validationError, } from 'simple-validators';

}
function validateExportFormat(input, opts) {
export function validateExportFormat(input, opts) {
if (input === undefined)

@@ -182,2 +182,5 @@ return undefined;

const validExport = { ...value, format, output, template };
if (defined(value.id)) {
validExport.id = validateString(value.id, incrementOptions('id', opts));
}
if (defined(value.zip)) {

@@ -184,0 +187,0 @@ validExport.zip = validateBoolean(value.zip, incrementOptions('zip', opts));

export * from './affiliations/index.js';
export * from './biblio/index.js';
export * from './contributors/index.js';
export * from './downloads/index.js';
export * from './exports/index.js';

@@ -5,0 +6,0 @@ export * from './funding/index.js';

export * from './affiliations/index.js';
export * from './biblio/index.js';
export * from './contributors/index.js';
export * from './downloads/index.js';
export * from './exports/index.js';

@@ -5,0 +6,0 @@ export * from './funding/index.js';

import type { Biblio } from '../biblio/types.js';
import type { Download } from '../downloads/types.js';
import type { Export } from '../exports/types.js';

@@ -30,2 +31,3 @@ import type { Licenses } from '../licenses/types.js';

exports?: Export[];
downloads?: Download[];
settings?: ProjectSettings;

@@ -32,0 +34,0 @@ };

@@ -19,2 +19,3 @@ import { SITE_FRONTMATTER_KEYS } from '../site/validators.js';

'exports',
'downloads',
'settings',

@@ -21,0 +22,0 @@ // Do not add any project specific keys here!

import { defined, filterKeys, incrementOptions, validateBoolean, validateDate, validateList, validateObject, validateObjectKeys, validateString, validateUrl, } from 'simple-validators';
import { validateBiblio } from '../biblio/validators.js';
import { validateDownloadsList } from '../downloads/validators.js';
import { validateExportsList } from '../exports/validators.js';

@@ -88,2 +89,7 @@ import { validateLicenses } from '../licenses/validators.js';

}
if (defined(value.downloads)) {
const downloads = validateDownloadsList(value.downloads, opts);
if (downloads)
output.downloads = downloads;
}
if (value.thumbnail === null) {

@@ -90,0 +96,0 @@ // It is possible for the thumbnail to explicitly be null.

@@ -11,2 +11,3 @@ import type { ValidationOptions } from 'simple-validators';

export: string;
download: string;
jupyter: string;

@@ -13,0 +14,0 @@ part: string;

@@ -37,2 +37,3 @@ import { defined, incrementOptions, validateList, validateObject, validateString, validationError, } from 'simple-validators';

export: 'exports',
download: 'downloads',
jupyter: 'thebe',

@@ -39,0 +40,0 @@ part: 'parts',

{
"name": "myst-frontmatter",
"version": "1.1.33",
"version": "1.1.34",
"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

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc