diff --git a/src/lang/en.ts b/src/lang/en.ts index 4840211..a292575 100644 --- a/src/lang/en.ts +++ b/src/lang/en.ts @@ -18,7 +18,7 @@ export default { pleaseInputName: 'Please input the name', nameLengthError: 'Name length must be between {min} and {max} characters', passwordSpecial: 'Must contain special characters', - passwordCase: 'Mix of uppercase, lowercase and numbers', + passwordCase: 'A combination of numbers and letters', pleaseInputEmail: 'Please input the email', emailFormatError: 'Please input the email again', pleaseInputPassword: 'Please input the password', @@ -355,7 +355,7 @@ export default { Offices: "Offices", JoinWithUs: "Join with Us", }, - addShoppingCart:{ + addShoppingCart: { title: 'Added to your Shopping Cart', statement: 'Digital Assets Only. No physical product included.', button: 'See Shopping Cart' @@ -375,5 +375,23 @@ export default { germany: 'Germany', australia: 'Australia', canada: 'Canada' + }, + Pay: { + OrderSummary: 'Order Summary', + PaymentDetails: 'Payment Details', + CreditDebitCard: 'Credit / Debit Card', + AgreementText: 'I agree to the Terms & Conditions and Privacy Policy. All digital item sales are final and non-refundable.', + PayWithStripe: 'Pay with Stripe', + PayWith: 'Pay with', + Cancel: 'Cancel', + IHaveCompletedPayment: 'I Have Completed payment', + Back: 'Back', + PayTip1: "You'll be redirected to a Stripe popup to log in and confirm. No card details are shared with Stylish Parade — Stripe handles all payment security.", + PayTip2: "Please keep the window open until the payment is completed. If you are to open the payment window, please check your browser settings to see if pop-ups are being blocked. Points may be delayed after successful payment. Please wait 1-3 minutes and click the credits refresh button.", + PurchaseSuccessful: "Purchase Successful", + PurchaseSuccessfulTip: "Your digital items are now available and have been saved in Personal Center → My Wardrobe.", + DownloadAllAssets: "download all Assets", + ExportInvoice: "Export Invoice", + ContinueShopping: "Continue Shopping" } } diff --git a/src/lang/zh-cn.ts b/src/lang/zh-cn.ts index c42e792..0410399 100644 --- a/src/lang/zh-cn.ts +++ b/src/lang/zh-cn.ts @@ -18,7 +18,7 @@ export default { pleaseInputName: '请输入姓名', nameLengthError: '姓名长度必须在 {min} 到 {max} 个字符之间', passwordSpecial: '必须包含特殊符号', - passwordCase: '大小写字母与数字混合组合', + passwordCase: '字母和数字组合', pleaseInputEmail: '请输入邮箱', emailFormatError: '请输入正确的邮箱', pleaseInputPassword: '请输入密码', @@ -376,5 +376,23 @@ export default { AboutUs: '关于我们', Offices: '办公室', JoinWithUs: '加入我们' + }, + Pay: { + OrderSummary: '订单信息', + PaymentDetails: '支付详情', + CreditDebitCard: '信用卡/借记卡', + AgreementText: '我同意 使用条款与条件隐私政策。所有数字资产销售均为最终销售,不可退款。', + PayWithStripe: '使用 Stripe 支付', + PayWith: '支付', + Cancel: '取消', + IHaveCompletedPayment: '我已完成支付', + Back: '返回', + PayTip1: "您将被重定向到 Stripe 弹窗以登录并确认支付。您的信用卡信息不会被 Stylish Parade 收集。Stripe 处理所有支付安全。", + PayTip2: "请保持窗口打开,直到支付完成。如果您打开支付窗口,请检查浏览器设置以查看是否已阻止弹窗。支付完成后,积分可能会有延迟。请等待 1-3 分钟并点击积分刷新按钮。", + PurchaseSuccessful: "购买成功", + PurchaseSuccessfulTip: "您的数字资产已保存在个人中心的我的衣橱中。", + DownloadAllAssets: "下载所有资产", + ExportInvoice: "导出发票", + ContinueShopping: "继续购物" } } diff --git a/src/router/index.ts b/src/router/index.ts index 1f3729c..24cfc33 100644 --- a/src/router/index.ts +++ b/src/router/index.ts @@ -4,6 +4,7 @@ import { useGlobalStore } from '@/stores/global' import { getUserLanguage } from '@/api/user' import { fetchAllUnreadMessage } from '@/api/notification' import i18n from '@/lang/index' +import myEvent from '@/utils/myEvent' // 语言映射:后端格式 -> i18n 格式 const backendToI18nLanguage: Record = { @@ -19,6 +20,8 @@ let languageSynced = false * 1. 设置路由的meta属性为{ cache: true },表示需要缓存 * 2. App.vue中使用RouteCache组件,通过路由的name来进行匹配 * 3. 路由的name默认是文件名,如果文件名与name不一致,通过defineOptions({ name: 'componentName' })来设置 + * + * 需要登录路由: meta={ login:true } */ const router = createRouter({ routes: [ @@ -62,7 +65,8 @@ const router = createRouter({ { path: '/shoppingCart', // 购物车 name: 'shoppingCart', - component: () => import('@/views/shoppingCart/index.vue') + component: () => import('@/views/shoppingCart/index.vue'), + meta: { login: true } }, { path: '/notifications', @@ -94,6 +98,9 @@ const router = createRouter({ }) router.beforeEach((to, from, next) => { + if(to.meta?.login && !useUserInfoStore().state.token) { + myEvent.emit('openLoginDialog') + } next() }) diff --git a/src/views/home/index.vue b/src/views/home/index.vue index ad62926..d4dc704 100644 --- a/src/views/home/index.vue +++ b/src/views/home/index.vue @@ -28,6 +28,7 @@ > section { width: 100%; height: auto; + min-height: 50vw; } > section.bgw { position: relative; @@ -40,5 +41,8 @@ position: absolute; } } + > .section-footer { + min-height: 0; + } } diff --git a/src/views/home/section-digital-items1.vue b/src/views/home/section-digital-items1.vue index 157d2ea..11a3a7f 100644 --- a/src/views/home/section-digital-items1.vue +++ b/src/views/home/section-digital-items1.vue @@ -78,6 +78,7 @@ > div { padding: 1rem; border: 0.1rem solid #979797; + background-color: #fff; > img { width: 27.4rem; height: 34.6rem; diff --git a/src/views/home/section-digital-items2.vue b/src/views/home/section-digital-items2.vue index 4b2899d..34eca01 100644 --- a/src/views/home/section-digital-items2.vue +++ b/src/views/home/section-digital-items2.vue @@ -1,6 +1,6 @@