Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
1507 commits
Select commit Hold shift + click to select a range
ebaa8ce
Merge pull request #190 from Rythmify/M4_track
nourabosaif Apr 30, 2026
31ca159
Merge branch 'development' into M2_Profile
nourabosaif Apr 30, 2026
136313d
premium appaers
rowidAAA Apr 30, 2026
08cd2be
Merge branch 'M2_Profile' of https://github.com/Rythmify/frontend int…
rowidAAA Apr 30, 2026
bcbeff3
fixing URL of track in profile, Finished add to playlist feature in t…
Shahd-Yehya Apr 30, 2026
8da1562
Merge branch 'development' into M4_track
Shahd-Yehya Apr 30, 2026
0604216
Merge pull request #191 from Rythmify/M2_Profile
nourabosaif Apr 30, 2026
a1784fd
responsive + show seeded track in playlist + added to playlist in mor…
mariammmramy Apr 30, 2026
98fdd6c
Merge branch 'development' into M4_track
nourabosaif Apr 30, 2026
403d854
sucessfully redirect to premium
mariammmramy Apr 30, 2026
45622fa
colors in profile fixed
rowidAAA Apr 30, 2026
5910013
Merge pull request #193 from Rythmify/M4_track
nourabosaif Apr 30, 2026
ee40ea0
Merge branch 'development' into M14-Premium
nourabosaif Apr 30, 2026
64f3ca2
color fixed
rowidAAA Apr 30, 2026
1f5b8b2
Merge branch 'development' into M2_Profile
rowidAAA Apr 30, 2026
dbe33a7
validations done
rowidAAA Apr 30, 2026
4cdeb87
errors more specific in the add email section
rowidAAA Apr 30, 2026
7cdd204
correct user redirection
mariammmramy Apr 30, 2026
47c304f
added download btn in card overlay
rowidAAA Apr 30, 2026
32da997
fix url redirection in trackitem
mariammmramy Apr 30, 2026
8d399c2
show users who reposted or liked a playlist
mariammmramy Apr 30, 2026
40ed8f6
unit tests and colors fixed
rowidAAA Apr 30, 2026
6b5459f
data tests for premium
rowidAAA Apr 30, 2026
6259656
downloads unit tests
rowidAAA Apr 30, 2026
932cdca
fixing playlist component in messages, fixing seek waveform bug
Shahd-Yehya Apr 30, 2026
9098d9b
hydrate tracks to show play count
mariammmramy Apr 30, 2026
ea35dad
Merge branch 'development' into M6_Playlist_New
mariammmramy Apr 30, 2026
f49fda5
Merge branch 'development' into M4_track
Shahd-Yehya Apr 30, 2026
fb9b54b
profile unit tests
rowidAAA Apr 30, 2026
bfa36c0
settings tests
rowidAAA Apr 30, 2026
3b19209
increase gap between likes and reposts
mariammmramy Apr 30, 2026
d2d0f51
Merge pull request #192 from Rythmify/M14-Premium
nourabosaif May 1, 2026
e3323f7
- Replace offset-based pagination with page-based pagination in fetch…
farahsharshar May 1, 2026
b627ccf
Merge branch 'development' of https://github.com/Rythmify/frontend in…
farahsharshar May 1, 2026
764e990
change engagement kind to always radio tracks in more what u like
mariammmramy May 1, 2026
d169758
Merge branch 'development' of https://github.com/Rythmify/frontend in…
farahsharshar May 1, 2026
52a19f5
Merge branch 'development' into M6_Playlist_New
mariammmramy May 1, 2026
5ebf0dd
- normalize all filter arrays in SearchFilters with typeof check befo…
farahsharshar May 1, 2026
3ea368e
- remove "To listen to" license filter section entirely
farahsharshar May 1, 2026
cf6378f
* in searching without filters the results are sorted according to th…
farahsharshar May 1, 2026
8814998
*responsive search
farahsharshar May 1, 2026
58d755c
unit testing, datatest
Shahd-Yehya May 1, 2026
9780ed3
Merge branch 'development' into M4_track
Shahd-Yehya May 1, 2026
354a3ac
isnights page layout
nourabosaif May 1, 2026
b86fb12
insights most components
nourabosaif May 1, 2026
9ab100f
empty state of insights
nourabosaif May 1, 2026
4395e3c
metric pill
nourabosaif May 1, 2026
d2da604
chart
nourabosaif May 1, 2026
2fceef9
top listeners
nourabosaif May 1, 2026
3ac4805
top tracks
nourabosaif May 1, 2026
778cc4f
all platfroms
nourabosaif May 1, 2026
dfa0db5
fan state
nourabosaif May 1, 2026
5833f45
Merge branch 'development' into M2_Profile
nourabosaif May 1, 2026
5819b0f
*implemented sockets
farahsharshar May 1, 2026
751b7e1
Merge pull request #195 from Rythmify/M2_Profile
nourabosaif May 1, 2026
cd5fc07
Merge branch 'development' into M4_track
nourabosaif May 1, 2026
6a8ef87
Merge pull request #196 from Rythmify/M4_track
nourabosaif May 1, 2026
a6eee54
Merge branch 'development' into M6_Playlist_New
nourabosaif May 1, 2026
6596445
Merge pull request #197 from Rythmify/M6_Playlist_New
nourabosaif May 1, 2026
e6cf51c
Merge branch 'development' into M8_Search
nourabosaif May 1, 2026
d2ce1f2
Merge pull request #198 from Rythmify/M8_Search
nourabosaif May 1, 2026
562ae25
Merge branch 'development' into M9_Messaging_New
nourabosaif May 1, 2026
c229df2
location fixed , trying to fix is premium and weblinks
rowidAAA May 1, 2026
f25f04e
Merge branch 'M2_Profile' of https://github.com/Rythmify/frontend int…
rowidAAA May 1, 2026
9d7a151
Merge branch 'development' into M2_Profile
rowidAAA May 1, 2026
3b87137
Merge pull request #199 from Rythmify/M9_Messaging_New
nourabosaif May 1, 2026
40ee1d1
Merge branch 'development' of https://github.com/Rythmify/frontend in…
nourabosaif May 1, 2026
c94bdd8
admin dashboard unit tests
nourabosaif May 1, 2026
0ea3654
inisghts unit tests
nourabosaif May 1, 2026
e8f1fc0
artist page unit tests
nourabosaif May 1, 2026
5f6d9be
Merge branch 'development' into M10_Notifications
nourabosaif May 1, 2026
15effe5
Merge branch 'development' into M2_Profile
rowidAAA May 1, 2026
7883e19
download button added in track details page
Shahd-Yehya May 1, 2026
739dfbd
Merge branch 'development' into M4_track
Shahd-Yehya May 1, 2026
5b54b70
Merge pull request #200 from Rythmify/M10_Notifications
nourabosaif May 1, 2026
98edede
Merge branch 'development' into M12_Library
nourabosaif May 1, 2026
e81f6f3
Merge branch 'development' into M2_Profile
nourabosaif May 1, 2026
8aaee55
Merge branch 'development' of https://github.com/Rythmify/frontend in…
nourabosaif May 1, 2026
fa75aed
installing vitest ui
nourabosaif May 1, 2026
f4b0569
Merge branch 'development' into M4_track
Shahd-Yehya May 1, 2026
481a88a
Merge pull request #202 from Rythmify/M2_Profile
nourabosaif May 1, 2026
4fd80a2
Merge branch 'development' into M4_track
nourabosaif May 1, 2026
ea47e55
Merge branch 'development' of https://github.com/Rythmify/frontend in…
nourabosaif May 1, 2026
3e1a6a6
Merge pull request #203 from Rythmify/M4_track
nourabosaif May 1, 2026
9657cd1
Merge branch 'development' of https://github.com/Rythmify/frontend in…
nourabosaif May 1, 2026
5c42b09
Merge branch 'development' into M12_Library
nourabosaif May 1, 2026
dfbcf67
Merge branch 'M12_Library' of https://github.com/Rythmify/frontend in…
nourabosaif May 1, 2026
99ce3ab
go mobile done
rowidAAA May 1, 2026
ea0f2b4
ts error
nourabosaif May 1, 2026
27ca447
Merge branch 'development' into M2_Profile
rowidAAA May 1, 2026
ea8f2e8
ts error
nourabosaif May 1, 2026
c7fbbe9
Merge pull request #201 from Rythmify/M12_Library
Abasy714 May 1, 2026
88bdb88
Gamila's unit tests for discover
nourabosaif May 1, 2026
01534da
Merge branch 'development' into M12_Library
nourabosaif May 1, 2026
6faeb91
Merge branch 'development' into M2_Profile
rowidAAA May 1, 2026
4361c34
error fixing
nourabosaif May 1, 2026
e99756c
Merge branch 'M12_Library' of https://github.com/Rythmify/frontend in…
nourabosaif May 1, 2026
6e508c1
Merge pull request #205 from Rythmify/M12_Library
BisoLab May 1, 2026
b8c29dd
Merge branch 'development' into M2_Profile
nourabosaif May 1, 2026
ce36cf0
RecipientInputBox:
farahsharshar May 1, 2026
f18ee73
Merge branch 'development' of https://github.com/Rythmify/frontend in…
farahsharshar May 1, 2026
0701c04
added unit tests
mariammmramy May 1, 2026
2c8fea8
Merge branch 'M6_Playlist_New' of https://github.com/Rythmify/fronten…
mariammmramy May 1, 2026
ccf0771
share modal working
rowidAAA May 1, 2026
8cc9fd9
colors fixed
rowidAAA May 1, 2026
7f9897e
unit tests have more coverage now
mariammmramy May 1, 2026
27d5b40
Merge branch 'development' into M6_Playlist_New
mariammmramy May 1, 2026
eb88683
Merge pull request #204 from Rythmify/M2_Profile
nourabosaif May 1, 2026
eb95d0a
added playlist cover and engagement sidebar tests
mariammmramy May 1, 2026
4dcf069
playlist sidebar for you test coverage
mariammmramy May 1, 2026
10e8d24
Update coverage threshold to 95% and add end-to-end testing job with …
Abasy714 May 1, 2026
70ce176
*pagination of conversation headers not working correctly
farahsharshar May 1, 2026
398081c
Fix environment variable name for Vite production build
Abasy714 May 1, 2026
30bb737
Merge branch 'development' into pipeline
Abasy714 May 1, 2026
0dbd765
Merge pull request #207 from Rythmify/pipeline
nourabosaif May 1, 2026
075a47a
Merge branch 'development' into M6_Playlist_New
nourabosaif May 1, 2026
0f45a52
95% coverage inshallah
mariammmramy May 1, 2026
15606fd
Merge branch 'M6_Playlist_New' of https://github.com/Rythmify/fronten…
mariammmramy May 1, 2026
cb6636b
Merge pull request #206 from Rythmify/M6_Playlist_New
nourabosaif May 1, 2026
7bca902
albums/sets and station pages unit tests covered
mariammmramy May 1, 2026
4364f45
Merge branch 'development' into M6_Playlist_New
mariammmramy May 1, 2026
8baece4
*fixing bug of navigation to new conversation without having convers…
farahsharshar May 1, 2026
8d529d3
Merge branch 'development' of https://github.com/Rythmify/frontend in…
farahsharshar May 1, 2026
8852885
Merge pull request #208 from Rythmify/M6_Playlist_New
nourabosaif May 1, 2026
d634ec5
Merge branch 'development' into M9_Messaging_New
nourabosaif May 1, 2026
773305a
followers and following page fixed
rowidAAA May 1, 2026
114805e
Merge branch 'development' of https://github.com/Rythmify/frontend in…
farahsharshar May 1, 2026
e1410f5
drop down colors fixed
rowidAAA May 1, 2026
e436af5
*fixed pipeline errors and added data test attributes
farahsharshar May 1, 2026
eadf45e
Merge branch 'M9_Messaging_New' of https://github.com/Rythmify/fronte…
farahsharshar May 1, 2026
69e11e1
Merge pull request #209 from Rythmify/M9_Messaging_New
nourabosaif May 1, 2026
04dbd75
Merge branch 'development' into M2_Profile
rowidAAA May 1, 2026
6b98db5
Merge pull request #210 from Rythmify/M2_Profile
nourabosaif May 1, 2026
013f50b
x redirects to artist studio
mariammmramy May 1, 2026
437842b
95 % test coverage
mariammmramy May 1, 2026
9e81946
hydrate first seeded track to get artist usernam for URL
mariammmramy May 1, 2026
8dd9125
privacy page ready for backend
rowidAAA May 1, 2026
666d16a
Merge branch 'development' into M2_Profile
rowidAAA May 1, 2026
84537e8
error fixed
rowidAAA May 1, 2026
a25b73c
*unit testing
farahsharshar May 1, 2026
c289c36
selecting multiple tracks and adding them in one playlist feature'
nourabosaif May 1, 2026
9a48b55
Merge branch 'development' of https://github.com/Rythmify/frontend in…
nourabosaif May 1, 2026
23e5b04
add track duration of seeded in more of what u like
mariammmramy May 1, 2026
9c50027
Merge pull request #213 from Rythmify/M12_Library
BisoLab May 1, 2026
f920f9b
Merge branch 'development' into M3_UploadTrack
nourabosaif May 1, 2026
b048c4a
update track duration in album
mariammmramy May 1, 2026
f380f85
fix album like + remove old playlist card
mariammmramy May 1, 2026
7f105d2
Merge pull request #211 from Rythmify/M3_UploadTrack
nourabosaif May 1, 2026
da21dba
fix albumforyou like for cards + playlistactions
mariammmramy May 1, 2026
9904af9
*unit testing search module above 95%
farahsharshar May 1, 2026
6cd1174
refactor featured artists into separate service
mariammmramy May 1, 2026
e54183a
*notifications unit testing +changing data test attribute in all file…
farahsharshar May 1, 2026
d395e05
format track duration correctly and track count
mariammmramy May 1, 2026
b249a30
artists featured adds first artists in seeded track also
mariammmramy May 1, 2026
ab5bb51
Merge branch 'development' into M2_Profile
nourabosaif May 1, 2026
08f9071
add fallback url for broken cover images
mariammmramy May 1, 2026
b2eeab2
Merge branch 'development' into M6_Playlist_New
mariammmramy May 1, 2026
18f5df1
*unit testing
farahsharshar May 1, 2026
ef9e466
Merge pull request #212 from Rythmify/M2_Profile
nourabosaif May 1, 2026
0f8cfc1
recently played not falling to mock
nourabosaif May 1, 2026
df70494
refactoring of more of what u like page
mariammmramy May 1, 2026
164d125
Merge branch 'development' into M6_Playlist_New
nourabosaif May 1, 2026
1391205
coverting to album handling in library + refactoring the library
nourabosaif May 1, 2026
54f3c29
Merge pull request #214 from Rythmify/M6_Playlist_New
nourabosaif May 1, 2026
84e242a
*unit test messaging +artist button unfinalized
farahsharshar May 1, 2026
45622ea
*fixing search follow button to be clickable
farahsharshar May 1, 2026
d7dd7e4
blank space
nourabosaif May 1, 2026
793c1b7
insights and artist studio responsive
nourabosaif May 1, 2026
7e41a96
working links in sign in
nourabosaif May 1, 2026
3d5aa79
workaround to fix hmr error
nourabosaif May 1, 2026
092947c
track item redirect to correct username + hero goes to username
mariammmramy May 1, 2026
b452f27
Merge branch 'development' into M6_Playlist_New
mariammmramy May 1, 2026
28d7495
fix username thats not current user
mariammmramy May 1, 2026
bd5e681
*adjusted the artist button in messaging +some unit testing
farahsharshar May 1, 2026
60f6e46
Merge branch 'development' of https://github.com/Rythmify/frontend in…
farahsharshar May 1, 2026
e4e527f
not found page
nourabosaif May 1, 2026
28a09db
url error
nourabosaif May 1, 2026
150ccae
removing non working links from navbar
nourabosaif May 1, 2026
ca1e3c8
cross links ( download app )
nourabosaif May 1, 2026
10981f8
default image
nourabosaif May 1, 2026
f60cf12
default image of tracks
nourabosaif May 1, 2026
843e711
Merge branch 'development' of https://github.com/Rythmify/frontend in…
nourabosaif May 1, 2026
5a543b4
Merge pull request #217 from Rythmify/M12_Library
BisoLab May 1, 2026
0644307
Update API base URL and smoke check to use HTTPS
Abasy714 May 2, 2026
0b1bc02
Merge branch 'development' into pipeline
Abasy714 May 2, 2026
e618246
Merge pull request #218 from Rythmify/pipeline
Abasy714 May 2, 2026
04e8ce5
fix errors
mariammmramy May 2, 2026
6f59f26
Merge branch 'development' into M6_Playlist_New
nourabosaif May 2, 2026
ff75dd3
Use curl -fsS for frontend smoke check
Abasy714 May 2, 2026
954b709
Merge pull request #215 from Rythmify/M6_Playlist_New
nourabosaif May 2, 2026
f63fd91
Merge branch 'development' into M9_Messaging_New
nourabosaif May 2, 2026
bb85e0b
Merge pull request #216 from Rythmify/M9_Messaging_New
nourabosaif May 2, 2026
dfedcb6
Merge branch 'development' into pipeline
nourabosaif May 2, 2026
4b1fed7
Merge pull request #219 from Rythmify/pipeline
nourabosaif May 2, 2026
fd95e24
sidebar blank space handled
nourabosaif May 2, 2026
9208e55
renectly played local storage error
nourabosaif May 2, 2026
02c7ec3
default image in almost everything
nourabosaif May 2, 2026
de7c94e
playlist message , playlist name bug ashan khater sajaa
nourabosaif May 2, 2026
2cdd475
tracks name bug in track tab in profile ashan khater al mo3eed
nourabosaif May 2, 2026
80ba649
going to tracks page from liked tracks in sidebars
nourabosaif May 2, 2026
0ebd281
cursor stays in message box ashan khater al mo3eed bardo
nourabosaif May 2, 2026
c5781e7
*unit testing
farahsharshar May 2, 2026
fe276ee
number of followers bug fixed
rowidAAA May 2, 2026
ed5ae63
Merge branch 'M2_Profile' of https://github.com/Rythmify/frontend int…
rowidAAA May 2, 2026
68e50bf
Merge branch 'development' into M2_Profile
rowidAAA May 2, 2026
67a9457
shuffling all the songs msh 5 bas inshallah bashmonds mohamed maytl3s…
nourabosaif May 2, 2026
196932a
repost and unrepost btn in trackitem
rowidAAA May 2, 2026
f80ab4c
download btn in cardoverlay
rowidAAA May 2, 2026
7e19936
Finished PlaybackAccess, fixing comments in trackcard
Shahd-Yehya May 2, 2026
0a72864
tests done and all passed
rowidAAA May 2, 2026
0f69c75
Solving conflicts
Shahd-Yehya May 2, 2026
e230a99
MAKING DEFAULT COUNTRY EG
Shahd-Yehya May 2, 2026
2fee6f5
showing comment when passing through the waveform and then disppears
nourabosaif May 2, 2026
cdb9c8c
Merge pull request #222 from Rythmify/M4_track
Ahmedattay May 2, 2026
fe12e1f
Merge branch 'development' of https://github.com/Rythmify/frontend in…
nourabosaif May 2, 2026
00603e8
history stor error
nourabosaif May 2, 2026
c56ad65
Merge pull request #223 from Rythmify/M12_Library
Ahmedattay May 2, 2026
152013f
Merge branch 'development' into M2_Profile
nourabosaif May 2, 2026
85bf433
Merge pull request #220 from Rythmify/M2_Profile
nourabosaif May 2, 2026
0b16bfb
seek working
SajaAboulmagd05 May 2, 2026
81c57b2
Merge branch 'development' of https://github.com/Rythmify/frontend in…
farahsharshar May 2, 2026
7305ea5
mini player bar fixed
SajaAboulmagd05 May 2, 2026
a80253e
Merge branch 'development' into player-seek-bug
SajaAboulmagd05 May 2, 2026
4f7492e
fix pipeline issue
SajaAboulmagd05 May 2, 2026
6f24b22
Merge pull request #224 from Rythmify/player-seek-bug
nourabosaif May 2, 2026
cb22d5a
*fixing comment notification bug+ 3 unit test files
farahsharshar May 2, 2026
0e6c8ae
made TrackRelatedPage, made the tracks in related tracks list clickable
Shahd-Yehya May 2, 2026
e43eb89
Merge branch 'development' into M4_track
nourabosaif May 2, 2026
2c05955
Merge pull request #225 from Rythmify/M4_track
nourabosaif May 2, 2026
524e12d
*fixing pagination of conversation header
farahsharshar May 2, 2026
c33f75b
Refactor tests and update mocks for discover UI
gamila06 May 2, 2026
7ec9dfa
*fixing error in conversaionapi related to pagination
farahsharshar May 2, 2026
ce8d065
Merge pull request #226 from Rythmify/M7_Feed_v3
nourabosaif May 2, 2026
1daeea3
library test and some ui modif
nourabosaif May 2, 2026
885a516
*unit testing
farahsharshar May 2, 2026
950eae8
* messaging unit testing mn 8er modalnewmessagepage and messageidpage
farahsharshar May 2, 2026
b573253
*handling premium notification
farahsharshar May 2, 2026
63fc4ad
*fixed comment bug
farahsharshar May 2, 2026
c9703ff
* ay kalam
farahsharshar May 2, 2026
d29ac63
Merge branch 'development' of https://github.com/Rythmify/frontend in…
farahsharshar May 2, 2026
950f46b
* deleted failing file
farahsharshar May 2, 2026
41b5f85
*deleted messaging and notification handlers
farahsharshar May 2, 2026
88f8cc5
*fixed pipeline error
farahsharshar May 2, 2026
472d657
*fixing pipeline error
farahsharshar May 3, 2026
426f382
Merge pull request #228 from Rythmify/M9_Messaging_New
nourabosaif May 3, 2026
9900e1e
Merge branch 'development' of https://github.com/Rythmify/frontend in…
nourabosaif May 3, 2026
8a54d00
unit tests error
nourabosaif May 3, 2026
ae7cfbe
unit tests error
nourabosaif May 3, 2026
8061c0b
unit test error
nourabosaif May 3, 2026
cb2b963
Merge pull request #229 from Rythmify/M12_Library
BisoLab May 3, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
10 changes: 10 additions & 0 deletions .dockerignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
node_modules
.git
.gitignore
.env
.env.*
*.log
npm-debug.log*
dist
coverage
.nyc_output
Original file line number Diff line number Diff line change
@@ -0,0 +1,52 @@
name: Azure Static Web Apps CI/CD — Dir 1 (Frontend)

