Skip to content

Self-hosted personal gallery application with online photo management and albums, supporting Live/Motion Photos, EXIF parsing, geolocation recognition, and an explore map.

style: 修复加载动画样式丢失

Timothy Yin4f26b6283f24
diff --git a/app/layouts/default.vue b/app/layouts/default.vue
index 74a33f07..6218ee5c 100644
--- a/app/layouts/default.vue
+++ b/app/layouts/default.vue
@@ -34,4 +34,37 @@ const photos = computed(() => (data.value as Photo[]) || [])
</div>
</template>
-<style scoped></style>
+<style scoped>
+.loading-scan-wrapper {
+ display: inline-block;
+ position: relative;
+}
+
+.loading-scan-text {
+ display: inline-block;
+ background: linear-gradient(
+ 90deg,
+ var(--ui-text-highlighted) 0%,
+ var(--ui-text-highlighted) 30%,
+ var(--ui-text-muted) 50%,
+ var(--ui-text-highlighted) 70%,
+ var(--ui-text-highlighted) 100%
+ );
+ background-size: 200% 100%;
+ background-position: 200% 0;
+ -webkit-background-clip: text;
+ -webkit-text-fill-color: transparent;
+ background-clip: text;
+ color: transparent;
+ animation: scan-x-text 1.2s linear infinite;
+}
+
+@keyframes scan-x-text {
+ 0% {
+ background-position: 200% 0;
+ }
+ 100% {
+ background-position: -200% 0;
+ }
+}
+</style>
diff --git a/app/pages/[...slug].vue b/app/pages/[...slug].vue
index 18b5b670..b9c9897c 100644
--- a/app/pages/[...slug].vue
+++ b/app/pages/[...slug].vue
@@ -64,36 +64,4 @@ const handleClose = () => {
/>
</template>
-<style scoped>
-.loading-scan-wrapper {
- display: inline-block;
- position: relative;
-}
-
-.loading-scan-text {
- display: inline-block;
- background: linear-gradient(
- 90deg,
- var(--ui-text-highlighted) 0%,
- var(--ui-text-highlighted) 30%,
- var(--ui-text-muted) 50%,
- var(--ui-text-highlighted) 70%,
- var(--ui-text-highlighted) 100%
- );
- background-size: 200% 100%;
- background-position: 200% 0;
- -webkit-background-clip: text;
- -webkit-text-fill-color: transparent;
- background-clip: text;
- color: transparent;
- animation: scan-x-text 1.2s linear infinite;
-}
-@keyframes scan-x-text {
- 0% {
- background-position: 200% 0;
- }
- 100% {
- background-position: -200% 0;
- }
-}
-</style>
+<style scoped></style>