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

@nteract/types

Package Overview
Dependencies
Maintainers
15
Versions
59
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@nteract/types - npm Package Compare versions

Comparing version 4.1.0 to 4.2.0

9

lib/entities/contents/index.d.ts

@@ -14,2 +14,11 @@ /**

export * from "./file";
export interface AuthorObject {
name: string;
}
export interface HeaderDataProps {
authors: AuthorObject[];
description: string;
tags: string[];
title: string;
}
export declare type ContentModel = NotebookModel | DirectoryModelRecord | FileModelRecord | EmptyModelRecord;

@@ -16,0 +25,0 @@ export declare type ContentRecord = NotebookContentRecord | DummyContentRecord | FileContentRecord | DirectoryContentRecord;

/**
* @module types
*/
/**
* Description
*/
import { CellId, ImmutableCell, ImmutableNotebook } from "@nteract/commutable";
import { NotebookV4 } from "@nteract/commutable/lib/v4";
import * as Immutable from "immutable";
import { KernelRef } from "../..";
export interface BookstoreDataModel {
/**
* Basename of the entity.
*/
name: string | undefined;
/**
* Full (API-style)*def path to entity.
* def => https://jupyter-notebook.readthedocs.io/en/stable/extending/contents.html#apipaths
*/
path: string;
/**
* The entity type. One of "notebook", "file", or "directory".
*/
type: "notebook";
/**
* Creation date of the entity.
*/
created: string | undefined | null;
/**
* Last modified date of the entity.
*/
last_modified: string | undefined | null;
/**
* The "content" of the entity.
* See: https://jupyter-notebook.readthedocs.io/en/stable/extending/contents.html#filesystem-entities
*/
content: NotebookV4;
/**
* The mimetype of `content`, if any.
* See: https://jupyter-notebook.readthedocs.io/en/stable/extending/contents.html#filesystem-entities
*/
mimetype: string | undefined | null;
/**
* The format of `content`, if any.
* See: https://jupyter-notebook.readthedocs.io/en/stable/extending/contents.html#filesystem-entities
*/
format: "json";
}
export interface DocumentRecordProps {

@@ -32,4 +74,5 @@ type: "notebook";

error?: object | null;
showHeaderEditor?: boolean;
}
export declare const makeNotebookContentRecord: Immutable.Record.Factory<NotebookContentRecordProps>;
export declare type NotebookContentRecord = Immutable.RecordOf<NotebookContentRecordProps>;

9

lib/entities/contents/notebook.js
"use strict";
/**
* @module types
*/
var __importStar = (this && this.__importStar) || function (mod) {

@@ -11,4 +14,5 @@ if (mod && mod.__esModule) return mod;

/**
* @module types
* Description
*/
// Vendor modules
const commutable_1 = require("@nteract/commutable");

@@ -40,3 +44,4 @@ const Immutable = __importStar(require("immutable"));

loading: false,
error: null
error: null,
showHeaderEditor: false
});

