@nextsparkjs/theme-default 0.1.0-beta.38 β†’ 0.1.0-beta.40

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 (25) hide show
  1. package/components/ai-chat/ChatPanel.tsx +1 -1
  2. package/components/ai-chat/Message.tsx +1 -1
  3. package/components/ai-chat/MessageInput.tsx +1 -1
  4. package/components/ai-chat/MessageList.tsx +1 -1
  5. package/components/ai-chat/TypingIndicator.tsx +1 -1
  6. package/lib/selectors.ts +2 -3
  7. package/package.json +3 -2
  8. package/tests/cypress/e2e/api/_core/billing/BillingAPIController.js +1 -1
  9. package/tests/cypress/e2e/api/_core/settings/api-keys.crud.cy.ts +1 -1
  10. package/tests/cypress/e2e/api/_core/users/users-crud.cy.ts +1 -1
  11. package/tests/cypress/e2e/api/_core/users/users-metas.cy.ts +1 -1
  12. package/tests/cypress/e2e/api/entities/customers/customers-crud.cy.ts +1 -1
  13. package/tests/cypress/e2e/api/entities/customers/customers-metas.cy.ts +1 -1
  14. package/tests/cypress/e2e/api/entities/tasks/tasks-crud.cy.ts +1 -1
  15. package/tests/cypress/e2e/api/entities/tasks/tasks-metas.cy.ts +1 -1
  16. package/tests/cypress/e2e/uat/_core/teams/team-switcher.md +2 -2
  17. package/tests/cypress/src/core/BasePOM.ts +23 -76
  18. package/tests/cypress/src/core/DashboardEntityPOM.ts +17 -668
  19. package/tests/cypress/src/entities/TasksPOM.ts +70 -0
  20. package/tests/cypress/src/helpers/ApiInterceptor.ts +14 -171
  21. package/tests/cypress.config.ts +12 -17
  22. package/tests/cypress/e2e/_utils/docs/tutorials/sector7-superadmin-teams.narration.json +0 -155
  23. package/tests/cypress/e2e/_utils/docs/tutorials/sector7-superadmin.cy.ts +0 -390
  24. package/tests/cypress/e2e/_utils/docs/tutorials/teams-system.doc.cy.ts +0 -349
  25. package/tests/cypress/e2e/_utils/docs/tutorials/teams-system.narration.json +0 -165
