New source found from dndbeyond.com
This commit is contained in:
+2
-2
@@ -183,8 +183,8 @@ function uniqueId(prefix) {
|
||||
}
|
||||
|
||||
// index.tsx
|
||||
var mask_default = Mask_default;
|
||||
var index_default = Mask_default;
|
||||
export {
|
||||
Mask_default as Mask,
|
||||
mask_default as default
|
||||
index_default as default
|
||||
};
|
||||
|
||||
+14
-15
@@ -1,6 +1,4 @@
|
||||
var __defProp = Object.defineProperty;
|
||||
var __defProps = Object.defineProperties;
|
||||
var __getOwnPropDescs = Object.getOwnPropertyDescriptors;
|
||||
var __getOwnPropSymbols = Object.getOwnPropertySymbols;
|
||||
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
||||
var __propIsEnum = Object.prototype.propertyIsEnumerable;
|
||||
@@ -16,7 +14,6 @@ var __spreadValues = (a, b) => {
|
||||
}
|
||||
return a;
|
||||
};
|
||||
var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
||||
var __objRest = (source, exclude) => {
|
||||
var target = {};
|
||||
for (var prop in source)
|
||||
@@ -89,10 +86,11 @@ var Popover = (_a) => {
|
||||
const getStyles = stylesMatcher(styles);
|
||||
const helperRect = useRect(helperRef, refresher);
|
||||
const { width: helperWidth, height: helperHeight } = helperRect;
|
||||
const targetLeft = sizes == null ? void 0 : sizes.left;
|
||||
const targetTop = sizes == null ? void 0 : sizes.top;
|
||||
const targetRight = sizes == null ? void 0 : sizes.right;
|
||||
const targetBottom = sizes == null ? void 0 : sizes.bottom;
|
||||
const [pt, pr, pb, pl] = getPadding(padding);
|
||||
const targetLeft = (sizes == null ? void 0 : sizes.left) - pl;
|
||||
const targetTop = (sizes == null ? void 0 : sizes.top) - pt;
|
||||
const targetRight = (sizes == null ? void 0 : sizes.right) + pr;
|
||||
const targetBottom = (sizes == null ? void 0 : sizes.bottom) + pb;
|
||||
const position = providedPosition && typeof providedPosition === "function" ? providedPosition(
|
||||
{
|
||||
width: helperWidth,
|
||||
@@ -114,7 +112,6 @@ var Popover = (_a) => {
|
||||
top: targetTop,
|
||||
bottom: windowHeight - targetBottom
|
||||
};
|
||||
const [pt, pr, pb, pl] = getPadding(padding);
|
||||
const couldPositionAt = (position2, isOutsideX2, isOutsideY2) => {
|
||||
switch (position2) {
|
||||
case "top":
|
||||
@@ -195,13 +192,15 @@ var Popover = (_a) => {
|
||||
"div",
|
||||
__spreadValues({
|
||||
className: "reactour__popover",
|
||||
style: __spreadProps(__spreadValues({}, getStyles("popover", {
|
||||
style: __spreadValues({
|
||||
transform: `translate(${Math.round(p[0])}px, ${Math.round(p[1])}px)`
|
||||
}, getStyles("popover", {
|
||||
position: positionRef.current,
|
||||
verticalAlign: verticalAlignRef.current,
|
||||
horizontalAlign: horizontalAlignRef.current
|
||||
})), {
|
||||
transform: `translate(${Math.round(p[0])}px, ${Math.round(p[1])}px)`
|
||||
}),
|
||||
horizontalAlign: horizontalAlignRef.current,
|
||||
helperRect,
|
||||
targetRect: sizes
|
||||
})),
|
||||
ref: helperRef
|
||||
}, props),
|
||||
children
|
||||
@@ -210,8 +209,8 @@ var Popover = (_a) => {
|
||||
var Popover_default = Popover;
|
||||
|
||||
// index.tsx
|
||||
var popover_default = Popover_default;
|
||||
var index_default = Popover_default;
|
||||
export {
|
||||
Popover_default as Popover,
|
||||
popover_default as default
|
||||
index_default as default
|
||||
};
|
||||
|
||||
+4
-6
@@ -86,8 +86,7 @@ function useSizes(step, scrollOptions = {
|
||||
if (!isInView && target) {
|
||||
setTransition(true);
|
||||
smoothScroll(target, scrollOptions).then(() => {
|
||||
if (!observing)
|
||||
setRefresher(Date.now());
|
||||
if (!observing) setRefresher(Date.now());
|
||||
}).finally(() => {
|
||||
setTransition(false);
|
||||
});
|
||||
@@ -506,8 +505,7 @@ var Navigation = ({
|
||||
disabled: disableDots || disableAll
|
||||
}),
|
||||
onClick: () => {
|
||||
if (!disableDots && !disableAll)
|
||||
setCurrentStep(index);
|
||||
if (!disableDots && !disableAll) setCurrentStep(index);
|
||||
},
|
||||
key: `navigation_dot_${index}`,
|
||||
"aria-label": ((_a = steps[index]) == null ? void 0 : _a.navDotAriaLabel) || `Go to step ${index + 1}`
|
||||
@@ -966,13 +964,13 @@ function withTour(WrappedComponent) {
|
||||
}
|
||||
|
||||
// index.tsx
|
||||
var tour_default = Tour_default;
|
||||
var index_default = Tour_default;
|
||||
export {
|
||||
Tour_default as Tour,
|
||||
Context_default as TourContext,
|
||||
TourProvider,
|
||||
components,
|
||||
tour_default as default,
|
||||
index_default as default,
|
||||
useTour,
|
||||
withTour
|
||||
};
|
||||
|
||||
+4
-8
@@ -35,8 +35,7 @@ var Observables = ({
|
||||
const found = resizeObservables.find(
|
||||
(observable) => node.matches(observable)
|
||||
);
|
||||
if (found)
|
||||
setMutationsCounter(mutationsCounter + 1);
|
||||
if (found) setMutationsCounter(mutationsCounter + 1);
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -90,8 +89,7 @@ function getRect(element) {
|
||||
function useRect(ref, refresher) {
|
||||
const [dimensions, setDimensions] = useState2(initialState);
|
||||
const handleResize = useCallback(() => {
|
||||
if (!(ref == null ? void 0 : ref.current))
|
||||
return;
|
||||
if (!(ref == null ? void 0 : ref.current)) return;
|
||||
setDimensions(getRect(ref == null ? void 0 : ref.current));
|
||||
}, [ref == null ? void 0 : ref.current]);
|
||||
useEffect2(() => {
|
||||
@@ -104,8 +102,7 @@ function useRect(ref, refresher) {
|
||||
function useElemRect(elem, refresher) {
|
||||
const [dimensions, setDimensions] = useState2(initialState);
|
||||
const handleResize = useCallback(() => {
|
||||
if (!elem)
|
||||
return;
|
||||
if (!elem) return;
|
||||
setDimensions(getRect(elem));
|
||||
}, [elem]);
|
||||
useEffect2(() => {
|
||||
@@ -168,8 +165,7 @@ function useIntersectionObserver(elementRef, {
|
||||
useEffect3(() => {
|
||||
const node = elementRef == null ? void 0 : elementRef.current;
|
||||
const hasIOSupport = !!window.IntersectionObserver;
|
||||
if (!hasIOSupport || frozen || !node)
|
||||
return;
|
||||
if (!hasIOSupport || frozen || !node) return;
|
||||
const observerParams = { threshold, root, rootMargin };
|
||||
const observer = new IntersectionObserver(updateEntry, observerParams);
|
||||
observer.observe(node);
|
||||
|
||||
Reference in New Issue
Block a user