From f2d1a8dd9264ec5c591ed62a4a2c528f063ad0c6 Mon Sep 17 00:00:00 2001 From: wuyiping0628 <42107997+wuyiping0628@users.noreply.github.com> Date: Fri, 26 Jul 2024 00:37:38 -0700 Subject: [PATCH] fix(breadcrumb): [breadcrumb] resolve the issue of separator not switching (#1783) --- packages/renderless/package.json | 2 +- packages/renderless/src/breadcrumb-item/vue.ts | 9 +++------ 2 files changed, 4 insertions(+), 7 deletions(-) diff --git a/packages/renderless/package.json b/packages/renderless/package.json index 879561ca65..dbdc9d877a 100644 --- a/packages/renderless/package.json +++ b/packages/renderless/package.json @@ -1,6 +1,6 @@ { "name": "@opentiny/vue-renderless", - "version": "3.17.5", + "version": "3.17.6", "private": true, "description": "An enterprise-class UI component library, support both Vue.js 2 and Vue.js 3, as well as PC and mobile.", "author": "OpenTiny Team", diff --git a/packages/renderless/src/breadcrumb-item/vue.ts b/packages/renderless/src/breadcrumb-item/vue.ts index d6982e4af9..4c02c6a320 100644 --- a/packages/renderless/src/breadcrumb-item/vue.ts +++ b/packages/renderless/src/breadcrumb-item/vue.ts @@ -22,18 +22,15 @@ export const api = ['linkClick', 'state'] export const renderless = ( props: IBreadcrumbItemProps, - { reactive, inject }: ISharedRenderlessParamHooks, - { designConfig }, - { refs, router, emit }: IBreadcrumbItemRenderlessParamUtils + { reactive, inject, computed }: ISharedRenderlessParamHooks, + { refs, router, emit, designConfig }: IBreadcrumbItemRenderlessParamUtils ) => { const breadcrumbEmitter = inject('breadcrumbEmitter') const breadcrumb = inject('breadcrumb') const constants = breadcrumb._constants - // separator - const separator = breadcrumb.separator || designConfig?.separator || '>' const state = reactive({ size: inject('size', null), - separator + separator: computed(() => breadcrumb.separator || designConfig?.separator || '>') }) const api: IBreadcrumbItemApi = { state,