aboutsummaryrefslogtreecommitdiffstats
path: root/web_src
Commit message (Collapse)AuthorAgeFilesLines
* Optimize Layout Styles of Filelist (#33920)Kerwin Bryant13 days1-4/+14
| | | | | | | Align items --------- Co-authored-by: wxiaoguang <wxiaoguang@gmail.com>
* Fix file tree issues (#33916)Kerwin Bryant2025-03-172-2/+1
|
* Remove unused or abused styles (#33918)wxiaoguang2025-03-174-49/+2
| | | | | | * `top aligned` => `tw-align-top` * label list: it was broken, this PR fixes it * reference link: simplified * settings/repos: not affected
* Replace text-align classes with tailwind (#33905)silverwind2025-03-166-64/+1
| | | | | | | Small refactor to remove these CSS classes in favor of tailwind. --------- Co-authored-by: wxiaoguang <wxiaoguang@gmail.com>
* Simplify secure context check (#33906)silverwind2025-03-161-7/+4
| | | | As discussed in https://github.com/go-gitea/gitea/pull/33820/files#r1997532169.
* Update JS and PY deps, misc tweaks (#33903)silverwind2025-03-162-3/+5
| | | | | | | | | - Update all updateable dependencies - Add a few more unupgradable ones to updates blocklist - Adapt to breaking changes - Update to typescript 5.8, enable `erasableSyntaxOnly` which necessitated a change because of forbidden syntax - Misc cleanups - Tested htmx, easymde, swagger, chart.js
* Add file tree to file view page (#32721)Kerwin Bryant2025-03-156-0/+274
| | | | | | | | | | | Resolve #29328 This pull request introduces a file tree on the left side when reviewing files of a repository. --------- Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com> Co-authored-by: wxiaoguang <wxiaoguang@gmail.com>
* Add old svg class name to git entry icon (#33884)wxiaoguang2025-03-141-1/+1
| | | Fix https://github.com/go-gitea/gitea/pull/33837#discussion_r1995521288
* Fix various Fomantic UI and htmx problems (#33851)wxiaoguang2025-03-117-67/+16
| | | Also fix #31328, fix #33854
* Drop fomantic build (#33845)wxiaoguang2025-03-1125-25299/+12860
| | | | | | | | | | | | We would never update or build fomantic again, we have forked it as a private library long time ago. So just put the JS and CSS files in "fomantic/build" into git. And use "import" to use them. Remove "form.js", rewrite "tab" component. All source code is from official Fomantic UI build. Will apply patches in separate PRs.
* Add material icons for file list (#33837)wxiaoguang2025-03-103-0/+6
|
* Improve theme display (#30671)wxiaoguang2025-03-086-0/+24
| | | | | | Document: https://gitea.com/gitea/docs/pulls/180 ![image](https://github.com/go-gitea/gitea/assets/2114189/68e38573-b911-45d9-b7aa-40d96d836ecb)
* Do not show passkey on http sites (#33820)wxiaoguang2025-03-071-1/+10
| | | Fix #33615
* Update TypeScript types (#33799)Kerwin Bryant2025-03-053-8/+8
| | | Co-authored-by: wxiaoguang <wxiaoguang@gmail.com>
* Refactor repo-issue.ts (#33784)wxiaoguang2025-03-043-147/+110
| | | And remove jQuery
* Refactor repo-settings.ts (#33785)wxiaoguang2025-03-051-39/+39
| | | and remove jQuery
* Refactor admin/common.ts (#33788)wxiaoguang2025-03-041-87/+112
| | | Only remove jQuery
* Refactor initRepoBranchTagSelector to use new init framework (#33776)Kerwin Bryant2025-03-032-5/+6
| | | | | | | | Make "initRepoBranchTagSelector" to use new init framework and fix the abused "js-branch-tag-selector" styles --------- Co-authored-by: wxiaoguang <wxiaoguang@gmail.com>
* Refactor buttons to use new init framework (#33774)Kerwin Bryant2025-03-033-25/+27
| | | | | | | | | | Make buttons to use new init framework * "js-toggle-commit-body" * "show-panel/hide-panel/show-modal" * "copy-content" --------- Co-authored-by: wxiaoguang <wxiaoguang@gmail.com>
* Refactor markup and pdf-viewer to use new init framework (#33772)Kerwin Bryant2025-03-0315-209/+183
| | | | | | | | | | | | | | | | 1. Add some "render-content" classes to "markup" elements when the content is rendered 2. Use correct "markup" wrapper for "preview" (but not set that class on the tab) 3. Remove incorrect "markup" class from LFS file view, because there is no markup content * "edit-diff" is also removed because it does nothing 5. Use "initPdfViewer" for PDF viewer 6. Remove incorrect "content" class from milestone markup 7. Init all ".markup" elements by new init framework --------- Co-authored-by: wxiaoguang <wxiaoguang@gmail.com>
* Refactor global init code and add more comments (#33755)wxiaoguang2025-03-037-109/+135
| | | | | | | | | | | | | | | | | | | Follow up #33748 Now there are 3 "global" functions: * registerGlobalSelectorFunc: for all elements matching the selector, eg: `.ui.dropdown` * registerGlobalInitFunc: for `data-global-init="initInputAutoFocusEnd"` * registerGlobalEventFunc: for `data-global-click="onCommentReactionButtonClick"` And introduce `initGlobalInput` to replace old `initAutoFocusEnd` and `attachDirAuto`, use `data-global-init` to replace fragile `.js-autofocus-end` selector. Another benefit is that by the new approach, no matter how many times `registerGlobalInitFunc` is called, we only need to do one "querySelectorAll" in the last step, it could slightly improve the performance.
* Fix dynamic content loading init problem (#33748)wxiaoguang2025-03-018-126/+162
| | | | | | | | | | | | | | | | 1. Rewrite `dirauto.ts` to `observer.ts`. * We have been using MutationObserver for long time, it's proven that it is quite performant. * Now we extend its ability to handle more "init" works. 2. Use `observeAddedElement` to init all non-custom "dropdown". 3. Use `data-global-click` to handle click events from dynamically loaded elements. * By this new approach, the old fragile selector-based (`.comment-reaction-button`) mechanism is removed. 4. By the way, remove unused `.diff-box` selector, it was abused and never really used. A lot of FIXMEs in "repo-diff.ts" are completely fixed, newly loaded contents could work as expected.
* Refactor repo-diff.ts (#33746)wxiaoguang2025-02-282-67/+52
| | | Remove jQuery
* Use `git diff-tree` for `DiffFileTree` on diff pages (#33514)Alexander McRae2025-02-2810-196/+275
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Modify Diff View FileTree to show all files ## Changes * removes Show Status button on diff * uses `git diff-tree` to generate the file tree for the diff * doesn't reload the diff tree each time we load more files in the preview * selecting and unloaded file will keep loading until that file is loaded * removes `DiffFileList.vue` and "Show Stats" in diff options ## Open Questions * selecting and unloaded file will keep loading until that file is loaded. Is this behaviour okay? It matches what github does. ### Demo In this demo I set `git.MAX_GIT_DIFF_FILES=1` in my `app.ini` to demonstrate a worst case example. In most cases the behaviour isn't nearly as jarring as we load a bunch of files at a time. https://github.com/user-attachments/assets/72f29663-d6fc-472d-94fa-7fb5950c2836 --------- Co-authored-by: silverwind <me@silverwind.io> Co-authored-by: wxiaoguang <wxiaoguang@gmail.com>
* Improve "generate new access token" form (#33730)Guillaume2025-02-276-129/+10
| | | | | | | | | | | | | | | | | | | | | Fix: https://github.com/go-gitea/gitea/issues/33519 As discussed in [PR #33614](https://github.com/go-gitea/gitea/pull/33614), the ScopedAccessTokenSelector Vue component is not particularly useful. This PR removes the component and reverts to using HTML templates. It also introduces some (hopefully) useful refactoring. The Vue component was causing the UX bug reported in the linked issue. Required form fields are now properly working, as expected (see screenshot). ![Screenshot from 2025-02-25 22-00-28](https://github.com/user-attachments/assets/41167854-0718-48b0-a3ee-75ca3a7b8b20) --------- Co-authored-by: wxiaoguang <wxiaoguang@gmail.com>
* Clone repository with Tea CLI (#33725)Quentin2025-02-271-8/+41
| | | | | | | | | | | | This PR adds "Tea CLI" as a clone method. <img width="350" alt="Capture d’écran 2025-02-25 à 23 38 47" src="https://github.com/user-attachments/assets/8e86e54a-998b-45d1-9f20-167b449e79b6" /> --------- Signed-off-by: Quentin Guidée <quentin.guidee@gmail.com> Co-authored-by: wxiaoguang <wxiaoguang@gmail.com>
* Align sidebar gears to the right (#33721)Quentin2025-02-271-0/+10
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Currently, the issue/pr sidebar is hard to read visually. One of the reason is that the gear icons make reading difficult because they are "in the way" when reading, and not aligned together. This PR proposes to align them on the right. Actions are also better highlighted this way. ## Screenshots ### Issue | Before this PR | After this PR | | --- | --- | | <img width="322" alt="Capture d’écran 2025-02-25 à 19 59 39" src="https://github.com/user-attachments/assets/efdd13af-7b22-4f2b-8e65-dd17d6f3ffad" /> | <img width="322" alt="Capture d’écran 2025-02-25 à 19 58 56" src="https://github.com/user-attachments/assets/eeacc3f4-5e2c-4558-a4b3-0f1ab4742107" /> | ### Pull Request | Before this PR | After this PR | | --- | --- | | <img width="322" alt="Capture d’écran 2025-02-25 à 20 16 12" src="https://github.com/user-attachments/assets/c274b58b-ad50-4ad8-b3da-91dbabd1b120" /> | <img width="322" alt="Capture d’écran 2025-02-25 à 20 15 54" src="https://github.com/user-attachments/assets/ecfd6d60-a525-4767-872d-2ef84030d81e" /> | Signed-off-by: Quentin Guidée <quentin.guidee@gmail.com> Co-authored-by: Giteabot <teabot@gitea.io>
* Always show the "rerun" button for action jobs (#33692)wxiaoguang2025-02-241-9/+3
| | | And improve the mock code.
* Improve Open-with URL encoding (#33666)wxiaoguang2025-02-212-1/+16
| | | Fix #33665
* Fix mCaptcha bug (#33659)wxiaoguang2025-02-202-5/+10
| | | Fix #33658
* Fix typo in HTML attribute (#33599)silverwind2025-02-141-1/+1
|
* Optimize the dashboard (#32990)Kerwin Bryant2025-02-111-6/+29
| | | | | | | | | | | | | | | | | | | | | before: ![image](https://github.com/user-attachments/assets/d0b432e4-a521-4540-a489-d18b9c265674) after: ![image](https://github.com/user-attachments/assets/dbb8b387-d150-41e2-b12b-f9d8450e36d7) ----- ![image](https://github.com/user-attachments/assets/40dcd71e-344b-4043-9811-77227c71aed9) ----- Optimize the dashboard by adding welcoming messages or quick action entry points (such as adding a new repository or organization) to ensure that new users are not greeted by a blank page upon logging in. --------- Co-authored-by: wxiaoguang <wxiaoguang@gmail.com>
* Remove "class-name" from svg icon (#33540)wxiaoguang2025-02-095-30/+20
| | | Only use "class" attribute
* Add cropping support when modifying the user/org/repo avatar (#33498)Kerwin Bryant2025-02-066-14/+23
| | | | | | | | Fixed #33321 --------- Co-authored-by: wxiaoguang <wxiaoguang@gmail.com>
* Update feishu icon (#33470)Typed SIGTERM2025-02-011-0/+1
|
* Hide/disable unusable UI elements when a repository is archived (#33459)wxiaoguang2025-01-311-12/+6
| | | And by the way, remove some jQuery code
* Update `@github/text-expander-element`, adapt type imports (#33449)silverwind2025-01-311-1/+1
| | | | Followup to https://github.com/go-gitea/gitea/pull/33435, upstream issue is fixed so the imports are clean now.
* Fix issue sidebar dropdown keyboard support (#33447)wxiaoguang2025-01-301-1/+4
| | | Just a quick fix, fix #33444
* Update `@github/text-expander-element` to 2.9.0 (#33435)silverwind2025-01-291-15/+3
| | | | | | | | | Update and use their newly exported types. Tested, works. The import path is a bit suboptimal, to be fixed once https://github.com/github/text-expander-element/pull/75 is merged and released. Co-authored-by: Giteabot <teabot@gitea.io>
* Fix flex width (#33414)wxiaoguang2025-01-271-0/+1
| | | Fix #33409
* Clone button enhancements (#33362)silverwind2025-01-275-4/+12
| | | | | | | | | | - Add box-shadow to default tippy theme - Make colors for tabs match the ones from `.ui.tabular.menu` - Remove tippy arrow and slightly offset tooltip closer to the button - Fix setting of `aria-haspopup` when default role is used with tippy --------- Co-authored-by: wxiaoguang <wxiaoguang@gmail.com>
* Fix issue suggestion bug (#33389)wxiaoguang2025-01-261-8/+51
| | | Fix #33388
* Do not show unnecessary commit sign lock icon (#33387)wxiaoguang2025-01-251-1/+2
| | | Fix #33385
* Fix js error when edit issue (#33384)wxiaoguang2025-01-251-1/+1
|
* Repo homepage styling tweaks (#33289)silverwind2025-01-241-3/+2
| | | | | | | | | | | | | | | Reduce it to a value that results in `.repo-home-sidebar-top` and `.repo-home-sidebar-bottom` having 240px content width, the same as GitHub. Before: <img width="1333" alt="Screenshot 2025-01-15 at 18 28 34" src="https://github.com/user-attachments/assets/cf0fa21b-87be-40e3-a6cd-26d146bce9cc" /> After: <img width="1330" alt="Screenshot 2025-01-15 at 18 28 27" src="https://github.com/user-attachments/assets/28acd837-10f4-4176-b8a0-510cd28c8b8d" />
* Fix comment header padding (#33377)Typed SIGTERM2025-01-251-6/+2
|
* Enable Typescript `noImplicitAny` (#33322)silverwind2025-01-2261-265/+319
| | | | | | | Enable `noImplicitAny` and fix all issues. --------- Co-authored-by: wxiaoguang <wxiaoguang@gmail.com>
* Make issue suggestion work for all editors (#33340)wxiaoguang2025-01-215-16/+34
| | | And do not handle special keys when the text-expander popup exists
* Make tracked time representation display as hours (#33315)Vladimir Sysoev2025-01-191-20/+7
| | | | | | | | | | Estimated time represented in hours it might be convenient to have tracked time represented in the same way to be compared and managed. --------- Co-authored-by: Sysoev, Vladimir <i@vsysoev.ru> Co-authored-by: wxiaoguang <wxiaoguang@gmail.com>
* Trivial fixes (#33304)wxiaoguang2025-01-172-7/+18
| | | | | | | 1. the error check was added for go-git, it was caused by the empty `.keep` file in the test fixtures. 2. use `PostFormValue` instead of `PostForm.Get` (`Get` needs to parse the form ahead) 3. fix incorrect container text (it should show "Images" in the header but not "OS/Arch") 4. align maven xml 5. fix closed PR color&icon