···11-# Welcome to at://advent!
11+## Welcome to at://advent!
2233at://advent is an atproto adventure to learn [atproto](https://atproto.com/) in an interactive and
44hopefully fun way in the style of advent of code.
+2
shared/challenges_markdown/one/part_two.md
···11+//notes we are using the users multibase as the answer here. Explain how to find the did doc and what that key does
22+13Great job beating Part 1! Now onto Part 2.
2435This will be submitting their public verification code from the did doc since each did doc will have one.
+4-4
web/src/handlers/day.rs
···338338 ),
339339 )
340340 .await?;
341341- Ok(Redirect::to(format!("/day/{}", day as u8).as_str()))
341341+ Ok(Redirect::to(format!("/day/{}#part_two", day as u8).as_str()))
342342 }
343343 ChallengeCheckResponse::Incorrect(message) => {
344344 set_flash_message(
···383383 ),
384384 )
385385 .await?;
386386- Ok(Redirect::to(format!("/day/{}", day as u8).as_str()))
386386+ Ok(Redirect::to(format!("/day/{}#part_two", day as u8).as_str()))
387387 }
388388 ChallengeCheckResponse::Incorrect(message) => {
389389 set_flash_message(
···392392 FlashMessage::Error(message),
393393 )
394394 .await?;
395395- Ok(Redirect::to(format!("/day/{}", day as u8).as_str()))
395395+ Ok(Redirect::to(format!("/day/{}#part_two", day as u8).as_str()))
396396 }
397397 }
398398 }
399399- CompletionStatus::Both => Ok(Redirect::to(format!("/day/{}", day as u8).as_str())),
399399+ CompletionStatus::Both => Ok(Redirect::to(format!("/day/{}#part_two", day as u8).as_str())),
400400 }
401401 }
402402 }
+9-1
web/templates/day.askama.html
···75757676 <!-- Part 2 -->
7777 {% if let Some(challenge_two_text) = challenge_two_text %}
7878- <div class="card bg-base-100 shadow-xl mb-6">
7878+ <div id="part_two" class="card bg-base-100 shadow-xl mb-6">
7979 <div class="card-body">
8080 <h3 class="card-title text-2xl">
8181 Part 2
···145145 <div class="text-sm">You've completed all the challenges for today! Come back tomorrow at 00:00 UTC for more.</div>
146146 </div>
147147 </div>
148148+ {% endif %}
149149+150150+ {% if challenge_one_completed %}
151151+ <script>
152152+ if (window.location.hash === '#part_two') {
153153+ document.getElementById('part_two')?.scrollIntoView({ behavior: 'smooth' });
154154+ }
155155+ </script>
148156 {% endif %}
149157150158{% endblock %}