mirror of
https://github.com/cheeaun/phanpy.git
synced 2024-11-29 04:38:55 +03:00
Make code blocks focusable
This commit is contained in:
parent
3ac05d8cdd
commit
39d96f22a0
1 changed files with 1 additions and 1 deletions
|
@ -120,7 +120,7 @@ function enhanceContent(content, opts = {}) {
|
|||
p.querySelectorAll('br').forEach((br) => br.replaceWith('\n'));
|
||||
});
|
||||
const codeText = nextParagraphs.map((p) => p.innerHTML).join('\n\n');
|
||||
pre.innerHTML = `<code>${codeText}</code>`;
|
||||
pre.innerHTML = `<code tabindex="0">${codeText}</code>`;
|
||||
block.replaceWith(pre);
|
||||
nextParagraphs.forEach((p) => p.remove());
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue