@box/metadata-editor 1.64.5 → 1.64.6

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 (173) hide show
  1. package/dist/chunks/ai-suggestion-field.js +83 -0
  2. package/dist/chunks/autofill-overlay.js +63 -0
  3. package/dist/chunks/combobox-with-api-pagination.js +162 -0
  4. package/dist/chunks/custom-instance-new-field.js +60 -0
  5. package/dist/chunks/custom-instance.js +74 -0
  6. package/dist/chunks/delete-confirmation-modal.js +76 -0
  7. package/dist/chunks/field-action-bar.module.js +6 -8
  8. package/dist/chunks/filter-dropdown-menu.module.js +14 -13
  9. package/dist/chunks/filter-instances-dropdown.js +84 -0
  10. package/dist/chunks/interactive-header-text.js +19 -0
  11. package/dist/chunks/interactive-text.js +17 -0
  12. package/dist/chunks/metadata-editor.js +9 -0
  13. package/dist/chunks/metadata-instance-content.js +29 -0
  14. package/dist/chunks/metadata-instance-entry.js +82 -0
  15. package/dist/chunks/metadata-instance-footer.js +25 -0
  16. package/dist/chunks/metadata-instance-form-autofill-button.js +113 -0
  17. package/dist/chunks/metadata-instance-form-card-wrapper.js +47 -70
  18. package/dist/chunks/metadata-instance-form-footer.js +43 -0
  19. package/dist/chunks/metadata-instance-form-header.js +45 -0
  20. package/dist/chunks/metadata-instance-header.js +52 -0
  21. package/dist/chunks/metadata-instance-list.js +19 -0
  22. package/dist/chunks/metadata-instance.js +59 -0
  23. package/dist/chunks/shared-field-styles.module.js +5 -7
  24. package/dist/chunks/taxonomy-ancestor-status-pill.js +88 -109
  25. package/dist/chunks/types.js +8 -12
  26. package/dist/chunks/update-mode-field-wrapper.js +80 -0
  27. package/dist/chunks/utils.js +57 -54
  28. package/dist/chunks/utils2.js +50 -70
  29. package/dist/esm/index.js +27 -52
  30. package/dist/esm/lib/components/add-metadata-template-dropdown/add-metadata-template-dropdown.js +31 -43
  31. package/dist/esm/lib/components/add-metadata-template-dropdown/index.js +1 -3
  32. package/dist/esm/lib/components/add-metadata-template-dropdown/messages.js +15 -17
  33. package/dist/esm/lib/components/combobox-with-api-pagination/combobox-with-api-pagination.js +2 -205
  34. package/dist/esm/lib/components/combobox-with-api-pagination/index.js +2 -4
  35. package/dist/esm/lib/components/combobox-with-api-pagination/messages.js +31 -33
  36. package/dist/esm/lib/components/combobox-with-api-pagination/request.js +4 -6
  37. package/dist/esm/lib/components/combobox-with-api-pagination/use-async-list.js +113 -128
  38. package/dist/esm/lib/components/combobox-with-api-pagination/utils/is-abort-error.js +8 -10
  39. package/dist/esm/lib/components/combobox-with-api-pagination/utils/use-controllable-state.js +32 -34
  40. package/dist/esm/lib/components/combobox-with-api-pagination/utils/use-intersection-observer.js +72 -82
  41. package/dist/esm/lib/components/filter-dropdown-menu/filter-dropdown-menu-content.js +13 -18
  42. package/dist/esm/lib/components/filter-dropdown-menu/filter-dropdown-menu-empty-state.js +16 -19
  43. package/dist/esm/lib/components/filter-dropdown-menu/filter-dropdown-menu-item.js +12 -17
  44. package/dist/esm/lib/components/filter-dropdown-menu/filter-dropdown-menu-list.js +15 -20
  45. package/dist/esm/lib/components/filter-dropdown-menu/filter-dropdown-menu-root.js +13 -18
  46. package/dist/esm/lib/components/filter-dropdown-menu/filter-dropdown-menu-search.js +36 -44
  47. package/dist/esm/lib/components/filter-dropdown-menu/filter-dropdown-menu-trigger.js +7 -12
  48. package/dist/esm/lib/components/filter-dropdown-menu/index.js +16 -18
  49. package/dist/esm/lib/components/filter-dropdown-menu/messages.js +10 -12
  50. package/dist/esm/lib/components/filter-instances-dropdown/filter-instances-dropdown.js +2 -93
  51. package/dist/esm/lib/components/filter-instances-dropdown/index.js +2 -4
  52. package/dist/esm/lib/components/filter-instances-dropdown/messages.js +18 -20
  53. package/dist/esm/lib/components/interactive-header-text/interactive-header-text.js +2 -28
  54. package/dist/esm/lib/components/interactive-text/interactive-text.js +2 -30
  55. package/dist/esm/lib/components/metadata-editor-fields/components/ai-logo-badge/ai-logo-badge.js +20 -32
  56. package/dist/esm/lib/components/metadata-editor-fields/components/ai-logo-badge/index.js +2 -4
  57. package/dist/esm/lib/components/metadata-editor-fields/components/ai-suggestion-field/ai-suggestion-field.js +2 -110
  58. package/dist/esm/lib/components/metadata-editor-fields/components/ai-suggestion-field/index.js +2 -4
  59. package/dist/esm/lib/components/metadata-editor-fields/components/ai-suggestion-field/messages.js +50 -52
  60. package/dist/esm/lib/components/metadata-editor-fields/components/ai-suggestion-field/utils.js +12 -17
  61. package/dist/esm/lib/components/metadata-editor-fields/components/constants.js +2 -6
  62. package/dist/esm/lib/components/metadata-editor-fields/components/low-confidence-badge/index.js +2 -4
  63. package/dist/esm/lib/components/metadata-editor-fields/components/low-confidence-badge/low-confidence-badge.js +20 -24
  64. package/dist/esm/lib/components/metadata-editor-fields/components/low-confidence-suggestion-field/index.js +2 -4
  65. package/dist/esm/lib/components/metadata-editor-fields/components/low-confidence-suggestion-field/low-confidence-suggestion-field.js +66 -75
  66. package/dist/esm/lib/components/metadata-editor-fields/components/low-confidence-suggestion-field/messages.js +30 -32
  67. package/dist/esm/lib/components/metadata-editor-fields/components/metadata-date-field/metadata-date-field.js +43 -60
  68. package/dist/esm/lib/components/metadata-editor-fields/components/metadata-enum-field/metadata-enum-field.js +47 -71
  69. package/dist/esm/lib/components/metadata-editor-fields/components/metadata-float-field/metadata-float-field.js +32 -54
  70. package/dist/esm/lib/components/metadata-editor-fields/components/metadata-float-field/use-float-validation.js +8 -14
  71. package/dist/esm/lib/components/metadata-editor-fields/components/metadata-multi-select-field/metadata-multi-select-field.js +40 -62
  72. package/dist/esm/lib/components/metadata-editor-fields/components/metadata-string-field/metadata-string-field.js +28 -44
  73. package/dist/esm/lib/components/metadata-editor-fields/components/metadata-taxonomy-field/metadata-taxonomy-field.js +66 -95
  74. package/dist/esm/lib/components/metadata-editor-fields/components/update-mode-field-wrapper/messages.js +30 -32
  75. package/dist/esm/lib/components/metadata-editor-fields/components/update-mode-field-wrapper/mulitple-values-utils.js +7 -11
  76. package/dist/esm/lib/components/metadata-editor-fields/components/update-mode-field-wrapper/update-mode-field-wrapper.js +2 -92
  77. package/dist/esm/lib/components/metadata-editor-fields/editor-field-types.js +30 -34
  78. package/dist/esm/lib/components/metadata-editor-fields/hooks/use-memoized-field-label.js +11 -7
  79. package/dist/esm/lib/components/metadata-editor-fields/hooks/use-review-field-filter.js +35 -40
  80. package/dist/esm/lib/components/metadata-editor-fields/hooks/use-view-reference-tooltip.js +39 -34
  81. package/dist/esm/lib/components/metadata-editor-fields/messages.js +5 -9
  82. package/dist/esm/lib/components/metadata-editor-fields/metadata-editor-field-wrapper.js +186 -176
  83. package/dist/esm/lib/components/metadata-editor-fields/metadata-editor-fields.js +30 -42
  84. package/dist/esm/lib/components/metadata-editor-fields/utils.js +2 -13
  85. package/dist/esm/lib/components/metadata-empty-state/messages.js +42 -44
  86. package/dist/esm/lib/components/metadata-empty-state/metadata-empty-state.js +46 -62
  87. package/dist/esm/lib/components/metadata-instance-editor/index.js +7 -14
  88. package/dist/esm/lib/components/metadata-instance-editor/subcomponents/autofill-overlay/autofill-overlay.js +2 -64
  89. package/dist/esm/lib/components/metadata-instance-editor/subcomponents/autofill-overlay/messages.js +39 -41
  90. package/dist/esm/lib/components/metadata-instance-editor/subcomponents/autofill-overlay/useErrorMessaging.js +21 -26
  91. package/dist/esm/lib/components/metadata-instance-editor/subcomponents/custom-instance/custom-instance.js +2 -86
  92. package/dist/esm/lib/components/metadata-instance-editor/subcomponents/custom-instance/messages.js +15 -17
  93. package/dist/esm/lib/components/metadata-instance-editor/subcomponents/custom-instance-new-field/custom-instance-new-field.js +2 -62
  94. package/dist/esm/lib/components/metadata-instance-editor/subcomponents/custom-instance-new-field/messages.js +42 -44
  95. package/dist/esm/lib/components/metadata-instance-editor/subcomponents/delete-confirmation-modal/delete-confirmation-modal.js +2 -91
  96. package/dist/esm/lib/components/metadata-instance-editor/subcomponents/delete-confirmation-modal/messages.js +50 -52
  97. package/dist/esm/lib/components/metadata-instance-editor/subcomponents/metadata-instance-form/constants.js +2 -7
  98. package/dist/esm/lib/components/metadata-instance-editor/subcomponents/metadata-instance-form/messages.js +0 -1
  99. package/dist/esm/lib/components/metadata-instance-editor/subcomponents/metadata-instance-form/metadata-instance-form-card-wrapper.js +2 -10
  100. package/dist/esm/lib/components/metadata-instance-editor/subcomponents/metadata-instance-form/metadata-instance-form.js +126 -155
  101. package/dist/esm/lib/components/metadata-instance-editor/subcomponents/metadata-instance-form/utils.js +2 -9
  102. package/dist/esm/lib/components/metadata-instance-editor/subcomponents/metadata-instance-form-autofill-button/messages.js +23 -25
  103. package/dist/esm/lib/components/metadata-instance-editor/subcomponents/metadata-instance-form-autofill-button/metadata-instance-form-autofill-button.js +2 -128
  104. package/dist/esm/lib/components/metadata-instance-editor/subcomponents/metadata-instance-form-footer/messages.js +19 -21
  105. package/dist/esm/lib/components/metadata-instance-editor/subcomponents/metadata-instance-form-footer/metadata-instance-form-footer.js +2 -53
  106. package/dist/esm/lib/components/metadata-instance-editor/subcomponents/metadata-instance-form-header/messages.js +6 -10
  107. package/dist/esm/lib/components/metadata-instance-editor/subcomponents/metadata-instance-form-header/metadata-instance-form-header.js +2 -58
  108. package/dist/esm/lib/components/metadata-instance-editor/subcomponents/metadata-instance-form-inline-notice/messages.js +18 -20
  109. package/dist/esm/lib/components/metadata-instance-editor/subcomponents/metadata-instance-form-inline-notice/metadata-instance-form-inline-notice.js +30 -37
  110. package/dist/esm/lib/components/metadata-instance-list/index.js +4 -8
  111. package/dist/esm/lib/components/metadata-instance-list/metadata-instance-list.js +2 -35
  112. package/dist/esm/lib/components/metadata-instance-list/subcomponents/metadata-instance/metadata-instance.js +2 -79
  113. package/dist/esm/lib/components/metadata-instance-list/subcomponents/metadata-instance-content/metadata-instance-content.js +2 -40
  114. package/dist/esm/lib/components/metadata-instance-list/subcomponents/metadata-instance-entry/messages.js +5 -9
  115. package/dist/esm/lib/components/metadata-instance-list/subcomponents/metadata-instance-entry/metadata-entry-display.js +14 -24
  116. package/dist/esm/lib/components/metadata-instance-list/subcomponents/metadata-instance-entry/metadata-instance-entry.js +2 -112
  117. package/dist/esm/lib/components/metadata-instance-list/subcomponents/metadata-instance-entry/taxonomy-entry/messages.js +22 -24
  118. package/dist/esm/lib/components/metadata-instance-list/subcomponents/metadata-instance-entry/taxonomy-entry/taxonomy-ancestor-status-pill.js +2 -11
  119. package/dist/esm/lib/components/metadata-instance-list/subcomponents/metadata-instance-entry/taxonomy-entry/taxonomy-value.js +24 -36
  120. package/dist/esm/lib/components/metadata-instance-list/subcomponents/metadata-instance-footer/messages.js +10 -12
  121. package/dist/esm/lib/components/metadata-instance-list/subcomponents/metadata-instance-footer/metadata-instance-footer.js +2 -31
  122. package/dist/esm/lib/components/metadata-instance-list/subcomponents/metadata-instance-header/messages.js +15 -17
  123. package/dist/esm/lib/components/metadata-instance-list/subcomponents/metadata-instance-header/metadata-instance-header.js +2 -63
  124. package/dist/esm/lib/components/metadata-instance-review-notice/messages.js +30 -32
  125. package/dist/esm/lib/components/metadata-instance-review-notice/metadata-instance-review-notice.js +22 -32
  126. package/dist/esm/lib/components/unsaved-changes-modal/index.js +2 -4
  127. package/dist/esm/lib/components/unsaved-changes-modal/messages.js +23 -25
  128. package/dist/esm/lib/components/unsaved-changes-modal/unsaved-changes-modal.js +41 -57
  129. package/dist/esm/lib/components/unsaved-changes-modal/utils.js +3 -5
  130. package/dist/esm/lib/constants.js +14 -18
  131. package/dist/esm/lib/defaults.js +14 -17
  132. package/dist/esm/lib/mappers.js +22 -28
  133. package/dist/esm/lib/messages.js +123 -126
  134. package/dist/esm/lib/metadata-editor.js +2 -14
  135. package/dist/esm/lib/utils/api-wrapper.js +12 -18
  136. package/dist/esm/lib/utils/autofill-context.js +65 -67
  137. package/dist/esm/lib/utils/check-if-has-bounding-boxes.js +2 -4
  138. package/dist/esm/lib/utils/confidence-score/format-confidence-score-percent.js +3 -5
  139. package/dist/esm/lib/utils/confidence-score/get-confidence-score-tooltip.js +12 -19
  140. package/dist/esm/lib/utils/confidence-score/get-fields-needing-review.js +5 -7
  141. package/dist/esm/lib/utils/confidence-score/index.js +5 -10
  142. package/dist/esm/lib/utils/confidence-score/is-confidence-score-needing-review.js +4 -6
  143. package/dist/esm/lib/utils/confidence-score/messages.js +14 -16
  144. package/dist/esm/lib/utils/convertDate.js +20 -31
  145. package/dist/esm/lib/utils/is-interactive-form-element.js +2 -4
  146. package/dist/esm/lib/utils/utils.js +4 -9
  147. package/dist/styles/autofill-overlay.css +1 -1
  148. package/dist/styles/combobox-with-api-pagination.css +1 -1
  149. package/dist/styles/custom-instance-new-field.css +1 -1
  150. package/dist/styles/custom-instance.css +1 -1
  151. package/dist/styles/delete-confirmation-modal.css +1 -1
  152. package/dist/styles/field-action-bar.css +1 -1
  153. package/dist/styles/filter-dropdown-menu.css +1 -1
  154. package/dist/styles/filter-instances-dropdown.css +1 -1
  155. package/dist/styles/interactive-header-text.css +1 -1
  156. package/dist/styles/interactive-text.css +1 -1
  157. package/dist/styles/metadata-editor.css +1 -0
  158. package/dist/styles/metadata-instance-content.css +1 -1
  159. package/dist/styles/metadata-instance-entry.css +1 -1
  160. package/dist/styles/metadata-instance-footer.css +1 -1
  161. package/dist/styles/metadata-instance-form-autofill-button.css +1 -1
  162. package/dist/styles/metadata-instance-form-card-wrapper.css +1 -1
  163. package/dist/styles/metadata-instance-form-footer.css +1 -1
  164. package/dist/styles/metadata-instance-form-header.css +1 -1
  165. package/dist/styles/metadata-instance-header.css +1 -1
  166. package/dist/styles/metadata-instance-list.css +1 -1
  167. package/dist/styles/shared-field-styles.css +1 -1
  168. package/dist/styles/taxonomy-ancestor-status-pill.css +1 -1
  169. package/dist/styles/update-mode-field-wrapper.css +1 -1
  170. package/dist/styles/utils.css +1 -1
  171. package/dist/types/lib/test-utils/index.d.ts +1 -0
  172. package/dist/types/lib/test-utils/pending-promise.d.ts +19 -0
  173. package/package.json +9 -9
@@ -1,112 +1,91 @@
1
- import { Popover as t, FilterChip as y, InlineNotice as A, TextButton as T, LoadingIndicator as I } from "@box/blueprint-web";
2
- import { Loader as W } from "@box/blueprint-web-assets/icons/Fill";
3
- import V from "lodash/orderBy";
1
+ import e from "../esm/lib/components/metadata-instance-list/subcomponents/metadata-instance-entry/taxonomy-entry/messages.js";
2
+ import { FilterChip as t, InlineNotice as n, LoadingIndicator as r, Popover as i, TextButton as a } from "@box/blueprint-web";
3
+ import { Loader as o } from "@box/blueprint-web-assets/icons/Fill";
4
4
  import { useState as s } from "react";
5
- import { useIntl as B, FormattedMessage as _ } from "react-intl";
6
- import n from "../esm/lib/components/metadata-instance-list/subcomponents/metadata-instance-entry/taxonomy-entry/messages.js";
7
- import { jsxs as l, jsx as o } from "react/jsx-runtime";
8
- import '../styles/taxonomy-ancestor-status-pill.css';const N = "_popoverContentContainer_f0vo4_2", w = "_popoverMainContent_f0vo4_7", E = "_loadingIndicatorWrapper_f0vo4_11", D = "_errorMessageWrapper_f0vo4_18", P = "_errorMessageWrapperText_f0vo4_23", R = "_taxonomyAncestorTable_f0vo4_37", k = "_taxonomyValueGroup_f0vo4_80", K = "_taxonomyValueButton_f0vo4_85", G = "_taxonomyValueLabel_f0vo4_95", a = {
9
- popoverContentContainer: N,
10
- popoverMainContent: w,
11
- loadingIndicatorWrapper: E,
12
- errorMessageWrapper: D,
13
- errorMessageWrapperText: P,
14
- taxonomyAncestorTable: R,
15
- taxonomyValueGroup: k,
16
- taxonomyValueButton: K,
17
- taxonomyValueLabel: G
18
- }, O = {
19
- right: 24
20
- }, j = (r) => {
21
- r.stopPropagation();
22
- }, S = (r) => {
23
- (r.key === "ArrowLeft" || r.key === "ArrowRight") && r.stopPropagation();
5
+ import { FormattedMessage as c, useIntl as l } from "react-intl";
6
+ import { jsx as u, jsxs as d } from "react/jsx-runtime";
7
+ import f from "lodash/orderBy";
8
+ import '../styles/taxonomy-ancestor-status-pill.css';var p = {
9
+ popoverContentContainer: "_popoverContentContainer_f0vo4_2",
10
+ popoverMainContent: "_popoverMainContent_f0vo4_7",
11
+ loadingIndicatorWrapper: "_loadingIndicatorWrapper_f0vo4_11",
12
+ errorMessageWrapper: "_errorMessageWrapper_f0vo4_18",
13
+ errorMessageWrapperText: "_errorMessageWrapperText_f0vo4_23",
14
+ container: "_container_f0vo4_31",
15
+ taxonomyAncestorTable: "_taxonomyAncestorTable_f0vo4_37",
16
+ taxonomyValueGroup: "_taxonomyValueGroup_f0vo4_80",
17
+ taxonomyValueButton: "_taxonomyValueButton_f0vo4_85",
18
+ taxonomyValueLabel: "_taxonomyValueLabel_f0vo4_95"
19
+ }, m = { right: 24 }, h = (e) => {
20
+ e.stopPropagation();
21
+ }, g = (e) => {
22
+ (e.key === "ArrowLeft" || e.key === "ArrowRight") && e.stopPropagation();
24
23
  };
25
- function X({
26
- taxonomyNodeFetcher: r,
27
- scope: f,
28
- taxonomyKey: h,
29
- value: x,
30
- displayValue: c
31
- }) {
32
- const {
33
- formatMessage: i
34
- } = B(), [C, b] = s([]), [p, d] = s(!1), [m, g] = s(!1), [M, u] = s(!1), L = V(C, (e) => e.level), v = async () => {
35
- d(!0), g(!1), u(!0);
36
- try {
37
- const e = await r(f, h, x);
38
- b(e);
39
- } catch {
40
- g(!0);
41
- } finally {
42
- d(!1);
43
- }
44
- };
45
- return /* @__PURE__ */ l(t.Root, {
46
- onOpenChange: u,
47
- open: M,
48
- children: [/* @__PURE__ */ o(t.Trigger, {
49
- children: /* @__PURE__ */ o(y.ChipButton, {
50
- "aria-checked": void 0,
51
- className: a.taxonomyValueButton,
52
- disabled: !r,
53
- onClick: v,
54
- onKeyDown: S,
55
- role: void 0,
56
- value: c,
57
- children: /* @__PURE__ */ o(y.Label, {
58
- className: a.taxonomyValueLabel,
59
- children: c
60
- })
61
- })
62
- }), /* @__PURE__ */ o(t.ContentContainer, {
63
- align: "start",
64
- className: a.popoverContentContainer,
65
- collisionPadding: O,
66
- onEscapeKeyDown: j,
67
- children: /* @__PURE__ */ l(t.MainContent, {
68
- className: a.popoverMainContent,
69
- children: [m && /* @__PURE__ */ l("div", {
70
- className: a.errorMessageWrapper,
71
- children: [/* @__PURE__ */ o(A, {
72
- variant: "error",
73
- variantIconAriaLabel: i(n.loadingResultsErrorIconLabel),
74
- children: /* @__PURE__ */ o(_, {
75
- ...n.loadingResultsErrorMessage
76
- })
77
- }), /* @__PURE__ */ o(T, {
78
- className: a.errorMessageWrapperText,
79
- icon: W,
80
- onClick: v,
81
- "data-target-id": "TextButton-loadingResultsErrorAction",
82
- children: i(n.loadingResultsErrorAction)
83
- })]
84
- }), p && /* @__PURE__ */ o("div", {
85
- className: a.loadingIndicatorWrapper,
86
- children: /* @__PURE__ */ o(I, {
87
- "aria-label": i(n.loadingAriaLabel),
88
- size: "large"
89
- })
90
- }), !m && !p && /* @__PURE__ */ o("table", {
91
- className: a.taxonomyAncestorTable,
92
- children: /* @__PURE__ */ o("tbody", {
93
- children: L.map((e) => /* @__PURE__ */ l("tr", {
94
- children: [/* @__PURE__ */ o("th", {
95
- scope: "row",
96
- children: e.levelName
97
- }), /* @__PURE__ */ o("td", {
98
- children: e.levelValue || /* @__PURE__ */ o(_, {
99
- ...n.emptyAncestorLevelValue
100
- })
101
- })]
102
- }, e.id || e.level))
103
- })
104
- })]
105
- })
106
- })]
107
- });
24
+ function _({ taxonomyNodeFetcher: _, scope: v, taxonomyKey: y, value: b, displayValue: x }) {
25
+ let { formatMessage: S } = l(), [C, w] = s([]), [T, E] = s(!1), [D, O] = s(!1), [k, A] = s(!1), j = f(C, (e) => e.level), M = async () => {
26
+ E(!0), O(!1), A(!0);
27
+ try {
28
+ w(await _(v, y, b));
29
+ } catch {
30
+ O(!0);
31
+ } finally {
32
+ E(!1);
33
+ }
34
+ };
35
+ return /* @__PURE__ */ d(i.Root, {
36
+ onOpenChange: A,
37
+ open: k,
38
+ children: [/* @__PURE__ */ u(i.Trigger, { children: /* @__PURE__ */ u(t.ChipButton, {
39
+ "aria-checked": void 0,
40
+ className: p.taxonomyValueButton,
41
+ disabled: !_,
42
+ onClick: M,
43
+ onKeyDown: g,
44
+ role: void 0,
45
+ value: x,
46
+ children: /* @__PURE__ */ u(t.Label, {
47
+ className: p.taxonomyValueLabel,
48
+ children: x
49
+ })
50
+ }) }), /* @__PURE__ */ u(i.ContentContainer, {
51
+ align: "start",
52
+ className: p.popoverContentContainer,
53
+ collisionPadding: m,
54
+ onEscapeKeyDown: h,
55
+ children: /* @__PURE__ */ d(i.MainContent, {
56
+ className: p.popoverMainContent,
57
+ children: [
58
+ D && /* @__PURE__ */ d("div", {
59
+ className: p.errorMessageWrapper,
60
+ children: [/* @__PURE__ */ u(n, {
61
+ variant: "error",
62
+ variantIconAriaLabel: S(e.loadingResultsErrorIconLabel),
63
+ children: /* @__PURE__ */ u(c, { ...e.loadingResultsErrorMessage })
64
+ }), /* @__PURE__ */ u(a, {
65
+ className: p.errorMessageWrapperText,
66
+ icon: o,
67
+ onClick: M,
68
+ "data-target-id": "TextButton-loadingResultsErrorAction",
69
+ children: S(e.loadingResultsErrorAction)
70
+ })]
71
+ }),
72
+ T && /* @__PURE__ */ u("div", {
73
+ className: p.loadingIndicatorWrapper,
74
+ children: /* @__PURE__ */ u(r, {
75
+ "aria-label": S(e.loadingAriaLabel),
76
+ size: "large"
77
+ })
78
+ }),
79
+ !D && !T && /* @__PURE__ */ u("table", {
80
+ className: p.taxonomyAncestorTable,
81
+ children: /* @__PURE__ */ u("tbody", { children: j.map((t) => /* @__PURE__ */ d("tr", { children: [/* @__PURE__ */ u("th", {
82
+ scope: "row",
83
+ children: t.levelName
84
+ }), /* @__PURE__ */ u("td", { children: t.levelValue || /* @__PURE__ */ u(c, { ...e.emptyAncestorLevelValue }) })] }, t.id || t.level)) })
85
+ })
86
+ ]
87
+ })
88
+ })]
89
+ });
108
90
  }
109
- export {
110
- X as T,
111
- a as s
112
- };
91
+ export { p as n, _ as t };
@@ -1,12 +1,8 @@
1
- let r = /* @__PURE__ */ (function(e) {
2
- return e.ClearAndReplace = "clearAndReplace", e.RemoveEntered = "removeEntered", e.ReplaceEntered = "replaceEntered", e.Append = "append", e;
3
- })({}), n = /* @__PURE__ */ (function(e) {
4
- return e.Initial = "INITIAL", e.Pending = "PENDING", e.Applied = "APPLIED", e;
5
- })({}), l = /* @__PURE__ */ (function(e) {
6
- return e.Low = "LOW", e.Medium = "MEDIUM", e.High = "HIGH", e;
7
- })({});
8
- export {
9
- n as A,
10
- l as C,
11
- r as U
12
- };
1
+ var e = /* @__PURE__ */ function(e) {
2
+ return e.ClearAndReplace = "clearAndReplace", e.RemoveEntered = "removeEntered", e.ReplaceEntered = "replaceEntered", e.Append = "append", e;
3
+ }({}), t = /* @__PURE__ */ function(e) {
4
+ return e.Initial = "INITIAL", e.Pending = "PENDING", e.Applied = "APPLIED", e;
5
+ }({}), n = /* @__PURE__ */ function(e) {
6
+ return e.Low = "LOW", e.Medium = "MEDIUM", e.High = "HIGH", e;
7
+ }({});
8
+ export { n, e as r, t };
@@ -0,0 +1,80 @@
1
+ import { MULTI_VALUE_DEFAULT_OPTION as e } from "../esm/lib/components/metadata-editor-fields/components/update-mode-field-wrapper/mulitple-values-utils.js";
2
+ import { r as t } from "./types.js";
3
+ import { messages as n } from "../esm/lib/components/metadata-editor-fields/components/update-mode-field-wrapper/messages.js";
4
+ import { IconButton as r, Radio as i } from "@box/blueprint-web";
5
+ import { Settings as a, XMark as o } from "@box/blueprint-web-assets/icons/Fill";
6
+ import s from "react";
7
+ import { useIntl as c } from "react-intl";
8
+ import { jsx as l, jsxs as u } from "react/jsx-runtime";
9
+ import d from "clsx";
10
+ import { Field as f, getIn as p, useFormikContext as m } from "formik";
11
+ import '../styles/update-mode-field-wrapper.css';var h = {
12
+ wrapperContianer: "_wrapperContianer_19nqy_1",
13
+ fieldContainer: "_fieldContainer_19nqy_6",
14
+ field: "_field_19nqy_6",
15
+ collapseButton: "_collapseButton_19nqy_14",
16
+ radioContainer: "_radioContainer_19nqy_20",
17
+ additionalFieldContainer: "_additionalFieldContainer_19nqy_23",
18
+ hidden: "_hidden_19nqy_27"
19
+ }, g = (e) => e === t.ReplaceEntered, _ = (e, t) => e === "string" || e === "multiSelect" || t, v = ({ children: v, fieldNamePrefix: y, fieldType: b, isTaxonomyMultiSelect: x }) => {
20
+ let { setFieldValue: S, values: C } = m(), w = c(), T = `${y}.updateMode.mode`, E = p(C, T), D = v && s.Children.only(v), O = p(C, `${y}.options`, []).filter((t) => t.id !== e.id).map(({ key: e }) => e), k = p(C, `${y}.updateMode.isOpened`);
21
+ return /* @__PURE__ */ u("div", {
22
+ className: h.wrapperContianer,
23
+ children: [/* @__PURE__ */ u("div", {
24
+ className: h.fieldContainer,
25
+ children: [/* @__PURE__ */ l("span", {
26
+ className: h.field,
27
+ children: v
28
+ }), /* @__PURE__ */ l(r, {
29
+ "aria-label": w.formatMessage(n.toggleUpdateModeSelectiorAriaLabel),
30
+ className: h.collapseButton,
31
+ "data-testid": `${D.props.label}-update-mode-toggle`,
32
+ icon: k ? o : a,
33
+ onClick: () => {
34
+ S(`${y}.updateMode.isOpened`, !k);
35
+ },
36
+ size: "small",
37
+ "data-target-id": "IconButton-toggleUpdateModeSelectiorAriaLabel"
38
+ })]
39
+ }), /* @__PURE__ */ u("div", {
40
+ className: d(h.radioContainer, { [h.hidden]: !k }),
41
+ children: [/* @__PURE__ */ l(f, {
42
+ name: `${y}.updateMode.mode`,
43
+ children: ({ field: e }) => /* @__PURE__ */ u(i.Group, {
44
+ "data-testid": `${D.props.label}-radio-group`,
45
+ loop: !0,
46
+ onValueChange: (e) => S(T, e),
47
+ orientation: "vertical",
48
+ value: e.value,
49
+ children: [
50
+ _(b, x) && /* @__PURE__ */ l(i.Item, {
51
+ label: w.formatMessage(n.append),
52
+ value: t.Append
53
+ }),
54
+ /* @__PURE__ */ l(i.Item, {
55
+ label: w.formatMessage(n.clearAndReplace),
56
+ value: t.ClearAndReplace
57
+ }),
58
+ /* @__PURE__ */ l(i.Item, {
59
+ label: w.formatMessage(n.removeEntered),
60
+ value: t.RemoveEntered
61
+ }),
62
+ /* @__PURE__ */ l(i.Item, {
63
+ label: w.formatMessage(n.replaceEntered),
64
+ value: t.ReplaceEntered
65
+ })
66
+ ]
67
+ })
68
+ }), g(E) && D && /* @__PURE__ */ l("div", {
69
+ className: h.additionalFieldContainer,
70
+ children: /* @__PURE__ */ s.cloneElement(D, {
71
+ updateModePrefix: `${y}.updateMode`,
72
+ options: O,
73
+ label: w.formatMessage(n.with)
74
+ })
75
+ })]
76
+ })]
77
+ });
78
+ };
79
+ v.displayName = "UpdateModeFieldWrapper";
80
+ export { v as t };
@@ -1,55 +1,58 @@
1
- import g from "lodash/isArray";
2
- import h from "lodash/isEmpty";
3
- import f from "lodash/isEqual";
4
- import { TEMPLATE_CUSTOM_PROPERTIES as m } from "../esm/lib/constants.js";
5
- const i = {
6
- ADD: "add",
7
- REMOVE: "remove",
8
- REPLACE: "replace",
9
- TEST: "test"
10
- }, A = "AI_ACCEPTED", O = (t, o) => t.value === o.value && t.level === o.level && t.isAccepted === o.isAccepted, p = (t) => t.value === void 0 || t.value === null || t.value === "" || g(t.value) && h(t.value), l = (t, o, c) => {
11
- const n = o.confidenceScore, a = c.confidenceScore;
12
- return a ? n && O(n, a) ? [] : T(t, a) : [];
13
- }, T = (t, o) => {
14
- const c = [];
15
- return o.isAccepted && c.push(s(`${t}/process`, A)), c.push(s(`${t}/confidenceScore`, o.value), s(`${t}/confidenceLevel`, o.level)), c;
16
- }, C = (t, o, c) => {
17
- const n = o.targetLocation, a = c.targetLocation, v = o.confidenceScore?.isAccepted ?? !1, E = c.confidenceScore?.isAccepted ?? !1, e = !v && E;
18
- return a ? !f(n, a) || e ? [s(`${t}/targetLocation`, JSON.stringify(a))] : [] : [];
19
- }, D = (t, o) => {
20
- const c = [], n = t.metadata.fields, a = o.templateKey === m, v = new Map(o.fields.map((e) => [e.key, e])), E = new Map(n.map((e) => [e.key, e]));
21
- return n.forEach((e) => {
22
- const r = v.get(e.key);
23
- if (!r) {
24
- c.push(s(e.key, u(e)));
25
- return;
26
- }
27
- if (f(e, r))
28
- return;
29
- const y = !f(e.value, r.value);
30
- !a && p(r) && !p(e) ? c.push(s(e.key, u(e))) : (!a && y && r.value !== null && !p(e) || a && y) && (c.push(S(r.key, u(r))), c.push(L(e.key, u(e)))), c.push(...l(e.key, r, e)), c.push(...C(e.key, r, e));
31
- }), o.fields.forEach((e) => {
32
- const r = E.get(e.key);
33
- (!r || !a && p(r) && !p(e)) && (c.push(S(e.key, u(e))), c.push(k(e.key)));
34
- }), c;
35
- }, u = (t) => t.type === "float" ? Number(t.value) : t.type === "taxonomy" ? t.value.map((o) => o.value) : t.type === "date" && typeof t.value == "string" ? new Date(t.value).toISOString() : t.value, S = (t, o) => ({
36
- op: i.TEST,
37
- path: `/${t}`,
38
- value: o
39
- }), s = (t, o) => ({
40
- op: i.ADD,
41
- path: `/${t}`,
42
- value: o
43
- }), k = (t) => ({
44
- op: i.REMOVE,
45
- path: `/${t}`
46
- }), L = (t, o) => ({
47
- op: i.REPLACE,
48
- path: `/${t}`,
49
- value: o
50
- });
51
- export {
52
- i as J,
53
- D as c,
54
- u as g
1
+ import { isConfidenceScoreNeedingReview as e } from "../esm/lib/utils/confidence-score/is-confidence-score-needing-review.js";
2
+ import { convertISOStringtoRFC3339String as t } from "../esm/lib/utils/convertDate.js";
3
+ import { t as n } from "./interactive-text.js";
4
+ import { AiLogoBadge as r } from "../esm/lib/components/metadata-editor-fields/components/ai-logo-badge/ai-logo-badge.js";
5
+ import { LowConfidenceBadge as i } from "../esm/lib/components/metadata-editor-fields/components/low-confidence-badge/low-confidence-badge.js";
6
+ import { createElement as a, memo as o } from "react";
7
+ import { jsx as s, jsxs as c } from "react/jsx-runtime";
8
+ import l from "clsx";
9
+ import '../styles/utils.css';var u = {
10
+ noAttributesText: "_noAttributesText_1lpn0_2",
11
+ fieldWrapper: "_fieldWrapper_1lpn0_6",
12
+ hasSuggestion: "_hasSuggestion_1lpn0_11",
13
+ hasConfidenceReview: "_hasConfidenceReview_1lpn0_16",
14
+ error: "_error_1lpn0_25",
15
+ dateField: "_dateField_1lpn0_44",
16
+ aiApproved: "_aiApproved_1lpn0_49",
17
+ comboboxContainer: "_comboboxContainer_1lpn0_49",
18
+ labelWrapper: "_labelWrapper_1lpn0_95",
19
+ labelText: "_labelText_1lpn0_101",
20
+ labelTruncated: "_labelTruncated_1lpn0_104",
21
+ labelIcon: "_labelIcon_1lpn0_111"
22
+ }, d = /* @__PURE__ */ o(function({ fieldName: t, fieldDescription: o, isAiSuggestionApplied: d, as: f, confidenceScore: p, labelProps: m }) {
23
+ let { className: h, ...g } = m, _ = l(h || u.labelText, u.labelTruncated), v = !!p && e(p), y = () => p && v ? /* @__PURE__ */ s(i, {}) : d || p ? /* @__PURE__ */ s(r, {
24
+ className: u.labelIcon,
25
+ confidenceScore: p
26
+ }) : null;
27
+ return /* @__PURE__ */ c("div", {
28
+ className: u.labelWrapper,
29
+ children: [o ? /* @__PURE__ */ s(n, {
30
+ as: f,
31
+ className: _,
32
+ tooltipText: o,
33
+ ...g,
34
+ children: t
35
+ }) : /* @__PURE__ */ a(f, {
36
+ className: _,
37
+ ...g
38
+ }, t), y()]
39
+ });
40
+ }, (e, t) => {
41
+ let n = e.labelProps, r = t.labelProps;
42
+ return e.fieldName === t.fieldName && e.fieldDescription === t.fieldDescription && e.isAiSuggestionApplied === t.isAiSuggestionApplied && e.confidenceScore === t.confidenceScore && e.as === t.as && n.className === r.className && n.htmlFor === r.htmlFor && n.id === r.id;
43
+ }), f = (e, t, n = !1, r = "label", i) => (a) => /* @__PURE__ */ s(d, {
44
+ as: r,
45
+ confidenceScore: i,
46
+ fieldDescription: t,
47
+ fieldName: e,
48
+ isAiSuggestionApplied: n,
49
+ labelProps: a
50
+ }), p = (e) => {
51
+ try {
52
+ let n = t(e), r = new Date(n);
53
+ return isNaN(r.getTime()) ? null : n;
54
+ } catch {
55
+ return null;
56
+ }
55
57
  };
58
+ export { p as n, u as r, f as t };
@@ -1,70 +1,50 @@
1
- import b from "clsx";
2
- import { memo as u, createElement as f } from "react";
3
- import { convertISOStringtoRFC3339String as g } from "../esm/lib/utils/convertDate.js";
4
- import T from "../esm/lib/components/interactive-text/interactive-text.js";
5
- import { jsx as r, jsxs as N } from "react/jsx-runtime";
6
- import { isConfidenceScoreNeedingReview as h } from "../esm/lib/utils/confidence-score/is-confidence-score-needing-review.js";
7
- import { LowConfidenceBadge as A } from "../esm/lib/components/metadata-editor-fields/components/low-confidence-badge/low-confidence-badge.js";
8
- import { AiLogoBadge as C } from "../esm/lib/components/metadata-editor-fields/components/ai-logo-badge/ai-logo-badge.js";
9
- import '../styles/utils.css';const S = "_noAttributesText_1lpn0_2", x = "_fieldWrapper_1lpn0_6", L = "_hasSuggestion_1lpn0_11", w = "_hasConfidenceReview_1lpn0_16", F = "_dateField_1lpn0_44", W = "_aiApproved_1lpn0_49", I = "_labelWrapper_1lpn0_95", v = "_labelText_1lpn0_101", P = "_labelTruncated_1lpn0_104", R = "_labelIcon_1lpn0_111", s = {
10
- noAttributesText: S,
11
- fieldWrapper: x,
12
- hasSuggestion: L,
13
- hasConfidenceReview: w,
14
- dateField: F,
15
- aiApproved: W,
16
- labelWrapper: I,
17
- labelText: v,
18
- labelTruncated: P,
19
- labelIcon: R
20
- }, D = /* @__PURE__ */ u(function({
21
- fieldName: e,
22
- fieldDescription: l,
23
- isAiSuggestionApplied: n,
24
- as: o,
25
- confidenceScore: a,
26
- labelProps: p
27
- }) {
28
- const {
29
- className: d,
30
- ...i
31
- } = p, c = b(d || s.labelText, s.labelTruncated), m = !!a && h(a), _ = () => a && m ? /* @__PURE__ */ r(A, {}) : n || a ? /* @__PURE__ */ r(C, {
32
- className: s.labelIcon,
33
- confidenceScore: a
34
- }) : null;
35
- return /* @__PURE__ */ N("div", {
36
- className: s.labelWrapper,
37
- children: [l ? /* @__PURE__ */ r(T, {
38
- as: o,
39
- className: c,
40
- tooltipText: l,
41
- ...i,
42
- children: e
43
- }) : /* @__PURE__ */ f(o, {
44
- className: c,
45
- ...i
46
- }, e), _()]
47
- });
48
- }, (t, e) => {
49
- const l = t.labelProps, n = e.labelProps;
50
- return t.fieldName === e.fieldName && t.fieldDescription === e.fieldDescription && t.isAiSuggestionApplied === e.isAiSuggestionApplied && t.confidenceScore === e.confidenceScore && t.as === e.as && l.className === n.className && l.htmlFor === n.htmlFor && l.id === n.id;
51
- }), G = (t, e, l = !1, n = "label", o) => (a) => /* @__PURE__ */ r(D, {
52
- as: n,
53
- confidenceScore: o,
54
- fieldDescription: e,
55
- fieldName: t,
56
- isAiSuggestionApplied: l,
57
- labelProps: a
58
- }), H = (t) => {
59
- try {
60
- const e = g(t), l = new Date(e);
61
- return isNaN(l.getTime()) ? null : e;
62
- } catch {
63
- return null;
64
- }
65
- };
66
- export {
67
- G as g,
68
- s,
69
- H as t
70
- };
1
+ import { TEMPLATE_CUSTOM_PROPERTIES as e } from "../esm/lib/constants.js";
2
+ import t from "lodash/isEqual";
3
+ import n from "lodash/isArray";
4
+ import r from "lodash/isEmpty";
5
+ var i = {
6
+ ADD: "add",
7
+ REMOVE: "remove",
8
+ REPLACE: "replace",
9
+ TEST: "test"
10
+ }, a = "AI_ACCEPTED", o = (e, t) => e.value === t.value && e.level === t.level && e.isAccepted === t.isAccepted, s = (e) => e.value === void 0 || e.value === null || e.value === "" || n(e.value) && r(e.value), c = (e, t, n) => {
11
+ let r = t.confidenceScore, i = n.confidenceScore;
12
+ return !i || r && o(r, i) ? [] : l(e, i);
13
+ }, l = (e, t) => {
14
+ let n = [];
15
+ return t.isAccepted && n.push(m(`${e}/process`, a)), n.push(m(`${e}/confidenceScore`, t.value), m(`${e}/confidenceLevel`, t.level)), n;
16
+ }, u = (e, n, r) => {
17
+ let i = n.targetLocation, a = r.targetLocation, o = n.confidenceScore?.isAccepted ?? !1, s = r.confidenceScore?.isAccepted ?? !1, c = !o && s;
18
+ return a && (!t(i, a) || c) ? [m(`${e}/targetLocation`, JSON.stringify(a))] : [];
19
+ }, d = (n, r) => {
20
+ let i = [], a = n.metadata.fields, o = r.templateKey === e, l = new Map(r.fields.map((e) => [e.key, e])), d = new Map(a.map((e) => [e.key, e]));
21
+ return a.forEach((e) => {
22
+ let n = l.get(e.key);
23
+ if (!n) {
24
+ i.push(m(e.key, f(e)));
25
+ return;
26
+ }
27
+ if (t(e, n)) return;
28
+ let r = !t(e.value, n.value);
29
+ !o && s(n) && !s(e) ? i.push(m(e.key, f(e))) : (!o && r && n.value !== null && !s(e) || o && r) && (i.push(p(n.key, f(n))), i.push(g(e.key, f(e)))), i.push(...c(e.key, n, e)), i.push(...u(e.key, n, e));
30
+ }), r.fields.forEach((e) => {
31
+ let t = d.get(e.key);
32
+ (!t || !o && s(t) && !s(e)) && (i.push(p(e.key, f(e))), i.push(h(e.key)));
33
+ }), i;
34
+ }, f = (e) => e.type === "float" ? Number(e.value) : e.type === "taxonomy" ? e.value.map((e) => e.value) : e.type === "date" && typeof e.value == "string" ? new Date(e.value).toISOString() : e.value, p = (e, t) => ({
35
+ op: i.TEST,
36
+ path: `/${e}`,
37
+ value: t
38
+ }), m = (e, t) => ({
39
+ op: i.ADD,
40
+ path: `/${e}`,
41
+ value: t
42
+ }), h = (e) => ({
43
+ op: i.REMOVE,
44
+ path: `/${e}`
45
+ }), g = (e, t) => ({
46
+ op: i.REPLACE,
47
+ path: `/${e}`,
48
+ value: t
49
+ });
50
+ export { f as n, i as r, d as t };
package/dist/esm/index.js CHANGED
@@ -1,52 +1,27 @@
1
- import { FilterDropdownMenu as o } from "./lib/components/filter-dropdown-menu/index.js";
2
- import { MULTI_VALUE_DEFAULT_OPTION as r, MULTI_VALUE_DEFAULT_TAXONOMY_OPTION as n, MULTI_VALUE_DEFAULT_VALUE as p } from "./lib/components/metadata-editor-fields/components/update-mode-field-wrapper/mulitple-values-utils.js";
3
- import { MetadataEmptyState as m } from "./lib/components/metadata-empty-state/metadata-empty-state.js";
4
- import { defaultInitialValues as x, defaultMetadataValueMap as i } from "./lib/defaults.js";
5
- import { MetadataEditor as s } from "./lib/metadata-editor.js";
6
- import { A, C as I, U } from "../chunks/types.js";
7
- import { withApiWrapper as L } from "./lib/utils/api-wrapper.js";
8
- import { AutofillContext as _, AutofillContextProvider as E, TIMEOUT_10_SECONDS as c, useAutofill as O } from "./lib/utils/autofill-context.js";
9
- import { AddMetadataTemplateDropdown as F } from "./lib/components/add-metadata-template-dropdown/add-metadata-template-dropdown.js";
10
- import { ComboboxWithApiPagination as N } from "./lib/components/combobox-with-api-pagination/combobox-with-api-pagination.js";
11
- import { CustomInstanceNewField as V } from "./lib/components/metadata-instance-editor/subcomponents/custom-instance-new-field/custom-instance-new-field.js";
12
- import { DeleteConfirmationModal as P } from "./lib/components/metadata-instance-editor/subcomponents/delete-confirmation-modal/delete-confirmation-modal.js";
13
- import { FilterInstancesDropdown as h } from "./lib/components/filter-instances-dropdown/filter-instances-dropdown.js";
14
- import { J as b } from "../chunks/utils.js";
15
- import { MetadataInstance as J } from "./lib/components/metadata-instance-list/subcomponents/metadata-instance/metadata-instance.js";
16
- import { MetadataInstanceForm as y } from "./lib/components/metadata-instance-editor/subcomponents/metadata-instance-form/metadata-instance-form.js";
17
- import { MetadataInstanceFormAutofillButton as X } from "./lib/components/metadata-instance-editor/subcomponents/metadata-instance-form-autofill-button/metadata-instance-form-autofill-button.js";
18
- import { MetadataInstanceFormHeader as j } from "./lib/components/metadata-instance-editor/subcomponents/metadata-instance-form-header/metadata-instance-form-header.js";
19
- import { MetadataInstanceHeader as q } from "./lib/components/metadata-instance-list/subcomponents/metadata-instance-header/metadata-instance-header.js";
20
- import { MetadataInstanceList as G } from "./lib/components/metadata-instance-list/metadata-instance-list.js";
21
- import { UnsavedChangesModal as Q } from "./lib/components/unsaved-changes-modal/unsaved-changes-modal.js";
22
- export {
23
- F as AddMetadataTemplateDropdown,
24
- A as AiSuggestionState,
25
- _ as AutofillContext,
26
- E as AutofillContextProvider,
27
- N as ComboboxWithApiPagination,
28
- I as ConfidenceLevel,
29
- V as CustomInstanceNewField,
30
- P as DeleteConfirmationModal,
31
- o as FilterDropdownMenu,
32
- h as FilterInstancesDropdown,
33
- b as JSONPatchOp,
34
- r as MULTI_VALUE_DEFAULT_OPTION,
35
- n as MULTI_VALUE_DEFAULT_TAXONOMY_OPTION,
36
- p as MULTI_VALUE_DEFAULT_VALUE,
37
- s as MetadataEditor,
38
- m as MetadataEmptyState,
39
- J as MetadataInstance,
40
- y as MetadataInstanceForm,
41
- X as MetadataInstanceFormAutofillButton,
42
- j as MetadataInstanceFormHeader,
43
- q as MetadataInstanceHeader,
44
- G as MetadataInstanceList,
45
- c as TIMEOUT_10_SECONDS,
46
- Q as UnsavedChangesModal,
47
- U as UpdateMode,
48
- x as defaultInitialValues,
49
- i as defaultMetadataValueMap,
50
- O as useAutofill,
51
- L as withApiWrapper
52
- };
1
+ import { FilterDropdownMenu as e } from "./lib/components/filter-dropdown-menu/index.js";
2
+ import { AddMetadataTemplateDropdown as t } from "./lib/components/add-metadata-template-dropdown/add-metadata-template-dropdown.js";
3
+ import "./lib/components/add-metadata-template-dropdown/index.js";
4
+ import { t as n } from "../chunks/combobox-with-api-pagination.js";
5
+ import "./lib/components/combobox-with-api-pagination/index.js";
6
+ import { t as r } from "../chunks/filter-instances-dropdown.js";
7
+ import "./lib/components/filter-instances-dropdown/index.js";
8
+ import { MULTI_VALUE_DEFAULT_OPTION as i, MULTI_VALUE_DEFAULT_TAXONOMY_OPTION as a, MULTI_VALUE_DEFAULT_VALUE as o } from "./lib/components/metadata-editor-fields/components/update-mode-field-wrapper/mulitple-values-utils.js";
9
+ import { MetadataEmptyState as s } from "./lib/components/metadata-empty-state/metadata-empty-state.js";
10
+ import { t as c } from "../chunks/custom-instance-new-field.js";
11
+ import { t as l } from "../chunks/delete-confirmation-modal.js";
12
+ import { AutofillContext as u, AutofillContextProvider as d, TIMEOUT_10_SECONDS as f, useAutofill as p } from "./lib/utils/autofill-context.js";
13
+ import { t as m } from "../chunks/metadata-instance-form-autofill-button.js";
14
+ import { n as h, r as g, t as _ } from "../chunks/types.js";
15
+ import { t as v } from "../chunks/metadata-instance-form-header.js";
16
+ import { UnsavedChangesModal as y } from "./lib/components/unsaved-changes-modal/unsaved-changes-modal.js";
17
+ import { r as b } from "../chunks/utils2.js";
18
+ import { MetadataInstanceForm as x } from "./lib/components/metadata-instance-editor/subcomponents/metadata-instance-form/metadata-instance-form.js";
19
+ import "./lib/components/metadata-instance-editor/index.js";
20
+ import { t as S } from "../chunks/metadata-instance-list.js";
21
+ import { t as C } from "../chunks/metadata-instance-header.js";
22
+ import { t as w } from "../chunks/metadata-instance.js";
23
+ import "./lib/components/metadata-instance-list/index.js";
24
+ import { defaultInitialValues as T, defaultMetadataValueMap as E } from "./lib/defaults.js";
25
+ import { t as D } from "../chunks/metadata-editor.js";
26
+ import { withApiWrapper as O } from "./lib/utils/api-wrapper.js";
27
+ export { t as AddMetadataTemplateDropdown, _ as AiSuggestionState, u as AutofillContext, d as AutofillContextProvider, n as ComboboxWithApiPagination, h as ConfidenceLevel, c as CustomInstanceNewField, l as DeleteConfirmationModal, e as FilterDropdownMenu, r as FilterInstancesDropdown, b as JSONPatchOp, i as MULTI_VALUE_DEFAULT_OPTION, a as MULTI_VALUE_DEFAULT_TAXONOMY_OPTION, o as MULTI_VALUE_DEFAULT_VALUE, D as MetadataEditor, s as MetadataEmptyState, w as MetadataInstance, x as MetadataInstanceForm, m as MetadataInstanceFormAutofillButton, v as MetadataInstanceFormHeader, C as MetadataInstanceHeader, S as MetadataInstanceList, f as TIMEOUT_10_SECONDS, y as UnsavedChangesModal, g as UpdateMode, T as defaultInitialValues, E as defaultMetadataValueMap, p as useAutofill, O as withApiWrapper };