on:
push:
branches:
- development
pull_request:
types: [opened, synchronize, reopened, closed]
branches:
- development

jobs:
build_and_deploy_job:
runs-on: ubuntu-latest
name: Build and Deploy Job
if: github.event_name == 'push' || (github.event_name == 'pull_request' && github.event.action != 'closed')
steps:
- uses: actions/checkout@v3
with:
submodules: true
lfs: false

- name: Build And Deploy
id: builddeploy
uses: Azure/static-web-apps-deploy@v1
with:
azure_static_web_apps_api_token: ${{ secrets.AZURE_STATIC_WEB_APPS_API_TOKEN_GRAY_GRASS_0AB138600 }}
repo_token: ${{ secrets.GITHUB_TOKEN }}
action: "upload"
app_location: "/"
api_location: ""
output_location: "dist"
production_branch: "development"
env:
VITE_API_BASE_URL: ${{ secrets.VITE_API_BASE_URL }}
VITE_APP_URL: ${{ secrets.VITE_APP_URL }}
VITE_GOOGLE_CLIENT_ID: ${{ secrets.VITE_GOOGLE_CLIENT_ID }}
VITE_RECAPTCHA_SITE_KEY: ${{ secrets.VITE_RECAPTCHA_SITE_KEY }}
VITE_USE_MOCK: ${{ secrets.VITE_USE_MOCK }}

