diff --git a/desktop-app/resources/index.html b/desktop-app/resources/index.html
index 32be8f98..7108af59 100644
--- a/desktop-app/resources/index.html
+++ b/desktop-app/resources/index.html
@@ -239,8 +239,8 @@
Menu
-
-
+
+
@@ -778,10 +778,10 @@
Open-source credits
-
+
-
+
@@ -818,7 +818,7 @@
Open-source credits
-
+
diff --git a/desktop-app/resources/js/script.js b/desktop-app/resources/js/script.js
index 9fd28eaf..42c35ff9 100644
--- a/desktop-app/resources/js/script.js
+++ b/desktop-app/resources/js/script.js
@@ -1518,6 +1518,14 @@ document.addEventListener("DOMContentLoaded", function () {
enhanceGitHubAlerts(markdownPreview);
processEmojis(markdownPreview);
+
+ // Add accessible dynamic labels to task list checkboxes matching their parent text
+ markdownPreview.querySelectorAll('input[type="checkbox"]').forEach(function(input) {
+ if (!input.hasAttribute('aria-label')) {
+ const parentText = input.parentElement ? input.parentElement.textContent.trim() : '';
+ input.setAttribute('aria-label', parentText || 'Task item');
+ }
+ });
// PERF-002: Lazy-load mermaid only when diagrams are present
try {
@@ -1559,7 +1567,11 @@ document.addEventListener("DOMContentLoaded", function () {
if (hasMath) {
if (window.MathJax) {
try {
- MathJax.typesetPromise([markdownPreview]).catch((err) => {
+ MathJax.typesetPromise([markdownPreview]).then(function() {
+ markdownPreview.querySelectorAll('mjx-container[tabindex="0"]').forEach(function(mjx) {
+ mjx.removeAttribute('tabindex');
+ });
+ }).catch(function(err) {
console.warn('MathJax typesetting failed:', err);
});
} catch (e) {
@@ -1578,7 +1590,11 @@ document.addEventListener("DOMContentLoaded", function () {
};
loadScript(CDN.mathjax).then(function() {
try {
- MathJax.typesetPromise([markdownPreview]).catch(function(err) {
+ MathJax.typesetPromise([markdownPreview]).then(function() {
+ markdownPreview.querySelectorAll('mjx-container[tabindex="0"]').forEach(function(mjx) {
+ mjx.removeAttribute('tabindex');
+ });
+ }).catch(function(err) {
console.warn('MathJax typesetting failed:', err);
});
} catch (e) {
diff --git a/desktop-app/resources/styles.css b/desktop-app/resources/styles.css
index 56be2004..984a61f3 100644
--- a/desktop-app/resources/styles.css
+++ b/desktop-app/resources/styles.css
@@ -758,7 +758,7 @@ a:focus {
--color-prettylights-syntax-entity: #6f42c1;
--color-prettylights-syntax-storage-modifier-import: #24292e;
--color-prettylights-syntax-entity-tag: #22863a;
- --color-prettylights-syntax-keyword: #d73a49;
+ --color-prettylights-syntax-keyword: #cf222e;
--color-prettylights-syntax-string: #032f62;
--color-prettylights-syntax-variable: #e36209;
--color-prettylights-syntax-brackethighlighter-unmatched: #b31d28;
@@ -1732,7 +1732,7 @@ a:focus {
display: flex;
align-items: center;
gap: 6px;
- height: 27px;
+ height: 32px;
padding: 0 8px 0 10px;
min-width: 100px;
max-width: 180px;
@@ -1874,8 +1874,8 @@ a:focus {
display: flex;
align-items: center;
justify-content: center;
- width: 18px;
- height: 18px;
+ width: 22px;
+ height: 22px;
border-radius: 3px;
background: none;
border: none;
diff --git a/index.html b/index.html
index f6d01b08..8407b3bb 100644
--- a/index.html
+++ b/index.html
@@ -298,8 +298,8 @@ Menu
-
-
+
+
@@ -837,10 +837,10 @@
Open-source credits
-
+
-
+
@@ -877,7 +877,7 @@
Open-source credits
-
+
diff --git a/script.js b/script.js
index 9fd28eaf..42c35ff9 100644
--- a/script.js
+++ b/script.js
@@ -1518,6 +1518,14 @@ document.addEventListener("DOMContentLoaded", function () {
enhanceGitHubAlerts(markdownPreview);
processEmojis(markdownPreview);
+
+ // Add accessible dynamic labels to task list checkboxes matching their parent text
+ markdownPreview.querySelectorAll('input[type="checkbox"]').forEach(function(input) {
+ if (!input.hasAttribute('aria-label')) {
+ const parentText = input.parentElement ? input.parentElement.textContent.trim() : '';
+ input.setAttribute('aria-label', parentText || 'Task item');
+ }
+ });
// PERF-002: Lazy-load mermaid only when diagrams are present
try {
@@ -1559,7 +1567,11 @@ document.addEventListener("DOMContentLoaded", function () {
if (hasMath) {
if (window.MathJax) {
try {
- MathJax.typesetPromise([markdownPreview]).catch((err) => {
+ MathJax.typesetPromise([markdownPreview]).then(function() {
+ markdownPreview.querySelectorAll('mjx-container[tabindex="0"]').forEach(function(mjx) {
+ mjx.removeAttribute('tabindex');
+ });
+ }).catch(function(err) {
console.warn('MathJax typesetting failed:', err);
});
} catch (e) {
@@ -1578,7 +1590,11 @@ document.addEventListener("DOMContentLoaded", function () {
};
loadScript(CDN.mathjax).then(function() {
try {
- MathJax.typesetPromise([markdownPreview]).catch(function(err) {
+ MathJax.typesetPromise([markdownPreview]).then(function() {
+ markdownPreview.querySelectorAll('mjx-container[tabindex="0"]').forEach(function(mjx) {
+ mjx.removeAttribute('tabindex');
+ });
+ }).catch(function(err) {
console.warn('MathJax typesetting failed:', err);
});
} catch (e) {
diff --git a/styles.css b/styles.css
index 56be2004..984a61f3 100644
--- a/styles.css
+++ b/styles.css
@@ -758,7 +758,7 @@ a:focus {
--color-prettylights-syntax-entity: #6f42c1;
--color-prettylights-syntax-storage-modifier-import: #24292e;
--color-prettylights-syntax-entity-tag: #22863a;
- --color-prettylights-syntax-keyword: #d73a49;
+ --color-prettylights-syntax-keyword: #cf222e;
--color-prettylights-syntax-string: #032f62;
--color-prettylights-syntax-variable: #e36209;
--color-prettylights-syntax-brackethighlighter-unmatched: #b31d28;
@@ -1732,7 +1732,7 @@ a:focus {
display: flex;
align-items: center;
gap: 6px;
- height: 27px;
+ height: 32px;
padding: 0 8px 0 10px;
min-width: 100px;
max-width: 180px;
@@ -1874,8 +1874,8 @@ a:focus {
display: flex;
align-items: center;
justify-content: center;
- width: 18px;
- height: 18px;
+ width: 22px;
+ height: 22px;
border-radius: 3px;
background: none;
border: none;