Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
275 commits
Select commit Hold shift + click to select a range
1c8a084
Very initial modjam work
Villagers654 Feb 20, 2026
4b516e9
Unify styling
Villagers654 Feb 20, 2026
10a382b
Jam creation flow
Villagers654 Feb 20, 2026
fb29083
Jam submission flow
Villagers654 Feb 20, 2026
f49faeb
Remove APP_
Villagers654 Feb 20, 2026
dcfde13
Don't use projectlayout
Villagers654 Feb 20, 2026
ad39ee2
Jam calendar
Villagers654 Feb 20, 2026
30bca15
Proper navbar widths
Villagers654 Feb 20, 2026
ab10d69
Fix jam publishing
Villagers654 Feb 20, 2026
8e67c46
More fixes for publishing
Villagers654 Feb 20, 2026
d37281e
Mild restyle and some more fixes
Villagers654 Feb 20, 2026
cddc607
It just doesn't feel right...
Villagers654 Feb 20, 2026
c845d85
More of a unique identity again + ui bug fixes
Villagers654 Feb 20, 2026
6b08514
Make it more clear as you make progress towards jam publishing
Villagers654 Feb 20, 2026
e03904a
Fix 401
Villagers654 Feb 20, 2026
bd1cef6
Getting annoyed
Villagers654 Feb 20, 2026
88d6f69
Found the actual issue
Villagers654 Feb 20, 2026
eb17f86
Styling changes + new card component
Villagers654 Feb 20, 2026
c409ffd
Make jam elements more visually distinct from project counterparts
Villagers654 Feb 20, 2026
9ea4554
Make jam card a little closer to the jam page in terms of layout
Villagers654 Feb 20, 2026
ad7e2e7
Various bug fixes
Villagers654 Feb 20, 2026
7c42604
Fix compile
Villagers654 Feb 20, 2026
73f5505
Jam editing and deletion
Villagers654 Feb 21, 2026
da90b43
Refine editing and deleting
Villagers654 Feb 21, 2026
6b6c480
Managing jams in the dashboard
Villagers654 Feb 21, 2026
6d672fa
Merge remote-tracking branch 'origin/modjam' into modjam
Villagers654 Feb 21, 2026
a2c88cb
Very initial modjam work
Villagers654 Feb 20, 2026
1ff575d
Unify styling
Villagers654 Feb 20, 2026
e95d526
Jam creation flow
Villagers654 Feb 20, 2026
fb30ebc
Jam submission flow
Villagers654 Feb 20, 2026
8f726ed
Remove APP_
Villagers654 Feb 20, 2026
fd4a96c
Don't use projectlayout
Villagers654 Feb 20, 2026
e280d05
Jam calendar
Villagers654 Feb 20, 2026
1822110
Proper navbar widths
Villagers654 Feb 20, 2026
f423a1b
Fix jam publishing
Villagers654 Feb 20, 2026
03553d2
More fixes for publishing
Villagers654 Feb 20, 2026
d67887c
Mild restyle and some more fixes
Villagers654 Feb 20, 2026
8db61d6
It just doesn't feel right...
Villagers654 Feb 20, 2026
a5622c1
More of a unique identity again + ui bug fixes
Villagers654 Feb 20, 2026
400c841
Make it more clear as you make progress towards jam publishing
Villagers654 Feb 20, 2026
e7baf1a
Fix 401
Villagers654 Feb 20, 2026
cdac428
Getting annoyed
Villagers654 Feb 20, 2026
f660656
Found the actual issue
Villagers654 Feb 20, 2026
c344a37
Styling changes + new card component
Villagers654 Feb 20, 2026
a0cc8ef
Make jam elements more visually distinct from project counterparts
Villagers654 Feb 20, 2026
4e5445e
Make jam card a little closer to the jam page in terms of layout
Villagers654 Feb 20, 2026
c61476a
Various bug fixes
Villagers654 Feb 20, 2026
5a5b84b
Fix compile
Villagers654 Feb 20, 2026
7546186
Jam editing and deletion
Villagers654 Feb 21, 2026
55110bf
Refine editing and deleting
Villagers654 Feb 21, 2026
9df3a0f
Managing jams in the dashboard
Villagers654 Feb 21, 2026
d4fb2ff
Very initial modjam work
Villagers654 Feb 20, 2026
3e3d283
Unify styling
Villagers654 Feb 20, 2026
748b013
Jam creation flow
Villagers654 Feb 20, 2026
d77de07
Don't use projectlayout
Villagers654 Feb 20, 2026
d54c71a
Jam calendar
Villagers654 Feb 20, 2026
75da6cf
Proper navbar widths
Villagers654 Feb 20, 2026
a5c316d
Fix jam publishing
Villagers654 Feb 20, 2026
ff088c2
More fixes for publishing
Villagers654 Feb 20, 2026
6eb4eeb
Mild restyle and some more fixes
Villagers654 Feb 20, 2026
d95e94f
It just doesn't feel right...
Villagers654 Feb 20, 2026
8687cab
More of a unique identity again + ui bug fixes
Villagers654 Feb 20, 2026
7dd62eb
Make it more clear as you make progress towards jam publishing
Villagers654 Feb 20, 2026
e5d5747
Fix 401
Villagers654 Feb 20, 2026
79390a2
Getting annoyed
Villagers654 Feb 20, 2026
b6cdd55
Found the actual issue
Villagers654 Feb 20, 2026
3bc724c
Styling changes + new card component
Villagers654 Feb 20, 2026
81224ec
Make jam elements more visually distinct from project counterparts
Villagers654 Feb 20, 2026
6670ac3
Make jam card a little closer to the jam page in terms of layout
Villagers654 Feb 20, 2026
abc12d6
Various bug fixes
Villagers654 Feb 20, 2026
c5eb9b7
Fix compile
Villagers654 Feb 20, 2026
b8d9842
Jam editing and deletion
Villagers654 Feb 21, 2026
c7fee4e
Refine editing and deleting
Villagers654 Feb 21, 2026
008967b
Managing jams in the dashboard
Villagers654 Feb 21, 2026
35aa64d
Merge remote-tracking branch 'origin/modjam' into modjam
Villagers654 Feb 21, 2026
469ec91
Very initial modjam work
Villagers654 Feb 20, 2026
92e26ff
Unify styling
Villagers654 Feb 20, 2026
e9937be
Jam creation flow
Villagers654 Feb 20, 2026
2aa8d7a
Jam submission flow
Villagers654 Feb 20, 2026
0a52a7b
Remove APP_
Villagers654 Feb 20, 2026
f333828
Don't use projectlayout
Villagers654 Feb 20, 2026
cf8e725
Jam calendar
Villagers654 Feb 20, 2026
9f45472
Proper navbar widths
Villagers654 Feb 20, 2026
3e300e7
Fix jam publishing
Villagers654 Feb 20, 2026
50f5199
More fixes for publishing
Villagers654 Feb 20, 2026
e1903ef
Mild restyle and some more fixes
Villagers654 Feb 20, 2026
e6a01b8
It just doesn't feel right...
Villagers654 Feb 20, 2026
7580c83
More of a unique identity again + ui bug fixes
Villagers654 Feb 20, 2026
0070cf6
Make it more clear as you make progress towards jam publishing
Villagers654 Feb 20, 2026
496fe49
Fix 401
Villagers654 Feb 20, 2026
11b885f
Getting annoyed
Villagers654 Feb 20, 2026
ccda427
Found the actual issue
Villagers654 Feb 20, 2026
23a2e0b
Styling changes + new card component
Villagers654 Feb 20, 2026
efef5e7
Make jam elements more visually distinct from project counterparts
Villagers654 Feb 20, 2026
fe43eac
Make jam card a little closer to the jam page in terms of layout
Villagers654 Feb 20, 2026
c198791
Various bug fixes
Villagers654 Feb 20, 2026
c64fc26
Fix compile
Villagers654 Feb 20, 2026
33700d6
Jam editing and deletion
Villagers654 Feb 21, 2026
ee8b09f
Refine editing and deleting
Villagers654 Feb 21, 2026
5664ecf
Managing jams in the dashboard
Villagers654 Feb 21, 2026
0e6e4df
Very initial modjam work
Villagers654 Feb 20, 2026
9f96667
Unify styling
Villagers654 Feb 20, 2026
4f13253
Jam creation flow
Villagers654 Feb 20, 2026
ef026c4
Don't use projectlayout
Villagers654 Feb 20, 2026
6f0115a
Jam calendar
Villagers654 Feb 20, 2026
120b7cf
Proper navbar widths
Villagers654 Feb 20, 2026
5303117
Fix jam publishing
Villagers654 Feb 20, 2026
e10a2c8
More fixes for publishing
Villagers654 Feb 20, 2026
4a52edd
Mild restyle and some more fixes
Villagers654 Feb 20, 2026
77e7461
It just doesn't feel right...
Villagers654 Feb 20, 2026
296d09e
More of a unique identity again + ui bug fixes
Villagers654 Feb 20, 2026
02b3125
Make it more clear as you make progress towards jam publishing
Villagers654 Feb 20, 2026
1fe9d73
Fix 401
Villagers654 Feb 20, 2026
c5678d1
Getting annoyed
Villagers654 Feb 20, 2026
2f152a3
Found the actual issue
Villagers654 Feb 20, 2026
3d7b975
Styling changes + new card component
Villagers654 Feb 20, 2026
ced3932
Make jam elements more visually distinct from project counterparts
Villagers654 Feb 20, 2026
d428908
Make jam card a little closer to the jam page in terms of layout
Villagers654 Feb 20, 2026
976494c
Various bug fixes
Villagers654 Feb 20, 2026
64a1f7b
Fix compile
Villagers654 Feb 20, 2026
0f9a492
Jam editing and deletion
Villagers654 Feb 21, 2026
5ae901a
Refine editing and deleting
Villagers654 Feb 21, 2026
e2343a7
Managing jams in the dashboard
Villagers654 Feb 21, 2026
384ff1d
Very initial modjam work
Villagers654 Feb 20, 2026
fae2d3f
Unify styling
Villagers654 Feb 20, 2026
6b95bb8
Jam creation flow
Villagers654 Feb 20, 2026
37200de
Don't use projectlayout
Villagers654 Feb 20, 2026
872ebc4
Jam calendar
Villagers654 Feb 20, 2026
05156e1
Proper navbar widths
Villagers654 Feb 20, 2026
cd84642
Fix jam publishing
Villagers654 Feb 20, 2026
45e8037
More fixes for publishing
Villagers654 Feb 20, 2026
ff269c2
Mild restyle and some more fixes
Villagers654 Feb 20, 2026
ca58ac0
It just doesn't feel right...
Villagers654 Feb 20, 2026
7e39afc
More of a unique identity again + ui bug fixes
Villagers654 Feb 20, 2026
f69eb00
Make it more clear as you make progress towards jam publishing
Villagers654 Feb 20, 2026
5583a78
Fix 401
Villagers654 Feb 20, 2026
5a693f0
Getting annoyed
Villagers654 Feb 20, 2026
45f99e0
Found the actual issue
Villagers654 Feb 20, 2026
626007f
Styling changes + new card component
Villagers654 Feb 20, 2026
79e8fbb
Make jam elements more visually distinct from project counterparts
Villagers654 Feb 20, 2026
016ba0e
Make jam card a little closer to the jam page in terms of layout
Villagers654 Feb 20, 2026
3fc10cd
Various bug fixes
Villagers654 Feb 20, 2026
60a0c28
Fix compile
Villagers654 Feb 20, 2026
3b146a9
Jam editing and deletion
Villagers654 Feb 21, 2026
f05bcab
Refine editing and deleting
Villagers654 Feb 21, 2026
412315b
Managing jams in the dashboard
Villagers654 Feb 21, 2026
051397f
Very initial modjam work
Villagers654 Feb 20, 2026
2a64a27
Unify styling
Villagers654 Feb 20, 2026
88cdd92
Jam creation flow
Villagers654 Feb 20, 2026
d596f5c
Don't use projectlayout
Villagers654 Feb 20, 2026
2ba714e
Jam calendar
Villagers654 Feb 20, 2026
c595d1d
Proper navbar widths
Villagers654 Feb 20, 2026
e991915
Fix jam publishing
Villagers654 Feb 20, 2026
b5e1e7a
More fixes for publishing
Villagers654 Feb 20, 2026
c7ec4a6
Mild restyle and some more fixes
Villagers654 Feb 20, 2026
f8b3438
It just doesn't feel right...
Villagers654 Feb 20, 2026
0423fa3
More of a unique identity again + ui bug fixes
Villagers654 Feb 20, 2026
a210f17
Make it more clear as you make progress towards jam publishing
Villagers654 Feb 20, 2026
ad98d9f
Fix 401
Villagers654 Feb 20, 2026
e304e16
Getting annoyed
Villagers654 Feb 20, 2026
76c72bb
Found the actual issue
Villagers654 Feb 20, 2026
0ccefd7
Styling changes + new card component
Villagers654 Feb 20, 2026
f999975
Make jam elements more visually distinct from project counterparts
Villagers654 Feb 20, 2026
eebe7f7
Make jam card a little closer to the jam page in terms of layout
Villagers654 Feb 20, 2026
d8a92ff
Various bug fixes
Villagers654 Feb 20, 2026
d5df479
Fix compile
Villagers654 Feb 20, 2026
fb4a178
Jam editing and deletion
Villagers654 Feb 21, 2026
bfa7991
Refine editing and deleting
Villagers654 Feb 21, 2026
1cc81bb
Managing jams in the dashboard
Villagers654 Feb 21, 2026
82ab591
Merge remote-tracking branch 'origin/modjam' into modjam
Villagers654 Feb 21, 2026
06b6592
Implement jam submissions
Villagers654 Feb 21, 2026
8f95908
Use the right endpoint
Villagers654 Feb 21, 2026
d559f84
More configurability on how voting works
Villagers654 Feb 21, 2026
0cc234a
Better styling for jam submissions card
Villagers654 Feb 21, 2026
b2050f5
Fix NPE
Villagers654 Feb 21, 2026
0785be9
Show votes before the submissions end by default
Villagers654 Feb 21, 2026
38eec9d
Make the way the current votes are presented more minimal
Villagers654 Feb 21, 2026
58fcfbd
Add banners back to the cards
Villagers654 Feb 21, 2026
3698f20
Implement countdown
Villagers654 Feb 21, 2026
2ea0b77
Calendar-based jam list
Villagers654 Feb 21, 2026
469d93d
Minor styling adjustment
Villagers654 Feb 21, 2026
cf1a965
Bring calendar more in line with modtale styling
Villagers654 Feb 21, 2026
1a70712
Make the banner less dominating
Villagers654 Feb 21, 2026
a7ac598
Fix uploading banners/icons
Villagers654 Feb 23, 2026
5ba0973
All-new jam UI
Villagers654 Feb 23, 2026
90d5ef7
Neil made fun of my UI so I changed it
Villagers654 Feb 23, 2026
0e80f22
Markdown support
Villagers654 Feb 23, 2026
e5f3f03
Make sure outdated data is not being served
Villagers654 Feb 23, 2026
8d77985
Some enhancements to make sure everything is being fetched correctly
Villagers654 Feb 23, 2026
3f9eedc
More minor adjustments
Villagers654 Feb 23, 2026
afe091d
I don't like rockets or sparkles
Villagers654 Feb 23, 2026
de39aad
Optimistically handle votes
Villagers654 Feb 23, 2026
acc9d1c
Do jam publish requirements like project publish requirements
Villagers654 Feb 23, 2026
63a0bdb
Refactor
Villagers654 Feb 23, 2026
89c6f8c
Be consistent
Villagers654 Feb 23, 2026
8826ff5
Merge branch 'develop' into modjam
Villagers654 Feb 23, 2026
5d95771
Merge branch 'develop' into modjam
Villagers654 Feb 24, 2026
cd222ce
Fix og embedding
Villagers654 Feb 24, 2026
26a3a69
Show if a project was a participant/winner of a jam
Villagers654 Feb 24, 2026
9f8cb20
Fix prev. commit
Villagers654 Feb 24, 2026
44981ee
Grab the pretty names and slugs
Villagers654 Feb 24, 2026
3af9a81
Use the jam icon if it has one
Villagers654 Feb 24, 2026
33861ff
Better jam display
Villagers654 Feb 24, 2026
bf14156
Allow configuring which of the jams the project was submitted to are …
Villagers654 Feb 24, 2026
0185db8
Fix resolving icon url
Villagers654 Feb 24, 2026
2748d1b
Properly implement closing the vote
Villagers654 Feb 24, 2026
a1c0885
Implement winners
Villagers654 Feb 24, 2026
fb91f5b
Fix up the 'submission to' container
Villagers654 Feb 25, 2026
8144e64
Make everything a Link
Villagers654 Feb 25, 2026
ce1be1e
Fix overview being half width
Villagers654 Feb 25, 2026
ab38546
Make the 'jams' button on the navbar glow for any jam related url
Villagers654 Feb 25, 2026
2dff41e
Make the participants text a little bigger
Villagers654 Feb 25, 2026
cacfad3
Updated jam cards
Villagers654 Feb 25, 2026
6b2dc16
Fix some errors
Villagers654 Feb 25, 2026
d19c62d
Submission type restrictions
Villagers654 Feb 25, 2026
133473b
Use /edit for the jam builder
Villagers654 Feb 25, 2026
43b70a2
Rules generator & more submission restrictions
Villagers654 Feb 25, 2026
991408f
Implement jams into the dashboard properly
Villagers654 Feb 25, 2026
28690a5
Allow setting jam start and end times by time rather than just by date
Villagers654 Feb 25, 2026
707d184
Allow setting jam times by minute rather than just date
Villagers654 Feb 26, 2026
d8e52e8
More restrictions based on level of experience
Villagers654 Feb 26, 2026
91e6777
Only show a jam in 'past events' once it drops off the calendar
Villagers654 Feb 26, 2026
df47f52
Fix UI bug with the tab selector
Villagers654 Feb 26, 2026
2efee50
Judging system preliminary
Villagers654 Feb 27, 2026
11b085e
Merge branch 'refs/heads/develop' into modjam
Villagers654 Feb 27, 2026
74ffbcf
Ability to hide all projects until voting starts, and submit a projec…
Villagers654 Feb 27, 2026
ea5de62
Improved error handling & communication
Villagers654 Feb 27, 2026
9c84270
Fix crash
Villagers654 Feb 27, 2026
512e165
Don't show private projects
Villagers654 Feb 27, 2026
ee6d431
Make it clear to users when a jam is on secret mode
Villagers654 Feb 27, 2026
a4cabc3
Show participants instead of entries
Villagers654 Feb 27, 2026
dc3a1c5
Custom slugs
Villagers654 Feb 27, 2026
6f164ea
Add jams to the sitemap
Villagers654 Feb 27, 2026
4823555
Fix inaccurate jam end date
Villagers654 Mar 3, 2026
85b39a0
Merge branch 'develop' into modjam
Villagers654 Apr 25, 2026
9462fa2
Fix merge compilation issues
Villagers654 Apr 25, 2026
0b9f55c
Merge develop into modjam and migrate modjam to module-based structure
Villagers654 May 23, 2026
0675f1c
Fix compile
Villagers654 May 23, 2026
948f5c2
Restructure JamList
Villagers654 May 23, 2026
f39c934
Total modjam pages restyle
Villagers654 May 23, 2026
91f7af4
Add unsaved changes indicator to jambuilder
Villagers654 May 23, 2026
ed45795
When seeding, seed all the dependencies as well
Villagers654 May 23, 2026
20b0254
Merge branch 'develop' into modjam
Villagers654 May 23, 2026
0666be2
Merge branch 'develop' into modjam
Villagers654 May 23, 2026
d8e5d10
Merge branch 'develop' into modjam
Villagers654 May 23, 2026
060532b
Render jamlayout more efficiently
Villagers654 May 23, 2026
4f922c5
Don't constantly resize the gallery
Villagers654 May 23, 2026
6b13c07
Merge develop into modjam
Villagers654 Jun 11, 2026
b22b681
Merge branch 'develop' into modjam
Villagers654 Jun 21, 2026
02633cb
Merge branch 'develop' into modjam
Villagers654 Jun 21, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
18 changes: 9 additions & 9 deletions .github/workflows/ci-cd.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: Modtale CI/CD
name: Modtale CI/CD

