Rocky_Mountain_Vending/.pnpm-store/v10/files/61/4629efa57c19336f7a8c7f14e8561394c77a2f599063b12931d4ea94849ee5643fec40509f2eec484292bebbae18c5a9140c3d2e735fd9b59c767f3c1370ad
DMleadgen 46d973904b
Initial commit: Rocky Mountain Vending website
Next.js website for Rocky Mountain Vending company featuring:
- Product catalog with Stripe integration
- Service areas and parts pages
- Admin dashboard with Clerk authentication
- SEO optimized pages with JSON-LD structured data

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-02-12 16:22:15 -07:00

41 lines
1.7 KiB
Text

import * as React from 'react';
import { fullWidthClassName, zeroRightClassName } from 'react-remove-scroll-bar/constants';
import { useMergeRefs } from 'use-callback-ref';
import { effectCar } from './medium';
const nothing = () => {
return;
};
/**
* Removes scrollbar from the page and contain the scroll within the Lock
*/
const RemoveScroll = React.forwardRef((props, parentRef) => {
const ref = React.useRef(null);
const [callbacks, setCallbacks] = React.useState({
onScrollCapture: nothing,
onWheelCapture: nothing,
onTouchMoveCapture: nothing,
});
const { forwardProps, children, className, removeScrollBar, enabled, shards, sideCar, noRelative, noIsolation, inert, allowPinchZoom, as: Container = 'div', gapMode, ...rest } = props;
const SideCar = sideCar;
const containerRef = useMergeRefs([ref, parentRef]);
const containerProps = {
...rest,
...callbacks,
};
return (React.createElement(React.Fragment, null,
enabled && (React.createElement(SideCar, { sideCar: effectCar, removeScrollBar: removeScrollBar, shards: shards, noRelative: noRelative, noIsolation: noIsolation, inert: inert, setCallbacks: setCallbacks, allowPinchZoom: !!allowPinchZoom, lockRef: ref, gapMode: gapMode })),
forwardProps ? (React.cloneElement(React.Children.only(children), {
...containerProps,
ref: containerRef,
})) : (React.createElement(Container, { ...containerProps, className: className, ref: containerRef }, children))));
});
RemoveScroll.defaultProps = {
enabled: true,
removeScrollBar: true,
inert: false,
};
RemoveScroll.classNames = {
fullWidth: fullWidthClassName,
zeroRight: zeroRightClassName,
};
export { RemoveScroll };