mirror of https://github.com/laurent22/joplin.git
Merge branch 'release-2.2' into dev
commit
11bd3d9e1f
|
@ -1,6 +1,6 @@
|
||||||
{
|
{
|
||||||
"name": "joplin",
|
"name": "joplin",
|
||||||
"version": "2.2.0",
|
"version": "2.2.1",
|
||||||
"lockfileVersion": 1,
|
"lockfileVersion": 1,
|
||||||
"requires": true,
|
"requires": true,
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
|
|
|
@ -32,7 +32,7 @@
|
||||||
],
|
],
|
||||||
"owner": "Laurent Cozic"
|
"owner": "Laurent Cozic"
|
||||||
},
|
},
|
||||||
"version": "2.2.0",
|
"version": "2.2.1",
|
||||||
"bin": {
|
"bin": {
|
||||||
"joplin": "./main.js"
|
"joplin": "./main.js"
|
||||||
},
|
},
|
||||||
|
|
|
@ -8,6 +8,8 @@ import JoplinViews from './JoplinViews';
|
||||||
import JoplinInterop from './JoplinInterop';
|
import JoplinInterop from './JoplinInterop';
|
||||||
import JoplinSettings from './JoplinSettings';
|
import JoplinSettings from './JoplinSettings';
|
||||||
import JoplinContentScripts from './JoplinContentScripts';
|
import JoplinContentScripts from './JoplinContentScripts';
|
||||||
|
import JoplinClipboard from './JoplinClipboard';
|
||||||
|
import JoplinWindow from './JoplinWindow';
|
||||||
/**
|
/**
|
||||||
* This is the main entry point to the Joplin API. You can access various services using the provided accessors.
|
* This is the main entry point to the Joplin API. You can access various services using the provided accessors.
|
||||||
*
|
*
|
||||||
|
@ -33,8 +35,12 @@ export default class Joplin {
|
||||||
private interop_;
|
private interop_;
|
||||||
private settings_;
|
private settings_;
|
||||||
private contentScripts_;
|
private contentScripts_;
|
||||||
|
private clipboard_;
|
||||||
|
private window_;
|
||||||
constructor(implementation: any, plugin: Plugin, store: any);
|
constructor(implementation: any, plugin: Plugin, store: any);
|
||||||
get data(): JoplinData;
|
get data(): JoplinData;
|
||||||
|
get clipboard(): JoplinClipboard;
|
||||||
|
get window(): JoplinWindow;
|
||||||
get plugins(): JoplinPlugins;
|
get plugins(): JoplinPlugins;
|
||||||
get workspace(): JoplinWorkspace;
|
get workspace(): JoplinWorkspace;
|
||||||
get contentScripts(): JoplinContentScripts;
|
get contentScripts(): JoplinContentScripts;
|
||||||
|
|
23
packages/app-cli/tests/support/plugins/codemirror_content_script/api/JoplinClipboard.d.ts
vendored
Normal file
23
packages/app-cli/tests/support/plugins/codemirror_content_script/api/JoplinClipboard.d.ts
vendored
Normal file
|
@ -0,0 +1,23 @@
|
||||||
|
export default class JoplinClipboard {
|
||||||
|
private electronClipboard_;
|
||||||
|
private electronNativeImage_;
|
||||||
|
constructor(electronClipboard: any, electronNativeImage: any);
|
||||||
|
readText(): Promise<string>;
|
||||||
|
writeText(text: string): Promise<void>;
|
||||||
|
readHtml(): Promise<string>;
|
||||||
|
writeHtml(html: string): Promise<void>;
|
||||||
|
/**
|
||||||
|
* Returns the image in [data URL](https://developer.mozilla.org/en-US/docs/Web/HTTP/Basics_of_HTTP/Data_URIs) format.
|
||||||
|
*/
|
||||||
|
readImage(): Promise<string>;
|
||||||
|
/**
|
||||||
|
* Takes an image in [data URL](https://developer.mozilla.org/en-US/docs/Web/HTTP/Basics_of_HTTP/Data_URIs) format.
|
||||||
|
*/
|
||||||
|
writeImage(dataUrl: string): Promise<void>;
|
||||||
|
/**
|
||||||
|
* Returns the list available formats (mime types).
|
||||||
|
*
|
||||||
|
* For example [ 'text/plain', 'text/html' ]
|
||||||
|
*/
|
||||||
|
availableFormats(): Promise<string[]>;
|
||||||
|
}
|
|
@ -2,7 +2,7 @@ import Plugin from '../Plugin';
|
||||||
import { ButtonSpec, ViewHandle, DialogResult } from './types';
|
import { ButtonSpec, ViewHandle, DialogResult } from './types';
|
||||||
/**
|
/**
|
||||||
* Allows creating and managing dialogs. A dialog is modal window that
|
* Allows creating and managing dialogs. A dialog is modal window that
|
||||||
* contains a webview and a row of buttons. You can update the update the
|
* contains a webview and a row of buttons. You can update the
|
||||||
* webview using the `setHtml` method. Dialogs are hidden by default and
|
* webview using the `setHtml` method. Dialogs are hidden by default and
|
||||||
* you need to call `open()` to open them. Once the user clicks on a
|
* you need to call `open()` to open them. Once the user clicks on a
|
||||||
* button, the `open` call will return an object indicating what button was
|
* button, the `open` call will return an object indicating what button was
|
||||||
|
@ -59,4 +59,11 @@ export default class JoplinViewsDialogs {
|
||||||
* Opens the dialog
|
* Opens the dialog
|
||||||
*/
|
*/
|
||||||
open(handle: ViewHandle): Promise<DialogResult>;
|
open(handle: ViewHandle): Promise<DialogResult>;
|
||||||
|
/**
|
||||||
|
* Toggle on whether to fit the dialog size to the content or not.
|
||||||
|
* When set to false, the dialog stretches to fill the application
|
||||||
|
* window.
|
||||||
|
* @default true
|
||||||
|
*/
|
||||||
|
setFitToContent(handle: ViewHandle, status: boolean): Promise<boolean>;
|
||||||
}
|
}
|
||||||
|
|
24
packages/app-cli/tests/support/plugins/codemirror_content_script/api/JoplinWindow.d.ts
vendored
Normal file
24
packages/app-cli/tests/support/plugins/codemirror_content_script/api/JoplinWindow.d.ts
vendored
Normal file
|
@ -0,0 +1,24 @@
|
||||||
|
import Plugin from '../Plugin';
|
||||||
|
export interface Implementation {
|
||||||
|
injectCustomStyles(elementId: string, cssFilePath: string): Promise<void>;
|
||||||
|
}
|
||||||
|
export default class JoplinWindow {
|
||||||
|
private plugin_;
|
||||||
|
private store_;
|
||||||
|
private implementation_;
|
||||||
|
constructor(implementation: Implementation, plugin: Plugin, store: any);
|
||||||
|
/**
|
||||||
|
* Loads a chrome CSS file. It will apply to the window UI elements, except
|
||||||
|
* for the note viewer. It is the same as the "Custom stylesheet for
|
||||||
|
* Joplin-wide app styles" setting. See the [Load CSS Demo](https://github.com/laurent22/joplin/tree/dev/packages/app-cli/tests/support/plugins/load_css)
|
||||||
|
* for an example.
|
||||||
|
*/
|
||||||
|
loadChromeCssFile(filePath: string): Promise<void>;
|
||||||
|
/**
|
||||||
|
* Loads a note CSS file. It will apply to the note viewer, as well as any
|
||||||
|
* exported or printed note. It is the same as the "Custom stylesheet for
|
||||||
|
* rendered Markdown" setting. See the [Load CSS Demo](https://github.com/laurent22/joplin/tree/dev/packages/app-cli/tests/support/plugins/load_css)
|
||||||
|
* for an example.
|
||||||
|
*/
|
||||||
|
loadNoteCssFile(filePath: string): Promise<void>;
|
||||||
|
}
|
|
@ -334,6 +334,17 @@ export enum SettingItemType {
|
||||||
Button = 6,
|
Button = 6,
|
||||||
}
|
}
|
||||||
|
|
||||||
|
export enum AppType {
|
||||||
|
Desktop = 'desktop',
|
||||||
|
Mobile = 'mobile',
|
||||||
|
Cli = 'cli',
|
||||||
|
}
|
||||||
|
|
||||||
|
export enum SettingStorage {
|
||||||
|
Database = 1,
|
||||||
|
File = 2,
|
||||||
|
}
|
||||||
|
|
||||||
// Redefine a simplified interface to mask internal details
|
// Redefine a simplified interface to mask internal details
|
||||||
// and to remove function calls as they would have to be async.
|
// and to remove function calls as they would have to be async.
|
||||||
export interface SettingItem {
|
export interface SettingItem {
|
||||||
|
@ -372,7 +383,7 @@ export interface SettingItem {
|
||||||
/**
|
/**
|
||||||
* Reserved property. Not used at the moment.
|
* Reserved property. Not used at the moment.
|
||||||
*/
|
*/
|
||||||
appTypes?: string[];
|
appTypes?: AppType[];
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Set this to `true` to store secure data, such as passwords. Any such
|
* Set this to `true` to store secure data, such as passwords. Any such
|
||||||
|
@ -393,6 +404,11 @@ export interface SettingItem {
|
||||||
minimum?: number;
|
minimum?: number;
|
||||||
maximum?: number;
|
maximum?: number;
|
||||||
step?: number;
|
step?: number;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Either store the setting in the database or in settings.json. Defaults to database.
|
||||||
|
*/
|
||||||
|
storage?: SettingStorage;
|
||||||
}
|
}
|
||||||
|
|
||||||
export interface SettingSection {
|
export interface SettingSection {
|
||||||
|
@ -419,7 +435,7 @@ export type Path = string[];
|
||||||
// Content Script types
|
// Content Script types
|
||||||
// =================================================================
|
// =================================================================
|
||||||
|
|
||||||
export type PostMessageHandler = (id: string, message: any)=> Promise<any>;
|
export type PostMessageHandler = (message: any)=> Promise<any>;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* When a content script is initialised, it receives a `context` object.
|
* When a content script is initialised, it receives a `context` object.
|
||||||
|
|
|
@ -8,6 +8,8 @@ import JoplinViews from './JoplinViews';
|
||||||
import JoplinInterop from './JoplinInterop';
|
import JoplinInterop from './JoplinInterop';
|
||||||
import JoplinSettings from './JoplinSettings';
|
import JoplinSettings from './JoplinSettings';
|
||||||
import JoplinContentScripts from './JoplinContentScripts';
|
import JoplinContentScripts from './JoplinContentScripts';
|
||||||
|
import JoplinClipboard from './JoplinClipboard';
|
||||||
|
import JoplinWindow from './JoplinWindow';
|
||||||
/**
|
/**
|
||||||
* This is the main entry point to the Joplin API. You can access various services using the provided accessors.
|
* This is the main entry point to the Joplin API. You can access various services using the provided accessors.
|
||||||
*
|
*
|
||||||
|
@ -33,8 +35,12 @@ export default class Joplin {
|
||||||
private interop_;
|
private interop_;
|
||||||
private settings_;
|
private settings_;
|
||||||
private contentScripts_;
|
private contentScripts_;
|
||||||
|
private clipboard_;
|
||||||
|
private window_;
|
||||||
constructor(implementation: any, plugin: Plugin, store: any);
|
constructor(implementation: any, plugin: Plugin, store: any);
|
||||||
get data(): JoplinData;
|
get data(): JoplinData;
|
||||||
|
get clipboard(): JoplinClipboard;
|
||||||
|
get window(): JoplinWindow;
|
||||||
get plugins(): JoplinPlugins;
|
get plugins(): JoplinPlugins;
|
||||||
get workspace(): JoplinWorkspace;
|
get workspace(): JoplinWorkspace;
|
||||||
get contentScripts(): JoplinContentScripts;
|
get contentScripts(): JoplinContentScripts;
|
||||||
|
|
23
packages/app-cli/tests/support/plugins/content_script/api/JoplinClipboard.d.ts
vendored
Normal file
23
packages/app-cli/tests/support/plugins/content_script/api/JoplinClipboard.d.ts
vendored
Normal file
|
@ -0,0 +1,23 @@
|
||||||
|
export default class JoplinClipboard {
|
||||||
|
private electronClipboard_;
|
||||||
|
private electronNativeImage_;
|
||||||
|
constructor(electronClipboard: any, electronNativeImage: any);
|
||||||
|
readText(): Promise<string>;
|
||||||
|
writeText(text: string): Promise<void>;
|
||||||
|
readHtml(): Promise<string>;
|
||||||
|
writeHtml(html: string): Promise<void>;
|
||||||
|
/**
|
||||||
|
* Returns the image in [data URL](https://developer.mozilla.org/en-US/docs/Web/HTTP/Basics_of_HTTP/Data_URIs) format.
|
||||||
|
*/
|
||||||
|
readImage(): Promise<string>;
|
||||||
|
/**
|
||||||
|
* Takes an image in [data URL](https://developer.mozilla.org/en-US/docs/Web/HTTP/Basics_of_HTTP/Data_URIs) format.
|
||||||
|
*/
|
||||||
|
writeImage(dataUrl: string): Promise<void>;
|
||||||
|
/**
|
||||||
|
* Returns the list available formats (mime types).
|
||||||
|
*
|
||||||
|
* For example [ 'text/plain', 'text/html' ]
|
||||||
|
*/
|
||||||
|
availableFormats(): Promise<string[]>;
|
||||||
|
}
|
|
@ -2,7 +2,7 @@ import Plugin from '../Plugin';
|
||||||
import { ButtonSpec, ViewHandle, DialogResult } from './types';
|
import { ButtonSpec, ViewHandle, DialogResult } from './types';
|
||||||
/**
|
/**
|
||||||
* Allows creating and managing dialogs. A dialog is modal window that
|
* Allows creating and managing dialogs. A dialog is modal window that
|
||||||
* contains a webview and a row of buttons. You can update the update the
|
* contains a webview and a row of buttons. You can update the
|
||||||
* webview using the `setHtml` method. Dialogs are hidden by default and
|
* webview using the `setHtml` method. Dialogs are hidden by default and
|
||||||
* you need to call `open()` to open them. Once the user clicks on a
|
* you need to call `open()` to open them. Once the user clicks on a
|
||||||
* button, the `open` call will return an object indicating what button was
|
* button, the `open` call will return an object indicating what button was
|
||||||
|
@ -59,4 +59,11 @@ export default class JoplinViewsDialogs {
|
||||||
* Opens the dialog
|
* Opens the dialog
|
||||||
*/
|
*/
|
||||||
open(handle: ViewHandle): Promise<DialogResult>;
|
open(handle: ViewHandle): Promise<DialogResult>;
|
||||||
|
/**
|
||||||
|
* Toggle on whether to fit the dialog size to the content or not.
|
||||||
|
* When set to false, the dialog stretches to fill the application
|
||||||
|
* window.
|
||||||
|
* @default true
|
||||||
|
*/
|
||||||
|
setFitToContent(handle: ViewHandle, status: boolean): Promise<boolean>;
|
||||||
}
|
}
|
||||||
|
|
|
@ -0,0 +1,24 @@
|
||||||
|
import Plugin from '../Plugin';
|
||||||
|
export interface Implementation {
|
||||||
|
injectCustomStyles(elementId: string, cssFilePath: string): Promise<void>;
|
||||||
|
}
|
||||||
|
export default class JoplinWindow {
|
||||||
|
private plugin_;
|
||||||
|
private store_;
|
||||||
|
private implementation_;
|
||||||
|
constructor(implementation: Implementation, plugin: Plugin, store: any);
|
||||||
|
/**
|
||||||
|
* Loads a chrome CSS file. It will apply to the window UI elements, except
|
||||||
|
* for the note viewer. It is the same as the "Custom stylesheet for
|
||||||
|
* Joplin-wide app styles" setting. See the [Load CSS Demo](https://github.com/laurent22/joplin/tree/dev/packages/app-cli/tests/support/plugins/load_css)
|
||||||
|
* for an example.
|
||||||
|
*/
|
||||||
|
loadChromeCssFile(filePath: string): Promise<void>;
|
||||||
|
/**
|
||||||
|
* Loads a note CSS file. It will apply to the note viewer, as well as any
|
||||||
|
* exported or printed note. It is the same as the "Custom stylesheet for
|
||||||
|
* rendered Markdown" setting. See the [Load CSS Demo](https://github.com/laurent22/joplin/tree/dev/packages/app-cli/tests/support/plugins/load_css)
|
||||||
|
* for an example.
|
||||||
|
*/
|
||||||
|
loadNoteCssFile(filePath: string): Promise<void>;
|
||||||
|
}
|
|
@ -334,6 +334,17 @@ export enum SettingItemType {
|
||||||
Button = 6,
|
Button = 6,
|
||||||
}
|
}
|
||||||
|
|
||||||
|
export enum AppType {
|
||||||
|
Desktop = 'desktop',
|
||||||
|
Mobile = 'mobile',
|
||||||
|
Cli = 'cli',
|
||||||
|
}
|
||||||
|
|
||||||
|
export enum SettingStorage {
|
||||||
|
Database = 1,
|
||||||
|
File = 2,
|
||||||
|
}
|
||||||
|
|
||||||
// Redefine a simplified interface to mask internal details
|
// Redefine a simplified interface to mask internal details
|
||||||
// and to remove function calls as they would have to be async.
|
// and to remove function calls as they would have to be async.
|
||||||
export interface SettingItem {
|
export interface SettingItem {
|
||||||
|
@ -372,7 +383,7 @@ export interface SettingItem {
|
||||||
/**
|
/**
|
||||||
* Reserved property. Not used at the moment.
|
* Reserved property. Not used at the moment.
|
||||||
*/
|
*/
|
||||||
appTypes?: string[];
|
appTypes?: AppType[];
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Set this to `true` to store secure data, such as passwords. Any such
|
* Set this to `true` to store secure data, such as passwords. Any such
|
||||||
|
@ -393,6 +404,11 @@ export interface SettingItem {
|
||||||
minimum?: number;
|
minimum?: number;
|
||||||
maximum?: number;
|
maximum?: number;
|
||||||
step?: number;
|
step?: number;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Either store the setting in the database or in settings.json. Defaults to database.
|
||||||
|
*/
|
||||||
|
storage?: SettingStorage;
|
||||||
}
|
}
|
||||||
|
|
||||||
export interface SettingSection {
|
export interface SettingSection {
|
||||||
|
@ -419,7 +435,7 @@ export type Path = string[];
|
||||||
// Content Script types
|
// Content Script types
|
||||||
// =================================================================
|
// =================================================================
|
||||||
|
|
||||||
export type PostMessageHandler = (id: string, message: any)=> Promise<any>;
|
export type PostMessageHandler = (message: any)=> Promise<any>;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* When a content script is initialised, it receives a `context` object.
|
* When a content script is initialised, it receives a `context` object.
|
||||||
|
|
|
@ -8,6 +8,8 @@ import JoplinViews from './JoplinViews';
|
||||||
import JoplinInterop from './JoplinInterop';
|
import JoplinInterop from './JoplinInterop';
|
||||||
import JoplinSettings from './JoplinSettings';
|
import JoplinSettings from './JoplinSettings';
|
||||||
import JoplinContentScripts from './JoplinContentScripts';
|
import JoplinContentScripts from './JoplinContentScripts';
|
||||||
|
import JoplinClipboard from './JoplinClipboard';
|
||||||
|
import JoplinWindow from './JoplinWindow';
|
||||||
/**
|
/**
|
||||||
* This is the main entry point to the Joplin API. You can access various services using the provided accessors.
|
* This is the main entry point to the Joplin API. You can access various services using the provided accessors.
|
||||||
*
|
*
|
||||||
|
@ -33,8 +35,12 @@ export default class Joplin {
|
||||||
private interop_;
|
private interop_;
|
||||||
private settings_;
|
private settings_;
|
||||||
private contentScripts_;
|
private contentScripts_;
|
||||||
|
private clipboard_;
|
||||||
|
private window_;
|
||||||
constructor(implementation: any, plugin: Plugin, store: any);
|
constructor(implementation: any, plugin: Plugin, store: any);
|
||||||
get data(): JoplinData;
|
get data(): JoplinData;
|
||||||
|
get clipboard(): JoplinClipboard;
|
||||||
|
get window(): JoplinWindow;
|
||||||
get plugins(): JoplinPlugins;
|
get plugins(): JoplinPlugins;
|
||||||
get workspace(): JoplinWorkspace;
|
get workspace(): JoplinWorkspace;
|
||||||
get contentScripts(): JoplinContentScripts;
|
get contentScripts(): JoplinContentScripts;
|
||||||
|
|
|
@ -0,0 +1,23 @@
|
||||||
|
export default class JoplinClipboard {
|
||||||
|
private electronClipboard_;
|
||||||
|
private electronNativeImage_;
|
||||||
|
constructor(electronClipboard: any, electronNativeImage: any);
|
||||||
|
readText(): Promise<string>;
|
||||||
|
writeText(text: string): Promise<void>;
|
||||||
|
readHtml(): Promise<string>;
|
||||||
|
writeHtml(html: string): Promise<void>;
|
||||||
|
/**
|
||||||
|
* Returns the image in [data URL](https://developer.mozilla.org/en-US/docs/Web/HTTP/Basics_of_HTTP/Data_URIs) format.
|
||||||
|
*/
|
||||||
|
readImage(): Promise<string>;
|
||||||
|
/**
|
||||||
|
* Takes an image in [data URL](https://developer.mozilla.org/en-US/docs/Web/HTTP/Basics_of_HTTP/Data_URIs) format.
|
||||||
|
*/
|
||||||
|
writeImage(dataUrl: string): Promise<void>;
|
||||||
|
/**
|
||||||
|
* Returns the list available formats (mime types).
|
||||||
|
*
|
||||||
|
* For example [ 'text/plain', 'text/html' ]
|
||||||
|
*/
|
||||||
|
availableFormats(): Promise<string[]>;
|
||||||
|
}
|
|
@ -2,7 +2,7 @@ import Plugin from '../Plugin';
|
||||||
import { ButtonSpec, ViewHandle, DialogResult } from './types';
|
import { ButtonSpec, ViewHandle, DialogResult } from './types';
|
||||||
/**
|
/**
|
||||||
* Allows creating and managing dialogs. A dialog is modal window that
|
* Allows creating and managing dialogs. A dialog is modal window that
|
||||||
* contains a webview and a row of buttons. You can update the update the
|
* contains a webview and a row of buttons. You can update the
|
||||||
* webview using the `setHtml` method. Dialogs are hidden by default and
|
* webview using the `setHtml` method. Dialogs are hidden by default and
|
||||||
* you need to call `open()` to open them. Once the user clicks on a
|
* you need to call `open()` to open them. Once the user clicks on a
|
||||||
* button, the `open` call will return an object indicating what button was
|
* button, the `open` call will return an object indicating what button was
|
||||||
|
@ -59,4 +59,11 @@ export default class JoplinViewsDialogs {
|
||||||
* Opens the dialog
|
* Opens the dialog
|
||||||
*/
|
*/
|
||||||
open(handle: ViewHandle): Promise<DialogResult>;
|
open(handle: ViewHandle): Promise<DialogResult>;
|
||||||
|
/**
|
||||||
|
* Toggle on whether to fit the dialog size to the content or not.
|
||||||
|
* When set to false, the dialog stretches to fill the application
|
||||||
|
* window.
|
||||||
|
* @default true
|
||||||
|
*/
|
||||||
|
setFitToContent(handle: ViewHandle, status: boolean): Promise<boolean>;
|
||||||
}
|
}
|
||||||
|
|
|
@ -0,0 +1,24 @@
|
||||||
|
import Plugin from '../Plugin';
|
||||||
|
export interface Implementation {
|
||||||
|
injectCustomStyles(elementId: string, cssFilePath: string): Promise<void>;
|
||||||
|
}
|
||||||
|
export default class JoplinWindow {
|
||||||
|
private plugin_;
|
||||||
|
private store_;
|
||||||
|
private implementation_;
|
||||||
|
constructor(implementation: Implementation, plugin: Plugin, store: any);
|
||||||
|
/**
|
||||||
|
* Loads a chrome CSS file. It will apply to the window UI elements, except
|
||||||
|
* for the note viewer. It is the same as the "Custom stylesheet for
|
||||||
|
* Joplin-wide app styles" setting. See the [Load CSS Demo](https://github.com/laurent22/joplin/tree/dev/packages/app-cli/tests/support/plugins/load_css)
|
||||||
|
* for an example.
|
||||||
|
*/
|
||||||
|
loadChromeCssFile(filePath: string): Promise<void>;
|
||||||
|
/**
|
||||||
|
* Loads a note CSS file. It will apply to the note viewer, as well as any
|
||||||
|
* exported or printed note. It is the same as the "Custom stylesheet for
|
||||||
|
* rendered Markdown" setting. See the [Load CSS Demo](https://github.com/laurent22/joplin/tree/dev/packages/app-cli/tests/support/plugins/load_css)
|
||||||
|
* for an example.
|
||||||
|
*/
|
||||||
|
loadNoteCssFile(filePath: string): Promise<void>;
|
||||||
|
}
|
|
@ -334,6 +334,17 @@ export enum SettingItemType {
|
||||||
Button = 6,
|
Button = 6,
|
||||||
}
|
}
|
||||||
|
|
||||||
|
export enum AppType {
|
||||||
|
Desktop = 'desktop',
|
||||||
|
Mobile = 'mobile',
|
||||||
|
Cli = 'cli',
|
||||||
|
}
|
||||||
|
|
||||||
|
export enum SettingStorage {
|
||||||
|
Database = 1,
|
||||||
|
File = 2,
|
||||||
|
}
|
||||||
|
|
||||||
// Redefine a simplified interface to mask internal details
|
// Redefine a simplified interface to mask internal details
|
||||||
// and to remove function calls as they would have to be async.
|
// and to remove function calls as they would have to be async.
|
||||||
export interface SettingItem {
|
export interface SettingItem {
|
||||||
|
@ -372,7 +383,7 @@ export interface SettingItem {
|
||||||
/**
|
/**
|
||||||
* Reserved property. Not used at the moment.
|
* Reserved property. Not used at the moment.
|
||||||
*/
|
*/
|
||||||
appTypes?: string[];
|
appTypes?: AppType[];
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Set this to `true` to store secure data, such as passwords. Any such
|
* Set this to `true` to store secure data, such as passwords. Any such
|
||||||
|
@ -393,6 +404,11 @@ export interface SettingItem {
|
||||||
minimum?: number;
|
minimum?: number;
|
||||||
maximum?: number;
|
maximum?: number;
|
||||||
step?: number;
|
step?: number;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Either store the setting in the database or in settings.json. Defaults to database.
|
||||||
|
*/
|
||||||
|
storage?: SettingStorage;
|
||||||
}
|
}
|
||||||
|
|
||||||
export interface SettingSection {
|
export interface SettingSection {
|
||||||
|
@ -419,7 +435,7 @@ export type Path = string[];
|
||||||
// Content Script types
|
// Content Script types
|
||||||
// =================================================================
|
// =================================================================
|
||||||
|
|
||||||
export type PostMessageHandler = (id: string, message: any)=> Promise<any>;
|
export type PostMessageHandler = (message: any)=> Promise<any>;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* When a content script is initialised, it receives a `context` object.
|
* When a content script is initialised, it receives a `context` object.
|
||||||
|
|
|
@ -8,6 +8,8 @@ import JoplinViews from './JoplinViews';
|
||||||
import JoplinInterop from './JoplinInterop';
|
import JoplinInterop from './JoplinInterop';
|
||||||
import JoplinSettings from './JoplinSettings';
|
import JoplinSettings from './JoplinSettings';
|
||||||
import JoplinContentScripts from './JoplinContentScripts';
|
import JoplinContentScripts from './JoplinContentScripts';
|
||||||
|
import JoplinClipboard from './JoplinClipboard';
|
||||||
|
import JoplinWindow from './JoplinWindow';
|
||||||
/**
|
/**
|
||||||
* This is the main entry point to the Joplin API. You can access various services using the provided accessors.
|
* This is the main entry point to the Joplin API. You can access various services using the provided accessors.
|
||||||
*
|
*
|
||||||
|
@ -33,8 +35,12 @@ export default class Joplin {
|
||||||
private interop_;
|
private interop_;
|
||||||
private settings_;
|
private settings_;
|
||||||
private contentScripts_;
|
private contentScripts_;
|
||||||
|
private clipboard_;
|
||||||
|
private window_;
|
||||||
constructor(implementation: any, plugin: Plugin, store: any);
|
constructor(implementation: any, plugin: Plugin, store: any);
|
||||||
get data(): JoplinData;
|
get data(): JoplinData;
|
||||||
|
get clipboard(): JoplinClipboard;
|
||||||
|
get window(): JoplinWindow;
|
||||||
get plugins(): JoplinPlugins;
|
get plugins(): JoplinPlugins;
|
||||||
get workspace(): JoplinWorkspace;
|
get workspace(): JoplinWorkspace;
|
||||||
get contentScripts(): JoplinContentScripts;
|
get contentScripts(): JoplinContentScripts;
|
||||||
|
|
23
packages/app-cli/tests/support/plugins/editor_context_menu/api/JoplinClipboard.d.ts
vendored
Normal file
23
packages/app-cli/tests/support/plugins/editor_context_menu/api/JoplinClipboard.d.ts
vendored
Normal file
|
@ -0,0 +1,23 @@
|
||||||
|
export default class JoplinClipboard {
|
||||||
|
private electronClipboard_;
|
||||||
|
private electronNativeImage_;
|
||||||
|
constructor(electronClipboard: any, electronNativeImage: any);
|
||||||
|
readText(): Promise<string>;
|
||||||
|
writeText(text: string): Promise<void>;
|
||||||
|
readHtml(): Promise<string>;
|
||||||
|
writeHtml(html: string): Promise<void>;
|
||||||
|
/**
|
||||||
|
* Returns the image in [data URL](https://developer.mozilla.org/en-US/docs/Web/HTTP/Basics_of_HTTP/Data_URIs) format.
|
||||||
|
*/
|
||||||
|
readImage(): Promise<string>;
|
||||||
|
/**
|
||||||
|
* Takes an image in [data URL](https://developer.mozilla.org/en-US/docs/Web/HTTP/Basics_of_HTTP/Data_URIs) format.
|
||||||
|
*/
|
||||||
|
writeImage(dataUrl: string): Promise<void>;
|
||||||
|
/**
|
||||||
|
* Returns the list available formats (mime types).
|
||||||
|
*
|
||||||
|
* For example [ 'text/plain', 'text/html' ]
|
||||||
|
*/
|
||||||
|
availableFormats(): Promise<string[]>;
|
||||||
|
}
|
|
@ -2,7 +2,7 @@ import Plugin from '../Plugin';
|
||||||
import { ButtonSpec, ViewHandle, DialogResult } from './types';
|
import { ButtonSpec, ViewHandle, DialogResult } from './types';
|
||||||
/**
|
/**
|
||||||
* Allows creating and managing dialogs. A dialog is modal window that
|
* Allows creating and managing dialogs. A dialog is modal window that
|
||||||
* contains a webview and a row of buttons. You can update the update the
|
* contains a webview and a row of buttons. You can update the
|
||||||
* webview using the `setHtml` method. Dialogs are hidden by default and
|
* webview using the `setHtml` method. Dialogs are hidden by default and
|
||||||
* you need to call `open()` to open them. Once the user clicks on a
|
* you need to call `open()` to open them. Once the user clicks on a
|
||||||
* button, the `open` call will return an object indicating what button was
|
* button, the `open` call will return an object indicating what button was
|
||||||
|
@ -59,4 +59,11 @@ export default class JoplinViewsDialogs {
|
||||||
* Opens the dialog
|
* Opens the dialog
|
||||||
*/
|
*/
|
||||||
open(handle: ViewHandle): Promise<DialogResult>;
|
open(handle: ViewHandle): Promise<DialogResult>;
|
||||||
|
/**
|
||||||
|
* Toggle on whether to fit the dialog size to the content or not.
|
||||||
|
* When set to false, the dialog stretches to fill the application
|
||||||
|
* window.
|
||||||
|
* @default true
|
||||||
|
*/
|
||||||
|
setFitToContent(handle: ViewHandle, status: boolean): Promise<boolean>;
|
||||||
}
|
}
|
||||||
|
|
24
packages/app-cli/tests/support/plugins/editor_context_menu/api/JoplinWindow.d.ts
vendored
Normal file
24
packages/app-cli/tests/support/plugins/editor_context_menu/api/JoplinWindow.d.ts
vendored
Normal file
|
@ -0,0 +1,24 @@
|
||||||
|
import Plugin from '../Plugin';
|
||||||
|
export interface Implementation {
|
||||||
|
injectCustomStyles(elementId: string, cssFilePath: string): Promise<void>;
|
||||||
|
}
|
||||||
|
export default class JoplinWindow {
|
||||||
|
private plugin_;
|
||||||
|
private store_;
|
||||||
|
private implementation_;
|
||||||
|
constructor(implementation: Implementation, plugin: Plugin, store: any);
|
||||||
|
/**
|
||||||
|
* Loads a chrome CSS file. It will apply to the window UI elements, except
|
||||||
|
* for the note viewer. It is the same as the "Custom stylesheet for
|
||||||
|
* Joplin-wide app styles" setting. See the [Load CSS Demo](https://github.com/laurent22/joplin/tree/dev/packages/app-cli/tests/support/plugins/load_css)
|
||||||
|
* for an example.
|
||||||
|
*/
|
||||||
|
loadChromeCssFile(filePath: string): Promise<void>;
|
||||||
|
/**
|
||||||
|
* Loads a note CSS file. It will apply to the note viewer, as well as any
|
||||||
|
* exported or printed note. It is the same as the "Custom stylesheet for
|
||||||
|
* rendered Markdown" setting. See the [Load CSS Demo](https://github.com/laurent22/joplin/tree/dev/packages/app-cli/tests/support/plugins/load_css)
|
||||||
|
* for an example.
|
||||||
|
*/
|
||||||
|
loadNoteCssFile(filePath: string): Promise<void>;
|
||||||
|
}
|
|
@ -334,6 +334,17 @@ export enum SettingItemType {
|
||||||
Button = 6,
|
Button = 6,
|
||||||
}
|
}
|
||||||
|
|
||||||
|
export enum AppType {
|
||||||
|
Desktop = 'desktop',
|
||||||
|
Mobile = 'mobile',
|
||||||
|
Cli = 'cli',
|
||||||
|
}
|
||||||
|
|
||||||
|
export enum SettingStorage {
|
||||||
|
Database = 1,
|
||||||
|
File = 2,
|
||||||
|
}
|
||||||
|
|
||||||
// Redefine a simplified interface to mask internal details
|
// Redefine a simplified interface to mask internal details
|
||||||
// and to remove function calls as they would have to be async.
|
// and to remove function calls as they would have to be async.
|
||||||
export interface SettingItem {
|
export interface SettingItem {
|
||||||
|
@ -372,7 +383,7 @@ export interface SettingItem {
|
||||||
/**
|
/**
|
||||||
* Reserved property. Not used at the moment.
|
* Reserved property. Not used at the moment.
|
||||||
*/
|
*/
|
||||||
appTypes?: string[];
|
appTypes?: AppType[];
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Set this to `true` to store secure data, such as passwords. Any such
|
* Set this to `true` to store secure data, such as passwords. Any such
|
||||||
|
@ -393,6 +404,11 @@ export interface SettingItem {
|
||||||
minimum?: number;
|
minimum?: number;
|
||||||
maximum?: number;
|
maximum?: number;
|
||||||
step?: number;
|
step?: number;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Either store the setting in the database or in settings.json. Defaults to database.
|
||||||
|
*/
|
||||||
|
storage?: SettingStorage;
|
||||||
}
|
}
|
||||||
|
|
||||||
export interface SettingSection {
|
export interface SettingSection {
|
||||||
|
@ -419,7 +435,7 @@ export type Path = string[];
|
||||||
// Content Script types
|
// Content Script types
|
||||||
// =================================================================
|
// =================================================================
|
||||||
|
|
||||||
export type PostMessageHandler = (id: string, message: any)=> Promise<any>;
|
export type PostMessageHandler = (message: any)=> Promise<any>;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* When a content script is initialised, it receives a `context` object.
|
* When a content script is initialised, it receives a `context` object.
|
||||||
|
|
|
@ -8,6 +8,8 @@ import JoplinViews from './JoplinViews';
|
||||||
import JoplinInterop from './JoplinInterop';
|
import JoplinInterop from './JoplinInterop';
|
||||||
import JoplinSettings from './JoplinSettings';
|
import JoplinSettings from './JoplinSettings';
|
||||||
import JoplinContentScripts from './JoplinContentScripts';
|
import JoplinContentScripts from './JoplinContentScripts';
|
||||||
|
import JoplinClipboard from './JoplinClipboard';
|
||||||
|
import JoplinWindow from './JoplinWindow';
|
||||||
/**
|
/**
|
||||||
* This is the main entry point to the Joplin API. You can access various services using the provided accessors.
|
* This is the main entry point to the Joplin API. You can access various services using the provided accessors.
|
||||||
*
|
*
|
||||||
|
@ -33,8 +35,12 @@ export default class Joplin {
|
||||||
private interop_;
|
private interop_;
|
||||||
private settings_;
|
private settings_;
|
||||||
private contentScripts_;
|
private contentScripts_;
|
||||||
|
private clipboard_;
|
||||||
|
private window_;
|
||||||
constructor(implementation: any, plugin: Plugin, store: any);
|
constructor(implementation: any, plugin: Plugin, store: any);
|
||||||
get data(): JoplinData;
|
get data(): JoplinData;
|
||||||
|
get clipboard(): JoplinClipboard;
|
||||||
|
get window(): JoplinWindow;
|
||||||
get plugins(): JoplinPlugins;
|
get plugins(): JoplinPlugins;
|
||||||
get workspace(): JoplinWorkspace;
|
get workspace(): JoplinWorkspace;
|
||||||
get contentScripts(): JoplinContentScripts;
|
get contentScripts(): JoplinContentScripts;
|
||||||
|
|
|
@ -0,0 +1,23 @@
|
||||||
|
export default class JoplinClipboard {
|
||||||
|
private electronClipboard_;
|
||||||
|
private electronNativeImage_;
|
||||||
|
constructor(electronClipboard: any, electronNativeImage: any);
|
||||||
|
readText(): Promise<string>;
|
||||||
|
writeText(text: string): Promise<void>;
|
||||||
|
readHtml(): Promise<string>;
|
||||||
|
writeHtml(html: string): Promise<void>;
|
||||||
|
/**
|
||||||
|
* Returns the image in [data URL](https://developer.mozilla.org/en-US/docs/Web/HTTP/Basics_of_HTTP/Data_URIs) format.
|
||||||
|
*/
|
||||||
|
readImage(): Promise<string>;
|
||||||
|
/**
|
||||||
|
* Takes an image in [data URL](https://developer.mozilla.org/en-US/docs/Web/HTTP/Basics_of_HTTP/Data_URIs) format.
|
||||||
|
*/
|
||||||
|
writeImage(dataUrl: string): Promise<void>;
|
||||||
|
/**
|
||||||
|
* Returns the list available formats (mime types).
|
||||||
|
*
|
||||||
|
* For example [ 'text/plain', 'text/html' ]
|
||||||
|
*/
|
||||||
|
availableFormats(): Promise<string[]>;
|
||||||
|
}
|
|
@ -2,7 +2,7 @@ import Plugin from '../Plugin';
|
||||||
import { ButtonSpec, ViewHandle, DialogResult } from './types';
|
import { ButtonSpec, ViewHandle, DialogResult } from './types';
|
||||||
/**
|
/**
|
||||||
* Allows creating and managing dialogs. A dialog is modal window that
|
* Allows creating and managing dialogs. A dialog is modal window that
|
||||||
* contains a webview and a row of buttons. You can update the update the
|
* contains a webview and a row of buttons. You can update the
|
||||||
* webview using the `setHtml` method. Dialogs are hidden by default and
|
* webview using the `setHtml` method. Dialogs are hidden by default and
|
||||||
* you need to call `open()` to open them. Once the user clicks on a
|
* you need to call `open()` to open them. Once the user clicks on a
|
||||||
* button, the `open` call will return an object indicating what button was
|
* button, the `open` call will return an object indicating what button was
|
||||||
|
@ -59,4 +59,11 @@ export default class JoplinViewsDialogs {
|
||||||
* Opens the dialog
|
* Opens the dialog
|
||||||
*/
|
*/
|
||||||
open(handle: ViewHandle): Promise<DialogResult>;
|
open(handle: ViewHandle): Promise<DialogResult>;
|
||||||
|
/**
|
||||||
|
* Toggle on whether to fit the dialog size to the content or not.
|
||||||
|
* When set to false, the dialog stretches to fill the application
|
||||||
|
* window.
|
||||||
|
* @default true
|
||||||
|
*/
|
||||||
|
setFitToContent(handle: ViewHandle, status: boolean): Promise<boolean>;
|
||||||
}
|
}
|
||||||
|
|
|
@ -0,0 +1,24 @@
|
||||||
|
import Plugin from '../Plugin';
|
||||||
|
export interface Implementation {
|
||||||
|
injectCustomStyles(elementId: string, cssFilePath: string): Promise<void>;
|
||||||
|
}
|
||||||
|
export default class JoplinWindow {
|
||||||
|
private plugin_;
|
||||||
|
private store_;
|
||||||
|
private implementation_;
|
||||||
|
constructor(implementation: Implementation, plugin: Plugin, store: any);
|
||||||
|
/**
|
||||||
|
* Loads a chrome CSS file. It will apply to the window UI elements, except
|
||||||
|
* for the note viewer. It is the same as the "Custom stylesheet for
|
||||||
|
* Joplin-wide app styles" setting. See the [Load CSS Demo](https://github.com/laurent22/joplin/tree/dev/packages/app-cli/tests/support/plugins/load_css)
|
||||||
|
* for an example.
|
||||||
|
*/
|
||||||
|
loadChromeCssFile(filePath: string): Promise<void>;
|
||||||
|
/**
|
||||||
|
* Loads a note CSS file. It will apply to the note viewer, as well as any
|
||||||
|
* exported or printed note. It is the same as the "Custom stylesheet for
|
||||||
|
* rendered Markdown" setting. See the [Load CSS Demo](https://github.com/laurent22/joplin/tree/dev/packages/app-cli/tests/support/plugins/load_css)
|
||||||
|
* for an example.
|
||||||
|
*/
|
||||||
|
loadNoteCssFile(filePath: string): Promise<void>;
|
||||||
|
}
|
|
@ -334,6 +334,17 @@ export enum SettingItemType {
|
||||||
Button = 6,
|
Button = 6,
|
||||||
}
|
}
|
||||||
|
|
||||||
|
export enum AppType {
|
||||||
|
Desktop = 'desktop',
|
||||||
|
Mobile = 'mobile',
|
||||||
|
Cli = 'cli',
|
||||||
|
}
|
||||||
|
|
||||||
|
export enum SettingStorage {
|
||||||
|
Database = 1,
|
||||||
|
File = 2,
|
||||||
|
}
|
||||||
|
|
||||||
// Redefine a simplified interface to mask internal details
|
// Redefine a simplified interface to mask internal details
|
||||||
// and to remove function calls as they would have to be async.
|
// and to remove function calls as they would have to be async.
|
||||||
export interface SettingItem {
|
export interface SettingItem {
|
||||||
|
@ -372,7 +383,7 @@ export interface SettingItem {
|
||||||
/**
|
/**
|
||||||
* Reserved property. Not used at the moment.
|
* Reserved property. Not used at the moment.
|
||||||
*/
|
*/
|
||||||
appTypes?: string[];
|
appTypes?: AppType[];
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Set this to `true` to store secure data, such as passwords. Any such
|
* Set this to `true` to store secure data, such as passwords. Any such
|
||||||
|
@ -393,6 +404,11 @@ export interface SettingItem {
|
||||||
minimum?: number;
|
minimum?: number;
|
||||||
maximum?: number;
|
maximum?: number;
|
||||||
step?: number;
|
step?: number;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Either store the setting in the database or in settings.json. Defaults to database.
|
||||||
|
*/
|
||||||
|
storage?: SettingStorage;
|
||||||
}
|
}
|
||||||
|
|
||||||
export interface SettingSection {
|
export interface SettingSection {
|
||||||
|
@ -419,7 +435,7 @@ export type Path = string[];
|
||||||
// Content Script types
|
// Content Script types
|
||||||
// =================================================================
|
// =================================================================
|
||||||
|
|
||||||
export type PostMessageHandler = (id: string, message: any)=> Promise<any>;
|
export type PostMessageHandler = (message: any)=> Promise<any>;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* When a content script is initialised, it receives a `context` object.
|
* When a content script is initialised, it receives a `context` object.
|
||||||
|
|
|
@ -8,6 +8,8 @@ import JoplinViews from './JoplinViews';
|
||||||
import JoplinInterop from './JoplinInterop';
|
import JoplinInterop from './JoplinInterop';
|
||||||
import JoplinSettings from './JoplinSettings';
|
import JoplinSettings from './JoplinSettings';
|
||||||
import JoplinContentScripts from './JoplinContentScripts';
|
import JoplinContentScripts from './JoplinContentScripts';
|
||||||
|
import JoplinClipboard from './JoplinClipboard';
|
||||||
|
import JoplinWindow from './JoplinWindow';
|
||||||
/**
|
/**
|
||||||
* This is the main entry point to the Joplin API. You can access various services using the provided accessors.
|
* This is the main entry point to the Joplin API. You can access various services using the provided accessors.
|
||||||
*
|
*
|
||||||
|
@ -33,8 +35,12 @@ export default class Joplin {
|
||||||
private interop_;
|
private interop_;
|
||||||
private settings_;
|
private settings_;
|
||||||
private contentScripts_;
|
private contentScripts_;
|
||||||
|
private clipboard_;
|
||||||
|
private window_;
|
||||||
constructor(implementation: any, plugin: Plugin, store: any);
|
constructor(implementation: any, plugin: Plugin, store: any);
|
||||||
get data(): JoplinData;
|
get data(): JoplinData;
|
||||||
|
get clipboard(): JoplinClipboard;
|
||||||
|
get window(): JoplinWindow;
|
||||||
get plugins(): JoplinPlugins;
|
get plugins(): JoplinPlugins;
|
||||||
get workspace(): JoplinWorkspace;
|
get workspace(): JoplinWorkspace;
|
||||||
get contentScripts(): JoplinContentScripts;
|
get contentScripts(): JoplinContentScripts;
|
||||||
|
|
23
packages/app-cli/tests/support/plugins/external_assets/api/JoplinClipboard.d.ts
vendored
Normal file
23
packages/app-cli/tests/support/plugins/external_assets/api/JoplinClipboard.d.ts
vendored
Normal file
|
@ -0,0 +1,23 @@
|
||||||
|
export default class JoplinClipboard {
|
||||||
|
private electronClipboard_;
|
||||||
|
private electronNativeImage_;
|
||||||
|
constructor(electronClipboard: any, electronNativeImage: any);
|
||||||
|
readText(): Promise<string>;
|
||||||
|
writeText(text: string): Promise<void>;
|
||||||
|
readHtml(): Promise<string>;
|
||||||
|
writeHtml(html: string): Promise<void>;
|
||||||
|
/**
|
||||||
|
* Returns the image in [data URL](https://developer.mozilla.org/en-US/docs/Web/HTTP/Basics_of_HTTP/Data_URIs) format.
|
||||||
|
*/
|
||||||
|
readImage(): Promise<string>;
|
||||||
|
/**
|
||||||
|
* Takes an image in [data URL](https://developer.mozilla.org/en-US/docs/Web/HTTP/Basics_of_HTTP/Data_URIs) format.
|
||||||
|
*/
|
||||||
|
writeImage(dataUrl: string): Promise<void>;
|
||||||
|
/**
|
||||||
|
* Returns the list available formats (mime types).
|
||||||
|
*
|
||||||
|
* For example [ 'text/plain', 'text/html' ]
|
||||||
|
*/
|
||||||
|
availableFormats(): Promise<string[]>;
|
||||||
|
}
|
|
@ -2,7 +2,7 @@ import Plugin from '../Plugin';
|
||||||
import { ButtonSpec, ViewHandle, DialogResult } from './types';
|
import { ButtonSpec, ViewHandle, DialogResult } from './types';
|
||||||
/**
|
/**
|
||||||
* Allows creating and managing dialogs. A dialog is modal window that
|
* Allows creating and managing dialogs. A dialog is modal window that
|
||||||
* contains a webview and a row of buttons. You can update the update the
|
* contains a webview and a row of buttons. You can update the
|
||||||
* webview using the `setHtml` method. Dialogs are hidden by default and
|
* webview using the `setHtml` method. Dialogs are hidden by default and
|
||||||
* you need to call `open()` to open them. Once the user clicks on a
|
* you need to call `open()` to open them. Once the user clicks on a
|
||||||
* button, the `open` call will return an object indicating what button was
|
* button, the `open` call will return an object indicating what button was
|
||||||
|
@ -59,4 +59,11 @@ export default class JoplinViewsDialogs {
|
||||||
* Opens the dialog
|
* Opens the dialog
|
||||||
*/
|
*/
|
||||||
open(handle: ViewHandle): Promise<DialogResult>;
|
open(handle: ViewHandle): Promise<DialogResult>;
|
||||||
|
/**
|
||||||
|
* Toggle on whether to fit the dialog size to the content or not.
|
||||||
|
* When set to false, the dialog stretches to fill the application
|
||||||
|
* window.
|
||||||
|
* @default true
|
||||||
|
*/
|
||||||
|
setFitToContent(handle: ViewHandle, status: boolean): Promise<boolean>;
|
||||||
}
|
}
|
||||||
|
|
24
packages/app-cli/tests/support/plugins/external_assets/api/JoplinWindow.d.ts
vendored
Normal file
24
packages/app-cli/tests/support/plugins/external_assets/api/JoplinWindow.d.ts
vendored
Normal file
|
@ -0,0 +1,24 @@
|
||||||
|
import Plugin from '../Plugin';
|
||||||
|
export interface Implementation {
|
||||||
|
injectCustomStyles(elementId: string, cssFilePath: string): Promise<void>;
|
||||||
|
}
|
||||||
|
export default class JoplinWindow {
|
||||||
|
private plugin_;
|
||||||
|
private store_;
|
||||||
|
private implementation_;
|
||||||
|
constructor(implementation: Implementation, plugin: Plugin, store: any);
|
||||||
|
/**
|
||||||
|
* Loads a chrome CSS file. It will apply to the window UI elements, except
|
||||||
|
* for the note viewer. It is the same as the "Custom stylesheet for
|
||||||
|
* Joplin-wide app styles" setting. See the [Load CSS Demo](https://github.com/laurent22/joplin/tree/dev/packages/app-cli/tests/support/plugins/load_css)
|
||||||
|
* for an example.
|
||||||
|
*/
|
||||||
|
loadChromeCssFile(filePath: string): Promise<void>;
|
||||||
|
/**
|
||||||
|
* Loads a note CSS file. It will apply to the note viewer, as well as any
|
||||||
|
* exported or printed note. It is the same as the "Custom stylesheet for
|
||||||
|
* rendered Markdown" setting. See the [Load CSS Demo](https://github.com/laurent22/joplin/tree/dev/packages/app-cli/tests/support/plugins/load_css)
|
||||||
|
* for an example.
|
||||||
|
*/
|
||||||
|
loadNoteCssFile(filePath: string): Promise<void>;
|
||||||
|
}
|
|
@ -334,6 +334,17 @@ export enum SettingItemType {
|
||||||
Button = 6,
|
Button = 6,
|
||||||
}
|
}
|
||||||
|
|
||||||
|
export enum AppType {
|
||||||
|
Desktop = 'desktop',
|
||||||
|
Mobile = 'mobile',
|
||||||
|
Cli = 'cli',
|
||||||
|
}
|
||||||
|
|
||||||
|
export enum SettingStorage {
|
||||||
|
Database = 1,
|
||||||
|
File = 2,
|
||||||
|
}
|
||||||
|
|
||||||
// Redefine a simplified interface to mask internal details
|
// Redefine a simplified interface to mask internal details
|
||||||
// and to remove function calls as they would have to be async.
|
// and to remove function calls as they would have to be async.
|
||||||
export interface SettingItem {
|
export interface SettingItem {
|
||||||
|
@ -372,7 +383,7 @@ export interface SettingItem {
|
||||||
/**
|
/**
|
||||||
* Reserved property. Not used at the moment.
|
* Reserved property. Not used at the moment.
|
||||||
*/
|
*/
|
||||||
appTypes?: string[];
|
appTypes?: AppType[];
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Set this to `true` to store secure data, such as passwords. Any such
|
* Set this to `true` to store secure data, such as passwords. Any such
|
||||||
|
@ -393,6 +404,11 @@ export interface SettingItem {
|
||||||
minimum?: number;
|
minimum?: number;
|
||||||
maximum?: number;
|
maximum?: number;
|
||||||
step?: number;
|
step?: number;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Either store the setting in the database or in settings.json. Defaults to database.
|
||||||
|
*/
|
||||||
|
storage?: SettingStorage;
|
||||||
}
|
}
|
||||||
|
|
||||||
export interface SettingSection {
|
export interface SettingSection {
|
||||||
|
@ -419,7 +435,7 @@ export type Path = string[];
|
||||||
// Content Script types
|
// Content Script types
|
||||||
// =================================================================
|
// =================================================================
|
||||||
|
|
||||||
export type PostMessageHandler = (id: string, message: any)=> Promise<any>;
|
export type PostMessageHandler = (message: any)=> Promise<any>;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* When a content script is initialised, it receives a `context` object.
|
* When a content script is initialised, it receives a `context` object.
|
||||||
|
|
|
@ -8,6 +8,8 @@ import JoplinViews from './JoplinViews';
|
||||||
import JoplinInterop from './JoplinInterop';
|
import JoplinInterop from './JoplinInterop';
|
||||||
import JoplinSettings from './JoplinSettings';
|
import JoplinSettings from './JoplinSettings';
|
||||||
import JoplinContentScripts from './JoplinContentScripts';
|
import JoplinContentScripts from './JoplinContentScripts';
|
||||||
|
import JoplinClipboard from './JoplinClipboard';
|
||||||
|
import JoplinWindow from './JoplinWindow';
|
||||||
/**
|
/**
|
||||||
* This is the main entry point to the Joplin API. You can access various services using the provided accessors.
|
* This is the main entry point to the Joplin API. You can access various services using the provided accessors.
|
||||||
*
|
*
|
||||||
|
@ -33,8 +35,12 @@ export default class Joplin {
|
||||||
private interop_;
|
private interop_;
|
||||||
private settings_;
|
private settings_;
|
||||||
private contentScripts_;
|
private contentScripts_;
|
||||||
|
private clipboard_;
|
||||||
|
private window_;
|
||||||
constructor(implementation: any, plugin: Plugin, store: any);
|
constructor(implementation: any, plugin: Plugin, store: any);
|
||||||
get data(): JoplinData;
|
get data(): JoplinData;
|
||||||
|
get clipboard(): JoplinClipboard;
|
||||||
|
get window(): JoplinWindow;
|
||||||
get plugins(): JoplinPlugins;
|
get plugins(): JoplinPlugins;
|
||||||
get workspace(): JoplinWorkspace;
|
get workspace(): JoplinWorkspace;
|
||||||
get contentScripts(): JoplinContentScripts;
|
get contentScripts(): JoplinContentScripts;
|
||||||
|
|
|
@ -0,0 +1,23 @@
|
||||||
|
export default class JoplinClipboard {
|
||||||
|
private electronClipboard_;
|
||||||
|
private electronNativeImage_;
|
||||||
|
constructor(electronClipboard: any, electronNativeImage: any);
|
||||||
|
readText(): Promise<string>;
|
||||||
|
writeText(text: string): Promise<void>;
|
||||||
|
readHtml(): Promise<string>;
|
||||||
|
writeHtml(html: string): Promise<void>;
|
||||||
|
/**
|
||||||
|
* Returns the image in [data URL](https://developer.mozilla.org/en-US/docs/Web/HTTP/Basics_of_HTTP/Data_URIs) format.
|
||||||
|
*/
|
||||||
|
readImage(): Promise<string>;
|
||||||
|
/**
|
||||||
|
* Takes an image in [data URL](https://developer.mozilla.org/en-US/docs/Web/HTTP/Basics_of_HTTP/Data_URIs) format.
|
||||||
|
*/
|
||||||
|
writeImage(dataUrl: string): Promise<void>;
|
||||||
|
/**
|
||||||
|
* Returns the list available formats (mime types).
|
||||||
|
*
|
||||||
|
* For example [ 'text/plain', 'text/html' ]
|
||||||
|
*/
|
||||||
|
availableFormats(): Promise<string[]>;
|
||||||
|
}
|
|
@ -2,7 +2,7 @@ import Plugin from '../Plugin';
|
||||||
import { ButtonSpec, ViewHandle, DialogResult } from './types';
|
import { ButtonSpec, ViewHandle, DialogResult } from './types';
|
||||||
/**
|
/**
|
||||||
* Allows creating and managing dialogs. A dialog is modal window that
|
* Allows creating and managing dialogs. A dialog is modal window that
|
||||||
* contains a webview and a row of buttons. You can update the update the
|
* contains a webview and a row of buttons. You can update the
|
||||||
* webview using the `setHtml` method. Dialogs are hidden by default and
|
* webview using the `setHtml` method. Dialogs are hidden by default and
|
||||||
* you need to call `open()` to open them. Once the user clicks on a
|
* you need to call `open()` to open them. Once the user clicks on a
|
||||||
* button, the `open` call will return an object indicating what button was
|
* button, the `open` call will return an object indicating what button was
|
||||||
|
@ -59,4 +59,11 @@ export default class JoplinViewsDialogs {
|
||||||
* Opens the dialog
|
* Opens the dialog
|
||||||
*/
|
*/
|
||||||
open(handle: ViewHandle): Promise<DialogResult>;
|
open(handle: ViewHandle): Promise<DialogResult>;
|
||||||
|
/**
|
||||||
|
* Toggle on whether to fit the dialog size to the content or not.
|
||||||
|
* When set to false, the dialog stretches to fill the application
|
||||||
|
* window.
|
||||||
|
* @default true
|
||||||
|
*/
|
||||||
|
setFitToContent(handle: ViewHandle, status: boolean): Promise<boolean>;
|
||||||
}
|
}
|
||||||
|
|
|
@ -0,0 +1,24 @@
|
||||||
|
import Plugin from '../Plugin';
|
||||||
|
export interface Implementation {
|
||||||
|
injectCustomStyles(elementId: string, cssFilePath: string): Promise<void>;
|
||||||
|
}
|
||||||
|
export default class JoplinWindow {
|
||||||
|
private plugin_;
|
||||||
|
private store_;
|
||||||
|
private implementation_;
|
||||||
|
constructor(implementation: Implementation, plugin: Plugin, store: any);
|
||||||
|
/**
|
||||||
|
* Loads a chrome CSS file. It will apply to the window UI elements, except
|
||||||
|
* for the note viewer. It is the same as the "Custom stylesheet for
|
||||||
|
* Joplin-wide app styles" setting. See the [Load CSS Demo](https://github.com/laurent22/joplin/tree/dev/packages/app-cli/tests/support/plugins/load_css)
|
||||||
|
* for an example.
|
||||||
|
*/
|
||||||
|
loadChromeCssFile(filePath: string): Promise<void>;
|
||||||
|
/**
|
||||||
|
* Loads a note CSS file. It will apply to the note viewer, as well as any
|
||||||
|
* exported or printed note. It is the same as the "Custom stylesheet for
|
||||||
|
* rendered Markdown" setting. See the [Load CSS Demo](https://github.com/laurent22/joplin/tree/dev/packages/app-cli/tests/support/plugins/load_css)
|
||||||
|
* for an example.
|
||||||
|
*/
|
||||||
|
loadNoteCssFile(filePath: string): Promise<void>;
|
||||||
|
}
|
|
@ -334,6 +334,17 @@ export enum SettingItemType {
|
||||||
Button = 6,
|
Button = 6,
|
||||||
}
|
}
|
||||||
|
|
||||||
|
export enum AppType {
|
||||||
|
Desktop = 'desktop',
|
||||||
|
Mobile = 'mobile',
|
||||||
|
Cli = 'cli',
|
||||||
|
}
|
||||||
|
|
||||||
|
export enum SettingStorage {
|
||||||
|
Database = 1,
|
||||||
|
File = 2,
|
||||||
|
}
|
||||||
|
|
||||||
// Redefine a simplified interface to mask internal details
|
// Redefine a simplified interface to mask internal details
|
||||||
// and to remove function calls as they would have to be async.
|
// and to remove function calls as they would have to be async.
|
||||||
export interface SettingItem {
|
export interface SettingItem {
|
||||||
|
@ -372,7 +383,7 @@ export interface SettingItem {
|
||||||
/**
|
/**
|
||||||
* Reserved property. Not used at the moment.
|
* Reserved property. Not used at the moment.
|
||||||
*/
|
*/
|
||||||
appTypes?: string[];
|
appTypes?: AppType[];
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Set this to `true` to store secure data, such as passwords. Any such
|
* Set this to `true` to store secure data, such as passwords. Any such
|
||||||
|
@ -393,6 +404,11 @@ export interface SettingItem {
|
||||||
minimum?: number;
|
minimum?: number;
|
||||||
maximum?: number;
|
maximum?: number;
|
||||||
step?: number;
|
step?: number;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Either store the setting in the database or in settings.json. Defaults to database.
|
||||||
|
*/
|
||||||
|
storage?: SettingStorage;
|
||||||
}
|
}
|
||||||
|
|
||||||
export interface SettingSection {
|
export interface SettingSection {
|
||||||
|
@ -419,7 +435,7 @@ export type Path = string[];
|
||||||
// Content Script types
|
// Content Script types
|
||||||
// =================================================================
|
// =================================================================
|
||||||
|
|
||||||
export type PostMessageHandler = (id: string, message: any)=> Promise<any>;
|
export type PostMessageHandler = (message: any)=> Promise<any>;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* When a content script is initialised, it receives a `context` object.
|
* When a content script is initialised, it receives a `context` object.
|
||||||
|
|
|
@ -8,6 +8,8 @@ import JoplinViews from './JoplinViews';
|
||||||
import JoplinInterop from './JoplinInterop';
|
import JoplinInterop from './JoplinInterop';
|
||||||
import JoplinSettings from './JoplinSettings';
|
import JoplinSettings from './JoplinSettings';
|
||||||
import JoplinContentScripts from './JoplinContentScripts';
|
import JoplinContentScripts from './JoplinContentScripts';
|
||||||
|
import JoplinClipboard from './JoplinClipboard';
|
||||||
|
import JoplinWindow from './JoplinWindow';
|
||||||
/**
|
/**
|
||||||
* This is the main entry point to the Joplin API. You can access various services using the provided accessors.
|
* This is the main entry point to the Joplin API. You can access various services using the provided accessors.
|
||||||
*
|
*
|
||||||
|
@ -33,8 +35,12 @@ export default class Joplin {
|
||||||
private interop_;
|
private interop_;
|
||||||
private settings_;
|
private settings_;
|
||||||
private contentScripts_;
|
private contentScripts_;
|
||||||
|
private clipboard_;
|
||||||
|
private window_;
|
||||||
constructor(implementation: any, plugin: Plugin, store: any);
|
constructor(implementation: any, plugin: Plugin, store: any);
|
||||||
get data(): JoplinData;
|
get data(): JoplinData;
|
||||||
|
get clipboard(): JoplinClipboard;
|
||||||
|
get window(): JoplinWindow;
|
||||||
get plugins(): JoplinPlugins;
|
get plugins(): JoplinPlugins;
|
||||||
get workspace(): JoplinWorkspace;
|
get workspace(): JoplinWorkspace;
|
||||||
get contentScripts(): JoplinContentScripts;
|
get contentScripts(): JoplinContentScripts;
|
||||||
|
|
|
@ -0,0 +1,23 @@
|
||||||
|
export default class JoplinClipboard {
|
||||||
|
private electronClipboard_;
|
||||||
|
private electronNativeImage_;
|
||||||
|
constructor(electronClipboard: any, electronNativeImage: any);
|
||||||
|
readText(): Promise<string>;
|
||||||
|
writeText(text: string): Promise<void>;
|
||||||
|
readHtml(): Promise<string>;
|
||||||
|
writeHtml(html: string): Promise<void>;
|
||||||
|
/**
|
||||||
|
* Returns the image in [data URL](https://developer.mozilla.org/en-US/docs/Web/HTTP/Basics_of_HTTP/Data_URIs) format.
|
||||||
|
*/
|
||||||
|
readImage(): Promise<string>;
|
||||||
|
/**
|
||||||
|
* Takes an image in [data URL](https://developer.mozilla.org/en-US/docs/Web/HTTP/Basics_of_HTTP/Data_URIs) format.
|
||||||
|
*/
|
||||||
|
writeImage(dataUrl: string): Promise<void>;
|
||||||
|
/**
|
||||||
|
* Returns the list available formats (mime types).
|
||||||
|
*
|
||||||
|
* For example [ 'text/plain', 'text/html' ]
|
||||||
|
*/
|
||||||
|
availableFormats(): Promise<string[]>;
|
||||||
|
}
|
|
@ -2,7 +2,7 @@ import Plugin from '../Plugin';
|
||||||
import { ButtonSpec, ViewHandle, DialogResult } from './types';
|
import { ButtonSpec, ViewHandle, DialogResult } from './types';
|
||||||
/**
|
/**
|
||||||
* Allows creating and managing dialogs. A dialog is modal window that
|
* Allows creating and managing dialogs. A dialog is modal window that
|
||||||
* contains a webview and a row of buttons. You can update the update the
|
* contains a webview and a row of buttons. You can update the
|
||||||
* webview using the `setHtml` method. Dialogs are hidden by default and
|
* webview using the `setHtml` method. Dialogs are hidden by default and
|
||||||
* you need to call `open()` to open them. Once the user clicks on a
|
* you need to call `open()` to open them. Once the user clicks on a
|
||||||
* button, the `open` call will return an object indicating what button was
|
* button, the `open` call will return an object indicating what button was
|
||||||
|
@ -59,4 +59,11 @@ export default class JoplinViewsDialogs {
|
||||||
* Opens the dialog
|
* Opens the dialog
|
||||||
*/
|
*/
|
||||||
open(handle: ViewHandle): Promise<DialogResult>;
|
open(handle: ViewHandle): Promise<DialogResult>;
|
||||||
|
/**
|
||||||
|
* Toggle on whether to fit the dialog size to the content or not.
|
||||||
|
* When set to false, the dialog stretches to fill the application
|
||||||
|
* window.
|
||||||
|
* @default true
|
||||||
|
*/
|
||||||
|
setFitToContent(handle: ViewHandle, status: boolean): Promise<boolean>;
|
||||||
}
|
}
|
||||||
|
|
|
@ -0,0 +1,24 @@
|
||||||
|
import Plugin from '../Plugin';
|
||||||
|
export interface Implementation {
|
||||||
|
injectCustomStyles(elementId: string, cssFilePath: string): Promise<void>;
|
||||||
|
}
|
||||||
|
export default class JoplinWindow {
|
||||||
|
private plugin_;
|
||||||
|
private store_;
|
||||||
|
private implementation_;
|
||||||
|
constructor(implementation: Implementation, plugin: Plugin, store: any);
|
||||||
|
/**
|
||||||
|
* Loads a chrome CSS file. It will apply to the window UI elements, except
|
||||||
|
* for the note viewer. It is the same as the "Custom stylesheet for
|
||||||
|
* Joplin-wide app styles" setting. See the [Load CSS Demo](https://github.com/laurent22/joplin/tree/dev/packages/app-cli/tests/support/plugins/load_css)
|
||||||
|
* for an example.
|
||||||
|
*/
|
||||||
|
loadChromeCssFile(filePath: string): Promise<void>;
|
||||||
|
/**
|
||||||
|
* Loads a note CSS file. It will apply to the note viewer, as well as any
|
||||||
|
* exported or printed note. It is the same as the "Custom stylesheet for
|
||||||
|
* rendered Markdown" setting. See the [Load CSS Demo](https://github.com/laurent22/joplin/tree/dev/packages/app-cli/tests/support/plugins/load_css)
|
||||||
|
* for an example.
|
||||||
|
*/
|
||||||
|
loadNoteCssFile(filePath: string): Promise<void>;
|
||||||
|
}
|
|
@ -334,6 +334,17 @@ export enum SettingItemType {
|
||||||
Button = 6,
|
Button = 6,
|
||||||
}
|
}
|
||||||
|
|
||||||
|
export enum AppType {
|
||||||
|
Desktop = 'desktop',
|
||||||
|
Mobile = 'mobile',
|
||||||
|
Cli = 'cli',
|
||||||
|
}
|
||||||
|
|
||||||
|
export enum SettingStorage {
|
||||||
|
Database = 1,
|
||||||
|
File = 2,
|
||||||
|
}
|
||||||
|
|
||||||
// Redefine a simplified interface to mask internal details
|
// Redefine a simplified interface to mask internal details
|
||||||
// and to remove function calls as they would have to be async.
|
// and to remove function calls as they would have to be async.
|
||||||
export interface SettingItem {
|
export interface SettingItem {
|
||||||
|
@ -372,7 +383,7 @@ export interface SettingItem {
|
||||||
/**
|
/**
|
||||||
* Reserved property. Not used at the moment.
|
* Reserved property. Not used at the moment.
|
||||||
*/
|
*/
|
||||||
appTypes?: string[];
|
appTypes?: AppType[];
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Set this to `true` to store secure data, such as passwords. Any such
|
* Set this to `true` to store secure data, such as passwords. Any such
|
||||||
|
@ -393,6 +404,11 @@ export interface SettingItem {
|
||||||
minimum?: number;
|
minimum?: number;
|
||||||
maximum?: number;
|
maximum?: number;
|
||||||
step?: number;
|
step?: number;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Either store the setting in the database or in settings.json. Defaults to database.
|
||||||
|
*/
|
||||||
|
storage?: SettingStorage;
|
||||||
}
|
}
|
||||||
|
|
||||||
export interface SettingSection {
|
export interface SettingSection {
|
||||||
|
@ -419,7 +435,7 @@ export type Path = string[];
|
||||||
// Content Script types
|
// Content Script types
|
||||||
// =================================================================
|
// =================================================================
|
||||||
|
|
||||||
export type PostMessageHandler = (id: string, message: any)=> Promise<any>;
|
export type PostMessageHandler = (message: any)=> Promise<any>;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* When a content script is initialised, it receives a `context` object.
|
* When a content script is initialised, it receives a `context` object.
|
||||||
|
|
|
@ -8,6 +8,8 @@ import JoplinViews from './JoplinViews';
|
||||||
import JoplinInterop from './JoplinInterop';
|
import JoplinInterop from './JoplinInterop';
|
||||||
import JoplinSettings from './JoplinSettings';
|
import JoplinSettings from './JoplinSettings';
|
||||||
import JoplinContentScripts from './JoplinContentScripts';
|
import JoplinContentScripts from './JoplinContentScripts';
|
||||||
|
import JoplinClipboard from './JoplinClipboard';
|
||||||
|
import JoplinWindow from './JoplinWindow';
|
||||||
/**
|
/**
|
||||||
* This is the main entry point to the Joplin API. You can access various services using the provided accessors.
|
* This is the main entry point to the Joplin API. You can access various services using the provided accessors.
|
||||||
*
|
*
|
||||||
|
@ -33,8 +35,12 @@ export default class Joplin {
|
||||||
private interop_;
|
private interop_;
|
||||||
private settings_;
|
private settings_;
|
||||||
private contentScripts_;
|
private contentScripts_;
|
||||||
|
private clipboard_;
|
||||||
|
private window_;
|
||||||
constructor(implementation: any, plugin: Plugin, store: any);
|
constructor(implementation: any, plugin: Plugin, store: any);
|
||||||
get data(): JoplinData;
|
get data(): JoplinData;
|
||||||
|
get clipboard(): JoplinClipboard;
|
||||||
|
get window(): JoplinWindow;
|
||||||
get plugins(): JoplinPlugins;
|
get plugins(): JoplinPlugins;
|
||||||
get workspace(): JoplinWorkspace;
|
get workspace(): JoplinWorkspace;
|
||||||
get contentScripts(): JoplinContentScripts;
|
get contentScripts(): JoplinContentScripts;
|
||||||
|
|
|
@ -0,0 +1,23 @@
|
||||||
|
export default class JoplinClipboard {
|
||||||
|
private electronClipboard_;
|
||||||
|
private electronNativeImage_;
|
||||||
|
constructor(electronClipboard: any, electronNativeImage: any);
|
||||||
|
readText(): Promise<string>;
|
||||||
|
writeText(text: string): Promise<void>;
|
||||||
|
readHtml(): Promise<string>;
|
||||||
|
writeHtml(html: string): Promise<void>;
|
||||||
|
/**
|
||||||
|
* Returns the image in [data URL](https://developer.mozilla.org/en-US/docs/Web/HTTP/Basics_of_HTTP/Data_URIs) format.
|
||||||
|
*/
|
||||||
|
readImage(): Promise<string>;
|
||||||
|
/**
|
||||||
|
* Takes an image in [data URL](https://developer.mozilla.org/en-US/docs/Web/HTTP/Basics_of_HTTP/Data_URIs) format.
|
||||||
|
*/
|
||||||
|
writeImage(dataUrl: string): Promise<void>;
|
||||||
|
/**
|
||||||
|
* Returns the list available formats (mime types).
|
||||||
|
*
|
||||||
|
* For example [ 'text/plain', 'text/html' ]
|
||||||
|
*/
|
||||||
|
availableFormats(): Promise<string[]>;
|
||||||
|
}
|
|
@ -2,7 +2,7 @@ import Plugin from '../Plugin';
|
||||||
import { ButtonSpec, ViewHandle, DialogResult } from './types';
|
import { ButtonSpec, ViewHandle, DialogResult } from './types';
|
||||||
/**
|
/**
|
||||||
* Allows creating and managing dialogs. A dialog is modal window that
|
* Allows creating and managing dialogs. A dialog is modal window that
|
||||||
* contains a webview and a row of buttons. You can update the update the
|
* contains a webview and a row of buttons. You can update the
|
||||||
* webview using the `setHtml` method. Dialogs are hidden by default and
|
* webview using the `setHtml` method. Dialogs are hidden by default and
|
||||||
* you need to call `open()` to open them. Once the user clicks on a
|
* you need to call `open()` to open them. Once the user clicks on a
|
||||||
* button, the `open` call will return an object indicating what button was
|
* button, the `open` call will return an object indicating what button was
|
||||||
|
@ -59,4 +59,11 @@ export default class JoplinViewsDialogs {
|
||||||
* Opens the dialog
|
* Opens the dialog
|
||||||
*/
|
*/
|
||||||
open(handle: ViewHandle): Promise<DialogResult>;
|
open(handle: ViewHandle): Promise<DialogResult>;
|
||||||
|
/**
|
||||||
|
* Toggle on whether to fit the dialog size to the content or not.
|
||||||
|
* When set to false, the dialog stretches to fill the application
|
||||||
|
* window.
|
||||||
|
* @default true
|
||||||
|
*/
|
||||||
|
setFitToContent(handle: ViewHandle, status: boolean): Promise<boolean>;
|
||||||
}
|
}
|
||||||
|
|
|
@ -0,0 +1,24 @@
|
||||||
|
import Plugin from '../Plugin';
|
||||||
|
export interface Implementation {
|
||||||
|
injectCustomStyles(elementId: string, cssFilePath: string): Promise<void>;
|
||||||
|
}
|
||||||
|
export default class JoplinWindow {
|
||||||
|
private plugin_;
|
||||||
|
private store_;
|
||||||
|
private implementation_;
|
||||||
|
constructor(implementation: Implementation, plugin: Plugin, store: any);
|
||||||
|
/**
|
||||||
|
* Loads a chrome CSS file. It will apply to the window UI elements, except
|
||||||
|
* for the note viewer. It is the same as the "Custom stylesheet for
|
||||||
|
* Joplin-wide app styles" setting. See the [Load CSS Demo](https://github.com/laurent22/joplin/tree/dev/packages/app-cli/tests/support/plugins/load_css)
|
||||||
|
* for an example.
|
||||||
|
*/
|
||||||
|
loadChromeCssFile(filePath: string): Promise<void>;
|
||||||
|
/**
|
||||||
|
* Loads a note CSS file. It will apply to the note viewer, as well as any
|
||||||
|
* exported or printed note. It is the same as the "Custom stylesheet for
|
||||||
|
* rendered Markdown" setting. See the [Load CSS Demo](https://github.com/laurent22/joplin/tree/dev/packages/app-cli/tests/support/plugins/load_css)
|
||||||
|
* for an example.
|
||||||
|
*/
|
||||||
|
loadNoteCssFile(filePath: string): Promise<void>;
|
||||||
|
}
|
|
@ -334,6 +334,17 @@ export enum SettingItemType {
|
||||||
Button = 6,
|
Button = 6,
|
||||||
}
|
}
|
||||||
|
|
||||||
|
export enum AppType {
|
||||||
|
Desktop = 'desktop',
|
||||||
|
Mobile = 'mobile',
|
||||||
|
Cli = 'cli',
|
||||||
|
}
|
||||||
|
|
||||||
|
export enum SettingStorage {
|
||||||
|
Database = 1,
|
||||||
|
File = 2,
|
||||||
|
}
|
||||||
|
|
||||||
// Redefine a simplified interface to mask internal details
|
// Redefine a simplified interface to mask internal details
|
||||||
// and to remove function calls as they would have to be async.
|
// and to remove function calls as they would have to be async.
|
||||||
export interface SettingItem {
|
export interface SettingItem {
|
||||||
|
@ -372,7 +383,7 @@ export interface SettingItem {
|
||||||
/**
|
/**
|
||||||
* Reserved property. Not used at the moment.
|
* Reserved property. Not used at the moment.
|
||||||
*/
|
*/
|
||||||
appTypes?: string[];
|
appTypes?: AppType[];
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Set this to `true` to store secure data, such as passwords. Any such
|
* Set this to `true` to store secure data, such as passwords. Any such
|
||||||
|
@ -393,6 +404,11 @@ export interface SettingItem {
|
||||||
minimum?: number;
|
minimum?: number;
|
||||||
maximum?: number;
|
maximum?: number;
|
||||||
step?: number;
|
step?: number;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Either store the setting in the database or in settings.json. Defaults to database.
|
||||||
|
*/
|
||||||
|
storage?: SettingStorage;
|
||||||
}
|
}
|
||||||
|
|
||||||
export interface SettingSection {
|
export interface SettingSection {
|
||||||
|
@ -419,7 +435,7 @@ export type Path = string[];
|
||||||
// Content Script types
|
// Content Script types
|
||||||
// =================================================================
|
// =================================================================
|
||||||
|
|
||||||
export type PostMessageHandler = (id: string, message: any)=> Promise<any>;
|
export type PostMessageHandler = (message: any)=> Promise<any>;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* When a content script is initialised, it receives a `context` object.
|
* When a content script is initialised, it receives a `context` object.
|
||||||
|
|
|
@ -8,6 +8,8 @@ import JoplinViews from './JoplinViews';
|
||||||
import JoplinInterop from './JoplinInterop';
|
import JoplinInterop from './JoplinInterop';
|
||||||
import JoplinSettings from './JoplinSettings';
|
import JoplinSettings from './JoplinSettings';
|
||||||
import JoplinContentScripts from './JoplinContentScripts';
|
import JoplinContentScripts from './JoplinContentScripts';
|
||||||
|
import JoplinClipboard from './JoplinClipboard';
|
||||||
|
import JoplinWindow from './JoplinWindow';
|
||||||
/**
|
/**
|
||||||
* This is the main entry point to the Joplin API. You can access various services using the provided accessors.
|
* This is the main entry point to the Joplin API. You can access various services using the provided accessors.
|
||||||
*
|
*
|
||||||
|
@ -33,8 +35,12 @@ export default class Joplin {
|
||||||
private interop_;
|
private interop_;
|
||||||
private settings_;
|
private settings_;
|
||||||
private contentScripts_;
|
private contentScripts_;
|
||||||
|
private clipboard_;
|
||||||
|
private window_;
|
||||||
constructor(implementation: any, plugin: Plugin, store: any);
|
constructor(implementation: any, plugin: Plugin, store: any);
|
||||||
get data(): JoplinData;
|
get data(): JoplinData;
|
||||||
|
get clipboard(): JoplinClipboard;
|
||||||
|
get window(): JoplinWindow;
|
||||||
get plugins(): JoplinPlugins;
|
get plugins(): JoplinPlugins;
|
||||||
get workspace(): JoplinWorkspace;
|
get workspace(): JoplinWorkspace;
|
||||||
get contentScripts(): JoplinContentScripts;
|
get contentScripts(): JoplinContentScripts;
|
||||||
|
|
23
packages/app-cli/tests/support/plugins/multi_selection/api/JoplinClipboard.d.ts
vendored
Normal file
23
packages/app-cli/tests/support/plugins/multi_selection/api/JoplinClipboard.d.ts
vendored
Normal file
|
@ -0,0 +1,23 @@
|
||||||
|
export default class JoplinClipboard {
|
||||||
|
private electronClipboard_;
|
||||||
|
private electronNativeImage_;
|
||||||
|
constructor(electronClipboard: any, electronNativeImage: any);
|
||||||
|
readText(): Promise<string>;
|
||||||
|
writeText(text: string): Promise<void>;
|
||||||
|
readHtml(): Promise<string>;
|
||||||
|
writeHtml(html: string): Promise<void>;
|
||||||
|
/**
|
||||||
|
* Returns the image in [data URL](https://developer.mozilla.org/en-US/docs/Web/HTTP/Basics_of_HTTP/Data_URIs) format.
|
||||||
|
*/
|
||||||
|
readImage(): Promise<string>;
|
||||||
|
/**
|
||||||
|
* Takes an image in [data URL](https://developer.mozilla.org/en-US/docs/Web/HTTP/Basics_of_HTTP/Data_URIs) format.
|
||||||
|
*/
|
||||||
|
writeImage(dataUrl: string): Promise<void>;
|
||||||
|
/**
|
||||||
|
* Returns the list available formats (mime types).
|
||||||
|
*
|
||||||
|
* For example [ 'text/plain', 'text/html' ]
|
||||||
|
*/
|
||||||
|
availableFormats(): Promise<string[]>;
|
||||||
|
}
|
|
@ -2,7 +2,7 @@ import Plugin from '../Plugin';
|
||||||
import { ButtonSpec, ViewHandle, DialogResult } from './types';
|
import { ButtonSpec, ViewHandle, DialogResult } from './types';
|
||||||
/**
|
/**
|
||||||
* Allows creating and managing dialogs. A dialog is modal window that
|
* Allows creating and managing dialogs. A dialog is modal window that
|
||||||
* contains a webview and a row of buttons. You can update the update the
|
* contains a webview and a row of buttons. You can update the
|
||||||
* webview using the `setHtml` method. Dialogs are hidden by default and
|
* webview using the `setHtml` method. Dialogs are hidden by default and
|
||||||
* you need to call `open()` to open them. Once the user clicks on a
|
* you need to call `open()` to open them. Once the user clicks on a
|
||||||
* button, the `open` call will return an object indicating what button was
|
* button, the `open` call will return an object indicating what button was
|
||||||
|
@ -59,4 +59,11 @@ export default class JoplinViewsDialogs {
|
||||||
* Opens the dialog
|
* Opens the dialog
|
||||||
*/
|
*/
|
||||||
open(handle: ViewHandle): Promise<DialogResult>;
|
open(handle: ViewHandle): Promise<DialogResult>;
|
||||||
|
/**
|
||||||
|
* Toggle on whether to fit the dialog size to the content or not.
|
||||||
|
* When set to false, the dialog stretches to fill the application
|
||||||
|
* window.
|
||||||
|
* @default true
|
||||||
|
*/
|
||||||
|
setFitToContent(handle: ViewHandle, status: boolean): Promise<boolean>;
|
||||||
}
|
}
|
||||||
|
|
24
packages/app-cli/tests/support/plugins/multi_selection/api/JoplinWindow.d.ts
vendored
Normal file
24
packages/app-cli/tests/support/plugins/multi_selection/api/JoplinWindow.d.ts
vendored
Normal file
|
@ -0,0 +1,24 @@
|
||||||
|
import Plugin from '../Plugin';
|
||||||
|
export interface Implementation {
|
||||||
|
injectCustomStyles(elementId: string, cssFilePath: string): Promise<void>;
|
||||||
|
}
|
||||||
|
export default class JoplinWindow {
|
||||||
|
private plugin_;
|
||||||
|
private store_;
|
||||||
|
private implementation_;
|
||||||
|
constructor(implementation: Implementation, plugin: Plugin, store: any);
|
||||||
|
/**
|
||||||
|
* Loads a chrome CSS file. It will apply to the window UI elements, except
|
||||||
|
* for the note viewer. It is the same as the "Custom stylesheet for
|
||||||
|
* Joplin-wide app styles" setting. See the [Load CSS Demo](https://github.com/laurent22/joplin/tree/dev/packages/app-cli/tests/support/plugins/load_css)
|
||||||
|
* for an example.
|
||||||
|
*/
|
||||||
|
loadChromeCssFile(filePath: string): Promise<void>;
|
||||||
|
/**
|
||||||
|
* Loads a note CSS file. It will apply to the note viewer, as well as any
|
||||||
|
* exported or printed note. It is the same as the "Custom stylesheet for
|
||||||
|
* rendered Markdown" setting. See the [Load CSS Demo](https://github.com/laurent22/joplin/tree/dev/packages/app-cli/tests/support/plugins/load_css)
|
||||||
|
* for an example.
|
||||||
|
*/
|
||||||
|
loadNoteCssFile(filePath: string): Promise<void>;
|
||||||
|
}
|
|
@ -334,6 +334,17 @@ export enum SettingItemType {
|
||||||
Button = 6,
|
Button = 6,
|
||||||
}
|
}
|
||||||
|
|
||||||
|
export enum AppType {
|
||||||
|
Desktop = 'desktop',
|
||||||
|
Mobile = 'mobile',
|
||||||
|
Cli = 'cli',
|
||||||
|
}
|
||||||
|
|
||||||
|
export enum SettingStorage {
|
||||||
|
Database = 1,
|
||||||
|
File = 2,
|
||||||
|
}
|
||||||
|
|
||||||
// Redefine a simplified interface to mask internal details
|
// Redefine a simplified interface to mask internal details
|
||||||
// and to remove function calls as they would have to be async.
|
// and to remove function calls as they would have to be async.
|
||||||
export interface SettingItem {
|
export interface SettingItem {
|
||||||
|
@ -372,7 +383,7 @@ export interface SettingItem {
|
||||||
/**
|
/**
|
||||||
* Reserved property. Not used at the moment.
|
* Reserved property. Not used at the moment.
|
||||||
*/
|
*/
|
||||||
appTypes?: string[];
|
appTypes?: AppType[];
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Set this to `true` to store secure data, such as passwords. Any such
|
* Set this to `true` to store secure data, such as passwords. Any such
|
||||||
|
@ -393,6 +404,11 @@ export interface SettingItem {
|
||||||
minimum?: number;
|
minimum?: number;
|
||||||
maximum?: number;
|
maximum?: number;
|
||||||
step?: number;
|
step?: number;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Either store the setting in the database or in settings.json. Defaults to database.
|
||||||
|
*/
|
||||||
|
storage?: SettingStorage;
|
||||||
}
|
}
|
||||||
|
|
||||||
export interface SettingSection {
|
export interface SettingSection {
|
||||||
|
@ -419,7 +435,7 @@ export type Path = string[];
|
||||||
// Content Script types
|
// Content Script types
|
||||||
// =================================================================
|
// =================================================================
|
||||||
|
|
||||||
export type PostMessageHandler = (id: string, message: any)=> Promise<any>;
|
export type PostMessageHandler = (message: any)=> Promise<any>;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* When a content script is initialised, it receives a `context` object.
|
* When a content script is initialised, it receives a `context` object.
|
||||||
|
|
|
@ -8,6 +8,8 @@ import JoplinViews from './JoplinViews';
|
||||||
import JoplinInterop from './JoplinInterop';
|
import JoplinInterop from './JoplinInterop';
|
||||||
import JoplinSettings from './JoplinSettings';
|
import JoplinSettings from './JoplinSettings';
|
||||||
import JoplinContentScripts from './JoplinContentScripts';
|
import JoplinContentScripts from './JoplinContentScripts';
|
||||||
|
import JoplinClipboard from './JoplinClipboard';
|
||||||
|
import JoplinWindow from './JoplinWindow';
|
||||||
/**
|
/**
|
||||||
* This is the main entry point to the Joplin API. You can access various services using the provided accessors.
|
* This is the main entry point to the Joplin API. You can access various services using the provided accessors.
|
||||||
*
|
*
|
||||||
|
@ -33,8 +35,12 @@ export default class Joplin {
|
||||||
private interop_;
|
private interop_;
|
||||||
private settings_;
|
private settings_;
|
||||||
private contentScripts_;
|
private contentScripts_;
|
||||||
|
private clipboard_;
|
||||||
|
private window_;
|
||||||
constructor(implementation: any, plugin: Plugin, store: any);
|
constructor(implementation: any, plugin: Plugin, store: any);
|
||||||
get data(): JoplinData;
|
get data(): JoplinData;
|
||||||
|
get clipboard(): JoplinClipboard;
|
||||||
|
get window(): JoplinWindow;
|
||||||
get plugins(): JoplinPlugins;
|
get plugins(): JoplinPlugins;
|
||||||
get workspace(): JoplinWorkspace;
|
get workspace(): JoplinWorkspace;
|
||||||
get contentScripts(): JoplinContentScripts;
|
get contentScripts(): JoplinContentScripts;
|
||||||
|
|
23
packages/app-cli/tests/support/plugins/nativeModule/api/JoplinClipboard.d.ts
vendored
Normal file
23
packages/app-cli/tests/support/plugins/nativeModule/api/JoplinClipboard.d.ts
vendored
Normal file
|
@ -0,0 +1,23 @@
|
||||||
|
export default class JoplinClipboard {
|
||||||
|
private electronClipboard_;
|
||||||
|
private electronNativeImage_;
|
||||||
|
constructor(electronClipboard: any, electronNativeImage: any);
|
||||||
|
readText(): Promise<string>;
|
||||||
|
writeText(text: string): Promise<void>;
|
||||||
|
readHtml(): Promise<string>;
|
||||||
|
writeHtml(html: string): Promise<void>;
|
||||||
|
/**
|
||||||
|
* Returns the image in [data URL](https://developer.mozilla.org/en-US/docs/Web/HTTP/Basics_of_HTTP/Data_URIs) format.
|
||||||
|
*/
|
||||||
|
readImage(): Promise<string>;
|
||||||
|
/**
|
||||||
|
* Takes an image in [data URL](https://developer.mozilla.org/en-US/docs/Web/HTTP/Basics_of_HTTP/Data_URIs) format.
|
||||||
|
*/
|
||||||
|
writeImage(dataUrl: string): Promise<void>;
|
||||||
|
/**
|
||||||
|
* Returns the list available formats (mime types).
|
||||||
|
*
|
||||||
|
* For example [ 'text/plain', 'text/html' ]
|
||||||
|
*/
|
||||||
|
availableFormats(): Promise<string[]>;
|
||||||
|
}
|
|
@ -2,7 +2,7 @@ import Plugin from '../Plugin';
|
||||||
import { ButtonSpec, ViewHandle, DialogResult } from './types';
|
import { ButtonSpec, ViewHandle, DialogResult } from './types';
|
||||||
/**
|
/**
|
||||||
* Allows creating and managing dialogs. A dialog is modal window that
|
* Allows creating and managing dialogs. A dialog is modal window that
|
||||||
* contains a webview and a row of buttons. You can update the update the
|
* contains a webview and a row of buttons. You can update the
|
||||||
* webview using the `setHtml` method. Dialogs are hidden by default and
|
* webview using the `setHtml` method. Dialogs are hidden by default and
|
||||||
* you need to call `open()` to open them. Once the user clicks on a
|
* you need to call `open()` to open them. Once the user clicks on a
|
||||||
* button, the `open` call will return an object indicating what button was
|
* button, the `open` call will return an object indicating what button was
|
||||||
|
@ -59,4 +59,11 @@ export default class JoplinViewsDialogs {
|
||||||
* Opens the dialog
|
* Opens the dialog
|
||||||
*/
|
*/
|
||||||
open(handle: ViewHandle): Promise<DialogResult>;
|
open(handle: ViewHandle): Promise<DialogResult>;
|
||||||
|
/**
|
||||||
|
* Toggle on whether to fit the dialog size to the content or not.
|
||||||
|
* When set to false, the dialog stretches to fill the application
|
||||||
|
* window.
|
||||||
|
* @default true
|
||||||
|
*/
|
||||||
|
setFitToContent(handle: ViewHandle, status: boolean): Promise<boolean>;
|
||||||
}
|
}
|
||||||
|
|
|
@ -0,0 +1,24 @@
|
||||||
|
import Plugin from '../Plugin';
|
||||||
|
export interface Implementation {
|
||||||
|
injectCustomStyles(elementId: string, cssFilePath: string): Promise<void>;
|
||||||
|
}
|
||||||
|
export default class JoplinWindow {
|
||||||
|
private plugin_;
|
||||||
|
private store_;
|
||||||
|
private implementation_;
|
||||||
|
constructor(implementation: Implementation, plugin: Plugin, store: any);
|
||||||
|
/**
|
||||||
|
* Loads a chrome CSS file. It will apply to the window UI elements, except
|
||||||
|
* for the note viewer. It is the same as the "Custom stylesheet for
|
||||||
|
* Joplin-wide app styles" setting. See the [Load CSS Demo](https://github.com/laurent22/joplin/tree/dev/packages/app-cli/tests/support/plugins/load_css)
|
||||||
|
* for an example.
|
||||||
|
*/
|
||||||
|
loadChromeCssFile(filePath: string): Promise<void>;
|
||||||
|
/**
|
||||||
|
* Loads a note CSS file. It will apply to the note viewer, as well as any
|
||||||
|
* exported or printed note. It is the same as the "Custom stylesheet for
|
||||||
|
* rendered Markdown" setting. See the [Load CSS Demo](https://github.com/laurent22/joplin/tree/dev/packages/app-cli/tests/support/plugins/load_css)
|
||||||
|
* for an example.
|
||||||
|
*/
|
||||||
|
loadNoteCssFile(filePath: string): Promise<void>;
|
||||||
|
}
|
|
@ -334,6 +334,17 @@ export enum SettingItemType {
|
||||||
Button = 6,
|
Button = 6,
|
||||||
}
|
}
|
||||||
|
|
||||||
|
export enum AppType {
|
||||||
|
Desktop = 'desktop',
|
||||||
|
Mobile = 'mobile',
|
||||||
|
Cli = 'cli',
|
||||||
|
}
|
||||||
|
|
||||||
|
export enum SettingStorage {
|
||||||
|
Database = 1,
|
||||||
|
File = 2,
|
||||||
|
}
|
||||||
|
|
||||||
// Redefine a simplified interface to mask internal details
|
// Redefine a simplified interface to mask internal details
|
||||||
// and to remove function calls as they would have to be async.
|
// and to remove function calls as they would have to be async.
|
||||||
export interface SettingItem {
|
export interface SettingItem {
|
||||||
|
@ -372,7 +383,7 @@ export interface SettingItem {
|
||||||
/**
|
/**
|
||||||
* Reserved property. Not used at the moment.
|
* Reserved property. Not used at the moment.
|
||||||
*/
|
*/
|
||||||
appTypes?: string[];
|
appTypes?: AppType[];
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Set this to `true` to store secure data, such as passwords. Any such
|
* Set this to `true` to store secure data, such as passwords. Any such
|
||||||
|
@ -393,6 +404,11 @@ export interface SettingItem {
|
||||||
minimum?: number;
|
minimum?: number;
|
||||||
maximum?: number;
|
maximum?: number;
|
||||||
step?: number;
|
step?: number;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Either store the setting in the database or in settings.json. Defaults to database.
|
||||||
|
*/
|
||||||
|
storage?: SettingStorage;
|
||||||
}
|
}
|
||||||
|
|
||||||
export interface SettingSection {
|
export interface SettingSection {
|
||||||
|
@ -419,7 +435,7 @@ export type Path = string[];
|
||||||
// Content Script types
|
// Content Script types
|
||||||
// =================================================================
|
// =================================================================
|
||||||
|
|
||||||
export type PostMessageHandler = (id: string, message: any)=> Promise<any>;
|
export type PostMessageHandler = (message: any)=> Promise<any>;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* When a content script is initialised, it receives a `context` object.
|
* When a content script is initialised, it receives a `context` object.
|
||||||
|
|
|
@ -8,6 +8,8 @@ import JoplinViews from './JoplinViews';
|
||||||
import JoplinInterop from './JoplinInterop';
|
import JoplinInterop from './JoplinInterop';
|
||||||
import JoplinSettings from './JoplinSettings';
|
import JoplinSettings from './JoplinSettings';
|
||||||
import JoplinContentScripts from './JoplinContentScripts';
|
import JoplinContentScripts from './JoplinContentScripts';
|
||||||
|
import JoplinClipboard from './JoplinClipboard';
|
||||||
|
import JoplinWindow from './JoplinWindow';
|
||||||
/**
|
/**
|
||||||
* This is the main entry point to the Joplin API. You can access various services using the provided accessors.
|
* This is the main entry point to the Joplin API. You can access various services using the provided accessors.
|
||||||
*
|
*
|
||||||
|
@ -33,8 +35,12 @@ export default class Joplin {
|
||||||
private interop_;
|
private interop_;
|
||||||
private settings_;
|
private settings_;
|
||||||
private contentScripts_;
|
private contentScripts_;
|
||||||
|
private clipboard_;
|
||||||
|
private window_;
|
||||||
constructor(implementation: any, plugin: Plugin, store: any);
|
constructor(implementation: any, plugin: Plugin, store: any);
|
||||||
get data(): JoplinData;
|
get data(): JoplinData;
|
||||||
|
get clipboard(): JoplinClipboard;
|
||||||
|
get window(): JoplinWindow;
|
||||||
get plugins(): JoplinPlugins;
|
get plugins(): JoplinPlugins;
|
||||||
get workspace(): JoplinWorkspace;
|
get workspace(): JoplinWorkspace;
|
||||||
get contentScripts(): JoplinContentScripts;
|
get contentScripts(): JoplinContentScripts;
|
||||||
|
|
23
packages/app-cli/tests/support/plugins/post_messages/api/JoplinClipboard.d.ts
vendored
Normal file
23
packages/app-cli/tests/support/plugins/post_messages/api/JoplinClipboard.d.ts
vendored
Normal file
|
@ -0,0 +1,23 @@
|
||||||
|
export default class JoplinClipboard {
|
||||||
|
private electronClipboard_;
|
||||||
|
private electronNativeImage_;
|
||||||
|
constructor(electronClipboard: any, electronNativeImage: any);
|
||||||
|
readText(): Promise<string>;
|
||||||
|
writeText(text: string): Promise<void>;
|
||||||
|
readHtml(): Promise<string>;
|
||||||
|
writeHtml(html: string): Promise<void>;
|
||||||
|
/**
|
||||||
|
* Returns the image in [data URL](https://developer.mozilla.org/en-US/docs/Web/HTTP/Basics_of_HTTP/Data_URIs) format.
|
||||||
|
*/
|
||||||
|
readImage(): Promise<string>;
|
||||||
|
/**
|
||||||
|
* Takes an image in [data URL](https://developer.mozilla.org/en-US/docs/Web/HTTP/Basics_of_HTTP/Data_URIs) format.
|
||||||
|
*/
|
||||||
|
writeImage(dataUrl: string): Promise<void>;
|
||||||
|
/**
|
||||||
|
* Returns the list available formats (mime types).
|
||||||
|
*
|
||||||
|
* For example [ 'text/plain', 'text/html' ]
|
||||||
|
*/
|
||||||
|
availableFormats(): Promise<string[]>;
|
||||||
|
}
|
|
@ -2,7 +2,7 @@ import Plugin from '../Plugin';
|
||||||
import { ButtonSpec, ViewHandle, DialogResult } from './types';
|
import { ButtonSpec, ViewHandle, DialogResult } from './types';
|
||||||
/**
|
/**
|
||||||
* Allows creating and managing dialogs. A dialog is modal window that
|
* Allows creating and managing dialogs. A dialog is modal window that
|
||||||
* contains a webview and a row of buttons. You can update the update the
|
* contains a webview and a row of buttons. You can update the
|
||||||
* webview using the `setHtml` method. Dialogs are hidden by default and
|
* webview using the `setHtml` method. Dialogs are hidden by default and
|
||||||
* you need to call `open()` to open them. Once the user clicks on a
|
* you need to call `open()` to open them. Once the user clicks on a
|
||||||
* button, the `open` call will return an object indicating what button was
|
* button, the `open` call will return an object indicating what button was
|
||||||
|
@ -59,4 +59,11 @@ export default class JoplinViewsDialogs {
|
||||||
* Opens the dialog
|
* Opens the dialog
|
||||||
*/
|
*/
|
||||||
open(handle: ViewHandle): Promise<DialogResult>;
|
open(handle: ViewHandle): Promise<DialogResult>;
|
||||||
|
/**
|
||||||
|
* Toggle on whether to fit the dialog size to the content or not.
|
||||||
|
* When set to false, the dialog stretches to fill the application
|
||||||
|
* window.
|
||||||
|
* @default true
|
||||||
|
*/
|
||||||
|
setFitToContent(handle: ViewHandle, status: boolean): Promise<boolean>;
|
||||||
}
|
}
|
||||||
|
|
|
@ -0,0 +1,24 @@
|
||||||
|
import Plugin from '../Plugin';
|
||||||
|
export interface Implementation {
|
||||||
|
injectCustomStyles(elementId: string, cssFilePath: string): Promise<void>;
|
||||||
|
}
|
||||||
|
export default class JoplinWindow {
|
||||||
|
private plugin_;
|
||||||
|
private store_;
|
||||||
|
private implementation_;
|
||||||
|
constructor(implementation: Implementation, plugin: Plugin, store: any);
|
||||||
|
/**
|
||||||
|
* Loads a chrome CSS file. It will apply to the window UI elements, except
|
||||||
|
* for the note viewer. It is the same as the "Custom stylesheet for
|
||||||
|
* Joplin-wide app styles" setting. See the [Load CSS Demo](https://github.com/laurent22/joplin/tree/dev/packages/app-cli/tests/support/plugins/load_css)
|
||||||
|
* for an example.
|
||||||
|
*/
|
||||||
|
loadChromeCssFile(filePath: string): Promise<void>;
|
||||||
|
/**
|
||||||
|
* Loads a note CSS file. It will apply to the note viewer, as well as any
|
||||||
|
* exported or printed note. It is the same as the "Custom stylesheet for
|
||||||
|
* rendered Markdown" setting. See the [Load CSS Demo](https://github.com/laurent22/joplin/tree/dev/packages/app-cli/tests/support/plugins/load_css)
|
||||||
|
* for an example.
|
||||||
|
*/
|
||||||
|
loadNoteCssFile(filePath: string): Promise<void>;
|
||||||
|
}
|
|
@ -334,6 +334,17 @@ export enum SettingItemType {
|
||||||
Button = 6,
|
Button = 6,
|
||||||
}
|
}
|
||||||
|
|
||||||
|
export enum AppType {
|
||||||
|
Desktop = 'desktop',
|
||||||
|
Mobile = 'mobile',
|
||||||
|
Cli = 'cli',
|
||||||
|
}
|
||||||
|
|
||||||
|
export enum SettingStorage {
|
||||||
|
Database = 1,
|
||||||
|
File = 2,
|
||||||
|
}
|
||||||
|
|
||||||
// Redefine a simplified interface to mask internal details
|
// Redefine a simplified interface to mask internal details
|
||||||
// and to remove function calls as they would have to be async.
|
// and to remove function calls as they would have to be async.
|
||||||
export interface SettingItem {
|
export interface SettingItem {
|
||||||
|
@ -372,7 +383,7 @@ export interface SettingItem {
|
||||||
/**
|
/**
|
||||||
* Reserved property. Not used at the moment.
|
* Reserved property. Not used at the moment.
|
||||||
*/
|
*/
|
||||||
appTypes?: string[];
|
appTypes?: AppType[];
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Set this to `true` to store secure data, such as passwords. Any such
|
* Set this to `true` to store secure data, such as passwords. Any such
|
||||||
|
@ -393,6 +404,11 @@ export interface SettingItem {
|
||||||
minimum?: number;
|
minimum?: number;
|
||||||
maximum?: number;
|
maximum?: number;
|
||||||
step?: number;
|
step?: number;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Either store the setting in the database or in settings.json. Defaults to database.
|
||||||
|
*/
|
||||||
|
storage?: SettingStorage;
|
||||||
}
|
}
|
||||||
|
|
||||||
export interface SettingSection {
|
export interface SettingSection {
|
||||||
|
@ -419,7 +435,7 @@ export type Path = string[];
|
||||||
// Content Script types
|
// Content Script types
|
||||||
// =================================================================
|
// =================================================================
|
||||||
|
|
||||||
export type PostMessageHandler = (id: string, message: any)=> Promise<any>;
|
export type PostMessageHandler = (message: any)=> Promise<any>;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* When a content script is initialised, it receives a `context` object.
|
* When a content script is initialised, it receives a `context` object.
|
||||||
|
|
|
@ -8,6 +8,8 @@ import JoplinViews from './JoplinViews';
|
||||||
import JoplinInterop from './JoplinInterop';
|
import JoplinInterop from './JoplinInterop';
|
||||||
import JoplinSettings from './JoplinSettings';
|
import JoplinSettings from './JoplinSettings';
|
||||||
import JoplinContentScripts from './JoplinContentScripts';
|
import JoplinContentScripts from './JoplinContentScripts';
|
||||||
|
import JoplinClipboard from './JoplinClipboard';
|
||||||
|
import JoplinWindow from './JoplinWindow';
|
||||||
/**
|
/**
|
||||||
* This is the main entry point to the Joplin API. You can access various services using the provided accessors.
|
* This is the main entry point to the Joplin API. You can access various services using the provided accessors.
|
||||||
*
|
*
|
||||||
|
@ -33,8 +35,12 @@ export default class Joplin {
|
||||||
private interop_;
|
private interop_;
|
||||||
private settings_;
|
private settings_;
|
||||||
private contentScripts_;
|
private contentScripts_;
|
||||||
|
private clipboard_;
|
||||||
|
private window_;
|
||||||
constructor(implementation: any, plugin: Plugin, store: any);
|
constructor(implementation: any, plugin: Plugin, store: any);
|
||||||
get data(): JoplinData;
|
get data(): JoplinData;
|
||||||
|
get clipboard(): JoplinClipboard;
|
||||||
|
get window(): JoplinWindow;
|
||||||
get plugins(): JoplinPlugins;
|
get plugins(): JoplinPlugins;
|
||||||
get workspace(): JoplinWorkspace;
|
get workspace(): JoplinWorkspace;
|
||||||
get contentScripts(): JoplinContentScripts;
|
get contentScripts(): JoplinContentScripts;
|
||||||
|
|
23
packages/app-cli/tests/support/plugins/register_command/api/JoplinClipboard.d.ts
vendored
Normal file
23
packages/app-cli/tests/support/plugins/register_command/api/JoplinClipboard.d.ts
vendored
Normal file
|
@ -0,0 +1,23 @@
|
||||||
|
export default class JoplinClipboard {
|
||||||
|
private electronClipboard_;
|
||||||
|
private electronNativeImage_;
|
||||||
|
constructor(electronClipboard: any, electronNativeImage: any);
|
||||||
|
readText(): Promise<string>;
|
||||||
|
writeText(text: string): Promise<void>;
|
||||||
|
readHtml(): Promise<string>;
|
||||||
|
writeHtml(html: string): Promise<void>;
|
||||||
|
/**
|
||||||
|
* Returns the image in [data URL](https://developer.mozilla.org/en-US/docs/Web/HTTP/Basics_of_HTTP/Data_URIs) format.
|
||||||
|
*/
|
||||||
|
readImage(): Promise<string>;
|
||||||
|
/**
|
||||||
|
* Takes an image in [data URL](https://developer.mozilla.org/en-US/docs/Web/HTTP/Basics_of_HTTP/Data_URIs) format.
|
||||||
|
*/
|
||||||
|
writeImage(dataUrl: string): Promise<void>;
|
||||||
|
/**
|
||||||
|
* Returns the list available formats (mime types).
|
||||||
|
*
|
||||||
|
* For example [ 'text/plain', 'text/html' ]
|
||||||
|
*/
|
||||||
|
availableFormats(): Promise<string[]>;
|
||||||
|
}
|
|
@ -2,7 +2,7 @@ import Plugin from '../Plugin';
|
||||||
import { ButtonSpec, ViewHandle, DialogResult } from './types';
|
import { ButtonSpec, ViewHandle, DialogResult } from './types';
|
||||||
/**
|
/**
|
||||||
* Allows creating and managing dialogs. A dialog is modal window that
|
* Allows creating and managing dialogs. A dialog is modal window that
|
||||||
* contains a webview and a row of buttons. You can update the update the
|
* contains a webview and a row of buttons. You can update the
|
||||||
* webview using the `setHtml` method. Dialogs are hidden by default and
|
* webview using the `setHtml` method. Dialogs are hidden by default and
|
||||||
* you need to call `open()` to open them. Once the user clicks on a
|
* you need to call `open()` to open them. Once the user clicks on a
|
||||||
* button, the `open` call will return an object indicating what button was
|
* button, the `open` call will return an object indicating what button was
|
||||||
|
@ -59,4 +59,11 @@ export default class JoplinViewsDialogs {
|
||||||
* Opens the dialog
|
* Opens the dialog
|
||||||
*/
|
*/
|
||||||
open(handle: ViewHandle): Promise<DialogResult>;
|
open(handle: ViewHandle): Promise<DialogResult>;
|
||||||
|
/**
|
||||||
|
* Toggle on whether to fit the dialog size to the content or not.
|
||||||
|
* When set to false, the dialog stretches to fill the application
|
||||||
|
* window.
|
||||||
|
* @default true
|
||||||
|
*/
|
||||||
|
setFitToContent(handle: ViewHandle, status: boolean): Promise<boolean>;
|
||||||
}
|
}
|
||||||
|
|
24
packages/app-cli/tests/support/plugins/register_command/api/JoplinWindow.d.ts
vendored
Normal file
24
packages/app-cli/tests/support/plugins/register_command/api/JoplinWindow.d.ts
vendored
Normal file
|
@ -0,0 +1,24 @@
|
||||||
|
import Plugin from '../Plugin';
|
||||||
|
export interface Implementation {
|
||||||
|
injectCustomStyles(elementId: string, cssFilePath: string): Promise<void>;
|
||||||
|
}
|
||||||
|
export default class JoplinWindow {
|
||||||
|
private plugin_;
|
||||||
|
private store_;
|
||||||
|
private implementation_;
|
||||||
|
constructor(implementation: Implementation, plugin: Plugin, store: any);
|
||||||
|
/**
|
||||||
|
* Loads a chrome CSS file. It will apply to the window UI elements, except
|
||||||
|
* for the note viewer. It is the same as the "Custom stylesheet for
|
||||||
|
* Joplin-wide app styles" setting. See the [Load CSS Demo](https://github.com/laurent22/joplin/tree/dev/packages/app-cli/tests/support/plugins/load_css)
|
||||||
|
* for an example.
|
||||||
|
*/
|
||||||
|
loadChromeCssFile(filePath: string): Promise<void>;
|
||||||
|
/**
|
||||||
|
* Loads a note CSS file. It will apply to the note viewer, as well as any
|
||||||
|
* exported or printed note. It is the same as the "Custom stylesheet for
|
||||||
|
* rendered Markdown" setting. See the [Load CSS Demo](https://github.com/laurent22/joplin/tree/dev/packages/app-cli/tests/support/plugins/load_css)
|
||||||
|
* for an example.
|
||||||
|
*/
|
||||||
|
loadNoteCssFile(filePath: string): Promise<void>;
|
||||||
|
}
|
|
@ -334,6 +334,17 @@ export enum SettingItemType {
|
||||||
Button = 6,
|
Button = 6,
|
||||||
}
|
}
|
||||||
|
|
||||||
|
export enum AppType {
|
||||||
|
Desktop = 'desktop',
|
||||||
|
Mobile = 'mobile',
|
||||||
|
Cli = 'cli',
|
||||||
|
}
|
||||||
|
|
||||||
|
export enum SettingStorage {
|
||||||
|
Database = 1,
|
||||||
|
File = 2,
|
||||||
|
}
|
||||||
|
|
||||||
// Redefine a simplified interface to mask internal details
|
// Redefine a simplified interface to mask internal details
|
||||||
// and to remove function calls as they would have to be async.
|
// and to remove function calls as they would have to be async.
|
||||||
export interface SettingItem {
|
export interface SettingItem {
|
||||||
|
@ -372,7 +383,7 @@ export interface SettingItem {
|
||||||
/**
|
/**
|
||||||
* Reserved property. Not used at the moment.
|
* Reserved property. Not used at the moment.
|
||||||
*/
|
*/
|
||||||
appTypes?: string[];
|
appTypes?: AppType[];
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Set this to `true` to store secure data, such as passwords. Any such
|
* Set this to `true` to store secure data, such as passwords. Any such
|
||||||
|
@ -393,6 +404,11 @@ export interface SettingItem {
|
||||||
minimum?: number;
|
minimum?: number;
|
||||||
maximum?: number;
|
maximum?: number;
|
||||||
step?: number;
|
step?: number;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Either store the setting in the database or in settings.json. Defaults to database.
|
||||||
|
*/
|
||||||
|
storage?: SettingStorage;
|
||||||
}
|
}
|
||||||
|
|
||||||
export interface SettingSection {
|
export interface SettingSection {
|
||||||
|
@ -419,7 +435,7 @@ export type Path = string[];
|
||||||
// Content Script types
|
// Content Script types
|
||||||
// =================================================================
|
// =================================================================
|
||||||
|
|
||||||
export type PostMessageHandler = (id: string, message: any)=> Promise<any>;
|
export type PostMessageHandler = (message: any)=> Promise<any>;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* When a content script is initialised, it receives a `context` object.
|
* When a content script is initialised, it receives a `context` object.
|
||||||
|
|
|
@ -8,6 +8,8 @@ import JoplinViews from './JoplinViews';
|
||||||
import JoplinInterop from './JoplinInterop';
|
import JoplinInterop from './JoplinInterop';
|
||||||
import JoplinSettings from './JoplinSettings';
|
import JoplinSettings from './JoplinSettings';
|
||||||
import JoplinContentScripts from './JoplinContentScripts';
|
import JoplinContentScripts from './JoplinContentScripts';
|
||||||
|
import JoplinClipboard from './JoplinClipboard';
|
||||||
|
import JoplinWindow from './JoplinWindow';
|
||||||
/**
|
/**
|
||||||
* This is the main entry point to the Joplin API. You can access various services using the provided accessors.
|
* This is the main entry point to the Joplin API. You can access various services using the provided accessors.
|
||||||
*
|
*
|
||||||
|
@ -33,8 +35,12 @@ export default class Joplin {
|
||||||
private interop_;
|
private interop_;
|
||||||
private settings_;
|
private settings_;
|
||||||
private contentScripts_;
|
private contentScripts_;
|
||||||
|
private clipboard_;
|
||||||
|
private window_;
|
||||||
constructor(implementation: any, plugin: Plugin, store: any);
|
constructor(implementation: any, plugin: Plugin, store: any);
|
||||||
get data(): JoplinData;
|
get data(): JoplinData;
|
||||||
|
get clipboard(): JoplinClipboard;
|
||||||
|
get window(): JoplinWindow;
|
||||||
get plugins(): JoplinPlugins;
|
get plugins(): JoplinPlugins;
|
||||||
get workspace(): JoplinWorkspace;
|
get workspace(): JoplinWorkspace;
|
||||||
get contentScripts(): JoplinContentScripts;
|
get contentScripts(): JoplinContentScripts;
|
||||||
|
|
23
packages/app-cli/tests/support/plugins/selected_text/api/JoplinClipboard.d.ts
vendored
Normal file
23
packages/app-cli/tests/support/plugins/selected_text/api/JoplinClipboard.d.ts
vendored
Normal file
|
@ -0,0 +1,23 @@
|
||||||
|
export default class JoplinClipboard {
|
||||||
|
private electronClipboard_;
|
||||||
|
private electronNativeImage_;
|
||||||
|
constructor(electronClipboard: any, electronNativeImage: any);
|
||||||
|
readText(): Promise<string>;
|
||||||
|
writeText(text: string): Promise<void>;
|
||||||
|
readHtml(): Promise<string>;
|
||||||
|
writeHtml(html: string): Promise<void>;
|
||||||
|
/**
|
||||||
|
* Returns the image in [data URL](https://developer.mozilla.org/en-US/docs/Web/HTTP/Basics_of_HTTP/Data_URIs) format.
|
||||||
|
*/
|
||||||
|
readImage(): Promise<string>;
|
||||||
|
/**
|
||||||
|
* Takes an image in [data URL](https://developer.mozilla.org/en-US/docs/Web/HTTP/Basics_of_HTTP/Data_URIs) format.
|
||||||
|
*/
|
||||||
|
writeImage(dataUrl: string): Promise<void>;
|
||||||
|
/**
|
||||||
|
* Returns the list available formats (mime types).
|
||||||
|
*
|
||||||
|
* For example [ 'text/plain', 'text/html' ]
|
||||||
|
*/
|
||||||
|
availableFormats(): Promise<string[]>;
|
||||||
|
}
|
|
@ -2,7 +2,7 @@ import Plugin from '../Plugin';
|
||||||
import { ButtonSpec, ViewHandle, DialogResult } from './types';
|
import { ButtonSpec, ViewHandle, DialogResult } from './types';
|
||||||
/**
|
/**
|
||||||
* Allows creating and managing dialogs. A dialog is modal window that
|
* Allows creating and managing dialogs. A dialog is modal window that
|
||||||
* contains a webview and a row of buttons. You can update the update the
|
* contains a webview and a row of buttons. You can update the
|
||||||
* webview using the `setHtml` method. Dialogs are hidden by default and
|
* webview using the `setHtml` method. Dialogs are hidden by default and
|
||||||
* you need to call `open()` to open them. Once the user clicks on a
|
* you need to call `open()` to open them. Once the user clicks on a
|
||||||
* button, the `open` call will return an object indicating what button was
|
* button, the `open` call will return an object indicating what button was
|
||||||
|
@ -59,4 +59,11 @@ export default class JoplinViewsDialogs {
|
||||||
* Opens the dialog
|
* Opens the dialog
|
||||||
*/
|
*/
|
||||||
open(handle: ViewHandle): Promise<DialogResult>;
|
open(handle: ViewHandle): Promise<DialogResult>;
|
||||||
|
/**
|
||||||
|
* Toggle on whether to fit the dialog size to the content or not.
|
||||||
|
* When set to false, the dialog stretches to fill the application
|
||||||
|
* window.
|
||||||
|
* @default true
|
||||||
|
*/
|
||||||
|
setFitToContent(handle: ViewHandle, status: boolean): Promise<boolean>;
|
||||||
}
|
}
|
||||||
|
|
|
@ -0,0 +1,24 @@
|
||||||
|
import Plugin from '../Plugin';
|
||||||
|
export interface Implementation {
|
||||||
|
injectCustomStyles(elementId: string, cssFilePath: string): Promise<void>;
|
||||||
|
}
|
||||||
|
export default class JoplinWindow {
|
||||||
|
private plugin_;
|
||||||
|
private store_;
|
||||||
|
private implementation_;
|
||||||
|
constructor(implementation: Implementation, plugin: Plugin, store: any);
|
||||||
|
/**
|
||||||
|
* Loads a chrome CSS file. It will apply to the window UI elements, except
|
||||||
|
* for the note viewer. It is the same as the "Custom stylesheet for
|
||||||
|
* Joplin-wide app styles" setting. See the [Load CSS Demo](https://github.com/laurent22/joplin/tree/dev/packages/app-cli/tests/support/plugins/load_css)
|
||||||
|
* for an example.
|
||||||
|
*/
|
||||||
|
loadChromeCssFile(filePath: string): Promise<void>;
|
||||||
|
/**
|
||||||
|
* Loads a note CSS file. It will apply to the note viewer, as well as any
|
||||||
|
* exported or printed note. It is the same as the "Custom stylesheet for
|
||||||
|
* rendered Markdown" setting. See the [Load CSS Demo](https://github.com/laurent22/joplin/tree/dev/packages/app-cli/tests/support/plugins/load_css)
|
||||||
|
* for an example.
|
||||||
|
*/
|
||||||
|
loadNoteCssFile(filePath: string): Promise<void>;
|
||||||
|
}
|
|
@ -334,6 +334,17 @@ export enum SettingItemType {
|
||||||
Button = 6,
|
Button = 6,
|
||||||
}
|
}
|
||||||
|
|
||||||
|
export enum AppType {
|
||||||
|
Desktop = 'desktop',
|
||||||
|
Mobile = 'mobile',
|
||||||
|
Cli = 'cli',
|
||||||
|
}
|
||||||
|
|
||||||
|
export enum SettingStorage {
|
||||||
|
Database = 1,
|
||||||
|
File = 2,
|
||||||
|
}
|
||||||
|
|
||||||
// Redefine a simplified interface to mask internal details
|
// Redefine a simplified interface to mask internal details
|
||||||
// and to remove function calls as they would have to be async.
|
// and to remove function calls as they would have to be async.
|
||||||
export interface SettingItem {
|
export interface SettingItem {
|
||||||
|
@ -372,7 +383,7 @@ export interface SettingItem {
|
||||||
/**
|
/**
|
||||||
* Reserved property. Not used at the moment.
|
* Reserved property. Not used at the moment.
|
||||||
*/
|
*/
|
||||||
appTypes?: string[];
|
appTypes?: AppType[];
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Set this to `true` to store secure data, such as passwords. Any such
|
* Set this to `true` to store secure data, such as passwords. Any such
|
||||||
|
@ -393,6 +404,11 @@ export interface SettingItem {
|
||||||
minimum?: number;
|
minimum?: number;
|
||||||
maximum?: number;
|
maximum?: number;
|
||||||
step?: number;
|
step?: number;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Either store the setting in the database or in settings.json. Defaults to database.
|
||||||
|
*/
|
||||||
|
storage?: SettingStorage;
|
||||||
}
|
}
|
||||||
|
|
||||||
export interface SettingSection {
|
export interface SettingSection {
|
||||||
|
@ -419,7 +435,7 @@ export type Path = string[];
|
||||||
// Content Script types
|
// Content Script types
|
||||||
// =================================================================
|
// =================================================================
|
||||||
|
|
||||||
export type PostMessageHandler = (id: string, message: any)=> Promise<any>;
|
export type PostMessageHandler = (message: any)=> Promise<any>;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* When a content script is initialised, it receives a `context` object.
|
* When a content script is initialised, it receives a `context` object.
|
||||||
|
|
|
@ -8,6 +8,8 @@ import JoplinViews from './JoplinViews';
|
||||||
import JoplinInterop from './JoplinInterop';
|
import JoplinInterop from './JoplinInterop';
|
||||||
import JoplinSettings from './JoplinSettings';
|
import JoplinSettings from './JoplinSettings';
|
||||||
import JoplinContentScripts from './JoplinContentScripts';
|
import JoplinContentScripts from './JoplinContentScripts';
|
||||||
|
import JoplinClipboard from './JoplinClipboard';
|
||||||
|
import JoplinWindow from './JoplinWindow';
|
||||||
/**
|
/**
|
||||||
* This is the main entry point to the Joplin API. You can access various services using the provided accessors.
|
* This is the main entry point to the Joplin API. You can access various services using the provided accessors.
|
||||||
*
|
*
|
||||||
|
@ -33,8 +35,12 @@ export default class Joplin {
|
||||||
private interop_;
|
private interop_;
|
||||||
private settings_;
|
private settings_;
|
||||||
private contentScripts_;
|
private contentScripts_;
|
||||||
|
private clipboard_;
|
||||||
|
private window_;
|
||||||
constructor(implementation: any, plugin: Plugin, store: any);
|
constructor(implementation: any, plugin: Plugin, store: any);
|
||||||
get data(): JoplinData;
|
get data(): JoplinData;
|
||||||
|
get clipboard(): JoplinClipboard;
|
||||||
|
get window(): JoplinWindow;
|
||||||
get plugins(): JoplinPlugins;
|
get plugins(): JoplinPlugins;
|
||||||
get workspace(): JoplinWorkspace;
|
get workspace(): JoplinWorkspace;
|
||||||
get contentScripts(): JoplinContentScripts;
|
get contentScripts(): JoplinContentScripts;
|
||||||
|
|
|
@ -0,0 +1,23 @@
|
||||||
|
export default class JoplinClipboard {
|
||||||
|
private electronClipboard_;
|
||||||
|
private electronNativeImage_;
|
||||||
|
constructor(electronClipboard: any, electronNativeImage: any);
|
||||||
|
readText(): Promise<string>;
|
||||||
|
writeText(text: string): Promise<void>;
|
||||||
|
readHtml(): Promise<string>;
|
||||||
|
writeHtml(html: string): Promise<void>;
|
||||||
|
/**
|
||||||
|
* Returns the image in [data URL](https://developer.mozilla.org/en-US/docs/Web/HTTP/Basics_of_HTTP/Data_URIs) format.
|
||||||
|
*/
|
||||||
|
readImage(): Promise<string>;
|
||||||
|
/**
|
||||||
|
* Takes an image in [data URL](https://developer.mozilla.org/en-US/docs/Web/HTTP/Basics_of_HTTP/Data_URIs) format.
|
||||||
|
*/
|
||||||
|
writeImage(dataUrl: string): Promise<void>;
|
||||||
|
/**
|
||||||
|
* Returns the list available formats (mime types).
|
||||||
|
*
|
||||||
|
* For example [ 'text/plain', 'text/html' ]
|
||||||
|
*/
|
||||||
|
availableFormats(): Promise<string[]>;
|
||||||
|
}
|
|
@ -2,7 +2,7 @@ import Plugin from '../Plugin';
|
||||||
import { ButtonSpec, ViewHandle, DialogResult } from './types';
|
import { ButtonSpec, ViewHandle, DialogResult } from './types';
|
||||||
/**
|
/**
|
||||||
* Allows creating and managing dialogs. A dialog is modal window that
|
* Allows creating and managing dialogs. A dialog is modal window that
|
||||||
* contains a webview and a row of buttons. You can update the update the
|
* contains a webview and a row of buttons. You can update the
|
||||||
* webview using the `setHtml` method. Dialogs are hidden by default and
|
* webview using the `setHtml` method. Dialogs are hidden by default and
|
||||||
* you need to call `open()` to open them. Once the user clicks on a
|
* you need to call `open()` to open them. Once the user clicks on a
|
||||||
* button, the `open` call will return an object indicating what button was
|
* button, the `open` call will return an object indicating what button was
|
||||||
|
@ -59,4 +59,11 @@ export default class JoplinViewsDialogs {
|
||||||
* Opens the dialog
|
* Opens the dialog
|
||||||
*/
|
*/
|
||||||
open(handle: ViewHandle): Promise<DialogResult>;
|
open(handle: ViewHandle): Promise<DialogResult>;
|
||||||
|
/**
|
||||||
|
* Toggle on whether to fit the dialog size to the content or not.
|
||||||
|
* When set to false, the dialog stretches to fill the application
|
||||||
|
* window.
|
||||||
|
* @default true
|
||||||
|
*/
|
||||||
|
setFitToContent(handle: ViewHandle, status: boolean): Promise<boolean>;
|
||||||
}
|
}
|
||||||
|
|
|
@ -0,0 +1,24 @@
|
||||||
|
import Plugin from '../Plugin';
|
||||||
|
export interface Implementation {
|
||||||
|
injectCustomStyles(elementId: string, cssFilePath: string): Promise<void>;
|
||||||
|
}
|
||||||
|
export default class JoplinWindow {
|
||||||
|
private plugin_;
|
||||||
|
private store_;
|
||||||
|
private implementation_;
|
||||||
|
constructor(implementation: Implementation, plugin: Plugin, store: any);
|
||||||
|
/**
|
||||||
|
* Loads a chrome CSS file. It will apply to the window UI elements, except
|
||||||
|
* for the note viewer. It is the same as the "Custom stylesheet for
|
||||||
|
* Joplin-wide app styles" setting. See the [Load CSS Demo](https://github.com/laurent22/joplin/tree/dev/packages/app-cli/tests/support/plugins/load_css)
|
||||||
|
* for an example.
|
||||||
|
*/
|
||||||
|
loadChromeCssFile(filePath: string): Promise<void>;
|
||||||
|
/**
|
||||||
|
* Loads a note CSS file. It will apply to the note viewer, as well as any
|
||||||
|
* exported or printed note. It is the same as the "Custom stylesheet for
|
||||||
|
* rendered Markdown" setting. See the [Load CSS Demo](https://github.com/laurent22/joplin/tree/dev/packages/app-cli/tests/support/plugins/load_css)
|
||||||
|
* for an example.
|
||||||
|
*/
|
||||||
|
loadNoteCssFile(filePath: string): Promise<void>;
|
||||||
|
}
|
|
@ -334,6 +334,17 @@ export enum SettingItemType {
|
||||||
Button = 6,
|
Button = 6,
|
||||||
}
|
}
|
||||||
|
|
||||||
|
export enum AppType {
|
||||||
|
Desktop = 'desktop',
|
||||||
|
Mobile = 'mobile',
|
||||||
|
Cli = 'cli',
|
||||||
|
}
|
||||||
|
|
||||||
|
export enum SettingStorage {
|
||||||
|
Database = 1,
|
||||||
|
File = 2,
|
||||||
|
}
|
||||||
|
|
||||||
// Redefine a simplified interface to mask internal details
|
// Redefine a simplified interface to mask internal details
|
||||||
// and to remove function calls as they would have to be async.
|
// and to remove function calls as they would have to be async.
|
||||||
export interface SettingItem {
|
export interface SettingItem {
|
||||||
|
@ -372,7 +383,7 @@ export interface SettingItem {
|
||||||
/**
|
/**
|
||||||
* Reserved property. Not used at the moment.
|
* Reserved property. Not used at the moment.
|
||||||
*/
|
*/
|
||||||
appTypes?: string[];
|
appTypes?: AppType[];
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Set this to `true` to store secure data, such as passwords. Any such
|
* Set this to `true` to store secure data, such as passwords. Any such
|
||||||
|
@ -393,6 +404,11 @@ export interface SettingItem {
|
||||||
minimum?: number;
|
minimum?: number;
|
||||||
maximum?: number;
|
maximum?: number;
|
||||||
step?: number;
|
step?: number;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Either store the setting in the database or in settings.json. Defaults to database.
|
||||||
|
*/
|
||||||
|
storage?: SettingStorage;
|
||||||
}
|
}
|
||||||
|
|
||||||
export interface SettingSection {
|
export interface SettingSection {
|
||||||
|
@ -419,7 +435,7 @@ export type Path = string[];
|
||||||
// Content Script types
|
// Content Script types
|
||||||
// =================================================================
|
// =================================================================
|
||||||
|
|
||||||
export type PostMessageHandler = (id: string, message: any)=> Promise<any>;
|
export type PostMessageHandler = (message: any)=> Promise<any>;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* When a content script is initialised, it receives a `context` object.
|
* When a content script is initialised, it receives a `context` object.
|
||||||
|
|
|
@ -8,6 +8,8 @@ import JoplinViews from './JoplinViews';
|
||||||
import JoplinInterop from './JoplinInterop';
|
import JoplinInterop from './JoplinInterop';
|
||||||
import JoplinSettings from './JoplinSettings';
|
import JoplinSettings from './JoplinSettings';
|
||||||
import JoplinContentScripts from './JoplinContentScripts';
|
import JoplinContentScripts from './JoplinContentScripts';
|
||||||
|
import JoplinClipboard from './JoplinClipboard';
|
||||||
|
import JoplinWindow from './JoplinWindow';
|
||||||
/**
|
/**
|
||||||
* This is the main entry point to the Joplin API. You can access various services using the provided accessors.
|
* This is the main entry point to the Joplin API. You can access various services using the provided accessors.
|
||||||
*
|
*
|
||||||
|
@ -33,8 +35,12 @@ export default class Joplin {
|
||||||
private interop_;
|
private interop_;
|
||||||
private settings_;
|
private settings_;
|
||||||
private contentScripts_;
|
private contentScripts_;
|
||||||
|
private clipboard_;
|
||||||
|
private window_;
|
||||||
constructor(implementation: any, plugin: Plugin, store: any);
|
constructor(implementation: any, plugin: Plugin, store: any);
|
||||||
get data(): JoplinData;
|
get data(): JoplinData;
|
||||||
|
get clipboard(): JoplinClipboard;
|
||||||
|
get window(): JoplinWindow;
|
||||||
get plugins(): JoplinPlugins;
|
get plugins(): JoplinPlugins;
|
||||||
get workspace(): JoplinWorkspace;
|
get workspace(): JoplinWorkspace;
|
||||||
get contentScripts(): JoplinContentScripts;
|
get contentScripts(): JoplinContentScripts;
|
||||||
|
|
|
@ -0,0 +1,23 @@
|
||||||
|
export default class JoplinClipboard {
|
||||||
|
private electronClipboard_;
|
||||||
|
private electronNativeImage_;
|
||||||
|
constructor(electronClipboard: any, electronNativeImage: any);
|
||||||
|
readText(): Promise<string>;
|
||||||
|
writeText(text: string): Promise<void>;
|
||||||
|
readHtml(): Promise<string>;
|
||||||
|
writeHtml(html: string): Promise<void>;
|
||||||
|
/**
|
||||||
|
* Returns the image in [data URL](https://developer.mozilla.org/en-US/docs/Web/HTTP/Basics_of_HTTP/Data_URIs) format.
|
||||||
|
*/
|
||||||
|
readImage(): Promise<string>;
|
||||||
|
/**
|
||||||
|
* Takes an image in [data URL](https://developer.mozilla.org/en-US/docs/Web/HTTP/Basics_of_HTTP/Data_URIs) format.
|
||||||
|
*/
|
||||||
|
writeImage(dataUrl: string): Promise<void>;
|
||||||
|
/**
|
||||||
|
* Returns the list available formats (mime types).
|
||||||
|
*
|
||||||
|
* For example [ 'text/plain', 'text/html' ]
|
||||||
|
*/
|
||||||
|
availableFormats(): Promise<string[]>;
|
||||||
|
}
|
|
@ -2,7 +2,7 @@ import Plugin from '../Plugin';
|
||||||
import { ButtonSpec, ViewHandle, DialogResult } from './types';
|
import { ButtonSpec, ViewHandle, DialogResult } from './types';
|
||||||
/**
|
/**
|
||||||
* Allows creating and managing dialogs. A dialog is modal window that
|
* Allows creating and managing dialogs. A dialog is modal window that
|
||||||
* contains a webview and a row of buttons. You can update the update the
|
* contains a webview and a row of buttons. You can update the
|
||||||
* webview using the `setHtml` method. Dialogs are hidden by default and
|
* webview using the `setHtml` method. Dialogs are hidden by default and
|
||||||
* you need to call `open()` to open them. Once the user clicks on a
|
* you need to call `open()` to open them. Once the user clicks on a
|
||||||
* button, the `open` call will return an object indicating what button was
|
* button, the `open` call will return an object indicating what button was
|
||||||
|
@ -59,4 +59,11 @@ export default class JoplinViewsDialogs {
|
||||||
* Opens the dialog
|
* Opens the dialog
|
||||||
*/
|
*/
|
||||||
open(handle: ViewHandle): Promise<DialogResult>;
|
open(handle: ViewHandle): Promise<DialogResult>;
|
||||||
|
/**
|
||||||
|
* Toggle on whether to fit the dialog size to the content or not.
|
||||||
|
* When set to false, the dialog stretches to fill the application
|
||||||
|
* window.
|
||||||
|
* @default true
|
||||||
|
*/
|
||||||
|
setFitToContent(handle: ViewHandle, status: boolean): Promise<boolean>;
|
||||||
}
|
}
|
||||||
|
|
|
@ -0,0 +1,24 @@
|
||||||
|
import Plugin from '../Plugin';
|
||||||
|
export interface Implementation {
|
||||||
|
injectCustomStyles(elementId: string, cssFilePath: string): Promise<void>;
|
||||||
|
}
|
||||||
|
export default class JoplinWindow {
|
||||||
|
private plugin_;
|
||||||
|
private store_;
|
||||||
|
private implementation_;
|
||||||
|
constructor(implementation: Implementation, plugin: Plugin, store: any);
|
||||||
|
/**
|
||||||
|
* Loads a chrome CSS file. It will apply to the window UI elements, except
|
||||||
|
* for the note viewer. It is the same as the "Custom stylesheet for
|
||||||
|
* Joplin-wide app styles" setting. See the [Load CSS Demo](https://github.com/laurent22/joplin/tree/dev/packages/app-cli/tests/support/plugins/load_css)
|
||||||
|
* for an example.
|
||||||
|
*/
|
||||||
|
loadChromeCssFile(filePath: string): Promise<void>;
|
||||||
|
/**
|
||||||
|
* Loads a note CSS file. It will apply to the note viewer, as well as any
|
||||||
|
* exported or printed note. It is the same as the "Custom stylesheet for
|
||||||
|
* rendered Markdown" setting. See the [Load CSS Demo](https://github.com/laurent22/joplin/tree/dev/packages/app-cli/tests/support/plugins/load_css)
|
||||||
|
* for an example.
|
||||||
|
*/
|
||||||
|
loadNoteCssFile(filePath: string): Promise<void>;
|
||||||
|
}
|
|
@ -334,6 +334,17 @@ export enum SettingItemType {
|
||||||
Button = 6,
|
Button = 6,
|
||||||
}
|
}
|
||||||
|
|
||||||
|
export enum AppType {
|
||||||
|
Desktop = 'desktop',
|
||||||
|
Mobile = 'mobile',
|
||||||
|
Cli = 'cli',
|
||||||
|
}
|
||||||
|
|
||||||
|
export enum SettingStorage {
|
||||||
|
Database = 1,
|
||||||
|
File = 2,
|
||||||
|
}
|
||||||
|
|
||||||
// Redefine a simplified interface to mask internal details
|
// Redefine a simplified interface to mask internal details
|
||||||
// and to remove function calls as they would have to be async.
|
// and to remove function calls as they would have to be async.
|
||||||
export interface SettingItem {
|
export interface SettingItem {
|
||||||
|
@ -372,7 +383,7 @@ export interface SettingItem {
|
||||||
/**
|
/**
|
||||||
* Reserved property. Not used at the moment.
|
* Reserved property. Not used at the moment.
|
||||||
*/
|
*/
|
||||||
appTypes?: string[];
|
appTypes?: AppType[];
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Set this to `true` to store secure data, such as passwords. Any such
|
* Set this to `true` to store secure data, such as passwords. Any such
|
||||||
|
@ -393,6 +404,11 @@ export interface SettingItem {
|
||||||
minimum?: number;
|
minimum?: number;
|
||||||
maximum?: number;
|
maximum?: number;
|
||||||
step?: number;
|
step?: number;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Either store the setting in the database or in settings.json. Defaults to database.
|
||||||
|
*/
|
||||||
|
storage?: SettingStorage;
|
||||||
}
|
}
|
||||||
|
|
||||||
export interface SettingSection {
|
export interface SettingSection {
|
||||||
|
@ -419,7 +435,7 @@ export type Path = string[];
|
||||||
// Content Script types
|
// Content Script types
|
||||||
// =================================================================
|
// =================================================================
|
||||||
|
|
||||||
export type PostMessageHandler = (id: string, message: any)=> Promise<any>;
|
export type PostMessageHandler = (message: any)=> Promise<any>;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* When a content script is initialised, it receives a `context` object.
|
* When a content script is initialised, it receives a `context` object.
|
||||||
|
|
|
@ -8,6 +8,8 @@ import JoplinViews from './JoplinViews';
|
||||||
import JoplinInterop from './JoplinInterop';
|
import JoplinInterop from './JoplinInterop';
|
||||||
import JoplinSettings from './JoplinSettings';
|
import JoplinSettings from './JoplinSettings';
|
||||||
import JoplinContentScripts from './JoplinContentScripts';
|
import JoplinContentScripts from './JoplinContentScripts';
|
||||||
|
import JoplinClipboard from './JoplinClipboard';
|
||||||
|
import JoplinWindow from './JoplinWindow';
|
||||||
/**
|
/**
|
||||||
* This is the main entry point to the Joplin API. You can access various services using the provided accessors.
|
* This is the main entry point to the Joplin API. You can access various services using the provided accessors.
|
||||||
*
|
*
|
||||||
|
@ -33,8 +35,12 @@ export default class Joplin {
|
||||||
private interop_;
|
private interop_;
|
||||||
private settings_;
|
private settings_;
|
||||||
private contentScripts_;
|
private contentScripts_;
|
||||||
|
private clipboard_;
|
||||||
|
private window_;
|
||||||
constructor(implementation: any, plugin: Plugin, store: any);
|
constructor(implementation: any, plugin: Plugin, store: any);
|
||||||
get data(): JoplinData;
|
get data(): JoplinData;
|
||||||
|
get clipboard(): JoplinClipboard;
|
||||||
|
get window(): JoplinWindow;
|
||||||
get plugins(): JoplinPlugins;
|
get plugins(): JoplinPlugins;
|
||||||
get workspace(): JoplinWorkspace;
|
get workspace(): JoplinWorkspace;
|
||||||
get contentScripts(): JoplinContentScripts;
|
get contentScripts(): JoplinContentScripts;
|
||||||
|
|
23
packages/app-cli/tests/support/plugins/withExternalModules/api/JoplinClipboard.d.ts
vendored
Normal file
23
packages/app-cli/tests/support/plugins/withExternalModules/api/JoplinClipboard.d.ts
vendored
Normal file
|
@ -0,0 +1,23 @@
|
||||||
|
export default class JoplinClipboard {
|
||||||
|
private electronClipboard_;
|
||||||
|
private electronNativeImage_;
|
||||||
|
constructor(electronClipboard: any, electronNativeImage: any);
|
||||||
|
readText(): Promise<string>;
|
||||||
|
writeText(text: string): Promise<void>;
|
||||||
|
readHtml(): Promise<string>;
|
||||||
|
writeHtml(html: string): Promise<void>;
|
||||||
|
/**
|
||||||
|
* Returns the image in [data URL](https://developer.mozilla.org/en-US/docs/Web/HTTP/Basics_of_HTTP/Data_URIs) format.
|
||||||
|
*/
|
||||||
|
readImage(): Promise<string>;
|
||||||
|
/**
|
||||||
|
* Takes an image in [data URL](https://developer.mozilla.org/en-US/docs/Web/HTTP/Basics_of_HTTP/Data_URIs) format.
|
||||||
|
*/
|
||||||
|
writeImage(dataUrl: string): Promise<void>;
|
||||||
|
/**
|
||||||
|
* Returns the list available formats (mime types).
|
||||||
|
*
|
||||||
|
* For example [ 'text/plain', 'text/html' ]
|
||||||
|
*/
|
||||||
|
availableFormats(): Promise<string[]>;
|
||||||
|
}
|
|
@ -2,7 +2,7 @@ import Plugin from '../Plugin';
|
||||||
import { ButtonSpec, ViewHandle, DialogResult } from './types';
|
import { ButtonSpec, ViewHandle, DialogResult } from './types';
|
||||||
/**
|
/**
|
||||||
* Allows creating and managing dialogs. A dialog is modal window that
|
* Allows creating and managing dialogs. A dialog is modal window that
|
||||||
* contains a webview and a row of buttons. You can update the update the
|
* contains a webview and a row of buttons. You can update the
|
||||||
* webview using the `setHtml` method. Dialogs are hidden by default and
|
* webview using the `setHtml` method. Dialogs are hidden by default and
|
||||||
* you need to call `open()` to open them. Once the user clicks on a
|
* you need to call `open()` to open them. Once the user clicks on a
|
||||||
* button, the `open` call will return an object indicating what button was
|
* button, the `open` call will return an object indicating what button was
|
||||||
|
@ -59,4 +59,11 @@ export default class JoplinViewsDialogs {
|
||||||
* Opens the dialog
|
* Opens the dialog
|
||||||
*/
|
*/
|
||||||
open(handle: ViewHandle): Promise<DialogResult>;
|
open(handle: ViewHandle): Promise<DialogResult>;
|
||||||
|
/**
|
||||||
|
* Toggle on whether to fit the dialog size to the content or not.
|
||||||
|
* When set to false, the dialog stretches to fill the application
|
||||||
|
* window.
|
||||||
|
* @default true
|
||||||
|
*/
|
||||||
|
setFitToContent(handle: ViewHandle, status: boolean): Promise<boolean>;
|
||||||
}
|
}
|
||||||
|
|
24
packages/app-cli/tests/support/plugins/withExternalModules/api/JoplinWindow.d.ts
vendored
Normal file
24
packages/app-cli/tests/support/plugins/withExternalModules/api/JoplinWindow.d.ts
vendored
Normal file
|
@ -0,0 +1,24 @@
|
||||||
|
import Plugin from '../Plugin';
|
||||||
|
export interface Implementation {
|
||||||
|
injectCustomStyles(elementId: string, cssFilePath: string): Promise<void>;
|
||||||
|
}
|
||||||
|
export default class JoplinWindow {
|
||||||
|
private plugin_;
|
||||||
|
private store_;
|
||||||
|
private implementation_;
|
||||||
|
constructor(implementation: Implementation, plugin: Plugin, store: any);
|
||||||
|
/**
|
||||||
|
* Loads a chrome CSS file. It will apply to the window UI elements, except
|
||||||
|
* for the note viewer. It is the same as the "Custom stylesheet for
|
||||||
|
* Joplin-wide app styles" setting. See the [Load CSS Demo](https://github.com/laurent22/joplin/tree/dev/packages/app-cli/tests/support/plugins/load_css)
|
||||||
|
* for an example.
|
||||||
|
*/
|
||||||
|
loadChromeCssFile(filePath: string): Promise<void>;
|
||||||
|
/**
|
||||||
|
* Loads a note CSS file. It will apply to the note viewer, as well as any
|
||||||
|
* exported or printed note. It is the same as the "Custom stylesheet for
|
||||||
|
* rendered Markdown" setting. See the [Load CSS Demo](https://github.com/laurent22/joplin/tree/dev/packages/app-cli/tests/support/plugins/load_css)
|
||||||
|
* for an example.
|
||||||
|
*/
|
||||||
|
loadNoteCssFile(filePath: string): Promise<void>;
|
||||||
|
}
|
|
@ -334,6 +334,17 @@ export enum SettingItemType {
|
||||||
Button = 6,
|
Button = 6,
|
||||||
}
|
}
|
||||||
|
|
||||||
|
export enum AppType {
|
||||||
|
Desktop = 'desktop',
|
||||||
|
Mobile = 'mobile',
|
||||||
|
Cli = 'cli',
|
||||||
|
}
|
||||||
|
|
||||||
|
export enum SettingStorage {
|
||||||
|
Database = 1,
|
||||||
|
File = 2,
|
||||||
|
}
|
||||||
|
|
||||||
// Redefine a simplified interface to mask internal details
|
// Redefine a simplified interface to mask internal details
|
||||||
// and to remove function calls as they would have to be async.
|
// and to remove function calls as they would have to be async.
|
||||||
export interface SettingItem {
|
export interface SettingItem {
|
||||||
|
@ -372,7 +383,7 @@ export interface SettingItem {
|
||||||
/**
|
/**
|
||||||
* Reserved property. Not used at the moment.
|
* Reserved property. Not used at the moment.
|
||||||
*/
|
*/
|
||||||
appTypes?: string[];
|
appTypes?: AppType[];
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Set this to `true` to store secure data, such as passwords. Any such
|
* Set this to `true` to store secure data, such as passwords. Any such
|
||||||
|
@ -393,6 +404,11 @@ export interface SettingItem {
|
||||||
minimum?: number;
|
minimum?: number;
|
||||||
maximum?: number;
|
maximum?: number;
|
||||||
step?: number;
|
step?: number;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Either store the setting in the database or in settings.json. Defaults to database.
|
||||||
|
*/
|
||||||
|
storage?: SettingStorage;
|
||||||
}
|
}
|
||||||
|
|
||||||
export interface SettingSection {
|
export interface SettingSection {
|
||||||
|
@ -419,7 +435,7 @@ export type Path = string[];
|
||||||
// Content Script types
|
// Content Script types
|
||||||
// =================================================================
|
// =================================================================
|
||||||
|
|
||||||
export type PostMessageHandler = (id: string, message: any)=> Promise<any>;
|
export type PostMessageHandler = (message: any)=> Promise<any>;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* When a content script is initialised, it receives a `context` object.
|
* When a content script is initialised, it receives a `context` object.
|
||||||
|
|
|
@ -486,13 +486,13 @@
|
||||||
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
|
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
|
||||||
CLANG_ENABLE_MODULES = YES;
|
CLANG_ENABLE_MODULES = YES;
|
||||||
CODE_SIGN_ENTITLEMENTS = Joplin/Joplin.entitlements;
|
CODE_SIGN_ENTITLEMENTS = Joplin/Joplin.entitlements;
|
||||||
CURRENT_PROJECT_VERSION = 70;
|
CURRENT_PROJECT_VERSION = 71;
|
||||||
DEVELOPMENT_TEAM = A9BXAFS6CT;
|
DEVELOPMENT_TEAM = A9BXAFS6CT;
|
||||||
ENABLE_BITCODE = NO;
|
ENABLE_BITCODE = NO;
|
||||||
INFOPLIST_FILE = Joplin/Info.plist;
|
INFOPLIST_FILE = Joplin/Info.plist;
|
||||||
IPHONEOS_DEPLOYMENT_TARGET = 9.0;
|
IPHONEOS_DEPLOYMENT_TARGET = 9.0;
|
||||||
LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks";
|
LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks";
|
||||||
MARKETING_VERSION = 12.2.0;
|
MARKETING_VERSION = 12.2.1;
|
||||||
OTHER_LDFLAGS = (
|
OTHER_LDFLAGS = (
|
||||||
"$(inherited)",
|
"$(inherited)",
|
||||||
"-ObjC",
|
"-ObjC",
|
||||||
|
@ -514,12 +514,12 @@
|
||||||
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
|
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
|
||||||
CLANG_ENABLE_MODULES = YES;
|
CLANG_ENABLE_MODULES = YES;
|
||||||
CODE_SIGN_ENTITLEMENTS = Joplin/Joplin.entitlements;
|
CODE_SIGN_ENTITLEMENTS = Joplin/Joplin.entitlements;
|
||||||
CURRENT_PROJECT_VERSION = 70;
|
CURRENT_PROJECT_VERSION = 71;
|
||||||
DEVELOPMENT_TEAM = A9BXAFS6CT;
|
DEVELOPMENT_TEAM = A9BXAFS6CT;
|
||||||
INFOPLIST_FILE = Joplin/Info.plist;
|
INFOPLIST_FILE = Joplin/Info.plist;
|
||||||
IPHONEOS_DEPLOYMENT_TARGET = 9.0;
|
IPHONEOS_DEPLOYMENT_TARGET = 9.0;
|
||||||
LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks";
|
LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks";
|
||||||
MARKETING_VERSION = 12.2.0;
|
MARKETING_VERSION = 12.2.1;
|
||||||
OTHER_LDFLAGS = (
|
OTHER_LDFLAGS = (
|
||||||
"$(inherited)",
|
"$(inherited)",
|
||||||
"-ObjC",
|
"-ObjC",
|
||||||
|
@ -659,14 +659,14 @@
|
||||||
CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE;
|
CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE;
|
||||||
CODE_SIGN_ENTITLEMENTS = ShareExtension/ShareExtension.entitlements;
|
CODE_SIGN_ENTITLEMENTS = ShareExtension/ShareExtension.entitlements;
|
||||||
CODE_SIGN_STYLE = Automatic;
|
CODE_SIGN_STYLE = Automatic;
|
||||||
CURRENT_PROJECT_VERSION = 70;
|
CURRENT_PROJECT_VERSION = 71;
|
||||||
DEBUG_INFORMATION_FORMAT = dwarf;
|
DEBUG_INFORMATION_FORMAT = dwarf;
|
||||||
DEVELOPMENT_TEAM = A9BXAFS6CT;
|
DEVELOPMENT_TEAM = A9BXAFS6CT;
|
||||||
GCC_C_LANGUAGE_STANDARD = gnu11;
|
GCC_C_LANGUAGE_STANDARD = gnu11;
|
||||||
INFOPLIST_FILE = ShareExtension/Info.plist;
|
INFOPLIST_FILE = ShareExtension/Info.plist;
|
||||||
IPHONEOS_DEPLOYMENT_TARGET = 9.0;
|
IPHONEOS_DEPLOYMENT_TARGET = 9.0;
|
||||||
LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @executable_path/../../Frameworks";
|
LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @executable_path/../../Frameworks";
|
||||||
MARKETING_VERSION = 12.2.0;
|
MARKETING_VERSION = 12.2.1;
|
||||||
MTL_ENABLE_DEBUG_INFO = INCLUDE_SOURCE;
|
MTL_ENABLE_DEBUG_INFO = INCLUDE_SOURCE;
|
||||||
MTL_FAST_MATH = YES;
|
MTL_FAST_MATH = YES;
|
||||||
PRODUCT_BUNDLE_IDENTIFIER = net.cozic.joplin.ShareExtension;
|
PRODUCT_BUNDLE_IDENTIFIER = net.cozic.joplin.ShareExtension;
|
||||||
|
@ -690,14 +690,14 @@
|
||||||
CODE_SIGN_ENTITLEMENTS = ShareExtension/ShareExtension.entitlements;
|
CODE_SIGN_ENTITLEMENTS = ShareExtension/ShareExtension.entitlements;
|
||||||
CODE_SIGN_STYLE = Automatic;
|
CODE_SIGN_STYLE = Automatic;
|
||||||
COPY_PHASE_STRIP = NO;
|
COPY_PHASE_STRIP = NO;
|
||||||
CURRENT_PROJECT_VERSION = 70;
|
CURRENT_PROJECT_VERSION = 71;
|
||||||
DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym";
|
DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym";
|
||||||
DEVELOPMENT_TEAM = A9BXAFS6CT;
|
DEVELOPMENT_TEAM = A9BXAFS6CT;
|
||||||
GCC_C_LANGUAGE_STANDARD = gnu11;
|
GCC_C_LANGUAGE_STANDARD = gnu11;
|
||||||
INFOPLIST_FILE = ShareExtension/Info.plist;
|
INFOPLIST_FILE = ShareExtension/Info.plist;
|
||||||
IPHONEOS_DEPLOYMENT_TARGET = 9.0;
|
IPHONEOS_DEPLOYMENT_TARGET = 9.0;
|
||||||
LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @executable_path/../../Frameworks";
|
LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @executable_path/../../Frameworks";
|
||||||
MARKETING_VERSION = 12.2.0;
|
MARKETING_VERSION = 12.2.1;
|
||||||
MTL_FAST_MATH = YES;
|
MTL_FAST_MATH = YES;
|
||||||
PRODUCT_BUNDLE_IDENTIFIER = net.cozic.joplin.ShareExtension;
|
PRODUCT_BUNDLE_IDENTIFIER = net.cozic.joplin.ShareExtension;
|
||||||
PRODUCT_NAME = "$(TARGET_NAME)";
|
PRODUCT_NAME = "$(TARGET_NAME)";
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
{
|
{
|
||||||
"name": "@joplin/fork-htmlparser2",
|
"name": "@joplin/fork-htmlparser2",
|
||||||
"version": "4.1.28",
|
"version": "4.1.30",
|
||||||
"lockfileVersion": 1,
|
"lockfileVersion": 1,
|
||||||
"requires": true,
|
"requires": true,
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
{
|
{
|
||||||
"name": "@joplin/fork-htmlparser2",
|
"name": "@joplin/fork-htmlparser2",
|
||||||
"description": "Fast & forgiving HTML/XML/RSS parser",
|
"description": "Fast & forgiving HTML/XML/RSS parser",
|
||||||
"version": "4.1.28",
|
"version": "4.1.30",
|
||||||
"author": "Felix Boehm <me@feedic.com>",
|
"author": "Felix Boehm <me@feedic.com>",
|
||||||
"publishConfig": {
|
"publishConfig": {
|
||||||
"access": "public"
|
"access": "public"
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
{
|
{
|
||||||
"name": "@joplin/fork-sax",
|
"name": "@joplin/fork-sax",
|
||||||
"version": "1.2.32",
|
"version": "1.2.34",
|
||||||
"lockfileVersion": 1,
|
"lockfileVersion": 1,
|
||||||
"requires": true,
|
"requires": true,
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
|
|
|
@ -2,7 +2,7 @@
|
||||||
"name": "@joplin/fork-sax",
|
"name": "@joplin/fork-sax",
|
||||||
"description": "An evented streaming XML parser in JavaScript",
|
"description": "An evented streaming XML parser in JavaScript",
|
||||||
"author": "Isaac Z. Schlueter <i@izs.me> (http://blog.izs.me/)",
|
"author": "Isaac Z. Schlueter <i@izs.me> (http://blog.izs.me/)",
|
||||||
"version": "1.2.32",
|
"version": "1.2.34",
|
||||||
"main": "lib/sax.js",
|
"main": "lib/sax.js",
|
||||||
"publishConfig": {
|
"publishConfig": {
|
||||||
"access": "public"
|
"access": "public"
|
||||||
|
|
|
@ -8,6 +8,8 @@ import JoplinViews from './JoplinViews';
|
||||||
import JoplinInterop from './JoplinInterop';
|
import JoplinInterop from './JoplinInterop';
|
||||||
import JoplinSettings from './JoplinSettings';
|
import JoplinSettings from './JoplinSettings';
|
||||||
import JoplinContentScripts from './JoplinContentScripts';
|
import JoplinContentScripts from './JoplinContentScripts';
|
||||||
|
import JoplinClipboard from './JoplinClipboard';
|
||||||
|
import JoplinWindow from './JoplinWindow';
|
||||||
/**
|
/**
|
||||||
* This is the main entry point to the Joplin API. You can access various services using the provided accessors.
|
* This is the main entry point to the Joplin API. You can access various services using the provided accessors.
|
||||||
*
|
*
|
||||||
|
@ -33,8 +35,12 @@ export default class Joplin {
|
||||||
private interop_;
|
private interop_;
|
||||||
private settings_;
|
private settings_;
|
||||||
private contentScripts_;
|
private contentScripts_;
|
||||||
|
private clipboard_;
|
||||||
|
private window_;
|
||||||
constructor(implementation: any, plugin: Plugin, store: any);
|
constructor(implementation: any, plugin: Plugin, store: any);
|
||||||
get data(): JoplinData;
|
get data(): JoplinData;
|
||||||
|
get clipboard(): JoplinClipboard;
|
||||||
|
get window(): JoplinWindow;
|
||||||
get plugins(): JoplinPlugins;
|
get plugins(): JoplinPlugins;
|
||||||
get workspace(): JoplinWorkspace;
|
get workspace(): JoplinWorkspace;
|
||||||
get contentScripts(): JoplinContentScripts;
|
get contentScripts(): JoplinContentScripts;
|
||||||
|
|
|
@ -0,0 +1,23 @@
|
||||||
|
export default class JoplinClipboard {
|
||||||
|
private electronClipboard_;
|
||||||
|
private electronNativeImage_;
|
||||||
|
constructor(electronClipboard: any, electronNativeImage: any);
|
||||||
|
readText(): Promise<string>;
|
||||||
|
writeText(text: string): Promise<void>;
|
||||||
|
readHtml(): Promise<string>;
|
||||||
|
writeHtml(html: string): Promise<void>;
|
||||||
|
/**
|
||||||
|
* Returns the image in [data URL](https://developer.mozilla.org/en-US/docs/Web/HTTP/Basics_of_HTTP/Data_URIs) format.
|
||||||
|
*/
|
||||||
|
readImage(): Promise<string>;
|
||||||
|
/**
|
||||||
|
* Takes an image in [data URL](https://developer.mozilla.org/en-US/docs/Web/HTTP/Basics_of_HTTP/Data_URIs) format.
|
||||||
|
*/
|
||||||
|
writeImage(dataUrl: string): Promise<void>;
|
||||||
|
/**
|
||||||
|
* Returns the list available formats (mime types).
|
||||||
|
*
|
||||||
|
* For example [ 'text/plain', 'text/html' ]
|
||||||
|
*/
|
||||||
|
availableFormats(): Promise<string[]>;
|
||||||
|
}
|
|
@ -2,7 +2,7 @@ import Plugin from '../Plugin';
|
||||||
import { ButtonSpec, ViewHandle, DialogResult } from './types';
|
import { ButtonSpec, ViewHandle, DialogResult } from './types';
|
||||||
/**
|
/**
|
||||||
* Allows creating and managing dialogs. A dialog is modal window that
|
* Allows creating and managing dialogs. A dialog is modal window that
|
||||||
* contains a webview and a row of buttons. You can update the update the
|
* contains a webview and a row of buttons. You can update the
|
||||||
* webview using the `setHtml` method. Dialogs are hidden by default and
|
* webview using the `setHtml` method. Dialogs are hidden by default and
|
||||||
* you need to call `open()` to open them. Once the user clicks on a
|
* you need to call `open()` to open them. Once the user clicks on a
|
||||||
* button, the `open` call will return an object indicating what button was
|
* button, the `open` call will return an object indicating what button was
|
||||||
|
@ -59,4 +59,11 @@ export default class JoplinViewsDialogs {
|
||||||
* Opens the dialog
|
* Opens the dialog
|
||||||
*/
|
*/
|
||||||
open(handle: ViewHandle): Promise<DialogResult>;
|
open(handle: ViewHandle): Promise<DialogResult>;
|
||||||
|
/**
|
||||||
|
* Toggle on whether to fit the dialog size to the content or not.
|
||||||
|
* When set to false, the dialog stretches to fill the application
|
||||||
|
* window.
|
||||||
|
* @default true
|
||||||
|
*/
|
||||||
|
setFitToContent(handle: ViewHandle, status: boolean): Promise<boolean>;
|
||||||
}
|
}
|
||||||
|
|
|
@ -0,0 +1,24 @@
|
||||||
|
import Plugin from '../Plugin';
|
||||||
|
export interface Implementation {
|
||||||
|
injectCustomStyles(elementId: string, cssFilePath: string): Promise<void>;
|
||||||
|
}
|
||||||
|
export default class JoplinWindow {
|
||||||
|
private plugin_;
|
||||||
|
private store_;
|
||||||
|
private implementation_;
|
||||||
|
constructor(implementation: Implementation, plugin: Plugin, store: any);
|
||||||
|
/**
|
||||||
|
* Loads a chrome CSS file. It will apply to the window UI elements, except
|
||||||
|
* for the note viewer. It is the same as the "Custom stylesheet for
|
||||||
|
* Joplin-wide app styles" setting. See the [Load CSS Demo](https://github.com/laurent22/joplin/tree/dev/packages/app-cli/tests/support/plugins/load_css)
|
||||||
|
* for an example.
|
||||||
|
*/
|
||||||
|
loadChromeCssFile(filePath: string): Promise<void>;
|
||||||
|
/**
|
||||||
|
* Loads a note CSS file. It will apply to the note viewer, as well as any
|
||||||
|
* exported or printed note. It is the same as the "Custom stylesheet for
|
||||||
|
* rendered Markdown" setting. See the [Load CSS Demo](https://github.com/laurent22/joplin/tree/dev/packages/app-cli/tests/support/plugins/load_css)
|
||||||
|
* for an example.
|
||||||
|
*/
|
||||||
|
loadNoteCssFile(filePath: string): Promise<void>;
|
||||||
|
}
|
|
@ -334,6 +334,17 @@ export enum SettingItemType {
|
||||||
Button = 6,
|
Button = 6,
|
||||||
}
|
}
|
||||||
|
|
||||||
|
export enum AppType {
|
||||||
|
Desktop = 'desktop',
|
||||||
|
Mobile = 'mobile',
|
||||||
|
Cli = 'cli',
|
||||||
|
}
|
||||||
|
|
||||||
|
export enum SettingStorage {
|
||||||
|
Database = 1,
|
||||||
|
File = 2,
|
||||||
|
}
|
||||||
|
|
||||||
// Redefine a simplified interface to mask internal details
|
// Redefine a simplified interface to mask internal details
|
||||||
// and to remove function calls as they would have to be async.
|
// and to remove function calls as they would have to be async.
|
||||||
export interface SettingItem {
|
export interface SettingItem {
|
||||||
|
@ -372,7 +383,7 @@ export interface SettingItem {
|
||||||
/**
|
/**
|
||||||
* Reserved property. Not used at the moment.
|
* Reserved property. Not used at the moment.
|
||||||
*/
|
*/
|
||||||
appTypes?: string[];
|
appTypes?: AppType[];
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Set this to `true` to store secure data, such as passwords. Any such
|
* Set this to `true` to store secure data, such as passwords. Any such
|
||||||
|
@ -393,6 +404,11 @@ export interface SettingItem {
|
||||||
minimum?: number;
|
minimum?: number;
|
||||||
maximum?: number;
|
maximum?: number;
|
||||||
step?: number;
|
step?: number;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Either store the setting in the database or in settings.json. Defaults to database.
|
||||||
|
*/
|
||||||
|
storage?: SettingStorage;
|
||||||
}
|
}
|
||||||
|
|
||||||
export interface SettingSection {
|
export interface SettingSection {
|
||||||
|
@ -419,7 +435,7 @@ export type Path = string[];
|
||||||
// Content Script types
|
// Content Script types
|
||||||
// =================================================================
|
// =================================================================
|
||||||
|
|
||||||
export type PostMessageHandler = (id: string, message: any)=> Promise<any>;
|
export type PostMessageHandler = (message: any)=> Promise<any>;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* When a content script is initialised, it receives a `context` object.
|
* When a content script is initialised, it receives a `context` object.
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
{
|
{
|
||||||
"name": "generator-joplin",
|
"name": "generator-joplin",
|
||||||
"version": "2.0.1",
|
"version": "2.2.1",
|
||||||
"lockfileVersion": 1,
|
"lockfileVersion": 1,
|
||||||
"requires": true,
|
"requires": true,
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
{
|
{
|
||||||
"name": "generator-joplin",
|
"name": "generator-joplin",
|
||||||
"version": "2.2.0",
|
"version": "2.2.1",
|
||||||
"description": "Scaffolds out a new Joplin plugin",
|
"description": "Scaffolds out a new Joplin plugin",
|
||||||
"homepage": "https://github.com/laurent22/joplin/tree/dev/packages/generator-joplin",
|
"homepage": "https://github.com/laurent22/joplin/tree/dev/packages/generator-joplin",
|
||||||
"author": {
|
"author": {
|
||||||
|
@ -34,4 +34,4 @@
|
||||||
"repository": "https://github.com/laurent22/generator-joplin",
|
"repository": "https://github.com/laurent22/generator-joplin",
|
||||||
"license": "MIT",
|
"license": "MIT",
|
||||||
"private": true
|
"private": true
|
||||||
}
|
}
|
|
@ -1,6 +1,6 @@
|
||||||
{
|
{
|
||||||
"name": "@joplin/lib",
|
"name": "@joplin/lib",
|
||||||
"version": "2.2.0",
|
"version": "2.2.2",
|
||||||
"lockfileVersion": 1,
|
"lockfileVersion": 1,
|
||||||
"requires": true,
|
"requires": true,
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
|
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in New Issue