Span is not read from a screen reader if there is no fallback message

Discussão em 'Angular' iniciado por SSS, Setembro 12, 2025.

  1. SSS

    SSS Guest

    I am trying to implement accessibility in my site, but when I use a screen reader, it ignores the text "Test message".

    I have a component named Account:

    <span [ngClass] ='ÁccountStyles'>
    <slot></slot>
    </span>


    In the BankAccount component, I have the following code: Test message

    How can I make this text readable by a screen reader without using a fallback message?

    For comparison, the Account component with a fallback message looks like this:

    <span [ngClass] ='ÁccountStyles'>
    <slot>fall\back</slot>
    </span>

    Continue reading...

Compartilhe esta Página