Improve toolbox reorder and checklist editing UX
All checks were successful
Deploy Sokko G / deploy (push) Successful in 8s
All checks were successful
Deploy Sokko G / deploy (push) Successful in 8s
This commit is contained in:
parent
1e4ac4259b
commit
8eb622e05d
11 changed files with 695 additions and 140 deletions
|
|
@ -15,6 +15,7 @@ test("toolbox storage, cards and pages are wired", async () => {
|
|||
const reorderHook = await readFile("website/src/hooks/usePointerReorder.js", "utf8");
|
||||
const groupedReorderHook = await readFile("website/src/hooks/useGroupedReorder.js", "utf8");
|
||||
const inlineEditHook = await readFile("website/src/hooks/useInlineEdit.js", "utf8");
|
||||
const draftFormHook = await readFile("website/src/hooks/useDraftForm.js", "utf8");
|
||||
|
||||
assert.match(`${indexedToolboxesHook}\n${toolboxPages}`, /indexedDbStorage\.js/);
|
||||
assert.match(source, /features\/toolboxes\/storage\/useIndexedToolboxes\.js/);
|
||||
|
|
@ -90,6 +91,10 @@ test("toolbox storage, cards and pages are wired", async () => {
|
|||
assert.match(inlineEditHook, /blurOnEscape/);
|
||||
assert.match(inlineEditHook, /commitOnEnter/);
|
||||
assert.match(inlineEditHook, /getContentEditableProps/);
|
||||
assert.match(draftFormHook, /export function useDraftForm/);
|
||||
assert.match(draftFormHook, /getFieldProps/);
|
||||
assert.match(draftFormHook, /handleSubmit/);
|
||||
assert.match(draftFormHook, /preventDefault/);
|
||||
});
|
||||
|
||||
test("toolbox module registry and modules expose expected behavior", async () => {
|
||||
|
|
@ -156,6 +161,8 @@ test("toolbox module registry and modules expose expected behavior", async () =>
|
|||
assert.match(combosModule, /useInlineEdit/);
|
||||
assert.match(combosModule, /useGroupedReorder/);
|
||||
assert.match(combosModule, /reorderFeatures/);
|
||||
assert.match(combosModule, /getGroupBoundaryProps/);
|
||||
assert.match(combosModule, /combos-category-boundary-drop-zone/);
|
||||
assert.doesNotMatch(combosModule, /canMoveItem:/);
|
||||
assert.doesNotMatch(combosModule, /canMoveGroup:/);
|
||||
assert.match(calculatorModule, /export function CalculatorModule/);
|
||||
|
|
@ -208,6 +215,7 @@ test("toolbox module registry and modules expose expected behavior", async () =>
|
|||
assert.match(timerModule, /stopwatch/);
|
||||
assert.match(timerModule, /countdown/);
|
||||
assert.match(timerModule, /useInlineEdit/);
|
||||
assert.match(timerModule, /useDraftForm/);
|
||||
assert.match(timerModule, /normalizeTimerData/);
|
||||
assert.match(taskPlannerModule, /export function TaskPlannerModule/);
|
||||
assert.match(taskPlannerModule, /normalizeTaskPlannerData/);
|
||||
|
|
@ -219,6 +227,7 @@ test("toolbox module registry and modules expose expected behavior", async () =>
|
|||
assert.match(taskPlannerModule, /task-planner-warning/);
|
||||
assert.match(taskPlannerModule, /useGroupedReorder/);
|
||||
assert.match(taskPlannerModule, /useInlineEdit/);
|
||||
assert.match(taskPlannerModule, /useDraftForm/);
|
||||
assert.match(taskPlannerModule, /commitOnEnter: false/);
|
||||
assert.match(taskPlannerModule, /reorderFeatures/);
|
||||
assert.doesNotMatch(taskPlannerModule, /canMoveItem:/);
|
||||
|
|
@ -237,7 +246,15 @@ test("toolbox module registry and modules expose expected behavior", async () =>
|
|||
assert.match(checklistModule, /Number\.parseInt/);
|
||||
assert.match(checklistModule, /checklist-qty-current/);
|
||||
assert.match(checklistModule, /checklist-delete-button danger/);
|
||||
assert.doesNotMatch(checklistModule, /useGroupedReorder/);
|
||||
assert.match(checklistModule, /useGroupedReorder/);
|
||||
assert.match(checklistModule, /getItemProps/);
|
||||
assert.match(checklistModule, /getGroupProps/);
|
||||
assert.match(checklistModule, /getGroupBoundaryProps/);
|
||||
assert.match(checklistModule, /checklist-category-boundary-drop-zone/);
|
||||
assert.match(checklistModule, /itemReorder\.startDrag/);
|
||||
assert.match(checklistModule, /groupReorder\.startDrag/);
|
||||
assert.match(checklistModule, /useInlineEdit/);
|
||||
assert.match(checklistModule, /moveChecklistItemToCategory/);
|
||||
assert.match(textImportModal, /createPortal/);
|
||||
assert.match(textImportModal, /lockBodyScroll/);
|
||||
assert.match(imagesModule, /export function ImagesModule/);
|
||||
|
|
@ -264,11 +281,15 @@ test("toolbox module registry and modules expose expected behavior", async () =>
|
|||
assert.match(linksModule, /parseColonImportLines/);
|
||||
assert.match(linksModule, /context\.normalizeUrl/);
|
||||
assert.match(linksModule, /useGroupedReorder/);
|
||||
assert.match(linksModule, /useDraftForm/);
|
||||
assert.match(linksModule, /linkDraft\.getFieldProps/);
|
||||
assert.match(linksModule, /link-drag-handle/);
|
||||
assert.match(countersModule, /export function CountersModule/);
|
||||
assert.match(countersModule, /editing &&/);
|
||||
assert.match(countersModule, /counter-actions/);
|
||||
assert.match(countersModule, /useGroupedReorder/);
|
||||
assert.match(countersModule, /useDraftForm/);
|
||||
assert.match(countersModule, /counterDraft\.getFieldProps/);
|
||||
assert.match(countersModule, /orientation: "horizontal"/);
|
||||
assert.match(countersModule, /counter-drag-handle/);
|
||||
assert.match(timerModule, /useGroupedReorder/);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue