<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>https://wiki.storlye.com/wiki/index.php?action=history&amp;feed=atom&amp;title=Developers%2FWorkflow%2FView_As_Role_Switching</id>
	<title>Developers/Workflow/View As Role Switching - Revision history</title>
	<link rel="self" type="application/atom+xml" href="https://wiki.storlye.com/wiki/index.php?action=history&amp;feed=atom&amp;title=Developers%2FWorkflow%2FView_As_Role_Switching"/>
	<link rel="alternate" type="text/html" href="https://wiki.storlye.com/wiki/index.php?title=Developers/Workflow/View_As_Role_Switching&amp;action=history"/>
	<updated>2026-06-15T21:49:23Z</updated>
	<subtitle>Revision history for this page on the wiki</subtitle>
	<generator>MediaWiki 1.45.3</generator>
	<entry>
		<id>https://wiki.storlye.com/wiki/index.php?title=Developers/Workflow/View_As_Role_Switching&amp;diff=49&amp;oldid=prev</id>
		<title>Wikistorlye admin: Document View as role switching for superadmin</title>
		<link rel="alternate" type="text/html" href="https://wiki.storlye.com/wiki/index.php?title=Developers/Workflow/View_As_Role_Switching&amp;diff=49&amp;oldid=prev"/>
		<updated>2026-06-15T18:43:01Z</updated>

		<summary type="html">&lt;p&gt;Document View as role switching for superadmin&lt;/p&gt;
&lt;p&gt;&lt;b&gt;New page&lt;/b&gt;&lt;/p&gt;&lt;div&gt;= View As Role Switching =&lt;br /&gt;
&lt;br /&gt;
== Objective ==&lt;br /&gt;
Allow a logged superadmin to navigate the app as another role while keeping the View as control always available.&lt;br /&gt;
&lt;br /&gt;
== Scope ==&lt;br /&gt;
- Frontend: avatar popup menu in main page header.&lt;br /&gt;
- Roles available in View as: superadmin, admin, moderator, user.&lt;br /&gt;
- Applies only when the authenticated account has role code superadmin.&lt;br /&gt;
&lt;br /&gt;
== Behavior ==&lt;br /&gt;
- A new section &amp;quot;View as&amp;quot; is shown in the user avatar menu.&lt;br /&gt;
- Each role option shows a marker on the left:&lt;br /&gt;
  - &amp;quot;√&amp;quot; for the active effective role.&lt;br /&gt;
  - blank marker for inactive options.&lt;br /&gt;
- Default state for superadmin login:&lt;br /&gt;
  - superadmin starts selected with &amp;quot;√&amp;quot;.&lt;br /&gt;
- On selection:&lt;br /&gt;
  - superadmin -&amp;gt; opens Super Admin panel.&lt;br /&gt;
  - admin -&amp;gt; opens Admin panel.&lt;br /&gt;
  - moderator -&amp;gt; opens Moderator panel.&lt;br /&gt;
  - user -&amp;gt; navigates to Home.&lt;br /&gt;
- The &amp;quot;View as&amp;quot; section remains visible after switching, allowing back-and-forth role simulation without logging out.&lt;br /&gt;
&lt;br /&gt;
== Access Model ==&lt;br /&gt;
- Authentication roles from backend remain unchanged.&lt;br /&gt;
- View as creates an effective role in frontend navigation only.&lt;br /&gt;
- Panel access checks use the effective role for navigation guards.&lt;br /&gt;
&lt;br /&gt;
== UX Notes ==&lt;br /&gt;
- This is role simulation for navigation and UI surface.&lt;br /&gt;
- Logged identity/session remains the same authenticated superadmin user.&lt;br /&gt;
&lt;br /&gt;
== Technical Notes ==&lt;br /&gt;
- Primary implementation file: App.tsx&lt;br /&gt;
- Added i18n keys for menu labels:&lt;br /&gt;
  - actionViewAs&lt;br /&gt;
  - actionUser&lt;/div&gt;</summary>
		<author><name>Wikistorlye admin</name></author>
	</entry>
</feed>