close_pull_request_job:
runs-on: ubuntu-latest
name: Close Pull Request Job
if: github.event_name == 'pull_request' && github.event.action == 'closed'
steps:
- name: Close Pull Request
id: closepullrequest
uses: Azure/static-web-apps-deploy@v1
with:
azure_static_web_apps_api_token: ${{ secrets.AZURE_STATIC_WEB_APPS_API_TOKEN_GRAY_GRASS_0AB138600 }}
action: "close"
app_location: "/"
72 changes: 72 additions & 0 deletions .github/workflows/frontend-cd-main.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,72 @@
name: Frontend CD — VM Deploy

on:
push:
branches:
- development

jobs:
build-and-deploy:
name: Build Vite App & Deploy to VM1
runs-on: ubuntu-latest

steps:
- name: Checkout repository
uses: actions/checkout@v4

- name: Set up Node.js
uses: actions/setup-node@v4
with:
node-version: "20"
cache: "npm"

- name: Install dependencies
run: npm ci

- name: Build production bundle
run: npm run build
env:
VITE_API_BASE_URL: https://rythmify-back.duckdns.org/api/v1
VITE_GOOGLE_CLIENT_ID: ${{ secrets.VITE_GOOGLE_CLIENT_ID }}
VITE_RECAPTCHA_SITE_KEY: ${{ secrets.VITE_RECAPTCHA_SITE_KEY }}

