@theia/messages 1.29.0-next.6 → 1.29.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/lib/browser/notification-content-renderer.spec.js +0 -1
- package/lib/browser/notification-content-renderer.spec.js.map +1 -1
- package/lib/browser/notifications-renderer.d.ts +2 -0
- package/lib/browser/notifications-renderer.d.ts.map +1 -1
- package/lib/browser/notifications-renderer.js +4 -3
- package/lib/browser/notifications-renderer.js.map +1 -1
- package/package.json +4 -4
- package/src/browser/notification-content-renderer.spec.ts +0 -2
- package/src/browser/notifications-renderer.tsx +5 -3
|
@@ -17,7 +17,6 @@
|
|
|
17
17
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
18
18
|
const chai_1 = require("chai");
|
|
19
19
|
const notification_content_renderer_1 = require("./notification-content-renderer");
|
|
20
|
-
/* eslint-disable no-unused-expressions */
|
|
21
20
|
describe('notification-content-renderer', () => {
|
|
22
21
|
const contentRenderer = new notification_content_renderer_1.NotificationContentRenderer();
|
|
23
22
|
it('should remove new lines', () => {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"notification-content-renderer.spec.js","sourceRoot":"","sources":["../../src/browser/notification-content-renderer.spec.ts"],"names":[],"mappings":";AAAA,gFAAgF;AAChF,yCAAyC;AACzC,EAAE;AACF,2EAA2E;AAC3E,mEAAmE;AACnE,wCAAwC;AACxC,EAAE;AACF,4EAA4E;AAC5E,8EAA8E;AAC9E,6EAA6E;AAC7E,yDAAyD;AACzD,uDAAuD;AACvD,EAAE;AACF,2EAA2E;AAC3E,gFAAgF;;AAEhF,+BAA8B;AAC9B,mFAA8E;AAE9E,
|
|
1
|
+
{"version":3,"file":"notification-content-renderer.spec.js","sourceRoot":"","sources":["../../src/browser/notification-content-renderer.spec.ts"],"names":[],"mappings":";AAAA,gFAAgF;AAChF,yCAAyC;AACzC,EAAE;AACF,2EAA2E;AAC3E,mEAAmE;AACnE,wCAAwC;AACxC,EAAE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AC,MAAM,CAAC,CAAC;AAEzE,CAAC,CAAC,CAAC"}
|
|
@@ -1,9 +1,11 @@
|
|
|
1
|
+
import { Root } from '@theia/core/shared/react-dom/client';
|
|
1
2
|
import { ApplicationShell, CorePreferences } from '@theia/core/lib/browser';
|
|
2
3
|
import { NotificationManager } from './notifications-manager';
|
|
3
4
|
export declare class NotificationsRenderer {
|
|
4
5
|
protected readonly shell: ApplicationShell;
|
|
5
6
|
protected readonly manager: NotificationManager;
|
|
6
7
|
protected readonly corePreferences: CorePreferences;
|
|
8
|
+
protected containerRoot: Root;
|
|
7
9
|
protected init(): void;
|
|
8
10
|
protected container: HTMLDivElement;
|
|
9
11
|
protected createOverlayContainer(): void;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"notifications-renderer.d.ts","sourceRoot":"","sources":["../../src/browser/notifications-renderer.tsx"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"notifications-renderer.d.ts","sourceRoot":"","sources":["../../src/browser/notifications-renderer.tsx"],"names":[],"mappings":"AAiBA,OAAO,EAAc,IAAI,EAAE,MAAM,qCAAqC,CAAC;AAEvE,OAAO,EAAE,gBAAgB,EAAE,eAAe,EAAE,MAAM,yBAAyB,CAAC;AAC5E,OAAO,EAAE,mBAAmB,EAAE,MAAM,yBAAyB,CAAC;AAI9D,qBACa,qBAAqB;IAG9B,SAAS,CAAC,QAAQ,CAAC,KAAK,EAAE,gBAAgB,CAAC;IAG3C,SAAS,CAAC,QAAQ,CAAC,OAAO,EAAE,mBAAmB,CAAC;IAGhD,SAAS,CAAC,QAAQ,CAAC,eAAe,EAAE,eAAe,CAAC;IACpD,SAAS,CAAC,aAAa,EAAE,IAAI,CAAC;IAG9B,SAAS,CAAC,IAAI,IAAI,IAAI;IAKtB,SAAS,CAAC,SAAS,EAAE,cAAc,CAAC;IACpC,SAAS,CAAC,sBAAsB,IAAI,IAAI;IASxC,SAAS,CAAC,MAAM,IAAI,IAAI;CAO3B"}
|
|
@@ -25,8 +25,8 @@ var __metadata = (this && this.__metadata) || function (k, v) {
|
|
|
25
25
|
};
|
|
26
26
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
27
27
|
exports.NotificationsRenderer = void 0;
|
|
28
|
-
const ReactDOM = require("@theia/core/shared/react-dom");
|
|
29
28
|
const React = require("@theia/core/shared/react");
|
|
29
|
+
const client_1 = require("@theia/core/shared/react-dom/client");
|
|
30
30
|
const inversify_1 = require("@theia/core/shared/inversify");
|
|
31
31
|
const browser_1 = require("@theia/core/lib/browser");
|
|
32
32
|
const notifications_manager_1 = require("./notifications-manager");
|
|
@@ -43,11 +43,12 @@ let NotificationsRenderer = class NotificationsRenderer {
|
|
|
43
43
|
if (window.document.body) {
|
|
44
44
|
window.document.body.appendChild(this.container);
|
|
45
45
|
}
|
|
46
|
+
this.containerRoot = (0, client_1.createRoot)(this.container);
|
|
46
47
|
}
|
|
47
48
|
render() {
|
|
48
|
-
|
|
49
|
+
this.containerRoot.render(React.createElement("div", null,
|
|
49
50
|
React.createElement(notification_toasts_component_1.NotificationToastsComponent, { manager: this.manager, corePreferences: this.corePreferences }),
|
|
50
|
-
React.createElement(notification_center_component_1.NotificationCenterComponent, { manager: this.manager }))
|
|
51
|
+
React.createElement(notification_center_component_1.NotificationCenterComponent, { manager: this.manager })));
|
|
51
52
|
}
|
|
52
53
|
};
|
|
53
54
|
__decorate([
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"notifications-renderer.js","sourceRoot":"","sources":["../../src/browser/notifications-renderer.tsx"],"names":[],"mappings":";AAAA,gFAAgF;AAChF,yCAAyC;AACzC,EAAE;AACF,2EAA2E;AAC3E,mEAAmE;AACnE,wCAAwC;AACxC,EAAE;AACF,4EAA4E;AAC5E,8EAA8E;AAC9E,6EAA6E;AAC7E,yDAAyD;AACzD,uDAAuD;AACvD,EAAE;AACF,2EAA2E;AAC3E,gFAAgF;;;;;;;;;;;;AAEhF,
|
|
1
|
+
{"version":3,"file":"notifications-renderer.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AAgB;oDAAC;AAG3C;IADC,IAAA,kBAAM,EAAC,2CAAmB,CAAC;8BACA,2CAAmB;sDAAC;AAGhD;IADC,IAAA,kBAAM,EAAC,yBAAe,CAAC;;8DAC4B;AAIpD;IADC,IAAA,yBAAa,GAAE;;;;iDAIf;AAhBQ,qBAAqB;IADjC,IAAA,sBAAU,GAAE;GACA,qBAAqB,CAmCjC;AAnCY,sDAAqB"}
|
package/package.json
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@theia/messages",
|
|
3
|
-
"version": "1.29.0
|
|
3
|
+
"version": "1.29.0",
|
|
4
4
|
"description": "Theia - Messages Extension",
|
|
5
5
|
"dependencies": {
|
|
6
|
-
"@theia/core": "1.29.0
|
|
6
|
+
"@theia/core": "1.29.0",
|
|
7
7
|
"react-perfect-scrollbar": "^1.5.3",
|
|
8
8
|
"ts-md5": "^1.2.2"
|
|
9
9
|
},
|
|
@@ -40,10 +40,10 @@
|
|
|
40
40
|
"watch": "theiaext watch"
|
|
41
41
|
},
|
|
42
42
|
"devDependencies": {
|
|
43
|
-
"@theia/ext-scripts": "1.
|
|
43
|
+
"@theia/ext-scripts": "1.29.0"
|
|
44
44
|
},
|
|
45
45
|
"nyc": {
|
|
46
46
|
"extends": "../../configs/nyc.json"
|
|
47
47
|
},
|
|
48
|
-
"gitHead": "
|
|
48
|
+
"gitHead": "054a575b92bd689505dcb74c1573b96483cc687c"
|
|
49
49
|
}
|
|
@@ -17,8 +17,6 @@
|
|
|
17
17
|
import { expect } from 'chai';
|
|
18
18
|
import { NotificationContentRenderer } from './notification-content-renderer';
|
|
19
19
|
|
|
20
|
-
/* eslint-disable no-unused-expressions */
|
|
21
|
-
|
|
22
20
|
describe('notification-content-renderer', () => {
|
|
23
21
|
|
|
24
22
|
const contentRenderer = new NotificationContentRenderer();
|
|
@@ -14,8 +14,8 @@
|
|
|
14
14
|
// SPDX-License-Identifier: EPL-2.0 OR GPL-2.0 WITH Classpath-exception-2.0
|
|
15
15
|
// *****************************************************************************
|
|
16
16
|
|
|
17
|
-
import * as ReactDOM from '@theia/core/shared/react-dom';
|
|
18
17
|
import * as React from '@theia/core/shared/react';
|
|
18
|
+
import { createRoot, Root } from '@theia/core/shared/react-dom/client';
|
|
19
19
|
import { injectable, inject, postConstruct } from '@theia/core/shared/inversify';
|
|
20
20
|
import { ApplicationShell, CorePreferences } from '@theia/core/lib/browser';
|
|
21
21
|
import { NotificationManager } from './notifications-manager';
|
|
@@ -33,6 +33,7 @@ export class NotificationsRenderer {
|
|
|
33
33
|
|
|
34
34
|
@inject(CorePreferences)
|
|
35
35
|
protected readonly corePreferences: CorePreferences;
|
|
36
|
+
protected containerRoot: Root;
|
|
36
37
|
|
|
37
38
|
@postConstruct()
|
|
38
39
|
protected init(): void {
|
|
@@ -47,13 +48,14 @@ export class NotificationsRenderer {
|
|
|
47
48
|
if (window.document.body) {
|
|
48
49
|
window.document.body.appendChild(this.container);
|
|
49
50
|
}
|
|
51
|
+
this.containerRoot = createRoot(this.container);
|
|
50
52
|
}
|
|
51
53
|
|
|
52
54
|
protected render(): void {
|
|
53
|
-
|
|
55
|
+
this.containerRoot.render(<div>
|
|
54
56
|
<NotificationToastsComponent manager={this.manager} corePreferences={this.corePreferences} />
|
|
55
57
|
<NotificationCenterComponent manager={this.manager} />
|
|
56
|
-
</div
|
|
58
|
+
</div>);
|
|
57
59
|
}
|
|
58
60
|
|
|
59
61
|
}
|