refactor(pkg): components to script setup (modals) - #3040
Open
JammingBen wants to merge 1 commit into
Open
Conversation
Contributor
There was a problem hiding this comment.
Pull request overview
This PR advances the long-running refactor in #1462 by converting several modal components in web-pkg from Options API to Vue 3 <script setup> with typed defineProps/defineEmits, and aligns the corresponding unit tests with the new component instance shape.
Changes:
- Refactored multiple modal components to
<script setup>and migrated props/emits to typeddefineProps/defineEmits. - Updated modal unit tests to access script-setup bindings/methods on
wrapper.vm(usingas anywhere needed). - Adjusted iframe URL handling in picker-style modals to use
iframeUrl.hrefdirectly in templates/tests.
Reviewed changes
Copilot reviewed 9 out of 9 changed files in this pull request and generated 1 comment.
Show a summary per file
| File | Description |
|---|---|
| packages/web-pkg/src/components/Modals/SaveAsModal.vue | Converted to <script setup> and kept iframe/message handling + save/open logic. |
| packages/web-pkg/src/components/Modals/FilePickerModal.vue | Converted to <script setup> and updated typed props for callback payload. |
| packages/web-pkg/src/components/Modals/ResourceConflictModal.vue | Converted to <script setup> with destructured prop defaults and retained conflict resolution callbacks. |
| packages/web-pkg/src/components/Modals/DatePickerModal.vue | Converted to <script setup> with typed emits for confirm/cancel. |
| packages/web-pkg/src/components/Modals/UnsavedChangesModal.vue | Converted to <script setup> with typed emits and close handler. |
| packages/web-pkg/src/components/Modals/SpaceMoveInfoModal.vue | Converted to <script setup> with typed defineProps. |
| packages/web-pkg/tests/unit/components/Modals/SaveAsModal.spec.ts | Updated assertions and method invocation to match script-setup instance shape. |
| packages/web-pkg/tests/unit/components/Modals/FilePickerModal.spec.ts | Updated assertions and method invocation to match script-setup instance shape. |
| packages/web-pkg/tests/unit/components/Modals/ResourceConflictModal.spec.ts | Updated computed/method access to match script-setup instance shape. |
馃挕 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
JammingBen
force-pushed
the
refactor/pkg-components-to-script-setup-#2
branch
from
August 5, 2026 12:15
296b710 to
ea43ab7
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
refs #1462