@x33025/sveltely 0.0.54 → 0.0.55
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -159,11 +159,12 @@
|
|
|
159
159
|
sourceRect.height / 2,
|
|
160
160
|
sourceRect.width / 2
|
|
161
161
|
);
|
|
162
|
-
const panelStyle = getComputedStyle(panelEl);
|
|
163
|
-
const panelPadding = Math.min(parsePx(panelStyle.paddingTop), parsePx(panelStyle.paddingLeft));
|
|
164
162
|
const panelRect = panelEl.getBoundingClientRect();
|
|
163
|
+
const insetTop = Math.max(0, sourceRect.top - panelRect.top);
|
|
164
|
+
const insetLeft = Math.max(0, sourceRect.left - panelRect.left);
|
|
165
|
+
const sourceInset = Math.min(insetTop, insetLeft);
|
|
165
166
|
const panelRadius = Math.min(
|
|
166
|
-
Math.max(0, effectiveSourceRadius +
|
|
167
|
+
Math.max(0, effectiveSourceRadius + sourceInset),
|
|
167
168
|
panelRect.height / 2,
|
|
168
169
|
panelRect.width / 2
|
|
169
170
|
);
|