orgnote-api 0.41.40 → 0.41.42

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.
@@ -188,7 +188,18 @@ export declare enum i18n {
188
188
  GPG_EMAIL_REQUIRED = "gpg email required",
189
189
  GPG_EMAIL_INVALID = "gpg email invalid",
190
190
  CLEAR_ALL_NOTIFICATIONS = "clear all notifications",
191
- NO_NOTIFICATIONS = "no notifications"
191
+ NO_NOTIFICATIONS = "no notifications",
192
+ GRAPH_TITLE = "graph.title",
193
+ GRAPH_DESCRIPTION = "graph.description",
194
+ GRAPH_EMPTY_TITLE = "graph.empty.title",
195
+ GRAPH_EMPTY_DESCRIPTION = "graph.empty.description",
196
+ GRAPH_ERROR_TITLE = "graph.error.title",
197
+ GRAPH_SELECTED_LABEL = "graph.selected.label",
198
+ GRAPH_REFRESH = "graph.refresh",
199
+ GRAPH_NODES_LABEL = "graph.nodes.label",
200
+ GRAPH_EDGES_LABEL = "graph.edges.label",
201
+ GRAPH_SETTINGS_TITLE = "graph.settings.title",
202
+ GRAPH_SETTINGS_GROUP = "graph.settings.group"
192
203
  }
193
204
  export declare const I18N: {
194
205
  REPORT_BUG: DefaultCommands.REPORT_BUG;
@@ -245,6 +256,8 @@ export declare const I18N: {
245
256
  OPEN_NOTE_EDITOR: DefaultCommands.OPEN_NOTE_EDITOR;
246
257
  OPEN_NOTE_VIEWER: DefaultCommands.OPEN_NOTE_VIEWER;
247
258
  OPEN_GRAPH: DefaultCommands.OPEN_GRAPH;
259
+ GRAPH_SETTINGS: DefaultCommands.GRAPH_SETTINGS;
260
+ OPEN_GRAPH_SETTINGS: DefaultCommands.OPEN_GRAPH_SETTINGS;
248
261
  SELECT_FILE_PATH: DefaultCommands.SELECT_FILE_PATH;
249
262
  PICK_SYNC_DIR: DefaultCommands.PICK_SYNC_DIR;
250
263
  SYNC_FILES: DefaultCommands.SYNC_FILES;
@@ -505,5 +518,16 @@ export declare const I18N: {
505
518
  GPG_EMAIL_INVALID: i18n.GPG_EMAIL_INVALID;
506
519
  CLEAR_ALL_NOTIFICATIONS: i18n.CLEAR_ALL_NOTIFICATIONS;
507
520
  NO_NOTIFICATIONS: i18n.NO_NOTIFICATIONS;
521
+ GRAPH_TITLE: i18n.GRAPH_TITLE;
522
+ GRAPH_DESCRIPTION: i18n.GRAPH_DESCRIPTION;
523
+ GRAPH_EMPTY_TITLE: i18n.GRAPH_EMPTY_TITLE;
524
+ GRAPH_EMPTY_DESCRIPTION: i18n.GRAPH_EMPTY_DESCRIPTION;
525
+ GRAPH_ERROR_TITLE: i18n.GRAPH_ERROR_TITLE;
526
+ GRAPH_SELECTED_LABEL: i18n.GRAPH_SELECTED_LABEL;
527
+ GRAPH_REFRESH: i18n.GRAPH_REFRESH;
528
+ GRAPH_NODES_LABEL: i18n.GRAPH_NODES_LABEL;
529
+ GRAPH_EDGES_LABEL: i18n.GRAPH_EDGES_LABEL;
530
+ GRAPH_SETTINGS_TITLE: i18n.GRAPH_SETTINGS_TITLE;
531
+ GRAPH_SETTINGS_GROUP: i18n.GRAPH_SETTINGS_GROUP;
508
532
  };
509
533
  export type I18N = i18n | DefaultCommands;
@@ -200,6 +200,18 @@ export var i18n;
200
200
  i18n["GPG_EMAIL_INVALID"] = "gpg email invalid";
201
201
  i18n["CLEAR_ALL_NOTIFICATIONS"] = "clear all notifications";
202
202
  i18n["NO_NOTIFICATIONS"] = "no notifications";
203
+ // Graph
204
+ i18n["GRAPH_TITLE"] = "graph.title";
205
+ i18n["GRAPH_DESCRIPTION"] = "graph.description";
206
+ i18n["GRAPH_EMPTY_TITLE"] = "graph.empty.title";
207
+ i18n["GRAPH_EMPTY_DESCRIPTION"] = "graph.empty.description";
208
+ i18n["GRAPH_ERROR_TITLE"] = "graph.error.title";
209
+ i18n["GRAPH_SELECTED_LABEL"] = "graph.selected.label";
210
+ i18n["GRAPH_REFRESH"] = "graph.refresh";
211
+ i18n["GRAPH_NODES_LABEL"] = "graph.nodes.label";
212
+ i18n["GRAPH_EDGES_LABEL"] = "graph.edges.label";
213
+ i18n["GRAPH_SETTINGS_TITLE"] = "graph.settings.title";
214
+ i18n["GRAPH_SETTINGS_GROUP"] = "graph.settings.group";
203
215
  })(i18n || (i18n = {}));
