mirror of
https://github.com/d0zingcat/NotionNext.git
synced 2026-06-04 15:10:23 +00:00
new-theme-plog
This commit is contained in:
23
themes/plog/components/InformationButton.js
Normal file
23
themes/plog/components/InformationButton.js
Normal file
@@ -0,0 +1,23 @@
|
||||
import { InformationCircle } from '@/components/HeroIcons'
|
||||
import SlideOvers from './SlideOvers'
|
||||
import { useRef } from 'react'
|
||||
|
||||
/**
|
||||
* 显示网站用户信息按钮
|
||||
* @returns
|
||||
*/
|
||||
export default function InformationButton() {
|
||||
const slideOversRef = useRef({})
|
||||
const toggleCollapsed = () => {
|
||||
console.log(slideOversRef)
|
||||
slideOversRef.current.toggleSlideOvers()
|
||||
}
|
||||
|
||||
return <>
|
||||
<div className='cursor-pointer' onClick={toggleCollapsed}>
|
||||
<InformationCircle className={'w-5 h-5'} />
|
||||
</div>
|
||||
|
||||
<SlideOvers cRef={slideOversRef} />
|
||||
</>
|
||||
}
|
||||
Reference in New Issue
Block a user