@theia/messages 1.34.1 → 1.34.3

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 (38) hide show
  1. package/LICENSE +641 -641
  2. package/README.md +30 -30
  3. package/lib/browser/messages-frontend-module.d.ts +4 -4
  4. package/lib/browser/messages-frontend-module.js +43 -43
  5. package/lib/browser/notification-center-component.d.ts +18 -18
  6. package/lib/browser/notification-center-component.js +67 -67
  7. package/lib/browser/notification-component.d.ts +15 -15
  8. package/lib/browser/notification-component.js +88 -88
  9. package/lib/browser/notification-content-renderer.d.ts +5 -5
  10. package/lib/browser/notification-content-renderer.js +40 -40
  11. package/lib/browser/notification-content-renderer.spec.d.ts +1 -1
  12. package/lib/browser/notification-content-renderer.spec.js +41 -41
  13. package/lib/browser/notification-preferences.d.ts +11 -11
  14. package/lib/browser/notification-preferences.js +46 -46
  15. package/lib/browser/notification-toasts-component.d.ts +18 -18
  16. package/lib/browser/notification-toasts-component.js +48 -48
  17. package/lib/browser/notifications-commands.d.ts +7 -7
  18. package/lib/browser/notifications-commands.js +47 -47
  19. package/lib/browser/notifications-contribution.d.ts +30 -30
  20. package/lib/browser/notifications-contribution.js +232 -232
  21. package/lib/browser/notifications-manager.d.ts +69 -69
  22. package/lib/browser/notifications-manager.js +277 -277
  23. package/lib/browser/notifications-renderer.d.ts +13 -13
  24. package/lib/browser/notifications-renderer.js +75 -75
  25. package/package.json +4 -4
  26. package/src/browser/messages-frontend-module.ts +44 -44
  27. package/src/browser/notification-center-component.tsx +95 -95
  28. package/src/browser/notification-component.tsx +128 -128
  29. package/src/browser/notification-content-renderer.spec.ts +73 -73
  30. package/src/browser/notification-content-renderer.ts +31 -31
  31. package/src/browser/notification-preferences.ts +58 -58
  32. package/src/browser/notification-toasts-component.tsx +67 -67
  33. package/src/browser/notifications-commands.ts +50 -50
  34. package/src/browser/notifications-contribution.ts +235 -235
  35. package/src/browser/notifications-manager.ts +297 -297
  36. package/src/browser/notifications-renderer.tsx +61 -61
  37. package/src/browser/style/index.css +17 -17
  38. package/src/browser/style/notifications.css +270 -270