204
216
  export const I18N = {
205
217
  ...i18n,
@@ -24,6 +24,7 @@ export declare enum RouteNames {
24
24
  ApiSettings = "ApiSettings",
25
25
  AuthenticationSettings = "AuthenticationSettings",
26
26
  SynchronisationSettings = "SynchronisationSettings",
27
+ GraphSettings = "GraphSettings",
27
28
  Extensions = "Extensions",
28
29
  Keybindings = "Keybindings",
29
30
  RawEditor = "Raw editor",
@@ -25,6 +25,7 @@ export var RouteNames;
25
25
  RouteNames["ApiSettings"] = "ApiSettings";
26
26
  RouteNames["AuthenticationSettings"] = "AuthenticationSettings";
27
27
  RouteNames["SynchronisationSettings"] = "SynchronisationSettings";
28
+ RouteNames["GraphSettings"] = "GraphSettings";
28
29
  RouteNames["Extensions"] = "Extensions";
29
30
  RouteNames["Keybindings"] = "Keybindings";
30
31
  RouteNames["RawEditor"] = "Raw editor";
@@ -53,6 +53,8 @@ export declare enum DefaultCommands {
53
53
  OPEN_NOTE_EDITOR = "edit mode",
54
54
  OPEN_NOTE_VIEWER = "view mode",
55
55
  OPEN_GRAPH = "graph",
56
+ GRAPH_SETTINGS = "graph settings",
57
+ OPEN_GRAPH_SETTINGS = "open graph settings",
56
58
  SELECT_FILE_PATH = "select file path",
57
59
  PICK_SYNC_DIR = "pick sync dir",
58
60
  SYNC_FILES = "sync files",
@@ -64,6 +64,8 @@ export var DefaultCommands;
64
64
  DefaultCommands["OPEN_NOTE_EDITOR"] = "edit mode";
65
65
  DefaultCommands["OPEN_NOTE_VIEWER"] = "view mode";
66
66
  DefaultCommands["OPEN_GRAPH"] = "graph";
67
+ DefaultCommands["GRAPH_SETTINGS"] = "graph settings";
68
+ DefaultCommands["OPEN_GRAPH_SETTINGS"] = "open graph settings";
67
69
  // Native mobile specific
68
70
  DefaultCommands["SELECT_FILE_PATH"] = "select file path";
69
71
  DefaultCommands["PICK_SYNC_DIR"] = "pick sync dir";
@@ -42,6 +42,16 @@ export declare const ORG_NOTE_CONFIG_SCHEMA: import("valibot").SchemaWithPipe<re
42
42
  readonly persistantPanesSaveDelay: import("valibot").NumberSchema<undefined>;
43
43
  readonly showFileTitleBar: import("valibot").BooleanSchema<undefined>;
44
44
  readonly dropZoneEdgeRatio: import("valibot").NumberSchema<undefined>;
45
+ readonly graph: import("valibot").ObjectSchema<{
46
+ readonly nodeRelSize: import("valibot").OptionalSchema<import("valibot").NumberSchema<undefined>, undefined>;
47
+ readonly linkDistance: import("valibot").OptionalSchema<import("valibot").NumberSchema<undefined>, undefined>;
48
+ readonly chargeStrength: import("valibot").OptionalSchema<import("valibot").NumberSchema<undefined>, undefined>;
49
+ readonly warmupTicks: import("valibot").OptionalSchema<import("valibot").NumberSchema<undefined>, undefined>;
50
+ readonly velocityDecay: import("valibot").OptionalSchema<import("valibot").NumberSchema<undefined>, undefined>;
51
+ readonly initialZoom: import("valibot").OptionalSchema<import("valibot").NumberSchema<undefined>, undefined>;
52
+ readonly labelFontSize: import("valibot").OptionalSchema<import("valibot").NumberSchema<undefined>, undefined>;
53
+ readonly linkWidth: import("valibot").OptionalSchema<import("valibot").NumberSchema<undefined>, undefined>;
54
+ }, undefined>;
45
55
  readonly fonts: import("valibot").OptionalSchema<import("valibot").ObjectSchema<{
46
56
  readonly main: import("valibot").OptionalSchema<import("valibot").StringSchema<undefined>, undefined>;
47
57
  readonly editor: import("valibot").OptionalSchema<import("valibot").StringSchema<undefined>, undefined>;
@@ -99,6 +109,7 @@ export interface DefinedOrgNoteSettings {
99
109
  export type OrgNoteSettings = DefinedOrgNoteSettings & {
100
110
  [key: string]: unknown;
101
111
  };
112
+ export type GraphUiConfig = Required<NonNullable<InferOutput<typeof ORG_NOTE_CONFIG_SCHEMA>['ui']['graph']>>;
102
113
  export type OrgNoteConfig = InferOutput<typeof ORG_NOTE_CONFIG_SCHEMA> & {
103
114
  [key: string]: any;
104
115
  };
@@ -44,6 +44,16 @@ export const ORG_NOTE_CONFIG_SCHEMA = pipe(objectWithRest({
44
44
  persistantPanesSaveDelay: number(),
45
45
  showFileTitleBar: boolean(),
46
46
  dropZoneEdgeRatio: number(),
47
+ graph: object({
48
+ nodeRelSize: optional(number()),
49
+ linkDistance: optional(number()),
50
+ chargeStrength: optional(number()),
51
+ warmupTicks: optional(number()),
52
+ velocityDecay: optional(number()),
53
+ initialZoom: optional(number()),
54
+ labelFontSize: optional(number()),
55
+ linkWidth: optional(number()),
56
+ }),
47
57
  fonts: optional(object({
48
58
  main: optional(string()),
49
59
  editor: optional(string()),
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "orgnote-api",
3
- "version": "0.41.40",
3
+ "version": "0.41.42",
4
4
  "description": "Official API for creating extensions for OrgNote app",
5
5
  "type": "module",
6
6
  "main": "./index.js",