fix: lint

pull/340/MERGE
xingyu4j 2026-04-13 16:46:44 +08:00
parent adecddae67
commit b2cf1646a4
11 changed files with 13 additions and 14 deletions

View File

@ -64,12 +64,12 @@ const [Form, formApi] = useVbenForm({
// ================= =================
/** SKU 扩展类型 */
interface SkuExtension extends MallSpuApi.Sku {
interface SkuExtension extends MallSpuApi.Sku {
productConfig: MallDiscountActivityApi.DiscountProduct;
}
/** SPU 扩展类型 */
interface SpuExtension extends MallSpuApi.Spu {
interface SpuExtension extends MallSpuApi.Spu {
skus?: SkuExtension[];
}

View File

@ -50,7 +50,7 @@ function openRightMessage(item: MallKefuConversationApi.Conversation) {
/** 获得消息类型 */
const getConversationDisplayText = computed(
() => (lastMessageContentType: number, lastMessageContent: string) => {
() => (lastMessageContentType: number, lastMessageContent: string) => {
switch (lastMessageContentType) {
case KeFuMessageContentTypeEnum.IMAGE: {
return '[图片消息]';

View File

@ -21,7 +21,7 @@ import ProductBrowsingHistory from './product-browsing-history.vue';
const activeTab = ref<string>('会员信息');
const tabActivation = computed(() => (tab: string) => activeTab.value === tab);
const tabActivation = computed(() => (tab: string) => activeTab.value === tab);
/** tab 切换 */
const productBrowsingHistoryRef =

View File

@ -51,7 +51,7 @@ const loadHistory = ref(false); // 加载历史消息
/** 获悉消息内容 */
const getMessageContent = computed(
() => (item: any) => jsonParse(item.content),
() => (item: any) => jsonParse(item.content),
);
/** 获得消息列表 */

View File

@ -25,7 +25,7 @@ const emits = defineEmits<{
}>();
/** 选择赠送的优惠类型拓展 */
interface GiveCoupon extends MallCouponTemplateApi.CouponTemplate {
interface GiveCoupon extends MallCouponTemplateApi.CouponTemplate {
giveCount?: number;
}

View File

@ -64,12 +64,12 @@ const [Form, formApi] = useVbenForm({
// ================= =================
/** SKU 扩展类型 */
interface SkuExtension extends MallSpuApi.Sku {
interface SkuExtension extends MallSpuApi.Sku {
productConfig: MallDiscountActivityApi.DiscountProduct;
}
/** SPU 扩展类型 */
interface SpuExtension extends MallSpuApi.Spu {
interface SpuExtension extends MallSpuApi.Spu {
skus?: SkuExtension[];
}

View File

@ -50,7 +50,7 @@ function openRightMessage(item: MallKefuConversationApi.Conversation) {
/** 获得消息类型 */
const getConversationDisplayText = computed(
() => (lastMessageContentType: number, lastMessageContent: string) => {
() => (lastMessageContentType: number, lastMessageContent: string) => {
switch (lastMessageContentType) {
case KeFuMessageContentTypeEnum.IMAGE: {
return '[图片消息]';

View File

@ -21,7 +21,7 @@ import ProductBrowsingHistory from './product-browsing-history.vue';
const activeTab = ref<string>('会员信息');
const tabActivation = computed(() => (tab: string) => activeTab.value === tab);
const tabActivation = computed(() => (tab: string) => activeTab.value === tab);
/** tab 切换 */
const productBrowsingHistoryRef =

View File

@ -57,7 +57,7 @@ const loadHistory = ref(false); // 加载历史消息
/** 获悉消息内容 */
const getMessageContent = computed(
() => (item: any) => jsonParse(item.content),
() => (item: any) => jsonParse(item.content),
);
/** 获得消息列表 */

View File

@ -25,7 +25,7 @@ const emits = defineEmits<{
}>();
/** 选择赠送的优惠类型拓展 */
interface GiveCoupon extends MallCouponTemplateApi.CouponTemplate {
interface GiveCoupon extends MallCouponTemplateApi.CouponTemplate {
giveCount?: number;
}

View File

@ -4,8 +4,7 @@
*/
export function isUrl(path: string): boolean {
try {
new URL(path);
return true;
return Boolean(new URL(path));
} catch {
return false;
}