用户每一次关键操作都在底层触发了一个埋点事件,飞掠网络被永远记录在案。
+{{ t('payment_title') }}
+{{ t('payment_desc') }}
+ +diff --git a/docs/.vitepress/theme/components/appendix/browser-frontend/A11yScreenReaderDemo.vue b/docs/.vitepress/theme/components/appendix/browser-frontend/A11yScreenReaderDemo.vue
new file mode 100644
index 0000000..e8a5da9
--- /dev/null
+++ b/docs/.vitepress/theme/components/appendix/browser-frontend/A11yScreenReaderDemo.vue
@@ -0,0 +1,246 @@
+
+ 使用 使用 {{ t('payment_desc') }}
+ 由于我们在 CSS 中使用了弹性的 Flex 布局,并且没有写死 `margin-left` 而是用了 `gap` 与 `justify-content`,当切换到阿拉伯语时,`dir="rtl"` 属性会指挥浏览器**完美镜像反转**整个布局。当切换到德语时,超长的按钮文字会自动引发弹性换行,而不会溢出。
+
+ 彻底抛弃正则表达式的截取与拼接!看看原生的 ❌ 野路子开发:全是 DIV
+
+ ✅ 专业前端:语义化 + ARIA
+
+
+ 可以尝试用键盘 Tab 键选中并按 Enter!只有右侧的按钮会响应。
+ ❌ 案例 A:纯粹的视觉欺骗
+ <div> 结合 CSS 绘制。在渲染树上很完美,但在 AOM 树中缺失语义。✅ 案例 B:语义化 + ARIA 护航
+ <input>、<button> 等原生标签,补充 aria-label。在 AOM 树中拥有完整交互属性。{{ t('payment_title') }}
+ 实战区 1:依赖 Flex 面向字典与排版进行重构
+ 实战区 2:使用 Intl 引擎接管数据呈现
+ Intl.NumberFormat 和 Intl.DateTimeFormat 是如何根据我们上方选择的“环境代号”将下方固定不变的底层二进制数据无缝格式化的。
+ 1459800.5
+
➔
+ 1757430000000
+
➔
+
{{ animationCode }}
- - 💡 - 提示: - 动画的本质是快速连续绘制静态画面。Canvas 每秒可以绘制 60 - 帧(60FPS),形成流畅的动画效果。 -
-{{ currentCode }}
- // 绘制坐标轴
-const canvas = document.getElementById('myCanvas')
-const ctx = canvas.getContext('2d')
+
-// X 轴(红色)
-ctx.strokeStyle = '#e74c3c'
-ctx.lineWidth = 2
-ctx.beginPath()
-ctx.moveTo(0, 0)
-ctx.lineTo(canvas.width, 0)
-ctx.stroke()
-
-// Y 轴(蓝色)
-ctx.strokeStyle = '#3498db'
-ctx.beginPath()
-ctx.moveTo(0, 0)
-ctx.lineTo(0, canvas.height)
-ctx.stroke()
-
-// 绘制点
-ctx.fillStyle = '#2ecc71'
-ctx.beginPath()
-ctx.arc({{ Math.round(selectedPoint?.x || 100) }}, {{ Math.round(selectedPoint?.y || 100) }}, 5, 0, Math.PI * 2)
-ctx.fill()
- - 💡 - 提示: - Canvas 的 Y - 轴方向与传统数学坐标系相反,向下为正。这在处理图形定位时需要特别注意。 -
-{{ currentCode }}
- {{ particleCode }}
- - 💡 - 提示: - 移动鼠标或点击画布来产生粒子!不同的效果有不同的交互方式。 -
-{{ optimizationCode }}
- 用户每一次关键操作都在底层触发了一个埋点事件,飞掠网络被永远记录在案。
+每一个标准事件都必须回答 4W1H:Who, What, When, Where, How。
+数据并非立刻入库,为了抵御高并发和弱网环境,它必须经历缓存、打包、列队和清洗的漫长流水线。
+{{ steps[currentStep].desc }}
+<html>
+ <style>
+ .title { color: #f00; }
+ </style>
+ <body>
+ <h1 class="title">
+ Google Search
+ </h1>
+ <input />
+ </body>
+</html>
- 为什么需要 DNS?(查导航) -
-
- 你知道店铺名字叫 "bilibili.com",但快递员需要知道具体的经纬度坐标 (IP 地址)
- 才能送达。
-
- DNS 就像是地图导航,输入店名,它通过“114查号台”帮你找到坐标。
-
{{ responseBody }}
- {{ currentDescription }}
+