inspect-ai 0.3.48__py3-none-any.whl → 0.3.50__py3-none-any.whl

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 (97) hide show
  1. inspect_ai/_cli/info.py +2 -2
  2. inspect_ai/_cli/log.py +2 -2
  3. inspect_ai/_cli/score.py +2 -2
  4. inspect_ai/_display/core/display.py +19 -0
  5. inspect_ai/_display/core/panel.py +37 -7
  6. inspect_ai/_display/core/progress.py +29 -2
  7. inspect_ai/_display/core/results.py +79 -40
  8. inspect_ai/_display/core/textual.py +21 -0
  9. inspect_ai/_display/rich/display.py +28 -8
  10. inspect_ai/_display/textual/app.py +112 -3
  11. inspect_ai/_display/textual/display.py +1 -1
  12. inspect_ai/_display/textual/widgets/samples.py +132 -91
  13. inspect_ai/_display/textual/widgets/task_detail.py +232 -0
  14. inspect_ai/_display/textual/widgets/tasks.py +74 -6
  15. inspect_ai/_display/textual/widgets/toggle.py +32 -0
  16. inspect_ai/_eval/context.py +2 -0
  17. inspect_ai/_eval/eval.py +4 -3
  18. inspect_ai/_eval/loader.py +1 -1
  19. inspect_ai/_eval/run.py +35 -2
  20. inspect_ai/_eval/task/log.py +13 -11
  21. inspect_ai/_eval/task/results.py +12 -3
  22. inspect_ai/_eval/task/run.py +139 -36
  23. inspect_ai/_eval/task/sandbox.py +2 -1
  24. inspect_ai/_util/_async.py +30 -1
  25. inspect_ai/_util/file.py +47 -5
  26. inspect_ai/_util/html.py +3 -0
  27. inspect_ai/_util/logger.py +6 -5
  28. inspect_ai/_util/platform.py +5 -6
  29. inspect_ai/_util/registry.py +1 -1
  30. inspect_ai/_view/server.py +9 -9
  31. inspect_ai/_view/www/App.css +2 -2
  32. inspect_ai/_view/www/dist/assets/index.css +2 -2
  33. inspect_ai/_view/www/dist/assets/index.js +395 -307
  34. inspect_ai/_view/www/log-schema.json +13 -0
  35. inspect_ai/_view/www/package.json +1 -0
  36. inspect_ai/_view/www/src/components/MessageBand.mjs +1 -1
  37. inspect_ai/_view/www/src/components/Tools.mjs +27 -16
  38. inspect_ai/_view/www/src/samples/SampleDisplay.mjs +1 -3
  39. inspect_ai/_view/www/src/samples/SampleScoreView.mjs +52 -77
  40. inspect_ai/_view/www/src/samples/SamplesDescriptor.mjs +38 -13
  41. inspect_ai/_view/www/src/samples/tools/SortFilter.mjs +40 -18
  42. inspect_ai/_view/www/src/samples/transcript/ModelEventView.mjs +15 -2
  43. inspect_ai/_view/www/src/samples/transcript/state/StateEventRenderers.mjs +4 -2
  44. inspect_ai/_view/www/src/types/log.d.ts +2 -0
  45. inspect_ai/_view/www/src/utils/debugging.mjs +23 -0
  46. inspect_ai/_view/www/src/workspace/WorkSpace.mjs +2 -0
  47. inspect_ai/_view/www/yarn.lock +9 -4
  48. inspect_ai/approval/__init__.py +1 -1
  49. inspect_ai/approval/_human/approver.py +35 -0
  50. inspect_ai/approval/_human/console.py +62 -0
  51. inspect_ai/approval/_human/manager.py +108 -0
  52. inspect_ai/approval/_human/panel.py +233 -0
  53. inspect_ai/approval/_human/util.py +51 -0
  54. inspect_ai/dataset/_sources/hf.py +2 -2
  55. inspect_ai/dataset/_sources/util.py +1 -1
  56. inspect_ai/log/_file.py +106 -36
  57. inspect_ai/log/_recorders/eval.py +226 -158
  58. inspect_ai/log/_recorders/file.py +9 -6
  59. inspect_ai/log/_recorders/json.py +35 -12
  60. inspect_ai/log/_recorders/recorder.py +15 -15
  61. inspect_ai/log/_samples.py +52 -0
  62. inspect_ai/model/_model.py +14 -0
  63. inspect_ai/model/_model_output.py +4 -0
  64. inspect_ai/model/_providers/azureai.py +1 -1
  65. inspect_ai/model/_providers/hf.py +106 -4
  66. inspect_ai/model/_providers/util/__init__.py +2 -0
  67. inspect_ai/model/_providers/util/hf_handler.py +200 -0
  68. inspect_ai/scorer/_common.py +1 -1
  69. inspect_ai/solver/_plan.py +0 -8
  70. inspect_ai/solver/_task_state.py +18 -1
  71. inspect_ai/solver/_use_tools.py +9 -1
  72. inspect_ai/tool/_tool_call.py +1 -1
  73. inspect_ai/tool/_tool_def.py +2 -2
  74. inspect_ai/tool/_tool_info.py +14 -2
  75. inspect_ai/tool/_tool_params.py +2 -1
  76. inspect_ai/tool/_tools/_execute.py +1 -1
  77. inspect_ai/tool/_tools/_web_browser/_web_browser.py +6 -0
  78. inspect_ai/util/__init__.py +5 -6
  79. inspect_ai/util/_panel.py +91 -0
  80. inspect_ai/util/_sandbox/__init__.py +2 -6
  81. inspect_ai/util/_sandbox/context.py +4 -3
  82. inspect_ai/util/_sandbox/docker/compose.py +12 -2
  83. inspect_ai/util/_sandbox/docker/docker.py +19 -9
  84. inspect_ai/util/_sandbox/docker/util.py +10 -2
  85. inspect_ai/util/_sandbox/environment.py +47 -41
  86. inspect_ai/util/_sandbox/local.py +15 -10
  87. inspect_ai/util/_sandbox/self_check.py +6 -3
  88. inspect_ai/util/_subprocess.py +43 -3
  89. {inspect_ai-0.3.48.dist-info → inspect_ai-0.3.50.dist-info}/METADATA +2 -2
  90. {inspect_ai-0.3.48.dist-info → inspect_ai-0.3.50.dist-info}/RECORD +94 -85
  91. inspect_ai/_view/www/node_modules/flatted/python/flatted.py +0 -149
  92. inspect_ai/_view/www/node_modules/flatted/python/test.py +0 -63
  93. inspect_ai/approval/_human.py +0 -123
  94. {inspect_ai-0.3.48.dist-info → inspect_ai-0.3.50.dist-info}/LICENSE +0 -0
  95. {inspect_ai-0.3.48.dist-info → inspect_ai-0.3.50.dist-info}/WHEEL +0 -0
  96. {inspect_ai-0.3.48.dist-info → inspect_ai-0.3.50.dist-info}/entry_points.txt +0 -0
  97. {inspect_ai-0.3.48.dist-info → inspect_ai-0.3.50.dist-info}/top_level.txt +0 -0
@@ -38,104 +38,105 @@ var __publicField = (obj, key2, value) => __defNormalProp(obj, typeof key2 !== "
38
38
  fetch(link2.href, fetchOpts);
39
39
  }
40
40
  })();
