Re: link handling in js-reader

2021-03-10 Thread Gavin Smith
On Thu, Mar 04, 2021 at 09:20:53PM -0600, Jacob Bachmeyer wrote: > Per Bothner wrote: > > On 3/4/21 12:16 PM, Gavin Smith wrote: > > > On Wed, Mar 03, 2021 at 08:25:59PM -0600, Jacob Bachmeyer wrote: > > > > > > The texinfo tool that generates HTML has the ToC, so really the correct > > > > soluti

Re: link handling in js-reader

2021-03-04 Thread Jacob Bachmeyer
Per Bothner wrote: On 3/4/21 12:16 PM, Gavin Smith wrote: On Wed, Mar 03, 2021 at 08:25:59PM -0600, Jacob Bachmeyer wrote: The texinfo tool that generates HTML has the ToC, so really the correct solution here would be for the HTML output to include the 'target' attributes directly. JS can th

Re: link handling in js-reader

2021-03-04 Thread Per Bothner
On 3/4/21 12:16 PM, Gavin Smith wrote: On Wed, Mar 03, 2021 at 08:25:59PM -0600, Jacob Bachmeyer wrote: The texinfo tool that generates HTML has the ToC, so really the correct solution here would be for the HTML output to include the 'target' attributes directly. JS can then determine interna

Re: link handling in js-reader

2021-03-04 Thread Gavin Smith
On Wed, Mar 03, 2021 at 08:25:59PM -0600, Jacob Bachmeyer wrote: > Per Bothner wrote: > > [...] > > Ideally, one could determine which links are internal by checking for an > > entry in the table-of-contents. However, that is bit complicated, > > mainly because sub-pages don't have access to the T

Re: link handling in js-reader

2021-03-03 Thread Jacob Bachmeyer
Per Bothner wrote: [...] Ideally, one could determine which links are internal by checking for an entry in the table-of-contents. However, that is bit complicated, mainly because sub-pages don't have access to the ToC, so it would have to involve message sending between JavaScript contexts (no b

Re: link handling in js-reader

2021-03-03 Thread Per Bothner
On 3/3/21 9:07 AM, Gavin Smith wrote: On Wed, Mar 03, 2021 at 08:09:01AM -0800, Per Bothner wrote: The JavaScript info reader calls the fix_links function to convert cross-references to special "magic" links that load a different page (or scroll within the current one). "External" references are

Re: link handling in js-reader

2021-03-03 Thread Gavin Smith
On Wed, Mar 03, 2021 at 08:09:01AM -0800, Per Bothner wrote: > The JavaScript info reader calls the fix_links function to convert > cross-references to special "magic" links that load a different page > (or scroll within the current one). "External" references are unchanged, > except the 'target' a

link handling in js-reader

2021-03-03 Thread Per Bothner
The JavaScript info reader calls the fix_links function to convert cross-references to special "magic" links that load a different page (or scroll within the current one). "External" references are unchanged, except the 'target' attribute is set so they open in a new tab. This logic is rather bro