Skip to content

Commit

Permalink
fix: layout shift after first search
Browse files Browse the repository at this point in the history
  • Loading branch information
scissorsneedfoodtoo committed Nov 20, 2023
1 parent a8b5e4a commit edd4277
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 3 deletions.
2 changes: 1 addition & 1 deletion apps/pokemon-search-app/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ <h1>Pokémon Search App</h1>
<span id="weight"></span>
<span id="height"></span>
</div>
<img src alt id="sprite" />
<div class="sprite-container"><img alt id="sprite" /></div>
<div id="types"></div>
</div>
<div class="bottom-container">
Expand Down
9 changes: 7 additions & 2 deletions apps/pokemon-search-app/public/styles.css
Original file line number Diff line number Diff line change
Expand Up @@ -114,10 +114,15 @@ label {
font-size: 0.85rem;
}

.sprite-container {
flex-grow: 2;
display: flex;
align-items: center;
justify-content: center;
}

#sprite {
margin: 20px 0;
width: 180px;
align-self: center;
}

#types {
Expand Down

0 comments on commit edd4277

Please sign in to comment.