Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[WIP] feat(structure): History UI updates #7462

Draft
wants to merge 4 commits into
base: next
Choose a base branch
from
Draft

Conversation

pedrobonamin
Copy link
Contributor

@pedrobonamin pedrobonamin commented Sep 4, 2024

Description

This PR introduces changes in how the history and revision panel is shown.

  • Chunks are squashed together on publish.
  • Moves the revision selector to the history panel.
  • Timeline item are updated with new looks.
  • Footer shown when seeing a revision is updated with new looks.
  • The inspector panel now includes two tabs the user can navigate history and review changes

What does "chunks are squashed together on publish" means?

Once the draft changes are published all the draft edits done before that publish will be squashed and shown as 1 change, that could be expanded, showing also the collaborators for that published.
This means:
If we have the following mutations:
[draftEdit, publish, draftEdit, draftEdit, create]
it will be shown as
`[draftEdit, publish (expandable), create]
On expand, it will show the two collapsed draftEdit actions

The changes are not removed from the history, they are only visually squashed for easier navigation in the UI.

This is achieved by creating a relation between parents publish action and children draftEdit actions, in the addChunksMetadata function.

Collapsed Expanded
Screenshot 2024-09-03 at 11 11 33 Screenshot 2024-09-03 at 11 11 50
Collapsable.history.items.mov

What to review

Are the changes correct? Is something missing?

Testing

Notes for release

Updates to history inspector UI

Copy link

vercel bot commented Sep 4, 2024

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
page-building-studio ✅ Ready (Inspect) Visit Preview 💬 Add feedback Oct 1, 2024 7:22am
performance-studio ✅ Ready (Inspect) Visit Preview 💬 Add feedback Oct 1, 2024 7:22am
test-compiled-studio ✅ Ready (Inspect) Visit Preview 💬 Add feedback Oct 1, 2024 7:22am
test-next-studio ✅ Ready (Inspect) Visit Preview 💬 Add feedback Oct 1, 2024 7:22am
test-studio ✅ Ready (Inspect) Visit Preview 💬 Add feedback Oct 1, 2024 7:22am
1 Skipped Deployment
Name Status Preview Comments Updated (UTC)
studio-workshop ⬜️ Ignored (Inspect) Visit Preview Oct 1, 2024 7:22am

Copy link
Contributor

github-actions bot commented Sep 4, 2024

No changes to documentation

Copy link
Contributor

github-actions bot commented Sep 4, 2024

Component Testing Report Updated Oct 1, 2024 7:27 AM (UTC)

✅ All Tests Passed -- expand for details
File Status Duration Passed Skipped Failed
comments/CommentInput.spec.tsx ✅ Passed (Inspect) 46s 15 0 0
formBuilder/ArrayInput.spec.tsx ✅ Passed (Inspect) 8s 3 0 0
formBuilder/inputs/PortableText/Annotations.spec.tsx ✅ Passed (Inspect) 30s 6 0 0
formBuilder/inputs/PortableText/copyPaste/CopyPaste.spec.tsx ✅ Passed (Inspect) 37s 11 7 0
formBuilder/inputs/PortableText/copyPaste/CopyPasteFields.spec.tsx ✅ Passed (Inspect) 0s 0 12 0
formBuilder/inputs/PortableText/Decorators.spec.tsx ✅ Passed (Inspect) 17s 6 0 0
formBuilder/inputs/PortableText/DisableFocusAndUnset.spec.tsx ✅ Passed (Inspect) 10s 3 0 0
formBuilder/inputs/PortableText/DragAndDrop.spec.tsx ✅ Passed (Inspect) 3m 0s 0 0 0
formBuilder/inputs/PortableText/FocusTracking.spec.tsx ✅ Passed (Inspect) 44s 15 0 0
formBuilder/inputs/PortableText/Input.spec.tsx ✅ Passed (Inspect) 1m 42s 21 0 0
formBuilder/inputs/PortableText/ObjectBlock.spec.tsx ✅ Passed (Inspect) 1m 15s 18 0 0
formBuilder/inputs/PortableText/PresenceCursors.spec.tsx ✅ Passed (Inspect) 9s 3 9 0
formBuilder/inputs/PortableText/RangeDecoration.spec.tsx ✅ Passed (Inspect) 25s 9 0 0
formBuilder/inputs/PortableText/Styles.spec.tsx ✅ Passed (Inspect) 18s 6 0 0
formBuilder/inputs/PortableText/Toolbar.spec.tsx ✅ Passed (Inspect) 35s 12 0 0
formBuilder/tree-editing/TreeEditing.spec.tsx ✅ Passed (Inspect) 0s 0 3 0
formBuilder/tree-editing/TreeEditingNestedObjects.spec.tsx ✅ Passed (Inspect) 0s 0 3 0

RitaDias and others added 4 commits October 1, 2024 08:58
* feat(sanity): update restore button

* chore(sanity): update translations

* feat(sanity): add left side information on footer (revision status line)
…el (#7435)

* feat(structure): add history and review tabs to changes inspector panel

* fix(structure): move changes inspector navigation to paneRouter

* fix(structure): update isReviewChangesOpen check in ChangeConnectorRoot

* fix(structure): rename uses of version to revision

* chore(core): rename review changes action to history
…nks (#7449)

* feat(structure): update TimelineItem to match new UI, prepare for chunks

* chore(core): export getCalendarLabels to support DateTimeInput reusability
* feat(structure): add squashed chunks to timeline

* feat(structure): refactor expandable item, all items need to be rendered in the same virtual list

* feat(structure): expand elements on menu click

* chore(structure): clean timeline item
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants