Skip to content

GYE-2403: Update library to service design guidelines for language to…#34

Open
rashadmughal wants to merge 2 commits into
hmrc:mainfrom
rashadmughal:GYE-2403
Open

GYE-2403: Update library to service design guidelines for language to…#34
rashadmughal wants to merge 2 commits into
hmrc:mainfrom
rashadmughal:GYE-2403

Conversation

@rashadmughal

Copy link
Copy Markdown

…ggle.

@rashadmughal rashadmughal force-pushed the GYE-2403 branch 2 times, most recently from 043dc1e to bc4d28c Compare March 11, 2021 11:11
@rashadmughal

rashadmughal commented Mar 11, 2021

Copy link
Copy Markdown
Author

To ensure the language toggle follows the design guidelines here:

https://design.tax.service.gov.uk/hmrc-design-patterns/welsh-language-toggle/

This what the final output looks like:

image

Final HTML for when English is selected.

<nav class="language-toggle hmrc-language-select" aria-label="Language switcher">
    <ul class="hmrc-language-select__list language-toggle" style="display: block;">
    
        
            <li class="hmrc-language-select__list-item" style="display: inline-block;">
                <span aria-current="true">English</span>
            </li>
        
        
             | 
        
    
        
            <li class="hmrc-language-select__list-item" style="display: inline-block;">
                <a id="cymraeg-switch" href="/customs/register-for-cds/language/cymraeg" target="_self" data-sso="false" data-journey-click="customs-rosm-frontend:language: cy">
                    <span class="visually-hidden">Newid yr iaith ir Gymraeg</span>
                    <span aria-hidden="true">Cymraeg</span>
                </a>
            </li>
        
        
    
    </ul>
</nav>

And for when welsh is selected:

<nav class="language-toggle hmrc-language-select" aria-label="Language switcher">
    <ul class="hmrc-language-select__list language-toggle" style="display: block;">
    
        
            <li class="hmrc-language-select__list-item" style="display: inline-block;">
                <a id="english-switch" href="/customs/register-for-cds/language/english" target="_self" data-sso="false" data-journey-click="customs-rosm-frontend:language: en">
                    <span class="visually-hidden">Change language to English</span>
                    <span aria-hidden="true">English</span>
                </a>
            </li>
        
        
             | 
        
    
        
            <li class="hmrc-language-select__list-item" style="display: inline-block;">
                <span aria-current="true">Cymraeg</span>
            </li>
        
        
    
    </ul>
</nav>

@hmrc-web-operations hmrc-web-operations changed the base branch from master to main September 8, 2021 14:07
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant