Skip to content

Commit

Permalink
♿ Set aria-hidden & lang attributes
Browse files Browse the repository at this point in the history
  • Loading branch information
0918nobita committed Dec 30, 2023
1 parent 240d99b commit 96e40e0
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions src/code-block-processor/render.ts
Original file line number Diff line number Diff line change
Expand Up @@ -184,10 +184,16 @@ export const codeBlockProcessor = async (

const container = element.createDiv({
cls: styles.container,
attr: {
lang: 'zh-CN',
},
});

const pinyinLine = container.createDiv({
cls: styles.pinyinLine,
attr: {
'aria-hidden': true,
},
}) as PinyinLine;

const zhCharLine = container.createDiv({
Expand Down

0 comments on commit 96e40e0

Please sign in to comment.