41
- var n$2, l$1, u$1, i$2, o$1, r$2, f$1, e$3, c$2, s$1, h$1 = {}, v$1 = [], p$1 = /acit|ex(?:s|g|n|p|$)|rph|grid|ows|mnc|ntw|ine[ch]|zoo|^ord|itera/i, y$1 = Array.isArray;
42
- function d$1(n2, l2) {
41
+ var n$2, l$1, u$1, i$2, r$2, o$1, e$3, f$1, c$2, s$1, a$1, p$1 = {}, v$1 = [], y$1 = /acit|ex(?:s|g|n|p|$)|rph|grid|ows|mnc|ntw|ine[ch]|zoo|^ord|itera/i, d$1 = Array.isArray;
42
+ function w$1(n2, l2) {
43
43
  for (var u2 in l2) n2[u2] = l2[u2];
44
44
  return n2;
45
45
  }
46
- function w$1(n2) {
46
+ function _(n2) {
47
47
  n2 && n2.parentNode && n2.parentNode.removeChild(n2);
48
48
  }
49
- function _(l2, u2, t2) {
50
- var i, o2, r2, f2 = {};
51
- for (r2 in u2) "key" == r2 ? i = u2[r2] : "ref" == r2 ? o2 = u2[r2] : f2[r2] = u2[r2];
52
- if (arguments.length > 2 && (f2.children = arguments.length > 3 ? n$2.call(arguments, 2) : t2), "function" == typeof l2 && null != l2.defaultProps) for (r2 in l2.defaultProps) void 0 === f2[r2] && (f2[r2] = l2.defaultProps[r2]);
53
- return g(l2, f2, i, o2, null);
49
+ function g(l2, u2, t2) {
50
+ var i, r2, o2, e2 = {};
51
+ for (o2 in u2) "key" == o2 ? i = u2[o2] : "ref" == o2 ? r2 = u2[o2] : e2[o2] = u2[o2];
52
+ if (arguments.length > 2 && (e2.children = arguments.length > 3 ? n$2.call(arguments, 2) : t2), "function" == typeof l2 && null != l2.defaultProps) for (o2 in l2.defaultProps) void 0 === e2[o2] && (e2[o2] = l2.defaultProps[o2]);
53
+ return m$2(l2, e2, i, r2, null);
54
54
  }
55
- function g(n2, t2, i, o2, r2) {
56
- var f2 = { type: n2, props: t2, key: i, ref: o2, __k: null, __: null, __b: 0, __e: null, __d: void 0, __c: null, constructor: void 0, __v: null == r2 ? ++u$1 : r2, __i: -1, __u: 0 };
57
- return null == r2 && null != l$1.vnode && l$1.vnode(f2), f2;
55
+ function m$2(n2, t2, i, r2, o2) {
56
+ var e2 = { type: n2, props: t2, key: i, ref: r2, __k: null, __: null, __b: 0, __e: null, __c: null, constructor: void 0, __v: null == o2 ? ++u$1 : o2, __i: -1, __u: 0 };
57
+ return null == o2 && null != l$1.vnode && l$1.vnode(e2), e2;
58
58
  }
59
- function m$2() {
59
+ function b() {
60
60
  return { current: null };
61
61
  }
62
- function b(n2) {
62
+ function k$1(n2) {
63
63
  return n2.children;
64
64
  }
65
- function k$1(n2, l2) {
65
+ function x$1(n2, l2) {
66
66
  this.props = n2, this.context = l2;
67
67
  }
68
- function x$1(n2, l2) {
69
- if (null == l2) return n2.__ ? x$1(n2.__, n2.__i + 1) : null;
68
+ function C$1(n2, l2) {
69
+ if (null == l2) return n2.__ ? C$1(n2.__, n2.__i + 1) : null;
70
70
  for (var u2; l2 < n2.__k.length; l2++) if (null != (u2 = n2.__k[l2]) && null != u2.__e) return u2.__e;
71
- return "function" == typeof n2.type ? x$1(n2) : null;
71
+ return "function" == typeof n2.type ? C$1(n2) : null;
72
72
  }
73
- function C$1(n2) {
73
+ function S(n2) {
74
74
  var l2, u2;
75
75
  if (null != (n2 = n2.__) && null != n2.__c) {
76
76
  for (n2.__e = n2.__c.base = null, l2 = 0; l2 < n2.__k.length; l2++) if (null != (u2 = n2.__k[l2]) && null != u2.__e) {
77
77
  n2.__e = n2.__c.base = u2.__e;
78
78
  break;
79
79
  }
80
- return C$1(n2);
80
+ return S(n2);
81
81
  }
82
82
  }
83
- function S(n2) {
84
- (!n2.__d && (n2.__d = true) && i$2.push(n2) && !M.__r++ || o$1 !== l$1.debounceRendering) && ((o$1 = l$1.debounceRendering) || r$2)(M);
83
+ function M(n2) {
84
+ (!n2.__d && (n2.__d = true) && i$2.push(n2) && !P$1.__r++ || r$2 !== l$1.debounceRendering) && ((r$2 = l$1.debounceRendering) || o$1)(P$1);
85
85
  }
86
- function M() {
87
- var n2, u2, t2, o2, r2, e2, c2, s2;
88
- for (i$2.sort(f$1); n2 = i$2.shift(); ) n2.__d && (u2 = i$2.length, o2 = void 0, e2 = (r2 = (t2 = n2).__v).__e, c2 = [], s2 = [], t2.__P && ((o2 = d$1({}, r2)).__v = r2.__v + 1, l$1.vnode && l$1.vnode(o2), O(t2.__P, o2, r2, t2.__n, t2.__P.namespaceURI, 32 & r2.__u ? [e2] : null, c2, null == e2 ? x$1(r2) : e2, !!(32 & r2.__u), s2), o2.__v = r2.__v, o2.__.__k[o2.__i] = o2, j$1(c2, o2, s2), o2.__e != e2 && C$1(o2)), i$2.length > u2 && i$2.sort(f$1));
89
- M.__r = 0;
86
+ function P$1() {
87
+ var n2, u2, t2, r2, o2, f2, c2, s2;
88
+ for (i$2.sort(e$3); n2 = i$2.shift(); ) n2.__d && (u2 = i$2.length, r2 = void 0, f2 = (o2 = (t2 = n2).__v).__e, c2 = [], s2 = [], t2.__P && ((r2 = w$1({}, o2)).__v = o2.__v + 1, l$1.vnode && l$1.vnode(r2), j$1(t2.__P, r2, o2, t2.__n, t2.__P.namespaceURI, 32 & o2.__u ? [f2] : null, c2, null == f2 ? C$1(o2) : f2, !!(32 & o2.__u), s2), r2.__v = o2.__v, r2.__.__k[r2.__i] = r2, z$1(c2, r2, s2), r2.__e != f2 && S(r2)), i$2.length > u2 && i$2.sort(e$3));
89
+ P$1.__r = 0;
90
90
  }
91
- function P$1(n2, l2, u2, t2, i, o2, r2, f2, e2, c2, s2) {
92
- var a2, p2, y2, d2, w2, _2 = t2 && t2.__k || v$1, g2 = l2.length;
93
- for (u2.__d = e2, $(u2, l2, _2), e2 = u2.__d, a2 = 0; a2 < g2; a2++) null != (y2 = u2.__k[a2]) && (p2 = -1 === y2.__i ? h$1 : _2[y2.__i] || h$1, y2.__i = a2, O(n2, y2, p2, i, o2, r2, f2, e2, c2, s2), d2 = y2.__e, y2.ref && p2.ref != y2.ref && (p2.ref && E(p2.ref, null, y2), s2.push(y2.ref, y2.__c || d2, y2)), null == w2 && null != d2 && (w2 = d2), 65536 & y2.__u || p2.__k === y2.__k ? e2 = I(y2, e2, n2) : "function" == typeof y2.type && void 0 !== y2.__d ? e2 = y2.__d : d2 && (e2 = d2.nextSibling), y2.__d = void 0, y2.__u &= -196609);
94
- u2.__d = e2, u2.__e = w2;
91
+ function $(n2, l2, u2, t2, i, r2, o2, e2, f2, c2, s2) {
92
+ var a2, h2, y2, d2, w2, _2, g2 = t2 && t2.__k || v$1, m2 = l2.length;
93
+ for (f2 = I(u2, l2, g2, f2), a2 = 0; a2 < m2; a2++) null != (y2 = u2.__k[a2]) && (h2 = -1 === y2.__i ? p$1 : g2[y2.__i] || p$1, y2.__i = a2, _2 = j$1(n2, y2, h2, i, r2, o2, e2, f2, c2, s2), d2 = y2.__e, y2.ref && h2.ref != y2.ref && (h2.ref && V(h2.ref, null, y2), s2.push(y2.ref, y2.__c || d2, y2)), null == w2 && null != d2 && (w2 = d2), 4 & y2.__u || h2.__k === y2.__k ? f2 = H(y2, f2, n2) : "function" == typeof y2.type && void 0 !== _2 ? f2 = _2 : d2 && (f2 = d2.nextSibling), y2.__u &= -7);
94
+ return u2.__e = w2, f2;
95
95
  }
96
- function $(n2, l2, u2) {
97
- var t2, i, o2, r2, f2, e2 = l2.length, c2 = u2.length, s2 = c2, a2 = 0;
98
- for (n2.__k = [], t2 = 0; t2 < e2; t2++) null != (i = l2[t2]) && "boolean" != typeof i && "function" != typeof i ? (r2 = t2 + a2, (i = n2.__k[t2] = "string" == typeof i || "number" == typeof i || "bigint" == typeof i || i.constructor == String ? g(null, i, null, null, null) : y$1(i) ? g(b, { children: i }, null, null, null) : void 0 === i.constructor && i.__b > 0 ? g(i.type, i.props, i.key, i.ref ? i.ref : null, i.__v) : i).__ = n2, i.__b = n2.__b + 1, o2 = null, -1 !== (f2 = i.__i = L(i, u2, r2, s2)) && (s2--, (o2 = u2[f2]) && (o2.__u |= 131072)), null == o2 || null === o2.__v ? (-1 == f2 && a2--, "function" != typeof i.type && (i.__u |= 65536)) : f2 !== r2 && (f2 == r2 - 1 ? a2-- : f2 == r2 + 1 ? a2++ : (f2 > r2 ? a2-- : a2++, i.__u |= 65536))) : i = n2.__k[t2] = null;
99
- if (s2) for (t2 = 0; t2 < c2; t2++) null != (o2 = u2[t2]) && 0 == (131072 & o2.__u) && (o2.__e == n2.__d && (n2.__d = x$1(o2)), N(o2, o2));
96
+ function I(n2, l2, u2, t2) {
97
+ var i, r2, o2, e2, f2, c2 = l2.length, s2 = u2.length, a2 = s2, h2 = 0;
98
+ for (n2.__k = [], i = 0; i < c2; i++) null != (r2 = l2[i]) && "boolean" != typeof r2 && "function" != typeof r2 ? (e2 = i + h2, (r2 = n2.__k[i] = "string" == typeof r2 || "number" == typeof r2 || "bigint" == typeof r2 || r2.constructor == String ? m$2(null, r2, null, null, null) : d$1(r2) ? m$2(k$1, { children: r2 }, null, null, null) : void 0 === r2.constructor && r2.__b > 0 ? m$2(r2.type, r2.props, r2.key, r2.ref ? r2.ref : null, r2.__v) : r2).__ = n2, r2.__b = n2.__b + 1, o2 = null, -1 !== (f2 = r2.__i = T$1(r2, u2, e2, a2)) && (a2--, (o2 = u2[f2]) && (o2.__u |= 2)), null == o2 || null === o2.__v ? (-1 == f2 && h2--, "function" != typeof r2.type && (r2.__u |= 4)) : f2 !== e2 && (f2 == e2 - 1 ? h2-- : f2 == e2 + 1 ? h2++ : (f2 > e2 ? h2-- : h2++, r2.__u |= 4))) : r2 = n2.__k[i] = null;
99
+ if (a2) for (i = 0; i < s2; i++) null != (o2 = u2[i]) && 0 == (2 & o2.__u) && (o2.__e == t2 && (t2 = C$1(o2)), q$1(o2, o2));
100
+ return t2;
100
101
  }
101
- function I(n2, l2, u2) {
102
+ function H(n2, l2, u2) {
102
103
  var t2, i;
103
104
  if ("function" == typeof n2.type) {
104
- for (t2 = n2.__k, i = 0; t2 && i < t2.length; i++) t2[i] && (t2[i].__ = n2, l2 = I(t2[i], l2, u2));
105
+ for (t2 = n2.__k, i = 0; t2 && i < t2.length; i++) t2[i] && (t2[i].__ = n2, l2 = H(t2[i], l2, u2));
105
106
  return l2;
106
107
  }
107
- n2.__e != l2 && (l2 && n2.type && !u2.contains(l2) && (l2 = x$1(n2)), u2.insertBefore(n2.__e, l2 || null), l2 = n2.__e);
108
+ n2.__e != l2 && (l2 && n2.type && !u2.contains(l2) && (l2 = C$1(n2)), u2.insertBefore(n2.__e, l2 || null), l2 = n2.__e);
108
109
  do {
109
110
  l2 = l2 && l2.nextSibling;
110
111
  } while (null != l2 && 8 === l2.nodeType);
111
112
  return l2;
112
113
  }
113
- function L(n2, l2, u2, t2) {
114
- var i = n2.key, o2 = n2.type, r2 = u2 - 1, f2 = u2 + 1, e2 = l2[u2];
115
- if (null === e2 || e2 && i == e2.key && o2 === e2.type && 0 == (131072 & e2.__u)) return u2;
116
- if (("function" != typeof o2 || o2 === b || i) && t2 > (null != e2 && 0 == (131072 & e2.__u) ? 1 : 0)) for (; r2 >= 0 || f2 < l2.length; ) {
117
- if (r2 >= 0) {
118
- if ((e2 = l2[r2]) && 0 == (131072 & e2.__u) && i == e2.key && o2 === e2.type) return r2;
119
- r2--;
114
+ function T$1(n2, l2, u2, t2) {
115
+ var i = n2.key, r2 = n2.type, o2 = u2 - 1, e2 = u2 + 1, f2 = l2[u2];
116
+ if (null === f2 || f2 && i == f2.key && r2 === f2.type && 0 == (2 & f2.__u)) return u2;
117
+ if (("function" != typeof r2 || r2 === k$1 || i) && t2 > (null != f2 && 0 == (2 & f2.__u) ? 1 : 0)) for (; o2 >= 0 || e2 < l2.length; ) {
118
+ if (o2 >= 0) {
119
+ if ((f2 = l2[o2]) && 0 == (2 & f2.__u) && i == f2.key && r2 === f2.type) return o2;
120
+ o2--;
120
121
  }
121
- if (f2 < l2.length) {
122
- if ((e2 = l2[f2]) && 0 == (131072 & e2.__u) && i == e2.key && o2 === e2.type) return f2;
123
- f2++;
122
+ if (e2 < l2.length) {
123
+ if ((f2 = l2[e2]) && 0 == (2 & f2.__u) && i == f2.key && r2 === f2.type) return e2;
124
+ e2++;
124
125
  }
125
126
  }
126
127
  return -1;
127
128
  }
128
- function T$1(n2, l2, u2) {
129
- "-" === l2[0] ? n2.setProperty(l2, null == u2 ? "" : u2) : n2[l2] = null == u2 ? "" : "number" != typeof u2 || p$1.test(l2) ? u2 : u2 + "px";
129
+ function A$1(n2, l2, u2) {
130
+ "-" === l2[0] ? n2.setProperty(l2, null == u2 ? "" : u2) : n2[l2] = null == u2 ? "" : "number" != typeof u2 || y$1.test(l2) ? u2 : u2 + "px";
130
131
  }
131
- function A$1(n2, l2, u2, t2, i) {
132
- var o2;
132
+ function F(n2, l2, u2, t2, i) {
133
+ var r2;
133
134
  n: if ("style" === l2) if ("string" == typeof u2) n2.style.cssText = u2;
134
135
  else {
135
- if ("string" == typeof t2 && (n2.style.cssText = t2 = ""), t2) for (l2 in t2) u2 && l2 in u2 || T$1(n2.style, l2, "");
136
- if (u2) for (l2 in u2) t2 && u2[l2] === t2[l2] || T$1(n2.style, l2, u2[l2]);
136
+ if ("string" == typeof t2 && (n2.style.cssText = t2 = ""), t2) for (l2 in t2) u2 && l2 in u2 || A$1(n2.style, l2, "");
137
+ if (u2) for (l2 in u2) t2 && u2[l2] === t2[l2] || A$1(n2.style, l2, u2[l2]);
137
138
  }
138
- else if ("o" === l2[0] && "n" === l2[1]) o2 = l2 !== (l2 = l2.replace(/(PointerCapture)$|Capture$/i, "$1")), l2 = l2.toLowerCase() in n2 || "onFocusOut" === l2 || "onFocusIn" === l2 ? l2.toLowerCase().slice(2) : l2.slice(2), n2.l || (n2.l = {}), n2.l[l2 + o2] = u2, u2 ? t2 ? u2.u = t2.u : (u2.u = e$3, n2.addEventListener(l2, o2 ? s$1 : c$2, o2)) : n2.removeEventListener(l2, o2 ? s$1 : c$2, o2);
139
+ else if ("o" === l2[0] && "n" === l2[1]) r2 = l2 !== (l2 = l2.replace(f$1, "$1")), l2 = l2.toLowerCase() in n2 || "onFocusOut" === l2 || "onFocusIn" === l2 ? l2.toLowerCase().slice(2) : l2.slice(2), n2.l || (n2.l = {}), n2.l[l2 + r2] = u2, u2 ? t2 ? u2.u = t2.u : (u2.u = c$2, n2.addEventListener(l2, r2 ? a$1 : s$1, r2)) : n2.removeEventListener(l2, r2 ? a$1 : s$1, r2);
139
140
  else {
140
141
  if ("http://www.w3.org/2000/svg" == i) l2 = l2.replace(/xlink(H|:h)/, "h").replace(/sName$/, "s");
141
142
  else if ("width" != l2 && "height" != l2 && "href" != l2 && "list" != l2 && "form" != l2 && "tabIndex" != l2 && "download" != l2 && "rowSpan" != l2 && "colSpan" != l2 && "role" != l2 && "popover" != l2 && l2 in n2) try {
@@ -146,54 +147,54 @@ function A$1(n2, l2, u2, t2, i) {
146
147
  "function" == typeof u2 || (null == u2 || false === u2 && "-" !== l2[4] ? n2.removeAttribute(l2) : n2.setAttribute(l2, "popover" == l2 && 1 == u2 ? "" : u2));
147
148
  }
148
149
  }
149
- function F(n2) {
150
+ function O(n2) {
150
151
  return function(u2) {
151
152
  if (this.l) {
152
153
  var t2 = this.l[u2.type + n2];
153
- if (null == u2.t) u2.t = e$3++;
154
+ if (null == u2.t) u2.t = c$2++;
154
155
  else if (u2.t < t2.u) return;
155
- return l$1.event && (u2 = l$1.event(u2)), "handleEvent" in t2 ? t2.handleEvent(u2) : t2(u2);
156
+ return t2(l$1.event ? l$1.event(u2) : u2);
156
157
  }
157
158
  };
158
159
  }
159
- function O(n2, u2, t2, i, o2, r2, f2, e2, c2, s2) {
160
- var a2, h2, v2, p2, w2, _2, g2, m2, x, C2, S2, M2, $2, I2, H, L2, T2 = u2.type;
160
+ function j$1(n2, u2, t2, i, r2, o2, e2, f2, c2, s2) {
161
+ var a2, h2, p2, v2, y2, g2, m2, b2, C2, S2, M2, P2, I2, H2, L, T2, A2, F2 = u2.type;
161
162
  if (void 0 !== u2.constructor) return null;
162
- 128 & t2.__u && (c2 = !!(32 & t2.__u), r2 = [e2 = u2.__e = t2.__e]), (a2 = l$1.__b) && a2(u2);
163
- n: if ("function" == typeof T2) try {
164
- if (m2 = u2.props, x = "prototype" in T2 && T2.prototype.render, C2 = (a2 = T2.contextType) && i[a2.__c], S2 = a2 ? C2 ? C2.props.value : a2.__ : i, t2.__c ? g2 = (h2 = u2.__c = t2.__c).__ = h2.__E : (x ? u2.__c = h2 = new T2(m2, S2) : (u2.__c = h2 = new k$1(m2, S2), h2.constructor = T2, h2.render = V), C2 && C2.sub(h2), h2.props = m2, h2.state || (h2.state = {}), h2.context = S2, h2.__n = i, v2 = h2.__d = true, h2.__h = [], h2._sb = []), x && null == h2.__s && (h2.__s = h2.state), x && null != T2.getDerivedStateFromProps && (h2.__s == h2.state && (h2.__s = d$1({}, h2.__s)), d$1(h2.__s, T2.getDerivedStateFromProps(m2, h2.__s))), p2 = h2.props, w2 = h2.state, h2.__v = u2, v2) x && null == T2.getDerivedStateFromProps && null != h2.componentWillMount && h2.componentWillMount(), x && null != h2.componentDidMount && h2.__h.push(h2.componentDidMount);
163
+ 128 & t2.__u && (c2 = !!(32 & t2.__u), o2 = [f2 = u2.__e = t2.__e]), (a2 = l$1.__b) && a2(u2);
164
+ n: if ("function" == typeof F2) try {
165
+ if (b2 = u2.props, C2 = "prototype" in F2 && F2.prototype.render, S2 = (a2 = F2.contextType) && i[a2.__c], M2 = a2 ? S2 ? S2.props.value : a2.__ : i, t2.__c ? m2 = (h2 = u2.__c = t2.__c).__ = h2.__E : (C2 ? u2.__c = h2 = new F2(b2, M2) : (u2.__c = h2 = new x$1(b2, M2), h2.constructor = F2, h2.render = B$1), S2 && S2.sub(h2), h2.props = b2, h2.state || (h2.state = {}), h2.context = M2, h2.__n = i, p2 = h2.__d = true, h2.__h = [], h2._sb = []), C2 && null == h2.__s && (h2.__s = h2.state), C2 && null != F2.getDerivedStateFromProps && (h2.__s == h2.state && (h2.__s = w$1({}, h2.__s)), w$1(h2.__s, F2.getDerivedStateFromProps(b2, h2.__s))), v2 = h2.props, y2 = h2.state, h2.__v = u2, p2) C2 && null == F2.getDerivedStateFromProps && null != h2.componentWillMount && h2.componentWillMount(), C2 && null != h2.componentDidMount && h2.__h.push(h2.componentDidMount);
165
166
  else {
166
- if (x && null == T2.getDerivedStateFromProps && m2 !== p2 && null != h2.componentWillReceiveProps && h2.componentWillReceiveProps(m2, S2), !h2.__e && (null != h2.shouldComponentUpdate && false === h2.shouldComponentUpdate(m2, h2.__s, S2) || u2.__v === t2.__v)) {
167
- for (u2.__v !== t2.__v && (h2.props = m2, h2.state = h2.__s, h2.__d = false), u2.__e = t2.__e, u2.__k = t2.__k, u2.__k.some(function(n3) {
167
+ if (C2 && null == F2.getDerivedStateFromProps && b2 !== v2 && null != h2.componentWillReceiveProps && h2.componentWillReceiveProps(b2, M2), !h2.__e && (null != h2.shouldComponentUpdate && false === h2.shouldComponentUpdate(b2, h2.__s, M2) || u2.__v === t2.__v)) {
168
+ for (u2.__v !== t2.__v && (h2.props = b2, h2.state = h2.__s, h2.__d = false), u2.__e = t2.__e, u2.__k = t2.__k, u2.__k.some(function(n3) {
168
169
  n3 && (n3.__ = u2);
169
- }), M2 = 0; M2 < h2._sb.length; M2++) h2.__h.push(h2._sb[M2]);
170
- h2._sb = [], h2.__h.length && f2.push(h2);
170
+ }), P2 = 0; P2 < h2._sb.length; P2++) h2.__h.push(h2._sb[P2]);
171
+ h2._sb = [], h2.__h.length && e2.push(h2);
171
172
  break n;
172
173
  }
173
- null != h2.componentWillUpdate && h2.componentWillUpdate(m2, h2.__s, S2), x && null != h2.componentDidUpdate && h2.__h.push(function() {
174
- h2.componentDidUpdate(p2, w2, _2);
174
+ null != h2.componentWillUpdate && h2.componentWillUpdate(b2, h2.__s, M2), C2 && null != h2.componentDidUpdate && h2.__h.push(function() {
175
+ h2.componentDidUpdate(v2, y2, g2);
175
176
  });
176
177
  }
177
- if (h2.context = S2, h2.props = m2, h2.__P = n2, h2.__e = false, $2 = l$1.__r, I2 = 0, x) {
178
- for (h2.state = h2.__s, h2.__d = false, $2 && $2(u2), a2 = h2.render(h2.props, h2.state, h2.context), H = 0; H < h2._sb.length; H++) h2.__h.push(h2._sb[H]);
178
+ if (h2.context = M2, h2.props = b2, h2.__P = n2, h2.__e = false, I2 = l$1.__r, H2 = 0, C2) {
179
+ for (h2.state = h2.__s, h2.__d = false, I2 && I2(u2), a2 = h2.render(h2.props, h2.state, h2.context), L = 0; L < h2._sb.length; L++) h2.__h.push(h2._sb[L]);
179
180
  h2._sb = [];
180
181
  } else do {
181
- h2.__d = false, $2 && $2(u2), a2 = h2.render(h2.props, h2.state, h2.context), h2.state = h2.__s;
182
- } while (h2.__d && ++I2 < 25);
183
- h2.state = h2.__s, null != h2.getChildContext && (i = d$1(d$1({}, i), h2.getChildContext())), x && !v2 && null != h2.getSnapshotBeforeUpdate && (_2 = h2.getSnapshotBeforeUpdate(p2, w2)), P$1(n2, y$1(L2 = null != a2 && a2.type === b && null == a2.key ? a2.props.children : a2) ? L2 : [L2], u2, t2, i, o2, r2, f2, e2, c2, s2), h2.base = u2.__e, u2.__u &= -161, h2.__h.length && f2.push(h2), g2 && (h2.__E = h2.__ = null);
182
+ h2.__d = false, I2 && I2(u2), a2 = h2.render(h2.props, h2.state, h2.context), h2.state = h2.__s;
183
+ } while (h2.__d && ++H2 < 25);
184
+ h2.state = h2.__s, null != h2.getChildContext && (i = w$1(w$1({}, i), h2.getChildContext())), C2 && !p2 && null != h2.getSnapshotBeforeUpdate && (g2 = h2.getSnapshotBeforeUpdate(v2, y2)), f2 = $(n2, d$1(T2 = null != a2 && a2.type === k$1 && null == a2.key ? a2.props.children : a2) ? T2 : [T2], u2, t2, i, r2, o2, e2, f2, c2, s2), h2.base = u2.__e, u2.__u &= -161, h2.__h.length && e2.push(h2), m2 && (h2.__E = h2.__ = null);
184
185
  } catch (n3) {
185
- if (u2.__v = null, c2 || null != r2) {
186
- for (u2.__u |= c2 ? 160 : 128; e2 && 8 === e2.nodeType && e2.nextSibling; ) e2 = e2.nextSibling;
187
- r2[r2.indexOf(e2)] = null, u2.__e = e2;
188
- } else u2.__e = t2.__e, u2.__k = t2.__k;
186
+ if (u2.__v = null, c2 || null != o2) if (n3.then) {
187
+ for (u2.__u |= c2 ? 160 : 128; f2 && 8 === f2.nodeType && f2.nextSibling; ) f2 = f2.nextSibling;
188
+ o2[o2.indexOf(f2)] = null, u2.__e = f2;
189
+ } else for (A2 = o2.length; A2--; ) _(o2[A2]);
190
+ else u2.__e = t2.__e, u2.__k = t2.__k;
189
191
  l$1.__e(n3, u2, t2);
190
192
  }
191
- else null == r2 && u2.__v === t2.__v ? (u2.__k = t2.__k, u2.__e = t2.__e) : u2.__e = z$1(t2.__e, u2, t2, i, o2, r2, f2, c2, s2);
192
- (a2 = l$1.diffed) && a2(u2);
193
+ else null == o2 && u2.__v === t2.__v ? (u2.__k = t2.__k, u2.__e = t2.__e) : f2 = u2.__e = N(t2.__e, u2, t2, i, r2, o2, e2, c2, s2);
194
+ return (a2 = l$1.diffed) && a2(u2), 128 & u2.__u ? void 0 : f2;
193
195
  }
194
- function j$1(n2, u2, t2) {
195
- u2.__d = void 0;
196
- for (var i = 0; i < t2.length; i++) E(t2[i], t2[++i], t2[++i]);
196
+ function z$1(n2, u2, t2) {
197
+ for (var i = 0; i < t2.length; i++) V(t2[i], t2[++i], t2[++i]);
197
198
  l$1.__c && l$1.__c(u2, n2), n2.some(function(u3) {
198
199
  try {
199
200
  n2 = u3.__h, u3.__h = [], n2.some(function(n3) {
@@ -204,35 +205,35 @@ function j$1(n2, u2, t2) {
204
205
  }
205
206
  });
206
207
  }
207
- function z$1(u2, t2, i, o2, r2, f2, e2, c2, s2) {
208
- var a2, v2, p2, d2, _2, g2, m2, b2 = i.props, k2 = t2.props, C2 = t2.type;
209
- if ("svg" === C2 ? r2 = "http://www.w3.org/2000/svg" : "math" === C2 ? r2 = "http://www.w3.org/1998/Math/MathML" : r2 || (r2 = "http://www.w3.org/1999/xhtml"), null != f2) {
210
- for (a2 = 0; a2 < f2.length; a2++) if ((_2 = f2[a2]) && "setAttribute" in _2 == !!C2 && (C2 ? _2.localName === C2 : 3 === _2.nodeType)) {
211
- u2 = _2, f2[a2] = null;
208
+ function N(u2, t2, i, r2, o2, e2, f2, c2, s2) {
209
+ var a2, h2, v2, y2, w2, g2, m2, b2 = i.props, k2 = t2.props, x = t2.type;
210
+ if ("svg" === x ? o2 = "http://www.w3.org/2000/svg" : "math" === x ? o2 = "http://www.w3.org/1998/Math/MathML" : o2 || (o2 = "http://www.w3.org/1999/xhtml"), null != e2) {
211
+ for (a2 = 0; a2 < e2.length; a2++) if ((w2 = e2[a2]) && "setAttribute" in w2 == !!x && (x ? w2.localName === x : 3 === w2.nodeType)) {
212
+ u2 = w2, e2[a2] = null;
212
213
  break;
213
214
  }
214
215
  }
215
216
  if (null == u2) {
216
- if (null === C2) return document.createTextNode(k2);
217
- u2 = document.createElementNS(r2, C2, k2.is && k2), c2 && (l$1.__m && l$1.__m(t2, f2), c2 = false), f2 = null;
217
+ if (null === x) return document.createTextNode(k2);
218
+ u2 = document.createElementNS(o2, x, k2.is && k2), c2 && (l$1.__m && l$1.__m(t2, e2), c2 = false), e2 = null;
218
219
  }
219
- if (null === C2) b2 === k2 || c2 && u2.data === k2 || (u2.data = k2);
220
+ if (null === x) b2 === k2 || c2 && u2.data === k2 || (u2.data = k2);
220
221
  else {
221
- if (f2 = f2 && n$2.call(u2.childNodes), b2 = i.props || h$1, !c2 && null != f2) for (b2 = {}, a2 = 0; a2 < u2.attributes.length; a2++) b2[(_2 = u2.attributes[a2]).name] = _2.value;
222
- for (a2 in b2) if (_2 = b2[a2], "children" == a2) ;
223
- else if ("dangerouslySetInnerHTML" == a2) p2 = _2;
222
+ if (e2 = e2 && n$2.call(u2.childNodes), b2 = i.props || p$1, !c2 && null != e2) for (b2 = {}, a2 = 0; a2 < u2.attributes.length; a2++) b2[(w2 = u2.attributes[a2]).name] = w2.value;
223
+ for (a2 in b2) if (w2 = b2[a2], "children" == a2) ;
224
+ else if ("dangerouslySetInnerHTML" == a2) v2 = w2;
224
225
  else if (!(a2 in k2)) {
225
226
  if ("value" == a2 && "defaultValue" in k2 || "checked" == a2 && "defaultChecked" in k2) continue;
226
- A$1(u2, a2, null, _2, r2);
227
+ F(u2, a2, null, w2, o2);
227
228
  }
228
- for (a2 in k2) _2 = k2[a2], "children" == a2 ? d2 = _2 : "dangerouslySetInnerHTML" == a2 ? v2 = _2 : "value" == a2 ? g2 = _2 : "checked" == a2 ? m2 = _2 : c2 && "function" != typeof _2 || b2[a2] === _2 || A$1(u2, a2, _2, b2[a2], r2);
229
- if (v2) c2 || p2 && (v2.__html === p2.__html || v2.__html === u2.innerHTML) || (u2.innerHTML = v2.__html), t2.__k = [];
230
- else if (p2 && (u2.innerHTML = ""), P$1(u2, y$1(d2) ? d2 : [d2], t2, i, o2, "foreignObject" === C2 ? "http://www.w3.org/1999/xhtml" : r2, f2, e2, f2 ? f2[0] : i.__k && x$1(i, 0), c2, s2), null != f2) for (a2 = f2.length; a2--; ) w$1(f2[a2]);
231
- c2 || (a2 = "value", "progress" === C2 && null == g2 ? u2.removeAttribute("value") : void 0 !== g2 && (g2 !== u2[a2] || "progress" === C2 && !g2 || "option" === C2 && g2 !== b2[a2]) && A$1(u2, a2, g2, b2[a2], r2), a2 = "checked", void 0 !== m2 && m2 !== u2[a2] && A$1(u2, a2, m2, b2[a2], r2));
229
+ for (a2 in k2) w2 = k2[a2], "children" == a2 ? y2 = w2 : "dangerouslySetInnerHTML" == a2 ? h2 = w2 : "value" == a2 ? g2 = w2 : "checked" == a2 ? m2 = w2 : c2 && "function" != typeof w2 || b2[a2] === w2 || F(u2, a2, w2, b2[a2], o2);
230
+ if (h2) c2 || v2 && (h2.__html === v2.__html || h2.__html === u2.innerHTML) || (u2.innerHTML = h2.__html), t2.__k = [];
231
+ else if (v2 && (u2.innerHTML = ""), $(u2, d$1(y2) ? y2 : [y2], t2, i, r2, "foreignObject" === x ? "http://www.w3.org/1999/xhtml" : o2, e2, f2, e2 ? e2[0] : i.__k && C$1(i, 0), c2, s2), null != e2) for (a2 = e2.length; a2--; ) _(e2[a2]);
232
+ c2 || (a2 = "value", "progress" === x && null == g2 ? u2.removeAttribute("value") : void 0 !== g2 && (g2 !== u2[a2] || "progress" === x && !g2 || "option" === x && g2 !== b2[a2]) && F(u2, a2, g2, b2[a2], o2), a2 = "checked", void 0 !== m2 && m2 !== u2[a2] && F(u2, a2, m2, b2[a2], o2));
232
233
  }
233
234
  return u2;
234
235
  }
235
- function E(n2, u2, t2) {
236
+ function V(n2, u2, t2) {
236
237
  try {
237
238
  if ("function" == typeof n2) {
238
239
  var i = "function" == typeof n2.__u;
@@ -242,9 +243,9 @@ function E(n2, u2, t2) {
242
243
  l$1.__e(n3, t2);
243
244
  }
244
245
  }
245
- function N(n2, u2, t2) {
246
- var i, o2;
247
- if (l$1.unmount && l$1.unmount(n2), (i = n2.ref) && (i.current && i.current !== n2.__e || E(i, null, u2)), null != (i = n2.__c)) {
246
+ function q$1(n2, u2, t2) {
247
+ var i, r2;
248
+ if (l$1.unmount && l$1.unmount(n2), (i = n2.ref) && (i.current && i.current !== n2.__e || V(i, null, u2)), null != (i = n2.__c)) {
248
249
  if (i.componentWillUnmount) try {
249
250
  i.componentWillUnmount();
250
251
  } catch (n3) {
@@ -252,31 +253,31 @@ function N(n2, u2, t2) {
252
253
  }
253
254
  i.base = i.__P = null;
254
255
  }
255
- if (i = n2.__k) for (o2 = 0; o2 < i.length; o2++) i[o2] && N(i[o2], u2, t2 || "function" != typeof n2.type);
256
- t2 || w$1(n2.__e), n2.__c = n2.__ = n2.__e = n2.__d = void 0;
256
+ if (i = n2.__k) for (r2 = 0; r2 < i.length; r2++) i[r2] && q$1(i[r2], u2, t2 || "function" != typeof n2.type);
257
+ t2 || _(n2.__e), n2.__c = n2.__ = n2.__e = void 0;
257
258
  }
258
- function V(n2, l2, u2) {
259
+ function B$1(n2, l2, u2) {
259
260
  return this.constructor(n2, u2);
260
261
  }
261
- function q$1(u2, t2, i) {
262
- var o2, r2, f2, e2;
263
- l$1.__ && l$1.__(u2, t2), r2 = (o2 = "function" == typeof i) ? null : t2.__k, f2 = [], e2 = [], O(t2, u2 = (!o2 && i || t2).__k = _(b, null, [u2]), r2 || h$1, h$1, t2.namespaceURI, !o2 && i ? [i] : r2 ? null : t2.firstChild ? n$2.call(t2.childNodes) : null, f2, !o2 && i ? i : r2 ? r2.__e : t2.firstChild, o2, e2), j$1(f2, u2, e2);
262
+ function D$1(u2, t2, i) {
263
+ var r2, o2, e2, f2;
264
+ t2 === document && (t2 = document.documentElement), l$1.__ && l$1.__(u2, t2), o2 = (r2 = "function" == typeof i) ? null : t2.__k, e2 = [], f2 = [], j$1(t2, u2 = (!r2 && i || t2).__k = g(k$1, null, [u2]), o2 || p$1, p$1, t2.namespaceURI, !r2 && i ? [i] : o2 ? null : t2.firstChild ? n$2.call(t2.childNodes) : null, e2, !r2 && i ? i : o2 ? o2.__e : t2.firstChild, r2, f2), z$1(e2, u2, f2);
264
265
  }
265
266
  n$2 = v$1.slice, l$1 = { __e: function(n2, l2, u2, t2) {
266
- for (var i, o2, r2; l2 = l2.__; ) if ((i = l2.__c) && !i.__) try {
267
- if ((o2 = i.constructor) && null != o2.getDerivedStateFromError && (i.setState(o2.getDerivedStateFromError(n2)), r2 = i.__d), null != i.componentDidCatch && (i.componentDidCatch(n2, t2 || {}), r2 = i.__d), r2) return i.__E = i;
267
+ for (var i, r2, o2; l2 = l2.__; ) if ((i = l2.__c) && !i.__) try {
268
+ if ((r2 = i.constructor) && null != r2.getDerivedStateFromError && (i.setState(r2.getDerivedStateFromError(n2)), o2 = i.__d), null != i.componentDidCatch && (i.componentDidCatch(n2, t2 || {}), o2 = i.__d), o2) return i.__E = i;
268
269
  } catch (l3) {
269
270
  n2 = l3;
270
271
  }
271
272
  throw n2;
272
- } }, u$1 = 0, k$1.prototype.setState = function(n2, l2) {
273
+ } }, u$1 = 0, x$1.prototype.setState = function(n2, l2) {
273
274
  var u2;
274
- u2 = null != this.__s && this.__s !== this.state ? this.__s : this.__s = d$1({}, this.state), "function" == typeof n2 && (n2 = n2(d$1({}, u2), this.props)), n2 && d$1(u2, n2), null != n2 && this.__v && (l2 && this._sb.push(l2), S(this));
275
- }, k$1.prototype.forceUpdate = function(n2) {
276
- this.__v && (this.__e = true, n2 && this.__h.push(n2), S(this));
277
- }, k$1.prototype.render = b, i$2 = [], r$2 = "function" == typeof Promise ? Promise.prototype.then.bind(Promise.resolve()) : setTimeout, f$1 = function(n2, l2) {
275
+ u2 = null != this.__s && this.__s !== this.state ? this.__s : this.__s = w$1({}, this.state), "function" == typeof n2 && (n2 = n2(w$1({}, u2), this.props)), n2 && w$1(u2, n2), null != n2 && this.__v && (l2 && this._sb.push(l2), M(this));
276
+ }, x$1.prototype.forceUpdate = function(n2) {
277
+ this.__v && (this.__e = true, n2 && this.__h.push(n2), M(this));
278
+ }, x$1.prototype.render = k$1, i$2 = [], o$1 = "function" == typeof Promise ? Promise.prototype.then.bind(Promise.resolve()) : setTimeout, e$3 = function(n2, l2) {
278
279
  return n2.__v.__b - l2.__v.__b;
279
- }, M.__r = 0, e$3 = 0, c$2 = F(false), s$1 = F(true);
280
+ }, P$1.__r = 0, f$1 = /(PointerCapture)$|Capture$/i, c$2 = 0, s$1 = O(false), a$1 = O(true);
280
281
  var n$1 = function(t2, s2, r2, e2) {
281
282
  var u2;
282
283
  s2[0] = 0;
@@ -298,7 +299,7 @@ function e$2(s2) {
298
299
  return p2(), h2;
299
300
  }(s2)), r2), arguments, [])).length > 1 ? r2 : r2[0];
300
301
  }
301
- var m$1 = e$2.bind(_);
302
+ var m$1 = e$2.bind(g);
302
303
  var commonjsGlobal = typeof globalThis !== "undefined" ? globalThis : typeof window !== "undefined" ? window : typeof global !== "undefined" ? global : typeof self !== "undefined" ? self : {};
303
304
  function getDefaultExportFromCjs(x) {
304
305
  return x && x.__esModule && Object.prototype.hasOwnProperty.call(x, "default") ? x["default"] : x;
@@ -2297,9 +2298,9 @@ var clipboard = { exports: {} };
2297
2298
  279: (
2298
2299
  /***/
2299
2300
  function(module2) {
2300
- function E2() {
2301
+ function E() {
2301
2302
  }
2302
- E2.prototype = {
2303
+ E.prototype = {
2303
2304
  on: function(name, callback, ctx) {
2304
2305
  var e2 = this.e || (this.e = {});
2305
2306
  (e2[name] || (e2[name] = [])).push({
@@ -2341,8 +2342,8 @@ var clipboard = { exports: {} };
2341
2342
  return this;
2342
2343
  }
2343
2344
  };
2344
- module2.exports = E2;
2345
- module2.exports.TinyEmitter = E2;
2345
+ module2.exports = E;
2346
+ module2.exports.TinyEmitter = E;
2346
2347
  }
2347
2348
  )
2348
2349
  /******/
@@ -7951,7 +7952,7 @@ const ErrorPanel = ({ id, classes, title, error: error2 }) => {
7951
7952
  </div>
7952
7953
  `;
7953
7954
  };
7954
- class AppErrorBoundary extends k$1 {
7955
+ class AppErrorBoundary extends x$1 {
7955
7956
  constructor(props) {
7956
7957
  super(props);
7957
7958
  this.state = { hasError: false };
@@ -8614,7 +8615,7 @@ const ToolButton = ({ name, classes, icon, onclick, ...rest }) => {
8614
8615
  ...rest
8615
8616
  };
8616
8617
  const iconEl = icon ? m$1`<i class="${icon}" style=${{ marginRight: "0.5em" }}></i>` : "";
8617
- return _("button", attr, m$1`${iconEl}${name}`);
8618
+ return g("button", attr, m$1`${iconEl}${name}`);
8618
8619
  };
8619
8620
  const ghCommitUrl = (origin, commit) => {
8620
8621
  const baseUrl = origin.replace(/\.git$/, "");
@@ -14726,6 +14727,87 @@ function unescapeCodeHtmlEntities(str) {
14726
14727
  }
14727
14728
  );
14728
14729
  }
14730
+ var murmurhash$1 = { exports: {} };
14731
+ (function(module) {
14732
+ (function() {
14733
+ const createBuffer = (val) => new TextEncoder().encode(val);
14734
+ function MurmurHashV2(str, seed) {
14735
+ if (typeof str === "string") str = createBuffer(str);
14736
+ let l2 = str.length, h2 = seed ^ l2, i = 0, k2;
14737
+ while (l2 >= 4) {
14738
+ k2 = str[i] & 255 | (str[++i] & 255) << 8 | (str[++i] & 255) << 16 | (str[++i] & 255) << 24;
14739
+ k2 = (k2 & 65535) * 1540483477 + (((k2 >>> 16) * 1540483477 & 65535) << 16);
14740
+ k2 ^= k2 >>> 24;
14741
+ k2 = (k2 & 65535) * 1540483477 + (((k2 >>> 16) * 1540483477 & 65535) << 16);
14742
+ h2 = (h2 & 65535) * 1540483477 + (((h2 >>> 16) * 1540483477 & 65535) << 16) ^ k2;
14743
+ l2 -= 4;
14744
+ ++i;
14745
+ }
14746
+ switch (l2) {
14747
+ case 3:
14748
+ h2 ^= (str[i + 2] & 255) << 16;
14749
+ case 2:
14750
+ h2 ^= (str[i + 1] & 255) << 8;
14751
+ case 1:
14752
+ h2 ^= str[i] & 255;
14753
+ h2 = (h2 & 65535) * 1540483477 + (((h2 >>> 16) * 1540483477 & 65535) << 16);
14754
+ }
14755
+ h2 ^= h2 >>> 13;
14756
+ h2 = (h2 & 65535) * 1540483477 + (((h2 >>> 16) * 1540483477 & 65535) << 16);
14757
+ h2 ^= h2 >>> 15;
14758
+ return h2 >>> 0;
14759
+ }
14760
+ function MurmurHashV3(key2, seed) {
14761
+ if (typeof key2 === "string") key2 = createBuffer(key2);
14762
+ let remainder, bytes, h1, h1b, c1, c2, k1, i;
14763
+ remainder = key2.length & 3;
14764
+ bytes = key2.length - remainder;
14765
+ h1 = seed;
14766
+ c1 = 3432918353;
14767
+ c2 = 461845907;
14768
+ i = 0;
14769
+ while (i < bytes) {
14770
+ k1 = key2[i] & 255 | (key2[++i] & 255) << 8 | (key2[++i] & 255) << 16 | (key2[++i] & 255) << 24;
14771
+ ++i;
14772
+ k1 = (k1 & 65535) * c1 + (((k1 >>> 16) * c1 & 65535) << 16) & 4294967295;
14773
+ k1 = k1 << 15 | k1 >>> 17;
14774
+ k1 = (k1 & 65535) * c2 + (((k1 >>> 16) * c2 & 65535) << 16) & 4294967295;
14775
+ h1 ^= k1;
14776
+ h1 = h1 << 13 | h1 >>> 19;
14777
+ h1b = (h1 & 65535) * 5 + (((h1 >>> 16) * 5 & 65535) << 16) & 4294967295;
14778
+ h1 = (h1b & 65535) + 27492 + (((h1b >>> 16) + 58964 & 65535) << 16);
14779
+ }
14780
+ k1 = 0;
14781
+ switch (remainder) {
14782
+ case 3:
14783
+ k1 ^= (key2[i + 2] & 255) << 16;
14784
+ case 2:
14785
+ k1 ^= (key2[i + 1] & 255) << 8;
14786
+ case 1:
14787
+ k1 ^= key2[i] & 255;
14788
+ k1 = (k1 & 65535) * c1 + (((k1 >>> 16) * c1 & 65535) << 16) & 4294967295;
14789
+ k1 = k1 << 15 | k1 >>> 17;
14790
+ k1 = (k1 & 65535) * c2 + (((k1 >>> 16) * c2 & 65535) << 16) & 4294967295;
14791
+ h1 ^= k1;
14792
+ }
14793
+ h1 ^= key2.length;
14794
+ h1 ^= h1 >>> 16;
14795
+ h1 = (h1 & 65535) * 2246822507 + (((h1 >>> 16) * 2246822507 & 65535) << 16) & 4294967295;
14796
+ h1 ^= h1 >>> 13;
14797
+ h1 = (h1 & 65535) * 3266489909 + (((h1 >>> 16) * 3266489909 & 65535) << 16) & 4294967295;
14798
+ h1 ^= h1 >>> 16;
14799
+ return h1 >>> 0;
14800
+ }
14801
+ const murmur = MurmurHashV3;
14802
+ murmur.v2 = MurmurHashV2;
14803
+ murmur.v3 = MurmurHashV3;
14804
+ {
14805
+ module.exports = murmur;
14806
+ }
14807
+ })();
14808
+ })(murmurhash$1);
14809
+ var murmurhashExports = murmurhash$1.exports;
14810
+ const murmurhash = /* @__PURE__ */ getDefaultExportFromCjs(murmurhashExports);
14729
14811
  Prism.languages.python = {
14730
14812
  "comment": {
14731
14813
  pattern: /(^|[^\\])#.*/,
@@ -15199,7 +15281,7 @@ const ToolCallView = ({
15199
15281
  </div>`;
15200
15282
  };
15201
15283
  const ToolInput = ({ type, contents, view, style }) => {
15202
- if (!contents) {
15284
+ if (!contents && !(view == null ? void 0 : view.content)) {
15203
15285
  return "";
15204
15286
  }
15205
15287
  if (view) {
@@ -15224,7 +15306,7 @@ const ToolInput = ({ type, contents, view, style }) => {
15224
15306
  }
15225
15307
  }
15226
15308
  }
15227
- }, [toolInputRef.current]);
15309
+ }, [contents, view, style]);
15228
15310
  return m$1`<${MarkdownDiv}
15229
15311
  markdown=${view.content}
15230
15312
  ref=${toolInputRef}
@@ -15238,14 +15320,11 @@ const ToolInput = ({ type, contents, view, style }) => {
15238
15320
  y(() => {
15239
15321
  const tokens = Prism$1.languages[type];
15240
15322
  if (toolInputRef.current && tokens) {
15241
- let resolvedContents = contents;
15242
- if (typeof contents === "object" || Array.isArray(contents)) {
15243
- resolvedContents = JSON.stringify(contents);
15244
- }
15245
- const html = Prism$1.highlight(resolvedContents, tokens, type);
15246
- toolInputRef.current.innerHTML = html;
15323
+ Prism$1.highlightElement(toolInputRef.current);
15247
15324
  }
15248
- }, [toolInputRef.current, contents, type, view]);
15325
+ }, [contents, type, view]);
15326
+ contents = typeof contents === "object" || Array.isArray(contents) ? JSON.stringify(contents) : contents;
15327
+ const key2 = murmurhash.v3(contents);
15249
15328
  return m$1`<pre
15250
15329
  class="tool-output"
15251
15330
  style=${{
@@ -15255,7 +15334,9 @@ const ToolInput = ({ type, contents, view, style }) => {
15255
15334
  ...style
15256
15335
  }}
15257
15336
  >
15258
- <code ref=${toolInputRef} class="sourceCode${type ? ` language-${type}` : ""}" style=${{
15337
+ <code ref=${toolInputRef}
15338
+ key=${key2}
15339
+ class="sourceCode${type ? ` language-${type}` : ""}" style=${{
15259
15340
  overflowWrap: "anywhere",
15260
15341
  whiteSpace: "pre-wrap"
15261
15342
  }}>
@@ -15337,8 +15418,15 @@ const extractInput = (inputKey, args) => {
15337
15418
  };
15338
15419
  if (args) {
15339
15420
  if (Object.keys(args).length === 1) {
15421
+ const inputRaw = args[Object.keys(args)[0]];
15422
+ let input;
15423
+ if (Array.isArray(inputRaw) || typeof inputRaw === "object") {
15424
+ input = JSON.stringify(inputRaw, void 0, 2);
15425
+ } else {
15426
+ input = String(inputRaw);
15427
+ }
15340
15428
  return {
15341
- input: args[Object.keys(args)[0]],
15429
+ input,
15342
15430
  args: []
15343
15431
  };
15344
15432
  } else if (args[inputKey]) {
@@ -16361,7 +16449,7 @@ const PlanColumn = ({ title, classes, style, children }) => {
16361
16449
  };
16362
16450
  const MessageBand = ({ message, hidden, setHidden, type }) => {
16363
16451
  const bgColor = type === "info" ? "var(--bs-light)" : "var(--bs-" + type + "-bg-subtle)";
16364
- const color = "var(--bs-" + type === "info" ? "secondary" : "undefined-text-emphasis)";
16452
+ const color = "var(--bs-" + (type === "info" ? "secondary" : type) + "-text-emphasis)";
16365
16453
  return m$1`
16366
16454
  <div
16367
16455
  style=${{
@@ -16586,6 +16674,67 @@ const SampleScores = ({ sample, sampleDescriptor, scorer }) => {
16586
16674
  </div>`;
16587
16675
  }
16588
16676
  };
16677
+ const MetaDataGrid = ({ id, entries, classes, style, plain }) => {
16678
+ const baseId = "metadata-grid";
16679
+ const cellKeyStyle = {
16680
+ fontWeight: "400",
16681
+ whiteSpace: "nowrap",
16682
+ ...TextStyle.label,
16683
+ ...TextStyle.secondary
16684
+ };
16685
+ const cellValueStyle = {
16686
+ whiteSpace: "pre-wrap",
16687
+ wordWrap: "anywhere",
16688
+ fontSize: FontSize.small
16689
+ };
16690
+ const cellKeyTextStyle = {
16691
+ fontSize: FontSize.small
16692
+ };
16693
+ const entryRecords = (entries2) => {
16694
+ if (!entries2) {
16695
+ return [];
16696
+ }
16697
+ if (!Array.isArray(entries2)) {
16698
+ return Object.entries(entries2 || {}).map(([key2, value]) => {
16699
+ return { name: key2, value };
16700
+ });
16701
+ } else {
16702
+ return entries2;
16703
+ }
16704
+ };
16705
+ const entryEls = entryRecords(entries).map((entry, index) => {
16706
+ const id2 = `${baseId}-value-${index}`;
16707
+ return m$1`
16708
+ <div
16709
+ style=${{
16710
+ gridColumn: "1 / -1",
16711
+ borderBottom: `${!plain ? "solid 1px var(--bs-light-border-subtle" : ""}`
16712
+ }}
16713
+ ></div>
16714
+ <div
16715
+ class="${baseId}-key"
16716
+ style=${{ ...cellKeyStyle, ...cellKeyTextStyle }}
16717
+ >
16718
+ ${entry.name}
16719
+ </div>
16720
+ <div class="${baseId}-value" style=${{ ...cellValueStyle }}>
16721
+ <${RenderedContent} id=${id2} entry=${entry} />
16722
+ </div>
16723
+ `;
16724
+ });
16725
+ return m$1`<div
16726
+ ...${{ id }}
16727
+ class="${classes || ""}"
16728
+ style=${{
16729
+ display: "grid",
16730
+ gridTemplateColumns: "max-content auto",
16731
+ columnGap: "1em",
16732
+ ...style
16733
+ }}
16734
+ >
16735
+ ${entryEls}
16736
+ </div>`;
16737
+ };
16589
16738
  const labelStyle = {
16590
16739
  paddingRight: "2em",
16591
16740
  paddingLeft: "0",
@@ -16599,7 +16748,6 @@ const SampleScoreView = ({
16599
16748
  style,
16600
16749
  scorer
16601
16750
  }) => {
16602
- var _a2, _b2, _c;
16603
16751
  if (!sampleDescriptor) {
16604
16752
  return "";
16605
16753
  }
@@ -16615,16 +16763,20 @@ const SampleScoreView = ({
16615
16763
  const scorerDescriptor = sampleDescriptor.scorer(sample, scorer);
16616
16764
  const explanation = scorerDescriptor.explanation() || "(No Explanation)";
16617
16765
  const answer = scorerDescriptor.answer();
16766
+ const metadata = scorerDescriptor.metadata();
16618
16767
  return m$1`
16619
- <div
16620
- class="container-fluid"
16621
- style=${{
16622
- paddingTop: "1em",
16768
+ <div
16769
+ class="container-fluid"
16770
+ style=${{
16771
+ marginTop: "0.5em",
16623
16772
  paddingLeft: "0",
16624
16773
  fontSize: FontSize.base,
16625
16774
  ...style
16626
16775
  }}
16627
- >
16776
+ >
16777
+ <${Card}>
16778
+ <${CardHeader} label="Score"/>
16779
+ <${CardBody}>
16628
16780
  <div>
16629
16781
  <div style=${{ ...labelStyle }}>Input</div>
16630
16782
  <div>
@@ -16637,7 +16789,7 @@ const SampleScoreView = ({
16637
16789
 
16638
16790
  <table
16639
16791
  class="table"
16640
- style=${{ width: "100%", marginBottom: "0", marginTop: "1em" }}
16792
+ style=${{ width: "100%", marginBottom: "1em" }}
16641
16793
  >
16642
16794
  <thead style=${{ borderBottomColor: "#00000000" }}>
16643
16795
  <tr>
@@ -16693,68 +16845,34 @@ const SampleScoreView = ({
16693
16845
  </tr>
16694
16846
  </tbody>
16695
16847
  </table>
16848
+ </${CardBody}>
16849
+ </${Card}>
16696
16850
 
16697
- ${explanation && explanation !== answer ? m$1` <table
16698
- class="table"
16699
- style=${{ width: "100%", marginBottom: "0" }}
16700
- >
16701
- <thead>
16702
- <tr>
16703
- <th
16704
- style=${{
16705
- paddingBottom: "0",
16706
- paddingLeft: "0",
16707
- ...labelStyle,
16708
- fontWeight: "400"
16709
- }}
16710
- >
16711
- Explanation
16712
- </th>
16713
- </tr>
16714
- </thead>
16715
- <tbody>
16716
- <tr>
16717
- <td style=${{ paddingLeft: "0" }}>
16718
- <${MarkdownDiv}
16719
- markdown=${arrayToString(explanation)}
16720
- style=${{ paddingLeft: "0" }}
16721
- class="no-last-para-padding"
16722
- />
16723
- </td>
16724
- </tr>
16725
- </tbody>
16726
- </table>` : ""}
16727
- ${((_a2 = sample == null ? void 0 : sample.score) == null ? void 0 : _a2.metadata) && Object.keys((_b2 = sample == null ? void 0 : sample.score) == null ? void 0 : _b2.metadata).length > 0 ? m$1` <table
16728
- class="table"
16729
- style=${{ width: "100%", marginBottom: "0" }}
16730
- >
16731
- <thead>
16732
- <tr>
16733
- <th
16734
- style=${{
16735
- paddingBottom: "0",
16736
- paddingLeft: "0",
16737
- ...labelStyle,
16738
- fontWeight: "400"
16739
- }}
16740
- >
16741
- Metadata
16742
- </th>
16743
- </tr>
16744
- </thead>
16745
- <tbody>
16746
- <tr>
16747
- <td style=${{ paddingLeft: "0" }}>
16748
- <${MetaDataView}
16749
- id="task-sample-score-metadata"
16750
- classes="tab-pane"
16751
- entries="${(_c = sample == null ? void 0 : sample.score) == null ? void 0 : _c.metadata}"
16752
- style=${{ marginTop: "1em" }}
16753
- />
16754
- </td>
16755
- </tr>
16756
- </tbody>
16757
- </table>` : ""}
16851
+ ${explanation && explanation !== answer ? m$1`
16852
+ <${Card}>
16853
+ <${CardHeader} label="Explanation"/>
16854
+ <${CardBody}>
16855
+ <${MarkdownDiv}
16856
+ markdown=${arrayToString(explanation)}
16857
+ style=${{ paddingLeft: "0" }}
16858
+ class="no-last-para-padding"
16859
+ />
16860
+
16861
+ </${CardBody}>
16862
+ </${Card}>` : ""}
16863
+
16864
+ ${metadata && Object.keys(metadata).length > 0 ? m$1`
16865
+ <${Card}>
16866
+ <${CardHeader} label="Metadata"/>
16867
+ <${CardBody}>
16868
+ <${MetaDataGrid}
16869
+ id="task-sample-score-metadata"
16870
+ classes="tab-pane"
16871
+ entries="${metadata}"
16872
+ style=${{ marginTop: "0" }}
16873
+ />
16874
+ </${CardBody}>
16875
+ </${Card}>` : ""}
16758
16876
  </div>
16759
16877
  `;
16760
16878
  };
@@ -16953,67 +17071,6 @@ const EventNav = ({ target, title, selectedNav, setSelectedNav }) => {
16953
17071
  </button>
16954
17072
  </li>`;
16955
17073
  };
16956
- const MetaDataGrid = ({ id, entries, classes, style, plain }) => {
16957
- const baseId = "metadata-grid";
16958
- const cellKeyStyle = {
16959
- fontWeight: "400",
16960
- whiteSpace: "nowrap",
16961
- ...TextStyle.label,
16962
- ...TextStyle.secondary
16963
- };
16964
- const cellValueStyle = {
16965
- whiteSpace: "pre-wrap",
16966
- wordWrap: "anywhere",
16967
- fontSize: FontSize.small
16968
- };
16969
- const cellKeyTextStyle = {
16970
- fontSize: FontSize.small
16971
- };
16972
- const entryRecords = (entries2) => {
16973
- if (!entries2) {
16974
- return [];
16975
- }
16976
- if (!Array.isArray(entries2)) {
16977
- return Object.entries(entries2 || {}).map(([key2, value]) => {
16978
- return { name: key2, value };
16979
- });
16980
- } else {
16981
- return entries2;
16982
- }
16983
- };
16984
- const entryEls = entryRecords(entries).map((entry, index) => {
16985
- const id2 = `${baseId}-value-${index}`;
16986
- return m$1`
16987
- <div
16988
- style=${{
16989
- gridColumn: "1 / -1",
16990
- borderBottom: `${!plain ? "solid 1px var(--bs-light-border-subtle" : ""}`
16991
- }}
16992
- ></div>
16993
- <div
16994
- class="${baseId}-key"
16995
- style=${{ ...cellKeyStyle, ...cellKeyTextStyle }}
16996
- >
16997
- ${entry.name}
16998
- </div>
16999
- <div class="${baseId}-value" style=${{ ...cellValueStyle }}>
17000
- <${RenderedContent} id=${id2} entry=${entry} />
17001
- </div>
17002
- `;
17003
- });
17004
- return m$1`<div
17005
- ...${{ id }}
17006
- class="${classes || ""}"
17007
- style=${{
17008
- display: "grid",
17009
- gridTemplateColumns: "max-content auto",
17010
- columnGap: "1em",
17011
- ...style
17012
- }}
17013
- >
17014
- ${entryEls}
17015
- </div>`;
17016
- };
17017
17074
  const EventSection = ({ title, style, children }) => {
17018
17075
  return m$1`<div
17019
17076
  style=${{
@@ -17197,8 +17254,9 @@ const RenderableChangeTypes = [
17197
17254
  ];
17198
17255
  const Tools = ({ toolDefinitions }) => {
17199
17256
  return toolDefinitions.map((toolDefinition) => {
17257
+ var _a2;
17200
17258
  const toolName = toolDefinition.name;
17201
- const toolArgs = Object.keys(toolDefinition.parameters.properties);
17259
+ const toolArgs = ((_a2 = toolDefinition.parameters) == null ? void 0 : _a2.properties) ? Object.keys(toolDefinition.parameters.properties) : [];
17202
17260
  return m$1`<${Tool} toolName=${toolName} toolArgs=${toolArgs} />`;
17203
17261
  });
17204
17262
  };
@@ -19177,7 +19235,15 @@ const ModelUsagePanel = ({ usage }) => {
19177
19235
  const ModelEventView = ({ id, event, style }) => {
19178
19236
  var _a2, _b2;
19179
19237
  const totalUsage = (_a2 = event.output.usage) == null ? void 0 : _a2.total_tokens;
19180
- const subtitle = totalUsage ? `(${formatNumber(totalUsage)} tokens)` : "";
19238
+ const callTime = event.output.time;
19239
+ const subItems = [];
19240
+ if (totalUsage) {
19241
+ subItems.push(`${formatNumber(totalUsage)} tokens`);
19242
+ }
19243
+ if (callTime) {
19244
+ subItems.push(`${formatPrettyDecimal(callTime)} sec`);
19245
+ }
19246
+ const subtitle = subItems.length > 0 ? `(${subItems.join(", ")})` : "";
19181
19247
  const outputMessages = (_b2 = event.output.choices) == null ? void 0 : _b2.map((choice) => {
19182
19248
  return choice.message;
19183
19249
  });
@@ -19977,7 +20043,6 @@ const SampleDisplay = ({
19977
20043
  sample=${sample}
19978
20044
  sampleDescriptor=${sampleDescriptor}
19979
20045
  scorer=${Object.keys(sample.scores)[0]}
19980
- style=${{ paddingLeft: "0.8em", marginTop: "0.4em" }}
19981
20046
  />
19982
20047
  </${TabPanel}>`);
19983
20048
  } else {
@@ -19989,7 +20054,6 @@ const SampleDisplay = ({
19989
20054
  sample=${sample}
19990
20055
  sampleDescriptor=${sampleDescriptor}
19991
20056
  scorer=${scorer}
19992
- style=${{ paddingLeft: "0.8em", marginTop: "0.4em" }}
19993
20057
  />
19994
20058
  </${TabPanel}>`);
19995
20059
  }
@@ -20004,7 +20068,7 @@ const SampleDisplay = ({
20004
20068
  title="Metadata"
20005
20069
  onSelected=${onSelectedTab}
20006
20070
  selected=${selectedTab === kSampleMetdataTabId}>
20007
- <div style=${{ display: "flex", flexWrap: "wrap", alignItems: "flex-start", gap: "1em", paddingLeft: "0.8em", marginTop: "1em" }}>
20071
+ <div style=${{ display: "flex", flexWrap: "wrap", alignItems: "flex-start", gap: "1em", paddingLeft: "0", marginTop: "0.5em" }}>
20008
20072
  ${sampleMetadatas}
20009
20073
  </div>
20010
20074
  </${TabPanel}>`
@@ -20358,7 +20422,7 @@ const SampleDialog = ({
20358
20422
  };
20359
20423
  const STYLE_INNER = "position:relative; overflow:hidden; width:100%; min-height:100%;";
20360
20424
  const STYLE_CONTENT = "position:absolute; top:0; left:0; height:100%; width:100%; overflow:visible;";
20361
- class VirtualList extends k$1 {
20425
+ class VirtualList extends x$1 {
20362
20426
  constructor(props) {
20363
20427
  super(props);
20364
20428
  this.state = {
@@ -20367,7 +20431,7 @@ class VirtualList extends k$1 {
20367
20431
  };
20368
20432
  this.resize = this.resize.bind(this);
20369
20433
  this.handleScroll = throttle(this.handleScroll.bind(this), 100);
20370
- this.containerRef = m$2();
20434
+ this.containerRef = b();
20371
20435
  }
20372
20436
  resize() {
20373
20437
  if (this.state.height !== this.base.offsetHeight) {
@@ -23830,25 +23894,48 @@ const byEpoch = (sort) => {
23830
23894
  const bySample = (sort) => {
23831
23895
  return sort === kSampleAscVal || sort === kSampleDescVal;
23832
23896
  };
23897
+ const sortId = (a2, b2) => {
23898
+ if (isNumeric(a2.id) && isNumeric(b2.id)) {
23899
+ return Number(a2.id) - Number(b2.id);
23900
+ } else {
23901
+ return String(a2.id).localeCompare(String(b2.id));
23902
+ }
23903
+ };
23833
23904
  const sortSamples = (sort, samples, samplesDescriptor) => {
23834
23905
  const sortedSamples = samples.sort((a2, b2) => {
23835
23906
  switch (sort) {
23836
- case kSampleAscVal:
23837
- if (isNumeric(a2.id) && isNumeric(b2.id)) {
23838
- return Number(a2.id) - Number(b2.id);
23907
+ case kSampleAscVal: {
23908
+ const result = sortId(a2, b2);
23909
+ if (result !== 0) {
23910
+ return result;
23839
23911
  } else {
23840
- return String(a2.id).localeCompare(String(b2.id));
23912
+ return a2.epoch - b2.epoch;
23841
23913
  }
23842
- case kSampleDescVal:
23843
- if (isNumeric(a2.id) && isNumeric(b2.id)) {
23844
- return Number(b2.id) - Number(a2.id);
23914
+ }
23915
+ case kSampleDescVal: {
23916
+ const result = sortId(b2, a2);
23917
+ if (result !== 0) {
23918
+ return result;
23845
23919
  } else {
23846
- return String(b2.id).localeCompare(String(a2.id));
23920
+ return a2.epoch - b2.epoch;
23847
23921
  }
23848
- case kEpochAscVal:
23849
- return a2.epoch - b2.epoch;
23850
- case kEpochDescVal:
23851
- return b2.epoch - a2.epoch;
23922
+ }
23923
+ case kEpochAscVal: {
23924
+ const result = a2.epoch - b2.epoch;
23925
+ if (result !== 0) {
23926
+ return result;
23927
+ } else {
23928
+ return sortId(a2, b2);
23929
+ }
23930
+ }
23931
+ case kEpochDescVal: {
23932
+ const result = b2.epoch - a2.epoch;
23933
+ if (result !== 0) {
23934
+ return result;
23935
+ } else {
23936
+ return sortId(a2, b2);
23937
+ }
23938
+ }
23852
23939
  case kScoreAscVal:
23853
23940
  return samplesDescriptor.scoreDescriptor.compare(
23854
23941
  samplesDescriptor.selectedScore(a2).value,
@@ -24916,7 +25003,9 @@ const WorkSpace = ({
24916
25003
  evalError,
24917
25004
  logFileName,
24918
25005
  capabilities,
24919
- selectedTab
25006
+ selectedTab,
25007
+ setHidden,
25008
+ hidden
24920
25009
  ]);
24921
25010
  return m$1`<${WorkspaceDisplay}
24922
25011
  logFileName=${logFileName}
@@ -25239,6 +25328,15 @@ const createsSamplesDescriptor = (scorers, samples, epochs, selectedScore) => {
25239
25328
  }
25240
25329
  return void 0;
25241
25330
  };
25331
+ const scoreMetadata = (sample, scorer) => {
25332
+ if (sample) {
25333
+ const sampleScore = score(sample, scorer);
25334
+ if (sampleScore && sampleScore.metadata) {
25335
+ return sampleScore.metadata;
25336
+ }
25337
+ }
25338
+ return void 0;
25339
+ };
25242
25340
  const uniqScoreValues = [
25243
25341
  ...new Set(
25244
25342
  samples.filter((sample) => !!sample.scores).filter((sample) => {
@@ -25338,6 +25436,9 @@ const createsSamplesDescriptor = (scorers, samples, epochs, selectedScore) => {
25338
25436
  };
25339
25437
  const scorerDescriptor = (sample, scorer) => {
25340
25438
  return {
25439
+ metadata: () => {
25440
+ return scoreMetadata(sample, scorer);
25441
+ },
25341
25442
  explanation: () => {
25342
25443
  return scoreExplanation(sample, scorer);
25343
25444
  },
@@ -25348,35 +25449,22 @@ const createsSamplesDescriptor = (scorers, samples, epochs, selectedScore) => {
25348
25449
  if (!sample || !sample.scores) {
25349
25450
  return [];
25350
25451
  }
25351
- const scoreNames = scorers.map((score2) => {
25452
+ scorers.map((score2) => {
25352
25453
  return score2.name;
25353
25454
  });
25354
25455
  const sampleScorer = sample.scores[scorer];
25355
25456
  const scoreVal = sampleScorer.value;
25356
25457
  if (typeof scoreVal === "object") {
25357
25458
  const names = Object.keys(scoreVal);
25358
- if (names.find((name) => {
25359
- return !scoreNames.includes(name);
25360
- })) {
25361
- return [
25362
- {
25363
- name: scorer,
25364
- rendered: () => {
25365
- return scoreDescriptor.render(scoreVal);
25366
- }
25459
+ const scores = names.map((name) => {
25460
+ return {
25461
+ name,
25462
+ rendered: () => {
25463
+ return scoreDescriptor.render(scoreVal[name]);
25367
25464
  }
25368
- ];
25369
- } else {
25370
- const scores = names.map((name) => {
25371
- return {
25372
- name,
25373
- rendered: () => {
25374
- return scoreDescriptor.render(scoreVal[name]);
25375
- }
25376
- };
25377
- });
25378
- return scores;
25379
- }
25465
+ };
25466
+ });
25467
+ return scores;
25380
25468
  } else {
25381
25469
  return [
25382
25470
  {
@@ -25429,7 +25517,7 @@ const scoreCategorizers = [
25429
25517
  * @returns {ScoreDescriptor} a ScoreDescriptor
25430
25518
  */
25431
25519
  describe: (values) => {
25432
- if ((values.length === 1 || values.length === 2) && values.every((val) => {
25520
+ if (values.length === 2 && values.every((val) => {
25433
25521
  return val === 1 || val === 0;
25434
25522
  })) {
25435
25523
  return booleanScoreCategorizer();
@@ -26510,7 +26598,7 @@ let initialState = void 0;
26510
26598
  if (vscode) {
26511
26599
  initialState = vscode.getState();
26512
26600
  }
26513
- q$1(m$1`<${App}
26601
+ D$1(m$1`<${App}
26514
26602
  api=${api}
26515
26603
  initialState=${initialState}
26516
26604
  saveInitialState=${throttle((state) => {