@dotglitch/ngx-common 1.0.21 → 1.0.23

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.
Files changed (61) hide show
  1. package/assets/mat-icons.d.ts +5705 -0
  2. package/components/filemanager/file-grid/file-grid.component.d.ts +97 -0
  3. package/components/filemanager/filemanager.component.d.ts +206 -0
  4. package/components/filemanager/folder-rename/folder-rename.component.d.ts +18 -0
  5. package/components/filemanager/helpers.d.ts +5 -0
  6. package/components/filemanager/icon-resolver.d.ts +13 -0
  7. package/components/filemanager/textextensions.d.ts +3 -0
  8. package/components/filemanager/toolbar/breadcrumb/breadcrumb.component.d.ts +16 -0
  9. package/components/filemanager/toolbar/icon-button/icon-button.component.d.ts +11 -0
  10. package/components/filemanager/toolbar/toolbar.component.d.ts +30 -0
  11. package/components/filemanager/tree-view/tree-view.component.d.ts +21 -0
  12. package/components/tabulator/tabulator.component.d.ts +30 -0
  13. package/components/types.d.ts +16 -0
  14. package/components/vscode/ts-type-resolver/dependency-parser.d.ts +6 -0
  15. package/components/vscode/ts-type-resolver/dummy-source-cache.d.ts +7 -0
  16. package/components/vscode/ts-type-resolver/import-resolver.d.ts +28 -0
  17. package/components/vscode/ts-type-resolver/main.d.ts +22 -0
  18. package/components/vscode/ts-type-resolver/recursion-depth.d.ts +11 -0
  19. package/components/vscode/ts-type-resolver/types.d.ts +179 -0
  20. package/components/vscode/ts-type-resolver/unpkg-source-resolver.d.ts +5 -0
  21. package/components/vscode/ts-type-resolver/update-emitter.d.ts +2 -0
  22. package/components/vscode/vscode.component.d.ts +57 -0
  23. package/esm2020/assets/mat-icons.mjs +5705 -0
  24. package/esm2020/components/filemanager/file-grid/file-grid.component.mjs +672 -0
  25. package/esm2020/components/filemanager/filemanager.component.mjs +301 -0
  26. package/esm2020/components/filemanager/folder-rename/folder-rename.component.mjs +57 -0
  27. package/esm2020/components/filemanager/helpers.mjs +26 -0
  28. package/esm2020/components/filemanager/icon-resolver.mjs +155 -0
  29. package/esm2020/components/filemanager/textextensions.mjs +294 -0
  30. package/esm2020/components/filemanager/toolbar/breadcrumb/breadcrumb.component.mjs +26 -0
  31. package/esm2020/components/filemanager/toolbar/icon-button/icon-button.component.mjs +34 -0
  32. package/esm2020/components/filemanager/toolbar/toolbar.component.mjs +163 -0
  33. package/esm2020/components/filemanager/tree-view/tree-view.component.mjs +53 -0
  34. package/esm2020/components/lazy-loader/lazy-loader.module.mjs +3 -3
  35. package/esm2020/components/lazy-loader/lazy-loader.service.mjs +1 -1
  36. package/esm2020/components/menu/menu.component.mjs +3 -4
  37. package/esm2020/components/tabulator/tabulator.component.mjs +92 -0
  38. package/esm2020/components/types.mjs +3 -0
  39. package/esm2020/components/vscode/ts-type-resolver/dependency-parser.mjs +91 -0
  40. package/esm2020/components/vscode/ts-type-resolver/dummy-source-cache.mjs +15 -0
  41. package/esm2020/components/vscode/ts-type-resolver/import-resolver.mjs +311 -0
  42. package/esm2020/components/vscode/ts-type-resolver/main.mjs +112 -0
  43. package/esm2020/components/vscode/ts-type-resolver/recursion-depth.mjs +21 -0
  44. package/esm2020/components/vscode/ts-type-resolver/types.mjs +14 -0
  45. package/esm2020/components/vscode/ts-type-resolver/unpkg-source-resolver.mjs +21 -0
  46. package/esm2020/components/vscode/ts-type-resolver/update-emitter.mjs +37 -0
  47. package/esm2020/components/vscode/vscode.component.mjs +230 -0
  48. package/esm2020/directives/menu.directive.mjs +19 -18
  49. package/esm2020/public-api.mjs +6 -1
  50. package/esm2020/types/menu.mjs +1 -1
  51. package/fesm2015/dotglitch-ngx-common-folder-rename.component-d039534b.mjs +79 -0
  52. package/fesm2015/dotglitch-ngx-common-folder-rename.component-d039534b.mjs.map +1 -0
  53. package/fesm2015/dotglitch-ngx-common.mjs +8361 -28
  54. package/fesm2015/dotglitch-ngx-common.mjs.map +1 -1
  55. package/fesm2020/dotglitch-ngx-common-folder-rename.component-ba3ebd0a.mjs +78 -0
  56. package/fesm2020/dotglitch-ngx-common-folder-rename.component-ba3ebd0a.mjs.map +1 -0
  57. package/fesm2020/dotglitch-ngx-common.mjs +8330 -27
  58. package/fesm2020/dotglitch-ngx-common.mjs.map +1 -1
  59. package/package.json +6 -2
  60. package/public-api.d.ts +4 -0
  61. package/types/menu.d.ts +4 -0
