diff --git a/packages/devui-vue/devui/back-top/index.ts b/packages/devui-vue/devui/back-top/index.ts index 3a5f745c6a7af46599e3d69424067a3c2bea361b..cdc6e7eb8b734e768d62adc12ee73794299cfd16 100644 --- a/packages/devui-vue/devui/back-top/index.ts +++ b/packages/devui-vue/devui/back-top/index.ts @@ -10,7 +10,7 @@ export { BackTop } export default { title: 'BackTop 回到顶部', category: '导航', - status: '10%', // TODO: 组件若开发完成则填入"已完成",并删除该注释 + status: '60%', // TODO: 组件若开发完成则填入"已完成",并删除该注释 install(app: App): void { app.use(BackTop as any) } diff --git a/packages/devui-vue/devui/back-top/src/hooks/use-target.ts b/packages/devui-vue/devui/back-top/src/hooks/use-target.ts index 220e770bd7780759ce606729ef9200aa7d09b6a3..f0a1139b7950ecfe3c184bd4986b36e3988a6f09 100644 --- a/packages/devui-vue/devui/back-top/src/hooks/use-target.ts +++ b/packages/devui-vue/devui/back-top/src/hooks/use-target.ts @@ -8,7 +8,7 @@ export default function (props: BackTopProps, backTopRef) { if (!targetEl) throw new Error(`props ${target} is not existed`) // 设置定位 - targetEl.style.position = 'relative' + targetEl.parentElement.style.position = 'relative' backTopRef.value.style.position = 'absolute' return targetEl }