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

feat: undo redo #839

Merged
merged 31 commits into from
Aug 29, 2024
Merged

feat: undo redo #839

merged 31 commits into from
Aug 29, 2024

Conversation

tea-artist
Copy link
Contributor

@tea-artist tea-artist commented Aug 16, 2024

Undo & Redo
Undo redo needs to cache the operation context, locate the user operation window, and have some fault tolerance for changes to the table data structure

frontend

  • Button + Shortcut key + Toast
  • API integration

backend

  • Event
  • Stack

  • Create record
  • Delete record
  • Update record
  • Clear records
  • Delete selection
  • Paste selection
  • Move record
  • Create field
  • Delete field
  • Update field
  • Create view
  • Update view
  • Delete view

  • test coverage

@tea-artist tea-artist linked an issue Aug 16, 2024 that may be closed by this pull request
@coveralls
Copy link
Collaborator

coveralls commented Aug 21, 2024

Pull Request Test Coverage Report for Build 10613824090

Warning: This coverage report may be inaccurate.

This pull request's base commit is no longer the HEAD commit of its target branch. This means it includes changes from outside the original pull request, including, potentially, unrelated coverage changes.

Details

  • 2671 of 2782 (96.01%) changed or added relevant lines in 47 files are covered.
  • 4 unchanged lines in 4 files lost coverage.
  • Overall coverage increased (+1.1%) to 84.432%

Changes Missing Coverage Covered Lines Changed/Added Lines %
apps/nestjs-backend/src/features/view/open-api/view-open-api.controller.ts 62 63 98.41%
apps/nestjs-backend/src/features/undo-redo/operations/update-records-order.operation.ts 77 79 97.47%
apps/nestjs-backend/src/features/record/open-api/record-open-api.service.ts 160 163 98.16%
apps/nestjs-backend/src/features/view/view.service.ts 60 63 95.24%
apps/nestjs-backend/src/features/undo-redo/operations/create-fields.operation.ts 62 67 92.54%
apps/nestjs-backend/src/features/record/record.service.ts 143 149 95.97%
apps/nestjs-backend/src/features/undo-redo/stack/undo-redo-stack.service.ts 108 114 94.74%
apps/nestjs-backend/src/features/field/open-api/field-open-api.controller.ts 33 40 82.5%
apps/nestjs-backend/src/features/undo-redo/operations/convert-field.operation.ts 101 109 92.66%
apps/nestjs-backend/src/features/view/open-api/view-open-api.service.ts 122 132 92.42%
Files with Coverage Reduction New Missed Lines %
apps/nestjs-backend/src/features/field/field-calculate/field-converting.service.ts 1 85.39%
apps/nestjs-backend/src/features/field/open-api/field-open-api.controller.ts 1 82.47%
apps/nestjs-backend/src/features/field/open-api/field-open-api.service.ts 1 82.0%
apps/nestjs-backend/src/features/view/view.service.ts 1 90.17%
Totals Coverage Status
Change from base Build 10612623833: 1.1%
Covered Lines: 33046
Relevant Lines: 39139

💛 - Coveralls

@tea-artist tea-artist requested a review from Sky-FE August 21, 2024 10:49
@tea-artist tea-artist self-assigned this Aug 21, 2024
@tea-artist tea-artist force-pushed the feat/undo-redo branch 4 times, most recently from 9f6ebff to c830875 Compare August 28, 2024 11:04
@tea-artist tea-artist changed the title feat(wip): undo redo feat: undo redo Aug 29, 2024
@tea-artist tea-artist marked this pull request as ready for review August 29, 2024 08:02
@tea-artist tea-artist merged commit 14b06ec into develop Aug 29, 2024
7 checks passed
@tea-artist tea-artist deleted the feat/undo-redo branch August 29, 2024 11:22
AliceLanniste pushed a commit to AliceLanniste/teable that referenced this pull request Sep 1, 2024
* feat(wip): undo redo

* chore: register module

* feat: undo-redo create records

* fix: last modified

* fix: duplicate last modified

* feat: undo redo record retain order

* feat: update record undo redo

* refactor: await with event

* feat: undo reodo clear records

* feat: undo redo ui

* fix: lint

* fix: user name modifiy test

* fix: shortcut key for grid view undo redo

* feat: tooltip

* feat: undo redo delete records

* refactor: union operation logic

* chore: clean code

* feat: undo redo record order

* feat: create / delete fields undo redo

* feat: support batch delete fields

* fix: delete field with outgoing references

* fix: transaction issue

* fix: sqlite test

* feat: paste undo redo

* feat: convert field undo redo

* fix: constraint error

* fix: unit test

* feat: add delete view undo redo

* feat: update view undo redo

* fix: delete field error

* fix: page blank when undo delete view
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

There is no Ctrl Z options
2 participants