Fossil

Check-in [8c7e2620]
Login

Many hyperlinks are disabled.
Use anonymous login to enable hyperlinks.

Overview
Comment:Avoid line breaks between the copy button and the hash on the /info page.
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | copybtn.js-demonstration
Files: files | file ages | folders
SHA3-256: 8c7e26208b46136253bc99702fc04f910a44476025a9279fcbdbbed81889844e
User & Date: florian 2019-06-01 07:12:00
Context
2019-06-02
11:31
Add a TH1 command to output text with a copy button, and modify the default View Ticket Page template to include a copy button for the ticket hash (UUID). check-in: 68405c3f user: florian tags: copybtn.js-demonstration
2019-06-01
07:12
Avoid line breaks between the copy button and the hash on the /info page. check-in: 8c7e2620 user: florian tags: copybtn.js-demonstration
07:07
Also use the now global hash_digits() function in src/info.c, and set the copy length limit to FOSSIL_HASH_DIGITS_URL for consistency with the copy buttons on the tooltips. check-in: 710229e7 user: florian tags: copybtn.js-demonstration
Changes
Hide Diffs Unified Diffs Ignore Whitespace Patch

Changes to src/info.c.

792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
    @     %z(href("%R/tree?ci=%!S",zUuid))files</a>
    @   | %z(href("%R/fileage?name=%!S",zUuid))file ages</a>
    @   | %z(href("%R/tree?nofiles&type=tree&ci=%!S",zUuid))folders</a>
    @   </td>
    @ </tr>

    @ <tr><th>%s(hname_alg(nUuid)):</th><td>
    @ <span class="copy-button" id="copy-fullhash" data-copytarget="fullhash"
    @ data-copylength="%d(hash_digits(1))"></span>
    @ <span id="fullhash">%.32s(zUuid)<wbr>%s(zUuid+32)</span>
    if( g.perm.Setup ){
      @ (Record ID: %d(rid))
    }
    @ </td></tr>
    @ <tr><th>User&nbsp;&amp;&nbsp;Date:</th><td>
    hyperlink_to_user(zUser,zDate," on ");
    hyperlink_to_date(zDate, "</td></tr>");







|
|
|







792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
    @     %z(href("%R/tree?ci=%!S",zUuid))files</a>
    @   | %z(href("%R/fileage?name=%!S",zUuid))file ages</a>
    @   | %z(href("%R/tree?nofiles&type=tree&ci=%!S",zUuid))folders</a>
    @   </td>
    @ </tr>

    @ <tr><th>%s(hname_alg(nUuid)):</th><td>
    @ <span class="copy-button" id="copy-fullhash"
    @   data-copytarget="fullhash" data-copylength="%d(hash_digits(1))">
    @ </span>&nbsp;<span id="fullhash">%.32s(zUuid)<wbr>%s(zUuid+32)</span>
    if( g.perm.Setup ){
      @ (Record ID: %d(rid))
    }
    @ </td></tr>
    @ <tr><th>User&nbsp;&amp;&nbsp;Date:</th><td>
    hyperlink_to_user(zUser,zDate," on ");
    hyperlink_to_date(zDate, "</td></tr>");