gitea/templates/repo/diff
wxiaoguang 698ae7aa5b
Fix dynamic content loading init problem (#33748)
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.
2025-03-01 02:02:10 +00:00
..
blob_excerpt.tmpl Refactor tmpl and blob_excerpt (#32967) 2024-12-25 00:51:13 +08:00
box.tmpl Fix dynamic content loading init problem (#33748) 2025-03-01 02:02:10 +00:00
comment_form.tmpl Refactor markdown editor and use it for milestone description editor (#32688) 2024-12-04 02:11:34 +00:00
comment_form_datahandler.tmpl Make sure fmt catches all templates (#20979) 2022-08-31 23:58:54 +08:00
comments.tmpl Hide/disable unusable UI elements when a repository is archived (#33459) 2025-01-31 20:47:31 +08:00
compare.tmpl Refactor pull-request compare&create page (#33071) 2025-01-02 01:16:09 +08:00
conversation.tmpl Improve mobile review ui (#31091) 2024-05-28 13:41:37 +00:00
conversation_outdated.tmpl Improve user experience for outdated comments (#29050) 2024-02-08 01:50:48 +00:00
csv_diff.tmpl Fix CSV diff for added/deleted files (#21189) 2022-09-17 10:45:32 +08:00
escape_title.tmpl Refactor tmpl and blob_excerpt (#32967) 2024-12-25 00:51:13 +08:00
image_diff.tmpl Refactor image diff (#31444) 2024-06-22 04:52:09 +00:00
new_comment.tmpl Do not reload page after adding comments in Pull Request reviews (#13877) 2021-01-08 23:49:55 +02:00
new_review.tmpl Hide/disable unusable UI elements when a repository is archived (#33459) 2025-01-31 20:47:31 +08:00
options_dropdown.tmpl Use `git diff-tree` for `DiffFileTree` on diff pages (#33514) 2025-02-28 00:58:25 +00:00
section_code.tmpl Add template linting via djlint (#25212) 2023-06-14 18:17:58 +00:00
section_split.tmpl Refactor tmpl and blob_excerpt (#32967) 2024-12-25 00:51:13 +08:00
section_unified.tmpl De-emphasize signed commits (#31160) 2024-12-28 04:18:30 +08:00
stats.tmpl Migrate margin and padding helpers to tailwind (#30043) 2024-03-24 17:42:49 +01:00
whitespace_dropdown.tmpl code optimization (#31315) 2024-06-11 21:07:10 +08:00