Commit graph

741 commits

Author SHA1 Message Date
senke
1ea128b60d refactor(tracks): TrackHistory module, re-export, stories, tests
- Module track-history: types, useTrackHistory, Header, Empty, ItemRow, Pagination, Skeleton, trackHistoryUtils
- Re-export from TrackHistory.tsx
- Stories: Default, Loading, Empty, Error (MSW)
- Tests: mock @/features/tracks/services/trackHistoryService, formatHistoryDate defensive, pagination/error tests fixed

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-02-06 01:34:58 +01:00
senke
3886061ec9 refactor(settings): TwoFactorSetup module, re-export, stories
- Module two-factor-setup: types, useTwoFactorSetup, Header, Step1/2/3, Skeleton
- Re-export from TwoFactorSetup.tsx
- Stories: Default, Step1, Step2, Loading (Skeleton), Error (MSW)
- Decorator: min-h-layout-page-sm

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-02-06 01:25:43 +01:00
senke
6fb8745efa refactor(views): UploadView module, re-export, stories
- Module upload-view: types, useUploadView, Stepper, Step1/2/3, Skeleton
- Layout: min-h-layout-page, max-h-96 (no arbitrary values)
- Re-export from UploadView.tsx
- Stories: Default, Loading (Skeleton), Empty, Error

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-02-06 01:12:24 +01:00
senke
648cda6bf3 refactor(playlists): AddCollaboratorModal module, re-export, stories, tests
- Module add-collaborator-modal: types, useAddCollaboratorModal, Form, Skeleton
- Re-export from AddCollaboratorModal.tsx
- Stories: Default, Loading (Skeleton), Error (MSW)
- Tests: validation/mutation via ErrorDisplay, retry, no toast assertions

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-02-06 01:04:24 +01:00
senke
cf9bc76a03 refactor(playlists): découper SharePlaylistModal en module
- Module share-playlist-modal/ : useSharePlaylistModal, Content, Skeleton
- ErrorDisplay + retry (max 3), Spinner pour chargement
- Stories : Default, Loading, Error (MSW 500)
- Tests : useCreateShareLink mock, playlistId string
- Re-export depuis SharePlaylistModal.tsx

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-02-06 00:57:48 +01:00
senke
b3b206dd2b refactor(playlists): découper CreatePlaylistDialog en module
- Module create-playlist-dialog/ : schema zod, useCreatePlaylistDialog,
  CreatePlaylistDialogForm, CreatePlaylistDialogSkeleton
- Bouton Créer avec Spinner (remplace Loader2)
- Stories : Default, Loading
- Tests : assertion createPlaylist(object), erreur avec Error
- Re-export depuis CreatePlaylistDialog.tsx

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-02-06 00:52:51 +01:00
senke
40f43a9640 refactor(playlists): découper PlaylistSearch en module
- Module playlist-search/ : usePlaylistSearch, Bar, Filters, Results, Skeleton
- Chargement avec Spinner (remplace Loader2)
- PLAYLIST_SEARCH activé en Storybook (VITE_STORYBOOK)
- MSW : GET /api/v1/playlists/search
- Stories : Default, Loading, Empty, Error
- Tests : Vitest + mock playlistsApi, useToast stable
- Re-export depuis PlaylistSearch.tsx

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-02-06 00:47:28 +01:00
senke
5f5275f6bb refactor(playlists): découper PlaylistBatchActions en module
- Module playlist-batch-actions/ : usePlaylistBatchActions, exportUtils,
  Bar, Buttons, DeleteDialog, Skeleton
- Boutons min-h-11 (remplace min-h-[44px])
- Stories : Default, SingleSelection, Loading
- Tests : mocks URL + Playlist id/user_id en string
- Re-export depuis PlaylistBatchActions.tsx

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-02-06 00:37:06 +01:00
senke
157bda45e2 refactor(playlists): découper AddTrackToPlaylistModal en module
- Module add-track-to-playlist-modal/ : useAddTrackToPlaylistModal, Search,
  List, TrackRow, Footer, Skeleton
