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