@microsoft/applicationinsights-debugplugin-js 2.8.0-beta.2203-07 → 2.8.0-beta.2203-10

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 (54) hide show
  1. package/browser/{ai.dbg.2.8.0-beta.2203-07.cjs.js → ai.dbg.2.8.0-beta.2203-10.cjs.js} +14 -6
  2. package/browser/ai.dbg.2.8.0-beta.2203-10.cjs.js.map +1 -0
  3. package/browser/ai.dbg.2.8.0-beta.2203-10.cjs.min.js +6 -0
  4. package/browser/ai.dbg.2.8.0-beta.2203-10.cjs.min.js.map +1 -0
  5. package/browser/{ai.dbg.2.8.0-beta.2203-07.gbl.js → ai.dbg.2.8.0-beta.2203-10.gbl.js} +14 -6
  6. package/browser/ai.dbg.2.8.0-beta.2203-10.gbl.js.map +1 -0
  7. package/browser/ai.dbg.2.8.0-beta.2203-10.gbl.min.js +6 -0
  8. package/browser/ai.dbg.2.8.0-beta.2203-10.gbl.min.js.map +1 -0
  9. package/browser/ai.dbg.2.8.0-beta.2203-10.integrity.json +66 -0
  10. package/browser/{ai.dbg.2.8.0-beta.2203-07.js → ai.dbg.2.8.0-beta.2203-10.js} +14 -6
  11. package/browser/ai.dbg.2.8.0-beta.2203-10.js.map +1 -0
  12. package/browser/ai.dbg.2.8.0-beta.2203-10.min.js +6 -0
  13. package/browser/ai.dbg.2.8.0-beta.2203-10.min.js.map +1 -0
  14. package/browser/ai.dbg.2.cjs.js +13 -5
  15. package/browser/ai.dbg.2.cjs.js.map +1 -1
  16. package/browser/ai.dbg.2.cjs.min.js +2 -2
  17. package/browser/ai.dbg.2.cjs.min.js.map +1 -1
  18. package/browser/ai.dbg.2.gbl.js +13 -5
  19. package/browser/ai.dbg.2.gbl.js.map +1 -1
  20. package/browser/ai.dbg.2.gbl.min.js +2 -2
  21. package/browser/ai.dbg.2.gbl.min.js.map +1 -1
  22. package/browser/ai.dbg.2.js +13 -5
  23. package/browser/ai.dbg.2.js.map +1 -1
  24. package/browser/ai.dbg.2.min.js +2 -2
  25. package/browser/ai.dbg.2.min.js.map +1 -1
  26. package/dist/applicationinsights-debugplugin-js.d.ts +1 -1
  27. package/dist/applicationinsights-debugplugin-js.js +13 -5
  28. package/dist/applicationinsights-debugplugin-js.js.map +1 -1
  29. package/dist/applicationinsights-debugplugin-js.min.js +2 -2
  30. package/dist/applicationinsights-debugplugin-js.min.js.map +1 -1
  31. package/dist/applicationinsights-debugplugin-js.rollup.d.ts +1 -1
  32. package/dist-esm/DebugPlugin.js +1 -1
  33. package/dist-esm/applicationinsights-debugplugin-js.js +1 -1
  34. package/dist-esm/components/Dashboard.js +1 -1
  35. package/dist-esm/components/LogEntry.js +1 -1
  36. package/dist-esm/components/debugBins.js +1 -1
  37. package/dist-esm/components/filterList.js +1 -1
  38. package/dist-esm/components/helpers.js +1 -1
  39. package/dist-esm/components/styleNodeSrc.js +1 -1
  40. package/dist-esm/interfaces/IDebugPluginConfig.js +1 -1
  41. package/package.json +3 -3
  42. package/src/components/debugBins.ts +7 -6
  43. package/src/components/helpers.ts +55 -45
  44. package/src/components/styleNodeSrc.ts +33 -33
  45. package/browser/ai.dbg.2.8.0-beta.2203-07.cjs.js.map +0 -1
  46. package/browser/ai.dbg.2.8.0-beta.2203-07.cjs.min.js +0 -6
  47. package/browser/ai.dbg.2.8.0-beta.2203-07.cjs.min.js.map +0 -1
  48. package/browser/ai.dbg.2.8.0-beta.2203-07.gbl.js.map +0 -1
  49. package/browser/ai.dbg.2.8.0-beta.2203-07.gbl.min.js +0 -6
  50. package/browser/ai.dbg.2.8.0-beta.2203-07.gbl.min.js.map +0 -1
  51. package/browser/ai.dbg.2.8.0-beta.2203-07.integrity.json +0 -66
  52. package/browser/ai.dbg.2.8.0-beta.2203-07.js.map +0 -1
  53. package/browser/ai.dbg.2.8.0-beta.2203-07.min.js +0 -6
  54. package/browser/ai.dbg.2.8.0-beta.2203-07.min.js.map +0 -1