@@ -1,349 +0,0 @@
1
- /// <reference types="cypress" />
2
-
3
- /**
4
- * Teams System - Documentation Video
5
- *
6
- * This test generates a documentation video showing how the multi-tenant
7
- * team system works, including team switching and permission differences.
8
- *
9
- * Run with: NEXT_PUBLIC_ACTIVE_THEME=default pnpm cy:run --spec "teams-system.doc.cy.ts"
10
- *
11
- * Output:
12
- * - Video: cypress/videos/docs/tutorials/teams-system.doc.cy.ts.mp4
13
- * - Narrations: cypress/videos/narrations/teams-system.doc-narrations.json
14
- *
15
- * @tags @doc, @tutorial, @teams
16
- */
17
-
18
- // Import custom documentation commands (cy.narrate, cy.chapter, etc.)
19
- import '../../../support/doc-commands'
20
-
21
- // Import POMs
22
- import { DevKeyring } from '../../../../../../../../test/cypress/src/classes/components/auth/DevKeyring.js'
23
- import { TeamSwitcher } from '../../../../../../../../test/cypress/src/classes/components/teams/TeamSwitcher.js'
24
-
25
- // ============================================
26
- // Configuration
27
- // ============================================
28
-
29
- const CONFIG = {
30
- // Speed control (ms between commands) - for ~2min video
31
- commandDelay: 250,
32
-
33
- // Narration timing (ms)
34
- narration: {
35
- short: 1200, // ~10 words
36
- medium: 1800, // ~15-20 words
37
- long: 2400, // ~25+ words
38
- },
39
-
40
- // Test users
41
- users: {
42
- CARLOS: 'carlos.mendoza@nextspark.dev',
43
- },
44
-
45
- // Team slugs
46
- teams: {
47
- EVERPOINT: 'everpoint-labs',
48
- RIVERSTONE: 'riverstone-ventures',
49
- },
50
-
51
- // Spanish role names (app locale)
52
- roles: {
53
- OWNER: 'Propietario',
54
- MEMBER: 'Miembro',
55
- },
56
- }
57
-
58
- // ============================================
59
- // Documentation Test
60
- // ============================================
61
-
62
- describe('Tutorial: Sistema de Teams', {
63
- tags: ['@doc', '@tutorial', '@teams'],
64
- retries: 0, // No retries for documentation videos
65
- }, () => {
66
- let teamSwitcher: TeamSwitcher
67
-
68
- before(() => {
69
- // Start documentation mode with slow-down
70
- cy.startDocMode(CONFIG.commandDelay)
71
-
72
- cy.log('🎬 ═══════════════════════════════════════')
73
- cy.log('🎬 **DOCUMENTATION VIDEO RECORDING**')
74
- cy.log('🎬 Sistema de Teams - Multi-Tenancy')
75
- cy.log('🎬 ═══════════════════════════════════════')
76
- })
77
-
78
- beforeEach(() => {
79
- teamSwitcher = new TeamSwitcher()
80
- })
81
-
82
- after(() => {
83
- // End documentation mode and save narrations
84
- cy.endDocMode()
85
-
86
- cy.log('🎬 ═══════════════════════════════════════')
87
- cy.log('🎬 **RECORDING COMPLETE**')
88
- cy.log('🎬 ═══════════════════════════════════════')
89
- })
90
-
91
- // ============================================
92
- // Single test that captures the entire tutorial
93
- // ============================================
94
-
95
- it('demuestra el sistema completo de equipos y permisos', () => {
96
- // ─────────────────────────────────────────
97
- // CHAPTER 1: IntroducciΓ³n
98
- // ─────────────────────────────────────────
99
- cy.chapter('IntroducciΓ³n')
100
-
101
- cy.narrate(
102
- 'Bienvenido al tutorial del Sistema de Teams. Hoy aprenderΓ‘s cΓ³mo organizar tu trabajo en diferentes espacios.',
103
- { pause: CONFIG.narration.long }
104
- )
105
-
106
- cy.narrate(
107
- 'Carlos es un usuario con acceso a mΓΊltiples equipos. Veamos cΓ³mo funciona.',
108
- { pause: CONFIG.narration.medium }
109
- )
110
-
111
- // Login as Carlos
112
- cy.visit('/login')
113
- cy.wait(500, { log: false })
114
-
115
- const devKeyring = new DevKeyring()
116
- devKeyring.validateVisible()
117
-
118
- cy.narrate(
119
- 'Iniciamos sesiΓ³n con la cuenta de Carlos usando el selector de credenciales de prueba.',
120
- { pause: CONFIG.narration.medium }
121
- )
122
-
123
- devKeyring.quickLoginByEmail(CONFIG.users.CARLOS)
124
- cy.url().should('include', '/dashboard')
125
- cy.pauseForEmphasis(500)
126
-
127
- // ─────────────────────────────────────────
128
- // CHAPTER 2: El Selector de Equipos
129
- // ─────────────────────────────────────────
130
- cy.chapter('El Selector de Equipos')
131
-
132
- cy.narrate(
133
- 'En el panel lateral izquierdo encontramos el selector de equipos.',
134
- { pause: CONFIG.narration.medium }
135
- )
136
-
137
- // Ensure sidebar is expanded
138
- teamSwitcher.ensureSidebarExpanded()
139
- cy.pauseForEmphasis(300)
140
-
141
- // Highlight the team switcher
142
- cy.highlightElement('[data-cy="team-switcher-compact"]')
143
-
144
- cy.narrate(
145
- 'AquΓ­ vemos el equipo actual: Everpoint Labs, donde Carlos es propietario.',
146
- { pause: CONFIG.narration.medium }
147
- )
148
-
149
- // Validate current team
150
- teamSwitcher.validateCurrentTeamName('Everpoint Labs')
151
- cy.pauseForEmphasis(300)
152
-
153
- cy.narrate(
154
- 'Al hacer clic, se despliega una lista con todos los equipos disponibles.',
155
- { pause: CONFIG.narration.medium }
156
- )
157
-
158
- // Open dropdown
159
- teamSwitcher.open()
160
- cy.pauseForEmphasis(700)
161
-
162
- cy.narrate(
163
- 'Observa que cada equipo muestra el rol del usuario. Carlos es Propietario aquΓ­.',
164
- { pause: CONFIG.narration.long }
165
- )
166
-
167
- // Highlight Everpoint role
168
- cy.get(`[data-cy="team-option-${CONFIG.teams.EVERPOINT}"]`).then($el => {
169
- $el.css({
170
- outline: '3px solid #22c55e',
171
- outlineOffset: '2px',
172
- backgroundColor: 'rgba(34, 197, 94, 0.1)',
173
- })
174
- })
175
- cy.pauseForEmphasis(1000)
176
-
177
- cy.narrate(
178
- 'TambiΓ©n tiene acceso a Riverstone Ventures, pero aquΓ­ es solo Miembro.',
179
- { pause: CONFIG.narration.medium }
180
- )
181
-
182
- // Reset Everpoint, highlight Riverstone
183
- cy.get(`[data-cy="team-option-${CONFIG.teams.EVERPOINT}"]`).then($el => {
184
- $el.css({
185
- outline: 'none',
186
- backgroundColor: 'transparent',
187
- })
188
- })
189
-
190
- cy.get(`[data-cy="team-option-${CONFIG.teams.RIVERSTONE}"]`).then($el => {
191
- $el.css({
192
- outline: '3px solid #f59e0b',
193
- outlineOffset: '2px',
194
- backgroundColor: 'rgba(245, 158, 11, 0.1)',
195
- })
196
- })
197
- cy.pauseForEmphasis(1000)
198
-
199
- // Close dropdown
200
- cy.get('body').type('{esc}')
201
- cy.pauseForEmphasis(300)
202
-
203
- // ─────────────────────────────────────────
204
- // CHAPTER 3: Cambiar de Equipo
205
- // ─────────────────────────────────────────
206
- cy.chapter('Cambiar de Equipo')
207
-
208
- cy.narrate(
209
- 'Vamos a cambiar al equipo Riverstone Ventures para ver cΓ³mo cambia el contexto.',
210
- { pause: CONFIG.narration.medium }
211
- )
212
-
213
- // Start team switch
214
- teamSwitcher.open()
215
- cy.get(`[data-cy="team-option-${CONFIG.teams.RIVERSTONE}"]`).click()
216
-
217
- cy.narrate(
218
- 'El sistema estΓ‘ cargando los datos del nuevo equipo.',
219
- { pause: CONFIG.narration.medium }
220
- )
221
-
222
- // Wait for page to stabilize after team switch
223
- cy.url().should('include', '/dashboard')
224
- cy.pauseForEmphasis(1000)
225
-
226
- cy.narrate(
227
- 'Perfecto. Ahora estamos en Riverstone Ventures. Observa el cambio en el selector.',
228
- { pause: CONFIG.narration.medium }
229
- )
230
-
231
- // Highlight the changed team name
232
- cy.highlightElement('[data-cy="team-switcher-compact"]')
233
-
234
- teamSwitcher.validateCurrentTeamName('Riverstone Ventures')
235
-
236
- // ─────────────────────────────────────────
237
- // CHAPTER 4: Datos Separados por Equipo
238
- // ─────────────────────────────────────────
239
- cy.chapter('Datos Separados por Equipo')
240
-
241
- cy.narrate(
242
- 'Cada equipo tiene sus propios datos completamente aislados.',
243
- { pause: CONFIG.narration.medium }
244
- )
245
-
246
- cy.narrate(
247
- 'Vamos a la secciΓ³n de Clientes para comprobarlo.',
248
- { pause: CONFIG.narration.short }
249
- )
250
-
251
- // Navigate to customers
252
- cy.visit('/dashboard/customers')
253
- cy.get('[data-cy="customers-list"]', { timeout: 15000 }).should('exist')
254
- cy.pauseForEmphasis(700)
255
-
256
- cy.narrate(
257
- 'Estos son los clientes de Riverstone Ventures. Son independientes de los de Everpoint Labs.',
258
- { pause: CONFIG.narration.long }
259
- )
260
-
261
- cy.highlightElement('[data-cy="customers-list"]')
262
-
263
- // ─────────────────────────────────────────
264
- // CHAPTER 5: Permisos por Equipo
265
- // ─────────────────────────────────────────
266
- cy.chapter('Permisos por Equipo')
267
-
268
- cy.narrate(
269
- 'Ahora viene lo interesante: los permisos cambian segΓΊn tu rol en cada equipo.',
270
- { pause: CONFIG.narration.long }
271
- )
272
-
273
- cy.narrate(
274
- 'Como Carlos es Miembro aquΓ­, tiene acceso limitado. Observa la interfaz.',
275
- { pause: CONFIG.narration.medium }
276
- )
277
-
278
- cy.pauseForEmphasis(700)
279
-
280
- cy.narrate(
281
- 'No hay botΓ³n para crear nuevos clientes. Los miembros solo pueden ver los datos.',
282
- { pause: CONFIG.narration.long }
283
- )
284
-
285
- // Verify no create button and highlight the area where it would be
286
- cy.get('[data-cy="customers-add"]').should('not.exist')
287
-
288
- // Highlight header area
289
- cy.get('[data-cy="customers-list"]').parent().then($parent => {
290
- $parent.css({
291
- outline: '3px dashed #ef4444',
292
- outlineOffset: '4px',
293
- })
294
- })
295
- cy.pauseForEmphasis(1200)
296
-
297
- cy.get('[data-cy="customers-list"]').parent().then($parent => {
298
- $parent.css({ outline: 'none' })
299
- })
300
-
301
- cy.narrate(
302
- 'Volvamos a Everpoint Labs donde Carlos es Propietario.',
303
- { pause: CONFIG.narration.medium }
304
- )
305
-
306
- // Switch back to Everpoint
307
- teamSwitcher.open()
308
- cy.get(`[data-cy="team-option-${CONFIG.teams.EVERPOINT}"]`).click()
309
- cy.url().should('include', '/dashboard')
310
- cy.pauseForEmphasis(1000)
311
-
312
- // Navigate to customers
313
- cy.visit('/dashboard/customers')
314
- cy.get('[data-cy="customers-list"]', { timeout: 15000 }).should('exist')
315
- cy.pauseForEmphasis(500)
316
-
317
- cy.narrate(
318
- 'AquΓ­ sΓ­ aparece el botΓ³n de crear cliente. Los propietarios tienen control total.',
319
- { pause: CONFIG.narration.long }
320
- )
321
-
322
- // Highlight the create button
323
- cy.get('[data-cy="customers-add"]').should('be.visible')
324
- cy.highlightElement('[data-cy="customers-add"]')
325
-
326
- // ─────────────────────────────────────────
327
- // CHAPTER 6: ConclusiΓ³n
328
- // ─────────────────────────────────────────
329
- cy.chapter('ConclusiΓ³n')
330
-
331
- cy.narrate(
332
- 'AsΓ­ funciona el sistema de Teams: cada equipo es un espacio aislado con sus propios datos y permisos.',
333
- { pause: CONFIG.narration.long }
334
- )
335
-
336
- cy.narrate(
337
- 'Puedes colaborar en mΓΊltiples equipos con diferentes roles en cada uno.',
338
- { pause: CONFIG.narration.medium }
339
- )
340
-
341
- cy.pauseForEmphasis(500)
342
-
343
- cy.log('🎬 ═══════════════════════════════════════')
344
- cy.log('🎬 **‘Gracias por ver este tutorial!**')
345
- cy.log('🎬 ═══════════════════════════════════════')
346
-
347
- cy.pauseForEmphasis(1000)
348
- })
349
- })
@@ -1,165 +0,0 @@
1
- {
2
- "title": "Sistema de Teams - Multi-Tenancy",
3
- "description": "Tutorial que muestra cΓ³mo funciona el sistema de equipos, permitiendo tener diferentes entidades y permisos en diferentes espacios de trabajo.",
4
- "language": "es",
5
- "estimatedDuration": "3-4 minutos",
6
- "targetAudience": "Usuarios nuevos del sistema",
7
- "chapters": [
8
- {
9
- "id": "intro",
10
- "title": "IntroducciΓ³n",
11
- "narrations": [
12
- {
13
- "step": 1,
14
- "text": "Bienvenido al tutorial del Sistema de Teams. Hoy aprenderΓ‘s cΓ³mo organizar tu trabajo en diferentes espacios.",
15
- "action": "none",
16
- "estimatedSeconds": 5
17
- },
18
- {
19
- "step": 2,
20
- "text": "Carlos es un usuario con acceso a mΓΊltiples equipos. Veamos cΓ³mo funciona.",
21
- "action": "login",
22
- "estimatedSeconds": 4
23
- }
24
- ]
25
- },
26
- {
27
- "id": "team-switcher",
28
- "title": "El Selector de Equipos",
29
- "narrations": [
30
- {
31
- "step": 3,
32
- "text": "En el panel lateral izquierdo encontramos el selector de equipos. AquΓ­ vemos el equipo actual: Everpoint Labs.",
33
- "action": "highlight-switcher",
34
- "estimatedSeconds": 5
35
- },
36
- {
37
- "step": 4,
38
- "text": "Al hacer clic, se despliega una lista con todos los equipos a los que Carlos tiene acceso.",
39
- "action": "open-dropdown",
40
- "estimatedSeconds": 4
41
- },
42
- {
43
- "step": 5,
44
- "text": "Observa que cada equipo muestra el rol del usuario. Carlos es Propietario en Everpoint Labs.",
45
- "action": "highlight-role",
46
- "estimatedSeconds": 5
47
- },
48
- {
49
- "step": 6,
50
- "text": "TambiΓ©n tiene acceso a Riverstone Ventures, pero aquΓ­ es solo Miembro.",
51
- "action": "highlight-other-team",
52
- "estimatedSeconds": 4
53
- }
54
- ]
55
- },
56
- {
57
- "id": "switching-teams",
58
- "title": "Cambiar de Equipo",
59
- "narrations": [
60
- {
61
- "step": 7,
62
- "text": "Vamos a cambiar al equipo Riverstone Ventures para ver cΓ³mo cambia el contexto.",
63
- "action": "click-riverstone",
64
- "estimatedSeconds": 3
65
- },
66
- {
67
- "step": 8,
68
- "text": "Aparece un modal de transiciΓ³n mientras el sistema carga los datos del nuevo equipo.",
69
- "action": "show-modal",
70
- "estimatedSeconds": 3
71
- },
72
- {
73
- "step": 9,
74
- "text": "Perfecto. Ahora estamos en Riverstone Ventures. Observa que el nombre del equipo cambiΓ³ en el selector.",
75
- "action": "verify-switch",
76
- "estimatedSeconds": 4
77
- }
78
- ]
79
- },
80
- {
81
- "id": "different-data",
82
- "title": "Datos Separados por Equipo",
83
- "narrations": [
84
- {
85
- "step": 10,
86
- "text": "Cada equipo tiene sus propios datos. Vamos a la secciΓ³n de Clientes para comprobarlo.",
87
- "action": "navigate-customers",
88
- "estimatedSeconds": 4
89
- },
90
- {
91
- "step": 11,
92
- "text": "Estos son los clientes de Riverstone Ventures. Son completamente independientes de los de Everpoint Labs.",
93
- "action": "show-customers-list",
94
- "estimatedSeconds": 5
95
- }
96
- ]
97
- },
98
- {
99
- "id": "permissions",
100
- "title": "Permisos por Equipo",
101
- "narrations": [
102
- {
103
- "step": 12,
104
- "text": "Ahora viene lo interesante: los permisos. Como Carlos es Miembro aquΓ­, tiene acceso limitado.",
105
- "action": "highlight-permissions",
106
- "estimatedSeconds": 5
107
- },
108
- {
109
- "step": 13,
110
- "text": "Observa que NO hay botΓ³n para crear nuevos clientes. Los miembros solo pueden ver los datos.",
111
- "action": "show-no-create-button",
112
- "estimatedSeconds": 5
113
- },
114
- {
115
- "step": 14,
116
- "text": "Volvamos a Everpoint Labs donde Carlos es Propietario.",
117
- "action": "switch-back",
118
- "estimatedSeconds": 3
119
- },
120
- {
121
- "step": 15,
122
- "text": "AquΓ­ sΓ­ aparece el botΓ³n de crear cliente. Los propietarios tienen control total.",
123
- "action": "show-create-button",
124
- "estimatedSeconds": 4
125
- }
126
- ]
127
- },
128
- {
129
- "id": "conclusion",
130
- "title": "ConclusiΓ³n",
131
- "narrations": [
132
- {
133
- "step": 16,
134
- "text": "AsΓ­ funciona el sistema de Teams: cada equipo es un espacio aislado con sus propios datos y permisos.",
135
- "action": "none",
136
- "estimatedSeconds": 5
137
- },
138
- {
139
- "step": 17,
140
- "text": "Puedes colaborar en mΓΊltiples equipos con diferentes roles en cada uno. Β‘Gracias por ver este tutorial!",
141
- "action": "none",
142
- "estimatedSeconds": 5
143
- }
144
- ]
145
- }
146
- ],
147
- "totalSteps": 17,
148
- "technicalNotes": {
149
- "users": {
150
- "carlos": "carlos.mendoza@nextspark.dev",
151
- "role_everpoint": "owner",
152
- "role_riverstone": "member"
153
- },
154
- "teams": {
155
- "everpoint": "everpoint-labs",
156
- "riverstone": "riverstone-ventures"
157
- },
158
- "selectors": {
159
- "teamSwitcher": "[data-cy='team-switcher-compact']",
160
- "teamDropdown": "[data-cy='team-switcher-dropdown']",
161
- "customersAdd": "[data-cy='customers-add']",
162
- "customersList": "[data-cy='customers-list']"
163
- }
164
- }
165
- }