- Liste max-h-96 (layout), Spinner pour chargement
- Stories : Default (useArgs), Loading (Skeleton)
- Re-export depuis AddTrackToPlaylistModal.tsx

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-02-06 00:22:09 +01:00
senke
d1ad2639e4 refactor(playlists): PlaylistTrackList module with hook, subcomponents, skeleton
- Add playlist-track-list/ with usePlaylistTrackList, Empty, SortableItem, Skeleton, utils
- Prop isLoading for skeleton state
- Re-export from PlaylistTrackList.tsx and PlaylistTrackListSkeleton.tsx
- Stories: Default, Loading (Skeleton), Empty, Reordering (with mock data)

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-02-06 00:14:19 +01:00
senke
01bca2fe08 refactor(notifications): NotificationMenu module with hook, subcomponents, skeleton
- Add notification-menu/ with useNotificationMenu, Trigger, Dropdown, List, Item, Skeleton
- Dropdown max-h-96 (no arbitrary max-h-[500px])
- Props notificationsOverride, isLoadingOverride, errorOverride for Storybook
- Re-export from NotificationMenu.tsx
- Stories: Default, Loading, Empty, Error, Skeleton

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-02-06 00:07:19 +01:00
senke
3232e77bcf refactor(library): LibraryManager module with hook, subcomponents, skeleton
- Add library-manager/ with useLibraryManager, Header, Toolbar, Error, Empty, Content, Stats, Skeleton
- Layout min-h-layout-page (no arbitrary h-[600px])
- Props tracksOverride, errorOverride, isLoadingOverride for Storybook
- Re-export from LibraryManager.tsx
- Stories: Default, Loading (Skeleton), Empty, Error

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-02-06 00:00:35 +01:00
senke
423b9adb8e refactor(education): CourseDetailView module with hook, subcomponents, skeleton
- Add course-detail-view/ with useCourseDetailView, Header, Tabs, Sidebar, Skeleton
- Stories: Default, Loading (Skeleton), Empty, Enrolled
- Re-export from CourseDetailView.tsx

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-02-05 23:52:24 +01:00
senke
58cd96fe2e refactor(education): CourseLearningView module with hook, subcomponents, skeleton
- Add course-learning-view/ with useCourseLearningView, Header, Player, Tabs, Sidebar, Skeleton
- Layout min-h-layout-main, no arbitrary values
- Re-export from CourseLearningView.tsx
- Stories: Default, Loading (Skeleton), Empty, Complete

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-02-05 23:45:58 +01:00
senke
ab67b3b256 refactor(marketplace): split ProductDetailView into module (Header, Gallery, Info, Licenses, Description, Reviews, Similar, Skeleton)
Co-authored-by: Cursor <cursoragent@cursor.com>
2026-02-05 23:38:09 +01:00
senke
185fe03269 refactor(streaming): split PlaybackHeatmap into module (Header, Stats, Grid, Skeleton, Error, Empty)
Co-authored-by: Cursor <cursoragent@cursor.com>
2026-02-05 23:31:06 +01:00
senke
9aa1549bc7 refactor(studio): split ProjectDetailView into module (Header, Tabs, Overview, Files, Settings, Sidebar, Skeleton)
Co-authored-by: Cursor <cursoragent@cursor.com>
2026-02-05 23:24:39 +01:00
senke
3a991d85b6 refactor(auth): split SessionsPage into module (Header, Content, Skeleton, stories)
Co-authored-by: Cursor <cursoragent@cursor.com>
2026-02-05 23:19:06 +01:00
senke
c5ffa235a2 refactor(tracks): split TrackSearchFilters into module (Basic, Advanced, Skeleton)
Co-authored-by: Cursor <cursoragent@cursor.com>
2026-02-05 23:09:36 +01:00
senke
ea7faeb703 refactor(settings): extract AccountSettings into account-settings module
- Add account-settings/ with useAccountSettings, AccountSettingsErrorBanner,
  AccountSettingsPasswordCard, AccountSettingsExportCard, AccountSettingsDeleteCard,
  AccountSettingsSkeleton
- Re-export from AccountSettings.tsx for backward compatibility
- Stories: Default, Loading (skeleton, min-h-layout-story); remove ToastProvider

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-02-05 23:04:16 +01:00
senke
a056db91fe refactor(ui): extract Dialog into dialog module
- Add dialog/ with types, Dialog, DialogHeader, DialogBody, DialogFooter,
  DialogContent, DialogDescription, DialogTitle, DialogTrigger, DialogSkeleton
- Re-export from dialog.tsx via dialog/index for backward compatibility
- Stories: Default, Alert, Composition (max-w-md), Loading (DialogSkeleton)
- Test: assert Kodo destructive classes (text-kodo-red) for alert variant

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-02-05 22:59:48 +01:00
senke
a13555f58d refactor(playlists): extract PlaylistList into playlist-list module
- Add playlist-list/ with usePlaylistList, PlaylistListToolbar, PlaylistListEmpty,
  PlaylistListError, types; keep PlaylistListSkeleton at components level
