diff --git a/public/css/woff/fontFamily.css b/public/css/woff/fontFamily.css index db4b235..e6a53fc 100644 --- a/public/css/woff/fontFamily.css +++ b/public/css/woff/fontFamily.css @@ -34,6 +34,13 @@ src: url("./Roboto/Roboto-Bold.ttf") format('woff2'); /* unicode-range: U+0460-052F, U+1C80-1C88, U+20B4, U+2DE0-2DFF, U+A640-A69F, U+FE2E-FE2F; */ } +@font-face { + font-family: 'robotoRegular'; + font-style: italic; + font-weight: 700; + src: url("./Roboto/Roboto-Regular.ttf") format('woff2'); + /* unicode-range: U+0460-052F, U+1C80-1C88, U+20B4, U+2DE0-2DFF, U+A640-A69F, U+FE2E-FE2F; */ +} @font-face { font-family: 'boskaRegular'; font-style: italic; diff --git a/src/assets/css/style.less b/src/assets/css/style.less index 5e6617f..448580c 100644 --- a/src/assets/css/style.less +++ b/src/assets/css/style.less @@ -101,4 +101,4 @@ button.general, line-height: 7.4rem; width: 3.4rem; } -} \ No newline at end of file +} diff --git a/src/assets/icons/modelSelected.svg b/src/assets/icons/modelSelected.svg index 7056127..031ac2e 100644 --- a/src/assets/icons/modelSelected.svg +++ b/src/assets/icons/modelSelected.svg @@ -1,9 +1,10 @@ - + + - - + + - + diff --git a/src/assets/icons/send.svg b/src/assets/icons/send.svg index fa13feb..8f70a26 100644 --- a/src/assets/icons/send.svg +++ b/src/assets/icons/send.svg @@ -1,3 +1,3 @@ - - + + diff --git a/src/assets/icons/setting.svg b/src/assets/icons/setting.svg index e0db425..f84bf4a 100644 --- a/src/assets/icons/setting.svg +++ b/src/assets/icons/setting.svg @@ -1 +1,4 @@ - \ No newline at end of file + + + + diff --git a/src/utils/share.ts b/src/utils/share.ts deleted file mode 100644 index 8b87b6c..0000000 --- a/src/utils/share.ts +++ /dev/null @@ -1,209 +0,0 @@ -/** - * 分享工具函数 - * 支持移动浏览器原生分享 API 和 WhatsApp 分享 - */ - -interface ShareData { - title?: string - text?: string - url?: string - files?: File[] -} - -/** - * 检查是否支持 Web Share API - */ -export function isWebShareSupported(): boolean { - return typeof navigator !== 'undefined' && 'share' in navigator -} - -/** - * 使用 Web Share API 进行分享(移动浏览器原生分享) - * @param data 分享数据 - */ -async function shareWithWebAPI(data: ShareData): Promise { - if (!isWebShareSupported()) { - throw new Error('Web Share API is not supported') - } - - try { - // Web Share API 只支持 title, text, url 和 files - const shareData: ShareData = {} - - if (data.title) shareData.title = data.title - if (data.text) shareData.text = data.text - if (data.url) shareData.url = data.url - if (data.files && data.files.length > 0) shareData.files = data.files - - await navigator.share(shareData) - } catch (error: any) { - // 用户取消分享时,会抛出 AbortError,这是正常情况 - if (error.name !== 'AbortError') { - console.error('分享失败:', error) - throw error - } - } -} - -/** - * 分享到 WhatsApp(回退方案) - * @param text 分享的文本内容 - * @param url 分享的链接(可选) - */ -export function shareToWhatsApp(text: string, url?: string): void { - const shareText = url ? `${text} ${url}` : text - const encodedText = encodeURIComponent(shareText) - const whatsappScheme = `whatsapp://send?text=${encodedText}` - const whatsappWebUrl = `https://wa.me/?text=${encodedText}` - const isMobile = typeof navigator !== 'undefined' && /Android|iPhone|iPad|iPod|Mobile/i.test(navigator.userAgent) - - if (typeof window === 'undefined') return - - if (isMobile) { - // 优先尝试调用已安装的 WhatsApp 应用,失败后回退到 Web 版本 - let didFallback = false - const fallbackTimer = window.setTimeout(() => { - didFallback = true - window.location.href = whatsappWebUrl - }, 1500) - - try { - window.location.href = whatsappScheme - } catch (error) { - window.clearTimeout(fallbackTimer) - window.location.href = whatsappWebUrl - } - - // 某些浏览器会在成功唤起 App 时终止脚本,无需额外处理 - return - } - - // 桌面端或不支持 scheme 的环境直接打开 WhatsApp Web - window.open(whatsappWebUrl, '_blank') -} - -/** - * 通用分享函数(优先使用 Web Share API,不支持则回退到 WhatsApp) - * @param options 分享选项 - */ -export async function share(options: { - title?: string - text?: string - url?: string - files?: File[] - fallbackToWhatsApp?: boolean -}): Promise { - const { title, text, url, files, fallbackToWhatsApp = true } = options - - // 如果支持 Web Share API,优先使用 - if (isWebShareSupported() && !files) { - try { - await shareWithWebAPI({ title, text, url }) - return - } catch (error) { - // 如果分享失败且允许回退,则使用 WhatsApp - if (fallbackToWhatsApp) { - const shareText = [title, text, url].filter(Boolean).join('\n\n') - shareToWhatsApp(shareText) - return - } - throw error - } - } - - // 如果不支持 Web Share API 或需要分享文件,使用 WhatsApp - if (fallbackToWhatsApp) { - const shareText = [title, text, url].filter(Boolean).join('\n\n') - shareToWhatsApp(shareText) - } else { - throw new Error('Web Share API is not supported and fallback is disabled') - } -} - -/** - * 分享当前页面(优先使用原生分享,不支持则回退到 WhatsApp) - * @param title 分享的标题 - * @param description 分享的描述(可选) - */ -export async function shareCurrentPage(title: string, description?: string): Promise { - const currentUrl = window.location.href - await share({ - title, - text: description, - url: currentUrl, - fallbackToWhatsApp: true - }) -} - -/** - * 分享图片(优先使用原生分享,不支持则回退到 WhatsApp) - * @param imageUrl 图片链接 - * @param title 分享的标题 - * @param description 分享的描述(可选) - */ -export async function shareImage(imageUrl: string, title: string, description?: string): Promise { - const currentUrl = window.location.href - const text = description - ? `${description}\n\n查看图片: ${imageUrl}` - : `查看图片: ${imageUrl}` - - await share({ - title, - text, - url: currentUrl, - fallbackToWhatsApp: true - }) -} - -/** - * 分享图片文件(使用 Web Share API,支持直接分享图片文件) - * @param imageFile 图片文件 - * @param title 分享的标题(可选) - * @param text 分享的文本(可选) - */ -export async function shareImageFile(imageFile: File, title?: string, text?: string): Promise { - if (!isWebShareSupported()) { - throw new Error('WEB_SHARE_UNSUPPORTED') - } - if (typeof navigator.canShare === 'function' && !navigator.canShare({ files: [imageFile] })) { - throw new Error('WEB_SHARE_FILE_UNSUPPORTED') - } - - await shareWithWebAPI({ - title, - text, - files: [imageFile] - }) -} - -/** - * 将远程图片转换为 File 对象,便于提前缓存后再触发分享 - * @param imageUrl 图片链接 - * @param fileName 文件名(可选) - */ -export async function createImageFileFromUrl(imageUrl: string, fileName?: string): Promise { - const response = await fetch(imageUrl) - const blob = await response.blob() - const name = fileName || imageUrl.split('/').pop() || 'share-image.jpg' - return new File([blob], name, { type: blob.type || 'image/jpeg' }) -} - -/** - * 分享当前页面到 WhatsApp(兼容旧版本,推荐使用 shareCurrentPage) - * @param title 分享的标题 - * @param description 分享的描述(可选) - */ -export async function shareCurrentPageToWhatsApp(title: string, description?: string): Promise { - await shareCurrentPage(title, description) -} - -/** - * 分享图片到 WhatsApp(兼容旧版本,推荐使用 shareImage) - * @param imageUrl 图片链接 - * @param title 分享的标题 - * @param description 分享的描述(可选) - */ -export async function shareImageToWhatsApp(imageUrl: string, title: string, description?: string): Promise { - await shareImage(imageUrl, title, description) -} - diff --git a/src/views/Workshop/creation/creation-list.vue b/src/views/Workshop/creation/creation-list.vue index 1fa409a..53756aa 100644 --- a/src/views/Workshop/creation/creation-list.vue +++ b/src/views/Workshop/creation/creation-list.vue @@ -179,7 +179,7 @@ const onContinue = () => {
-
Your Creation
+
Your Creation
@@ -230,7 +230,7 @@ const onContinue = () => { display: flex; flex-direction: column; > .title { - font-family: satoshiRegular; + font-family: 'satoshiRegular'; font-size: 9rem; text-align: center; line-height: 124%; @@ -284,8 +284,9 @@ const onContinue = () => { } > .ai { color: #646464; - background: linear-gradient( - 137.95deg, + background: linear-gradient(0deg, rgba(230, 219, 219, 0.5), rgba(230, 219, 219, 0.5)), + linear-gradient( + 165.5deg, #7a96ac 2.28%, #eaeff3 19.8%, #c2d4e1 32.94%, @@ -293,8 +294,7 @@ const onContinue = () => { #d4dee5 62.15%, #abbdc8 78.69%, #bccad7 95.24% - ), - linear-gradient(0deg, rgba(230, 219, 219, 0.5), rgba(230, 219, 219, 0.5)); + ); } } > .icons { @@ -309,7 +309,7 @@ const onContinue = () => { width: 5rem; height: 5rem; border-radius: 1rem; - border: 0.2rem solid #000; + border: 0.2rem solid rgba(0, 0, 0, 0.5); --svg-icon-color: #000; display: flex; align-items: center; diff --git a/src/views/Workshop/product.vue b/src/views/Workshop/product.vue index 7f351a5..20f3143 100644 --- a/src/views/Workshop/product.vue +++ b/src/views/Workshop/product.vue @@ -151,7 +151,7 @@ const { isLoading } = toRefs(data);
- +
@@ -199,6 +199,7 @@ const { isLoading } = toRefs(data); font-weight: 700; font-size: 9.6rem; line-height: 124%; + color: #000; } } > .selectContent{ @@ -261,8 +262,18 @@ const { isLoading } = toRefs(data); margin-top: 4.4rem; display: flex; justify-content: center; - > div{ - margin-right: 3.9rem; + > button{ + border-radius: .7rem; + border: 3px solid #000; + background-color: #000; + text-align: center; + color: #fff; + font-family: satoshiMedium; + font-size: 3.6rem; + width: 24.6rem; + line-height: 6.7rem; + height: 6.7rem; + box-sizing: border-box; &:last-child{ margin-right: 0; } diff --git a/src/views/Workshop/selectStyle.vue b/src/views/Workshop/selectStyle.vue index 54ccabb..17de2b1 100644 --- a/src/views/Workshop/selectStyle.vue +++ b/src/views/Workshop/selectStyle.vue @@ -118,14 +118,14 @@ const { styleList, select } = toRefs(data); Select the outfit that matches you the most. -
+
+
- \ No newline at end of file diff --git a/src/views/Workshop/uploadFace1.vue b/src/views/Workshop/uploadFace1.vue index 9c59c5c..82c6c60 100644 --- a/src/views/Workshop/uploadFace1.vue +++ b/src/views/Workshop/uploadFace1.vue @@ -45,10 +45,10 @@

- - +
@@ -91,10 +91,14 @@ justify-content: center; bottom: 19.7rem; > button { - width: 40rem; + width: 35rem; height: 8.3rem; + box-sizing: border-box; border-radius: 0.7rem; margin: 0 1.8rem; + &.sandblasted-blurred { + border-width: 0.2rem; + } } } } diff --git a/src/views/asistant/components/InputArea.vue b/src/views/asistant/components/InputArea.vue index 2cc5612..670ca10 100644 --- a/src/views/asistant/components/InputArea.vue +++ b/src/views/asistant/components/InputArea.vue @@ -296,7 +296,7 @@ const stopRecording = () => { .shortcut-item { font-size: 4.2rem; width: fit-content; - font-family: 'robotoBold'; + font-family: 'robotoRegular'; white-space: nowrap; height: 8.1rem; line-height: 8.1rem; @@ -351,7 +351,7 @@ const stopRecording = () => { outline: none; background: transparent; font-size: 4rem; - font-family: 'robotoBold'; + font-family: 'robotoRegular'; font-weight: 400; line-height: 4.8rem; /* 设置行高等于实际渲染高度,实现垂直居中 */ padding: 0; @@ -362,7 +362,7 @@ const stopRecording = () => { color: #888; letter-spacing: -0.01em; font-weight: 400; - font-family: 'robotoBold'; + font-family: 'robotoRegular'; word-spacing: -5px; line-height: 4.8rem; } @@ -405,7 +405,7 @@ const stopRecording = () => { } .recording-text { - font-family: 'robotoBold'; + font-family: 'robotoRegular'; font-size: 2.8rem; color: #6d6868; letter-spacing: 0.02em; diff --git a/src/views/asistant/components/NoticeItem.vue b/src/views/asistant/components/NoticeItem.vue index 91666a4..d133f14 100644 --- a/src/views/asistant/components/NoticeItem.vue +++ b/src/views/asistant/components/NoticeItem.vue @@ -97,11 +97,11 @@ const actionList: ActionItem[] = [ align-items: flex-start; .message-text { font-size: 4.2rem; - font-family: 'robotoBold'; + font-family: 'robotoRegular'; line-height: 121%; font-weight: 400; background-color: #efefef; - padding: 4.95rem 3.95rem; + padding: 3.43rem 4.35rem; } &.user-message { diff --git a/src/views/asistant/index.vue b/src/views/asistant/index.vue index 4981c47..91dbaa2 100644 --- a/src/views/asistant/index.vue +++ b/src/views/asistant/index.vue @@ -17,8 +17,8 @@