@@ -1,270 +1,270 @@
1
- /********************************************************************************
2
- * Copyright (C) 2019 TypeFox and others.
3
- *
4
- * This program and the accompanying materials are made available under the
5
- * terms of the Eclipse Public License v. 2.0 which is available at
6
- * http://www.eclipse.org/legal/epl-2.0.
7
- *
8
- * This Source Code may also be made available under the following Secondary
9
- * Licenses when the conditions for such availability set forth in the Eclipse
10
- * Public License v. 2.0 are satisfied: GNU General Public License, version 2
11
- * with the GNU Classpath Exception which is available at
12
- * https://www.gnu.org/software/classpath/license.html.
13
- *
14
- * SPDX-License-Identifier: EPL-2.0 OR GPL-2.0 WITH Classpath-exception-2.0
15
- ********************************************************************************/
16
-
17
- /* Container */
18
-
19
- .theia-notifications-overlay {
20
- height: 0px;
21
- }
22
-
23
- .theia-notifications-container {
24
- position: absolute;
25
- bottom: 36px;
26
- right: 16px;
27
- width: 500px;
28
- user-select: none;
29
- z-index: 1111;
30
- }
31
- .theia-notifications-container.closed {
32
- display: none;
33
- }
34
- .theia-notifications-container > * {
35
- position: relative;
36
- }
37
-
38
- /* Toasts */
39
-
40
- .theia-notifications-container.theia-notification-toasts .theia-notification-list-item-container {
41
- margin-top: 6px;
42
- }
43
-
44
- .theia-notifications-container.theia-notification-toasts .theia-notification-list-item {
45
- box-shadow: 0px 0px 4px 0px var(--theia-widget-shadow);
46
- border: 1px solid var(--theia-notificationToast-border);
47
- }
48
-
49
- /* Center */
50
-
51
- .theia-notifications-container.theia-notification-center {
52
- background-color: var(--theia-notifications-background);
53
- border: 1px solid var(--theia-notificationCenter-border);
54
- box-shadow: 0px 0px 6px 0px var(--theia-widget-shadow);
55
- }
56
-
57
- /* Center > Header */
58
-
59
- .theia-notification-center-header {
60
- color: var(--theia-notificationCenterHeader-foreground);
61
- background-color: var(--theia-notificationCenterHeader-background);
62
- display: flex;
63
- flex-direction: row;
64
- flex-wrap: nowrap;
65
- justify-content: flex-end;
66
- min-height: 30px;
67
- align-items: center;
68
- }
69
-
70
- .theia-notification-center-header-title {
71
- font-size: calc(var(--theia-ui-font-size1) / 1.1);
72
- font-family: var(--theia-ui-font-family);
73
- margin: 8px;
74
- flex-grow: 2;
75
- }
76
-
77
- .theia-notification-center-header-actions {
78
- margin: 8px;
79
- }
80
-
81
- /* List */
82
-
83
- .theia-notification-list-scroll-container {
84
- max-height: 300px;
85
- overflow: auto;
86
- }
87
-
88
- .theia-notification-list {
89
- display: flex;
90
- flex-direction: column-reverse;
91
- flex-wrap: nowrap;
92
- }
93
-
94
-
95
- /* List > Item */
96
-
97
- .theia-notification-list-item {
98
- background-color: var(--theia-notifications-background);
99
- width: 100%;
100
- cursor: pointer;
101
- flex-grow: 1;
102
- display: flex;
103
- flex-direction: column;
104
- flex-wrap: nowrap;
105
- justify-content: space-between;
106
- }
107
-
108
- .theia-notification-list-item:focus {
109
- border-color: var(--theia-focusBorder);
110
- }
111
-
112
- .theia-notification-center .theia-notification-list-item:not(:last-child) {
113
- border-top: 1px var(--theia-notifications-border) solid;
114
- }
115
-
116
- .theia-notification-list-item-content {
117
- margin: 6px;
118
- flex-grow: 3;
119
- }
120
- .theia-notification-list-item-content.collapsed .theia-notification-list-item-content-bottom {
121
- display: none;
122
- }
123
- .theia-notification-list-item-content.collapsed .theia-notification-message {
124
- overflow: hidden;
125
- text-overflow: ellipsis;
126
- white-space: nowrap;
127
- }
128
-
129
- .theia-notification-list-item-content-main {
130
- display: flex;
131
- flex-direction: row;
132
- flex-wrap: nowrap;
133
- justify-content: space-between;
134
- padding: 5px 4px 7px 4px;
135
- }
136
-
137
- .theia-notification-message {
138
- font-size: var(--theia-ui-font-size1);
139
- font-family: var(--theia-ui-font-family);
140
- overflow-wrap: break-word;
141
- box-sizing: border-box;
142
- flex-basis: 0%;
143
- flex-grow: 1;
144
- flex-shrink: 1;
145
- display: block;
146
- overflow: hidden;
147
- user-select: text;
148
- margin-top: 3px;
149
- }
150
-
151
- .theia-notification-message a {
152
- border: none;
153
- color: var(--theia-notificationLink-foreground);
154
- outline: 0;
155
- text-decoration: none;
156
- }
157
- .theia-notification-message a:focus {
158
- outline-color: var(--theia-focusBorder);
159
- }
160
-
161
- .theia-notification-icon {
162
- margin-top: 1px;
163
- }
164
-
165
- .theia-notification-icon:before {
166
- font-size: 18px;
167
- padding-right: 4px;
168
- }
169
-
170
- .theia-notification-icon.info:before {
171
- color: var(--theia-notificationsInfoIcon-foreground);
172
- }
173
-
174
- .theia-notification-icon.warning:before {
175
- color: var(--theia-notificationsWarningIcon-foreground);
176
- }
177
-
178
- .theia-notification-icon.error:before {
179
- color: var(--theia-notificationsErrorIcon-foreground);
180
- }
181
-
182
- .theia-notification-actions {
183
- display: flex;
184
- flex-direction: row;
185
- flex-wrap: nowrap;
186
- justify-content: space-between;
187
- margin: 0px;
188
- padding: 0px;
189
- }
190
-
191
- .theia-notification-actions > li {
192
- display: inline-block;
193
- height: 16px;
194
- width: 16px;
195
- cursor: pointer;
196
- margin-left: 4px;
197
- }
198
-
199
- .theia-notification-actions > .expand {
200
- transform: rotate(180deg);
201
- }
202
-
203
- .theia-notification-list-item-content-bottom {
204
- display: flex;
205
- flex-direction: row;
206
- flex-wrap: wrap;
207
- justify-content: space-between;
208
- }
209
-
210
- .theia-notification-source {
211
- font-size: var(--theia-ui-font-size0);
212
- font-family: var(--theia-ui-font-family);
213
- overflow-wrap: break-word;
214
- box-sizing: border-box;
215
- flex-grow: 1;
216
- padding: 4px;
217
- display: block;
218
- overflow: hidden;
219
- }
220
-
221
- .theia-notification-buttons {
222
- flex-grow: 2;
223
- display: flex;
224
- flex-direction: row;
225
- justify-content: flex-end;
226
- flex-wrap: wrap;
227
- }
228
-
229
- .theia-notification-buttons > button {
230
- margin: 4px;
231
- max-width: 160px;
232
- text-overflow: ellipsis;
233
- white-space: nowrap;
234
- overflow: hidden;
235
- }
236
-
237
- .theia-notification-item-progress {
238
- display: block;
239
- }
240
-
241
- .theia-notification-item-progressbar {
242
- height: 2px;
243
- background-color: var(--theia-progressBar-background);
244
- width: 66%;
245
- }
246
-
247
- .theia-notification-item-progressbar.indeterminate {
248
- /* `progress-animation` is defined in `packages/core/src/browser/style/progress-bar.css` */
249
- animation: progress-animation 1.3s 0s infinite cubic-bezier(0.645, 0.045, 0.355, 1);
250
- }
251
-
252
- /* Perfect scrollbar */
253
-
254
- .theia-notification-list-scroll-container .ps__rail-y {
255
- width: var(--theia-scrollbar-rail-width);
256
- }
257
-
258
- .theia-notification-list-scroll-container .ps__rail-y:hover > .ps__thumb-y,
259
- .theia-notification-list-scroll-container .ps__rail-y:focus > .ps__thumb-y,
260
- .theia-notification-list-scroll-container .ps__rail-y.ps--clicking .ps__thumb-y {
261
- right: calc((var(--theia-scrollbar-rail-width) - var(--theia-scrollbar-width)) / 2);
262
- width: var(--theia-scrollbar-width);
263
- }
264
-
265
- .theia-notification-list-scroll-container .ps__rail-y > .ps__thumb-y {
266
- width: var(--theia-scrollbar-width);
267
- right: calc((var(--theia-scrollbar-rail-width) - var(--theia-scrollbar-width)) / 2);
268
- background: var(--theia-scrollbarSlider-background);
269
- border-radius: 0px;
270
- }
1
+ /********************************************************************************
2
+ * Copyright (C) 2019 TypeFox and others.
3
+ *
4
+ * This program and the accompanying materials are made available under the
5
+ * terms of the Eclipse Public License v. 2.0 which is available at
6
+ * http://www.eclipse.org/legal/epl-2.0.
7
+ *
8
+ * This Source Code may also be made available under the following Secondary
9
+ * Licenses when the conditions for such availability set forth in the Eclipse
10
+ * Public License v. 2.0 are satisfied: GNU General Public License, version 2
11
+ * with the GNU Classpath Exception which is available at
12
+ * https://www.gnu.org/software/classpath/license.html.
13
+ *
14
+ * SPDX-License-Identifier: EPL-2.0 OR GPL-2.0 WITH Classpath-exception-2.0
15
+ ********************************************************************************/
16
+
17
+ /* Container */
18
+
19
+ .theia-notifications-overlay {
20
+ height: 0px;
21
+ }
22
+
23
+ .theia-notifications-container {
24
+ position: absolute;
25
+ bottom: 36px;
26
+ right: 16px;
27
+ width: 500px;
28
+ user-select: none;
29
+ z-index: 1111;
30
+ }
31
+ .theia-notifications-container.closed {
32
+ display: none;
33
+ }
34
+ .theia-notifications-container > * {
35
+ position: relative;
36
+ }
37
+
38
+ /* Toasts */
39
+
40
+ .theia-notifications-container.theia-notification-toasts .theia-notification-list-item-container {
41
+ margin-top: 6px;
42
+ }
43
+
44
+ .theia-notifications-container.theia-notification-toasts .theia-notification-list-item {
45
+ box-shadow: 0px 0px 4px 0px var(--theia-widget-shadow);
46
+ border: 1px solid var(--theia-notificationToast-border);
47
+ }
48
+
49
+ /* Center */
50
+
51
+ .theia-notifications-container.theia-notification-center {
52
+ background-color: var(--theia-notifications-background);
53
+ border: 1px solid var(--theia-notificationCenter-border);
54
+ box-shadow: 0px 0px 6px 0px var(--theia-widget-shadow);
55
+ }
56
+
57
+ /* Center > Header */
58
+
59
+ .theia-notification-center-header {
60
+ color: var(--theia-notificationCenterHeader-foreground);
61
+ background-color: var(--theia-notificationCenterHeader-background);
62
+ display: flex;
63
+ flex-direction: row;
64
+ flex-wrap: nowrap;
65
+ justify-content: flex-end;
66
+ min-height: 30px;
67
+ align-items: center;
68
+ }
69
+
70
+ .theia-notification-center-header-title {
71
+ font-size: calc(var(--theia-ui-font-size1) / 1.1);
72
+ font-family: var(--theia-ui-font-family);
73
+ margin: 8px;
74
+ flex-grow: 2;
75
+ }
76
+
77
+ .theia-notification-center-header-actions {
78
+ margin: 8px;
79
+ }
80
+
81
+ /* List */
82
+
83
+ .theia-notification-list-scroll-container {
84
+ max-height: 300px;
85
+ overflow: auto;
86
+ }
87
+
88
+ .theia-notification-list {
89
+ display: flex;
90
+ flex-direction: column-reverse;
91
+ flex-wrap: nowrap;
92
+ }
93
+
94
+
95
+ /* List > Item */
96
+
97
+ .theia-notification-list-item {
98
+ background-color: var(--theia-notifications-background);
99
+ width: 100%;
100
+ cursor: pointer;
101
+ flex-grow: 1;
102
+ display: flex;
103
+ flex-direction: column;
104
+ flex-wrap: nowrap;
105
+ justify-content: space-between;
106
+ }
107
+
108
+ .theia-notification-list-item:focus {
109
+ border-color: var(--theia-focusBorder);
110
+ }
111
+
112
+ .theia-notification-center .theia-notification-list-item:not(:last-child) {
113
+ border-top: 1px var(--theia-notifications-border) solid;
114
+ }
115
+
116
+ .theia-notification-list-item-content {
117
+ margin: 6px;
118
+ flex-grow: 3;
119
+ }
120
+ .theia-notification-list-item-content.collapsed .theia-notification-list-item-content-bottom {
121
+ display: none;
122
+ }
123
+ .theia-notification-list-item-content.collapsed .theia-notification-message {
124
+ overflow: hidden;
125
+ text-overflow: ellipsis;
126
+ white-space: nowrap;
127
+ }
128
+
129
+ .theia-notification-list-item-content-main {
130
+ display: flex;
131
+ flex-direction: row;
132
+ flex-wrap: nowrap;
133
+ justify-content: space-between;
134
+ padding: 5px 4px 7px 4px;
135
+ }
136
+
137
+ .theia-notification-message {
138
+ font-size: var(--theia-ui-font-size1);
139
+ font-family: var(--theia-ui-font-family);
140
+ overflow-wrap: break-word;
141
+ box-sizing: border-box;
142
+ flex-basis: 0%;
143
+ flex-grow: 1;
144
+ flex-shrink: 1;
145
+ display: block;
146
+ overflow: hidden;
147
+ user-select: text;
148
+ margin-top: 3px;
149
+ }
150
+
151
+ .theia-notification-message a {
152
+ border: none;
153
+ color: var(--theia-notificationLink-foreground);
154
+ outline: 0;
155
+ text-decoration: none;
156
+ }
157
+ .theia-notification-message a:focus {
158
+ outline-color: var(--theia-focusBorder);
159
+ }
160
+
161
+ .theia-notification-icon {
162
+ margin-top: 1px;
163
+ }
164
+
165
+ .theia-notification-icon:before {
166
+ font-size: 18px;
167
+ padding-right: 4px;
168
+ }
169
+
170
+ .theia-notification-icon.info:before {
171
+ color: var(--theia-notificationsInfoIcon-foreground);
172
+ }
173
+
174
+ .theia-notification-icon.warning:before {
175
+ color: var(--theia-notificationsWarningIcon-foreground);
176
+ }
177
+
178
+ .theia-notification-icon.error:before {
179
+ color: var(--theia-notificationsErrorIcon-foreground);
180
+ }
181
+
182
+ .theia-notification-actions {
183
+ display: flex;
184
+ flex-direction: row;
185
+ flex-wrap: nowrap;
186
+ justify-content: space-between;
187
+ margin: 0px;
188
+ padding: 0px;
189
+ }
190
+
191
+ .theia-notification-actions > li {
192
+ display: inline-block;
193
+ height: 16px;
194
+ width: 16px;
195
+ cursor: pointer;
196
+ margin-left: 4px;
197
+ }
198
+
199
+ .theia-notification-actions > .expand {
200
+ transform: rotate(180deg);
201
+ }
202
+
203
+ .theia-notification-list-item-content-bottom {
204
+ display: flex;
205
+ flex-direction: row;
206
+ flex-wrap: wrap;
207
+ justify-content: space-between;
208
+ }
209
+
210
+ .theia-notification-source {
211
+ font-size: var(--theia-ui-font-size0);
212
+ font-family: var(--theia-ui-font-family);
213
+ overflow-wrap: break-word;
214
+ box-sizing: border-box;
215
+ flex-grow: 1;
216
+ padding: 4px;
217
+ display: block;
218
+ overflow: hidden;
219
+ }
220
+
221
+ .theia-notification-buttons {
222
+ flex-grow: 2;
223
+ display: flex;
224
+ flex-direction: row;
225
+ justify-content: flex-end;
226
+ flex-wrap: wrap;
227
+ }
228
+
229
+ .theia-notification-buttons > button {
230
+ margin: 4px;
231
+ max-width: 160px;
232
+ text-overflow: ellipsis;
233
+ white-space: nowrap;
234
+ overflow: hidden;
235
+ }
236
+
237
+ .theia-notification-item-progress {
238
+ display: block;
239
+ }
240
+
241
+ .theia-notification-item-progressbar {
242
+ height: 2px;
243
+ background-color: var(--theia-progressBar-background);
244
+ width: 66%;
245
+ }
246
+
247
+ .theia-notification-item-progressbar.indeterminate {
248
+ /* `progress-animation` is defined in `packages/core/src/browser/style/progress-bar.css` */
249
+ animation: progress-animation 1.3s 0s infinite cubic-bezier(0.645, 0.045, 0.355, 1);
250
+ }
251
+
252
+ /* Perfect scrollbar */
253
+
254
+ .theia-notification-list-scroll-container .ps__rail-y {
255
+ width: var(--theia-scrollbar-rail-width);
256
+ }
257
+
258
+ .theia-notification-list-scroll-container .ps__rail-y:hover > .ps__thumb-y,
259
+ .theia-notification-list-scroll-container .ps__rail-y:focus > .ps__thumb-y,
260
+ .theia-notification-list-scroll-container .ps__rail-y.ps--clicking .ps__thumb-y {
261
+ right: calc((var(--theia-scrollbar-rail-width) - var(--theia-scrollbar-width)) / 2);
262
+ width: var(--theia-scrollbar-width);
263
+ }
264
+
265
+ .theia-notification-list-scroll-container .ps__rail-y > .ps__thumb-y {
266
+ width: var(--theia-scrollbar-width);
267
+ right: calc((var(--theia-scrollbar-rail-width) - var(--theia-scrollbar-width)) / 2);
268
+ background: var(--theia-scrollbarSlider-background);
269
+ border-radius: 0px;
270
+ }