- Re-export from PlaylistList.tsx for backward compatibility
- Stories: Default, Grid, Empty (MSW), Loading (skeleton, min-h-layout-story)
- Replace min-h-[44px] with min-h-11; no arbitrary values
- Tests: assert French labels and Pagination text; fix skeleton test

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-02-05 22:54:54 +01:00
senke
048393d266 refactor(tracks): extract TrackFilters into track-filters module
- Add track-filters/ with useTrackFilters, TrackFiltersHeader, TrackFiltersSearch,
  TrackFiltersGrid, TrackFiltersClear, TrackFiltersSkeleton, types
- Re-export from TrackFilters.tsx for backward compatibility
- Stories: Default, Collapsible, Loading (skeleton)
- Layout primitive min-h-layout-story for skeleton; no arbitrary values

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-02-05 22:46:11 +01:00
senke
48ddd42182 refactor(player): extract AudioPlayer into audio-player module
- types, useAudioPlayerEffects, AudioPlayerTrackInfo, AudioPlayerControls
- AudioPlayerProgress, AudioPlayerVolume, AudioPlayerSkeleton
- Stories: Default (mock store), Skeleton
- Re-export from AudioPlayer.tsx

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-02-05 22:40:06 +01:00
senke
44eb0e142f refactor(ui): extract DataList into data-list module
- types, DataListSkeleton, DataListEmpty, DataListError, DataList
- Remove duplicate Modal/Dropdown from DataList.tsx (exist in modal.tsx/dropdown.tsx)
- Stories: Default, Loading, Empty, Error, Skeleton (min-h-layout-story)
- Re-export from DataList.tsx

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-02-05 22:35:53 +01:00
senke
db39d87955 refactor(ui): extract OptimizedImage into optimized-image module
- types, generateImageSources, BlurPlaceholder, useImageFormatSupport
- OptimizedImage, OptimizedImageSkeleton, useImagePreloader, ResponsiveImage
- Stories: Default, WithPlaceholder, ErrorState, Loading (skeleton)
- Re-export from optimized-image.tsx; tests adapted to loading state

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-02-05 22:31:35 +01:00
senke
15d31cf793 fix(ui): call onAvatarUpdated('') after successful avatar delete
Ensures parents that rely on onAvatarUpdated get the empty URL when
avatar is removed. Aligns with profile feature test contract.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-02-05 22:24:50 +01:00
senke
c4111ac059 refactor(ui): extract AvatarUpload into avatar-upload module
Co-authored-by: Cursor <cursoragent@cursor.com>
2026-02-05 22:21:02 +01:00
senke
38eab5c205 refactor(ui): extract DatePicker into date-picker module
Co-authored-by: Cursor <cursoragent@cursor.com>
2026-02-05 22:15:11 +01:00
senke
c30049e215 refactor(share): extract ShareLinkManager into share-link-manager module
Co-authored-by: Cursor <cursoragent@cursor.com>
2026-02-05 22:09:31 +01:00
senke
a74d51918c refactor(streaming): extract PlaybackDashboard into playback-dashboard module
Co-authored-by: Cursor <cursoragent@cursor.com>
2026-02-05 22:04:38 +01:00
senke
aec92086dd refactor(monitoring): extract MonitoringDashboard into monitoring-dashboard module
Co-authored-by: Cursor <cursoragent@cursor.com>
2026-02-05 21:57:39 +01:00
senke
f622fad9fc refactor(auth): extract RegisterPage into register-page module
- Add register-page/ with useRegisterPage, RegisterPageForm,
  RegisterPageVerificationNotice, RegisterPageSkeleton
- Layout primitives (min-h-layout-page-sm), tokens (success, destructive)
- Stories: Default, Loading, WithError; re-export from pages/RegisterPage

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-02-05 21:50:17 +01:00
senke
bc7eabdbbe refactor(views): extract FileManagerView into file-manager-view module
- Add file-manager-view/ with useFileManagerView, Header, Toolbar, Table, Grid,
  Empty, Skeleton; types and mockFiles
- Layout primitives (min-h-layout-page-sm), no arbitrary values
- Stories: Default, Loading, Empty
- Re-export from FileManagerView.tsx

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-02-05 21:45:01 +01:00
senke
6f0677fc88 refactor(search): extract SearchPage into feature module
- Add features/search/components/search-page/ with useSearchPage, Header,
  Discovery, Empty, Error, Results, Skeleton