@@ -1,5 +1,5 @@
1
1
  /*
2
- * Microsoft.ApplicationInsights, 2.8.0-beta.2203-07
2
+ * Microsoft.ApplicationInsights, 2.8.0-beta.2203-10
3
3
  * Copyright (c) Microsoft and contributors. All rights reserved.
4
4
  *
5
5
  * Microsoft Application Insights Team
@@ -1,5 +1,5 @@
1
1
  /*
2
- * Application Insights JavaScript SDK - Debug Plugin, 2.8.0-beta.2203-07
2
+ * Application Insights JavaScript SDK - Debug Plugin, 2.8.0-beta.2203-10
3
3
  * Copyright (c) Microsoft and contributors. All rights reserved.
4
4
  */
5
5
 
@@ -1,5 +1,5 @@
1
1
  /*
2
- * Application Insights JavaScript SDK - Debug Plugin, 2.8.0-beta.2203-07
2
+ * Application Insights JavaScript SDK - Debug Plugin, 2.8.0-beta.2203-10
3
3
  * Copyright (c) Microsoft and contributors. All rights reserved.
4
4
  */
5
5
 
@@ -1,5 +1,5 @@
1
1
  /*
2
- * Application Insights JavaScript SDK - Debug Plugin, 2.8.0-beta.2203-07
2
+ * Application Insights JavaScript SDK - Debug Plugin, 2.8.0-beta.2203-10
3
3
  * Copyright (c) Microsoft and contributors. All rights reserved.
4
4
  */
5
5
  import { arrForEach } from "@microsoft/applicationinsights-core-js";
@@ -1,5 +1,5 @@
1
1
  /*
2
- * Application Insights JavaScript SDK - Debug Plugin, 2.8.0-beta.2203-07
2
+ * Application Insights JavaScript SDK - Debug Plugin, 2.8.0-beta.2203-10
3
3
  * Copyright (c) Microsoft and contributors. All rights reserved.
4
4
  */
5
5
  import { isBoolean, isNumber, isObject, isString } from "@microsoft/applicationinsights-core-js";
@@ -1,5 +1,5 @@
1
1
  /*
2
- * Application Insights JavaScript SDK - Debug Plugin, 2.8.0-beta.2203-07
2
+ * Application Insights JavaScript SDK - Debug Plugin, 2.8.0-beta.2203-10
3
3
  * Copyright (c) Microsoft and contributors. All rights reserved.
4
4
  */
5
5
 
@@ -1,5 +1,5 @@
1
1
  /*
2
- * Application Insights JavaScript SDK - Debug Plugin, 2.8.0-beta.2203-07
2
+ * Application Insights JavaScript SDK - Debug Plugin, 2.8.0-beta.2203-10
3
3
  * Copyright (c) Microsoft and contributors. All rights reserved.
4
4
  */
5
5
 
@@ -1,5 +1,5 @@
1
1
  /*
2
- * Application Insights JavaScript SDK - Debug Plugin, 2.8.0-beta.2203-07
2
+ * Application Insights JavaScript SDK - Debug Plugin, 2.8.0-beta.2203-10
3
3
  * Copyright (c) Microsoft and contributors. All rights reserved.
4
4
  */
5
5
 
@@ -1,5 +1,5 @@
1
1
  /*
2
- * Application Insights JavaScript SDK - Debug Plugin, 2.8.0-beta.2203-07
2
+ * Application Insights JavaScript SDK - Debug Plugin, 2.8.0-beta.2203-10
3
3
  * Copyright (c) Microsoft and contributors. All rights reserved.
4
4
  */
