UX: Auto-select single Git account/branch in Provider settings and warn about unsaved changes

オープン
#6,140 コメント 1 件 リアクション 0 件 担当者 0 名 GitHub で見る

メンテナーはふだん 1 日以内に返信

まだ誰も着手していません。

評価

難易度
3/5
見積もり時間
1〜2日
初心者へのやさしさ
72/100
issue の種類
機能追加
明瞭さ
明確に書かれている
活発さ
活発
技術スタック
next.js, typescript
領域
frontend

調査の方向性

Start with the Provider tab used when creating or editing an Application or Compose service, then trace how provider accounts and repository branches are populated for GitHub, GitLab, Bitbucket, and Gitea. Add account and branch preselection behavior and a visible dirty-state indicator near the Save button, covering both Application and Compose service forms. Done means single-account and single-branch choices are preselected, multiple accounts use the most recently added one, and unsaved provider changes are clearly indicated.

索引モデルが issue の本文から書いたものです。

説明

enhancement
What problem will this feature address?

When creating or editing an Application or Compose service, the Provider tab ("Select the source of your code": GitHub / GitLab / Bitbucket / Gitea / Git / Raw) needs extra clicks even when there is only one possible choice. It also gives no warning about unsaved changes:

  1. Git account is not preselected. GitHub is already the default provider tab, but the account select stays empty. I have exactly one GitHub account connected, and I still have to open the dropdown and pick it every time.
  2. Branch is not preselected. When the selected repository has only one branch, I still have to pick it by hand.
  3. No unsaved-changes indicator. If I change provider settings and don't click save, nothing tells me. The changes are easy to lose by switching tabs or navigating away.
Describe the solution you'd like
  1. Account auto-select
    • If only one account is configured for the selected provider, preselect it.
    • If several exist, preselect the most recently created/added one.
    • (Future, optional): let users mark one account as "default" per provider. This needs a schema change, so it may be out of scope for this issue.
  2. Branch auto-select
    • If the selected repository has exactly one branch, preselect it.
    • (Optional): otherwise preselect the repository's default branch (e.g. main), if the provider API returns it.
  3. Unsaved-changes indicator
    • Show a visible hint, e.g. a banner or badge near the Save button, when the provider form is dirty.
    • Optionally warn before leaving the tab or page while changes are unsaved.

This applies to all Git providers (GitHub, GitLab, Bitbucket, Gitea), for both Applications and Compose services.

Describe alternatives you've considered

Selecting everything by hand every time. It works, but it's repetitive, and it's easy to forget to save.

Additional context

Related (closed) issues about unsaved changes in other forms: #2538, #2064.

Will you send a PR to implement it?

Maybe, need help

主要言語
TypeScript
スター
38.8k
フォーク
3.2k
平均マージ
1日 10時間
マージ済み PR(30日)
110

環境構築

Codespaces で開く

このプロジェクトの開発コンテナを、あなたの GitHub アカウントでブラウザ上に起動します。

はじめの一歩

  1. issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
  2. 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
  3. リポジトリをフォークし、ブランチを切って変更します。
  4. issue 番号を参照したプルリクエストを送ります。

Dokploy/dokploy のほかの issue

Dokploy/dokploy の issue をすべて見る

似ている issue

TypeScript の issue をもっと見る

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。