- Layout primitives only (min-h-layout-page, max-w-6xl)
- Stories: Default, Loading, Empty, Error; MSW handler for SearchResults shape

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-02-05 21:39:31 +01:00
senke
796745f57f fix(views): use layout primitive in NotificationsView loading state
Replace arbitrary h-[50vh] with min-h-layout-page-sm per .cursorrules

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-02-05 21:32:33 +01:00
senke
85abc9900f refactor(notifications): extract NotificationsPage into feature module
- Add features/notifications/components/notifications-page/ with:
  - useNotificationsPage (query + mark read / mark all read mutations)
  - NotificationsPageHeader, NotificationsPageFilters, NotificationsPageItem
  - NotificationsPageEmpty, NotificationsPageError, NotificationsPageSkeleton
  - types (FilterType, NotificationTypeFilter, NOTIFICATION_TYPE_LABELS)
- Page re-exports from module; stories moved to component (Default, Loading, Error, Empty)
- MSW handler: notifications response shape aligned with notificationService (data.notifications)

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-02-05 21:32:19 +01:00
senke
9dde2eec55 chore(studio): remove legacy CloudFileBrowser from components/studio
CloudFileBrowser lives in features/studio/components/cloud-file-browser/.
StudioView already imports from there.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-02-05 21:20:36 +01:00
senke
b20c9f4c6f test(ui): add Select stories (Default, Empty, Disabled, Grouped, MultiSelect), fix tests for listbox/option
Co-authored-by: Cursor <cursoragent@cursor.com>
2026-02-05 21:16:30 +01:00
senke
bf50ee4588 refactor(ui): decompose Select into select module
- Add select/ with useSelect, types, SelectTrigger, SelectDropdownContent,
  SelectOptionItem; min-w-48 max-h-72 (no arbitrary values)
- Remove monolithic select.tsx; entry point is select/index.ts
- Backward compatible: imports from './select' resolve to module

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-02-05 21:16:19 +01:00
senke
53a97148e3 test(ui): add FileUpload stories (Default, Empty, Error, Disabled, etc.)
Co-authored-by: Cursor <cursoragent@cursor.com>
2026-02-05 21:09:21 +01:00
senke
0eda9232df refactor(ui): decompose FileUpload into file-upload module
- Add file-upload/ with useFileUpload, types, utils, and presentational
  components: FileUploadDropzone, FileUploadErrorList, FileUploadFileList
- Remove monolithic file-upload.tsx; entry point is file-upload/index.ts
- Backward compatible: imports from './file-upload' resolve to module

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-02-05 21:09:08 +01:00
senke
f00c621bb4 test(upload): add UploadModal stories (Default, Open)
Co-authored-by: Cursor <cursoragent@cursor.com>
2026-02-05 21:03:15 +01:00
senke
eadc2b7c65 refactor(upload): decompose UploadModal into upload-modal module
- Add upload-modal/ with useUploadModal, constants, and presentational
  components: Dropzone, FileDisplay, Progress, ErrorAlert, MetadataForm
- Re-export from UploadModal.tsx for backward compatibility

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-02-05 21:03:07 +01:00
senke
1f2e59af8d test(ui): add LazyErrorFallback and LazyComponent stories; fix LazyComponent tests for fallback text
Co-authored-by: Cursor <cursoragent@cursor.com>
2026-02-05 20:49:17 +01:00
senke
df6c9c3d2b refactor(ui): decompose LazyComponent into lazy-component module with LazyErrorFallback, LazyErrorBoundary, createLazyComponent
Co-authored-by: Cursor <cursoragent@cursor.com>
2026-02-05 20:48:36 +01:00
senke
cc6b77aff4 test(views): add GearView stories Default, Loading, Empty, Error and GearViewSkeleton
Co-authored-by: Cursor <cursoragent@cursor.com>
2026-02-05 20:38:59 +01:00
senke
260a787da6 refactor(views): decompose GearView into gear-view module with useGearView and sub-components
Co-authored-by: Cursor <cursoragent@cursor.com>
2026-02-05 20:38:45 +01:00
senke
d1044b22d4 test(views): add ProfileView stories Default, Loading, Error and ProfileViewSkeleton
Co-authored-by: Cursor <cursoragent@cursor.com>
2026-02-05 20:30:50 +01:00
senke
5485415113 refactor(views): decompose ProfileView into profile-view module with hook and sub-components
Co-authored-by: Cursor <cursoragent@cursor.com>
2026-02-05 20:30:36 +01:00