Repository navigation
Conversation
|
@luke-song is attempting to deploy a commit to the Workoutcool Team Team on Vercel. A member of the Team first needs to authorize it. |
2 of 5 tasks
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Adds a Share my success button on the workout complete screen (next to Go to my profile) so users can generate a social-friendly summary image client-side.
Closes #54.
What changed
ShareWorkoutCard(4:5 / 600×750) with date, muscles worked, exercise count, motivational message, and workout.cool logoShareWorkoutButtonthat captures the card withhtml-to-image, then uses the Web Share API with a PNG file when available (mobile), otherwise downloads the imageWorkoutStepper(and the congrats branch inWorkoutSessionSetsfor consistency)html-to-imagedependencyWhy this approach
completeWorkout(),isWorkoutActivebecomesfalse, so the visible congrats screen is inWorkoutStepper— not onlyWorkoutSessionSets. This PR puts the share CTA where users actually land.formatDatefromshared/lib/date(FSD) and a plain<img>for the logo sohtml-to-imagecaptures reliably.How to test
workout-cool-summary.png.Notes
There is an existing open PR (#250) for the same issue; this implementation differs mainly by wiring the button into the
WorkoutSteppercongrats screen users actually see after finish, plus multi-locale strings and FSD date formatting.