on:
push:
Expand Down Expand Up @@ -51,7 +51,7 @@ jobs:
fi
echo "GIT_BRANCH_NAME=$BRANCH_NAME" >> $GITHUB_ENV
echo "BRANCH_SLUG=$BRANCH_SLUG" >> $GITHUB_ENV

if [ "$BRANCH_NAME" = "main" ]; then
echo "ENV_TYPE=prod" >> $GITHUB_ENV
echo "BUILD_SERVICE_ACCOUNT=${{ vars.GCP_BUILD_SERVICE_ACCOUNT }}" >> $GITHUB_ENV
Expand All @@ -76,7 +76,7 @@ jobs:
echo "WARDEN_ENABLED=true" >> $GITHUB_ENV
echo "OAUTH_ENABLED=true" >> $GITHUB_ENV
echo "WARDEN_SECRET_NAME=WARDEN_API_KEY" >> $GITHUB_ENV

elif [ "$BRANCH_NAME" = "develop" ]; then
echo "ENV_TYPE=dev" >> $GITHUB_ENV
echo "BUILD_SERVICE_ACCOUNT=${{ vars.GCP_BUILD_SERVICE_ACCOUNT }}" >> $GITHUB_ENV
Expand All @@ -101,7 +101,7 @@ jobs:
echo "WARDEN_ENABLED=true" >> $GITHUB_ENV
echo "OAUTH_ENABLED=true" >> $GITHUB_ENV
echo "WARDEN_SECRET_NAME=WARDEN_API_KEY" >> $GITHUB_ENV

