微信公众号搜"智元新知"关注
微信扫一扫可直接关注哦!

table <td> 元素内容没有被 NVDA 屏幕阅读器读出,但是被 VoiceOver 读出

如何解决table <td> 元素内容没有被 NVDA 屏幕阅读器读出,但是被 VoiceOver 读出

前两个 td 元素被聚焦,但内容没有被 NVDA 读出。但是,VoiceOver 可以正确读出内容。我希望 NVDA 和 VoiceOver 读出前两个元素的内容

<table class="nhsuk-table" tabindex="0">
          <caption class="nhsuk-table__caption">{{ 'workflow.manageKpis.heading' | locale }}</caption>
          <tr class="nhsuk-table__row">
            <th id="title_{{loop.index}}" class="nhsuk-table__header" scope="col"><strong>{{ 'workflow.manageKpis.table.title' | locale }}</strong></th>
            <th id="description_{{loop.index}}" class="nhsuk-table__header" scope="col"><strong>{{ 'workflow.manageKpis.table.description' | locale }}</strong></th>
            <th class="nhsuk-table__header" scope="col"><strong>{{ 'workflow.manageKpis.table.due' | locale }}</strong></th>
            <th class="nhsuk-table__header" scope="col"><strong>{{ 'workflow.manageKpis.table.done' | locale }}</strong></th>
          </tr>
          {% for task in stage.tasks %}
            <tr scope="row" class="nhsuk-table__row">
              <td class="nhsuk-table__cell" aria-labelledby="title_{{loop.index}}" tabindex="0">{{ ('workflow.manageKpis.tasks.' + task.taskCode + '.title') | locale }}</td>
              <td class="nhsuk-table__cell" aria-labelledby="description_{{loop.index}}" tabindex="0"><strong>{{ 'workflow.manageKpis.table.from' | locale }}</strong> {{ ('workflow.manageKpis.tasks.' + task.taskCode + '.from') | locale }} <br><strong>{{ 'workflow.manageKpis.table.to' | locale }}</strong> {{ ('workflow.manageKpis.tasks.' + task.taskCode + '.to') | locale }}</td>
              <td class="nhsuk-table__cell">
                <label class="nhsuk-label nhsuk-u-visually-hidden" id="error_{{ task.dueDaysFieldName }}" for="{{ task.dueDaysFieldId }}">{{ ('workflow.manageKpis.tasks.' + task.taskCode + '.title') | locale }} {{ 'workflow.manageKpis.validation.dueDays' | locale }}</label>
                <input class="nhsuk-input nhsuk-input--width-2 {{ 'nhsuk-textarea--error' if error.fieldErrors[task.dueDaysFieldName] }}" id="{{ task.dueDaysFieldId }}" name="{{ task.dueDaysFieldName }}" type="text" value="{{ values[task.dueDaysFieldName] }}" autocomplete="off" maxlength="2">
              </td>
              <td class="nhsuk-table__cell">
                <label class="nhsuk-label nhsuk-u-visually-hidden" id="error_{{ task.doneDaysFieldName }}" for="{{ task.doneDaysFieldId }}">{{ ('workflow.manageKpis.tasks.' + task.taskCode + '.title') | locale }} {{ 'workflow.manageKpis.validation.doneDays' | locale }}</label>
                <input class="nhsuk-input nhsuk-input--width-2 {{ 'nhsuk-textarea--error' if error.fieldErrors[task.doneDaysFieldName] }}" id="{{ task.doneDaysFieldId }}" name="{{ task.doneDaysFieldName }}" type="text" value="{{ values[task.doneDaysFieldName] }}" autocomplete="off" maxlength="2">
              </td>
            </tr>
          {% endfor %}
      </table>

版权声明:本文内容由互联网用户自发贡献,该文观点与技术仅代表作者本人。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌侵权/违法违规的内容, 请发送邮件至 dio@foxmail.com 举报,一经查实,本站将立刻删除。