aboutsummaryrefslogtreecommitdiffstats
path: root/web_src/js
diff options
context:
space:
mode:
authorIllya Marchenko <github-hek842t@social.mail.stuzer.link>2024-12-05 15:07:53 +0200
committerGitHub <noreply@github.com>2024-12-05 13:07:53 +0000
commit936665bf857787fb653a40dd202d0333c14e0e7e (patch)
treeba9a8676e18c95a9463239d0eb298c7cf05724d8 /web_src/js
parentc5422fae9a41b870257b8cbe148ff8e661b190a0 (diff)
downloadgitea-936665bf857787fb653a40dd202d0333c14e0e7e.tar.gz
gitea-936665bf857787fb653a40dd202d0333c14e0e7e.zip
Issue time estimate, meaningful time tracking (#23113)
Redesign the time tracker side bar, and add "time estimate" support (in "1d 2m" format) Closes #23112 --------- Co-authored-by: stuzer05 <stuzer05@gmail.com> Co-authored-by: Yarden Shoham <hrsi88@gmail.com> Co-authored-by: silverwind <me@silverwind.io> Co-authored-by: 6543 <6543@obermui.de> Co-authored-by: wxiaoguang <wxiaoguang@gmail.com>
Diffstat (limited to 'web_src/js')
-rw-r--r--web_src/js/features/repo-issue.ts31
-rw-r--r--web_src/js/index.ts2
2 files changed, 0 insertions, 33 deletions
diff --git a/web_src/js/features/repo-issue.ts b/web_src/js/features/repo-issue.ts
index a59e4319ab..477edbeb5f 100644
--- a/web_src/js/features/repo-issue.ts
+++ b/web_src/js/features/repo-issue.ts
@@ -11,37 +11,6 @@ import {initRepoIssueSidebar} from './repo-issue-sidebar.ts';
const {appSubUrl} = window.config;
-export function initRepoIssueTimeTracking() {
- $(document).on('click', '.issue-add-time', () => {
- $('.issue-start-time-modal').modal({
- duration: 200,
- onApprove() {
- $('#add_time_manual_form').trigger('submit');
- },
- }).modal('show');
- $('.issue-start-time-modal input').on('keydown', (e) => {
- if (e.key === 'Enter') {
- $('#add_time_manual_form').trigger('submit');
- }
- });
- });
- $(document).on('click', '.issue-start-time, .issue-stop-time', () => {
- $('#toggle_stopwatch_form').trigger('submit');
- });
- $(document).on('click', '.issue-cancel-time', () => {
- $('#cancel_stopwatch_form').trigger('submit');
- });
- $(document).on('click', 'button.issue-delete-time', function () {
- const sel = `.issue-delete-time-modal[data-id="${$(this).data('id')}"]`;
- $(sel).modal({
- duration: 200,
- onApprove() {
- $(`${sel} form`).trigger('submit');
- },
- }).modal('show');
- });
-}
-
/**
* @param {HTMLElement} item
*/
diff --git a/web_src/js/index.ts b/web_src/js/index.ts
index 48c4b76cee..f93c3495af 100644
--- a/web_src/js/index.ts
+++ b/web_src/js/index.ts
@@ -26,7 +26,6 @@ import {initPdfViewer} from './render/pdf.ts';
import {initUserAuthOauth2, initUserCheckAppUrl} from './features/user-auth.ts';
import {
initRepoIssueReferenceRepositorySearch,
- initRepoIssueTimeTracking,
initRepoIssueWipTitle,
initRepoPullRequestMergeInstruction,
initRepoPullRequestAllowMaintainerEdit,
@@ -184,7 +183,6 @@ onDomReady(() => {
initRepoIssueList,
initRepoIssueSidebarList,
initRepoIssueReferenceRepositorySearch,
- initRepoIssueTimeTracking,
initRepoIssueWipTitle,
initRepoMigration,
initRepoMigrationStatusChecker,