mirror of
https://github.com/muerwre/vault-frontend.git
synced 2025-04-26 05:16:41 +07:00
refactor editos
This commit is contained in:
parent
03ddb1862c
commit
5e9c111e0f
149 changed files with 416 additions and 317 deletions
15
src/components/common/Sticky/index.tsx
Normal file
15
src/components/common/Sticky/index.tsx
Normal file
|
@ -0,0 +1,15 @@
|
|||
import React, { DetailsHTMLAttributes, FC } from 'react';
|
||||
|
||||
import StickyBox from 'react-sticky-box';
|
||||
|
||||
interface IProps extends DetailsHTMLAttributes<HTMLDivElement> {
|
||||
offsetTop?: number;
|
||||
}
|
||||
|
||||
const Sticky: FC<IProps> = ({ children, offsetTop = 65 }) => (
|
||||
<StickyBox offsetTop={offsetTop} offsetBottom={10}>
|
||||
{children}
|
||||
</StickyBox>
|
||||
);
|
||||
|
||||
export { Sticky };
|
Loading…
Add table
Add a link
Reference in a new issue