5
5
 
@@ -1,5 +1,5 @@
1
1
  /*
2
- * Application Insights JavaScript SDK - Debug Plugin, 2.8.0-beta.2203-07
2
+ * Application Insights JavaScript SDK - Debug Plugin, 2.8.0-beta.2203-10
3
3
  * Copyright (c) Microsoft and contributors. All rights reserved.
4
4
  */
5
5
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@microsoft/applicationinsights-debugplugin-js",
3
- "version": "2.8.0-beta.2203-07",
3
+ "version": "2.8.0-beta.2203-10",
4
4
  "description": "Microsoft Application Insights JavaScript SDK - Debug Plugin extension",
5
5
  "homepage": "https://github.com/microsoft/ApplicationInsights-JS#readme",
6
6
  "author": "Microsoft Application Insights Team",
@@ -46,8 +46,8 @@
46
46
  },
47
47
  "dependencies": {
48
48
  "@microsoft/dynamicproto-js": "^1.1.4",
49
- "@microsoft/applicationinsights-common": "2.8.0-beta.2203-07",
50
- "@microsoft/applicationinsights-core-js": "2.8.0-beta.2203-07",
49
+ "@microsoft/applicationinsights-common": "2.8.0-beta.2203-10",
50
+ "@microsoft/applicationinsights-core-js": "2.8.0-beta.2203-10",
51
51
  "@microsoft/applicationinsights-shims": "2.0.1"
52
52
  },
53
53
  "license": "MIT",
@@ -73,14 +73,15 @@ export class DebugBinParent {
73
73
  if (ch instanceof DebugBin) {
74
74
  if (ch.el.parentElement !== _self.el && _self.showChildren) {
75
75
  _self.el.appendChild(ch.el);
76
- }
77
- else if (ch.el.parentElement === _self.el && !_self.showChildren) {
76
+ } else if (ch.el.parentElement === _self.el && !_self.showChildren) {
78
77
  _self.el.removeChild(ch.el);
79
78
  }
80
- }
81
- else {
82
- if (_self.showChildren) { _self.el.appendChild(ch); }
83
- else { _self.el.removeChild(ch); }
79
+ } else {
80
+ if (_self.showChildren) {
81
+ _self.el.appendChild(ch);
82
+ } else {
83
+ _self.el.removeChild(ch);
84
+ }
84
85
  }
85
86
  }
86
87
  }
