Hacktoberfest 2026:メンテナが10月に向けて印を付けた、オープンで初心者向けの issue。 Hacktoberfest の issue を見る

Don’t ask “Save draft?” unless the text has been edited

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

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

評価

難易度
2/5
見積もり時間
1〜3時間
初心者へのやさしさ
48/100
issue の種類
バグ
明瞭さ
明確に書かれている
活発さ
停滞
技術スタック
java
領域
frontend

調査の方向性

Issue に記載されている下書きの開始と Back の処理フローから着手し、元のテキストがどこに保存され、現在の alert がどこで表示されるかを確認します。変更せずに戻った場合は確認を求めずに下書きが破棄され、テキストを変更した場合は既存の保存/破棄プロンプトが引き続き表示されれば完了です。

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

説明

When I open a draft by double-clicking it, then change my mind and hit Back without typing any text, I am still prompted with this alert:

Save draft?
[Discard] [Save]

This alert should only be shown if the text at the moment I hit Back is different from the text as it was when I first opened the draft.

For the Discard feature to work, you must already be saving the original text when I first open the draft. So this feature should only need one extra if, plus a call to your discard function in the alternative branch. In pseudo-code:

if (textField.currentValue.equals(draftModel.originalValue)) {
    discard();
} else {
    // show prompt and save or discard as you currently do
}
主要言語
Java
スター
4
フォーク
0
PR マージ指標
30日以内にマージされた PR はありません

環境構築

このプロジェクトには開発コンテナ、Dockerfile、コントリビューションガイドがありません。まず README を読み、一般的な手順ははじめてのコントリビューションガイドを参照してください。

はじめの一歩

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

fadelakin/drafts のほかの issue

fadelakin/drafts の issue をすべて見る

似ている issue

Java の issue をもっと見る

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

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