import React, { type ReactNode, type HTMLAttributes } from 'react';
export type ScrollWrapperProps = HTMLAttributes & {
/**
* Contents of the wrapper element
*/
children: ReactNode;
/**
* CSS class names that can be appended to the component.
*/
className?: string;
/**
* Determines the direction that the shadows apply
*/
orientation?: 'horizontal' | 'vertical';
/**
* Type of shadow treatment for the wrapper:
* - **cover** - full-width shadow in the wrapper based on shadow context
* - **contain** - shadow whose edges fit within the width of the wrapper
*/
shadowType?: 'cover' | 'contain';
};
type ShadowStates = {
top: boolean;
bottom: boolean;
start: boolean;
end: boolean;
};
export declare const setShadowStates: (targetData: HTMLDivElement) => ShadowStates;
/**
* ## Usage
*
* Wrap content that has a fixed height but is scrollable, so that users have an indication that
* more content is available. Subtle shadows come in several variants.
*
* | Type/Use | Description | Example |
* |----------|-------------|---------|
* | Vertical | The default. Scrolls on the y axis and shades the top and bottom edges. | Long dialog bodies. Tall option lists. |
* | Horizontal | `orientation="horizontal"` scrolls on the x axis and shades the start and end edges. | Wide tables. Toolbars that overflow. |
*
* `orientation` picks one axis at a time, so a single wrapper shades either the vertical or the
* horizontal edges, not both.
*
* `shadowType` controls the treatment: `cover` (the default) spans the full width of the wrapper,
* while `contain` keeps the shadow's edges inside it.
*
* The effect depends on the container being shorter than its content, so the element above the
* scroll wrapper must have a fixed height. Without that, nothing overflows and no shadow appears.
*
* ## Interaction
*
* Shadows are set for the starting position as soon as the wrapper mounts, so content that
* overflows shows its bottom (or end) shadow before any scrolling.
*
* When vertical, scrolling will enable both shadows when there is more content above and below the
* current position. When there is only content above the current position (scrolled to the end of
* the container), only the top shadow is shown. When scrolled to the very top of the container,
* only the bottom shadow is shown. The same logic applies to the horizontal scrolling scenario,
* against the start and end edges.
*
* `Modal` renders a `ScrollWrapper` around its body for you, so its content scrolls without any
* extra setup.
*
* ## Content & Accessibility
*
* ### Do's
*
* * Use `ScrollWrapper` in any overlay components that need to exceed the available screen real estate. This is not for ones that definitely will, but ones that have variable content which could grow to be either too tall or too wide.
* * Use `cover` for the shadow type to emphasize and make clear that more content is available.
* * Leave the scrollable region in the tab order. It carries `tabIndex={0}` so that people navigating by keyboard can scroll it.
*
* ### Don'ts
*
* * Avoid wrapping entire pages with `ScrollWrapper`.
* * Never use multiple, adjacent `ScrollWrapper` instances.
*/
export declare const ScrollWrapper: {
({ children, className, orientation, shadowType, ...other }: ScrollWrapperProps): React.JSX.Element;
displayName: string;
};
export {};