6.0.6 • Published 6 months ago

@types/react-sticky v6.0.6

Weekly downloads
27,669
License
MIT
Repository
github
Last release
6 months ago

Installation

npm install --save @types/react-sticky

Summary

This package contains type definitions for react-sticky (https://github.com/captivationsoftware/react-sticky).

Details

Files were exported from https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/react-sticky.

index.d.ts

// Type definitions for react-sticky 6.0
// Project: https://github.com/captivationsoftware/react-sticky
// Definitions by: Matej Lednicky <http://www.thinkcreatix.com/>,
//                 Curtis Warren <https://github.com/curtisw0>,
//                 Andrew Hyndman <https://github.com/ajhyndman>
// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped
// TypeScript Version: 2.8

import * as React from "react";

export const StickyContainer: React.ComponentClass<
    React.HTMLAttributes<HTMLDivElement>
>;

export interface StickyChildArgs {
    style: React.CSSProperties;
    isSticky: boolean;
    wasSticky: boolean;
    distanceFromTop: number;
    distanceFromBottom: number;
    calculatedHeight: number;
}

export interface StickyProps {
    children: (args: StickyChildArgs) => React.ReactElement;
    relative?: boolean | undefined;
    isActive?: boolean | undefined;
    className?: string | undefined;
    style?: any;
    stickyClassName?: string | undefined;
    stickyStyle?: any;
    topOffset?: number | undefined;
    bottomOffset?: number | undefined;
    onStickyStateChange?(isSticky: boolean): void;
    disableCompensation?: boolean | undefined;
    disableHardwareAcceleration?: boolean | undefined;
}

export const Sticky: React.ComponentClass<StickyProps>;

Additional Details

  • Last updated: Wed, 07 Jul 2021 18:31:45 GMT
  • Dependencies: @types/react
  • Global values: none

Credits

These definitions were written by Matej Lednicky, Curtis Warren, and Andrew Hyndman.

6.0.5

7 months ago

6.0.6

6 months ago

6.0.4

3 years ago

6.0.3

5 years ago

6.0.2

6 years ago

6.0.1

6 years ago

6.0.0

6 years ago

5.0.6

6 years ago

5.0.5

7 years ago

5.0.4

7 years ago

5.0.3

7 years ago

5.0.2

7 years ago

5.0.1

7 years ago

5.0.0

7 years ago