-
Notifications
You must be signed in to change notification settings - Fork 315
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Refactor, move some fa icons to dedicated components. Eventually get …
…rid of fontawesome css hopefully.
- Loading branch information
Showing
8 changed files
with
22 additions
and
19 deletions.
There are no files selected for viewing
This file contains 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
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,30 +1,31 @@ | ||
--- | ||
import Paintbrush from "@components/icons/paintbrush.astro"; | ||
import Scroll from "@components/icons/scroll.astro"; | ||
const { type } = Astro.props; | ||
type Props = { | ||
type: ExtType; | ||
}; | ||
let icon = "fa-solid fa-paintbrush"; | ||
let abbrTitle = "Style"; | ||
if (type === "page" || type === "serviceWorker") { | ||
icon = "fa-solid fa-scroll"; | ||
abbrTitle = "Script"; | ||
} | ||
const abbrTitle = type === "theme" ? "Theme" : "Script"; | ||
--- | ||
|
||
<div class="marketplace-icon"> | ||
<abbr title={abbrTitle}> | ||
<i class={icon + " fa-lg marketplace-icon"}></i> | ||
{type === "theme" ? <Paintbrush class="icon" /> : <Scroll class="icon" />} | ||
</abbr> | ||
</div> | ||
|
||
<style> | ||
<style is:global> | ||
.marketplace-icon { | ||
width: 32px; | ||
filter: brightness(0.8); | ||
align-self: flex-start; | ||
padding-bottom: 1rem; | ||
} | ||
|
||
.mp-icon { | ||
height: 24px; | ||
} | ||
</style> |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 576 512" fill="var(--text-color)" class="mp-icon"> | ||
<path d="M339.3 367.1c27.3-3.9 51.9-19.4 67.2-42.9L568.2 74.1c12.6-19.5 9.4-45.3-7.6-61.2S517.7-4.4 499.1 9.6L262.4 187.2c-24 18-38.2 46.1-38.4 76.1L339.3 367.1zm-19.6 25.4l-116-104.4C143.9 290.3 96 339.6 96 400c0 3.9 .2 7.8 .6 11.6C98.4 429.1 86.4 448 68.8 448L64 448c-17.7 0-32 14.3-32 32s14.3 32 32 32l144 0c61.9 0 112-50.1 112-112c0-2.5-.1-5-.2-7.5z" /> | ||
</svg> |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 576 512" fill="var(--text-color)" class="mp-icon"> | ||
<path d="M0 80l0 48c0 17.7 14.3 32 32 32l16 0 48 0 0-80c0-26.5-21.5-48-48-48S0 53.5 0 80zM112 32c10 13.4 16 30 16 48l0 304c0 35.3 28.7 64 64 64s64-28.7 64-64l0-5.3c0-32.4 26.3-58.7 58.7-58.7L480 320l0-192c0-53-43-96-96-96L112 32zM464 480c61.9 0 112-50.1 112-112c0-8.8-7.2-16-16-16l-245.3 0c-14.7 0-26.7 11.9-26.7 26.7l0 5.3c0 53-43 96-96 96l176 0 96 0z" /> | ||
</svg> |
This file contains 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
This file contains 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
This file contains 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
This file contains 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