orgnote-api 0.0.11 → 0.0.13
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +4 -4
- package/src/api.ts +70 -0
- package/src/generated/api/.gitignore +4 -0
- package/src/generated/api/.npmignore +1 -0
- package/src/generated/api/.openapi-generator/FILES +9 -0
- package/src/generated/api/.openapi-generator/VERSION +1 -0
- package/src/generated/api/.openapi-generator-ignore +23 -0
- package/src/generated/api/api.ts +2040 -0
- package/src/generated/api/base.ts +72 -0
- package/src/generated/api/common.ts +150 -0
- package/{dist/generated/api/configuration.d.ts → src/generated/api/configuration.ts} +21 -3
- package/src/generated/api/git_push.sh +57 -0
- package/{dist/generated/api/index.d.ts → src/generated/api/index.ts} +5 -0
- package/{dist/index.d.ts → src/index.ts} +3 -0
- package/src/models/command.ts +30 -0
- package/src/models/completion.ts +30 -0
- package/src/models/extension.ts +45 -0
- package/src/models/modal.ts +4 -0
- package/src/models/note.ts +24 -0
- package/src/models/theme-variables.ts +194 -0
- package/src/models/widget.ts +56 -0
- package/dist/api.d.ts +0 -66
- package/dist/generated/api/api.d.ts +0 -1376
- package/dist/generated/api/base.d.ts +0 -54
- package/dist/generated/api/common.d.ts +0 -65
- package/dist/models/command.d.ts +0 -18
- package/dist/models/completion.d.ts +0 -22
- package/dist/models/extension.d.ts +0 -34
- package/dist/models/modal.d.ts +0 -4
- package/dist/models/note.d.ts +0 -21
- package/dist/models/theme-variables.d.ts +0 -192
- package/dist/models/widget.d.ts +0 -45
- /package/{dist/models/index.d.ts → src/models/index.ts} +0 -0
|
@@ -0,0 +1,72 @@
|
|
|
1
|
+
/* tslint:disable */
|
|
2
|
+
/* eslint-disable */
|
|
3
|
+
/**
|
|
4
|
+
* Org Note API
|
|
5
|
+
* List of methods for work with Org Note.
|
|
6
|
+
*
|
|
7
|
+
* The version of the OpenAPI document: 0.0.1
|
|
8
|
+
* Contact: artawower@protonmail.com
|
|
9
|
+
*
|
|
10
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
11
|
+
* https://openapi-generator.tech
|
|
12
|
+
* Do not edit the class manually.
|
|
13
|
+
*/
|
|
14
|
+
|
|
15
|
+
|
|
16
|
+
import type { Configuration } from './configuration';
|
|
17
|
+
// Some imports not used depending on template conditions
|
|
18
|
+
// @ts-ignore
|
|
19
|
+
import type { AxiosPromise, AxiosInstance, AxiosRequestConfig } from 'axios';
|
|
20
|
+
import globalAxios from 'axios';
|
|
21
|
+
|
|
22
|
+
export const BASE_PATH = "http://org-note.com/api/v1".replace(/\/+$/, "");
|
|
23
|
+
|
|
24
|
+
/**
|
|
25
|
+
*
|
|
26
|
+
* @export
|
|
27
|
+
*/
|
|
28
|
+
export const COLLECTION_FORMATS = {
|
|
29
|
+
csv: ",",
|
|
30
|
+
ssv: " ",
|
|
31
|
+
tsv: "\t",
|
|
32
|
+
pipes: "|",
|
|
33
|
+
};
|
|
34
|
+
|
|
35
|
+
/**
|
|
36
|
+
*
|
|
37
|
+
* @export
|
|
38
|
+
* @interface RequestArgs
|
|
39
|
+
*/
|
|
40
|
+
export interface RequestArgs {
|
|
41
|
+
url: string;
|
|
42
|
+
options: AxiosRequestConfig;
|
|
43
|
+
}
|
|
44
|
+
|
|
45
|
+
/**
|
|
46
|
+
*
|
|
47
|
+
* @export
|
|
48
|
+
* @class BaseAPI
|
|
49
|
+
*/
|
|
50
|
+
export class BaseAPI {
|
|
51
|
+
protected configuration: Configuration | undefined;
|
|
52
|
+
|
|
53
|
+
constructor(configuration?: Configuration, protected basePath: string = BASE_PATH, protected axios: AxiosInstance = globalAxios) {
|
|
54
|
+
if (configuration) {
|
|
55
|
+
this.configuration = configuration;
|
|
56
|
+
this.basePath = configuration.basePath || this.basePath;
|
|
57
|
+
}
|
|
58
|
+
}
|
|
59
|
+
};
|
|
60
|
+
|
|
61
|
+
/**
|
|
62
|
+
*
|
|
63
|
+
* @export
|
|
64
|
+
* @class RequiredError
|
|
65
|
+
* @extends {Error}
|
|
66
|
+
*/
|
|
67
|
+
export class RequiredError extends Error {
|
|
68
|
+
constructor(public field: string, msg?: string) {
|
|
69
|
+
super(msg);
|
|
70
|
+
this.name = "RequiredError"
|
|
71
|
+
}
|
|
72
|
+
}
|
|
@@ -0,0 +1,150 @@
|
|
|
1
|
+
/* tslint:disable */
|
|
2
|
+
/* eslint-disable */
|
|
3
|
+
/**
|
|
4
|
+
* Org Note API
|
|
5
|
+
* List of methods for work with Org Note.
|
|
6
|
+
*
|
|
7
|
+
* The version of the OpenAPI document: 0.0.1
|
|
8
|
+
* Contact: artawower@protonmail.com
|
|
9
|
+
*
|
|
10
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
11
|
+
* https://openapi-generator.tech
|
|
12
|
+
* Do not edit the class manually.
|
|
13
|
+
*/
|
|
14
|
+
|
|
15
|
+
|
|
16
|
+
import type { Configuration } from "./configuration";
|
|
17
|
+
import type { RequestArgs } from "./base";
|
|
18
|
+
import type { AxiosInstance, AxiosResponse } from 'axios';
|
|
19
|
+
import { RequiredError } from "./base";
|
|
20
|
+
|
|
21
|
+
/**
|
|
22
|
+
*
|
|
23
|
+
* @export
|
|
24
|
+
*/
|
|
25
|
+
export const DUMMY_BASE_URL = 'https://example.com'
|
|
26
|
+
|
|
27
|
+
/**
|
|
28
|
+
*
|
|
29
|
+
* @throws {RequiredError}
|
|
30
|
+
* @export
|
|
31
|
+
*/
|
|
32
|
+
export const assertParamExists = function (functionName: string, paramName: string, paramValue: unknown) {
|
|
33
|
+
if (paramValue === null || paramValue === undefined) {
|
|
34
|
+
throw new RequiredError(paramName, `Required parameter ${paramName} was null or undefined when calling ${functionName}.`);
|
|
35
|
+
}
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
/**
|
|
39
|
+
*
|
|
40
|
+
* @export
|
|
41
|
+
*/
|
|
42
|
+
export const setApiKeyToObject = async function (object: any, keyParamName: string, configuration?: Configuration) {
|
|
43
|
+
if (configuration && configuration.apiKey) {
|
|
44
|
+
const localVarApiKeyValue = typeof configuration.apiKey === 'function'
|
|
45
|
+
? await configuration.apiKey(keyParamName)
|
|
46
|
+
: await configuration.apiKey;
|
|
47
|
+
object[keyParamName] = localVarApiKeyValue;
|
|
48
|
+
}
|
|
49
|
+
}
|
|
50
|
+
|
|
51
|
+
/**
|
|
52
|
+
*
|
|
53
|
+
* @export
|
|
54
|
+
*/
|
|
55
|
+
export const setBasicAuthToObject = function (object: any, configuration?: Configuration) {
|
|
56
|
+
if (configuration && (configuration.username || configuration.password)) {
|
|
57
|
+
object["auth"] = { username: configuration.username, password: configuration.password };
|
|
58
|
+
}
|
|
59
|
+
}
|
|
60
|
+
|
|
61
|
+
/**
|
|
62
|
+
*
|
|
63
|
+
* @export
|
|
64
|
+
*/
|
|
65
|
+
export const setBearerAuthToObject = async function (object: any, configuration?: Configuration) {
|
|
66
|
+
if (configuration && configuration.accessToken) {
|
|
67
|
+
const accessToken = typeof configuration.accessToken === 'function'
|
|
68
|
+
? await configuration.accessToken()
|
|
69
|
+
: await configuration.accessToken;
|
|
70
|
+
object["Authorization"] = "Bearer " + accessToken;
|
|
71
|
+
}
|
|
72
|
+
}
|
|
73
|
+
|
|
74
|
+
/**
|
|
75
|
+
*
|
|
76
|
+
* @export
|
|
77
|
+
*/
|
|
78
|
+
export const setOAuthToObject = async function (object: any, name: string, scopes: string[], configuration?: Configuration) {
|
|
79
|
+
if (configuration && configuration.accessToken) {
|
|
80
|
+
const localVarAccessTokenValue = typeof configuration.accessToken === 'function'
|
|
81
|
+
? await configuration.accessToken(name, scopes)
|
|
82
|
+
: await configuration.accessToken;
|
|
83
|
+
object["Authorization"] = "Bearer " + localVarAccessTokenValue;
|
|
84
|
+
}
|
|
85
|
+
}
|
|
86
|
+
|
|
87
|
+
function setFlattenedQueryParams(urlSearchParams: URLSearchParams, parameter: any, key: string = ""): void {
|
|
88
|
+
if (parameter == null) return;
|
|
89
|
+
if (typeof parameter === "object") {
|
|
90
|
+
if (Array.isArray(parameter)) {
|
|
91
|
+
(parameter as any[]).forEach(item => setFlattenedQueryParams(urlSearchParams, item, key));
|
|
92
|
+
}
|
|
93
|
+
else {
|
|
94
|
+
Object.keys(parameter).forEach(currentKey =>
|
|
95
|
+
setFlattenedQueryParams(urlSearchParams, parameter[currentKey], `${key}${key !== '' ? '.' : ''}${currentKey}`)
|
|
96
|
+
);
|
|
97
|
+
}
|
|
98
|
+
}
|
|
99
|
+
else {
|
|
100
|
+
if (urlSearchParams.has(key)) {
|
|
101
|
+
urlSearchParams.append(key, parameter);
|
|
102
|
+
}
|
|
103
|
+
else {
|
|
104
|
+
urlSearchParams.set(key, parameter);
|
|
105
|
+
}
|
|
106
|
+
}
|
|
107
|
+
}
|
|
108
|
+
|
|
109
|
+
/**
|
|
110
|
+
*
|
|
111
|
+
* @export
|
|
112
|
+
*/
|
|
113
|
+
export const setSearchParams = function (url: URL, ...objects: any[]) {
|
|
114
|
+
const searchParams = new URLSearchParams(url.search);
|
|
115
|
+
setFlattenedQueryParams(searchParams, objects);
|
|
116
|
+
url.search = searchParams.toString();
|
|
117
|
+
}
|
|
118
|
+
|
|
119
|
+
/**
|
|
120
|
+
*
|
|
121
|
+
* @export
|
|
122
|
+
*/
|
|
123
|
+
export const serializeDataIfNeeded = function (value: any, requestOptions: any, configuration?: Configuration) {
|
|
124
|
+
const nonString = typeof value !== 'string';
|
|
125
|
+
const needsSerialization = nonString && configuration && configuration.isJsonMime
|
|
126
|
+
? configuration.isJsonMime(requestOptions.headers['Content-Type'])
|
|
127
|
+
: nonString;
|
|
128
|
+
return needsSerialization
|
|
129
|
+
? JSON.stringify(value !== undefined ? value : {})
|
|
130
|
+
: (value || "");
|
|
131
|
+
}
|
|
132
|
+
|
|
133
|
+
/**
|
|
134
|
+
*
|
|
135
|
+
* @export
|
|
136
|
+
*/
|
|
137
|
+
export const toPathString = function (url: URL) {
|
|
138
|
+
return url.pathname + url.search + url.hash
|
|
139
|
+
}
|
|
140
|
+
|
|
141
|
+
/**
|
|
142
|
+
*
|
|
143
|
+
* @export
|
|
144
|
+
*/
|
|
145
|
+
export const createRequestFunction = function (axiosArgs: RequestArgs, globalAxios: AxiosInstance, BASE_PATH: string, configuration?: Configuration) {
|
|
146
|
+
return <T = unknown, R = AxiosResponse<T>>(axios: AxiosInstance = globalAxios, basePath: string = BASE_PATH) => {
|
|
147
|
+
const axiosRequestArgs = {...axiosArgs.options, url: (configuration?.basePath || basePath) + axiosArgs.url};
|
|
148
|
+
return axios.request<T, R>(axiosRequestArgs);
|
|
149
|
+
};
|
|
150
|
+
}
|
|
@@ -1,3 +1,5 @@
|
|
|
1
|
+
/* tslint:disable */
|
|
2
|
+
/* eslint-disable */
|
|
1
3
|
/**
|
|
2
4
|
* Org Note API
|
|
3
5
|
* List of methods for work with Org Note.
|
|
@@ -9,6 +11,8 @@
|
|
|
9
11
|
* https://openapi-generator.tech
|
|
10
12
|
* Do not edit the class manually.
|
|
11
13
|
*/
|
|
14
|
+
|
|
15
|
+
|
|
12
16
|
export interface ConfigurationParameters {
|
|
13
17
|
apiKey?: string | Promise<string> | ((name: string) => string) | ((name: string) => Promise<string>);
|
|
14
18
|
username?: string;
|
|
@@ -18,7 +22,8 @@ export interface ConfigurationParameters {
|
|
|
18
22
|
baseOptions?: any;
|
|
19
23
|
formDataCtor?: new () => any;
|
|
20
24
|
}
|
|
21
|
-
|
|
25
|
+
|
|
26
|
+
export class Configuration {
|
|
22
27
|
/**
|
|
23
28
|
* parameter for apiKey security
|
|
24
29
|
* @param name security name
|
|
@@ -68,7 +73,17 @@ export declare class Configuration {
|
|
|
68
73
|
* @type {new () => FormData}
|
|
69
74
|
*/
|
|
70
75
|
formDataCtor?: new () => any;
|
|
71
|
-
|
|
76
|
+
|
|
77
|
+
constructor(param: ConfigurationParameters = {}) {
|
|
78
|
+
this.apiKey = param.apiKey;
|
|
79
|
+
this.username = param.username;
|
|
80
|
+
this.password = param.password;
|
|
81
|
+
this.accessToken = param.accessToken;
|
|
82
|
+
this.basePath = param.basePath;
|
|
83
|
+
this.baseOptions = param.baseOptions;
|
|
84
|
+
this.formDataCtor = param.formDataCtor;
|
|
85
|
+
}
|
|
86
|
+
|
|
72
87
|
/**
|
|
73
88
|
* Check if the given MIME is a JSON MIME.
|
|
74
89
|
* JSON MIME examples:
|
|
@@ -79,5 +94,8 @@ export declare class Configuration {
|
|
|
79
94
|
* @param mime - MIME (Multipurpose Internet Mail Extensions)
|
|
80
95
|
* @return True if the given MIME is JSON, false otherwise.
|
|
81
96
|
*/
|
|
82
|
-
isJsonMime(mime: string): boolean
|
|
97
|
+
public isJsonMime(mime: string): boolean {
|
|
98
|
+
const jsonMime: RegExp = new RegExp('^(application\/json|[^;/ \t]+\/[^;/ \t]+[+]json)[ \t]*(;.*)?$', 'i');
|
|
99
|
+
return mime !== null && (jsonMime.test(mime) || mime.toLowerCase() === 'application/json-patch+json');
|
|
100
|
+
}
|
|
83
101
|
}
|
|
@@ -0,0 +1,57 @@
|
|
|
1
|
+
#!/bin/sh
|
|
2
|
+
# ref: https://help.github.com/articles/adding-an-existing-project-to-github-using-the-command-line/
|
|
3
|
+
#
|
|
4
|
+
# Usage example: /bin/sh ./git_push.sh wing328 openapi-petstore-perl "minor update" "gitlab.com"
|
|
5
|
+
|
|
6
|
+
git_user_id=$1
|
|
7
|
+
git_repo_id=$2
|
|
8
|
+
release_note=$3
|
|
9
|
+
git_host=$4
|
|
10
|
+
|
|
11
|
+
if [ "$git_host" = "" ]; then
|
|
12
|
+
git_host="github.com"
|
|
13
|
+
echo "[INFO] No command line input provided. Set \$git_host to $git_host"
|
|
14
|
+
fi
|
|
15
|
+
|
|
16
|
+
if [ "$git_user_id" = "" ]; then
|
|
17
|
+
git_user_id="GIT_USER_ID"
|
|
18
|
+
echo "[INFO] No command line input provided. Set \$git_user_id to $git_user_id"
|
|
19
|
+
fi
|
|
20
|
+
|
|
21
|
+
if [ "$git_repo_id" = "" ]; then
|
|
22
|
+
git_repo_id="GIT_REPO_ID"
|
|
23
|
+
echo "[INFO] No command line input provided. Set \$git_repo_id to $git_repo_id"
|
|
24
|
+
fi
|
|
25
|
+
|
|
26
|
+
if [ "$release_note" = "" ]; then
|
|
27
|
+
release_note="Minor update"
|
|
28
|
+
echo "[INFO] No command line input provided. Set \$release_note to $release_note"
|
|
29
|
+
fi
|
|
30
|
+
|
|
31
|
+
# Initialize the local directory as a Git repository
|
|
32
|
+
git init
|
|
33
|
+
|
|
34
|
+
# Adds the files in the local repository and stages them for commit.
|
|
35
|
+
git add .
|
|
36
|
+
|
|
37
|
+
# Commits the tracked changes and prepares them to be pushed to a remote repository.
|
|
38
|
+
git commit -m "$release_note"
|
|
39
|
+
|
|
40
|
+
# Sets the new remote
|
|
41
|
+
git_remote=$(git remote)
|
|
42
|
+
if [ "$git_remote" = "" ]; then # git remote not defined
|
|
43
|
+
|
|
44
|
+
if [ "$GIT_TOKEN" = "" ]; then
|
|
45
|
+
echo "[INFO] \$GIT_TOKEN (environment variable) is not set. Using the git credential in your environment."
|
|
46
|
+
git remote add origin https://${git_host}/${git_user_id}/${git_repo_id}.git
|
|
47
|
+
else
|
|
48
|
+
git remote add origin https://${git_user_id}:"${GIT_TOKEN}"@${git_host}/${git_user_id}/${git_repo_id}.git
|
|
49
|
+
fi
|
|
50
|
+
|
|
51
|
+
fi
|
|
52
|
+
|
|
53
|
+
git pull origin master
|
|
54
|
+
|
|
55
|
+
# Pushes (Forces) the changes in the local repository up to the remote repository
|
|
56
|
+
echo "Git pushing to https://${git_host}/${git_user_id}/${git_repo_id}.git"
|
|
57
|
+
git push origin master 2>&1 | grep -v 'To https'
|
|
@@ -1,3 +1,5 @@
|
|
|
1
|
+
/* tslint:disable */
|
|
2
|
+
/* eslint-disable */
|
|
1
3
|
/**
|
|
2
4
|
* Org Note API
|
|
3
5
|
* List of methods for work with Org Note.
|
|
@@ -9,5 +11,8 @@
|
|
|
9
11
|
* https://openapi-generator.tech
|
|
10
12
|
* Do not edit the class manually.
|
|
11
13
|
*/
|
|
14
|
+
|
|
15
|
+
|
|
12
16
|
export * from "./api";
|
|
13
17
|
export * from "./configuration";
|
|
18
|
+
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
export const DEFAULT_KEYBINDING_GROUP = 'default';
|
|
2
|
+
|
|
3
|
+
export type CommandGroup =
|
|
4
|
+
| 'settings'
|
|
5
|
+
| 'editor'
|
|
6
|
+
| 'global'
|
|
7
|
+
| 'note-detail'
|
|
8
|
+
| 'completion'
|
|
9
|
+
| string;
|
|
10
|
+
|
|
11
|
+
export interface CommandHandlerParams {
|
|
12
|
+
event?: KeyboardEvent;
|
|
13
|
+
data?: unknown;
|
|
14
|
+
[key: string]: unknown;
|
|
15
|
+
}
|
|
16
|
+
|
|
17
|
+
export interface Command {
|
|
18
|
+
// TODO: add support for multiple key sequences
|
|
19
|
+
keySequence?: string | string[];
|
|
20
|
+
description?: string;
|
|
21
|
+
command?: string;
|
|
22
|
+
title?: string | (() => string);
|
|
23
|
+
icon?: string | (() => string);
|
|
24
|
+
/* Where is this command available, default value is global */
|
|
25
|
+
group?: CommandGroup;
|
|
26
|
+
allowOnInput?: boolean;
|
|
27
|
+
ignorePrompt?: boolean;
|
|
28
|
+
/* arguments depend on the current scope */
|
|
29
|
+
handler: (params?: CommandHandlerParams) => unknown | Promise<unknown>;
|
|
30
|
+
}
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
export interface CompletionCandidate<T = unknown> {
|
|
2
|
+
icon?: string | (() => string);
|
|
3
|
+
group?: string;
|
|
4
|
+
title?: string | (() => string);
|
|
5
|
+
description?: string;
|
|
6
|
+
command: string;
|
|
7
|
+
data: T;
|
|
8
|
+
/* Command handler could be used instead of command string */
|
|
9
|
+
commandHandler?: (data: T) => void;
|
|
10
|
+
}
|
|
11
|
+
|
|
12
|
+
export interface CompletionSearchResult<T = unknown> {
|
|
13
|
+
total?: number;
|
|
14
|
+
result: CompletionCandidate<T>[];
|
|
15
|
+
}
|
|
16
|
+
|
|
17
|
+
export type CandidateGetterFn<T = unknown> = (
|
|
18
|
+
filter: string,
|
|
19
|
+
limit?: number,
|
|
20
|
+
offset?: number
|
|
21
|
+
) => CompletionSearchResult<T> | Promise<CompletionSearchResult<T>>;
|
|
22
|
+
|
|
23
|
+
export interface CompletionConfigs<T = unknown> {
|
|
24
|
+
searchAutocompletions?: string[];
|
|
25
|
+
itemsGetter: CandidateGetterFn<T>;
|
|
26
|
+
placeholder?: string;
|
|
27
|
+
itemHeight?: string;
|
|
28
|
+
searchText?: string;
|
|
29
|
+
onClicked?: (candidate: CompletionCandidate<T>) => void;
|
|
30
|
+
}
|
|
@@ -0,0 +1,45 @@
|
|
|
1
|
+
import { OrgNoteApi } from '../api';
|
|
2
|
+
|
|
3
|
+
export interface ExtensionManifest {
|
|
4
|
+
/* Should be unique in the extension repo */
|
|
5
|
+
name: string;
|
|
6
|
+
version: string;
|
|
7
|
+
category: 'theme' | 'extension' | 'language pack' | 'other';
|
|
8
|
+
/* OrgNote api semver, 0.13.4 for example */
|
|
9
|
+
apiVersion?: string;
|
|
10
|
+
author?: string;
|
|
11
|
+
description?: string;
|
|
12
|
+
keywords?: string[];
|
|
13
|
+
// Repository url
|
|
14
|
+
sourceType: 'git' | 'file';
|
|
15
|
+
/* Default value is README.org */
|
|
16
|
+
readmeFilePath?: string;
|
|
17
|
+
/* WIP */
|
|
18
|
+
permissions?: Array<'files' | 'personal info' | '*' | 'third party'>;
|
|
19
|
+
reloadRequired?: boolean;
|
|
20
|
+
sourceUrl?: string;
|
|
21
|
+
sponsor?: string[];
|
|
22
|
+
development?: boolean;
|
|
23
|
+
icon?: string;
|
|
24
|
+
}
|
|
25
|
+
|
|
26
|
+
export interface Extension {
|
|
27
|
+
[key: string]: unknown;
|
|
28
|
+
|
|
29
|
+
onMounted: (api: OrgNoteApi) => Promise<void>;
|
|
30
|
+
onUnmounted?: (api: OrgNoteApi) => Promise<void>;
|
|
31
|
+
}
|
|
32
|
+
|
|
33
|
+
export interface ExtensionMeta {
|
|
34
|
+
manifest: ExtensionManifest;
|
|
35
|
+
uploaded?: boolean;
|
|
36
|
+
active?: boolean;
|
|
37
|
+
}
|
|
38
|
+
|
|
39
|
+
export interface StoredExtension extends ExtensionMeta {
|
|
40
|
+
module?: string;
|
|
41
|
+
}
|
|
42
|
+
|
|
43
|
+
export interface ActiveExtension extends ExtensionMeta {
|
|
44
|
+
module: Extension;
|
|
45
|
+
}
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
import type { ModelsPublicNote, ModelsPublicUser } from '../generated/api';
|
|
2
|
+
|
|
3
|
+
export interface NotesFilter {
|
|
4
|
+
searchText?: string;
|
|
5
|
+
userId?: string;
|
|
6
|
+
limit?: number;
|
|
7
|
+
offset?: number;
|
|
8
|
+
}
|
|
9
|
+
|
|
10
|
+
export interface NotePreview {
|
|
11
|
+
id: ModelsPublicNote['id'];
|
|
12
|
+
meta: ModelsPublicNote['meta'];
|
|
13
|
+
createdAt: ModelsPublicNote['createdAt'];
|
|
14
|
+
updatedAt: ModelsPublicNote['updatedAt'];
|
|
15
|
+
filePath: ModelsPublicNote['filePath'];
|
|
16
|
+
isMy: ModelsPublicNote['isMy'];
|
|
17
|
+
author?: ModelsPublicUser;
|
|
18
|
+
bookmarked?: boolean;
|
|
19
|
+
}
|
|
20
|
+
|
|
21
|
+
export interface Note extends ModelsPublicNote {
|
|
22
|
+
deleted?: Date;
|
|
23
|
+
bookmarked?: boolean;
|
|
24
|
+
}
|
|
@@ -0,0 +1,194 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* This file is generated by the script `collect-css-variables.js`.
|
|
3
|
+
* Do not edit it manually.
|
|
4
|
+
**/
|
|
5
|
+
|
|
6
|
+
export enum ThemeVariable {
|
|
7
|
+
red = 'red',
|
|
8
|
+
orange = 'orange',
|
|
9
|
+
green = 'green',
|
|
10
|
+
teal = 'teal',
|
|
11
|
+
yellow = 'yellow',
|
|
12
|
+
blue = 'blue',
|
|
13
|
+
darkBlue = 'darkBlue',
|
|
14
|
+
magenta = 'magenta',
|
|
15
|
+
violet = 'violet',
|
|
16
|
+
cyan = 'cyan',
|
|
17
|
+
darkCyan = 'darkCyan',
|
|
18
|
+
white = 'white',
|
|
19
|
+
bg = 'bg',
|
|
20
|
+
bgAlt = 'bgAlt',
|
|
21
|
+
bgAlt2 = 'bgAlt2',
|
|
22
|
+
fg = 'fg',
|
|
23
|
+
fgAlt = 'fgAlt',
|
|
24
|
+
base0 = 'base0',
|
|
25
|
+
base1 = 'base1',
|
|
26
|
+
base2 = 'base2',
|
|
27
|
+
base3 = 'base3',
|
|
28
|
+
base4 = 'base4',
|
|
29
|
+
base5 = 'base5',
|
|
30
|
+
base6 = 'base6',
|
|
31
|
+
base7 = 'base7',
|
|
32
|
+
base8 = 'base8',
|
|
33
|
+
}
|
|
34
|
+
|
|
35
|
+
export enum CSSVariable {
|
|
36
|
+
bg = 'bg',
|
|
37
|
+
fg = 'fg',
|
|
38
|
+
dur = 'dur',
|
|
39
|
+
easyTableHeaderBackgroundColor = 'easyTableHeaderBackgroundColor',
|
|
40
|
+
easyTableHeaderFontColor = 'easyTableHeaderFontColor',
|
|
41
|
+
easyTableBodyRowBackgroundColor = 'easyTableBodyRowBackgroundColor',
|
|
42
|
+
easyTableBodyRowFontColor = 'easyTableBodyRowFontColor',
|
|
43
|
+
easyTableBodyRowHoverBackgroundColor = 'easyTableBodyRowHoverBackgroundColor',
|
|
44
|
+
easyTableFooterBackgroundColor = 'easyTableFooterBackgroundColor',
|
|
45
|
+
easyTableFooterFontColor = 'easyTableFooterFontColor',
|
|
46
|
+
easyTableBodyRowHoverFontColor = 'easyTableBodyRowHoverFontColor',
|
|
47
|
+
easyTableRowBorder = 'easyTableRowBorder',
|
|
48
|
+
easyTableBorder = 'easyTableBorder',
|
|
49
|
+
easyTableMessageFontColor = 'easyTableMessageFontColor',
|
|
50
|
+
btnFlatSize = 'btnFlatSize',
|
|
51
|
+
btnFlatBorder = 'btnFlatBorder',
|
|
52
|
+
btnFlatBorderRadius = 'btnFlatBorderRadius',
|
|
53
|
+
btnFlatBoxShadow = 'btnFlatBoxShadow',
|
|
54
|
+
btnMainColor = 'btnMainColor',
|
|
55
|
+
btnSocialSize = 'btnSocialSize',
|
|
56
|
+
btnSocialBackground = 'btnSocialBackground',
|
|
57
|
+
checkboxColor = 'checkboxColor',
|
|
58
|
+
editorFontFamily = 'editorFontFamily',
|
|
59
|
+
flexGapMd = 'flexGapMd',
|
|
60
|
+
flexGapSm = 'flexGapSm',
|
|
61
|
+
inlineCodeBackground = 'inlineCodeBackground',
|
|
62
|
+
inlineCodeFontColor = 'inlineCodeFontColor',
|
|
63
|
+
scrollBarWidth = 'scrollBarWidth',
|
|
64
|
+
scrollBarColor = 'scrollBarColor',
|
|
65
|
+
fontSizeSm = 'fontSizeSm',
|
|
66
|
+
fontSizeMd = 'fontSizeMd',
|
|
67
|
+
fontSizeLg = 'fontSizeLg',
|
|
68
|
+
headlineMargin = 'headlineMargin',
|
|
69
|
+
paragraphFontSize = 'paragraphFontSize',
|
|
70
|
+
mainFontFamily = 'mainFontFamily',
|
|
71
|
+
editorFontFamilyMain = 'editorFontFamilyMain',
|
|
72
|
+
paragraphFontFamily = 'paragraphFontFamily',
|
|
73
|
+
headlineFontFamily = 'headlineFontFamily',
|
|
74
|
+
codeFontFamily = 'codeFontFamily',
|
|
75
|
+
descriptionFontFamily = 'descriptionFontFamily',
|
|
76
|
+
descriptionFontSize = 'descriptionFontSize',
|
|
77
|
+
descriptionFontStyle = 'descriptionFontStyle',
|
|
78
|
+
descriptionFontColor = 'descriptionFontColor',
|
|
79
|
+
descriptionPadding = 'descriptionPadding',
|
|
80
|
+
codeFontSize = 'codeFontSize',
|
|
81
|
+
headlineFontWeight = 'headlineFontWeight',
|
|
82
|
+
fontColorAction = 'fontColorAction',
|
|
83
|
+
fontSm = 'fontSm',
|
|
84
|
+
fontMd = 'fontMd',
|
|
85
|
+
fontLg = 'fontLg',
|
|
86
|
+
ulFontSize = 'ulFontSize',
|
|
87
|
+
ulLineHeight = 'ulLineHeight',
|
|
88
|
+
ulFontFamily = 'ulFontFamily',
|
|
89
|
+
topBarHeight = 'topBarHeight',
|
|
90
|
+
contentMaxWidth = 'contentMaxWidth',
|
|
91
|
+
modelineHeight = 'modelineHeight',
|
|
92
|
+
modelinePadding = 'modelinePadding',
|
|
93
|
+
modelineBackground = 'modelineBackground',
|
|
94
|
+
cardBackgroundColor = 'cardBackgroundColor',
|
|
95
|
+
shadowMain = 'shadowMain',
|
|
96
|
+
sidebarWidth = 'sidebarWidth',
|
|
97
|
+
actionPaneOpenedWidth = 'actionPaneOpenedWidth',
|
|
98
|
+
footerHeight = 'footerHeight',
|
|
99
|
+
publicPreviewImageWidth = 'publicPreviewImageWidth',
|
|
100
|
+
publicPreviewImageHeight = 'publicPreviewImageHeight',
|
|
101
|
+
publicPreviewMaxHeight = 'publicPreviewMaxHeight',
|
|
102
|
+
completionItemMinHeight = 'completionItemMinHeight',
|
|
103
|
+
completionItemPadding = 'completionItemPadding',
|
|
104
|
+
completionItemMargin = 'completionItemMargin',
|
|
105
|
+
completionItemHoverBackground = 'completionItemHoverBackground',
|
|
106
|
+
completionItemHoverColor = 'completionItemHoverColor',
|
|
107
|
+
completionFloatTop = 'completionFloatTop',
|
|
108
|
+
completionBorderRadius = 'completionBorderRadius',
|
|
109
|
+
completionWidth = 'completionWidth',
|
|
110
|
+
completionMaxWidth = 'completionMaxWidth',
|
|
111
|
+
completionBorder = 'completionBorder',
|
|
112
|
+
completionBoxShadow = 'completionBoxShadow',
|
|
113
|
+
completionInputHeight = 'completionInputHeight',
|
|
114
|
+
completionContainerMargin = 'completionContainerMargin',
|
|
115
|
+
menuPadding = 'menuPadding',
|
|
116
|
+
fileUploaderBorderWidth = 'fileUploaderBorderWidth',
|
|
117
|
+
fileUploaderBorderStyle = 'fileUploaderBorderStyle',
|
|
118
|
+
fileUploaderBorderColor = 'fileUploaderBorderColor',
|
|
119
|
+
fileUploaderBg = 'fileUploaderBg',
|
|
120
|
+
fileUploaderOpacity = 'fileUploaderOpacity',
|
|
121
|
+
notePreviewLinkMaxWidth = 'notePreviewLinkMaxWidth',
|
|
122
|
+
notePreviewLinkHeight = 'notePreviewLinkHeight',
|
|
123
|
+
btnActionShadow = 'btnActionShadow',
|
|
124
|
+
btnActionBorder = 'btnActionBorder',
|
|
125
|
+
btnActionBorderColor = 'btnActionBorderColor',
|
|
126
|
+
btnActionPadding = 'btnActionPadding',
|
|
127
|
+
btnActionRadius = 'btnActionRadius',
|
|
128
|
+
btnActionFireColor = 'btnActionFireColor',
|
|
129
|
+
btnActionFireBorderColor = 'btnActionFireBorderColor',
|
|
130
|
+
btnActionMd = 'btnActionMd',
|
|
131
|
+
btnActionSm = 'btnActionSm',
|
|
132
|
+
btnActionLg = 'btnActionLg',
|
|
133
|
+
btnActionColor = 'btnActionColor',
|
|
134
|
+
btnActionBg = 'btnActionBg',
|
|
135
|
+
miniBufferBackground = 'miniBufferBackground',
|
|
136
|
+
miniBufferFontColor = 'miniBufferFontColor',
|
|
137
|
+
miniBufferBorderTop = 'miniBufferBorderTop',
|
|
138
|
+
miniBufferMaxHeight = 'miniBufferMaxHeight',
|
|
139
|
+
tagHoverBackground = 'tagHoverBackground',
|
|
140
|
+
tagHoverColor = 'tagHoverColor',
|
|
141
|
+
toolbarBorderTop = 'toolbarBorderTop',
|
|
142
|
+
toolbarHoverColor = 'toolbarHoverColor',
|
|
143
|
+
headerbarHeight = 'headerbarHeight',
|
|
144
|
+
headerbarBorderRadius = 'headerbarBorderRadius',
|
|
145
|
+
headerbarBackgroundColor = 'headerbarBackgroundColor',
|
|
146
|
+
headerbarColor = 'headerbarColor',
|
|
147
|
+
headerbarBorder = 'headerbarBorder',
|
|
148
|
+
fileItemBgHover = 'fileItemBgHover',
|
|
149
|
+
fileItemColorHover = 'fileItemColorHover',
|
|
150
|
+
fileItemHeight = 'fileItemHeight',
|
|
151
|
+
iconBtnColor = 'iconBtnColor',
|
|
152
|
+
iconBtnHoverColor = 'iconBtnHoverColor',
|
|
153
|
+
modalMaxHeight = 'modalMaxHeight',
|
|
154
|
+
modalMaxWidth = 'modalMaxWidth',
|
|
155
|
+
modalPadding = 'modalPadding',
|
|
156
|
+
blockPaddingSm = 'blockPaddingSm',
|
|
157
|
+
blockPaddingMd = 'blockPaddingMd',
|
|
158
|
+
blockPaddingLg = 'blockPaddingLg',
|
|
159
|
+
blockMarginMd = 'blockMarginMd',
|
|
160
|
+
blockMarginSm = 'blockMarginSm',
|
|
161
|
+
blockBorderRadiusMd = 'blockBorderRadiusMd',
|
|
162
|
+
blockBorderRadiusSm = 'blockBorderRadiusSm',
|
|
163
|
+
itemDefaultRadius = 'itemDefaultRadius',
|
|
164
|
+
searchIcnSize = 'searchIcnSize',
|
|
165
|
+
gapMd = 'gapMd',
|
|
166
|
+
gapSm = 'gapSm',
|
|
167
|
+
gapXs = 'gapXs',
|
|
168
|
+
srcBlockHeaderPaddingY = 'srcBlockHeaderPaddingY',
|
|
169
|
+
srcBlockFooterPaddingY = 'srcBlockFooterPaddingY',
|
|
170
|
+
srcBlockPaddingX = 'srcBlockPaddingX',
|
|
171
|
+
srcBlockPaddingY = 'srcBlockPaddingY',
|
|
172
|
+
srcBlockMarginY = 'srcBlockMarginY',
|
|
173
|
+
pagePadding = 'pagePadding',
|
|
174
|
+
editorLineHeight = 'editorLineHeight',
|
|
175
|
+
editorHeadlineLineHeight = 'editorHeadlineLineHeight',
|
|
176
|
+
editorDefaultLineHeight = 'editorDefaultLineHeight',
|
|
177
|
+
editorPaddingBottom = 'editorPaddingBottom',
|
|
178
|
+
editorCursorColor = 'editorCursorColor',
|
|
179
|
+
editorSelectionBgColor = 'editorSelectionBgColor',
|
|
180
|
+
editorSelectionColor = 'editorSelectionColor',
|
|
181
|
+
editorGutterColor = 'editorGutterColor',
|
|
182
|
+
editorGutterHoverColor = 'editorGutterHoverColor',
|
|
183
|
+
editorFoldPlaceholderColor = 'editorFoldPlaceholderColor',
|
|
184
|
+
editorActiveLineBgColor = 'editorActiveLineBgColor',
|
|
185
|
+
editorCaretColor = 'editorCaretColor',
|
|
186
|
+
orgListItemBulletMarginLeft = 'orgListItemBulletMarginLeft',
|
|
187
|
+
devicePaddingBottom = 'devicePaddingBottom',
|
|
188
|
+
graphNodeColor = 'graphNodeColor',
|
|
189
|
+
graphEdgeColor = 'graphEdgeColor',
|
|
190
|
+
graphActiveColor = 'graphActiveColor',
|
|
191
|
+
inputHeight = 'inputHeight',
|
|
192
|
+
inputLgHeight = 'inputLgHeight',
|
|
193
|
+
borderMain = 'borderMain',
|
|
194
|
+
}
|