react live island
1.0.0
链接在线链接到小部件,您的在线主屏幕。 ➫? kee.so
经过 ? kee.so
动态岛? ⚛️反应
pnpm add react-live-island
# or
yarn add react-live-island
# or
npm i react-live-island
import LiveIsland from 'react-live-island' ;
const Demo = ( ) => {
return < LiveIsland > { ( isSmall ) => ( isSmall ? 'small' : 'large' ) } < / LiveIsland > ;
} ;
支柱 | 类型 | 默认 | 描述 |
---|---|---|---|
className | string | '' | 该岛的班级名称 |
top | number|string | 10 | 岛上的埃格德 |
smallClassName | string | '' | 小岛的班级名称 |
smallWidth | number|string | 96 | 小岛的宽度 |
smallHeight | number|string | 30 | 小岛的高度 |
largeClassName | string | '' | 大岛的班级名称 |
largeWidth | number|string | 400 | wid |
largeHeight | number|string | 180 | 大岛的高度 |
largeRadius | number|string | 36 | 边界半径 |
wrapperClassName | string | '' | 整个容器的班级名称 |
triggerType | 'click'|'hover' | 'click' | 打开的触发模式 |
initialAnimation | boolean | false | 是否在输入中显示动画 |
onChange | (isSmall: boolean) => void | - | 岛上开放和关闭时致电 |
children | (isSmall: boolean) => ReactNode | - | 渲染函数以定义岛屿的内容 |
麻省理工学院许可(C)Nanxiaobei