1 | import { DocumentRegistry } from '@jupyterlab/docregistry';
|
2 | import { ITranslator } from '@jupyterlab/translation';
|
3 | import { VDomModel, VDomRenderer } from '@jupyterlab/ui-components';
|
4 | import { Widget } from '@lumino/widgets';
|
5 | import { IDocumentManager } from './tokens';
|
6 |
|
7 |
|
8 |
|
9 | export declare class SavingStatus extends VDomRenderer<SavingStatus.Model> {
|
10 | |
11 |
|
12 |
|
13 | constructor(opts: SavingStatus.IOptions);
|
14 | /**
|
15 | * Render the SavingStatus item.
|
16 | */
|
17 | render(): JSX.Element | null;
|
18 | private _statusMap;
|
19 | }
|
20 | /**
|
21 | * A namespace for SavingStatus statics.
|
22 | */
|
23 | export declare namespace SavingStatus {
|
24 | |
25 |
|
26 |
|
27 | class Model extends VDomModel {
|
28 | |
29 |
|
30 |
|
31 | constructor(docManager: IDocumentManager);
|
32 | /**
|
33 | * The current status of the model.
|
34 | */
|
35 | get status(): DocumentRegistry.SaveState | null;
|
36 | /**
|
37 | * The current widget for the model. Any widget can be assigned,
|
38 | * but it only has any effect if the widget is an IDocument widget
|
39 | * known to the application document manager.
|
40 | */
|
41 | get widget(): Widget | null;
|
42 | set widget(widget: Widget | null);
|
43 | /**
|
44 | * React to a saving status change from the current document widget.
|
45 | */
|
46 | private _onStatusChange;
|
47 | private _status;
|
48 | private _widget;
|
49 | private _docManager;
|
50 | }
|
51 | /**
|
52 | * Options for creating a new SaveStatus item
|
53 | */
|
54 | interface IOptions {
|
55 | |
56 |
|
57 |
|
58 | docManager: IDocumentManager;
|
59 | |
60 |
|
61 |
|
62 | translator?: ITranslator;
|
63 | }
|
64 | }
|