Correction affichage edition

Signed-off-by: Gato <cedric@goutailler-olivier.fr>
This commit is contained in:
2026-05-28 18:19:11 +02:00
parent e68232de21
commit 36cebe5144
4 changed files with 71 additions and 4 deletions
@@ -58,6 +58,7 @@ export class IssueDetail {
protected showAddDependency = false;
protected selectedCandidateId: number | null = null;
protected editingDescription = false;
private _descriptionBeforeEdit = '';
protected showAddToEpic = false;
protected selectedEpicCandidateId: number | null = null;
protected showCreateInEpic = false;
@@ -237,6 +238,21 @@ export class IssueDetail {
return !!this.issue.epic;
}
protected startEditDescription(): void {
this._descriptionBeforeEdit = this.issue.description;
this.editingDescription = true;
}
protected async saveDescription(): Promise<void> {
this.editingDescription = false;
await this.saveIssue();
}
protected cancelEditDescription(): void {
this.issue.description = this._descriptionBeforeEdit;
this.editingDescription = false;
}
protected onDescriptionPaste(event: ClipboardEvent): void {
const ta = event.target as HTMLTextAreaElement;
const start = ta.selectionStart;