@delmaredigital/payload-experiments 0.4.0-rc.9 → 0.4.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 (254) hide show
  1. package/README.md +2 -8
  2. package/dist/admin/MetricSourceSelect.js +10 -3
  3. package/dist/admin/armSelect/armSelect.model.d.ts +1 -1
  4. package/dist/admin/blocks/BlockPanel.d.ts +1 -0
  5. package/dist/admin/blocks/BlockPanel.js +75 -29
  6. package/dist/admin/blocks/model.js +5 -4
  7. package/dist/admin/copy/blocks.d.ts +14 -11
  8. package/dist/admin/copy/blocks.js +33 -22
  9. package/dist/admin/copy/goals.d.ts +15 -8
  10. package/dist/admin/copy/goals.js +18 -8
  11. package/dist/admin/copy/newTest.d.ts +10 -7
  12. package/dist/admin/copy/newTest.js +14 -7
  13. package/dist/admin/copy/status.d.ts +1 -1
  14. package/dist/admin/copy/status.js +2 -1
  15. package/dist/admin/pageCollections.d.ts +1 -0
  16. package/dist/admin/pageCollections.js +3 -0
  17. package/dist/admin/placementStatus.model.js +5 -3
  18. package/dist/admin/status.model.d.ts +1 -0
  19. package/dist/admin/status.model.js +2 -1
  20. package/dist/admin/surface/ResultsRoute.js +4 -8
  21. package/dist/admin/surface/SurfaceShell.d.ts +4 -2
  22. package/dist/admin/surface/SurfaceShell.js +28 -3
  23. package/dist/admin/surface/TestRowMenu.d.ts +13 -0
  24. package/dist/admin/surface/TestRowMenu.js +163 -0
  25. package/dist/admin/surface/TestsHome.d.ts +4 -3
  26. package/dist/admin/surface/TestsHome.js +186 -47
  27. package/dist/admin/surface/TestsSurface.js +2 -1
  28. package/dist/admin/surface/goals/DeleteGoalDialog.d.ts +7 -0
  29. package/dist/admin/surface/goals/DeleteGoalDialog.js +42 -0
  30. package/dist/admin/surface/goals/GoalForm.d.ts +1 -0
  31. package/dist/admin/surface/goals/GoalForm.js +280 -198
  32. package/dist/admin/surface/goals/GoalsList.js +102 -33
  33. package/dist/admin/surface/goals/data.d.ts +2 -0
  34. package/dist/admin/surface/goals/data.js +9 -0
  35. package/dist/admin/surface/goals/goals.css +3 -2
  36. package/dist/admin/surface/goals/goals.model.d.ts +2 -2
  37. package/dist/admin/surface/goals/goals.model.js +7 -12
  38. package/dist/admin/surface/home.model.d.ts +15 -8
  39. package/dist/admin/surface/home.model.js +22 -18
  40. package/dist/admin/surface/newTest/NewTest.d.ts +3 -3
  41. package/dist/admin/surface/newTest/NewTest.js +156 -96
  42. package/dist/admin/surface/newTest/PageWizard.d.ts +4 -1
  43. package/dist/admin/surface/newTest/PageWizard.js +93 -68
  44. package/dist/admin/surface/newTest/newTest.css +28 -11
  45. package/dist/admin/surface/results/ResultsHeader.d.ts +1 -1
  46. package/dist/admin/surface/results/ResultsHeader.js +90 -63
  47. package/dist/admin/surface/surface.css +29 -0
  48. package/dist/admin/surface/test/TestPage.js +46 -38
  49. package/dist/admin/surface/useXpStepNav.d.ts +11 -0
  50. package/dist/admin/surface/useXpStepNav.js +14 -0
  51. package/dist/admin/views/TestsSurfaceClient.js +27 -3
  52. package/dist/admin/views/buildSurfaceProps.js +18 -66
  53. package/dist/arms/copy.d.ts +13 -3
  54. package/dist/arms/copy.js +5 -4
  55. package/dist/blocks/createExperimentBlock.js +1 -1
  56. package/dist/blocks/formState.js +1 -1
  57. package/dist/collections/experiments/armInvariants.js +8 -5
  58. package/dist/collections/metrics.js +12 -5
  59. package/dist/collections/serialize.js +3 -2
  60. package/dist/db/pageCopies.d.ts +5 -0
  61. package/dist/db/pageCopies.js +31 -0
  62. package/dist/db/snapshots.d.ts +1 -0
  63. package/dist/endpoints/duplicateOriginal.d.ts +38 -0
  64. package/dist/endpoints/duplicateOriginal.js +414 -0
  65. package/dist/endpoints/editorSurface.js +1 -1
  66. package/dist/endpoints/index.js +20 -0
  67. package/dist/endpoints/pages.js +245 -66
  68. package/dist/endpoints/placementStatus.js +1 -0
  69. package/dist/endpoints/results.js +3 -0
  70. package/dist/endpoints/testVersion.d.ts +2 -0
  71. package/dist/endpoints/testVersion.js +38 -0
  72. package/dist/endpoints/transitions.js +4 -5
  73. package/dist/exports/index.d.ts +1 -1
  74. package/dist/goals/picker/copy.js +1 -1
  75. package/dist/goals/sourceLabel.d.ts +2 -0
  76. package/dist/goals/sourceLabel.js +4 -0
  77. package/dist/hooks/trackPageCopies.d.ts +11 -0
  78. package/dist/hooks/trackPageCopies.js +7 -0
  79. package/dist/labels/arms.d.ts +3 -0
  80. package/dist/labels/arms.js +8 -0
  81. package/dist/options.d.ts +2 -0
  82. package/dist/options.js +18 -2
  83. package/dist/plugin.js +56 -2
  84. package/dist/puck/editor/ConfigureTestDrawer.d.ts +7 -7
  85. package/dist/puck/editor/ConfigureTestDrawer.js +36 -26
  86. package/dist/puck/editor/ExperimentSlotEditor.d.ts +2 -1
  87. package/dist/puck/editor/ExperimentSlotEditor.js +219 -106
  88. package/dist/puck/editor/LeftoverVersions.js +17 -32
  89. package/dist/puck/editor/QuickTestActions.d.ts +2 -2
  90. package/dist/puck/editor/QuickTestActions.js +44 -34
  91. package/dist/puck/editor/ResultsReadout.d.ts +3 -1
  92. package/dist/puck/editor/ResultsReadout.js +28 -16
  93. package/dist/puck/editor/VersionBuilder.d.ts +4 -2
  94. package/dist/puck/editor/VersionBuilder.js +42 -63
  95. package/dist/puck/editor/armWrites.js +1 -1
  96. package/dist/puck/editor/copy.d.ts +10 -6
  97. package/dist/puck/editor/copy.js +22 -12
  98. package/dist/puck/editor/editor.chrome.css +9 -8
  99. package/dist/puck/editor/editor.css +14 -9
  100. package/dist/puck/editor/placementsCache.d.ts +1 -1
  101. package/dist/puck/editor/placementsCache.js +9 -17
  102. package/dist/puck/editor/usePageSaveReadiness.d.ts +1 -4
  103. package/dist/puck/editor/usePageSaveReadiness.js +18 -21
  104. package/dist/puck/editor/usePlacementNotice.d.ts +2 -2
  105. package/dist/puck/editor/usePlacementNotice.js +4 -5
  106. package/dist/puck/nestedTestCopy.js +2 -2
  107. package/dist/puck/slotConfig.d.ts +1 -1
  108. package/dist/puck/slotConfig.js +1 -1
  109. package/dist/results/analyse.d.ts +2 -0
  110. package/dist/results/analyse.js +2 -2
  111. package/dist/results/verdict.d.ts +4 -4
  112. package/dist/results/verdict.js +13 -10
  113. package/dist/server/runResults.js +2 -1
  114. package/dist/testSurface/PreviewLinks.d.ts +2 -1
  115. package/dist/testSurface/PreviewLinks.js +3 -3
  116. package/dist/testSurface/actions/DecideDialog.d.ts +7 -4
  117. package/dist/testSurface/actions/DecideDialog.js +71 -59
  118. package/dist/testSurface/actions/LifecycleAction.d.ts +17 -0
  119. package/dist/testSurface/actions/LifecycleAction.js +107 -0
  120. package/dist/testSurface/actions/MakeContentResult.js +1 -1
  121. package/dist/testSurface/actions/actions.model.d.ts +13 -5
  122. package/dist/testSurface/actions/actions.model.js +75 -22
  123. package/dist/testSurface/actions/decide.model.d.ts +1 -0
  124. package/dist/testSurface/actions/decide.model.js +1 -0
  125. package/dist/testSurface/allocation.model.js +6 -3
  126. package/dist/testSurface/api.d.ts +4 -1
  127. package/dist/testSurface/api.js +22 -14
  128. package/dist/testSurface/copy/actions.d.ts +36 -14
  129. package/dist/testSurface/copy/actions.js +39 -17
  130. package/dist/testSurface/copy/advanced.d.ts +10 -0
  131. package/dist/testSurface/copy/advanced.js +10 -0
  132. package/dist/testSurface/copy/arms.d.ts +1 -1
  133. package/dist/testSurface/copy/arms.js +1 -1
  134. package/dist/testSurface/copy/audience.d.ts +4 -3
  135. package/dist/testSurface/copy/audience.js +5 -4
  136. package/dist/testSurface/copy/common.d.ts +6 -6
  137. package/dist/testSurface/copy/common.js +6 -6
  138. package/dist/testSurface/copy/metrics.d.ts +6 -0
  139. package/dist/testSurface/copy/metrics.js +8 -0
  140. package/dist/testSurface/copy/pages.d.ts +67 -7
  141. package/dist/testSurface/copy/pages.js +74 -7
  142. package/dist/testSurface/copy/readiness.d.ts +8 -6
  143. package/dist/testSurface/copy/readiness.js +19 -10
  144. package/dist/testSurface/copy/recommendation.d.ts +1 -22
  145. package/dist/testSurface/copy/recommendation.js +2 -22
  146. package/dist/testSurface/copy/results.d.ts +16 -10
  147. package/dist/testSurface/copy/results.js +19 -11
  148. package/dist/testSurface/copy/review.d.ts +13 -10
  149. package/dist/testSurface/copy/review.js +14 -10
  150. package/dist/testSurface/copy/setting.d.ts +1 -2
  151. package/dist/testSurface/copy/setting.js +1 -2
  152. package/dist/testSurface/copy/surface.d.ts +11 -2
  153. package/dist/testSurface/copy/surface.js +14 -11
  154. package/dist/testSurface/copy/testPage.d.ts +16 -10
  155. package/dist/testSurface/copy/testPage.js +24 -18
  156. package/dist/testSurface/format/date.d.ts +5 -2
  157. package/dist/testSurface/format/date.js +24 -8
  158. package/dist/testSurface/format/roundProgress.d.ts +6 -0
  159. package/dist/testSurface/format/roundProgress.js +15 -0
  160. package/dist/testSurface/format/useDateFormatter.d.ts +3 -0
  161. package/dist/testSurface/format/useDateFormatter.js +8 -0
  162. package/dist/testSurface/labels.d.ts +1 -2
  163. package/dist/testSurface/labels.js +2 -3
  164. package/dist/testSurface/lockedNotice.model.d.ts +2 -0
  165. package/dist/testSurface/lockedNotice.model.js +31 -0
  166. package/dist/testSurface/readPreflight.d.ts +0 -1
  167. package/dist/testSurface/readPreflight.js +0 -1
  168. package/dist/testSurface/results/CiChart.js +2 -1
  169. package/dist/testSurface/results/DataTable.d.ts +1 -1
  170. package/dist/testSurface/results/DataTable.js +4 -3
  171. package/dist/testSurface/results/VerdictHero.d.ts +1 -1
  172. package/dist/testSurface/results/legacy.d.ts +0 -5
  173. package/dist/testSurface/results/legacy.js +0 -14
  174. package/dist/testSurface/results/results.css +2 -2
  175. package/dist/testSurface/results/results.model.d.ts +8 -3
  176. package/dist/testSurface/results/results.model.js +25 -21
  177. package/dist/testSurface/results/snapshot.d.ts +2 -0
  178. package/dist/testSurface/results/snapshot.js +3 -0
  179. package/dist/testSurface/surface/contracts.d.ts +6 -1
  180. package/dist/testSurface/surface/editorPlacement.d.ts +1 -1
  181. package/dist/testSurface/surface/editorPlacement.js +1 -1
  182. package/dist/testSurface/surface/pageBlock/pageBlock.model.js +1 -1
  183. package/dist/testSurface/surface/pageBlock/parts.js +25 -12
  184. package/dist/testSurface/surface/pagePicker/CopyRoute.d.ts +8 -1
  185. package/dist/testSurface/surface/pagePicker/CopyRoute.js +243 -22
  186. package/dist/testSurface/surface/pagePicker/PageCombobox.d.ts +15 -4
  187. package/dist/testSurface/surface/pagePicker/PageCombobox.js +298 -209
  188. package/dist/testSurface/surface/pagePicker/pagePicker.css +73 -10
  189. package/dist/testSurface/surface/pagePicker/pagePicker.model.d.ts +5 -3
  190. package/dist/testSurface/surface/pagePicker/pagePicker.model.js +17 -2
  191. package/dist/testSurface/surface/readiness/ActionDialogs.d.ts +5 -3
  192. package/dist/testSurface/surface/readiness/ActionDialogs.js +213 -207
  193. package/dist/testSurface/surface/readiness/Banner.d.ts +5 -1
  194. package/dist/testSurface/surface/readiness/Banner.js +109 -148
  195. package/dist/testSurface/surface/readiness/SaveStatus.d.ts +5 -2
  196. package/dist/testSurface/surface/readiness/SaveStatus.js +8 -7
  197. package/dist/testSurface/surface/readiness/readiness.model.d.ts +14 -5
  198. package/dist/testSurface/surface/readiness/readiness.model.js +62 -12
  199. package/dist/testSurface/surface/readiness/useTransition.d.ts +3 -1
  200. package/dist/testSurface/surface/readiness/useTransition.js +49 -8
  201. package/dist/testSurface/surface/results/ReleasePages.d.ts +4 -3
  202. package/dist/testSurface/surface/results/ReleasePages.js +41 -41
  203. package/dist/testSurface/surface/results/ResultsBody.d.ts +7 -2
  204. package/dist/testSurface/surface/results/ResultsBody.js +170 -110
  205. package/dist/testSurface/surface/results/recommendation.model.d.ts +6 -9
  206. package/dist/testSurface/surface/results/recommendation.model.js +15 -59
  207. package/dist/testSurface/surface/results/useResults.d.ts +6 -2
  208. package/dist/testSurface/surface/setting/parts.js +31 -28
  209. package/dist/testSurface/surface/setting/setting.css +2 -1
  210. package/dist/testSurface/surface/test/AdvancedSection.js +10 -4
  211. package/dist/testSurface/surface/test/DeleteTest.d.ts +5 -1
  212. package/dist/testSurface/surface/test/DeleteTest.js +63 -55
  213. package/dist/testSurface/surface/test/GoalSection.js +11 -11
  214. package/dist/testSurface/surface/test/LengthSection.js +21 -13
  215. package/dist/testSurface/surface/test/PageHoldout.d.ts +1 -1
  216. package/dist/testSurface/surface/test/PageHoldout.js +7 -7
  217. package/dist/testSurface/surface/test/ReadinessBar.d.ts +2 -1
  218. package/dist/testSurface/surface/test/ReadinessBar.js +4 -10
  219. package/dist/testSurface/surface/test/Section.js +8 -0
  220. package/dist/testSurface/surface/test/TargetingSection.js +7 -2
  221. package/dist/testSurface/surface/test/TestSurface.js +17 -43
  222. package/dist/testSurface/surface/test/VersionsSection.js +93 -70
  223. package/dist/testSurface/surface/test/fields.d.ts +4 -3
  224. package/dist/testSurface/surface/test/fields.js +10 -16
  225. package/dist/testSurface/surface/test/pageParts.js +13 -7
  226. package/dist/testSurface/surface/test/testPage.css +9 -2
  227. package/dist/testSurface/surface/useTestDocument.d.ts +1 -3
  228. package/dist/testSurface/surface/useTestDocument.js +110 -52
  229. package/dist/testSurface/surface/watchTestDocument.d.ts +15 -0
  230. package/dist/testSurface/surface/watchTestDocument.js +181 -0
  231. package/dist/testSurface/surfaceUrls.d.ts +1 -0
  232. package/dist/testSurface/surfaceUrls.js +4 -0
  233. package/dist/testSurface/useApi.d.ts +3 -0
  234. package/dist/transitions/addMetric.d.ts +1 -1
  235. package/dist/transitions/addMetric.js +5 -1
  236. package/dist/transitions/kernel.d.ts +2 -0
  237. package/dist/transitions/kernel.js +1 -1
  238. package/dist/transitions/pageAddress.d.ts +6 -0
  239. package/dist/transitions/pageAddress.js +71 -0
  240. package/dist/transitions/pageVersions.d.ts +1 -1
  241. package/dist/transitions/preflightData.js +10 -2
  242. package/dist/transitions/start.d.ts +1 -1
  243. package/dist/transitions/start.js +8 -5
  244. package/dist/types/armKey.d.ts +2 -0
  245. package/dist/types/armKey.js +1 -0
  246. package/dist/types/contracts.d.ts +11 -1
  247. package/dist/types/endpoints.d.ts +38 -9
  248. package/dist/types/endpoints.js +1 -1
  249. package/dist/types/surface.d.ts +7 -9
  250. package/dist/ui/Dialog.d.ts +21 -2
  251. package/dist/ui/Dialog.js +101 -4
  252. package/dist/ui/Inputs.js +0 -1
  253. package/dist/ui/ui.css +5 -1
  254. package/package.json +2 -2