@@ -0,0 +1,179 @@
1
+ import type * as monaco from 'monaco-editor';
2
+ export interface SourceCache {
3
+ isFileAvailable?: (uri: string) => Promise<boolean>;
4
+ storeFile: (uri: string, content: string) => Promise<void>;
5
+ getFile: (uri: string) => Promise<string | undefined>;
6
+ clear: () => Promise<void>;
7
+ }
8
+ export type ProgressUpdate = {
9
+ type: 'CodeChanged';
10
+ } | {
11
+ type: 'ResolveNewImports';
12
+ } | {
13
+ type: 'LookedUpTypeFile';
14
+ path: string;
15
+ success: boolean;
16
+ } | {
17
+ type: 'AttemptedLookUpFile';
18
+ path: string;
19
+ success: boolean;
20
+ } | {
21
+ type: 'LookedUpPackage';
22
+ package: string;
23
+ definitelyTyped: boolean;
24
+ success: boolean;
25
+ } | {
26
+ type: 'LoadedFromCache';
27
+ importPath: string;
28
+ } | {
29
+ type: 'StoredToCache';
30
+ importPath: string;
31
+ };
32
+ export interface Options {
33
+ /**
34
+ * Share source cache between multiple editor instances by storing
35
+ * the cache in a static property.
36
+ *
37
+ * Defaults to false.
38
+ */
39
+ shareCache: boolean;
40
+ /**
41
+ * Only use packages specified in the `versions` property.
42
+ *
43
+ * Defaults to false.
44
+ */
45
+ onlySpecifiedPackages: boolean;
46
+ /**
47
+ * Load typings from prespecified versions when initializing. Versions
48
+ * need to be specified in the ``versions`` option.
49
+ *
50
+ * Defaults to false.
51
+ */
52
+ preloadPackages: boolean;
53
+ /**
54
+ * Updates compiler options to defaults suitable for auto-loaded
55
+ * declarations, specifically by setting ``moduleResolution`` to
56
+ * ``NodeJs`` and ``allowSyntheticDefaultImports`` to true.
57
+ * Other options are not changed. Set this property to true to
58
+ * disable this behaviour.
59
+ *
60
+ * Defaults to false.
61
+ */
62
+ dontAdaptEditorOptions: boolean;
63
+ /**
64
+ * After typings were resolved and injected into monaco, auto-typings
65
+ * updates the value of the current model to trigger a refresh in
66
+ * monaco's typing logic, so that it uses the injected typings.
67
+ */
68
+ dontRefreshModelValueAfterResolvement: boolean;
69
+ /**
70
+ * Prespecified package versions. If a package is loaded whose
71
+ * name is specified in this object, it will load with the exact
72
+ * version specified in the object.
73
+ *
74
+ * Example:
75
+ *
76
+ * ```json
77
+ * {
78
+ * "@types/react": "17.0.0",
79
+ * "csstype": "3.0.5"
80
+ * }
81
+ * ```
82
+ *
83
+ * Setting the option ``onlySpecifiedPackages`` to true makes this
84
+ * property act as a whitelist for packages.
85
+ *
86
+ * Setting the option ``preloadPackages`` makes the packages specified
87
+ * in this property load directly after initializing the auto-loader.
88
+ */
89
+ versions?: {
90
+ [packageName: string]: string;
91
+ };
92
+ /**
93
+ * If a new package was loaded, its name and version is added to the
94
+ * version object, and this method is called with the updated object.
95
+ * @param versions updated versions object.
96
+ */
97
+ onUpdateVersions?: (versions: {
98
+ [packageName: string]: string;
99
+ }) => void;
100
+ /**
101
+ * Supply a cache where declaration files and package.json files are
102
+ * cached to. Supply an instance of {@link LocalStorageCache} to cache
103
+ * files to localStorage.
104
+ */
105
+ sourceCache: SourceCache;
106
+ /**
107
+ * The root directory where your edited files are. Must end with
108
+ * a slash. The default is suitable unless you change the default
109
+ * URI of files loaded in the editor.
110
+ *
111
+ * Defaults to "inmemory://model/"
112
+ */
113
+ fileRootPath: string;
114
+ /**
115
+ * Debounces code reanalyzing after user has changed the editor contents
116
+ * by the specified amount. Set to zero to disable. Value provided in
117
+ * milliseconds.
118
+ *
119
+ * Defaults to 4000, i.e. 4 seconds.
120
+ */
121
+ debounceDuration: number;
122
+ /**
123
+ * Maximum recursion depth for recursing packages. Determines how many
124
+ * nested package declarations are loaded. For example, if ``packageRecursionDepth``
125
+ * has the value 2, the code in the monaco editor references packages ``A1``, ``A2``
126
+ * and ``A3``, package ``A1`` references package ``B1`` and ``B1`` references ``C1``,
127
+ * then packages ``A1``, ``A2``, ``A3`` and ``B1`` are loaded. Set to zero to
128
+ * disable.
129
+ *
130
+ * Defaults to 3.
131
+ */
132
+ packageRecursionDepth: number;
133
+ /**
134
+ * Maximum recursion depth for recursing files. Determines how many
135
+ * nested file declarations are loaded. The same as ``packageRecursionDepth``,
136
+ * but for individual files. Set to zero to disable.
137
+ *
138
+ * Defaults to 10.
139
+ */
140
+ fileRecursionDepth: number;
141
+ /**
142
+ * Called after progress updates like loaded declarations or events.
143
+ * @param update detailed event object containing update infos.
144
+ * @param textual a textual representation of the update for debugging.
145
+ */
146
+ onUpdate?: (update: ProgressUpdate, textual: string) => void;
147
+ /**
148
+ * Called if errors occur.
149
+ * @param error a textual representation of the error.
150
+ */
151
+ onError?: (error: string) => void;
152
+ /**
153
+ * instance of monaco editor
154
+ */
155
+ monaco: typeof monaco;
156
+ }
157
+ export interface ImportResourcePathPackage {
158
+ kind: 'package';
159
+ packageName: string;
160
+ importPath?: string;
161
+ }
162
+ export interface ImportResourcePathRelative {
163
+ kind: 'relative';
164
+ importPath: string;
165
+ sourcePath: string;
166
+ }
167
+ export interface ImportResourcePathRelativeInPackage {
168
+ kind: 'relative-in-package';
169
+ packageName: string;
170
+ importPath: string;
171
+ sourcePath: string;
172
+ }
173
+ export interface ImportResourceBruteForce {
174
+ kind: 'bruteforce';
175
+ packageName: string;
176
+ typingFiles: any[];
177
+ }
178
+ export type ImportResourcePath = ImportResourcePathPackage | ImportResourcePathRelative | ImportResourcePathRelativeInPackage | ImportResourceBruteForce;
179
+ export declare const importResourcePathToString: (p: ImportResourcePath) => any;
@@ -0,0 +1,5 @@
1
+ export declare class UnpkgSourceResolver {
2
+ static resolvePackageJson(packageName: string, version: string | undefined, subPath: string | undefined): Promise<string | undefined>;
3
+ static resolveSourceFile(packageName: string, version: string | undefined, path: string): Promise<string | undefined>;
4
+ private static resolveFile;
5
+ }
@@ -0,0 +1,2 @@
1
+ import { ProgressUpdate, Options } from './types';
2
+ export declare const invokeUpdate: (progress: ProgressUpdate, options: Options) => void;
@@ -0,0 +1,57 @@
1
+ import { AfterViewInit, EventEmitter, OnDestroy, SimpleChanges, ViewContainerRef } from '@angular/core';
2
+ import * as MonacoEditor from 'monaco-editor';
3
+ import * as i0 from "@angular/core";
4
+ export declare class VscodeComponent implements AfterViewInit, OnDestroy {
5
+ private viewContainer;
6
+ isDirty: boolean;
7
+ editor: MonacoEditor.editor.IStandaloneCodeEditor;
8
+ filename: string;
9
+ private _code;
10
+ set code(value: string);
11
+ get code(): string;
12
+ codeChange: EventEmitter<string>;
13
+ private onCodeType;
14
+ private typeDebounce;
15
+ customLanguage: {
16
+ init: Function;
17
+ };
18
+ private _language;
19
+ set language(value: string);
20
+ get language(): string;
21
+ installationLocation: string;
22
+ tabSize: number;
23
+ readOnly: boolean;
24
+ theme: string;
25
+ fontFamily: string;
26
+ fontSize: number;
27
+ automaticLayout: boolean;
28
+ colorDecorators: boolean;
29
+ folding: boolean;
30
+ minimapEnabled: boolean;
31
+ minimap: MonacoEditor.editor.IEditorMinimapOptions;
32
+ scrollbar: MonacoEditor.editor.IEditorScrollbarOptions;
33
+ smoothScrolling: boolean;
34
+ mouseWheelScrollSensitivity: number;
35
+ scrollBeyondLastLine: boolean;
36
+ scrollBeyondLastColumn: number;
37
+ scrollbarAlwaysConsumeMouseWheel: number;
38
+ lineNumbers: MonacoEditor.editor.LineNumbersType;
39
+ get settings(): MonacoEditor.editor.IStandaloneEditorConstructionOptions;
40
+ verticalScrollExhausted: boolean;
41
+ private _sub;
42
+ constructor(viewContainer: ViewContainerRef);
43
+ ngOnChanges(changes: SimpleChanges): void;
44
+ ngAfterViewInit(): Promise<void>;
45
+ ngOnDestroy(): void;
46
+ private createEditor;
47
+ private configureLanguageSupport;
48
+ /**
49
+ * true if the monaco UMD files are injected into the webpage
50
+ */
51
+ private static isMonacoInstalled;
52
+ private installMonaco;
53
+ download(): void;
54
+ resize: () => void;
55
+ static ɵfac: i0.ɵɵFactoryDeclaration<VscodeComponent, never>;
56
+ static ɵcmp: i0.ɵɵComponentDeclaration<VscodeComponent, "app-vscode", never, { "code": "code"; "customLanguage": "customLanguage"; "language": "language"; "installationLocation": "installationLocation"; "tabSize": "tabSize"; "readOnly": "readOnly"; "theme": "theme"; "fontFamily": "fontFamily"; "fontSize": "fontSize"; "automaticLayout": "automaticLayout"; "colorDecorators": "colorDecorators"; "folding": "folding"; "minimapEnabled": "minimapEnabled"; "minimap": "minimap"; "scrollbar": "scrollbar"; "smoothScrolling": "smoothScrolling"; "mouseWheelScrollSensitivity": "mouseWheelScrollSensitivity"; "scrollBeyondLastLine": "scrollBeyondLastLine"; "scrollBeyondLastColumn": "scrollBeyondLastColumn"; "scrollbarAlwaysConsumeMouseWheel": "scrollbarAlwaysConsumeMouseWheel"; "lineNumbers": "lineNumbers"; }, { "codeChange": "codeChange"; }, never, never, true, never>;
57
+ }