1
0

Project installation indicator (#3023)

* Add indicator for project installation

* fix lint

---------

Co-authored-by: Geometrically <18202329+Geometrically@users.noreply.github.com>
Co-authored-by: Jai A <jaiagr+gpg@pm.me>
This commit is contained in:
Prospector
2024-12-14 20:35:50 -08:00
committed by GitHub
parent 283a915a12
commit ca7cfb30c7
4 changed files with 42 additions and 12 deletions

View File

@@ -11,14 +11,28 @@
}
"
>
<div class="icon">
<Avatar :src="project.icon_url" size="96px" class="search-icon" />
<div class="icon w-[96px] h-[96px] relative">
<Avatar
:src="project.icon_url"
size="96px"
class="search-icon origin-top transition-all"
:class="{ 'scale-[0.85]': installed, 'brightness-50': installing }"
/>
<div v-if="installing" class="rounded-2xl absolute inset-0 flex items-center justify-center">
<SpinnerIcon class="h-8 w-8 animate-spin" />
</div>
<div
v-if="installed"
class="absolute shadow-sm font-semibold bottom-0 w-full p-1 bg-button-bg rounded-full text-xs justify-center items-center flex gap-1 text-brand border-[1px] border-solid border-[--color-button-border]"
>
<CheckIcon class="shrink-0 stroke-[3px]" /> Installed
</div>
</div>
<div class="flex flex-col gap-2 overflow-hidden">
<div class="gap-2 overflow-hidden no-wrap text-ellipsis">
<span class="text-lg font-extrabold text-contrast m-0 leading-none">{{
project.title
}}</span>
<span class="text-lg font-extrabold text-contrast m-0 leading-none">
{{ project.title }}
</span>
<span v-if="project.author" class="text-secondary"> by {{ project.author }}</span>
</div>
<div class="m-0 line-clamp-2">
@@ -93,6 +107,7 @@
<script setup>
import {
SpinnerIcon,
TagsIcon,
DownloadIcon,
HeartIcon,

View File

@@ -0,0 +1,19 @@
<svg
xmlns="http://www.w3.org/2000/svg"
fill="none"
viewBox="0 0 24 24"
>
<circle
class="opacity-25"
cx="12"
cy="12"
r="10"
stroke="currentColor"
stroke-width="4"
/>
<path
class="opacity-75"
fill="currentColor"
d="M4 12a8 8 0 018-8V0C5.373 0 0 5.373 0 12h4zm2 5.291A7.962 7.962 0 014 12H0c0 3.042 1.135 5.824 3 7.938l3-2.647z"
/>
</svg>

After

Width:  |  Height:  |  Size: 387 B

View File

@@ -145,6 +145,7 @@ import _SlashIcon from './icons/slash.svg?component'
import _SortAscendingIcon from './icons/sort-asc.svg?component'
import _SortDescendingIcon from './icons/sort-desc.svg?component'
import _SparklesIcon from './icons/sparkles.svg?component'
import _SpinnerIcon from './icons/spinner.svg?component'
import _StarIcon from './icons/star.svg?component'
import _StopCircleIcon from './icons/stop-circle.svg?component'
import _SunIcon from './icons/sun.svg?component'
@@ -333,6 +334,8 @@ export const ShieldIcon = _ShieldIcon
export const SlashIcon = _SlashIcon
export const SortAscendingIcon = _SortAscendingIcon
export const SortDescendingIcon = _SortDescendingIcon
export const SparklesIcon = _SparklesIcon
export const SpinnerIcon = _SpinnerIcon
export const StarIcon = _StarIcon
export const StopCircleIcon = _StopCircleIcon
export const SunIcon = _SunIcon
@@ -378,4 +381,3 @@ export const DBIcon = _DBIcon
export const LoaderIcon = _LoaderIcon
export const ImportIcon = _ImportIcon
export const CardIcon = _CardIcon
export const SparklesIcon = _SparklesIcon

View File

@@ -222,12 +222,6 @@ html {
--tab-underline-hovered: initial !important;
--color-button-text: initial !important;
--color-button-bg-hover: initial !important;
--color-button-text-hover: initial !important;
--color-button-bg-active: initial !important;
--color-button-text-active: initial !important;
--color-grey-link: inherit !important;
--color-grey-link-hover: inherit !important; // DEPRECATED, use filters in future
--color-grey-link-active: inherit !important; // DEPRECATED, use filters in future