This commit is contained in:
tamaina 2023-02-10 18:36:48 +00:00
parent dc4a814490
commit 8ce1a32615

View File

@ -138,7 +138,7 @@ let ro2: ResizeObserver | null;
function renderTab() {
const tabEl = props.tab ? tabRefs[props.tab] : undefined;
if (tabEl && tabEl.parentElement && tabHighlightEl && tabHighlightEl.parentElement) {
if (tabEl && tabHighlightEl && tabHighlightEl.parentElement) {
// offsetWidth offsetLeft getBoundingClientRect 使
// https://developer.mozilla.org/ja/docs/Web/API/HTMLElement/offsetWidth#%E5%80%A4
const parentRect = tabHighlightEl.parentElement.getBoundingClientRect();