Many hyperlinks are disabled.
Use anonymous login
to enable hyperlinks.
Overview
Comment: | Add comment about how last commit not related to Pinboard |
---|---|
Downloads: | Tarball | ZIP archive | SQL archive |
Timelines: | family | ancestors | descendants | both | master | trunk |
Files: | files | file ages | folders |
SHA3-256: |
b8e00b07b34ab27a62344b3e39b7451b |
User & Date: | base@atomicules.co.uk 2015-08-07 20:32:28 |
Context
2015-08-07
| ||
22:08 |
Revert commits 7036095 and 4fd8445
Figured out you can append to Lua functions so I'll leave this for | |
20:32 | Add comment about how last commit not related to Pinboard check-in: b8e00b07b3 user: base@atomicules.co.uk tags: master, trunk | |
20:22 |
Add fix for websites that don't text wrap properly
As a result of [this email] [1] on the ELinks-users list I worked out tags where I'd expect them to use acheck-in: b2ece6336b user: base@atomicules.co.uk tags: master, trunk | |
Changes
Changes to pinboard.lua.
︙ | ︙ | |||
51 52 53 54 55 56 57 58 59 60 61 62 63 64 | return html elseif string.find(url, "://pinboard.in/add%?url=") then --need to escape the ? here --Remove delete and destroy from the add page. html = string.gsub (html, '<div style="display:inline" id="delete_.-</div>', '') html = string.gsub (html, '<div style="visibility:hidden;display:none" class="delete_div" id="destroy_.-</div>', '') return html --Fix none, wrapping pages. For now, just this one elseif string.find(url, "antirez") then --Change <pre> to <div> this is very hacky and prone to failure html = string.gsub (html, '<pre(.-)</pre>', '<div%1</div>') --html = string.gsub (html, '<pre(.-)</pre>.-</div><div.->', '<div%1</div>') --But since we only want to do this for pre not followed by code, change any divs followed by code back to pre html = string.gsub (html, '<div(.-<code.-</code>.-)</div>', '<pre%1</pre>') return html | > | 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 | return html elseif string.find(url, "://pinboard.in/add%?url=") then --need to escape the ? here --Remove delete and destroy from the add page. html = string.gsub (html, '<div style="display:inline" id="delete_.-</div>', '') html = string.gsub (html, '<div style="visibility:hidden;display:none" class="delete_div" id="destroy_.-</div>', '') return html --Fix none, wrapping pages. For now, just this one --This is nothing to do with Pinboard, but I can only have one pre_format_html_hook elseif string.find(url, "antirez") then --Change <pre> to <div> this is very hacky and prone to failure html = string.gsub (html, '<pre(.-)</pre>', '<div%1</div>') --html = string.gsub (html, '<pre(.-)</pre>.-</div><div.->', '<div%1</div>') --But since we only want to do this for pre not followed by code, change any divs followed by code back to pre html = string.gsub (html, '<div(.-<code.-</code>.-)</div>', '<pre%1</pre>') return html |
︙ | ︙ |