Skip to content

feat: source selection modal for connection import (XTB vs PPTB)#500

Merged
Power-Maverick merged 2 commits intodevfrom
copilot/add-custom-modal-popup-for-import
Mar 29, 2026
Merged

feat: source selection modal for connection import (XTB vs PPTB)#500
Power-Maverick merged 2 commits intodevfrom
copilot/add-custom-modal-popup-for-import

Conversation

Copy link
Copy Markdown
Contributor

Copilot AI commented Mar 28, 2026

Replaces the combined file picker + format auto-detection with an explicit source selection modal before the file picker opens. Resolves user confusion around importing XrmToolBox connections.

Changes

  • New modal (src/renderer/modals/importConnectionSource/)

    • Two selectable cards: XrmToolBox (restricts picker to .xml) and Power Platform ToolBox (restricts picker to .json)
    • XTB card selected by default; selecting it reveals an inline hint panel with step-by-step XTB export instructions and the default ConnectionsList.xml path
    • Follows existing controller/view modal pattern (channel-based messaging via modalBridge)
  • connectionManagement.ts

    • importConnections() now opens the source modal first, then opens a format-restricted file picker — no more .xml/.json auto-detection heuristic
    • Wired using the same promise-handler pattern as selectConnection and editConnection modals
  • Use a meaningful title for the pull request.

  • Follow the guidelines from the CONTRIBUTING.md.

  • Test the change in your own code. (Compile and run)

  • Resolve all GH Copilot comments.

@github-actions
Copy link
Copy Markdown

Bundle Size Report 📦

Bundle Size
Main Process 954.15 KB
Renderer JS 540.15 KB
Renderer CSS 95.48 KB
Total 1.55 MB

Bundle Analysis Reports

The detailed bundle analysis reports are available in the workflow artifacts:

  • 📊 Main Process: stats-main.html
  • 📊 Renderer Process: stats-renderer.html

Download the artifacts from the workflow run to view interactive visualizations.


Bundle size tracking is now active! This helps prevent bundle bloat.

@Power-Maverick Power-Maverick marked this pull request as ready for review March 28, 2026 16:46
Copilot AI review requested due to automatic review settings March 28, 2026 16:46
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Adds an explicit “import source” selection step before the connection import file picker, to remove ambiguity between XrmToolBox (XML) and Power Platform ToolBox (JSON) imports in the renderer connection management flow.

Changes:

  • Introduced a new BrowserWindow modal (controller + view) to select import source (XTB vs PPTB) and show XTB export guidance.
  • Updated importConnections() to open the source selection modal first, then open a format-restricted file picker and parse accordingly.
  • Added modal wiring (channels + promise handlers) in connectionManagement.ts using the existing modalBridge pattern.

Reviewed changes

Copilot reviewed 3 out of 3 changed files in this pull request and generated 5 comments.

File Description
src/renderer/modules/connectionManagement.ts Adds a new modal bridge + promise flow and updates importConnections() to use source selection before file picking/parsing.
src/renderer/modals/importConnectionSource/view.ts New modal UI with two selectable cards (XTB/PPTB) and an XTB export hint panel.
src/renderer/modals/importConnectionSource/controller.ts New modal controller script wiring selection, cancel/close, and confirm messaging via modalBridge.

@github-actions
Copy link
Copy Markdown

Bundle Size Report 📦

Bundle Size
Main Process 955.75 KB
Renderer JS 544.83 KB
Renderer CSS 95.56 KB
Total 1.56 MB

Bundle Analysis Reports

The detailed bundle analysis reports are available in the workflow artifacts:

  • 📊 Main Process: stats-main.html
  • 📊 Renderer Process: stats-renderer.html

Download the artifacts from the workflow run to view interactive visualizations.


Bundle size tracking is now active! This helps prevent bundle bloat.

@Power-Maverick Power-Maverick merged commit 18dc4e5 into dev Mar 29, 2026
3 checks passed
@Power-Maverick Power-Maverick deleted the copilot/add-custom-modal-popup-for-import branch March 29, 2026 03:30
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.

3 participants