Replace the landing with the artifact design and rebuild the admin in Ant Design.
Adds consultation leads, section editors, and the one-time content reset for this release. Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
@@ -0,0 +1,26 @@
|
||||
<template>
|
||||
<img
|
||||
v-if="src && !failed"
|
||||
ref="imgEl"
|
||||
:src="src"
|
||||
:alt="alt"
|
||||
loading="lazy"
|
||||
decoding="async"
|
||||
@error="failed = true"
|
||||
>
|
||||
</template>
|
||||
|
||||
<script setup lang="ts">
|
||||
/** Lazy image that removes itself on load failure so a broken-image icon never shows inside the design. */
|
||||
const props = defineProps<{ src?: string | null; alt: string }>();
|
||||
const failed = ref(false);
|
||||
const imgEl = ref<HTMLImageElement | null>(null);
|
||||
|
||||
watch(() => props.src, () => (failed.value = false));
|
||||
|
||||
onMounted(() => {
|
||||
// A server-rendered image can fail before hydration attaches the error listener.
|
||||
const img = imgEl.value;
|
||||
if (img && img.complete && img.naturalWidth === 0) failed.value = true;
|
||||
});
|
||||
</script>
|
||||
Reference in New Issue
Block a user