@box/metadata-editor 1.32.2 → 1.34.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (83) hide show
  1. package/dist/chunks/types.js +5 -2
  2. package/dist/esm/index.js +38 -37
  3. package/dist/esm/lib/components/metadata-editor-fields/components/metadata-taxonomy-field/metadata-taxonomy-field.js +49 -48
  4. package/dist/esm/lib/components/metadata-editor-fields/metadata-editor-field-wrapper.js +38 -35
  5. package/dist/esm/lib/components/metadata-instance-editor/subcomponents/metadata-instance-form/metadata-instance-form.js +92 -90
  6. package/dist/esm/lib/components/metadata-instance-list/metadata-instance-list.js +13 -11
  7. package/dist/esm/lib/components/metadata-instance-list/subcomponents/metadata-instance/metadata-instance.js +27 -25
  8. package/dist/esm/lib/components/metadata-instance-list/subcomponents/metadata-instance-content/metadata-instance-content.js +11 -9
  9. package/dist/esm/lib/components/metadata-instance-list/subcomponents/metadata-instance-entry/metadata-entry-display.js +9 -7
  10. package/dist/esm/lib/components/metadata-instance-list/subcomponents/metadata-instance-entry/metadata-instance-entry.js +19 -17
  11. package/dist/esm/lib/components/metadata-instance-list/subcomponents/metadata-instance-entry/taxonomy-entry/taxonomy-value.js +21 -19
  12. package/dist/esm/lib/utils/confidence-score/format-confidence-score-percent.js +6 -0
  13. package/dist/esm/lib/utils/confidence-score/get-confidence-score-tooltip.js +25 -0
  14. package/dist/esm/lib/utils/confidence-score/get-fields-needing-review.js +7 -0
  15. package/dist/esm/lib/utils/confidence-score/messages.js +18 -0
  16. package/dist/i18n/bn-IN.js +4 -1
  17. package/dist/i18n/bn-IN.properties +1 -1
  18. package/dist/i18n/da-DK.js +4 -1
  19. package/dist/i18n/da-DK.properties +1 -1
  20. package/dist/i18n/de-DE.js +4 -1
  21. package/dist/i18n/de-DE.properties +1 -1
  22. package/dist/i18n/en-AU.js +3 -0
  23. package/dist/i18n/en-CA.js +3 -0
  24. package/dist/i18n/en-GB.js +3 -0
  25. package/dist/i18n/en-US.js +3 -0
  26. package/dist/i18n/en-US.properties +6 -0
  27. package/dist/i18n/en-x-pseudo.js +133 -130
  28. package/dist/i18n/en-x-pseudo.properties +130 -130
  29. package/dist/i18n/es-419.js +4 -1
  30. package/dist/i18n/es-419.properties +1 -1
  31. package/dist/i18n/es-ES.js +4 -1
  32. package/dist/i18n/es-ES.properties +1 -1
  33. package/dist/i18n/fi-FI.js +4 -1
  34. package/dist/i18n/fi-FI.properties +1 -1
  35. package/dist/i18n/fr-CA.js +4 -1
  36. package/dist/i18n/fr-CA.properties +1 -1
  37. package/dist/i18n/fr-FR.js +4 -1
  38. package/dist/i18n/fr-FR.properties +1 -1
  39. package/dist/i18n/hi-IN.js +4 -1
  40. package/dist/i18n/hi-IN.properties +1 -1
  41. package/dist/i18n/it-IT.js +4 -1
  42. package/dist/i18n/it-IT.properties +1 -1
  43. package/dist/i18n/ja-JP.js +4 -1
  44. package/dist/i18n/ja-JP.properties +1 -1
  45. package/dist/i18n/json/src/lib/utils/confidence-score/messages.json +1 -0
  46. package/dist/i18n/ko-KR.js +4 -1
  47. package/dist/i18n/ko-KR.properties +1 -1
  48. package/dist/i18n/nb-NO.js +4 -1
  49. package/dist/i18n/nb-NO.properties +1 -1
  50. package/dist/i18n/nl-NL.js +4 -1
  51. package/dist/i18n/nl-NL.properties +1 -1
  52. package/dist/i18n/pl-PL.js +4 -1
  53. package/dist/i18n/pl-PL.properties +1 -1
  54. package/dist/i18n/pt-BR.js +4 -1
  55. package/dist/i18n/pt-BR.properties +1 -1
  56. package/dist/i18n/ru-RU.js +4 -1
  57. package/dist/i18n/ru-RU.properties +1 -1
  58. package/dist/i18n/sv-SE.js +4 -1
  59. package/dist/i18n/sv-SE.properties +1 -1
  60. package/dist/i18n/tr-TR.js +4 -1
  61. package/dist/i18n/tr-TR.properties +1 -1
  62. package/dist/i18n/zh-CN.js +4 -1
  63. package/dist/i18n/zh-CN.properties +1 -1
  64. package/dist/i18n/zh-TW.js +4 -1
  65. package/dist/i18n/zh-TW.properties +1 -1
  66. package/dist/types/lib/components/metadata-editor-fields/types.d.ts +2 -0
  67. package/dist/types/lib/components/metadata-instance-editor/subcomponents/metadata-instance-form/types.d.ts +2 -0
  68. package/dist/types/lib/components/metadata-instance-list/metadata-instance-list.d.ts +1 -1
  69. package/dist/types/lib/components/metadata-instance-list/subcomponents/metadata-instance/metadata-instance.d.ts +1 -1
  70. package/dist/types/lib/components/metadata-instance-list/subcomponents/metadata-instance/types.d.ts +1 -0
  71. package/dist/types/lib/components/metadata-instance-list/subcomponents/metadata-instance-content/metadata-instance-content.d.ts +1 -1
  72. package/dist/types/lib/components/metadata-instance-list/subcomponents/metadata-instance-content/types.d.ts +1 -0
  73. package/dist/types/lib/components/metadata-instance-list/subcomponents/metadata-instance-entry/metadata-entry-display.d.ts +1 -1
  74. package/dist/types/lib/components/metadata-instance-list/subcomponents/metadata-instance-entry/metadata-instance-entry.d.ts +1 -1
  75. package/dist/types/lib/components/metadata-instance-list/subcomponents/metadata-instance-entry/taxonomy-entry/taxonomy-value.d.ts +1 -1
  76. package/dist/types/lib/components/metadata-instance-list/subcomponents/metadata-instance-entry/types.d.ts +3 -0
  77. package/dist/types/lib/components/metadata-instance-list/types.d.ts +1 -0
  78. package/dist/types/lib/types.d.ts +16 -0
  79. package/dist/types/lib/utils/confidence-score/format-confidence-score-percent.d.ts +13 -0
  80. package/dist/types/lib/utils/confidence-score/get-confidence-score-tooltip.d.ts +10 -0
  81. package/dist/types/lib/utils/confidence-score/get-fields-needing-review.d.ts +7 -0
  82. package/dist/types/lib/utils/confidence-score/messages.d.ts +18 -0
  83. package/package.json +4 -4
