Skip to content

Commit

Permalink
add page description as profile content
Browse files Browse the repository at this point in the history
  • Loading branch information
thatkookooguy committed Sep 4, 2024
1 parent 2d3e5cb commit 0a67774
Show file tree
Hide file tree
Showing 2 changed files with 22 additions and 5 deletions.
8 changes: 8 additions & 0 deletions index.html
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,14 @@
<img alt="User Avatar" src="https://i.pravatar.cc/300">
</div>
</div>
<div class="content">
<p>
This demo showcases the Achievibit profile cover image in action, brought to life using Phaser. Instead of a simple static image, the cover transforms into a fun, interactive platformer where users can explore their personalized "layer." The layer acts as a home base, reflecting the user’s faction and decorated with trophies and characters based on their achievements.
</p>
<p>
Navigate through your custom environment, uncover hidden surprises, and get a taste of how your accomplishments come to life in this dynamic cover experience. This demo offers a glimpse into how profile covers can be more than just visuals—they can be adventures!
</p>
</div>
<script type="module" src="src/main.ts"></script>
</body>

Expand Down
19 changes: 14 additions & 5 deletions scss/style.scss
Original file line number Diff line number Diff line change
@@ -1,9 +1,12 @@
html,
body {
--avatar-size: 150px;
display: flex;
justify-content: center;
flex-direction: column;

// align-items: center;
// justify-content: center;

align-items: center;

width: 100dvw;
height: 100dvh;
Expand All @@ -25,11 +28,17 @@ canvas {
box-shadow: rgb(0 0 0 / 50%) 0 5px 10px;
}

.content {
margin-block-start: calc(var(--avatar-size) / 2);
padding: 0 20px;

color: rgb(131 130 130);
}

.user-avatar {
--size: 150px;
position: absolute;
inset-block-start: calc(100dvh / 2 - var(--size) / 2);
inset-inline-start: calc(50% - var(--size) / 2);
inset-block-start: calc(100dvh / 2 - var(--avatar-size) / 2);
inset-inline-start: calc(50% - var(--avatar-size) / 2);

width: 150px;
height: 150px;
Expand Down

0 comments on commit 0a67774

Please sign in to comment.