- name: Write SSH key to file
run: |
echo "${{ secrets.VM_SSH_KEY }}" > vm_key.pem
chmod 600 vm_key.pem

- name: Clear old dist on VM1
run: |
ssh -i vm_key.pem \
-o StrictHostKeyChecking=no \
${{ secrets.VM_USER }}@${{ secrets.VM_HOST }} \
"sudo rm -rf /var/www/rythmify/* && sudo mkdir -p /var/www/rythmify && sudo chown -R rythmify:rythmify /var/www/rythmify && sudo chmod -R 755 /var/www/rythmify"

- name: SCP dist to VM1
run: |
scp -i vm_key.pem \
-o StrictHostKeyChecking=no \
-r dist/* \
${{ secrets.VM_USER }}@${{ secrets.VM_HOST }}:/var/www/rythmify/

- name: Fix permissions and reload Nginx
run: |
ssh -i vm_key.pem \
-o StrictHostKeyChecking=no \
${{ secrets.VM_USER }}@${{ secrets.VM_HOST }} << 'EOF'

sudo chown -R www-data:www-data /var/www/rythmify
sudo chmod -R 755 /var/www/rythmify
sudo systemctl reload nginx

EOF

- name: Smoke check frontend
run: |
sleep 5
curl -fsS https://rythmify.duckdns.org/ -o /dev/null
echo "Frontend smoke check passed."

- name: Clean up SSH key
if: always()
run: rm -f vm_key.pem
154 changes: 154 additions & 0 deletions .github/workflows/frontend-dev.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,154 @@
name: Frontend — Dev Pipeline

on:
pull_request:
branches:
- development

jobs:
# JOB 1 — Validate repo structure
validate-structure:
name: Validate Repo Structure
runs-on: ubuntu-latest

steps:
- name: Checkout frontend repo
uses: actions/checkout@v4

- name: Check package files exist
run: |
test -f package.json || { echo "MISSING: package.json"; exit 1; }
test -f package-lock.json || { echo "MISSING: package-lock.json (use npm, not yarn)"; exit 1; }
echo "Package files present."

- name: Check TypeScript config exists
run: |
test -f tsconfig.json || { echo "MISSING: tsconfig.json"; exit 1; }
test -f tsconfig.app.json || { echo "MISSING: tsconfig.app.json"; exit 1; }
echo "TypeScript configs present."

- name: Check Vite config exists
run: |
test -f vite.config.ts || { echo "MISSING: vite.config.ts"; exit 1; }
echo "vite.config.ts present."

- name: Check ESLint config exists
run: |
test -f eslint.config.js || { echo "MISSING: eslint.config.js"; exit 1; }
echo "eslint.config.js present."

- name: Check src structure exists
run: |
test -d src || { echo "MISSING: src/"; exit 1; }
test -f src/main.tsx || { echo "MISSING: src/main.tsx"; exit 1; }
test -f src/Router.tsx || { echo "MISSING: src/Router.tsx"; exit 1; }
test -d src/components || { echo "MISSING: src/components/"; exit 1; }
test -d src/pages || { echo "MISSING: src/pages/"; exit 1; }
test -d src/services || { echo "MISSING: src/services/"; exit 1; }
test -d src/stores || { echo "MISSING: src/stores/"; exit 1; }
echo "Core src structure present."

- name: Check required Zustand stores exist
run: |
test -f src/stores/auth.store.ts || { echo "MISSING: src/stores/auth.store.ts"; exit 1; }
test -f src/stores/player.store.ts || { echo "MISSING: src/stores/player.store.ts"; exit 1; }
test -f src/stores/notification.store.ts || { echo "MISSING: src/stores/notification.store.ts"; exit 1; }
echo "Required Zustand stores present."

- name: Check Axios instance exists
run: |
test -f src/services/api/axiosInstance.ts || { echo "MISSING: src/services/api/axiosInstance.ts"; exit 1; }
echo "axiosInstance.ts present."

- name: Check route guards exist
run: |
test -f src/components/guards/PrivateRoute.tsx || { echo "MISSING: src/components/guards/PrivateRoute.tsx"; exit 1; }
test -f src/components/guards/PublicOnlyRoute.tsx || { echo "MISSING: src/components/guards/PublicOnlyRoute.tsx"; exit 1; }
echo "Route guards present."

- name: Check test setup exists
run: |
test -f src/test/setup.ts || { echo "MISSING: src/test/setup.ts — Vitest setup file required"; exit 1; }
echo "Vitest setup file present."

- name: Check no hardcoded API URLs in axiosInstance
run: |
echo "Scanning axiosInstance.ts for hardcoded production URLs..."
if grep -qE "https://api\." src/services/api/axiosInstance.ts; then
echo "WARNING: Possible hardcoded production URL found in axiosInstance.ts"
grep -nE "https://api\." src/services/api/axiosInstance.ts || true
else
echo "No hardcoded production URLs detected in axiosInstance.ts."
fi

# JOB 2 — Lint and type check
lint-and-typecheck:
name: Lint & Type Check
runs-on: ubuntu-latest
needs: validate-structure

steps:
- name: Checkout frontend repo
uses: actions/checkout@v4

- name: Set up Node.js
uses: actions/setup-node@v4
with:
node-version: "20"
cache: "npm"

- name: Install dependencies
run: npm ci

- name: Run ESLint
run: |
npm run lint || {
echo "ESLint failed — fix all lint errors before merging to dev."
exit 1
}

- name: Run TypeScript type check
run: |
npx tsc -b --noEmit || {
echo "TypeScript type check failed — fix all type errors before merging to dev."
exit 1
}

# JOB 3 — Vite build
build:
name: Vite Build
runs-on: ubuntu-latest
needs: lint-and-typecheck

steps:
- name: Checkout frontend repo
uses: actions/checkout@v4

- name: Set up Node.js
uses: actions/setup-node@v4
with:
node-version: "20"
cache: "npm"

- name: Install dependencies
run: npm ci

- name: Build with Vite
env:
VITE_API_URL: http://localhost:8080/api/v1
VITE_RECAPTCHA_SITE_KEY: ${{ secrets.VITE_RECAPTCHA_SITE_KEY }}
VITE_GOOGLE_CLIENT_ID: ${{ secrets.VITE_GOOGLE_CLIENT_ID }}
run: npm run build

- name: Confirm dist was produced
run: |
test -d dist || { echo "dist/ not found — Vite build may have silently failed."; exit 1; }
test -f dist/index.html || { echo "dist/index.html missing — build output is incomplete."; exit 1; }
echo "Vite build output confirmed."

- name: Upload build artifact
uses: actions/upload-artifact@v4
with:
name: frontend-dev-build
path: dist/
retention-days: 3
Loading
Loading