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