On Tue, 6 Oct 2026 09:27:53 GMT, Nizar Benalla <[email protected]> wrote:
>> Hannes Wallnöfer has updated the pull request incrementally with one >> additional commit since the last revision: >> >> Refine scroll margin > > make/Docs.gmk line 726: > >> 724: REPLACEMENTS := \ >> 725: <style> => <script>const pathtoroot = "../../api/";</script> \ >> 726: <script >> src="../../api/script-files/script.js"></script> \ > > Could the icon and js script be copied instead? > If someone generates the specs using `make docs-jdk-specs` or `make > docs-jdk-zip`, the theme button will be missing That's a very good point. I originally chose to use the API docs script to avoid duplication of code, and because the script contains localized messages (used both in theme picker and permalinks), and the generation of the localized script is javadoc-specific and not easy to replicate in other build targets. But AFAICT other specs and tool guides are always generated with US locale, so hard-coded messages are ok. And the API script carries a lot of functionality that is not needed by other specs. So I think it's the better solution to create a small dedicatet script for the specs. The `jdk-default.js` script I added is a minimally modified subset of the API-docs script. There is some duplication of code, but I think we can live with it. I uploaded new generated specs produced with this latest commit: https://cr.openjdk.org/~hannesw/8377548/docs.02/ ------------- PR Review Comment: https://git.openjdk.org/jdk/pull/33127#discussion_r4217219195
