Instead of adding a second edit tab, provide an integration that only uses one edit tab.
For logged-out users:
- Show a single tab, labelled "Edit" regardless of which editor will be loaded.
- Store in a cookie the user's last-used editor where they had a choice of editors (e.g. edits to Talk:/Template: don't count).
- When a user clicks the edit tab, read the cookie and load that editor if available.
- When a user clicks the edit tab and no cookie is set (very first time), load the wiki-specific default editor for first time (aka 'primary')
- Let the user switch to the other editor if appropriate through a button on the toolbar.
- If they switch, update the cookie.
For logged-in users (where we can do this):
- Show a single tab
- For default user options ("remember my last editor")…
- Label the tab "Edit" if they last used VE when they had a choice, "Edit source" if they last used WT.
- Store in a preference the user's last-used editor where they had a choice of editors (e.g. edits to Talk:/Template: don't count).
- When a user clicks the edit tab, read the preference and load that editor if available.
- When a user clicks the edit tab and no preference is set (very first time), load the wiki-specific default editor for first time (aka 'primary').
- Let the user switch to the other editor if appropriate through a button on the toolbar.
- If they switch, update the preference.
- For users opting to "always prefer the visual editor"…
- Label the tab "Edit" if it will load VE, "Edit source" if it will load WT.
- When a user clicks the edit tab, load VE if available.
- Let the user switch to the other editor if appropriate through a button on the toolbar.
- If they switch, do not change their preferences.
- For users opting to "always prefer the wikitext editor"…
- Label the tab "Edit" always.
- When a user clicks the edit tab, load WT regardless.
- Let the user switch to the other editor if appropriate through a button on the toolbar.
- If they switch, do not change their preferences.
- For users opting to "always show two edit tabs"…
- Add where appropriate a second edit tab, with current behaviour (Edit/Edit source).
- When a user clicks an edit tab, load said label's editor.
- Let the user switch to the other editor if appropriate through a button on the toolbar.
- If they switch, do not change their preferences.
- For users opting to "temporarily disable the visual editor while it is in beta"...
- Don't change their edit tab experience at all, i.e. show one edit source tab labelled as 'edit'.