@nextsparkjs/theme-default 0.1.0-beta.20 → 0.1.0-beta.21

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (220) hide show
  1. package/package.json +1 -1
  2. package/tests/cypress/e2e/_devtools/access.bdd.md +262 -0
  3. package/tests/cypress/e2e/_devtools/access.cy.ts +171 -0
  4. package/tests/cypress/e2e/_devtools/navigation.bdd.md +261 -0
  5. package/tests/cypress/e2e/_devtools/navigation.cy.ts +157 -0
  6. package/tests/cypress/e2e/_devtools/pages.bdd.md +303 -0
  7. package/tests/cypress/e2e/_devtools/pages.cy.ts +184 -0
  8. package/tests/cypress/e2e/_docs/README.md +215 -0
  9. package/tests/cypress/e2e/_docs/tutorials/sector7-superadmin-teams.narration.json +155 -0
  10. package/tests/cypress/e2e/_docs/tutorials/sector7-superadmin.cy.ts +390 -0
  11. package/tests/cypress/e2e/_docs/tutorials/teams-system.doc.cy.ts +349 -0
  12. package/tests/cypress/e2e/_docs/tutorials/teams-system.narration.json +165 -0
  13. package/tests/cypress/e2e/_selectors/auth.cy.ts +306 -0
  14. package/tests/cypress/e2e/_selectors/billing.cy.ts +89 -0
  15. package/tests/cypress/e2e/_selectors/dashboard-mobile.cy.ts +113 -0
  16. package/tests/cypress/e2e/_selectors/dashboard-navigation.cy.ts +89 -0
  17. package/tests/cypress/e2e/_selectors/dashboard-sidebar.cy.ts +60 -0
  18. package/tests/cypress/e2e/_selectors/dashboard-topnav.cy.ts +146 -0
  19. package/tests/cypress/e2e/_selectors/devtools.cy.ts +210 -0
  20. package/tests/cypress/e2e/_selectors/global-search.cy.ts +88 -0
  21. package/tests/cypress/e2e/_selectors/pages-editor.cy.ts +179 -0
  22. package/tests/cypress/e2e/_selectors/posts-editor.cy.ts +282 -0
  23. package/tests/cypress/e2e/_selectors/public.cy.ts +112 -0
  24. package/tests/cypress/e2e/_selectors/settings-api-keys.cy.ts +228 -0
  25. package/tests/cypress/e2e/_selectors/settings-billing.cy.ts +105 -0
  26. package/tests/cypress/e2e/_selectors/settings-layout.cy.ts +119 -0
  27. package/tests/cypress/e2e/_selectors/settings-password.cy.ts +71 -0
  28. package/tests/cypress/e2e/_selectors/settings-profile.cy.ts +82 -0
  29. package/tests/cypress/e2e/_selectors/settings-teams.cy.ts +68 -0
  30. package/tests/cypress/e2e/_selectors/superadmin.cy.ts +185 -0
  31. package/tests/cypress/e2e/_selectors/tasks.cy.ts +242 -0
  32. package/tests/cypress/e2e/_selectors/taxonomies.cy.ts +126 -0
  33. package/tests/cypress/e2e/_selectors/teams.cy.ts +142 -0
  34. package/tests/cypress/e2e/_superadmin/all-teams.bdd.md +261 -0
  35. package/tests/cypress/e2e/_superadmin/all-teams.cy.ts +177 -0
  36. package/tests/cypress/e2e/_superadmin/all-users.bdd.md +406 -0
  37. package/tests/cypress/e2e/_superadmin/all-users.cy.ts +294 -0
  38. package/tests/cypress/e2e/_superadmin/dashboard.bdd.md +235 -0
  39. package/tests/cypress/e2e/_superadmin/dashboard.cy.ts +149 -0
  40. package/tests/cypress/e2e/_superadmin/subscriptions-overview.bdd.md +290 -0
  41. package/tests/cypress/e2e/_superadmin/subscriptions-overview.cy.ts +194 -0
  42. package/tests/cypress/e2e/ai/ai-usage.cy.ts +209 -0
  43. package/tests/cypress/e2e/ai/chat-api.cy.ts +107 -0
  44. package/tests/cypress/e2e/ai/guardrails.cy.ts +332 -0
  45. package/tests/cypress/e2e/api/billing/BillingAPIController.js +319 -0
  46. package/tests/cypress/e2e/api/billing/check-action.cy.ts +326 -0
  47. package/tests/cypress/e2e/api/billing/checkout.cy.ts +358 -0
  48. package/tests/cypress/e2e/api/billing/lifecycle.cy.ts +423 -0
  49. package/tests/cypress/e2e/api/billing/plans/README.md +345 -0
  50. package/tests/cypress/e2e/api/billing/plans/business.cy.ts +412 -0
  51. package/tests/cypress/e2e/api/billing/plans/downgrade.cy.ts +510 -0
  52. package/tests/cypress/e2e/api/billing/plans/fixtures/billing-plans.json +163 -0
  53. package/tests/cypress/e2e/api/billing/plans/free.cy.ts +500 -0
  54. package/tests/cypress/e2e/api/billing/plans/pro.cy.ts +497 -0
  55. package/tests/cypress/e2e/api/billing/plans/starter.cy.ts +342 -0
  56. package/tests/cypress/e2e/api/billing/portal.cy.ts +313 -0
  57. package/tests/cypress/e2e/api/devtools/registries.bdd.md +300 -0
  58. package/tests/cypress/e2e/api/devtools/registries.cy.ts +368 -0
  59. package/tests/cypress/e2e/api/entities/blocks-scope.cy.ts +396 -0
  60. package/tests/cypress/e2e/api/entities/customers-crud.cy.ts +648 -0
  61. package/tests/cypress/e2e/api/entities/customers-metas.cy.ts +839 -0
  62. package/tests/cypress/e2e/api/entities/pages-crud.cy.ts +425 -0
  63. package/tests/cypress/e2e/api/entities/pages-status.cy.ts +335 -0
  64. package/tests/cypress/e2e/api/entities/post-categories-crud.cy.ts +610 -0
  65. package/tests/cypress/e2e/api/entities/posts-crud.cy.ts +709 -0
  66. package/tests/cypress/e2e/api/entities/posts-status.cy.ts +396 -0
  67. package/tests/cypress/e2e/api/entities/tasks-crud.cy.ts +602 -0
  68. package/tests/cypress/e2e/api/entities/tasks-metas.cy.ts +878 -0
  69. package/tests/cypress/e2e/api/entities/users-crud.cy.ts +469 -0
  70. package/tests/cypress/e2e/api/entities/users-metas.cy.ts +913 -0
  71. package/tests/cypress/e2e/api/entities/users-security.cy.ts +375 -0
  72. package/tests/cypress/e2e/api/scheduled-actions/cron-endpoint.bdd.md +375 -0
  73. package/tests/cypress/e2e/api/scheduled-actions/cron-endpoint.cy.ts +346 -0
  74. package/tests/cypress/e2e/api/scheduled-actions/devtools-endpoint.bdd.md +451 -0
  75. package/tests/cypress/e2e/api/scheduled-actions/devtools-endpoint.cy.ts +447 -0
  76. package/tests/cypress/e2e/api/scheduled-actions/scheduling.bdd.md +649 -0
  77. package/tests/cypress/e2e/api/scheduled-actions/scheduling.cy.ts +333 -0
  78. package/tests/cypress/e2e/api/settings/api-keys.crud.cy.ts +923 -0
  79. package/tests/cypress/e2e/uat/auth/app-roles/developer-login.bdd.md +231 -0
  80. package/tests/cypress/e2e/uat/auth/app-roles/developer-login.cy.ts +144 -0
  81. package/tests/cypress/e2e/uat/auth/app-roles/superadmin-login.bdd.md +118 -0
  82. package/tests/cypress/e2e/uat/auth/app-roles/superadmin-login.cy.ts +84 -0
  83. package/tests/cypress/e2e/uat/auth/custom-roles/editor-login.bdd.md +288 -0
  84. package/tests/cypress/e2e/uat/auth/custom-roles/editor-login.cy.ts +188 -0
  85. package/tests/cypress/e2e/uat/auth/login-logout.bdd.md +160 -0
  86. package/tests/cypress/e2e/uat/auth/login-logout.cy.ts +116 -0
  87. package/tests/cypress/e2e/uat/auth/password-reset.bdd.md +289 -0
  88. package/tests/cypress/e2e/uat/auth/password-reset.cy.ts +200 -0
  89. package/tests/cypress/e2e/uat/auth/team-roles/admin-login.bdd.md +225 -0
  90. package/tests/cypress/e2e/uat/auth/team-roles/admin-login.cy.ts +148 -0
  91. package/tests/cypress/e2e/uat/auth/team-roles/member-login.bdd.md +251 -0
  92. package/tests/cypress/e2e/uat/auth/team-roles/member-login.cy.ts +163 -0
  93. package/tests/cypress/e2e/uat/auth/team-roles/owner-login.bdd.md +231 -0
  94. package/tests/cypress/e2e/uat/auth/team-roles/owner-login.cy.ts +141 -0
  95. package/tests/cypress/e2e/uat/billing/extended.bdd.md +273 -0
  96. package/tests/cypress/e2e/uat/billing/extended.cy.ts +209 -0
  97. package/tests/cypress/e2e/uat/billing/feature-gates.bdd.md +407 -0
  98. package/tests/cypress/e2e/uat/billing/feature-gates.cy.ts +307 -0
  99. package/tests/cypress/e2e/uat/billing/page.bdd.md +329 -0
  100. package/tests/cypress/e2e/uat/billing/page.cy.ts +250 -0
  101. package/tests/cypress/e2e/uat/billing/status.bdd.md +190 -0
  102. package/tests/cypress/e2e/uat/billing/status.cy.ts +145 -0
  103. package/tests/cypress/e2e/uat/billing/team-switch.bdd.md +156 -0
  104. package/tests/cypress/e2e/uat/billing/team-switch.cy.ts +122 -0
  105. package/tests/cypress/e2e/uat/billing/usage.bdd.md +218 -0
  106. package/tests/cypress/e2e/uat/billing/usage.cy.ts +176 -0
  107. package/tests/cypress/e2e/uat/blocks/hero.bdd.md +124 -0
  108. package/tests/cypress/e2e/uat/blocks/hero.cy.ts +56 -0
  109. package/tests/cypress/e2e/uat/devtools/api-tester.cy.ts +390 -0
  110. package/tests/cypress/e2e/uat/entities/customers/member.bdd.md +275 -0
  111. package/tests/cypress/e2e/uat/entities/customers/member.cy.ts +122 -0
  112. package/tests/cypress/e2e/uat/entities/customers/owner.bdd.md +243 -0
  113. package/tests/cypress/e2e/uat/entities/customers/owner.cy.ts +165 -0
  114. package/tests/cypress/e2e/uat/entities/pages/block-crud.bdd.md +476 -0
  115. package/tests/cypress/e2e/uat/entities/pages/block-crud.cy.ts +486 -0
  116. package/tests/cypress/e2e/uat/entities/pages/block-editor.bdd.md +460 -0
  117. package/tests/cypress/e2e/uat/entities/pages/block-editor.cy.ts +301 -0
  118. package/tests/cypress/e2e/uat/entities/pages/list.bdd.md +432 -0
  119. package/tests/cypress/e2e/uat/entities/pages/list.cy.ts +273 -0
  120. package/tests/cypress/e2e/uat/entities/pages/public-rendering.bdd.md +696 -0
  121. package/tests/cypress/e2e/uat/entities/pages/public-rendering.cy.ts +340 -0
  122. package/tests/cypress/e2e/uat/entities/posts/categories-api-aware.bdd.md +161 -0
  123. package/tests/cypress/e2e/uat/entities/posts/categories-api-aware.cy.ts +104 -0
  124. package/tests/cypress/e2e/uat/entities/posts/categories.bdd.md +375 -0
  125. package/tests/cypress/e2e/uat/entities/posts/categories.cy.ts +241 -0
  126. package/tests/cypress/e2e/uat/entities/posts/editor.bdd.md +429 -0
  127. package/tests/cypress/e2e/uat/entities/posts/editor.cy.ts +257 -0
  128. package/tests/cypress/e2e/uat/entities/posts/list.bdd.md +340 -0
  129. package/tests/cypress/e2e/uat/entities/posts/list.cy.ts +177 -0
  130. package/tests/cypress/e2e/uat/entities/posts/public.bdd.md +614 -0
  131. package/tests/cypress/e2e/uat/entities/posts/public.cy.ts +249 -0
  132. package/tests/cypress/e2e/uat/entities/tasks/member.bdd.md +222 -0
  133. package/tests/cypress/e2e/uat/entities/tasks/member.cy.ts +165 -0
  134. package/tests/cypress/e2e/uat/entities/tasks/owner.bdd.md +419 -0
  135. package/tests/cypress/e2e/uat/entities/tasks/owner.cy.ts +191 -0
  136. package/tests/cypress/e2e/uat/roles/editor-role.bdd.md +552 -0
  137. package/tests/cypress/e2e/uat/roles/editor-role.cy.ts +210 -0
  138. package/tests/cypress/e2e/uat/roles/member-restrictions.bdd.md +450 -0
  139. package/tests/cypress/e2e/uat/roles/member-restrictions.cy.ts +189 -0
  140. package/tests/cypress/e2e/uat/roles/owner-full-crud.bdd.md +530 -0
  141. package/tests/cypress/e2e/uat/roles/owner-full-crud.cy.ts +247 -0
  142. package/tests/cypress/e2e/uat/scheduled-actions/devtools-ui.bdd.md +736 -0
  143. package/tests/cypress/e2e/uat/scheduled-actions/devtools-ui.cy.ts +740 -0
  144. package/tests/cypress/e2e/uat/teams/roles-matrix.bdd.md +553 -0
  145. package/tests/cypress/e2e/uat/teams/roles-matrix.cy.ts +185 -0
  146. package/tests/cypress/e2e/uat/teams/switcher.bdd.md +1151 -0
  147. package/tests/cypress/e2e/uat/teams/switcher.cy.ts +497 -0
  148. package/tests/cypress/e2e/uat/teams/team-switcher.md +198 -0
  149. package/tests/cypress/fixtures/blocks.json +218 -0
  150. package/tests/cypress/fixtures/entities.json +78 -0
  151. package/tests/cypress/fixtures/page-builder.json +21 -0
  152. package/tests/cypress/src/components/CategoriesPOM.ts +382 -0
  153. package/tests/cypress/src/components/CustomersPOM.ts +439 -0
  154. package/tests/cypress/src/components/DevKeyringPOM.ts +160 -0
  155. package/tests/cypress/src/components/EntityForm.ts +375 -0
  156. package/tests/cypress/src/components/EntityList.ts +389 -0
  157. package/tests/cypress/src/components/PageBuilderPOM.ts +710 -0
  158. package/tests/cypress/src/components/PostEditorPOM.ts +370 -0
  159. package/tests/cypress/src/components/PostsListPOM.ts +223 -0
  160. package/tests/cypress/src/components/PublicPagePOM.ts +447 -0
  161. package/tests/cypress/src/components/PublicPostPOM.ts +146 -0
  162. package/tests/cypress/src/components/TasksPOM.ts +272 -0
  163. package/tests/cypress/src/components/TeamSwitcherPOM.ts +450 -0
  164. package/tests/cypress/src/components/index.ts +21 -0
  165. package/tests/cypress/src/controllers/ApiKeysAPIController.js +178 -0
  166. package/tests/cypress/src/controllers/BaseAPIController.js +317 -0
  167. package/tests/cypress/src/controllers/CustomerAPIController.js +251 -0
  168. package/tests/cypress/src/controllers/PagesAPIController.js +226 -0
  169. package/tests/cypress/src/controllers/PostsAPIController.js +250 -0
  170. package/tests/cypress/src/controllers/TaskAPIController.js +240 -0
  171. package/tests/cypress/src/controllers/UsersAPIController.js +242 -0
  172. package/tests/cypress/src/controllers/index.js +25 -0
  173. package/tests/cypress/src/core/AuthPOM.ts +450 -0
  174. package/tests/cypress/src/core/BasePOM.ts +86 -0
  175. package/tests/cypress/src/core/BlockEditorBasePOM.ts +576 -0
  176. package/tests/cypress/src/core/DashboardEntityPOM.ts +692 -0
  177. package/tests/cypress/src/core/index.ts +14 -0
  178. package/tests/cypress/src/entities/CustomersPOM.ts +172 -0
  179. package/tests/cypress/src/entities/PagesPOM.ts +137 -0
  180. package/tests/cypress/src/entities/PostsPOM.ts +137 -0
  181. package/tests/cypress/src/entities/TasksPOM.ts +176 -0
  182. package/tests/cypress/src/entities/index.ts +14 -0
  183. package/tests/cypress/src/features/BillingPOM.ts +385 -0
  184. package/tests/cypress/src/features/DashboardPOM.ts +245 -0
  185. package/tests/cypress/src/features/DevtoolsPOM.ts +739 -0
  186. package/tests/cypress/src/features/PageBuilderPOM.ts +263 -0
  187. package/tests/cypress/src/features/PostEditorPOM.ts +313 -0
  188. package/tests/cypress/src/features/ScheduledActionsPOM.ts +463 -0
  189. package/tests/cypress/src/features/SettingsPOM.ts +362 -0
  190. package/tests/cypress/src/features/SuperadminPOM.ts +331 -0
  191. package/tests/cypress/src/features/SuperadminTeamRolesPOM.ts +285 -0
  192. package/tests/cypress/src/features/index.ts +28 -0
  193. package/tests/cypress/src/helpers/ApiInterceptor.ts +177 -0
  194. package/tests/cypress/src/index.ts +101 -0
  195. package/tests/cypress/src/pages/dashboard/Dashboard.js +677 -0
  196. package/tests/cypress/src/pages/dashboard/DashboardPage.js +43 -0
  197. package/tests/cypress/src/pages/dashboard/DashboardStats.js +546 -0
  198. package/tests/cypress/src/pages/dashboard/index.js +6 -0
  199. package/tests/cypress/src/pages/index.js +5 -0
  200. package/tests/cypress/src/pages/public/FeaturesPage.js +28 -0
  201. package/tests/cypress/src/pages/public/LandingPage.js +69 -0
  202. package/tests/cypress/src/pages/public/PricingPage.js +33 -0
  203. package/tests/cypress/src/pages/public/index.js +6 -0
  204. package/tests/cypress/src/selectors.ts +46 -0
  205. package/tests/cypress/src/session-helpers.ts +500 -0
  206. package/tests/cypress/support/doc-commands.ts +260 -0
  207. package/tests/cypress.config.ts +150 -0
  208. package/tests/jest/components/post-header.test.tsx +377 -0
  209. package/tests/jest/config/role-config.test.ts +529 -0
  210. package/tests/jest/jest.config.ts +81 -0
  211. package/tests/jest/langchain/COVERAGE.md +372 -0
  212. package/tests/jest/langchain/guardrails.test.ts +465 -0
  213. package/tests/jest/langchain/streaming.test.ts +367 -0
  214. package/tests/jest/langchain/token-tracker.test.ts +455 -0
  215. package/tests/jest/langchain/tracer-callbacks.test.ts +881 -0
  216. package/tests/jest/langchain/tracer.test.ts +823 -0
  217. package/tests/jest/user-roles/role-helpers.test.ts +432 -0
  218. package/tests/jest/validation/categories.test.ts +429 -0
  219. package/tests/jest/validation/posts.test.ts +546 -0
  220. package/tests/tsconfig.json +15 -0
