Bug 536373 - breadcrumb dirty indicator id is not unique
Summary: breadcrumb dirty indicator id is not unique
Status: RESOLVED FIXED
Alias: None
Product: Orion (Archived)
Classification: ECD
Component: Editor (show other bugs)
Version: unspecified   Edit
Hardware: PC Windows 7
: P3 normal (vote)
Target Milestone: 19.0   Edit
Assignee: Carolyn MacLeod CLA
QA Contact:
URL:
Whiteboard:
Keywords: accessibility
Depends on:
Blocks:
 
Reported: 2018-06-27 15:33 EDT by Carolyn MacLeod CLA
Modified: 2018-06-27 16:51 EDT (History)
0 users

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Carolyn MacLeod CLA 2018-06-27 15:33:11 EDT
Steps:
- In Settings - General: check Enable Editor Tab Support
- In Settings - Editor Settings: uncheck Auto Save
- Go to the Editor page.
- Open at least 2 files, so that you have at least 2 tabs.
- In the 2nd tab, make a change, so that the file is "dirty" and the tab shows an asterisk.
- Hover on the 2nd tab to see its breadcrumb.
- Problem 1: The "dirty" indicator for this file should show up in the breadcrumb, but it is missing.
- Now hover over the 1st (leftmost) tab.
- Problem 2: This file is not "dirty", and yet its breadcrumb is showing a "dirty" indicator asterisk.

The bug is that an element with id "dirty" is being created for each breadcrumb (on line 152 in breadcrumbs.js).
So when the browser is asked for an element with that id (on line 368 of globalCommands.js) it just returns the first one found.

The breadcrumb "dirty" id needs to be made unique per file/tab/breadcrumb, and the mechanism for adding/removing the indicator needs to use the unique id.
(Either that, or implement it in a way that doesn't use an id).

This is also causing an "ids must be unique on the page" accessibility scanning violation.