@myrmidon/gve-core 3.0.3 → 5.0.0
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/fesm2022/myrmidon-gve-core.mjs +671 -547
- package/fesm2022/myrmidon-gve-core.mjs.map +1 -1
- package/index.d.ts +1500 -3
- package/package.json +12 -11
- package/lib/components/animation-timeline/animation-timeline.component.d.ts +0 -61
- package/lib/components/animation-timeline-set/animation-timeline-set.component.d.ts +0 -52
- package/lib/components/animation-tween/animation-tween.component.d.ts +0 -58
- package/lib/components/base-text-char/base-text-char.component.d.ts +0 -42
- package/lib/components/base-text-editor/base-text-editor.component.d.ts +0 -42
- package/lib/components/base-text-view/base-text-view.component.d.ts +0 -69
- package/lib/components/batch-operation-editor/batch-operation-editor.component.d.ts +0 -44
- package/lib/components/chain-operation-editor/chain-operation-editor.component.d.ts +0 -149
- package/lib/components/chain-result-view/chain-result-view.component.d.ts +0 -58
- package/lib/components/chain-view/chain-view.component.d.ts +0 -42
- package/lib/components/feature-editor/feature-editor.component.d.ts +0 -82
- package/lib/components/feature-set-editor/feature-set-editor.component.d.ts +0 -76
- package/lib/components/feature-set-view/feature-set-view.component.d.ts +0 -54
- package/lib/components/ln-heights-editor/ln-heights-editor.component.d.ts +0 -41
- package/lib/components/operation-source-editor/operation-source-editor.component.d.ts +0 -52
- package/lib/components/snapshot-editor/snapshot-editor.component.d.ts +0 -293
- package/lib/components/snapshot-text-editor/snapshot-text-editor.component.d.ts +0 -37
- package/lib/components/steps-map/steps-map.component.d.ts +0 -48
- package/lib/models.d.ts +0 -15
- package/lib/services/gve-api.service.d.ts +0 -148
- package/lib/services/gve-graphviz.service.d.ts +0 -20
- package/lib/services/settings.service.d.ts +0 -89
- package/lib/validators/svg-validators.d.ts +0 -10
- package/public-api.d.ts +0 -21
|
@@ -1,48 +0,0 @@
|
|
|
1
|
-
import { ChainOperationContextStep } from '../../services/gve-api.service';
|
|
2
|
-
import * as i0 from "@angular/core";
|
|
3
|
-
/**
|
|
4
|
-
* 🔑 `gve-steps-map`
|
|
5
|
-
*
|
|
6
|
-
* A map of steps in a chain operation context. This shows the list of
|
|
7
|
-
* steps in the execution of a set of operations, and allows the user to
|
|
8
|
-
* pick a step to view.
|
|
9
|
-
*
|
|
10
|
-
* Used by the `gve-chain-result-view` component.
|
|
11
|
-
*
|
|
12
|
-
* - ▶️ `steps` (`ChainOperationContextStep[]`): the steps to display.
|
|
13
|
-
* - ▶️ `selectedStep` (`ChainOperationContextStep`): the step that is
|
|
14
|
-
* currently selected.
|
|
15
|
-
* - ▶️ `textFontSize` (`string`): the font size of the steps text.
|
|
16
|
-
* - 🔥 `selectedStepChange` (`ChainOperationContextStep`): emitted when
|
|
17
|
-
* the selectd step has been changed by the user. This is not emitted
|
|
18
|
-
* when the selected step is changed programmatically, unless this is
|
|
19
|
-
* the first time the steps are set. In that case, the last step is
|
|
20
|
-
* automatically selected.
|
|
21
|
-
*/
|
|
22
|
-
export declare class StepsMapComponent {
|
|
23
|
-
lines: {
|
|
24
|
-
[key: string]: string[];
|
|
25
|
-
};
|
|
26
|
-
/**
|
|
27
|
-
* The steps to display.
|
|
28
|
-
*/
|
|
29
|
-
readonly steps: import("@angular/core").InputSignal<ChainOperationContextStep[]>;
|
|
30
|
-
/**
|
|
31
|
-
* The step that is currently selected.
|
|
32
|
-
*/
|
|
33
|
-
readonly selectedStep: import("@angular/core").ModelSignal<ChainOperationContextStep | undefined>;
|
|
34
|
-
/**
|
|
35
|
-
* The font size of the steps text.
|
|
36
|
-
*/
|
|
37
|
-
readonly textFontSize: import("@angular/core").InputSignal<string>;
|
|
38
|
-
/**
|
|
39
|
-
* Emitted when the selected step has changed by user, or when
|
|
40
|
-
* the steps are set for the first time.
|
|
41
|
-
*/
|
|
42
|
-
selectedStepChange: import("@angular/core").OutputEmitterRef<ChainOperationContextStep | undefined>;
|
|
43
|
-
constructor();
|
|
44
|
-
private updateLines;
|
|
45
|
-
onStepClick(step: ChainOperationContextStep): void;
|
|
46
|
-
static ɵfac: i0.ɵɵFactoryDeclaration<StepsMapComponent, never>;
|
|
47
|
-
static ɵcmp: i0.ɵɵComponentDeclaration<StepsMapComponent, "gve-steps-map", never, { "steps": { "alias": "steps"; "required": false; "isSignal": true; }; "selectedStep": { "alias": "selectedStep"; "required": false; "isSignal": true; }; "textFontSize": { "alias": "textFontSize"; "required": false; "isSignal": true; }; }, { "selectedStep": "selectedStepChange"; "selectedStepChange": "selectedStepChange"; }, never, never, true, never>;
|
|
48
|
-
}
|
package/lib/models.d.ts
DELETED
|
@@ -1,15 +0,0 @@
|
|
|
1
|
-
import { MatDialogConfig } from "@angular/material/dialog";
|
|
2
|
-
/**
|
|
3
|
-
* API call result wrapper.
|
|
4
|
-
*/
|
|
5
|
-
export interface ResultWrapper<T> {
|
|
6
|
-
result?: T;
|
|
7
|
-
error?: string;
|
|
8
|
-
}
|
|
9
|
-
/**
|
|
10
|
-
* PayloadMatDialogConfig is a MatDialogConfig with a payload, used
|
|
11
|
-
* to pass data of type T to a dialog.
|
|
12
|
-
*/
|
|
13
|
-
export interface PayloadMatDialogConfig<T> extends MatDialogConfig {
|
|
14
|
-
payload?: T;
|
|
15
|
-
}
|
|
@@ -1,148 +0,0 @@
|
|
|
1
|
-
import { HttpClient } from '@angular/common/http';
|
|
2
|
-
import { Observable } from 'rxjs';
|
|
3
|
-
import { ErrorService, EnvService } from '@myrmidon/ngx-tools';
|
|
4
|
-
import { CharChainOperation, CharNode, OperationFeature } from '@myrmidon/gve-snapshot-view';
|
|
5
|
-
import { ResultWrapper } from '../models';
|
|
6
|
-
import * as i0 from "@angular/core";
|
|
7
|
-
/**
|
|
8
|
-
* Execution step of a char-based chain operation.
|
|
9
|
-
*/
|
|
10
|
-
export interface ChainOperationContextStep {
|
|
11
|
-
/**
|
|
12
|
-
* The operation that was executed.
|
|
13
|
-
*/
|
|
14
|
-
operation: CharChainOperation;
|
|
15
|
-
/**
|
|
16
|
-
* The input version tag.
|
|
17
|
-
*/
|
|
18
|
-
inputTag: string;
|
|
19
|
-
/**
|
|
20
|
-
* The output version tag.
|
|
21
|
-
*/
|
|
22
|
-
outputTag: string;
|
|
23
|
-
/**
|
|
24
|
-
* The string synthetically representing the resulting text
|
|
25
|
-
* version.
|
|
26
|
-
*/
|
|
27
|
-
result?: string;
|
|
28
|
-
/**
|
|
29
|
-
* The features emitted up to the executed operation.
|
|
30
|
-
* These are the features of the text as a whole, and
|
|
31
|
-
* those belonging to specific nodes, each keyed under
|
|
32
|
-
* a string built with `v` + output version tag + `_`
|
|
33
|
-
* + node ID (e.g. `v1_2` for node with ID 2 at version 1).
|
|
34
|
-
*/
|
|
35
|
-
featureSet: {
|
|
36
|
-
features: OperationFeature[];
|
|
37
|
-
nodeFeatures: Record<string, OperationFeature[]>;
|
|
38
|
-
};
|
|
39
|
-
/**
|
|
40
|
-
* The reference node IDs of the operation which was
|
|
41
|
-
* executed.
|
|
42
|
-
*/
|
|
43
|
-
refNodeIds: number[];
|
|
44
|
-
}
|
|
45
|
-
/**
|
|
46
|
-
* Result of execution of a char-based chain.
|
|
47
|
-
*/
|
|
48
|
-
export interface CharChainResult {
|
|
49
|
-
/**
|
|
50
|
-
* The execution steps of the chain.
|
|
51
|
-
*/
|
|
52
|
-
steps: ChainOperationContextStep[];
|
|
53
|
-
/**
|
|
54
|
-
* The chain dump, which is the text representation of the chain.
|
|
55
|
-
*/
|
|
56
|
-
chainDump: string;
|
|
57
|
-
/**
|
|
58
|
-
* The list of all unique tags in the chain.
|
|
59
|
-
*/
|
|
60
|
-
chainTags: string[];
|
|
61
|
-
/**
|
|
62
|
-
* The sets of nodes in their order, for each version tag.
|
|
63
|
-
* These nodes are collected by following the path defined
|
|
64
|
-
* by the set of links of each version tag; so each of the
|
|
65
|
-
* sets contains only the nodes used at that step to build
|
|
66
|
-
* the text version, with their features up to that stage.
|
|
67
|
-
*/
|
|
68
|
-
taggedNodes: {
|
|
69
|
-
[key: string]: CharNode[];
|
|
70
|
-
};
|
|
71
|
-
}
|
|
72
|
-
/**
|
|
73
|
-
* The input and output tags of a char-based chain operation.
|
|
74
|
-
*/
|
|
75
|
-
export interface ChainOperationTags {
|
|
76
|
-
inputTag: string;
|
|
77
|
-
outputTag: string;
|
|
78
|
-
}
|
|
79
|
-
/**
|
|
80
|
-
* The node of a character-based chain, used for diagnostic
|
|
81
|
-
* or demonstration purposes.
|
|
82
|
-
*/
|
|
83
|
-
export interface CharChainNode {
|
|
84
|
-
id: number;
|
|
85
|
-
label: string;
|
|
86
|
-
data: string;
|
|
87
|
-
sourceTag?: string;
|
|
88
|
-
}
|
|
89
|
-
/**
|
|
90
|
-
* The link of a character-based chain, used for diagnostic
|
|
91
|
-
* or demonstration purposes.
|
|
92
|
-
*/
|
|
93
|
-
export interface CharChainLink {
|
|
94
|
-
tag: string;
|
|
95
|
-
sourceId: number;
|
|
96
|
-
targetId: number;
|
|
97
|
-
}
|
|
98
|
-
/**
|
|
99
|
-
* The character-based chain, as resulting from running operations
|
|
100
|
-
* on a base text, used for diagnostic or demonstration purposes.
|
|
101
|
-
*/
|
|
102
|
-
export interface CharChain {
|
|
103
|
-
nodes: CharChainNode[];
|
|
104
|
-
links: CharChainLink[];
|
|
105
|
-
}
|
|
106
|
-
/**
|
|
107
|
-
* Service to interact with the GVE API.
|
|
108
|
-
*/
|
|
109
|
-
export declare class GveApiService {
|
|
110
|
-
private _http;
|
|
111
|
-
private _error;
|
|
112
|
-
private _env;
|
|
113
|
-
constructor(_http: HttpClient, _error: ErrorService, _env: EnvService);
|
|
114
|
-
/**
|
|
115
|
-
* Parse the specified text into operations. Each operation is a line
|
|
116
|
-
* of the text.
|
|
117
|
-
* @param text The text to parse.
|
|
118
|
-
* @returns The operations.
|
|
119
|
-
*/
|
|
120
|
-
parseOperations(text: string): Observable<ResultWrapper<CharChainOperation[]>>;
|
|
121
|
-
/**
|
|
122
|
-
* Run operations on the specified text.
|
|
123
|
-
*
|
|
124
|
-
* @param text The base text.
|
|
125
|
-
* @param operations The operations to run.
|
|
126
|
-
* @returns Result wrapper.
|
|
127
|
-
*/
|
|
128
|
-
runOperations(text: CharNode[], operations: CharChainOperation[]): Observable<ResultWrapper<CharChainResult>>;
|
|
129
|
-
/**
|
|
130
|
-
* Get the input and output tags for the given operations.
|
|
131
|
-
*
|
|
132
|
-
* @param operations The operations.
|
|
133
|
-
* @returns Result wrapper.
|
|
134
|
-
*/
|
|
135
|
-
getTags(operations: CharChainOperation[]): Observable<ResultWrapper<string[]>>;
|
|
136
|
-
/**
|
|
137
|
-
* Get the chain corresponding to the operations run on the
|
|
138
|
-
* specified text. This is used for diagnostic or demonstration
|
|
139
|
-
* purposes.
|
|
140
|
-
*
|
|
141
|
-
* @param text The base text.
|
|
142
|
-
* @param operations The operations to run.
|
|
143
|
-
* @returns Result wrapper.
|
|
144
|
-
*/
|
|
145
|
-
getChain(text: CharNode[], operations: CharChainOperation[]): Observable<ResultWrapper<CharChain>>;
|
|
146
|
-
static ɵfac: i0.ɵɵFactoryDeclaration<GveApiService, never>;
|
|
147
|
-
static ɵprov: i0.ɵɵInjectableDeclaration<GveApiService>;
|
|
148
|
-
}
|
|
@@ -1,20 +0,0 @@
|
|
|
1
|
-
import { CharChain } from './gve-api.service';
|
|
2
|
-
import * as i0 from "@angular/core";
|
|
3
|
-
export type GraphvizRankdir = 'TB' | 'LR' | 'BT' | 'RL';
|
|
4
|
-
export declare class GveGraphvizService {
|
|
5
|
-
private hashString;
|
|
6
|
-
private hslToRgb;
|
|
7
|
-
private getColorForTag;
|
|
8
|
-
private getExcludedNodeIds;
|
|
9
|
-
/**
|
|
10
|
-
* Represent the received chain as a Graphviz digraph.
|
|
11
|
-
*
|
|
12
|
-
* @param chain The source chain if any.
|
|
13
|
-
* @param tags The tags to show. When set, only the links with these tags are shown.
|
|
14
|
-
* @param rankdir The rank direction.
|
|
15
|
-
* @returns Graphviz representation of the chain.
|
|
16
|
-
*/
|
|
17
|
-
generateGraph(chain?: CharChain, tags?: string[], rankdir?: GraphvizRankdir): string;
|
|
18
|
-
static ɵfac: i0.ɵɵFactoryDeclaration<GveGraphvizService, never>;
|
|
19
|
-
static ɵprov: i0.ɵɵInjectableDeclaration<GveGraphvizService>;
|
|
20
|
-
}
|
|
@@ -1,89 +0,0 @@
|
|
|
1
|
-
import { Observable } from 'rxjs';
|
|
2
|
-
import * as i0 from "@angular/core";
|
|
3
|
-
/**
|
|
4
|
-
* Service to store and retrieve dynamic settings.
|
|
5
|
-
*/
|
|
6
|
-
export declare class SettingsService {
|
|
7
|
-
private readonly _cache;
|
|
8
|
-
private readonly _subject;
|
|
9
|
-
/**
|
|
10
|
-
* Observable emitting the key of the setting that has changed.
|
|
11
|
-
*/
|
|
12
|
-
get settingChange$(): Observable<string | null>;
|
|
13
|
-
/**
|
|
14
|
-
* Prefix to scope the keys. This prefix is used internally to scope the keys
|
|
15
|
-
* so that they cannot conflict with other keys in the local storage.
|
|
16
|
-
* The prefix is totally transparent to the user of the service, who should
|
|
17
|
-
* use the keys without the prefix.
|
|
18
|
-
*/
|
|
19
|
-
keyPrefix?: string;
|
|
20
|
-
/**
|
|
21
|
-
* True to persist the settings in the local storage by default.
|
|
22
|
-
*/
|
|
23
|
-
persistDefault: boolean;
|
|
24
|
-
/**
|
|
25
|
-
* Scopes the key by prefixing it with the keyPrefix if any.
|
|
26
|
-
*
|
|
27
|
-
* @param key The key to scope.
|
|
28
|
-
* @returns The scoped key.
|
|
29
|
-
*/
|
|
30
|
-
private getScopedKey;
|
|
31
|
-
private isPersist;
|
|
32
|
-
/**
|
|
33
|
-
* Sets a setting's value.
|
|
34
|
-
*
|
|
35
|
-
* @param key The key.
|
|
36
|
-
* @param value The value.
|
|
37
|
-
* @param persist True to persist this setting in local storage.
|
|
38
|
-
*/
|
|
39
|
-
set(key: string, value: any, persist?: boolean): void;
|
|
40
|
-
/**
|
|
41
|
-
* Set multiple settings at once from the specified settings object.
|
|
42
|
-
*
|
|
43
|
-
* @param settings The settings to set.
|
|
44
|
-
* @param persist True to persist these settings in local storage.
|
|
45
|
-
*/
|
|
46
|
-
setFrom(settings: {
|
|
47
|
-
[key: string]: any;
|
|
48
|
-
} | undefined | null, persist?: boolean): void;
|
|
49
|
-
/**
|
|
50
|
-
* Get a setting's value of type T.
|
|
51
|
-
*
|
|
52
|
-
* @param key The key.
|
|
53
|
-
* @param defaultValue The default value to get when the setting
|
|
54
|
-
* is not found in the store.
|
|
55
|
-
* @returns The value.
|
|
56
|
-
*/
|
|
57
|
-
get<T>(key: string, defaultValue?: any, persist?: boolean): T;
|
|
58
|
-
/**
|
|
59
|
-
* Check if a key exists in the store.
|
|
60
|
-
*
|
|
61
|
-
* @param key The key.
|
|
62
|
-
* @param persist True to check if the key exists in local storage.
|
|
63
|
-
* @returns True if the key exists in the store.
|
|
64
|
-
*/
|
|
65
|
-
contains(key: string, persist?: boolean): boolean;
|
|
66
|
-
/**
|
|
67
|
-
* Get all the keys of the settings in the store.
|
|
68
|
-
*
|
|
69
|
-
* @param persist True to include keys from local storage.
|
|
70
|
-
* @returns The keys of the settings in the store.
|
|
71
|
-
*/
|
|
72
|
-
getKeys(persist?: boolean): string[];
|
|
73
|
-
/**
|
|
74
|
-
* Remove a setting if present.
|
|
75
|
-
*
|
|
76
|
-
* @param key The key.
|
|
77
|
-
* @param persist True to remove the setting from local storage.
|
|
78
|
-
*/
|
|
79
|
-
remove(key: string, persist?: boolean): void;
|
|
80
|
-
/**
|
|
81
|
-
* Clear all settings. Warning: this will remove all settings from the
|
|
82
|
-
* local storage if no key prefix is set.
|
|
83
|
-
*
|
|
84
|
-
* @param persist True to remove all settings from local storage.
|
|
85
|
-
*/
|
|
86
|
-
clear(persist?: boolean): void;
|
|
87
|
-
static ɵfac: i0.ɵɵFactoryDeclaration<SettingsService, never>;
|
|
88
|
-
static ɵprov: i0.ɵɵInjectableDeclaration<SettingsService>;
|
|
89
|
-
}
|
package/public-api.d.ts
DELETED
|
@@ -1,21 +0,0 @@
|
|
|
1
|
-
export * from './lib/models';
|
|
2
|
-
export * from './lib/components/animation-timeline/animation-timeline.component';
|
|
3
|
-
export * from './lib/components/animation-tween/animation-tween.component';
|
|
4
|
-
export * from './lib/components/base-text-char/base-text-char.component';
|
|
5
|
-
export * from './lib/components/base-text-editor/base-text-editor.component';
|
|
6
|
-
export * from './lib/components/base-text-view/base-text-view.component';
|
|
7
|
-
export * from './lib/components/batch-operation-editor/batch-operation-editor.component';
|
|
8
|
-
export * from './lib/components/chain-operation-editor/chain-operation-editor.component';
|
|
9
|
-
export * from './lib/components/chain-result-view/chain-result-view.component';
|
|
10
|
-
export * from './lib/components/chain-view/chain-view.component';
|
|
11
|
-
export * from './lib/components/feature-editor/feature-editor.component';
|
|
12
|
-
export * from './lib/components/feature-set-editor/feature-set-editor.component';
|
|
13
|
-
export * from './lib/components/feature-set-view/feature-set-view.component';
|
|
14
|
-
export * from './lib/components/ln-heights-editor/ln-heights-editor.component';
|
|
15
|
-
export * from './lib/components/operation-source-editor/operation-source-editor.component';
|
|
16
|
-
export * from './lib/components/snapshot-editor/snapshot-editor.component';
|
|
17
|
-
export * from './lib/components/snapshot-text-editor/snapshot-text-editor.component';
|
|
18
|
-
export * from './lib/components/steps-map/steps-map.component';
|
|
19
|
-
export * from './lib/services/gve-api.service';
|
|
20
|
-
export * from './lib/services/gve-graphviz.service';
|
|
21
|
-
export * from './lib/services/settings.service';
|