{"action":"created","issue":{"url":"https://api.github.com/repos/asciidoctor/asciidoctor/issues/2019","repository_url":"https://api.github.com/repos/asciidoctor/asciidoctor","labels_url":"https://api.github.com/repos/asciidoctor/asciidoctor/issues/2019/labels{/name}","comments_url":"https://api.github.com/repos/asciidoctor/asciidoctor/issues/2019/comments","events_url":"https://api.github.com/repos/asciidoctor/asciidoctor/issues/2019/events","html_url":"https://github.com/asciidoctor/asciidoctor/issues/2019","id":206979562,"number":2019,"title":"User specified footnoteref ID which is the same as the footnote number leads to duplicate HTML id attributes","user":{"login":"djerius","id":196875,"avatar_url":"https://avatars2.githubusercontent.com/u/196875?v=4","gravatar_id":"","url":"https://api.github.com/users/djerius","html_url":"https://github.com/djerius","followers_url":"https://api.github.com/users/djerius/followers","following_url":"https://api.github.com/users/djerius/following{/other_user}","gists_url":"https://api.github.com/users/djerius/gists{/gist_id}","starred_url":"https://api.github.com/users/djerius/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/djerius/subscriptions","organizations_url":"https://api.github.com/users/djerius/orgs","repos_url":"https://api.github.com/users/djerius/repos","events_url":"https://api.github.com/users/djerius/events{/privacy}","received_events_url":"https://api.github.com/users/djerius/received_events","type":"User","site_admin":false},"labels":[{"id":6197064,"url":"https://api.github.com/repos/asciidoctor/asciidoctor/labels/bug","name":"bug","color":"fc2929","default":true}],"state":"open","locked":false,"assignee":{"login":"mojavelinux","id":79351,"avatar_url":"https://avatars2.githubusercontent.com/u/79351?v=4","gravatar_id":"","url":"https://api.github.com/users/mojavelinux","html_url":"https://github.com/mojavelinux","followers_url":"https://api.github.com/users/mojavelinux/followers","following_url":"https://api.github.com/users/mojavelinux/following{/other_user}","gists_url":"https://api.github.com/users/mojavelinux/gists{/gist_id}","starred_url":"https://api.github.com/users/mojavelinux/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mojavelinux/subscriptions","organizations_url":"https://api.github.com/users/mojavelinux/orgs","repos_url":"https://api.github.com/users/mojavelinux/repos","events_url":"https://api.github.com/users/mojavelinux/events{/privacy}","received_events_url":"https://api.github.com/users/mojavelinux/received_events","type":"User","site_admin":false},"assignees":[{"login":"mojavelinux","id":79351,"avatar_url":"https://avatars2.githubusercontent.com/u/79351?v=4","gravatar_id":"","url":"https://api.github.com/users/mojavelinux","html_url":"https://github.com/mojavelinux","followers_url":"https://api.github.com/users/mojavelinux/followers","following_url":"https://api.github.com/users/mojavelinux/following{/other_user}","gists_url":"https://api.github.com/users/mojavelinux/gists{/gist_id}","starred_url":"https://api.github.com/users/mojavelinux/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mojavelinux/subscriptions","organizations_url":"https://api.github.com/users/mojavelinux/orgs","repos_url":"https://api.github.com/users/mojavelinux/repos","events_url":"https://api.github.com/users/mojavelinux/events{/privacy}","received_events_url":"https://api.github.com/users/mojavelinux/received_events","type":"User","site_admin":false}],"milestone":{"url":"https://api.github.com/repos/asciidoctor/asciidoctor/milestones/22","html_url":"https://github.com/asciidoctor/asciidoctor/milestone/22","labels_url":"https://api.github.com/repos/asciidoctor/asciidoctor/milestones/22/labels","id":2409315,"number":22,"title":"v1.5.7","description":"","creator":{"login":"mojavelinux","id":79351,"avatar_url":"https://avatars2.githubusercontent.com/u/79351?v=4","gravatar_id":"","url":"https://api.github.com/users/mojavelinux","html_url":"https://github.com/mojavelinux","followers_url":"https://api.github.com/users/mojavelinux/followers","following_url":"https://api.github.com/users/mojavelinux/following{/other_user}","gists_url":"https://api.github.com/users/mojavelinux/gists{/gist_id}","starred_url":"https://api.github.com/users/mojavelinux/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mojavelinux/subscriptions","organizations_url":"https://api.github.com/users/mojavelinux/orgs","repos_url":"https://api.github.com/users/mojavelinux/repos","events_url":"https://api.github.com/users/mojavelinux/events{/privacy}","received_events_url":"https://api.github.com/users/mojavelinux/received_events","type":"User","site_admin":false},"open_issues":3,"closed_issues":105,"state":"open","created_at":"2017-03-24T14:37:18Z","updated_at":"2018-04-29T02:06:48Z","due_on":null,"closed_at":null},"comments":0,"created_at":"2017-02-11T13:23:46Z","updated_at":"2018-04-29T10:31:15Z","closed_at":null,"author_association":"NONE","body":"I couldn't come up with a clever footnote ID, so I decided to use numbers, e.g.\r\n\r\n```\r\nfootnoteref:[1,Footnote 1]\r\nfootnoteref:[2,Footnote 2]\r\nfootnoteref:[3,Footnote 3]\r\n```\r\n\r\nMuch to my surprise, the resultant footnote links didn't target the footnotes at the bottom of the page; instead they targetted  the first time the footnote was referenced in the body of the text.\r\n\r\nHere's the relevant output html for the references in the body:\r\n\r\n```\r\n<sup class=\"footnote\" id=\"_footnote_1\">[<a id=\"_footnoteref_1\" class=\"footnote\" href=\"#_footnote_1\" title=\"View footnote.\">1</a>]</sup>\r\n<sup class=\"footnote\" id=\"_footnote_2\">[<a id=\"_footnoteref_2\" class=\"footnote\" href=\"#_footnote_2\" title=\"View footnote.\">2</a>]</sup>\r\n<sup class=\"footnote\" id=\"_footnote_3\">[<a id=\"_footnoteref_3\" class=\"footnote\" href=\"#_footnote_3\" title=\"View footnote.\">3</a>]</sup>\r\n```\r\n\r\nAnd for the footnotes\r\n\r\n```\r\n<div class=\"footnote\" id=\"_footnote_1\">\r\n<a href=\"#_footnoteref_1\">1</a>. Footnote 1\r\n</div>\r\n<div class=\"footnote\" id=\"_footnote_2\">\r\n<a href=\"#_footnoteref_2\">2</a>. Footnote 2\r\n</div>\r\n<div class=\"footnote\" id=\"_footnote_3\">\r\n<a href=\"#_footnoteref_3\">3</a>. Footnote 3\r\n```\r\n\r\nThe `sup` elements in the references have the same id attribute as the `class` elements in the definitions.\r\n\r\nPlease consider making the prefix in the `sup` `id` attribute unique to them so that they cannot clash with those in the definitions.\r\n\r\nThanks,\r\nDiab\r\n\r\n"},"comment":{"url":"https://api.github.com/repos/asciidoctor/asciidoctor/issues/comments/385241491","html_url":"https://github.com/asciidoctor/asciidoctor/issues/2019#issuecomment-385241491","issue_url":"https://api.github.com/repos/asciidoctor/asciidoctor/issues/2019","id":385241491,"user":{"login":"mojavelinux","id":79351,"avatar_url":"https://avatars2.githubusercontent.com/u/79351?v=4","gravatar_id":"","url":"https://api.github.com/users/mojavelinux","html_url":"https://github.com/mojavelinux","followers_url":"https://api.github.com/users/mojavelinux/followers","following_url":"https://api.github.com/users/mojavelinux/following{/other_user}","gists_url":"https://api.github.com/users/mojavelinux/gists{/gist_id}","starred_url":"https://api.github.com/users/mojavelinux/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mojavelinux/subscriptions","organizations_url":"https://api.github.com/users/mojavelinux/orgs","repos_url":"https://api.github.com/users/mojavelinux/repos","events_url":"https://api.github.com/users/mojavelinux/events{/privacy}","received_events_url":"https://api.github.com/users/mojavelinux/received_events","type":"User","site_admin":false},"created_at":"2018-04-29T10:31:15Z","updated_at":"2018-04-29T10:31:15Z","author_association":"OWNER","body":"How about we use the prefix `_footnotedef_` for the footnote entry, `_footnoteref_` for the reference, and `_footnote_` for the custom ID? That way, the ID won't clash.\r\n\r\nFor example, in the case you cited:\r\n\r\n```\r\n<sup class=\"footnote\" id=\"_footnote_1\">[<a id=\"_footnoteref_1\" class=\"footnote\" href=\"#_footnotedef_1\" title=\"View footnote.\">1</a>]</sup>\r\n```\r\n\r\nand\r\n\r\n```\r\n<div class=\"footnote\" id=\"_footnotedef_1\">\r\n<a href=\"#_footnoteref_1\">1</a>. Footnote 1\r\n</div>\r\n```"}}
{"actor":{"display_login":"mojavelinux"}}