else
SLUG="$BRANCH_SLUG"
BRANCH_PREVIEW_SOURCE_R2_BUCKET_NAME="${{ vars.GCP_BRANCH_PREVIEW_SOURCE_R2_BUCKET_NAME }}"
Expand Down Expand Up @@ -417,7 +417,7 @@ jobs:
--config=cloudbuild.yml \
--service-account="projects/$PROJECT_ID/serviceAccounts/$BUILD_SERVICE_ACCOUNT" \
--substitutions=_TAG=${{ env.TAG }} .

ARGS=(
"--image" "gcr.io/$PROJECT_ID/modtale-backend:${{ env.TAG }}"
"--region" "$REGION"
Expand Down Expand Up @@ -602,7 +602,7 @@ jobs:
else
PUBLIC_BACKEND_URL=$B_URL
fi

gcloud run services update ${{ env.BACKEND_SERVICE }} \
--region $REGION \
--update-env-vars "FRONTEND_URL=$FINAL_FRONTEND_URL,BACKEND_URL=$PUBLIC_BACKEND_URL"
Expand Down Expand Up @@ -674,21 +674,21 @@ jobs:
echo "" >> $GITHUB_STEP_SUMMARY
echo "| Component | Status | Target Service | Service URL |" >> $GITHUB_STEP_SUMMARY
echo "|---|---|---|---|" >> $GITHUB_STEP_SUMMARY

if [ -n "$PUBLIC_API_URL" ]; then
echo "| **Backend API** | $BACKEND_STATUS | \`${{ env.BACKEND_SERVICE }}\` | [API Endpoint]($PUBLIC_API_URL) |" >> $GITHUB_STEP_SUMMARY
elif [ -n "$B_URL" ]; then
echo "| **Backend API** | $BACKEND_STATUS | \`${{ env.BACKEND_SERVICE }}\` | [API Endpoint]($B_URL/api/v1) |" >> $GITHUB_STEP_SUMMARY
else
echo "| **Backend API** | $BACKEND_STATUS | \`${{ env.BACKEND_SERVICE }}\` | *N/A* |" >> $GITHUB_STEP_SUMMARY
fi

if [ -n "$F_URL" ]; then
echo "| **Frontend App** | $FRONTEND_STATUS | \`${{ env.FRONTEND_SERVICE }}\` | [App URL]($F_URL) |" >> $GITHUB_STEP_SUMMARY
else
echo "| **Frontend App** | $FRONTEND_STATUS | \`${{ env.FRONTEND_SERVICE }}\` | *N/A* |" >> $GITHUB_STEP_SUMMARY
fi

echo "" >> $GITHUB_STEP_SUMMARY
echo "---" >> $GITHUB_STEP_SUMMARY
echo "*View deployment details in [Google Cloud Console](https://console.cloud.google.com/run?project=${{ env.PROJECT_ID }}).* " >> $GITHUB_STEP_SUMMARY
Expand Down
1 change: 1 addition & 0 deletions backend/src/main/java/net/modtale/ModtaleApplication.java
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@

@SpringBootApplication
@ConfigurationPropertiesScan
@EnableCaching
@EnableMethodSecurity
public class ModtaleApplication {
public static void main(String[] args) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -289,7 +289,10 @@ public SecurityFilterChain securityFilterChain(HttpSecurity http) throws Excepti
.requestMatchers("/sitemap.xml", "/actuator/health", "/actuator/health/**").permitAll()
.requestMatchers("/client-metadata.json").permitAll()
.requestMatchers(HttpMethod.GET,
"/api/v1/projects",
"/api/v1/projects/**",
"/api/v1/modjams",
"/api/v1/modjams/**",
"/api/v1/tags",
"/api/v1/files/**",
"/api/v1/user/profile/**",
Expand Down Expand Up @@ -361,9 +364,10 @@ public SecurityFilterChain securityFilterChain(HttpSecurity http) throws Excepti
"/api/v1/auth/change-password",
"/api/v1/auth/credentials"
).authenticated()
.requestMatchers(HttpMethod.POST, "/api/v1/projects/**").authenticated()
.requestMatchers(HttpMethod.PUT, "/api/v1/projects/**").authenticated()
.requestMatchers(HttpMethod.DELETE, "/api/v1/projects/**").authenticated()
.requestMatchers(HttpMethod.POST, "/api/v1/projects", "/api/v1/projects/**", "/api/v1/modjams", "/api/v1/modjams/**").authenticated()
.requestMatchers(HttpMethod.PUT, "/api/v1/projects", "/api/v1/projects/**", "/api/v1/modjams", "/api/v1/modjams/**").authenticated()
.requestMatchers(HttpMethod.DELETE, "/api/v1/projects", "/api/v1/projects/**", "/api/v1/modjams", "/api/v1/modjams/**").authenticated()
.requestMatchers(HttpMethod.PATCH, "/api/v1/modjams", "/api/v1/modjams/**").authenticated()
.requestMatchers("/api/**").authenticated()
.anyRequest().permitAll()
)
Expand Down
166 changes: 166 additions & 0 deletions backend/src/main/java/net/modtale/controller/ModjamController.java
Original file line number Diff line number Diff line change
@@ -0,0 +1,166 @@
package net.modtale.controller;

import net.modtale.model.jam.Modjam;
import net.modtale.model.jam.ModjamSubmission;
import net.modtale.model.user.User;
import net.modtale.service.ModjamService;
import net.modtale.service.user.account.AccountService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.http.ResponseEntity;
import org.springframework.web.bind.annotation.*;
import org.springframework.web.multipart.MultipartFile;
import org.springframework.web.server.ResponseStatusException;

import java.util.List;
import java.util.Map;

@RestController
@RequestMapping("/api/v1/modjams")
public class ModjamController {

@Autowired private ModjamService modjamService;
@Autowired private AccountService accountService;

@GetMapping
public ResponseEntity<List<Modjam>> getAllJams() {
return ResponseEntity.ok(modjamService.getAllJams());
}

@GetMapping("/user/me")
public ResponseEntity<List<Modjam>> getMyJams() {
User user = accountService.getCurrentUser();
if (user == null) return ResponseEntity.status(401).build();
return ResponseEntity.ok(modjamService.getUserHostedJams(user.getId()));
}

@GetMapping("/{slug}")
public ResponseEntity<Modjam> getJamBySlug(@PathVariable String slug) {
return ResponseEntity.ok(modjamService.getJamBySlug(slug));
}

@PostMapping
public ResponseEntity<Modjam> createJam(@RequestBody Modjam jam) {
User user = accountService.getCurrentUser();
if (user == null) return ResponseEntity.status(401).build();
return ResponseEntity.ok(modjamService.createJam(jam, user.getId(), user.getUsername()));
}

@PutMapping("/{id}")
public ResponseEntity<Modjam> updateJam(@PathVariable String id, @RequestBody Modjam jam) {
User user = accountService.getCurrentUser();
if (user == null) return ResponseEntity.status(401).build();
return ResponseEntity.ok(modjamService.updateJam(id, jam));
}

@PutMapping("/{id}/icon")
public ResponseEntity<?> updateIcon(@PathVariable String id, @RequestParam("file") MultipartFile file) {
User user = accountService.getCurrentUser();
if (user == null) return ResponseEntity.status(401).build();
try {
modjamService.updateIcon(id, file);
return ResponseEntity.ok().build();
} catch (Exception e) {
return ResponseEntity.badRequest().body(e.getMessage());
}
}

@PutMapping("/{id}/banner")
public ResponseEntity<?> updateBanner(@PathVariable String id, @RequestParam("file") MultipartFile file) {
User user = accountService.getCurrentUser();
if (user == null) return ResponseEntity.status(401).build();
try {
modjamService.updateBanner(id, file);
return ResponseEntity.ok().build();
} catch (Exception e) {
return ResponseEntity.badRequest().body(e.getMessage());
}
}

@DeleteMapping("/{id}")
public ResponseEntity<?> deleteJam(@PathVariable String id) {
User user = accountService.getCurrentUser();
if (user == null) return ResponseEntity.status(401).build();
try {
modjamService.deleteJam(id, user.getId());
return ResponseEntity.ok().build();
} catch (ResponseStatusException e) {
return ResponseEntity.status(e.getStatusCode()).body(e.getReason());
} catch (Exception e) {
return ResponseEntity.badRequest().body(e.getMessage());
}
}

@GetMapping("/{jamId}/submissions")
public ResponseEntity<List<ModjamSubmission>> getSubmissions(@PathVariable String jamId) {
return ResponseEntity.ok(modjamService.getSubmissions(jamId));
}

@PostMapping("/{jamId}/participate")
public ResponseEntity<Modjam> participate(@PathVariable String jamId) {
User user = accountService.getCurrentUser();
if (user == null) return ResponseEntity.status(401).build();
return ResponseEntity.ok(modjamService.participate(jamId, user.getId()));
}

@PostMapping("/{jamId}/leave")
public ResponseEntity<Modjam> leaveJam(@PathVariable String jamId) {
User user = accountService.getCurrentUser();
if (user == null) return ResponseEntity.status(401).build();
return ResponseEntity.ok(modjamService.leaveJam(jamId, user.getId()));
}

@PostMapping("/{jamId}/submit")
public ResponseEntity<ModjamSubmission> submitProject(@PathVariable String jamId, @RequestBody Map<String, String> body) {
User user = accountService.getCurrentUser();
if (user == null) return ResponseEntity.status(401).build();
return ResponseEntity.ok(modjamService.submitProject(jamId, body.get("projectId"), user.getId()));
}

@PostMapping("/{jamId}/vote")
public ResponseEntity<ModjamSubmission> vote(@PathVariable String jamId, @RequestBody Map<String, Object> body) {
User user = accountService.getCurrentUser();
if (user == null) return ResponseEntity.status(401).build();

String submissionId = (String) body.get("submissionId");
String categoryId = (String) body.get("categoryId");
int score = (Integer) body.get("score");

return ResponseEntity.ok(modjamService.vote(jamId, submissionId, categoryId, score, user.getId()));
}

@PostMapping("/{jamId}/finalize")
public ResponseEntity<Modjam> finalizeJam(@PathVariable String jamId, @RequestBody List<Map<String, String>> winners) {
User user = accountService.getCurrentUser();
if (user == null) return ResponseEntity.status(401).build();
return ResponseEntity.ok(modjamService.finalizeJam(jamId, user.getId(), winners));
}

// Judging Endpoints
@PostMapping("/{jamId}/judges/invite")
public ResponseEntity<Modjam> inviteJudge(@PathVariable String jamId, @RequestBody Map<String, String> body) {
User user = accountService.getCurrentUser();
if (user == null) return ResponseEntity.status(401).build();
return ResponseEntity.ok(modjamService.inviteJudge(jamId, body.get("username"), user.getId()));
}

@PostMapping("/{jamId}/judges/accept")
public ResponseEntity<Modjam> acceptJudge(@PathVariable String jamId) {
User user = accountService.getCurrentUser();
if (user == null) return ResponseEntity.status(401).build();
return ResponseEntity.ok(modjamService.acceptJudgeInvite(jamId, user.getId(), user.getUsername()));
}

@PostMapping("/{jamId}/judges/decline")
public ResponseEntity<Modjam> declineJudge(@PathVariable String jamId) {
User user = accountService.getCurrentUser();
if (user == null) return ResponseEntity.status(401).build();
return ResponseEntity.ok(modjamService.declineJudgeInvite(jamId, user.getUsername()));
}

@DeleteMapping("/{jamId}/judges/{username}")
public ResponseEntity<Modjam> removeJudge(@PathVariable String jamId, @PathVariable String username) {
User user = accountService.getCurrentUser();
if (user == null) return ResponseEntity.status(401).build();
return ResponseEntity.ok(modjamService.removeJudge(jamId, username, user.getId()));
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,7 @@ public class ProjectDTO {
private List<String> types;
private List<String> childProjectIds;
private List<String> modIds;
private List<String> modjamIds;
private boolean allowModpacks;
private boolean allowComments;
private boolean hmWikiEnabled;
Expand Down Expand Up @@ -109,6 +110,8 @@ public class ProjectDTO {
public void setChildProjectIds(List<String> childProjectIds) { this.childProjectIds = childProjectIds; }
public List<String> getModIds() { return modIds; }
public void setModIds(List<String> modIds) { this.modIds = modIds; }
public List<String> getModjamIds() { return modjamIds; }
public void setModjamIds(List<String> modjamIds) { this.modjamIds = modjamIds; }
public boolean isAllowModpacks() { return allowModpacks; }
public void setAllowModpacks(boolean allowModpacks) { this.allowModpacks = allowModpacks; }
public boolean isAllowComments() { return allowComments; }
Expand Down
Loading
Loading