@@ -8,2 +8,6 @@ /**

import { HostRef } from "../refs";
export interface Bookstore {
version: string;
enabled: boolean;
}
export interface ServerConfig {

@@ -16,2 +20,3 @@ endpoint: string;

type: "empty";
bookstoreEnabled?: boolean;
}

@@ -23,2 +28,4 @@ export declare type EmptyHostRecord = Immutable.RecordOf<EmptyHost>;

defaultKernelName: string;
bookstoreEnabled?: boolean;
showHeaderEditor?: boolean;
}

@@ -30,2 +37,4 @@ export declare type JupyterHostRecordProps = BaseHostProps & {

basePath: string;
bookstoreEnabled: boolean;
showHeaderEditor: boolean;
crossDomain?: boolean | null;

@@ -32,0 +41,0 @@ ajaxOptions?: Partial<AjaxRequest>;

@@ -15,3 +15,4 @@ "use strict";

exports.makeEmptyHostRecord = Immutable.Record({
type: "empty"
type: "empty",
bookstoreEnabled: false
});

@@ -27,3 +28,5 @@ exports.makeJupyterHostRecord = Immutable.Record({

ajaxOptions: undefined,
wsProtocol: undefined
wsProtocol: undefined,
bookstoreEnabled: false,
showHeaderEditor: false
});

@@ -33,3 +36,4 @@ exports.makeLocalHostRecord = Immutable.Record({

id: null,
defaultKernelName: "python"
defaultKernelName: "python",
bookstoreEnabled: false
});

@@ -36,0 +40,0 @@ exports.makeHostsRecord = Immutable.Record({

{
"name": "@nteract/types",
"version": "4.1.0",
"version": "4.2.0",
"description": "A collection of type definitions used within core nteract packages",

@@ -16,3 +16,3 @@ "main": "lib/index.js",

"dependencies": {
"@nteract/commutable": "^7.1.0",
"@nteract/commutable": "^7.1.1",
"immutable": "^4.0.0-rc.12",

@@ -22,3 +22,3 @@ "rxjs": "^6.3.3",

},
"gitHead": "f63a01c4067b05541ebddd3932345d7102ea3e5b"
"gitHead": "7ce2f58970920ef40415b992c94d48d4eb0ebfd6"
}

@@ -18,2 +18,13 @@ /**

export interface AuthorObject {
name: string;
}
export interface HeaderDataProps {
authors: AuthorObject[];
description: string;
tags: string[];
title: string;
}
export type ContentModel =

@@ -20,0 +31,0 @@ | NotebookModel

/**
* @module types
*/
/**
* Description
*/
// Vendor modules
import {

@@ -10,6 +16,49 @@ CellId,

} from "@nteract/commutable";
import { NotebookV4 } from "@nteract/commutable/lib/v4";
import * as Immutable from "immutable";
// Local modules
import { KernelRef } from "../..";
// The data model that `nteract/bookstore` accepts. For more info, see:
// https://jupyter-notebook.readthedocs.io/en/stable/extending/contents.html#data-model
export interface BookstoreDataModel {
/**
* Basename of the entity.
*/
name: string | undefined;
/**
* Full (API-style)*def path to entity.
* def => https://jupyter-notebook.readthedocs.io/en/stable/extending/contents.html#apipaths
*/
path: string;
/**
* The entity type. One of "notebook", "file", or "directory".
*/
type: "notebook";
/**
* Creation date of the entity.
*/
created: string | undefined | null;
/**
* Last modified date of the entity.
*/
last_modified: string | undefined | null;
/**
* The "content" of the entity.
* See: https://jupyter-notebook.readthedocs.io/en/stable/extending/contents.html#filesystem-entities
*/
content: NotebookV4;
/**
* The mimetype of `content`, if any.
* See: https://jupyter-notebook.readthedocs.io/en/stable/extending/contents.html#filesystem-entities
*/
mimetype: string | undefined | null;
/**
* The format of `content`, if any.
* See: https://jupyter-notebook.readthedocs.io/en/stable/extending/contents.html#filesystem-entities
*/
format: "json";
}
export interface DocumentRecordProps {

@@ -19,3 +68,4 @@ type: "notebook";

savedNotebook: ImmutableNotebook;
transient: Immutable.Map<string, any>; // has the keypaths for updating displays
// has the keypaths for updating displays
transient: Immutable.Map<string, any>;
// transient should be more fully typed (be a record itself)

@@ -30,2 +80,3 @@ // right now it's keypaths and then it looks like it's able to handle any per

}
export const makeDocumentRecord = Immutable.Record<DocumentRecordProps>({

@@ -44,2 +95,3 @@ type: "notebook",

});
export type NotebookModel = Immutable.RecordOf<DocumentRecordProps>;

@@ -59,2 +111,3 @@

error?: object | null;
showHeaderEditor?: boolean;
}

@@ -75,3 +128,4 @@

loading: false,
error: null
error: null,
showHeaderEditor: false
});

@@ -78,0 +132,0 @@

@@ -10,2 +10,7 @@ /**

export interface Bookstore {
version: string;
enabled: boolean;
}
export interface ServerConfig {

@@ -19,6 +24,8 @@ endpoint: string;

type: "empty";
bookstoreEnabled?: boolean;
}
export type EmptyHostRecord = Immutable.RecordOf<EmptyHost>;
export const makeEmptyHostRecord = Immutable.Record<EmptyHost>({
type: "empty"
type: "empty",
bookstoreEnabled: false
});

@@ -29,2 +36,4 @@

defaultKernelName: string;
bookstoreEnabled?: boolean;
showHeaderEditor?: boolean;
}

@@ -37,2 +46,4 @@

basePath: string;
bookstoreEnabled: boolean;
showHeaderEditor: boolean;
crossDomain?: boolean | null;

@@ -52,3 +63,5 @@ ajaxOptions?: Partial<AjaxRequest>;

ajaxOptions: undefined,
wsProtocol: undefined
wsProtocol: undefined,
bookstoreEnabled: false,
showHeaderEditor: false
});

@@ -65,3 +78,4 @@

id: null,
defaultKernelName: "python"
defaultKernelName: "python",
bookstoreEnabled: false
});

@@ -68,0 +82,0 @@

@@ -125,2 +125,3 @@ /**

});
export type CoreRecord = Immutable.RecordOf<StateRecordProps>;

@@ -127,0 +128,0 @@

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