Improve landmarks on the Project dashboard and Editor pages (#27401)

* Improve landmarks for the Project Dasbhboard

* Improve landmarks for the IDE page

* Improve landmarks for the new redesigned IDE page

* Sort locales

* Fix typo OlButtonToolbar -> OLButtonToolbar

* Update project navbar translation

* Update labels

* Redundant main landmark

* Fix failing test

* Descriptive name for the rails tab

* Header should not be in a button

* Update translation to Account and help

* Update translation to Project categories and tags

* Add explanations

* Show landmark for the survey widget when it's rendered

* Suggestions for nav stretch/scroll/borders

* Source format

---------

Co-authored-by: Antoine Clausse <antoine.clausse@overleaf.com>
GitOrigin-RevId: d05a738e782d2edb229529aadf92b9004dfd973a
This commit is contained in:
Rebeka Dekany
2025-07-28 10:03:16 +02:00
committed by Copybot
parent 1abb98fac2
commit 7c97cbbfe4
43 changed files with 340 additions and 165 deletions

View File

@@ -85,7 +85,11 @@ describe('git-bridge', function () {
it('should render the git-bridge UI in the editor', function () {
maybeClearAllTokens()
createProject('git').as('projectId')
cy.get('header').findByText('Menu').click()
cy.findByRole('navigation', {
name: /Project actions/i,
})
.findByRole('button', { name: /Menu/i })
.click()
cy.findByText('Sync')
cy.findByText('Git').click()
cy.findByTestId('git-bridge-modal').within(() => {
@@ -100,7 +104,11 @@ describe('git-bridge', function () {
// Re-open
cy.url().then(url => cy.visit(url))
cy.get('header').findByText('Menu').click()
cy.findByRole('navigation', {
name: /Project actions/i,
})
.findByRole('button', { name: /Menu/i })
.click()
cy.findByText('Git').click()
cy.findByTestId('git-bridge-modal').within(() => {
cy.get('@projectId').then(id => {
@@ -188,7 +196,11 @@ describe('git-bridge', function () {
function checkGitAccess(access: 'readOnly' | 'readAndWrite') {
const recompile = throttledRecompile()
cy.get('header').findByText('Menu').click()
cy.findByRole('navigation', {
name: /Project actions/i,
})
.findByRole('button', { name: /Menu/i })
.click()
cy.findByText('Sync')
cy.findByText('Git').click()
cy.get('@projectId').then(projectId => {
@@ -370,7 +382,11 @@ Hello world
it('should not render the git-bridge UI in the editor', function () {
login('user@example.com')
createProject('maybe git')
cy.get('header').findByText('Menu').click()
cy.findByRole('navigation', {
name: /Project actions/i,
})
.findByRole('button', { name: /Menu/i })
.click()
cy.findByText('Word Count') // wait for lazy loading
cy.findByText('Sync').should('not.exist')
cy.findByText('Git').should('not.exist')

View File

@@ -37,7 +37,11 @@ describe('SandboxedCompiles', function () {
cy.findByText(/This is pdfTeX, Version .+ \(TeX Live 2023\) /)
cy.log('Switch TeXLive version from 2023 to 2022')
cy.get('header').findByText('Menu').click()
cy.findByRole('navigation', {
name: /Project actions/i,
})
.findByRole('button', { name: /Menu/i })
.click()
cy.findByText(LABEL_TEX_LIVE_VERSION)
.parent()
.findByText('2023')
@@ -213,7 +217,11 @@ describe('SandboxedCompiles', function () {
cy.findByText(/This is pdfTeX/)
cy.log('Switch compiler to from pdfLaTeX to XeLaTeX')
cy.get('header').findByText('Menu').click()
cy.findByRole('navigation', {
name: /Project actions/i,
})
.findByRole('button', { name: /Menu/i })
.click()
cy.findByText('Compiler')
.parent()
.findByText('pdfLaTeX')
@@ -245,7 +253,11 @@ describe('SandboxedCompiles', function () {
cy.findByText(/This is pdfTeX, Version .+ \(TeX Live 2025\) /)
cy.log('Check that there is no TeX Live version toggle')
cy.get('header').findByText('Menu').click()
cy.findByRole('navigation', {
name: /Project actions/i,
})
.findByRole('button', { name: /Menu/i })
.click()
cy.findByText('Word Count') // wait for lazy loading
cy.findByText(LABEL_TEX_LIVE_VERSION).should('not.exist')
})

View File

@@ -57,7 +57,11 @@ describe('Templates', () => {
cy.visit('/')
createProject(name).as('templateProjectId')
cy.get('header').findByText('Menu').click()
cy.findByRole('navigation', {
name: /Project actions/i,
})
.findByRole('button', { name: /Menu/i })
.click()
cy.findByText('Manage Template').click()
cy.findByText('Template Description')
@@ -136,7 +140,11 @@ describe('Templates', () => {
cy.get('@templateProjectId').then(projectId =>
cy.visit(`/project/${projectId}`)
)
cy.get('header').findByText('Menu').click()
cy.findByRole('navigation', {
name: /Project actions/i,
})
.findByRole('button', { name: /Menu/i })
.click()
cy.findByText('Manage Template').click()
cy.findByText('Publish').click()
cy.findByText('Unpublish', { timeout: 10_000 })
@@ -161,7 +169,11 @@ describe('Templates', () => {
cy.findByText('Open as Template').click()
cy.url().should('match', /\/project\/[a-f0-9]{24}$/)
cy.get('.project-name').findByText(name)
cy.get('header').findByText('Menu').click()
cy.findByRole('navigation', {
name: /Project actions/i,
})
.findByRole('button', { name: /Menu/i })
.click()
cy.findByText('Word Count') // wait for lazy loading
cy.findByText('Manage Template').should('not.exist')
@@ -180,7 +192,11 @@ describe('Templates', () => {
cy.get('@templateProjectId').then(projectId =>
cy.visit(`/project/${projectId}`)
)
cy.get('header').findByText('Menu').click()
cy.findByRole('navigation', {
name: /Project actions/i,
})
.findByRole('button', { name: /Menu/i })
.click()
cy.findByText('Manage Template').click()
cy.findByText('Unpublish')
@@ -191,7 +207,11 @@ describe('Templates', () => {
cy.get('@templateProjectId').then(projectId =>
cy.visit(`/project/${projectId}`)
)
cy.get('header').findByText('Menu').click()
cy.findByRole('navigation', {
name: /Project actions/i,
})
.findByRole('button', { name: /Menu/i })
.click()
cy.findByText('Manage Template').click()
cy.findByText('Unpublish').click()
cy.findByText('Publish')
@@ -217,7 +237,11 @@ describe('Templates', () => {
cy.visit('/')
createProject('maybe templates')
cy.get('header').findByText('Menu').click()
cy.findByRole('navigation', {
name: /Project actions/i,
})
.findByRole('button', { name: /Menu/i })
.click()
cy.findByText('Word Count') // wait for lazy loading
cy.findByText('Manage Template').should('not.exist')

View File

@@ -55,7 +55,11 @@ describe('Upgrading', function () {
cy.log('Trigger full flush')
recompile()
cy.get('header').findByText('Menu').click()
cy.findByRole('navigation', {
name: /Project Layout, Sharing, and Submission/i,
})
.findByRole('button', { name: /Menu/i })
.click()
cy.findByText('Source').click()
cy.get('.left-menu-modal-backdrop').click({ force: true })
}
@@ -116,7 +120,9 @@ describe('Upgrading', function () {
openProjectByName(PROJECT_NAME)
cy.url().should('match', /\/project\/[a-fA-F0-9]{24}/)
cy.findByRole('navigation').within(() => {
cy.findByRole('navigation', {
name: /Project actions/i,
}).within(() => {
cy.findByText(PROJECT_NAME)
})
const recompile = throttledRecompile()