@@ -2,7 +2,7 @@
2
2
  import { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from "react/jsx-runtime";
3
3
  import { createPortal } from 'react-dom';
4
4
  import { createUsePuck, useGetPuck, FieldGroup } from '@puckeditor/core';
5
- import { useCallback, useEffect, useRef, useState } from 'react';
5
+ import { useCallback, useEffect, useId, useMemo, useRef, useState } from 'react';
6
6
  import { defaultArms } from '../../arms/model.js';
7
7
  import { BLOCK_SLOTS } from '../../blocks/model.js';
8
8
  import { publishOutlineVersion } from './outlineVersion.js';
@@ -11,7 +11,7 @@ import { Button } from '../../ui/Button.js';
11
11
  import { StatusChip } from '../../ui/StatusChip.js';
12
12
  import { Banner } from '../../ui/Banner.js';
13
13
  import { Tabs } from '../../ui/Tabs.js';
14
- import { Dialog } from '../../ui/Dialog.js';
14
+ import { ConfirmDialog, Dialog } from '../../ui/Dialog.js';
15
15
  import { accentVariables, deriveAccent, validateAccent } from '../../ui/accent.js';
16
16
  import { ExperimentPicker } from '../ExperimentPicker.js';
17
17
  import { TestSidebarField, useSidebarTargets } from './sidebar.js';
@@ -19,6 +19,8 @@ import { documentChanged, readPreflight, statusOrRoundChanged } from '../../test
19
19
  import { classifyReadinessRead } from '../../testSurface/readinessRead.js';
20
20
  import { READINESS_COPY } from '../../testSurface/copy/readiness.js';
21
21
  import { TEST_PAGE } from '../../testSurface/copy/testPage.js';
22
+ import { lockedReason } from '../../testSurface/lockedNotice.model.js';
23
+ import { EDITABLE_BY_STATUS } from '../../collections/experiments/editability.js';
22
24
  import { useOnTestReturn } from '../../testSurface/useOnTestReturn.js';
23
25
  import { useReadinessPolling } from '../../testSurface/useReadinessPolling.js';
24
26
  import { PlacementNotice } from './PlacementNotice.js';
@@ -44,11 +46,38 @@ import { editorContentNotice, pageReadinessContext } from '../../testSurface/sur
44
46
  import { localPlacements, localBlockVisibility, localNestedTests } from './localPlacements.js';
45
47
  import { usePageSaveReadiness } from './usePageSaveReadiness.js';
46
48
  import { usePlacementNotice } from './usePlacementNotice.js';
49
+ import { notifyTestDocument } from '../../testSurface/surface/watchTestDocument.js';
47
50
  import { useEditorSurface } from './editorSurface.js';
48
51
  import { createBlockTest, CreateRefused } from './createTest.js';
49
52
  import { ConfigureTestControl, openConfigureTestDrawer } from './ConfigureTestDrawer.js';
50
53
  import './editor.css';
51
54
  const usePuckSelector = createUsePuck();
55
+ function versionContentKey(state, id, sourceId) {
56
+ const blocks = localPlacements(state.appState.data).get(String(id));
57
+ // Placement discovery also walks props that Puck may not index as editable slots.
58
+ const items = Array.from(blocks ?? []).filter((blockId)=>state.getSelectorForId(blockId)).map((blockId)=>state.getItemById(blockId));
59
+ if (!items.length && state.getSelectorForId(sourceId)) {
60
+ const source = state.getItemById(sourceId);
61
+ // A hidden block still has editable content even without a visible placement.
62
+ if (source && String(source.props.experiment?.id) === String(id)) items.push(source);
63
+ }
64
+ if (!items.length) return '';
65
+ return BLOCK_SLOTS.map((slot)=>{
66
+ const filled = items.filter((item)=>{
67
+ const content = item?.props[slot];
68
+ return Array.isArray(content) && content.length > 0;
69
+ }).length;
70
+ return filled === items.length ? 'filled' : filled > 0 ? 'partial' : 'empty';
71
+ }).join(',');
72
+ }
73
+ function readVersionContent(key) {
74
+ if (!key) return;
75
+ const states = key.split(',');
76
+ return Object.fromEntries(BLOCK_SLOTS.map((slot, index)=>[
77
+ slot,
78
+ states[index]
79
+ ]));
80
+ }
52
81
  class TestReadError extends Error {
53
82
  status;
54
83
  constructor(status){
@@ -64,6 +93,42 @@ function isExperiment(value) {
64
93
  'holdout'
65
94
  ].includes(arm.kind) && typeof arm.label === 'string');
66
95
  }
96
+ function SidebarMore({ children }) {
97
+ const id = useId();
98
+ const [open, setOpen] = useState(false);
99
+ return /*#__PURE__*/ _jsxs("div", {
100
+ className: "xp-slot-more",
101
+ children: [
102
+ /*#__PURE__*/ _jsxs(Button, {
103
+ variant: "quiet",
104
+ size: "sm",
105
+ "aria-expanded": open,
106
+ "aria-controls": id,
107
+ onClick: ()=>setOpen((current)=>!current),
108
+ children: [
109
+ editorCopy.moreGroup,
110
+ /*#__PURE__*/ _jsx("svg", {
111
+ width: "12",
112
+ height: "12",
113
+ viewBox: "0 0 12 12",
114
+ fill: "none",
115
+ "aria-hidden": "true",
116
+ children: /*#__PURE__*/ _jsx("path", {
117
+ d: "M2.5 4.5 6 8l3.5-3.5",
118
+ stroke: "currentColor",
119
+ strokeWidth: "1.5"
120
+ })
121
+ })
122
+ ]
123
+ }),
124
+ /*#__PURE__*/ _jsx("div", {
125
+ id: id,
126
+ hidden: !open,
127
+ children: children
128
+ })
129
+ ]
130
+ });
131
+ }
67
132
  function EditorRender(props) {
68
133
  const getPuck = useGetPuck();
69
134
  const sidebar = useSidebarTargets(props.id);
@@ -137,11 +202,12 @@ function EditorRender(props) {
137
202
  const [settingUp, setSettingUp] = useState(false);
138
203
  const [setupError, setSetupError] = useState('');
139
204
  const configuration = useRef(undefined);
140
- useEffect(()=>()=>configuration.current?.close(), []);
205
+ useEffect(()=>()=>configuration.current?.drawer.close(), []);
141
206
  const creation = useRef(undefined);
142
207
  useEffect(()=>()=>creation.current?.closeIfIdle(), []);
143
208
  // A non-empty variant is only overwritten after an explicit second confirmation.
144
- const [confirming, setConfirming] = useState(null);
209
+ const [copyConfirmation, setCopyConfirmation] = useState(null);
210
+ const confirming = copyConfirmation?.key === bindingKey ? copyConfirmation.slot : undefined;
145
211
  // A Remove refusal stays with its open dialog, even if the version disappears or the test locks.
146
212
  // Close on a binding change, Cancel/Escape, or success; only then discard its refusal.
147
213
  // Split/Add refusals survive the locking read, then clear on a later status change;
@@ -289,7 +355,11 @@ function EditorRender(props) {
289
355
  });
290
356
  const hidden = blockVisibility === 'hidden';
291
357
  const visibilityNotice = hidden ? editorCopy.hidden : blockVisibility ? editorCopy.hiddenOn(blockVisibility) : undefined;
292
- const locallyShared = usePuckSelector((state)=>experimentId !== undefined && (localPlacements(state.appState.data).get(String(experimentId))?.size ?? 0) > 1);
358
+ const localPlacement = usePuckSelector((state)=>{
359
+ const count = experimentId === undefined ? 0 : localPlacements(state.appState.data).get(String(experimentId))?.size ?? 0;
360
+ return count > 1 ? 'multiple' : count === 1 ? 'single' : 'none';
361
+ });
362
+ const locallyShared = localPlacement === 'multiple';
293
363
  const result = experimentId === undefined || loaded?.id !== experimentId ? undefined : loaded;
294
364
  const shared = locallyShared || result?.shared === true;
295
365
  const experiment = cachedExperiment ?? result?.doc;
@@ -338,7 +408,14 @@ function EditorRender(props) {
338
408
  readinessRead,
339
409
  readTest
340
410
  ]);
341
- const editable = canManage && setupStatus && !statusChanged;
411
+ const editable = canManage && !!experiment && !lockedReason(experiment.status, 'arms', EDITABLE_BY_STATUS) && !statusChanged;
412
+ useEffect(()=>{
413
+ if (!editable || copyConfirmation && copyConfirmation.key !== bindingKey) setCopyConfirmation(null);
414
+ }, [
415
+ bindingKey,
416
+ copyConfirmation,
417
+ editable
418
+ ]);
342
419
  const [removed, setRemoved] = useState(null);
343
420
  useEffect(()=>{
344
421
  // Dialog cleanup must close the native modal before an outside tab can receive focus.
@@ -461,13 +538,18 @@ function EditorRender(props) {
461
538
  });
462
539
  }
463
540
  function requestCopy(variant) {
541
+ if (!editable || !isCurrentBinding()) return;
464
542
  const item = getPuck().getItemById(props.id);
465
543
  const target = item?.props[variant];
466
- if (Array.isArray(target) && target.length) setConfirming(variant);
544
+ if (Array.isArray(target) && target.length) setCopyConfirmation({
545
+ key: bindingKey,
546
+ slot: variant
547
+ });
467
548
  else copyTo(variant);
468
549
  }
469
550
  function copyTo(variant) {
470
- setConfirming(null);
551
+ setCopyConfirmation(null);
552
+ if (!editable || !isCurrentBinding()) return;
471
553
  const { getItemById, dispatch, getSelectorForId } = getPuck();
472
554
  const item = getItemById(props.id);
473
555
  if (!item || !Array.isArray(item.props.control) || !item.props.control.length) return;
@@ -597,12 +679,21 @@ function EditorRender(props) {
597
679
  setSetupError('');
598
680
  try {
599
681
  const created = await createBlockTest(api, pageTitle, await newTestArms());
600
- if (bind(created)) configuration.current = openConfigureTestDrawer(source, {
601
- admin,
602
- api,
603
- contentLocale
604
- }, created.id);
605
- else creation.current = openCreateExperimentDrawer(source, {
682
+ if (bind(created)) {
683
+ const content = readVersionContent(versionContentKey(getPuck(), created.id, props.id));
684
+ configuration.current?.drawer.close();
685
+ const drawer = openConfigureTestDrawer(source, {
686
+ admin,
687
+ api,
688
+ contentLocale
689
+ }, created.id, content, ()=>{
690
+ configuration.current = undefined;
691
+ });
692
+ configuration.current = {
693
+ id: created.id,
694
+ drawer
695
+ };
696
+ } else creation.current = openCreateExperimentDrawer(source, {
606
697
  admin,
607
698
  api
608
699
  }, {
@@ -619,27 +710,21 @@ function EditorRender(props) {
619
710
  const savedPlacements = placements?.id === experimentId ? placements?.value : undefined;
620
711
  const editorPage = currentPuckDocument(window.location.pathname, admin, savedPlacements);
621
712
  const placementMessage = hidden || statusChanged ? undefined : editorPlacementMessage(savedPlacements, editorPage, experiment?.status);
622
- const versionContent = usePuckSelector((state)=>{
623
- if (!editable || !sidebar || !editorPage || experimentId === undefined) return '';
624
- const blocks = localPlacements(state.appState.data).get(String(experimentId));
625
- if (!blocks?.size) return '';
626
- const items = Array.from(blocks, (id)=>state.getItemById(id));
627
- return BLOCK_SLOTS.map((version)=>{
628
- const filled = items.filter((item)=>{
629
- const content = item?.props[version];
630
- return Array.isArray(content) && content.length > 0;
631
- }).length;
632
- return filled === items.length ? 'filled' : filled > 0 ? 'partial' : 'empty';
633
- }).join(',');
634
- });
713
+ const contentKey = usePuckSelector((state)=>experimentId === undefined || !canManage || !sidebar && configuration.current?.id !== experimentId ? '' : versionContentKey(state, experimentId, props.id));
714
+ const versionContent = useMemo(()=>readVersionContent(contentKey), [
715
+ contentKey
716
+ ]);
717
+ useEffect(()=>{
718
+ const opened = configuration.current;
719
+ if (opened && opened.id === experimentId) opened.drawer.updateVersionContent(versionContent);
720
+ }, [
721
+ experimentId,
722
+ versionContent
723
+ ]);
635
724
  const currentPreflight = preflight && preflight.id === experimentId && Array.isArray(preflight.value?.checks) ? preflight.value : null;
636
- const contentStates = versionContent.split(',');
637
- const livePage = editorPage && versionContent ? {
725
+ const livePage = editorPage && editable && sidebar && localPlacement !== 'none' ? {
638
726
  ...editorPage,
639
- versionContent: Object.fromEntries(BLOCK_SLOTS.map((slot, index)=>[
640
- slot,
641
- contentStates[index]
642
- ]))
727
+ versionContent
643
728
  } : editorPage;
644
729
  const surface = access.surface ? {
645
730
  ...access.surface,
@@ -697,34 +782,38 @@ function EditorRender(props) {
697
782
  ]);
698
783
  },
699
784
  acceptTransition: (result)=>{
785
+ if (experimentId === undefined) return;
786
+ notifyTestDocument(api, experimentId);
700
787
  const doc = result?.doc;
701
- if (doc && experimentId !== undefined) publishExperiment(experimentId, doc);
788
+ if (doc) publishExperiment(experimentId, doc);
702
789
  }
703
790
  };
704
791
  const placementNotice = quickTest.preflightRead?.message ?? placementMessage;
705
792
  const contentNotice = sidebar && editable && surface && quickTest.doc ? editorContentNotice(currentPreflight, pageReadinessContext(quickTest.doc, currentPreflight, surface)) : undefined;
706
- usePlacementNotice(api, experimentId, canManage ? placementNotice ?? contentNotice : undefined, contentLocale, canManage);
793
+ usePlacementNotice(api, experimentId, canManage ? placementNotice ?? contentNotice : undefined, contentLocale);
707
794
  usePageSaveReadiness(api, sidebar && canManage ? experimentId : undefined, editorPage, contentLocale);
708
- const placementNoticeView = /*#__PURE__*/ _jsxs(_Fragment, {
709
- children: [
710
- nestedNotice ? /*#__PURE__*/ _jsx(Banner, {
711
- tone: "info",
712
- children: nestedNotice
713
- }) : null,
714
- visibilityNotice ? /*#__PURE__*/ _jsx(Banner, {
715
- tone: "info",
716
- children: visibilityNotice
717
- }) : null,
718
- canManage ? /*#__PURE__*/ _jsx(PlacementNotice, {
719
- read: quickTest.preflightRead,
720
- message: placementMessage,
721
- running: experiment?.status === 'running',
722
- onRetry: ()=>{
723
- if (experimentId !== undefined) void refreshPlacements(api, experimentId, contentLocale);
724
- }
725
- }) : null
726
- ]
727
- });
795
+ const runningInSidebar = !!(sidebar && showVersions && experiment.status === 'running' && !statusChanged);
796
+ const runningPlacement = runningInSidebar && canManage && !quickTest.preflightRead?.message ? placementMessage : undefined;
797
+ const placementNoticeView = (inSidebar)=>/*#__PURE__*/ _jsxs(_Fragment, {
798
+ children: [
799
+ nestedNotice ? /*#__PURE__*/ _jsx(Banner, {
800
+ tone: "info",
801
+ children: nestedNotice
802
+ }) : null,
803
+ visibilityNotice ? /*#__PURE__*/ _jsx(Banner, {
804
+ tone: "info",
805
+ children: visibilityNotice
806
+ }) : null,
807
+ canManage && (inSidebar || !runningInSidebar) ? /*#__PURE__*/ _jsx(PlacementNotice, {
808
+ read: quickTest.preflightRead,
809
+ message: runningPlacement ? undefined : placementMessage,
810
+ running: experiment?.status === 'running',
811
+ onRetry: ()=>{
812
+ if (experimentId !== undefined) void refreshPlacements(api, experimentId, contentLocale);
813
+ }
814
+ }) : null
815
+ ]
816
+ });
728
817
  const sidebarTest = currentPreflight && editorPage && nestedNotice && !hidden ? {
729
818
  ...quickTest,
730
819
  preflight: {
@@ -793,12 +882,27 @@ function EditorRender(props) {
793
882
  }) : experimentId !== undefined && (noAccess || unavailable || resultsOnly) ? /*#__PURE__*/ _jsx("p", {
794
883
  className: "xp-ui-help",
795
884
  children: resultsOnly ? pickerCopy.resultsOnly : pickerCopy.forbidden
796
- }) : /*#__PURE__*/ _jsx(Banner, {
885
+ }) : runningInSidebar ? null : /*#__PURE__*/ _jsxs(Banner, {
797
886
  tone: experiment?.status === 'running' ? 'warning' : 'info',
798
- children: experimentId === undefined ? bannerFor() : experiment ? statusChanged ? READINESS_COPY.checking : bannerFor(experiment.status, winner, originalLabel, experiment.decision ?? null) : editorCopy.loading
887
+ children: [
888
+ experimentId === undefined ? bannerFor() : experiment ? statusChanged ? READINESS_COPY.checking : bannerFor(experiment.status, winner, originalLabel, experiment.decision ?? null) : editorCopy.loading,
889
+ !statusChanged && experiment?.status === 'archived' ? /*#__PURE__*/ _jsxs(_Fragment, {
890
+ children: [
891
+ /*#__PURE__*/ _jsx("p", {
892
+ children: editorCopy.archivedStepsWhy
893
+ }),
894
+ /*#__PURE__*/ _jsx("ol", {
895
+ children: editorCopy.archivedSteps.map((step)=>/*#__PURE__*/ _jsx("li", {
896
+ children: step
897
+ }, step))
898
+ })
899
+ ]
900
+ }) : null
901
+ ]
799
902
  });
800
903
  const versionLockMessage = editable || !experiment ? undefined : canManage ? editorCopy.locked[experiment.status] ?? editorCopy.lockedGeneric : editorCopy.readOnlyVersions;
801
904
  const removeDialog = removing?.key === bindingKey ? /*#__PURE__*/ _jsx(RemoveVersion, {
905
+ name: experiment?.name,
802
906
  count: countSlotBlocks(getPuck().getItemById(props.id)?.props[removing.arm.key]),
803
907
  shared: locallyShared ? true : result?.shared,
804
908
  arm: removing.arm,
@@ -806,6 +910,14 @@ function EditorRender(props) {
806
910
  onRemove: removeContent,
807
911
  onClose: ()=>setRemoving(null)
808
912
  }) : null;
913
+ const replacingLabel = confirming ? tabs.find((tab)=>tab.slot === confirming)?.label ?? confirming : undefined;
914
+ const more = access.surface?.canManage && experimentId !== undefined ? /*#__PURE__*/ _jsx(SidebarMore, {
915
+ children: /*#__PURE__*/ _jsx(Button, {
916
+ disabled: hasSidebarDraft,
917
+ onClick: ()=>setChoosing(true),
918
+ children: editorCopy.differentTest
919
+ })
920
+ }) : null;
809
921
  return /*#__PURE__*/ _jsxs("section", {
810
922
  ref: root,
811
923
  className: "xp-slot-root xp-slot-editor",
@@ -818,6 +930,8 @@ function EditorRender(props) {
818
930
  onKeyDown: (event)=>event.stopPropagation(),
819
931
  children: /*#__PURE__*/ _jsx("section", {
820
932
  "aria-label": editorCopy.testGroup,
933
+ tabIndex: -1,
934
+ "data-dialog-focus-scope": true,
821
935
  children: /*#__PURE__*/ _jsxs(FieldGroup, {
822
936
  label: editorCopy.testGroup,
823
937
  collapsible: false,
@@ -838,7 +952,7 @@ function EditorRender(props) {
838
952
  tone: "info",
839
953
  children: editorCopy.sharedTest
840
954
  }) : null,
841
- placementNoticeView,
955
+ placementNoticeView(true),
842
956
  editable ? /*#__PURE__*/ _jsx(BlockerList, {
843
957
  steps: sidebarBlockers
844
958
  }) : null,
@@ -848,12 +962,13 @@ function EditorRender(props) {
848
962
  admin,
849
963
  api,
850
964
  contentLocale
851
- }
965
+ },
966
+ versionContent: versionContent
852
967
  }) : null,
853
968
  canManage && experiment && surface ? /*#__PURE__*/ _jsx(QuickTestActions, {
854
969
  test: quickTest,
855
970
  surface: surface
856
- }, `${experimentId}/${experiment.status}/${experiment.phase}`) : null,
971
+ }, experimentId) : null,
857
972
  canSetUp ? /*#__PURE__*/ _jsx(Button, {
858
973
  variant: "primary",
859
974
  busy: settingUp,
@@ -907,11 +1022,14 @@ function EditorRender(props) {
907
1022
  }),
908
1023
  showVersions ? /*#__PURE__*/ _jsx("section", {
909
1024
  "aria-label": editorCopy.versionsGroup,
1025
+ tabIndex: -1,
1026
+ "data-dialog-focus-scope": true,
910
1027
  children: /*#__PURE__*/ _jsx(FieldGroup, {
911
1028
  label: editorCopy.versionsGroup,
912
1029
  collapsible: false,
913
1030
  children: /*#__PURE__*/ _jsx(VersionLock, {
914
1031
  message: versionLockMessage,
1032
+ detail: runningPlacement,
915
1033
  children: (lockId)=>/*#__PURE__*/ _jsx(_Fragment, {
916
1034
  children: /*#__PURE__*/ _jsx(VersionWeights, {
917
1035
  edits: weightEdits,
@@ -921,7 +1039,7 @@ function EditorRender(props) {
921
1039
  experiment: experiment,
922
1040
  writes: writes,
923
1041
  editable: editable,
924
- showSplit: canManage,
1042
+ showSplit: editable,
925
1043
  beforeActions: leftoverControls,
926
1044
  beforeSplit: editable ? /*#__PURE__*/ _jsx(AddVariant, {
927
1045
  experiment: experiment,
@@ -955,15 +1073,18 @@ function EditorRender(props) {
955
1073
  ]
956
1074
  }, `${experimentId}-${arm.key}`),
957
1075
  input,
958
- arm.kind === 'variant' || arm.kind === 'holdout' && editable ? /*#__PURE__*/ _jsxs("div", {
1076
+ editable && (arm.kind === 'variant' || arm.kind === 'holdout') ? /*#__PURE__*/ _jsxs("div", {
959
1077
  className: "xp-slot-version-actions",
960
1078
  children: [
961
1079
  arm.kind === 'variant' ? /*#__PURE__*/ _jsx(Button, {
962
1080
  size: "sm",
963
1081
  disabled: originalEmpty,
964
1082
  "aria-disabled": writes.busy || undefined,
965
- onClick: ()=>{
966
- if (!writes.busy) requestCopy(arm.key);
1083
+ onClick: (event)=>{
1084
+ if (!writes.busy) {
1085
+ event.currentTarget.focus();
1086
+ requestCopy(arm.key);
1087
+ }
967
1088
  },
968
1089
  children: editorCopy.copy(originalLabel)
969
1090
  }) : null,
@@ -971,11 +1092,14 @@ function EditorRender(props) {
971
1092
  size: "sm",
972
1093
  "aria-describedby": lockId,
973
1094
  "aria-disabled": writes.busy || undefined,
974
- onClick: ()=>{
975
- if (!writes.busy) setRemoving({
976
- key: bindingKey,
977
- arm
978
- });
1095
+ onClick: (event)=>{
1096
+ if (!writes.busy) {
1097
+ event.currentTarget.focus();
1098
+ setRemoving({
1099
+ key: bindingKey,
1100
+ arm
1101
+ });
1102
+ }
979
1103
  },
980
1104
  children: editorCopy.removeVersion
981
1105
  }) : null
@@ -983,9 +1107,9 @@ function EditorRender(props) {
983
1107
  }) : null,
984
1108
  arm.kind === 'holdout' ? /*#__PURE__*/ _jsx("p", {
985
1109
  className: "xp-ui-help xp-slot-version-help",
986
- children: editorCopy.holdoutContent
1110
+ children: editorCopy.holdoutContent(originalLabel)
987
1111
  }) : null,
988
- arm.kind === 'variant' && originalEmpty ? /*#__PURE__*/ _jsx("p", {
1112
+ editable && arm.kind === 'variant' && originalEmpty ? /*#__PURE__*/ _jsx("p", {
989
1113
  className: "xp-ui-help xp-slot-version-help",
990
1114
  children: editorCopy.copyEmpty(originalLabel)
991
1115
  }) : null
@@ -996,15 +1120,6 @@ function EditorRender(props) {
996
1120
  }, bindingKey)
997
1121
  })
998
1122
  }) : null,
999
- access.surface?.canManage && experimentId !== undefined ? /*#__PURE__*/ _jsx(FieldGroup, {
1000
- label: editorCopy.moreGroup,
1001
- defaultExpanded: false,
1002
- children: /*#__PURE__*/ _jsx(Button, {
1003
- disabled: hasSidebarDraft,
1004
- onClick: ()=>setChoosing(true),
1005
- children: editorCopy.differentTest
1006
- })
1007
- }) : null,
1008
1123
  writes.busy ? /*#__PURE__*/ _jsx("p", {
1009
1124
  role: "status",
1010
1125
  children: editorCopy.savingVersions
@@ -1013,9 +1128,18 @@ function EditorRender(props) {
1013
1128
  role: "alert",
1014
1129
  children: writes.error
1015
1130
  }) : null,
1016
- clearError?.key === bindingKey ? /*#__PURE__*/ _jsx("p", {
1131
+ clearError?.key === bindingKey ? /*#__PURE__*/ _jsxs("div", {
1017
1132
  role: "alert",
1018
- children: clearError.message
1133
+ children: [
1134
+ /*#__PURE__*/ _jsx("p", {
1135
+ children: clearError.message
1136
+ }),
1137
+ /*#__PURE__*/ _jsx("ol", {
1138
+ children: editorCopy.removeUnclearedSteps.map((step)=>/*#__PURE__*/ _jsx("li", {
1139
+ children: step
1140
+ }, step))
1141
+ })
1142
+ ]
1019
1143
  }) : null,
1020
1144
  removed?.key === bindingKey && removed.contentRemoved ? /*#__PURE__*/ _jsx("p", {
1021
1145
  children: editorCopy.removed
@@ -1024,32 +1148,21 @@ function EditorRender(props) {
1024
1148
  id: experimentId,
1025
1149
  api: api,
1026
1150
  experiment: experiment,
1151
+ more: more,
1027
1152
  onRefresh: canManage && experiment.status === 'stopped' ? ()=>{
1028
1153
  void quickTest.refreshPreflight(true);
1029
1154
  } : undefined
1030
- }, `results-${experimentId}`) : null,
1031
- confirming ? /*#__PURE__*/ _jsxs("div", {
1032
- className: "xp-slot-copy-confirm",
1033
- role: "alert",
1034
- children: [
1035
- /*#__PURE__*/ _jsx("p", {
1036
- children: editorCopy.replaceConfirm(tabs.find((tab)=>tab.slot === confirming)?.label ?? confirming, originalLabel)
1037
- }),
1038
- /*#__PURE__*/ _jsxs("div", {
1039
- className: "xp-ui-button-group",
1040
- children: [
1041
- /*#__PURE__*/ _jsx(Button, {
1042
- variant: "primary",
1043
- onClick: ()=>copyTo(confirming),
1044
- children: editorCopy.replace
1045
- }),
1046
- /*#__PURE__*/ _jsx(Button, {
1047
- onClick: ()=>setConfirming(null),
1048
- children: editorCopy.cancel
1049
- })
1050
- ]
1051
- })
1052
- ]
1155
+ }, `results-${experimentId}`) : more,
1156
+ editable && confirming && replacingLabel ? /*#__PURE__*/ _jsx(ConfirmDialog, {
1157
+ title: editorCopy.replaceTitle(replacingLabel, experiment?.name),
1158
+ description: editorCopy.replaceConfirm(replacingLabel, originalLabel),
1159
+ onClose: ()=>setCopyConfirmation(null),
1160
+ cancelLabel: editorCopy.cancel,
1161
+ confirm: {
1162
+ label: editorCopy.replace,
1163
+ destructive: true,
1164
+ onClick: ()=>copyTo(confirming)
1165
+ }
1053
1166
  }) : null,
1054
1167
  removeDialog,
1055
1168
  choosing ? /*#__PURE__*/ _jsx(Dialog, {
@@ -1116,7 +1229,7 @@ function EditorRender(props) {
1116
1229
  tone: "info",
1117
1230
  children: editorCopy.sharedTest
1118
1231
  }) : null,
1119
- placementNoticeView,
1232
+ placementNoticeView(false),
1120
1233
  setupError && canSetUp ? /*#__PURE__*/ _jsx("p", {
1121
1234
  role: sidebar ? undefined : 'alert',
1122
1235
  children: setupError
@@ -2,7 +2,7 @@
2
2
  import { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from "react/jsx-runtime";
3
3
  import { useState } from 'react';
4
4
  import { Button } from '../../ui/Button.js';
5
- import { Dialog } from '../../ui/Dialog.js';
5
+ import { ConfirmDialog } from '../../ui/Dialog.js';
6
6
  import { slotLabels } from '../copy.js';
7
7
  import { editorCopy as C } from './copy.js';
8
8
  import { tabsFor } from './editor.model.js';
@@ -47,7 +47,10 @@ import { addLeftoverArms } from './armWrites.js';
47
47
  }) : null,
48
48
  /*#__PURE__*/ _jsx(Button, {
49
49
  size: "sm",
50
- onClick: ()=>setDeleting(slot),
50
+ onClick: (event)=>{
51
+ event.currentTarget.focus();
52
+ setDeleting(slot);
53
+ },
51
54
  children: C.deleteContent
52
55
  })
53
56
  ]
@@ -57,37 +60,19 @@ import { addLeftoverArms } from './armWrites.js';
57
60
  return /*#__PURE__*/ _jsxs(_Fragment, {
58
61
  children: [
59
62
  slots.map(notice),
60
- deleting ? /*#__PURE__*/ _jsx(Dialog, {
61
- open: true,
62
- title: C.deleteContentTitle(slotLabels[deleting]),
63
- initialFocus: "cancel",
63
+ deleting ? /*#__PURE__*/ _jsx(ConfirmDialog, {
64
+ title: C.deleteContentTitle(slotLabels[deleting], experiment.name),
64
65
  onClose: ()=>setDeleting(null),
65
- children: /*#__PURE__*/ _jsxs("div", {
66
- className: "xp-slot-drawer",
67
- children: [
68
- /*#__PURE__*/ _jsx("p", {
69
- children: C.deleteContentHelp(slotLabels[deleting], countBlocks(deleting))
70
- }),
71
- /*#__PURE__*/ _jsxs("div", {
72
- className: "xp-ui-button-group",
73
- children: [
74
- /*#__PURE__*/ _jsx(Button, {
75
- "data-dialog-cancel": true,
76
- onClick: ()=>setDeleting(null),
77
- children: C.cancel
78
- }),
79
- /*#__PURE__*/ _jsx(Button, {
80
- variant: "danger",
81
- onClick: ()=>{
82
- onDelete(deleting);
83
- setDeleting(null);
84
- },
85
- children: C.deleteContent
86
- })
87
- ]
88
- })
89
- ]
90
- })
66
+ description: C.deleteContentHelp(slotLabels[deleting], countBlocks(deleting)),
67
+ cancelLabel: C.cancel,
68
+ confirm: {
69
+ label: C.deleteContent,
70
+ destructive: true,
71
+ onClick: ()=>{
72
+ onDelete(deleting);
73
+ setDeleting(null);
74
+ }
75
+ }
91
76
  }) : null
92
77
  ]
93
78
  });
@@ -1,6 +1,6 @@
1
1
  import type { ActionTestApi, SurfaceProps } from '../../testSurface/surface/contracts.js';
2
- /** Same transition runner and confirmation as the drawer; Decide stays there. */
2
+ /** Render sidebar actions in the lifecycle model's order. */
3
3
  export declare function QuickTestActions({ test, surface }: {
4
4
  test: ActionTestApi;
5
5
  surface: SurfaceProps;
6
- }): import("react").JSX.Element | null;
6
+ }): import("react").JSX.Element;