@@ -0,0 +1,1151 @@
1
+ # Team Switcher UI Tests (Format: BDD/Gherkin - Bilingual)
2
+
3
+ > **Test File:** `team-switcher.cy.ts`
4
+ > **Format:** Behavior-Driven Development (BDD) with Given/When/Then
5
+ > **Languages:** English / Spanish (side-by-side)
6
+ > **Total Tests:** 25
7
+
8
+ ---
9
+
10
+ ## Feature: Team Switcher Component
11
+
12
+ <table>
13
+ <tr>
14
+ <th width="50%">English</th>
15
+ <th width="50%">Español</th>
16
+ </tr>
17
+ <tr>
18
+ <td>
19
+
20
+ As a **multi-tenant user**
21
+ I want to **switch between teams using the TeamSwitcherCompact component**
22
+ So that **I can access different team contexts and manage their data**
23
+
24
+ **Key Functionality:**
25
+ - View teams in dropdown
26
+ - Switch between teams
27
+ - Data reloads after switch
28
+ - Permission changes per team role
29
+
30
+ </td>
31
+ <td>
32
+
33
+ Como **usuario multi-tenant**
34
+ Quiero **cambiar entre equipos usando el componente TeamSwitcherCompact**
35
+ Para **acceder a diferentes contextos de equipo y gestionar sus datos**
36
+
37
+ **Funcionalidad Clave:**
38
+ - Ver equipos en dropdown
39
+ - Cambiar entre equipos
40
+ - Datos se recargan tras cambio
41
+ - Permisos cambian según rol del equipo
42
+
43
+ </td>
44
+ </tr>
45
+ </table>
46
+
47
+ ### Test Users / Usuarios de Prueba
48
+
49
+ | User | Email | Teams & Roles |
50
+ |------|-------|---------------|
51
+ | Carlos (Multi-team) | carlos.mendoza@nextspark.dev | Everpoint (owner), Riverstone (member), Ironvale (admin) |
52
+ | Sofia | sofia.lopez@nextspark.dev | Riverstone (owner), Ironvale (admin) |
53
+ | Emily | emily.johnson@nextspark.dev | Everpoint (member), Riverstone (admin) |
54
+ | James | james.wilson@nextspark.dev | Everpoint (admin), Riverstone (member) |
55
+ | Ana (Single-team) | ana.garcia@nextspark.dev | Ironvale Global (owner) |
56
+ | Sarah (Viewer) | sarah.davis@nextspark.dev | Ironvale Global (viewer) |
57
+
58
+ ---
59
+
60
+ ## Single/Few Team User
61
+
62
+ ### TEAM_SW_001: User sees their teams in switcher `@smoke`
63
+
64
+ <table>
65
+ <tr>
66
+ <th width="50%">English</th>
67
+ <th width="50%">Español</th>
68
+ </tr>
69
+ <tr>
70
+ <td>
71
+
72
+ ```gherkin
73
+ Scenario: User sees their teams in switcher
74
+
75
+ Given I am logged in as Ana (single-team user)
76
+ And I am on the dashboard
77
+ When I open the team switcher dropdown
78
+ Then the switcher should be visible
79
+ And I should see at least 1 team in the list
80
+ ```
81
+
82
+ </td>
83
+ <td>
84
+
85
+ ```gherkin
86
+ Scenario: Usuario ve sus equipos en el selector
87
+
88
+ Given estoy logueado como Ana (usuario single-team)
89
+ And estoy en el dashboard
90
+ When abro el dropdown del selector de equipos
91
+ Then el selector deberia estar visible
92
+ And deberia ver al menos 1 equipo en la lista
93
+ ```
94
+
95
+ </td>
96
+ </tr>
97
+ </table>
98
+
99
+ ---
100
+
101
+ ### TEAM_SW_002: Manage Teams link is visible and navigates correctly
102
+
103
+ <table>
104
+ <tr>
105
+ <th width="50%">English</th>
106
+ <th width="50%">Español</th>
107
+ </tr>
108
+ <tr>
109
+ <td>
110
+
111
+ ```gherkin
112
+ Scenario: Manage Teams link works correctly
113
+
114
+ Given I am logged in as Ana
115
+ And I am on the dashboard
116
+ When I open the team switcher
117
+ Then the "Manage Teams" link should be visible
118
+ And clicking it should navigate to team management
119
+ ```
120
+
121
+ </td>
122
+ <td>
123
+
124
+ ```gherkin
125
+ Scenario: Enlace Gestionar Equipos funciona correctamente
126
+
127
+ Given estoy logueado como Ana
128
+ And estoy en el dashboard
129
+ When abro el selector de equipos
130
+ Then el enlace "Gestionar Equipos" deberia estar visible
131
+ And al hacer clic deberia navegar a gestion de equipos
132
+ ```
133
+
134
+ </td>
135
+ </tr>
136
+ </table>
137
+
138
+ ---
139
+
140
+ ## Multi-Team User
141
+
142
+ ### TEAM_SW_010: Multi-team user sees all teams
143
+
144
+ <table>
145
+ <tr>
146
+ <th width="50%">English</th>
147
+ <th width="50%">Español</th>
148
+ </tr>
149
+ <tr>
150
+ <td>
151
+
152
+ ```gherkin
153
+ Scenario: Multi-team user sees all their teams
154
+
155
+ Given I am logged in as Carlos (multi-team user)
156
+ And I am on the dashboard
157
+ When I open the team switcher dropdown
158
+ Then the switcher should be visible
159
+ And I should see at least 2 teams
160
+ And "Everpoint Labs" should be in the list
161
+ And "Riverstone Ventures" should be in the list
162
+ ```
163
+
164
+ </td>
165
+ <td>
166
+
167
+ ```gherkin
168
+ Scenario: Usuario multi-team ve todos sus equipos
169
+
170
+ Given estoy logueado como Carlos (usuario multi-team)
171
+ And estoy en el dashboard
172
+ When abro el dropdown del selector de equipos
173
+ Then el selector deberia estar visible
174
+ And deberia ver al menos 2 equipos
175
+ And "Everpoint Labs" deberia estar en la lista
176
+ And "Riverstone Ventures" deberia estar en la lista
177
+ ```
178
+
179
+ </td>
180
+ </tr>
181
+ </table>
182
+
183
+ ---
184
+
185
+ ### TEAM_SW_011: Current team shows checkmark
186
+
187
+ <table>
188
+ <tr>
189
+ <th width="50%">English</th>
190
+ <th width="50%">Español</th>
191
+ </tr>
192
+ <tr>
193
+ <td>
194
+
195
+ ```gherkin
196
+ Scenario: Current team is indicated with checkmark
197
+
198
+ Given I am logged in as Carlos
199
+ And my current team is "Everpoint Labs"
200
+ When I open the team switcher
201
+ Then "Everpoint Labs" should have a checkmark
202
+ And "Riverstone Ventures" should NOT have a checkmark
203
+ ```
204
+
205
+ </td>
206
+ <td>
207
+
208
+ ```gherkin
209
+ Scenario: Equipo actual se indica con checkmark
210
+
211
+ Given estoy logueado como Carlos
212
+ And mi equipo actual es "Everpoint Labs"
213
+ When abro el selector de equipos
214
+ Then "Everpoint Labs" deberia tener un checkmark
215
+ And "Riverstone Ventures" NO deberia tener checkmark
216
+ ```
217
+
218
+ </td>
219
+ </tr>
220
+ </table>
221
+
222
+ ---
223
+
224
+ ### TEAM_SW_012: Roles are displayed correctly
225
+
226
+ <table>
227
+ <tr>
228
+ <th width="50%">English</th>
229
+ <th width="50%">Español</th>
230
+ </tr>
231
+ <tr>
232
+ <td>
233
+
234
+ ```gherkin
235
+ Scenario: User roles are displayed for each team
236
+
237
+ Given I am logged in as Carlos
238
+ And I have different roles in different teams
239
+ When I open the team switcher
240
+ Then "Everpoint Labs" should show "Propietario" role
241
+ And "Riverstone Ventures" should show "Miembro" role
242
+ ```
243
+
244
+ **Note:** Roles displayed in Spanish (app locale).
245
+
246
+ </td>
247
+ <td>
248
+
249
+ ```gherkin
250
+ Scenario: Roles de usuario se muestran para cada equipo
251
+
252
+ Given estoy logueado como Carlos
253
+ And tengo diferentes roles en diferentes equipos
254
+ When abro el selector de equipos
255
+ Then "Everpoint Labs" deberia mostrar rol "Propietario"
256
+ And "Riverstone Ventures" deberia mostrar rol "Miembro"
257
+ ```
258
+
259
+ **Nota:** Roles mostrados en español (locale de la app).
260
+
261
+ </td>
262
+ </tr>
263
+ </table>
264
+
265
+ ---
266
+
267
+ ### TEAM_SW_013: Can switch teams successfully
268
+
269
+ <table>
270
+ <tr>
271
+ <th width="50%">English</th>
272
+ <th width="50%">Español</th>
273
+ </tr>
274
+ <tr>
275
+ <td>
276
+
277
+ ```gherkin
278
+ Scenario: User can switch between teams
279
+
280
+ Given I am logged in as Carlos
281
+ And my current team is "Everpoint Labs"
282
+ When I select "Riverstone Ventures" from the switcher
283
+ Then the page should reload
284
+ And my current team should be "Riverstone Ventures"
285
+ ```
286
+
287
+ </td>
288
+ <td>
289
+
290
+ ```gherkin
291
+ Scenario: Usuario puede cambiar entre equipos
292
+
293
+ Given estoy logueado como Carlos
294
+ And mi equipo actual es "Everpoint Labs"
295
+ When selecciono "Riverstone Ventures" del selector
296
+ Then la pagina deberia recargarse
297
+ And mi equipo actual deberia ser "Riverstone Ventures"
298
+ ```
299
+
300
+ </td>
301
+ </tr>
302
+ </table>
303
+
304
+ ---
305
+
306
+ ### TEAM_SW_014: Modal appears during switch
307
+
308
+ <table>
309
+ <tr>
310
+ <th width="50%">English</th>
311
+ <th width="50%">Español</th>
312
+ </tr>
313
+ <tr>
314
+ <td>
315
+
316
+ ```gherkin
317
+ Scenario: Loading modal appears during team switch
318
+
319
+ Given I am logged in as Carlos
320
+ And I am on the dashboard
321
+ When I select a different team from the switcher
322
+ Then a switching modal should appear
323
+ And the modal should indicate team change in progress
324
+ ```
325
+
326
+ </td>
327
+ <td>
328
+
329
+ ```gherkin
330
+ Scenario: Modal de carga aparece durante cambio de equipo
331
+
332
+ Given estoy logueado como Carlos
333
+ And estoy en el dashboard
334
+ When selecciono un equipo diferente del selector
335
+ Then deberia aparecer un modal de cambio
336
+ And el modal deberia indicar cambio de equipo en progreso
337
+ ```
338
+
339
+ </td>
340
+ </tr>
341
+ </table>
342
+
343
+ ---
344
+
345
+ ## Data Reload After Switch
346
+
347
+ ### TEAM_SW_020: Customers reload after switch
348
+
349
+ <table>
350
+ <tr>
351
+ <th width="50%">English</th>
352
+ <th width="50%">Español</th>
353
+ </tr>
354
+ <tr>
355
+ <td>
356
+
357
+ ```gherkin
358
+ Scenario: Customers list reloads with new team data
359
+
360
+ Given I am logged in as Carlos on "Everpoint Labs"
361
+ And I am on the customers page
362
+ When I switch to "Riverstone Ventures"
363
+ And I navigate to customers page
364
+ Then the customers should be for "Riverstone Ventures"
365
+ And the team name in switcher should reflect the change
366
+ ```
367
+
368
+ </td>
369
+ <td>
370
+
371
+ ```gherkin
372
+ Scenario: Lista de clientes se recarga con datos del nuevo equipo
373
+
374
+ Given estoy logueado como Carlos en "Everpoint Labs"
375
+ And estoy en la pagina de clientes
376
+ When cambio a "Riverstone Ventures"
377
+ And navego a la pagina de clientes
378
+ Then los clientes deberian ser de "Riverstone Ventures"
379
+ And el nombre del equipo en selector deberia reflejar el cambio
380
+ ```
381
+
382
+ </td>
383
+ </tr>
384
+ </table>
385
+
386
+ ---
387
+
388
+ ### TEAM_SW_021: Tasks reload after switch
389
+
390
+ <table>
391
+ <tr>
392
+ <th width="50%">English</th>
393
+ <th width="50%">Español</th>
394
+ </tr>
395
+ <tr>
396
+ <td>
397
+
398
+ ```gherkin
399
+ Scenario: Tasks list reloads with new team data
400
+
401
+ Given I am logged in as Carlos on "Everpoint Labs"
402
+ And I am on the tasks page
403
+ When I switch to "Riverstone Ventures"
404
+ And I navigate to tasks page
405
+ Then the tasks should be for "Riverstone Ventures"
406
+ And the team name in switcher should reflect the change
407
+ ```
408
+
409
+ </td>
410
+ <td>
411
+
412
+ ```gherkin
413
+ Scenario: Lista de tareas se recarga con datos del nuevo equipo
414
+
415
+ Given estoy logueado como Carlos en "Everpoint Labs"
416
+ And estoy en la pagina de tareas
417
+ When cambio a "Riverstone Ventures"
418
+ And navego a la pagina de tareas
419
+ Then las tareas deberian ser de "Riverstone Ventures"
420
+ And el nombre del equipo en selector deberia reflejar el cambio
421
+ ```
422
+
423
+ </td>
424
+ </tr>
425
+ </table>
426
+
427
+ ---
428
+
429
+ ### TEAM_SW_022: Sidebar shows new team name
430
+
431
+ <table>
432
+ <tr>
433
+ <th width="50%">English</th>
434
+ <th width="50%">Español</th>
435
+ </tr>
436
+ <tr>
437
+ <td>
438
+
439
+ ```gherkin
440
+ Scenario: Sidebar reflects new team after switch
441
+
442
+ Given I am logged in as Carlos
443
+ And the sidebar shows "Everpoint Labs"
444
+ When I switch to "Riverstone Ventures"
445
+ Then the sidebar should show "Riverstone Ventures"
446
+ ```
447
+
448
+ </td>
449
+ <td>
450
+
451
+ ```gherkin
452
+ Scenario: Sidebar refleja nuevo equipo tras cambio
453
+
454
+ Given estoy logueado como Carlos
455
+ And el sidebar muestra "Everpoint Labs"
456
+ When cambio a "Riverstone Ventures"
457
+ Then el sidebar deberia mostrar "Riverstone Ventures"
458
+ ```
459
+
460
+ </td>
461
+ </tr>
462
+ </table>
463
+
464
+ ---
465
+
466
+ ## Permission Changes
467
+
468
+ ### TEAM_SW_030: Owner can create customer
469
+
470
+ <table>
471
+ <tr>
472
+ <th width="50%">English</th>
473
+ <th width="50%">Español</th>
474
+ </tr>
475
+ <tr>
476
+ <td>
477
+
478
+ ```gherkin
479
+ Scenario: Owner has create permission for customers
480
+
481
+ Given I am logged in as Carlos (owner in Everpoint)
482
+ And my current team is "Everpoint Labs"
483
+ When I navigate to the customers page
484
+ Then the page should load successfully
485
+ And the "Add" button should be visible
486
+ ```
487
+
488
+ </td>
489
+ <td>
490
+
491
+ ```gherkin
492
+ Scenario: Owner tiene permiso de creacion para clientes
493
+
494
+ Given estoy logueado como Carlos (owner en Everpoint)
495
+ And mi equipo actual es "Everpoint Labs"
496
+ When navego a la pagina de clientes
497
+ Then la pagina deberia cargar exitosamente
498
+ And el boton "Agregar" deberia estar visible
499
+ ```
500
+
501
+ </td>
502
+ </tr>
503
+ </table>
504
+
505
+ ---
506
+
507
+ ### TEAM_SW_031: Owner can edit/delete customer via detail page
508
+
509
+ <table>
510
+ <tr>
511
+ <th width="50%">English</th>
512
+ <th width="50%">Español</th>
513
+ </tr>
514
+ <tr>
515
+ <td>
516
+
517
+ ```gherkin
518
+ Scenario: Owner can edit and delete from detail page
519
+
520
+ Given I am logged in as Carlos (owner in Everpoint)
521
+ And I am on the customers page
522
+ When I click on a customer row
523
+ Then I should navigate to the customer detail page
524
+ And the "Edit" button should be visible
525
+ And the "Delete" button should be visible
526
+ ```
527
+
528
+ </td>
529
+ <td>
530
+
531
+ ```gherkin
532
+ Scenario: Owner puede editar y eliminar desde pagina de detalle
533
+
534
+ Given estoy logueado como Carlos (owner en Everpoint)
535
+ And estoy en la pagina de clientes
536
+ When hago clic en una fila de cliente
537
+ Then deberia navegar a la pagina de detalle del cliente
538
+ And el boton "Editar" deberia estar visible
539
+ And el boton "Eliminar" deberia estar visible
540
+ ```
541
+
542
+ </td>
543
+ </tr>
544
+ </table>
545
+
546
+ ---
547
+
548
+ ### TEAM_SW_032: Member cannot create customer `@security`
549
+
550
+ <table>
551
+ <tr>
552
+ <th width="50%">English</th>
553
+ <th width="50%">Español</th>
554
+ </tr>
555
+ <tr>
556
+ <td>
557
+
558
+ ```gherkin
559
+ Scenario: Member cannot create customers
560
+
561
+ Given I am logged in as Carlos (member in Riverstone)
562
+ And I switch to "Riverstone Ventures"
563
+ When I navigate to the customers page
564
+ Then the page should load successfully
565
+ But the "Add" button should NOT exist
566
+ ```
567
+
568
+ **Security Verification:**
569
+ Create button must be completely hidden, not just disabled.
570
+
571
+ </td>
572
+ <td>
573
+
574
+ ```gherkin
575
+ Scenario: Member no puede crear clientes
576
+
577
+ Given estoy logueado como Carlos (member en Riverstone)
578
+ And cambio a "Riverstone Ventures"
579
+ When navego a la pagina de clientes
580
+ Then la pagina deberia cargar exitosamente
581
+ But el boton "Agregar" NO deberia existir
582
+ ```
583
+
584
+ **Verificacion de Seguridad:**
585
+ El boton crear debe estar completamente oculto, no solo deshabilitado.
586
+
587
+ </td>
588
+ </tr>
589
+ </table>
590
+
591
+ ---
592
+
593
+ ### TEAM_SW_033: Member cannot delete customer via detail page `@security`
594
+
595
+ <table>
596
+ <tr>
597
+ <th width="50%">English</th>
598
+ <th width="50%">Español</th>
599
+ </tr>
600
+ <tr>
601
+ <td>
602
+
603
+ ```gherkin
604
+ Scenario: Member cannot delete from detail page
605
+
606
+ Given I am logged in as Carlos (member in Riverstone)
607
+ And I switch to "Riverstone Ventures"
608
+ And I navigate to the customers page
609
+ When I click on a customer row
610
+ Then I should navigate to the detail page
611
+ But the "Delete" button should NOT exist
612
+ ```
613
+
614
+ </td>
615
+ <td>
616
+
617
+ ```gherkin
618
+ Scenario: Member no puede eliminar desde pagina de detalle
619
+
620
+ Given estoy logueado como Carlos (member en Riverstone)
621
+ And cambio a "Riverstone Ventures"
622
+ And navego a la pagina de clientes
623
+ When hago clic en una fila de cliente
624
+ Then deberia navegar a la pagina de detalle
625
+ But el boton "Eliminar" NO deberia existir
626
+ ```
627
+
628
+ </td>
629
+ </tr>
630
+ </table>
631
+
632
+ ---
633
+
634
+ ### TEAM_SW_034: Member blocked from /edit URL `@security`
635
+
636
+ <table>
637
+ <tr>
638
+ <th width="50%">English</th>
639
+ <th width="50%">Español</th>
640
+ </tr>
641
+ <tr>
642
+ <td>
643
+
644
+ ```gherkin
645
+ Scenario: Member blocked from direct edit URL access
646
+
647
+ Given I am logged in as Carlos (member in Riverstone)
648
+ And I switch to "Riverstone Ventures"
649
+ And I get a customer ID from the list
650
+ When I navigate directly to /dashboard/customers/{id}/edit
651
+ Then I should see a "Permission Denied" message
652
+ ```
653
+
654
+ **Security Verification:**
655
+ Direct URL manipulation must be blocked for unauthorized roles.
656
+
657
+ </td>
658
+ <td>
659
+
660
+ ```gherkin
661
+ Scenario: Member bloqueado de acceso directo a URL de edicion
662
+
663
+ Given estoy logueado como Carlos (member en Riverstone)
664
+ And cambio a "Riverstone Ventures"
665
+ And obtengo un ID de cliente de la lista
666
+ When navego directamente a /dashboard/customers/{id}/edit
667
+ Then deberia ver un mensaje de "Permiso Denegado"
668
+ ```
669
+
670
+ **Verificacion de Seguridad:**
671
+ La manipulacion directa de URL debe ser bloqueada para roles no autorizados.
672
+
673
+ </td>
674
+ </tr>
675
+ </table>
676
+
677
+ ---
678
+
679
+ ### TEAM_SW_035: Member cannot access create URL `@security`
680
+
681
+ <table>
682
+ <tr>
683
+ <th width="50%">English</th>
684
+ <th width="50%">Español</th>
685
+ </tr>
686
+ <tr>
687
+ <td>
688
+
689
+ ```gherkin
690
+ Scenario: Member lacks create permissions
691
+
692
+ Given I am logged in as Carlos (member in Riverstone)
693
+ And I switch to "Riverstone Ventures"
694
+ When I navigate to the customers page
695
+ Then the "Add" button should NOT exist
696
+ And there should be no way to access the create form
697
+ ```
698
+
699
+ </td>
700
+ <td>
701
+
702
+ ```gherkin
703
+ Scenario: Member carece de permisos de creacion
704
+
705
+ Given estoy logueado como Carlos (member en Riverstone)
706
+ And cambio a "Riverstone Ventures"
707
+ When navego a la pagina de clientes
708
+ Then el boton "Agregar" NO deberia existir
709
+ And no deberia haber forma de acceder al formulario de creacion
710
+ ```
711
+
712
+ </td>
713
+ </tr>
714
+ </table>
715
+
716
+ ---
717
+
718
+ ## UI Behavior
719
+
720
+ ### TEAM_SW_040: Dropdown closes on escape key
721
+
722
+ <table>
723
+ <tr>
724
+ <th width="50%">English</th>
725
+ <th width="50%">Español</th>
726
+ </tr>
727
+ <tr>
728
+ <td>
729
+
730
+ ```gherkin
731
+ Scenario: Dropdown closes with Escape key
732
+
733
+ Given I am logged in as Carlos
734
+ And I am on the dashboard
735
+ When I open the team switcher dropdown
736
+ And I press the Escape key
737
+ Then the dropdown should close
738
+ ```
739
+
740
+ </td>
741
+ <td>
742
+
743
+ ```gherkin
744
+ Scenario: Dropdown se cierra con tecla Escape
745
+
746
+ Given estoy logueado como Carlos
747
+ And estoy en el dashboard
748
+ When abro el dropdown del selector de equipos
749
+ And presiono la tecla Escape
750
+ Then el dropdown deberia cerrarse
751
+ ```
752
+
753
+ </td>
754
+ </tr>
755
+ </table>
756
+
757
+ ---
758
+
759
+ ### TEAM_SW_041: Team options display team names
760
+
761
+ <table>
762
+ <tr>
763
+ <th width="50%">English</th>
764
+ <th width="50%">Español</th>
765
+ </tr>
766
+ <tr>
767
+ <td>
768
+
769
+ ```gherkin
770
+ Scenario: Team names are displayed in dropdown options
771
+
772
+ Given I am logged in as Carlos
773
+ When I open the team switcher dropdown
774
+ Then I should see "Everpoint" in the options
775
+ And I should see "Riverstone" in the options
776
+ ```
777
+
778
+ </td>
779
+ <td>
780
+
781
+ ```gherkin
782
+ Scenario: Nombres de equipo se muestran en opciones del dropdown
783
+
784
+ Given estoy logueado como Carlos
785
+ When abro el dropdown del selector de equipos
786
+ Then deberia ver "Everpoint" en las opciones
787
+ And deberia ver "Riverstone" en las opciones
788
+ ```
789
+
790
+ </td>
791
+ </tr>
792
+ </table>
793
+
794
+ ---
795
+
796
+ ### TEAM_SW_042: Switcher hidden when sidebar collapsed
797
+
798
+ <table>
799
+ <tr>
800
+ <th width="50%">English</th>
801
+ <th width="50%">Español</th>
802
+ </tr>
803
+ <tr>
804
+ <td>
805
+
806
+ ```gherkin
807
+ Scenario: Team switcher visibility follows sidebar state
808
+
809
+ Given I am logged in as Carlos
810
+ And the sidebar is expanded
811
+ And the team switcher is visible
812
+ When I collapse the sidebar
813
+ Then the team switcher should NOT be visible
814
+ When I expand the sidebar again
815
+ Then the team switcher should be visible again
816
+ ```
817
+
818
+ </td>
819
+ <td>
820
+
821
+ ```gherkin
822
+ Scenario: Visibilidad del selector sigue estado del sidebar
823
+
824
+ Given estoy logueado como Carlos
825
+ And el sidebar esta expandido
826
+ And el selector de equipos esta visible
827
+ When colapso el sidebar
828
+ Then el selector de equipos NO deberia estar visible
829
+ When expando el sidebar nuevamente
830
+ Then el selector de equipos deberia estar visible de nuevo
831
+ ```
832
+
833
+ </td>
834
+ </tr>
835
+ </table>
836
+
837
+ ---
838
+
839
+ ## Viewer Role
840
+
841
+ ### TEAM_SW_043: Viewer can only read customers `@security`
842
+
843
+ <table>
844
+ <tr>
845
+ <th width="50%">English</th>
846
+ <th width="50%">Español</th>
847
+ </tr>
848
+ <tr>
849
+ <td>
850
+
851
+ ```gherkin
852
+ Scenario: Viewer has read-only access to customers
853
+
854
+ Given I am logged in as Sarah (viewer in Ironvale)
855
+ When I navigate to the customers page
856
+ Then I should either see the customer list
857
+ Or I should be redirected (access denied)
858
+ But if the list is visible, the "Add" button should NOT exist
859
+ ```
860
+
861
+ </td>
862
+ <td>
863
+
864
+ ```gherkin
865
+ Scenario: Viewer tiene acceso solo lectura a clientes
866
+
867
+ Given estoy logueado como Sarah (viewer en Ironvale)
868
+ When navego a la pagina de clientes
869
+ Then deberia ver la lista de clientes
870
+ Or deberia ser redirigido (acceso denegado)
871
+ But si la lista es visible, el boton "Agregar" NO deberia existir
872
+ ```
873
+
874
+ </td>
875
+ </tr>
876
+ </table>
877
+
878
+ ---
879
+
880
+ ### TEAM_SW_044: Viewer can only read tasks `@security`
881
+
882
+ <table>
883
+ <tr>
884
+ <th width="50%">English</th>
885
+ <th width="50%">Español</th>
886
+ </tr>
887
+ <tr>
888
+ <td>
889
+
890
+ ```gherkin
891
+ Scenario: Viewer has read-only access to tasks
892
+
893
+ Given I am logged in as Sarah (viewer in Ironvale)
894
+ When I navigate to the tasks page
895
+ Then I should either see the tasks list
896
+ Or I should be redirected (access denied)
897
+ But if the list is visible, the "Add" button should NOT exist
898
+ ```
899
+
900
+ </td>
901
+ <td>
902
+
903
+ ```gherkin
904
+ Scenario: Viewer tiene acceso solo lectura a tareas
905
+
906
+ Given estoy logueado como Sarah (viewer en Ironvale)
907
+ When navego a la pagina de tareas
908
+ Then deberia ver la lista de tareas
909
+ Or deberia ser redirigido (acceso denegado)
910
+ But si la lista es visible, el boton "Agregar" NO deberia existir
911
+ ```
912
+
913
+ </td>
914
+ </tr>
915
+ </table>
916
+
917
+ ---
918
+
919
+ ### TEAM_SW_045: Viewer blocked from create URL `@security`
920
+
921
+ <table>
922
+ <tr>
923
+ <th width="50%">English</th>
924
+ <th width="50%">Español</th>
925
+ </tr>
926
+ <tr>
927
+ <td>
928
+
929
+ ```gherkin
930
+ Scenario: Viewer blocked from create URL
931
+
932
+ Given I am logged in as Sarah (viewer in Ironvale)
933
+ When I navigate directly to /dashboard/customers/create
934
+ Then I should see "Permission Denied" message
935
+ Or I should be redirected away from the create form
936
+ And the customer creation form should NOT be visible
937
+ ```
938
+
939
+ </td>
940
+ <td>
941
+
942
+ ```gherkin
943
+ Scenario: Viewer bloqueado de URL de creacion
944
+
945
+ Given estoy logueado como Sarah (viewer en Ironvale)
946
+ When navego directamente a /dashboard/customers/create
947
+ Then deberia ver mensaje de "Permiso Denegado"
948
+ Or deberia ser redirigido fuera del formulario de creacion
949
+ And el formulario de creacion de cliente NO deberia estar visible
950
+ ```
951
+
952
+ </td>
953
+ </tr>
954
+ </table>
955
+
956
+ ---
957
+
958
+ ## Mobile
959
+
960
+ ### TEAM_SW_050: Switcher visible in MobileMoreSheet
961
+
962
+ <table>
963
+ <tr>
964
+ <th width="50%">English</th>
965
+ <th width="50%">Español</th>
966
+ </tr>
967
+ <tr>
968
+ <td>
969
+
970
+ ```gherkin
971
+ Scenario: Team switcher is accessible on mobile
972
+
973
+ Given I am logged in as Carlos
974
+ And I am viewing on mobile viewport (iPhone X)
975
+ When I open the mobile "More" menu
976
+ Then the team switcher should be visible in the sheet
977
+ ```
978
+
979
+ </td>
980
+ <td>
981
+
982
+ ```gherkin
983
+ Scenario: Selector de equipos es accesible en movil
984
+
985
+ Given estoy logueado como Carlos
986
+ And estoy viendo en viewport movil (iPhone X)
987
+ When abro el menu "Mas" movil
988
+ Then el selector de equipos deberia estar visible en el sheet
989
+ ```
990
+
991
+ </td>
992
+ </tr>
993
+ </table>
994
+
995
+ ---
996
+
997
+ ### TEAM_SW_051: Can switch teams from mobile
998
+
999
+ <table>
1000
+ <tr>
1001
+ <th width="50%">English</th>
1002
+ <th width="50%">Español</th>
1003
+ </tr>
1004
+ <tr>
1005
+ <td>
1006
+
1007
+ ```gherkin
1008
+ Scenario: Team switching works on mobile
1009
+
1010
+ Given I am logged in as Carlos
1011
+ And I am viewing on mobile viewport
1012
+ When I open the mobile "More" menu
1013
+ And I switch to "Riverstone Ventures"
1014
+ Then the page should reload
1015
+ And the switcher should show "Riverstone"
1016
+ ```
1017
+
1018
+ </td>
1019
+ <td>
1020
+
1021
+ ```gherkin
1022
+ Scenario: Cambio de equipo funciona en movil
1023
+
1024
+ Given estoy logueado como Carlos
1025
+ And estoy viendo en viewport movil
1026
+ When abro el menu "Mas" movil
1027
+ And cambio a "Riverstone Ventures"
1028
+ Then la pagina deberia recargarse
1029
+ And el selector deberia mostrar "Riverstone"
1030
+ ```
1031
+
1032
+ </td>
1033
+ </tr>
1034
+ </table>
1035
+
1036
+ ---
1037
+
1038
+ ### TEAM_SW_052: Mobile shows all teams
1039
+
1040
+ <table>
1041
+ <tr>
1042
+ <th width="50%">English</th>
1043
+ <th width="50%">Español</th>
1044
+ </tr>
1045
+ <tr>
1046
+ <td>
1047
+
1048
+ ```gherkin
1049
+ Scenario: All teams visible on mobile dropdown
1050
+
1051
+ Given I am logged in as Carlos
1052
+ And I am viewing on mobile viewport
1053
+ When I open the mobile "More" menu
1054
+ And I open the team dropdown
1055
+ Then "Everpoint Labs" should be visible
1056
+ And "Riverstone Ventures" should be visible
1057
+ ```
1058
+
1059
+ </td>
1060
+ <td>
1061
+
1062
+ ```gherkin
1063
+ Scenario: Todos los equipos visibles en dropdown movil
1064
+
1065
+ Given estoy logueado como Carlos
1066
+ And estoy viendo en viewport movil
1067
+ When abro el menu "Mas" movil
1068
+ And abro el dropdown de equipos
1069
+ Then "Everpoint Labs" deberia estar visible
1070
+ And "Riverstone Ventures" deberia estar visible
1071
+ ```
1072
+
1073
+ </td>
1074
+ </tr>
1075
+ </table>
1076
+
1077
+ ---
1078
+
1079
+ ## UI Elements / Elementos UI
1080
+
1081
+ ### Team Switcher Component
1082
+
1083
+ | Element | Selector | Description / Descripción |
1084
+ |---------|----------|---------------------------|
1085
+ | Switcher Trigger | `[data-cy="team-switcher-trigger"]` | Main switcher button |
1086
+ | Dropdown | `[data-cy="team-switcher-dropdown"]` | Dropdown container |
1087
+ | Team Option | `[data-cy="team-option-{slug}"]` | Individual team option |
1088
+ | Manage Teams Link | `[data-cy="manage-teams-link"]` | Link to team management |
1089
+ | Switch Modal | `[data-cy="team-switch-modal"]` | Loading modal during switch |
1090
+
1091
+ ### Mobile Components
1092
+
1093
+ | Element | Selector | Description / Descripción |
1094
+ |---------|----------|---------------------------|
1095
+ | More Button | `[data-cy="mobile-more-button"]` | Mobile "More" menu trigger |
1096
+ | More Sheet | `[data-cy="mobile-more-sheet"]` | Mobile bottom sheet |
1097
+
1098
+ ### Permission Indicators
1099
+
1100
+ | Element | Selector | Description / Descripción |
1101
+ |---------|----------|---------------------------|
1102
+ | Add Button | `[data-cy="{entity}-add"]` | Create button (entity-specific) |
1103
+ | Edit Button | `[data-cy="{entity}-edit-btn"]` | Edit button on detail page |
1104
+ | Delete Button | `[data-cy="{entity}-delete-btn"]` | Delete button on detail page |
1105
+ | Permission Denied | `[data-cy="permission-denied"]` | Permission denied message |
1106
+
1107
+ ---
1108
+
1109
+ ## Permission Matrix by Role / Matriz de Permisos por Rol
1110
+
1111
+ | Operation / Operación | Owner | Admin | Member | Viewer |
1112
+ |-----------------------|:-----:|:-----:|:------:|:------:|
1113
+ | View Teams | Yes | Yes | Yes | Yes |
1114
+ | Switch Teams | Yes | Yes | Yes | Yes |
1115
+ | Create Customer | Yes | Yes | **No** | **No** |
1116
+ | Edit Customer | Yes | Yes | **No** | **No** |
1117
+ | Delete Customer | Yes | Yes | **No** | **No** |
1118
+ | Access /edit URL | Yes | Yes | **No** | **No** |
1119
+ | Access /create URL | Yes | Yes | **No** | **No** |
1120
+
1121
+ ---
1122
+
1123
+ ## Test Summary / Resumen de Tests
1124
+
1125
+ | Test ID | Block | Description / Descripción | Tags |
1126
+ |---------|-------|---------------------------|------|
1127
+ | TEAM_SW_001 | Single Team | User sees teams in switcher | `@smoke` |
1128
+ | TEAM_SW_002 | Single Team | Manage Teams link works | |
1129
+ | TEAM_SW_010 | Multi-Team | Multi-team user sees all teams | |
1130
+ | TEAM_SW_011 | Multi-Team | Current team shows checkmark | |
1131
+ | TEAM_SW_012 | Multi-Team | Roles displayed correctly | |
1132
+ | TEAM_SW_013 | Multi-Team | Can switch teams successfully | |
1133
+ | TEAM_SW_014 | Multi-Team | Modal appears during switch | |
1134
+ | TEAM_SW_020 | Data Reload | Customers reload after switch | |
1135
+ | TEAM_SW_021 | Data Reload | Tasks reload after switch | |
1136
+ | TEAM_SW_022 | Data Reload | Sidebar shows new team name | |
1137
+ | TEAM_SW_030 | Permissions | Owner can create customer | |
1138
+ | TEAM_SW_031 | Permissions | Owner can edit/delete customer | |
1139
+ | TEAM_SW_032 | Permissions | Member cannot create customer | `@security` |
1140
+ | TEAM_SW_033 | Permissions | Member cannot delete customer | `@security` |
1141
+ | TEAM_SW_034 | Permissions | Member blocked from /edit URL | `@security` |
1142
+ | TEAM_SW_035 | Permissions | Member cannot access create URL | `@security` |
1143
+ | TEAM_SW_040 | UI Behavior | Dropdown closes on escape | |
1144
+ | TEAM_SW_041 | UI Behavior | Team options display names | |
1145
+ | TEAM_SW_042 | UI Behavior | Switcher hidden when sidebar collapsed | |
1146
+ | TEAM_SW_043 | Viewer Role | Viewer can only read customers | `@security` |
1147
+ | TEAM_SW_044 | Viewer Role | Viewer can only read tasks | `@security` |
1148
+ | TEAM_SW_045 | Viewer Role | Viewer blocked from create URL | `@security` |
1149
+ | TEAM_SW_050 | Mobile | Switcher visible in MobileMoreSheet | |
1150
+ | TEAM_SW_051 | Mobile | Can switch teams from mobile | |
1151
+ | TEAM_SW_052 | Mobile | Mobile shows all teams | |