@@ -1,11 +1,11 @@
1
- import { ConfidenceScoreContextProvider as d } from "../../utils/confidence-score-context.js";
2
- import { getVisibleTemplates as f } from "../../utils/utils.js";
3
- import { MetadataInstance as l } from "./subcomponents/metadata-instance/metadata-instance.js";
1
+ import { ConfidenceScoreContextProvider as f } from "../../utils/confidence-score-context.js";
2
+ import { getVisibleTemplates as l } from "../../utils/utils.js";
3
+ import { MetadataInstance as p } from "./subcomponents/metadata-instance/metadata-instance.js";
4
4
  import { jsx as t } from "react/jsx-runtime";
5
5
  import "./subcomponents/metadata-instance-header/metadata-instance-header.js";
6
- import '../../../../styles/metadata-instance-list.css';const p = "_metadataInstanceList_bd83w_1", I = {
7
- metadataInstanceList: p
8
- }, v = ({
6
+ import '../../../../styles/metadata-instance-list.css';const I = "_metadataInstanceList_bd83w_1", L = {
7
+ metadataInstanceList: I
8
+ }, C = ({
9
9
  areAiSuggestionsAvailable: e,
10
10
  isAiSuggestionsFeatureEnabled: s,
11
11
  isBetaLanguageEnabled: n,
@@ -13,16 +13,18 @@ import '../../../../styles/metadata-instance-list.css';const p = "_metadataInsta
13
13
  templateInstances: o,
14
14
  taxonomyNodeFetcher: r,
15
15
  isAdvancedExtractAgentEnabled: m = !1,
16
- isConfidenceScoreReviewEnabled: c = !1
17
- }) => /* @__PURE__ */ t(d, {
16
+ isConfidenceScoreReviewEnabled: c = !1,
17
+ isExternallyOwned: d = !1
18
+ }) => /* @__PURE__ */ t(f, {
18
19
  isConfidenceScoreReviewEnabled: c,
19
20
  children: /* @__PURE__ */ t("div", {
20
- className: I.metadataInstanceList,
21
- children: f(o).map((a) => /* @__PURE__ */ t(l, {
21
+ className: L.metadataInstanceList,
22
+ children: l(o).map((a) => /* @__PURE__ */ t(p, {
22
23
  areAiSuggestionsAvailable: e,
23
24
  isAdvancedExtractAgentEnabled: m,
24
25
  isAiSuggestionsFeatureEnabled: s,
25
26
  isBetaLanguageEnabled: n,
27
+ isExternallyOwned: d,
26
28
  onEdit: i,
27
29
  taxonomyNodeFetcher: r,
28
30
  templateInstance: a
@@ -30,5 +32,5 @@ import '../../../../styles/metadata-instance-list.css';const p = "_metadataInsta
30
32
  })
31
33
  });
32
34
  export {
33
- v as MetadataInstanceList
35
+ C as MetadataInstanceList
34
36
  };
@@ -1,54 +1,56 @@
1
- import { Card as S, Divider as n } from "@box/blueprint-web";
2
- import { useState as b } from "react";
3
- import { useAutofill as g } from "../../../../utils/autofill-context.js";
4
- import { MetadataEmptyState as H } from "../../../metadata-empty-state/metadata-empty-state.js";
5
- import { MetadataInstanceContent as _ } from "../metadata-instance-content/metadata-instance-content.js";
6
- import { MetadataInstanceFooter as M } from "../metadata-instance-footer/metadata-instance-footer.js";
7
- import { MetadataInstanceHeader as N } from "../metadata-instance-header/metadata-instance-header.js";
1
+ import { Card as b, Divider as n } from "@box/blueprint-web";
2
+ import { useState as g } from "react";
3
+ import { useAutofill as H } from "../../../../utils/autofill-context.js";
4
+ import { MetadataEmptyState as _ } from "../../../metadata-empty-state/metadata-empty-state.js";
5
+ import { MetadataInstanceContent as M } from "../metadata-instance-content/metadata-instance-content.js";
6
+ import { MetadataInstanceFooter as N } from "../metadata-instance-footer/metadata-instance-footer.js";
7
+ import { MetadataInstanceHeader as x } from "../metadata-instance-header/metadata-instance-header.js";
8
8
  import { jsxs as r, jsx as o, Fragment as u } from "react/jsx-runtime";
9
- import '../../../../../../styles/metadata-instance.css';const x = "_topDivider_tzhlb_1", F = "_bottomDivider_tzhlb_5", p = {
10
- topDivider: x,
11
- bottomDivider: F
12
- }, q = ({
9
+ import '../../../../../../styles/metadata-instance.css';const F = "_topDivider_tzhlb_1", j = "_bottomDivider_tzhlb_5", p = {
10
+ topDivider: F,
11
+ bottomDivider: j
12
+ }, G = ({
13
13
  areAiSuggestionsAvailable: y,
14
14
  isAiSuggestionsFeatureEnabled: l,
15
15
  isBetaLanguageEnabled: c,
16
16
  onEdit: d,
17
17
  templateInstance: t,
18
18
  taxonomyNodeFetcher: h,
19
- isAdvancedExtractAgentEnabled: v = !1
19
+ isAdvancedExtractAgentEnabled: v = !1,
20
+ isExternallyOwned: E
20
21
  }) => {
21
- const i = t.fields, m = (e) => !e.value || Array.isArray(e.value) && e.value.length === 0, E = i.every(m), f = i.some(m), V = i.length > 0, [a, s] = b(!0), {
22
- getAiSuggestions: A
23
- } = g(), D = (e) => {
24
- d(t), A(t.templateKey, t.scope, e);
22
+ const i = t.fields, m = (e) => !e.value || Array.isArray(e.value) && e.value.length === 0, f = i.every(m), V = i.some(m), A = i.length > 0, [a, s] = g(!0), {
23
+ getAiSuggestions: D
24
+ } = H(), S = (e) => {
25
+ d(t), D(t.templateKey, t.scope, e);
25
26
  };
26
- return /* @__PURE__ */ r(S, {
27
- children: [/* @__PURE__ */ o(N, {
27
+ return /* @__PURE__ */ r(b, {
28
+ children: [/* @__PURE__ */ o(x, {
28
29
  areAiSuggestionsAvailable: y,
29
30
  canEdit: t.canEdit,
30
31
  isAdvancedExtractAgentEnabled: v,
31
32
  isAiSuggestionsFeatureEnabled: l,
32
33
  isBetaLanguageEnabled: c,
33
- onAutofill: D,
34
+ onAutofill: S,
34
35
  onEdit: () => d(t),
35
36
  templateName: t?.displayName
36
37
  }), /* @__PURE__ */ o(n, {
37
38
  className: p.topDivider
38
- }), a && E ? /* @__PURE__ */ o(H, {
39
- isAnyEmptyValueHidden: V,
39
+ }), a && f ? /* @__PURE__ */ o(_, {
40
+ isAnyEmptyValueHidden: A,
40
41
  isBoxAiSuggestionsFeatureEnabled: l,
41
42
  level: "instance",
42
43
  onShowEmptyValues: () => s(!1)
43
44
  }) : /* @__PURE__ */ r(u, {
44
- children: [/* @__PURE__ */ o(_, {
45
+ children: [/* @__PURE__ */ o(M, {
46
+ isExternallyOwned: E,
45
47
  shouldHideEmptyValues: a,
46
48
  taxonomyNodeFetcher: h,
47
49
  templateInstance: t
48
- }), f && /* @__PURE__ */ r(u, {
50
+ }), V && /* @__PURE__ */ r(u, {
49
51
  children: [/* @__PURE__ */ o(n, {
50
52
  className: p.bottomDivider
51
- }), /* @__PURE__ */ o(M, {
53
+ }), /* @__PURE__ */ o(N, {
52
54
  isAnyEmptyValueHidden: a,
53
55
  onHideEmptyValues: () => s(!0),
54
56
  onShowEmptyValues: () => s(!1)
@@ -58,5 +60,5 @@ import '../../../../../../styles/metadata-instance.css';const x = "_topDivider_t
58
60
  });
59
61
  };
60
62
  export {
61
- q as MetadataInstance
63
+ G as MetadataInstance
62
64
  };
@@ -1,19 +1,21 @@
1
- import { MetadataInstanceEntry as c } from "../metadata-instance-entry/metadata-instance-entry.js";
1
+ import { MetadataInstanceEntry as m } from "../metadata-instance-entry/metadata-instance-entry.js";
2
2
  import { jsx as a } from "react/jsx-runtime";
3
- import '../../../../../../styles/metadata-instance-content.css';const m = "_metadataInstanceContent_1a9zf_1", r = {
4
- metadataInstanceContent: m
5
- }, d = ({
3
+ import '../../../../../../styles/metadata-instance-content.css';const r = "_metadataInstanceContent_1a9zf_1", p = {
4
+ metadataInstanceContent: r
5
+ }, i = ({
6
6
  shouldHideEmptyValues: n,
7
7
  templateInstance: e,
8
- taxonomyNodeFetcher: o
8
+ taxonomyNodeFetcher: o,
9
+ isExternallyOwned: s
9
10
  }) => {
10
11
  const {
11
- fields: s = []
12
+ fields: c = []
12
13
  } = e;
13
14
  return /* @__PURE__ */ a("div", {
14
- className: r.metadataInstanceContent,
15
- children: s.filter((t) => !t.hidden).map((t) => /* @__PURE__ */ a(c, {
15
+ className: p.metadataInstanceContent,
16
+ children: c.filter((t) => !t.hidden).map((t) => /* @__PURE__ */ a(m, {
16
17
  description: t.description,
18
+ isExternallyOwned: s,
17
19
  name: t.displayName || t.key,
18
20
  scope: t.namespace,
19
21
  shouldHideEmptyValues: n,
@@ -25,5 +27,5 @@ import '../../../../../../styles/metadata-instance-content.css';const m = "_meta
25
27
  });
26
28
  };
27
29
  export {
28
- d as MetadataInstanceContent
30
+ i as MetadataInstanceContent
29
31
  };
@@ -1,23 +1,25 @@
1
- import { Text as y } from "@box/blueprint-web";
2
- import { TaxonomyValue as s } from "./taxonomy-entry/taxonomy-value.js";
1
+ import { Text as s } from "@box/blueprint-web";
2
+ import { TaxonomyValue as x } from "./taxonomy-entry/taxonomy-value.js";
3
3
  import { jsx as r } from "react/jsx-runtime";
4
- const l = ({
4
+ const T = ({
5
5
  type: t,
6
6
  formattedValue: o,
7
7
  value: n,
8
8
  taxonomyNodeFetcher: a,
9
9
  taxonomyKey: i,
10
- scope: m
11
- }) => t === "taxonomy" ? /* @__PURE__ */ r(s, {
10
+ scope: m,
11
+ isExternallyOwned: y
12
+ }) => t === "taxonomy" ? /* @__PURE__ */ r(x, {
13
+ isExternallyOwned: y,
12
14
  scope: m,
13
15
  taxonomyKey: i,
14
16
  taxonomyNodeFetcher: a,
15
17
  value: n
16
- }) : o && /* @__PURE__ */ r(y, {
18
+ }) : o && /* @__PURE__ */ r(s, {
17
19
  as: "p",
18
20
  variant: "bodyDefaultBold",
19
21
  children: o
20
22
  });
21
23
  export {
22
- l as MetadataEntryDisplay
24
+ T as MetadataEntryDisplay
23
25
  };
@@ -1,12 +1,12 @@
1
1
  import { Text as i } from "@box/blueprint-web";
2
- import { FormattedDate as f } from "react-intl";
3
- import { convertISOStringToUTCDate as y } from "../../../../utils/convertDate.js";
4
- import h from "../../../interactive-text/interactive-text.js";
5
- import { MetadataEntryDisplay as u } from "./metadata-entry-display.js";
6
- import { jsxs as p, jsx as r } from "react/jsx-runtime";
7
- import '../../../../../../styles/metadata-instance-entry.css';const x = "_metadataInstanceEntry_gwoh6_1", g = {
8
- metadataInstanceEntry: x
9
- }, j = ({
2
+ import { FormattedDate as y } from "react-intl";
3
+ import { convertISOStringToUTCDate as h } from "../../../../utils/convertDate.js";
4
+ import u from "../../../interactive-text/interactive-text.js";
5
+ import { MetadataEntryDisplay as p } from "./metadata-entry-display.js";
6
+ import { jsxs as x, jsx as r } from "react/jsx-runtime";
7
+ import '../../../../../../styles/metadata-instance-entry.css';const g = "_metadataInstanceEntry_gwoh6_1", D = {
8
+ metadataInstanceEntry: g
9
+ }, B = ({
10
10
  description: n,
11
11
  name: a,
12
12
  shouldHideEmptyValues: c,
@@ -14,7 +14,8 @@ import '../../../../../../styles/metadata-instance-entry.css';const x = "_metada
14
14
  value: t,
15
15
  taxonomyNodeFetcher: s,
16
16
  taxonomyKey: d,
17
- scope: m
17
+ scope: m,
18
+ isExternallyOwned: l
18
19
  }) => {
19
20
  const e = (() => {
20
21
  if (typeof t == "number")
@@ -24,23 +25,23 @@ import '../../../../../../styles/metadata-instance-entry.css';const x = "_metada
24
25
  if (Array.isArray(t))
25
26
  return t.join(", ");
26
27
  if (o === "date" && typeof t == "string") {
27
- const l = y(t);
28
- return /* @__PURE__ */ r(f, {
28
+ const f = h(t);
29
+ return /* @__PURE__ */ r(y, {
29
30
  day: "numeric",
30
31
  month: "long",
31
- value: l,
32
+ value: f,
32
33
  year: "numeric"
33
34
  });
34
35
  }
35
36
  return t;
36
37
  })();
37
- return c && !e ? null : /* @__PURE__ */ p("div", {
38
- className: g.metadataInstanceEntry,
38
+ return c && !e ? null : /* @__PURE__ */ x("div", {
39
+ className: D.metadataInstanceEntry,
39
40
  children: [/* @__PURE__ */ r(i, {
40
41
  as: "h5",
41
42
  color: "textOnLightSecondary",
42
43
  variant: "bodyDefaultBold",
43
- children: n ? /* @__PURE__ */ r(h, {
44
+ children: n ? /* @__PURE__ */ r(u, {
44
45
  as: "span",
45
46
  color: "textOnLightSecondary",
46
47
  tooltipText: n,
@@ -55,8 +56,9 @@ import '../../../../../../styles/metadata-instance-entry.css';const x = "_metada
55
56
  variant: "bodyDefaultBold",
56
57
  children: a
57
58
  })
58
- }), /* @__PURE__ */ r(u, {
59
+ }), /* @__PURE__ */ r(p, {
59
60
  formattedValue: e,
61
+ isExternallyOwned: l,
60
62
  scope: m,
61
63
  taxonomyKey: d,
62
64
  taxonomyNodeFetcher: s,
@@ -66,5 +68,5 @@ import '../../../../../../styles/metadata-instance-entry.css';const x = "_metada
66
68
  });
67
69
  };
68
70
  export {
69
- j as MetadataInstanceEntry
71
+ B as MetadataInstanceEntry
70
72
  };
@@ -1,35 +1,37 @@
1
- import { FilterChip as i } from "@box/blueprint-web";
2
- import { useIntl as p } from "react-intl";
3
- import { messages as u } from "../../../../metadata-editor-fields/components/update-mode-field-wrapper/messages.js";
4
- import { s as y, T as f } from "../../../../../../../chunks/taxonomy-ancestor-status-pill.js";
1
+ import { FilterChip as p } from "@box/blueprint-web";
2
+ import { useIntl as u } from "react-intl";
3
+ import { messages as y } from "../../../../metadata-editor-fields/components/update-mode-field-wrapper/messages.js";
4
+ import { s as d, T as f } from "../../../../../../../chunks/taxonomy-ancestor-status-pill.js";
5
5
  import { MULTI_VALUE_DEFAULT_VALUE as V } from "../../../../metadata-editor-fields/components/update-mode-field-wrapper/mulitple-values-utils.js";
6
- import { jsx as a } from "react/jsx-runtime";
7
- const g = ({
6
+ import { jsx as o } from "react/jsx-runtime";
7
+ const U = ({
8
8
  value: r,
9
9
  taxonomyNodeFetcher: s,
10
10
  taxonomyKey: l,
11
- scope: t
11
+ scope: e,
12
+ isExternallyOwned: t
12
13
  }) => {
13
- const e = p();
14
+ const n = u();
14
15
  if (!r || !Array.isArray(r) || !r.length)
15
16
  return null;
16
- const n = e.formatMessage(u.multipleValues);
17
- return /* @__PURE__ */ a(i.Group, {
18
- className: y.taxonomyValueGroup,
17
+ const m = n.formatMessage(y.multipleValues);
18
+ return /* @__PURE__ */ o(p.Group, {
19
+ className: d.taxonomyValueGroup,
20
+ disabled: t,
19
21
  name: void 0,
20
22
  type: "single",
21
- children: r.map((o) => {
22
- const m = o.displayValue === V ? n : o.displayValue;
23
- return /* @__PURE__ */ a(f, {
24
- displayValue: m,
25
- scope: t,
23
+ children: r.map((a) => {
24
+ const i = a.displayValue === V ? m : a.displayValue;
25
+ return /* @__PURE__ */ o(f, {
26
+ displayValue: i,
27
+ scope: e,
26
28
  taxonomyKey: l,
27
29
  taxonomyNodeFetcher: s,
28
- value: o.value
29
- }, o.value);
30
+ value: a.value
31
+ }, a.value);
30
32
  })
31
33
  });
32
34
  };
33
35
  export {
34
- g as TaxonomyValue
36
+ U as TaxonomyValue
35
37
  };
@@ -0,0 +1,6 @@
1
+ function o(e) {
2
+ return `${Math.floor(e * 100)}%`;
3
+ }
4
+ export {
5
+ o as formatConfidenceScorePercent
6
+ };
@@ -0,0 +1,25 @@
1
+ import { C as t } from "../../../../chunks/types.js";
2
+ import { formatConfidenceScorePercent as i } from "./format-confidence-score-percent.js";
3
+ import c from "./messages.js";
4
+ function p(e, r, n) {
5
+ const o = i(n);
6
+ switch (r) {
7
+ case t.ReviewIsNeeded:
8
+ return e(c.tooltipLowConfidence, {
9
+ score: o
10
+ });
11
+ case t.ReviewedAndAccepted:
12
+ return e(c.tooltipReviewedAndAccepted, {
13
+ score: o
14
+ });
15
+ case t.ReviewIsNotNeeded:
16
+ return e(c.tooltipHighConfidence, {
17
+ score: o
18
+ });
19
+ default:
20
+ return null;
21
+ }
22
+ }
23
+ export {
24
+ p as getConfidenceScoreTooltip
25
+ };
@@ -0,0 +1,7 @@
1
+ import { C as i } from "../../../../chunks/types.js";
2
+ function o(t) {
3
+ return t.filter((e) => !e.hidden && e.confidenceScore?.status === i.ReviewIsNeeded);
4
+ }
5
+ export {
6
+ o as getFieldsNeedingReview
7
+ };
@@ -0,0 +1,18 @@
1
+ import { defineMessages as e } from "react-intl";
2
+ const t = e({
3
+ tooltipLowConfidence: {
4
+ id: "metadataEditor.confidenceScore.tooltipLowConfidence",
5
+ defaultMessage: "Box AI returned low confidence ({score}) level for this extraction. Review the value."
6
+ },
7
+ tooltipReviewedAndAccepted: {
8
+ id: "metadataEditor.confidenceScore.tooltipReviewedAndAccepted",
9
+ defaultMessage: "Confidence score ({score}) has been reviewed and accepted by the user."
10
+ },
11
+ tooltipHighConfidence: {
12
+ id: "metadataEditor.confidenceScore.tooltipHighConfidence",
13
+ defaultMessage: "Box AI returned high confidence ({score}) level for this extraction."
14
+ }
15
+ });
16
+ export {
17
+ t as default
18
+ };
@@ -13,7 +13,7 @@ export default {
13
13
  "groupSharedFeatures.metadataEditor.metadataEditorFields.clearAndReplace": "সব মুছে ফেলুন ও প্রতিস্থাপন করুন",
14
14
  "groupSharedFeatures.metadataEditor.metadataEditorFields.clearSelectedDate": "নির্বাচিত তারিখ মুছে ফেলুন",
15
15
  "groupSharedFeatures.metadataEditor.metadataEditorFields.floatFieldInvalidValue": "অবৈধ ফিল্ড মান",
16
- "groupSharedFeatures.metadataEditor.metadataEditorFields.multipleValues": "Multiple values",
16
+ "groupSharedFeatures.metadataEditor.metadataEditorFields.multipleValues": "একাধিক মান",
17
17
  "groupSharedFeatures.metadataEditor.metadataEditorFields.multiselectPlaceholder": "মান নির্বাচন করুন",
18
18
  "groupSharedFeatures.metadataEditor.metadataEditorFields.noTemplateAtributesError": "এই টেমপ্লেটে কোনো অ্যাট্রিবিউট নেই।",
19
19
  "groupSharedFeatures.metadataEditor.metadataEditorFields.openCalendarLabel": "তারিখ বাছাই করার জন্য ক্যালেন্ডার খুলুন",
@@ -51,6 +51,9 @@ export default {
51
51
  "metadataEditor.autofillButton.tooltip.enhanced": "Box AI (বর্ধিত)-এর মাধ্যমে অটোফিল করুন",
52
52
  "metadataEditor.autofillButton.tooltip.ga": "Box AI-এর মাধ্যমে অটোফিল করুন",
53
53
  "metadataEditor.autofillButton.tooltip.standard": "Box AI (স্ট্যান্ডার্ড)-এর মাধ্যমে অটোফিল করুন",
54
+ "metadataEditor.confidenceScore.tooltipHighConfidence": "Box AI returned high confidence ({score}) level for this extraction.",
55
+ "metadataEditor.confidenceScore.tooltipLowConfidence": "Box AI returned low confidence ({score}) level for this extraction. Review the value.",
56
+ "metadataEditor.confidenceScore.tooltipReviewedAndAccepted": "Confidence score ({score}) has been reviewed and accepted by the user.",
54
57
  "metadataEditor.editInstance.deleteConfirmationModal.body.checkboxLabel": "মেটাডেটার ইনস্ট্যান্স মুছে ফেলা নিশ্চিত করুন",
55
58
  "metadataEditor.editInstance.deleteConfirmationModal.body.firstParagraph": "আপনি কি সত্যিই \"{templateName}\" মেটাডেটা টেমপ্লেট এবং এই ফাইল থেকে এটির সব মান মুছে ফেলতে চান?",
56
59
  "metadataEditor.editInstance.deleteConfirmationModal.body.firstParagraphCheckboxVersion": "আপনি কি নিশ্চিত যে \"{templateName}\" মেটাডেটার ইনস্ট্যান্স এবং এর মান মুছতে চান?",
@@ -27,7 +27,7 @@ groupSharedFeatures.metadataEditor.metadataEditorFields.clearSelectedDate = ন
27
27
  # Error message shown for an invalid field value
28
28
  groupSharedFeatures.metadataEditor.metadataEditorFields.floatFieldInvalidValue = অবৈধ ফিল্ড মান
29
29
  # Placeholder text displayed when editing metadata for multiple items and the selected items have different values for the field
30
- groupSharedFeatures.metadataEditor.metadataEditorFields.multipleValues = Multiple values
30
+ groupSharedFeatures.metadataEditor.metadataEditorFields.multipleValues = একাধিক মান
31
31
  # Placeholder text for the multiselect field
32
32
  groupSharedFeatures.metadataEditor.metadataEditorFields.multiselectPlaceholder = মান নির্বাচন করুন
33
33
  # Error message shown if no attributes are available in the template
@@ -13,7 +13,7 @@ export default {
13
13
  "groupSharedFeatures.metadataEditor.metadataEditorFields.clearAndReplace": "Ryd alle og erstat",
14
14
  "groupSharedFeatures.metadataEditor.metadataEditorFields.clearSelectedDate": "Ryd den valgte dato",
15
15
  "groupSharedFeatures.metadataEditor.metadataEditorFields.floatFieldInvalidValue": "Ugyldig feltværdi",
16
- "groupSharedFeatures.metadataEditor.metadataEditorFields.multipleValues": "Multiple values",
16
+ "groupSharedFeatures.metadataEditor.metadataEditorFields.multipleValues": "Flere værdier",
17
17
  "groupSharedFeatures.metadataEditor.metadataEditorFields.multiselectPlaceholder": "Vælg værdi(er)",
18
18
  "groupSharedFeatures.metadataEditor.metadataEditorFields.noTemplateAtributesError": "Der er ingen attributter i denne skabelon.",
19
19
  "groupSharedFeatures.metadataEditor.metadataEditorFields.openCalendarLabel": "Åbn kalenderen for at vælge en dato",
@@ -51,6 +51,9 @@ export default {
51
51
  "metadataEditor.autofillButton.tooltip.enhanced": "Automatisk udfyldning med Box AI (Forbedret)",
52
52
  "metadataEditor.autofillButton.tooltip.ga": "Automatisk udfyldning med Box AI",
53
53
  "metadataEditor.autofillButton.tooltip.standard": "Automatisk udfyldning med Box AI (Standard)",
54
+ "metadataEditor.confidenceScore.tooltipHighConfidence": "Box AI returned high confidence ({score}) level for this extraction.",
55
+ "metadataEditor.confidenceScore.tooltipLowConfidence": "Box AI returned low confidence ({score}) level for this extraction. Review the value.",
56
+ "metadataEditor.confidenceScore.tooltipReviewedAndAccepted": "Confidence score ({score}) has been reviewed and accepted by the user.",
54
57
  "metadataEditor.editInstance.deleteConfirmationModal.body.checkboxLabel": "Bekræft sletning af metadatainstans",
55
58
  "metadataEditor.editInstance.deleteConfirmationModal.body.firstParagraph": "Er du sikker på, at du vil slette \"{templateName}\" metadataskabelon og alle dens værdier fra denne fil?",
56
59
  "metadataEditor.editInstance.deleteConfirmationModal.body.firstParagraphCheckboxVersion": "Er du sikker på, at du vil slette metadatainstansen \"{templateName}\" og dens værdier?",
@@ -27,7 +27,7 @@ groupSharedFeatures.metadataEditor.metadataEditorFields.clearSelectedDate = Ryd
27
27
  # Error message shown for an invalid field value
28
28
  groupSharedFeatures.metadataEditor.metadataEditorFields.floatFieldInvalidValue = Ugyldig feltværdi
29
29
  # Placeholder text displayed when editing metadata for multiple items and the selected items have different values for the field
30
- groupSharedFeatures.metadataEditor.metadataEditorFields.multipleValues = Multiple values
30
+ groupSharedFeatures.metadataEditor.metadataEditorFields.multipleValues = Flere værdier
31
31
  # Placeholder text for the multiselect field
32
32
  groupSharedFeatures.metadataEditor.metadataEditorFields.multiselectPlaceholder = Vælg værdi(er)
33
33
  # Error message shown if no attributes are available in the template
@@ -13,7 +13,7 @@ export default {
13
13
  "groupSharedFeatures.metadataEditor.metadataEditorFields.clearAndReplace": "Alles löschen und ersetzen",
14
14
  "groupSharedFeatures.metadataEditor.metadataEditorFields.clearSelectedDate": "Ausgewähltes Datum löschen",
15
15
  "groupSharedFeatures.metadataEditor.metadataEditorFields.floatFieldInvalidValue": "Ungültiger Feldwert",
16
- "groupSharedFeatures.metadataEditor.metadataEditorFields.multipleValues": "Multiple values",
16
+ "groupSharedFeatures.metadataEditor.metadataEditorFields.multipleValues": "Mehrere Werte",
17
17
  "groupSharedFeatures.metadataEditor.metadataEditorFields.multiselectPlaceholder": "Wert(e) auswählen",
18
18
  "groupSharedFeatures.metadataEditor.metadataEditorFields.noTemplateAtributesError": "Diese Vorlage enthält keine Attribute.",
19
19
  "groupSharedFeatures.metadataEditor.metadataEditorFields.openCalendarLabel": "Kalender öffnen, um ein Datum auszuwählen",
@@ -51,6 +51,9 @@ export default {
51
51
  "metadataEditor.autofillButton.tooltip.enhanced": "Automatisch ausfüllen mit Box AI (erweitert)",
52
52
  "metadataEditor.autofillButton.tooltip.ga": "Automatisch ausfüllen mit Box AI",
53
53
  "metadataEditor.autofillButton.tooltip.standard": "Automatisch ausfüllen mit Box AI (Standard)",
54
+ "metadataEditor.confidenceScore.tooltipHighConfidence": "Box AI returned high confidence ({score}) level for this extraction.",
55
+ "metadataEditor.confidenceScore.tooltipLowConfidence": "Box AI returned low confidence ({score}) level for this extraction. Review the value.",
56
+ "metadataEditor.confidenceScore.tooltipReviewedAndAccepted": "Confidence score ({score}) has been reviewed and accepted by the user.",
54
57
  "metadataEditor.editInstance.deleteConfirmationModal.body.checkboxLabel": "Löschen der Metadateninstanz bestätigen",
55
58
  "metadataEditor.editInstance.deleteConfirmationModal.body.firstParagraph": "Möchten Sie die Metadaten-Vorlage „{templateName}“ und alle ihre Werte aus dieser Datei wirklich löschen?",
56
59
  "metadataEditor.editInstance.deleteConfirmationModal.body.firstParagraphCheckboxVersion": "Möchten Sie die Metadateninstanz „{templateName}“ und ihre Werte wirklich löschen?",
@@ -27,7 +27,7 @@ groupSharedFeatures.metadataEditor.metadataEditorFields.clearSelectedDate = Ausg
27
27
  # Error message shown for an invalid field value
28
28
  groupSharedFeatures.metadataEditor.metadataEditorFields.floatFieldInvalidValue = Ungültiger Feldwert
29
29
  # Placeholder text displayed when editing metadata for multiple items and the selected items have different values for the field
30
- groupSharedFeatures.metadataEditor.metadataEditorFields.multipleValues = Multiple values
30
+ groupSharedFeatures.metadataEditor.metadataEditorFields.multipleValues = Mehrere Werte
31
31
  # Placeholder text for the multiselect field
32
32
  groupSharedFeatures.metadataEditor.metadataEditorFields.multiselectPlaceholder = Wert(e) auswählen
33
33
  # Error message shown if no attributes are available in the template
@@ -51,6 +51,9 @@ export default {
51
51
  "metadataEditor.autofillButton.tooltip.enhanced": "Autofill with Box AI (Enhanced)",
52
52
  "metadataEditor.autofillButton.tooltip.ga": "Autofill with Box AI",
53
53
  "metadataEditor.autofillButton.tooltip.standard": "Autofill with Box AI (Standard)",
54
+ "metadataEditor.confidenceScore.tooltipHighConfidence": "Box AI returned high confidence ({score}) level for this extraction.",
55
+ "metadataEditor.confidenceScore.tooltipLowConfidence": "Box AI returned low confidence ({score}) level for this extraction. Review the value.",
56
+ "metadataEditor.confidenceScore.tooltipReviewedAndAccepted": "Confidence score ({score}) has been reviewed and accepted by the user.",
54
57
  "metadataEditor.editInstance.deleteConfirmationModal.body.checkboxLabel": "Confirm deletion of Metadata instance",
55
58
  "metadataEditor.editInstance.deleteConfirmationModal.body.firstParagraph": "Are you sure you want to delete the \"{templateName}\" Metadata template, and all of its values from this file?",
56
59
  "metadataEditor.editInstance.deleteConfirmationModal.body.firstParagraphCheckboxVersion": "Are you sure you want to delete the \"{templateName}\" Metadata instance, and its values?",
@@ -51,6 +51,9 @@ export default {
51
51
  "metadataEditor.autofillButton.tooltip.enhanced": "Autofill with Box AI (Enhanced)",
52
52
  "metadataEditor.autofillButton.tooltip.ga": "Autofill with Box AI",
53
53
  "metadataEditor.autofillButton.tooltip.standard": "Autofill with Box AI (Standard)",
54
+ "metadataEditor.confidenceScore.tooltipHighConfidence": "Box AI returned high confidence ({score}) level for this extraction.",
55
+ "metadataEditor.confidenceScore.tooltipLowConfidence": "Box AI returned low confidence ({score}) level for this extraction. Review the value.",
56
+ "metadataEditor.confidenceScore.tooltipReviewedAndAccepted": "Confidence score ({score}) has been reviewed and accepted by the user.",
54
57
  "metadataEditor.editInstance.deleteConfirmationModal.body.checkboxLabel": "Confirm deletion of Metadata instance",
55
58
  "metadataEditor.editInstance.deleteConfirmationModal.body.firstParagraph": "Are you sure you want to delete the \"{templateName}\" Metadata template, and all of its values from this file?",
56
59
  "metadataEditor.editInstance.deleteConfirmationModal.body.firstParagraphCheckboxVersion": "Are you sure you want to delete the \"{templateName}\" Metadata instance, and its values?",
@@ -51,6 +51,9 @@ export default {
51
51
  "metadataEditor.autofillButton.tooltip.enhanced": "Autofill with Box AI (Enhanced)",
52
52
  "metadataEditor.autofillButton.tooltip.ga": "Autofill with Box AI",
53
53
  "metadataEditor.autofillButton.tooltip.standard": "Autofill with Box AI (Standard)",
54
+ "metadataEditor.confidenceScore.tooltipHighConfidence": "Box AI returned high confidence ({score}) level for this extraction.",
55
+ "metadataEditor.confidenceScore.tooltipLowConfidence": "Box AI returned low confidence ({score}) level for this extraction. Review the value.",
56
+ "metadataEditor.confidenceScore.tooltipReviewedAndAccepted": "Confidence score ({score}) has been reviewed and accepted by the user.",
54
57
  "metadataEditor.editInstance.deleteConfirmationModal.body.checkboxLabel": "Confirm deletion of Metadata instance",
55
58
  "metadataEditor.editInstance.deleteConfirmationModal.body.firstParagraph": "Are you sure you want to delete the \"{templateName}\" Metadata template, and all of its values from this file?",
56
59
  "metadataEditor.editInstance.deleteConfirmationModal.body.firstParagraphCheckboxVersion": "Are you sure you want to delete the \"{templateName}\" Metadata instance, and its values?",
@@ -51,6 +51,9 @@ export default {
51
51
  "metadataEditor.autofillButton.tooltip.enhanced": "Autofill with Box AI (Enhanced)",
52
52
  "metadataEditor.autofillButton.tooltip.ga": "Autofill with Box AI",
53
53
  "metadataEditor.autofillButton.tooltip.standard": "Autofill with Box AI (Standard)",
54
+ "metadataEditor.confidenceScore.tooltipHighConfidence": "Box AI returned high confidence ({score}) level for this extraction.",
55
+ "metadataEditor.confidenceScore.tooltipLowConfidence": "Box AI returned low confidence ({score}) level for this extraction. Review the value.",
56
+ "metadataEditor.confidenceScore.tooltipReviewedAndAccepted": "Confidence score ({score}) has been reviewed and accepted by the user.",
54
57
  "metadataEditor.editInstance.deleteConfirmationModal.body.checkboxLabel": "Confirm deletion of Metadata instance",
55
58
  "metadataEditor.editInstance.deleteConfirmationModal.body.firstParagraph": "Are you sure you want to delete the \"{templateName}\" Metadata template, and all of its values from this file?",
56
59
  "metadataEditor.editInstance.deleteConfirmationModal.body.firstParagraphCheckboxVersion": "Are you sure you want to delete the \"{templateName}\" Metadata instance, and its values?",
@@ -102,6 +102,12 @@ metadataEditor.autofillButton.tooltip.enhanced = Autofill with Box AI (Enhanced)
102
102
  metadataEditor.autofillButton.tooltip.ga = Autofill with Box AI
103
103
  # Tooltip for the autofill button when using standard AI agent
104
104
  metadataEditor.autofillButton.tooltip.standard = Autofill with Box AI (Standard)
105
+ # Tooltip message shown when Box AI extraction has high confidence score. {score} is the formatted percentage (e.g., "95%")
106
+ metadataEditor.confidenceScore.tooltipHighConfidence = Box AI returned high confidence ({score}) level for this extraction.
107
+ # Tooltip message shown when Box AI extraction has low confidence score. {score} is the formatted percentage (e.g., "35%")
108
+ metadataEditor.confidenceScore.tooltipLowConfidence = Box AI returned low confidence ({score}) level for this extraction. Review the value.
109
+ # Tooltip message shown when a low confidence extraction has been reviewed and accepted by user
110
+ metadataEditor.confidenceScore.tooltipReviewedAndAccepted = Confidence score ({score}) has been reviewed and accepted by the user.
105
111
  # Label informing how to confirm deletion of the template
106
112
  metadataEditor.editInstance.deleteConfirmationModal.body.checkboxLabel = Confirm deletion of Metadata instance
107
113
  # Paragraph asking user are they sure that they want to delete the template