Skip to content

Commit 0d0c550

Browse files
committed
amend
1 parent 036368f commit 0d0c550

File tree

12 files changed

+220
-19
lines changed

12 files changed

+220
-19
lines changed

dist/index.d.ts

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,3 @@
1-
export { default } from './lib/test';
2-
export * from './lib/test';
1+
export { default } from './lib/ReactScrollDetect';
2+
export * from './lib/ReactScrollDetect';
3+
export * from './lib/DetectSection';

dist/index.es.js

Lines changed: 94 additions & 5 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

dist/index.es.js.map

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

dist/index.js

Lines changed: 95 additions & 5 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

dist/index.js.map

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

dist/lib/DetectSection.d.ts

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
import React from "react";
2+
export declare const DetectSection: React.FC;

dist/lib/ReactScrollDetect.d.ts

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
import { FC } from 'react';
2+
export interface ReactScrollDetectProps {
3+
onChange?: (index: number) => void;
4+
index?: number;
5+
}
6+
declare const ReactScrollDetect: FC<ReactScrollDetectProps>;
7+
export default ReactScrollDetect;

dist/lib/context.d.ts

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
/// <reference types="react" />
2+
export declare type TSectionEntry = {
3+
height: number;
4+
index: number;
5+
};
6+
export declare type ReactScrollDetectContextProviderValue = {
7+
onChange: (index: number) => void;
8+
addSection: (section: TSectionEntry) => void;
9+
sections: TSectionEntry[];
10+
index: number;
11+
};
12+
export declare const ReactScrollDetectContext: import("react").Context<ReactScrollDetectContextProviderValue>;

dist/lib/test.d.ts

Lines changed: 0 additions & 3 deletions
This file was deleted.

src/index.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
export { default } from './lib/ReactScrollDetect';
2-
export * from './lib/types';
2+
export * from './lib/ReactScrollDetect';
33
export * from './lib/DetectSection';
44

0 commit comments

Comments
 (0)