@@ -47,8 +47,7 @@ export function traverseAndReplace(target: Object, maxDepth: number, currentDept
47
47
 
48
48
  if (targetValue !== null && arrIndexOf(thingsReferenced, targetValue) !== -1) {
49
49
  out[key] = `<circular (${key} - "${getTargetName(targetValue)}")>`;
50
- }
51
- else if (targetValue !== null && isObject(targetValue)) {
50
+ } else if (targetValue !== null && isObject(targetValue)) {
52
51
  if (currentDepth >= maxDepth) {
53
52
  out[key] = "<max allowed depth reached>";
54
53
  } else {
@@ -56,8 +55,7 @@ export function traverseAndReplace(target: Object, maxDepth: number, currentDept
56
55
  out[key] = traverseAndReplace(targetValue, maxDepth, currentDepth + 1, thingsReferenced, excludedKeys, includeFunctions);
57
56
  thingsReferenced.pop();
58
57
  }
59
- }
60
- else {
58
+ } else {
61
59
  out[key] = targetValue;
62
60
  }
63
61
  }
@@ -129,7 +127,9 @@ export function focusHandler(evt: Event, target: Object, level: number, excludeK
129
127
  }
130
128
  lastSelectedElement = (evt.target as HTMLElement);
131
129
  for (let i = 0; i < 10; i++) {
132
- if (lastSelectedElement.tagName === "DIV") { break; }
130
+ if (lastSelectedElement.tagName === "DIV") {
131
+ break;
132
+ }
133
133
  lastSelectedElement = lastSelectedElement.parentElement;
134
134
  }
135
135
  lastSelectedElement.className += " last-selected-element";
@@ -139,41 +139,49 @@ export function focusHandler(evt: Event, target: Object, level: number, excludeK
139
139
  function _navHandler(evt: KeyboardEvent, openHandler?: (evt: Event, forceState?: boolean) => void, currentState?: boolean) {
140
140
  const el = evt.target as HTMLElement;
141
141
  switch (evt.which) {
142
- // Enter
143
- case 13: (openHandler) ? openHandler(evt) : void 0; break;
142
+ // Enter
143
+ case 13: (openHandler) ? openHandler(evt) : void 0; break;
144
144
  // ArrowUp
145
- case 38:
146
- evt.preventDefault();
147
- const prev = el.previousElementSibling as HTMLElement;
148
- if (prev && prev.tagName !== "BUTTON") { prev.focus(); }
149
- break;
145
+ case 38:
146
+ evt.preventDefault();
147
+ const prev = el.previousElementSibling as HTMLElement;
148
+ if (prev && prev.tagName !== "BUTTON") {
149
+ prev.focus();
150
+ }
151
+ break;
150
152
  // ArrowDown
151
- case 40:
152
- evt.preventDefault();
153
- const next = el.nextElementSibling as HTMLElement;
154
- if (next) { next.focus(); }
155
- break;
153
+ case 40:
154
+ evt.preventDefault();
155
+ const next = el.nextElementSibling as HTMLElement;
156
+ if (next) {
157
+ next.focus();
158
+ }
159
+ break;
156
160
  // ArrowRight
157
- case 39:
158
- if (openHandler) {
159
- openHandler(evt, true);
160
- if (currentState) {
161
- (el.firstElementChild.nextSibling as HTMLElement).focus();
162
- }
161
+ case 39:
162
+ if (openHandler) {
163
+ openHandler(evt, true);
164
+ if (currentState) {
165
+ (el.firstElementChild.nextSibling as HTMLElement).focus();
163
166
  }
164
- break;
167
+ }
168
+ break;
165
169
  // ArrowLeft
166
- case 37:
167
- if (openHandler) { openHandler(evt, false); }
168
- if (!currentState) { (el.parentElement as HTMLElement).focus(); }
169
- break;
170
+ case 37:
171
+ if (openHandler) {
172
+ openHandler(evt, false);
173
+ }
174
+ if (!currentState) {
175
+ (el.parentElement as HTMLElement).focus();
176
+ }
177
+ break;
170
178
  // c
171
- case 67:
172
- if (evt.ctrlKey) {
173
- copySelectedTree();
174
- (evt.target as HTMLElement).focus();
175
- }
176
- break;
179
+ case 67:
180
+ if (evt.ctrlKey) {
181
+ copySelectedTree();
182
+ (evt.target as HTMLElement).focus();
183
+ }
184
+ break;
177
185
  }
178
186
  }
179
187
 
@@ -290,8 +298,12 @@ export function formatLogElements(target: Object, tmLabel: string, key: string,
290
298
  let matched = false;
291
299
  let childOpened = false;
292
300
  const keys = getTargetKeys(target, excludeKeys, includeFunctions);
293
- if (keys.length === 0) { keys.push("<empty>"); }
294
- if (level >= MAX_DEPTH) { keys.unshift("<maxdepth>"); }
301
+ if (keys.length === 0) {
302
+ keys.push("<empty>");
303
+ }
304
+ if (level >= MAX_DEPTH) {
305
+ keys.unshift("<maxdepth>");
306
+ }
295
307
  for (const key of keys) {
296
308
  if (excludeKeys.indexOf(key) !== -1) {
297
309
  continue;
@@ -308,20 +320,17 @@ export function formatLogElements(target: Object, tmLabel: string, key: string,
308
320
  builder.innerText = "<max allowed depth reached>";
309
321
  children.push(builder);
310
322
  break;
311
- }
312
- else if (key === "<empty>") {
323
+ } else if (key === "<empty>") {
313
324
  const builder = document.createElement("div");
314
325
  builder.className = "empty";
315
326
  builder.innerText = "<empty>";
316
327
  children.push(builder);
317
- }
318
- else if (targetValue !== null && arrIndexOf(thingsReferenced, targetValue) !== -1) {
328
+ } else if (targetValue !== null && arrIndexOf(thingsReferenced, targetValue) !== -1) {
319
329
  const builder = document.createElement("div");
320
330
  builder.className = "empty";
321
331
  builder.innerText = `<circular (${key}) - "${getTargetName(targetValue)}">`;
322
332
  children.push(builder);
323
- }
324
- else if (targetValue !== null && (isObject(targetValue) || Util.isError(targetValue))) {
333
+ } else if (targetValue !== null && (isObject(targetValue) || Util.isError(targetValue))) {
325
334
  thingsReferenced.push(target);
326
335
  let formatted = formatLogElements(targetValue, null, key, level + 1, textFilter, excludeKeys, thingsReferenced, includeFunctions);
327
336
  thingsReferenced.pop();
@@ -421,7 +430,9 @@ export function formatLogElements(target: Object, tmLabel: string, key: string,
421
430
  _openNode(currentLine);
422
431
  }
423
432
  if (isObj) {
424
- if (isErr) { rootDiv.className = "exception" }
433
+ if (isErr) {
434
+ rootDiv.className = "exception"
435
+ }
425
436
  const openHandler = (evt: Event, forceState?: boolean) => {
426
437
  evt.stopPropagation();
427
438
  if (Util.getIEVersion()) {
@@ -433,8 +444,7 @@ export function formatLogElements(target: Object, tmLabel: string, key: string,
433
444
  if (lastSelectedElement === rootDiv) {
434
445
  if (openState) {
435
446
  _collapseNode(currentLine);
436
- }
437
- else {
447
+ } else {
438
448
  _openNode(currentLine);
439
449
  }
440
450
  }
@@ -4,15 +4,15 @@
4
4
  import { Util } from "@microsoft/applicationinsights-common";
5
5
 
6
6
  const BG_INFO = "#F0F6FF",
7
- BG_ERROR = "#FEF0F1",
8
- ICON_ERROR = "#E00B1C",
9
- BTN_PRIMARY = "#0078d4",
10
- BTN_HOVER = "#106EBE",
11
- BTN_ACTIVE = "#005A9E",
12
- TEXT_PRIMARY = "#323130",
13
- TEXT_MATCHED = "yellow",
14
- BORDER_GREY_160 = "1px solid #605E5C",
15
- BORDER_GREY_60 = "1px solid #B3B0AD";
7
+ BG_ERROR = "#FEF0F1",
8
+ ICON_ERROR = "#E00B1C",
9
+ BTN_PRIMARY = "#0078d4",
10
+ BTN_HOVER = "#106EBE",
11
+ BTN_ACTIVE = "#005A9E",
12
+ TEXT_PRIMARY = "#323130",
13
+ TEXT_MATCHED = "yellow",
14
+ BORDER_GREY_160 = "1px solid #605E5C",
15
+ BORDER_GREY_60 = "1px solid #B3B0AD";
16
16
 
17
17
  console.log(Util.getIEVersion());
18
18
 
@@ -66,15 +66,15 @@ export const tempStyle = (prefix: string) => `
66
66
  }
67
67
 
68
68
  ${Util.getIEVersion() && Util.getIEVersion() < 9
69
- ? ""
70
- : `.${prefix}-dbg-lgr .tree-root div::before {
69
+ ? ""
70
+ : `.${prefix}-dbg-lgr .tree-root div::before {
71
71
  content: '';
72
72
  position: absolute;
73
73
  left: -1.25em;
74
74
  height: 100%;
75
75
  border-right: 2px dotted #CCCCCC;
76
76
  }`
77
- }
77
+ }
78
78
 
79
79
  .${prefix}-dbg-lgr .tree-root div:hover::before {
80
80
  border-right: 2px solid #000;
@@ -111,8 +111,8 @@ export const tempStyle = (prefix: string) => `
111
111
  }
112
112
 
113
113
  ${Util.getIEVersion() && Util.getIEVersion() < 9
114
- ? ""
115
- : `.${prefix}-dbg-lgr .expandable.open::before {
114
+ ? ""
115
+ : `.${prefix}-dbg-lgr .expandable.open::before {
116
116
  content: '[-] ';
117
117
  font-weight: bold;
118
118
  }
@@ -121,7 +121,7 @@ export const tempStyle = (prefix: string) => `
121
121
  content: '[+] ';
122
122
  font-weight: bold;
123
123
  }`
124
- }
124
+ }
125
125
 
126
126
  .${prefix}-dbg-lgr div:hover > .obj-key {
127
127
  text-decoration: underline;
@@ -218,8 +218,8 @@ export const tempStyle = (prefix: string) => `
218
218
  }
219
219
 
220
220
  ${Util.getIEVersion() && Util.getIEVersion() < 9
221
- ? ""
222
- : `.${prefix}-dbg-lgr-dashboard .filterlist-input::after {
221
+ ? ""
222
+ : `.${prefix}-dbg-lgr-dashboard .filterlist-input::after {
223
223
  content: '';
224
224
  width: 8px;
225
225
  height: 8px;
@@ -232,7 +232,7 @@ export const tempStyle = (prefix: string) => `
232
232
  border-top: none;
233
233
  border-left: none;
234
234
  }`
235
- }
235
+ }
236
236
 
237
237
  .${prefix}-dbg-lgr-dashboard .filterlist-input:focus {
238
238
  border: ${BORDER_GREY_60}
@@ -296,8 +296,8 @@ export const tempStyle = (prefix: string) => `
296
296
  }
297
297
 
298
298
  ${Util.getIEVersion() && Util.getIEVersion() < 9
299
- ? ""
300
- : `.${prefix}-dbg-lgr-dashboard .checkbox.on::after {
299
+ ? ""
300
+ : `.${prefix}-dbg-lgr-dashboard .checkbox.on::after {
301
301
  content: '';
302
302
  width: 5px;
303
303
  height: 10px;
@@ -309,7 +309,7 @@ export const tempStyle = (prefix: string) => `
309
309
  border-top: none;
310
310
  border-left: none;
311
311
  }`
312
- }
312
+ }
313
313
 
314
314
 
315
315
  .${prefix}-dbg-lgr-dashboard .checkbox.off {
@@ -317,14 +317,14 @@ export const tempStyle = (prefix: string) => `
317
317
  }
318
318
 
319
319
  ${Util.getIEVersion() && Util.getIEVersion() < 9
320
- ? ""
321
- : `@media only screen and (max-width: 600px) {
320
+ ? ""
321
+ : `@media only screen and (max-width: 600px) {
322
322
  .${prefix}-dbg-lgr {
323
323
  width: 100%;
324
324
  min-width: 200px;
325
325
  }
326
326
  }`
327
- }
327
+ }
328
328
 
329
329
  `;
330
330
 
@@ -332,13 +332,13 @@ export const permStyle = (prefix: string) => `
332
332
  .${prefix}-debug-bin-container {
333
333
  position: fixed;
334
334
  ${Util.getIEVersion() && Util.getIEVersion() < 9
335
- ? `width: 100%;
335
+ ? `width: 100%;
336
336
  height: 100%;
337
337
  top: 0;
338
338
  left: 0;`
339
- : `width: 100vw;
339
+ : `width: 100vw;
340
340
  height: 100vh;`
341
- }
341
+ }
342
342
  pointer-events: none;
343
343
  }
344
344
 
@@ -411,11 +411,11 @@ export const permStyle = (prefix: string) => `
411
411
  }
412
412
 
413
413
  ${Util.getIEVersion() && Util.getIEVersion() < 9
414
- ? ""
415
- : `.${prefix}-debug-bin-parent.notify::after {
414
+ ? ""
415
+ : `.${prefix}-debug-bin-parent.notify::after {
416
416
  content: " (!)";
417
417
  }`
418
- }
418
+ }
419
419
 
420
420
  .${prefix}-debug-bin-parent .el-value.incremented {
421
421
  transform: scale(1.5);
@@ -424,11 +424,11 @@ export const permStyle = (prefix: string) => `
424
424
  }
425
425
 
426
426
  ${Util.getIEVersion() && Util.getIEVersion() < 9
427
- ? ""
428
- : `.${prefix}-debug-bin-parent:focus > span::before,
427
+ ? ""
428
+ : `.${prefix}-debug-bin-parent:focus > span::before,
429
429
  .${prefix}-debug-bin-parent:hover > span::before,
430
430
  .${prefix}-debug-bin-parent.active > span::before {
431
431
  content: attr(data-name) ": ";
432
432
  }`
433
- }
433
+ }
434
434
  `