forgejo/web_src/js
oliverpool 8f28cdefe0
Some checks are pending
/ release (push) Waiting to run
testing-integration / test-unit (push) Waiting to run
testing-integration / test-sqlite (push) Waiting to run
testing-integration / test-mariadb (v10.6) (push) Waiting to run
testing-integration / test-mariadb (v11.8) (push) Waiting to run
testing / backend-checks (push) Waiting to run
testing / frontend-checks (push) Waiting to run
testing / test-unit (push) Blocked by required conditions
testing / test-e2e (push) Blocked by required conditions
testing / test-remote-cacher (redis) (push) Blocked by required conditions
testing / test-remote-cacher (valkey) (push) Blocked by required conditions
testing / test-remote-cacher (garnet) (push) Blocked by required conditions
testing / test-remote-cacher (redict) (push) Blocked by required conditions
testing / test-mysql (push) Blocked by required conditions
testing / test-pgsql (push) Blocked by required conditions
testing / test-sqlite (push) Blocked by required conditions
testing / security-check (push) Blocked by required conditions
feat(ui): add switch between formats when previewing CITATION.{cff,bib} files (#9103)
See #8222 for context (loosely related to #4595).

## Implemented changes

The conversion logic is kept in the frontend and the related npm libraries are lazy-loaded (unchanged).

### Show some tabs on the preview of the `CITATION.*` file to switch between the formats:

![image](/attachments/be02656f-d906-4191-aa84-d666ee5a90ba)
![image](/attachments/240384e3-dec8-4f02-94e6-261143193541)

### Convert the "Cite repository" to a simple link to the citation file

So that this change can be considered non-breaking

## Current state (before this PR)

The last non-test call of `git.Blob.GetBlobContent` is made to retrieve the content of an eventual CITATION file.
This is available in the `...` menu near the clone URL:
![image](/attachments/ef79128d-ee3f-4e43-a74d-a00e4dcfe6b4)
And is displayed as a popup:

![image](/attachments/7aa930f9-0766-47b9-8145-cbebb5b051b0)

Co-authored-by: 0ko <0ko@noreply.codeberg.org>
Reviewed-on: https://codeberg.org/forgejo/forgejo/pulls/9103
Reviewed-by: Gusted <gusted@noreply.codeberg.org>
Reviewed-by: 0ko <0ko@noreply.codeberg.org>
Co-authored-by: oliverpool <git@olivier.pfad.fr>
Co-committed-by: oliverpool <git@olivier.pfad.fr>
2025-11-14 14:39:20 +01:00
..
components feat: display detailed action run diagnostics (#9966) 2025-11-11 04:39:02 +01:00
features feat(ui): add switch between formats when previewing CITATION.{cff,bib} files (#9103) 2025-11-14 14:39:20 +01:00
markup fix: Fix invisible iframes with RENDER_CONTENT_MODE=iframe (#8378) 2025-09-06 16:23:01 +02:00
modules feat(ui): arrow key navigation in dropdown (#10033) 2025-11-10 13:35:38 +01:00
render fix: don't show ConEmu OSC escape sequences (#9875) 2025-10-31 07:24:23 +01:00
standalone [CHORE] Proper chunking for swagger 2024-08-22 15:48:05 +02:00
utils fix: prevent page jumps due to textarea auto resizing (#7569) 2025-10-01 03:47:19 +02:00
vendor Vendor jquery.are-you-sure with strict mode fixes (#26901) 2023-09-06 00:02:44 +00:00
webcomponents feat(ui): add switch between formats when previewing CITATION.{cff,bib} files (#9103) 2025-11-14 14:39:20 +01:00
bootstrap.js Suppress Monaco JavaScript errors in Safari (#3805) 2024-05-18 21:07:09 +00:00
bootstrap.test.js Avoid duplicate JS error messages on UI (#28873) 2024-01-21 14:23:08 +00:00
emoji.test.js chore: add javascript unit test 2025-08-10 23:11:39 +02:00
htmx.js Update dependency htmx.org to v2 (forgejo) (#8342) 2025-06-29 13:52:24 +02:00
index.js feat: convert create/rename branch and create tag to native dialog (#9760) 2025-10-30 21:06:14 +01:00
jquery.js Forbid variables containing jQuery collections not having the $ prefix (#29839) 2024-03-20 08:46:30 +01:00
svg.js Reimplement editor Tab handling with accessibility safeguards (#6813) 2025-05-25 19:17:03 +02:00
svg.test.js Remove "class-name" from svg icon (#33540) 2025-02-25 12:56:30 +01:00
types.d.ts feat: run tsc in CI (#9574) 2025-10-10 15:48:45 +02:00
utils.js chore: add new lint rules 2024-10-23 08:10:18 +02:00
utils.test.js chore(ci): testSleep: show actual times on failures (#8271) 2025-06-25 15:58:55 +02:00
vitest.setup.js feat: replace cross origin protection (#9830) 2025-10-29 22:43:22 +01:00