mirror of
				https://github.com/yudejp/yude.jp.git
				synced 2025-11-04 00:36:01 +00:00 
			
		
		
		
	Sticky tab
This commit is contained in:
		
							parent
							
								
									56d18f25b4
								
							
						
					
					
						commit
						65dd7bf23c
					
				@ -77,7 +77,7 @@ export default function App() {
 | 
			
		||||
                  <div className="hidden md:block md:col-span-1">
 | 
			
		||||
                    <VerticalMenu />
 | 
			
		||||
                  </div>
 | 
			
		||||
                  <div className="block md:hidden">
 | 
			
		||||
                  <div className="sticky top-5 md:hidden">
 | 
			
		||||
                    <HorizontalMenu />
 | 
			
		||||
                  </div>
 | 
			
		||||
                  <div className="px-5 md:col-span-4 md:px-0">
 | 
			
		||||
 | 
			
		||||
@ -140,7 +140,7 @@ export default function Chat() {
 | 
			
		||||
                </button>
 | 
			
		||||
            </div>
 | 
			
		||||
 | 
			
		||||
            <div className="overflow-auto max-h-96 mt-5 rounded-lg max-w-xl">
 | 
			
		||||
            <div className="overflow-auto h-96 mt-5 rounded-lg max-w-xl">
 | 
			
		||||
            {
 | 
			
		||||
                messages &&
 | 
			
		||||
                messages.map((message, index) => {
 | 
			
		||||
 | 
			
		||||
@ -16,7 +16,7 @@ export default function HorizontalMenu() {
 | 
			
		||||
 | 
			
		||||
    return (
 | 
			
		||||
      <RecoilRoot>
 | 
			
		||||
        <div className="text-lg font-medium text-center hover:cursor-pointer grid grid-cols-5 grid-flow-col">
 | 
			
		||||
        <div className="relative text-lg font-medium text-center hover:cursor-pointer grid grid-cols-5 grid-flow-col backdrop-blur-2xl bg-zinc-100/30 dark:bg-neutral-900/30 rounded-lg">
 | 
			
		||||
            <div
 | 
			
		||||
                className={`self-start py-3 rounded-lg${page === Pages.Profile ? activeColor : ""}`}
 | 
			
		||||
                onClick={() => {setPage(Pages.Profile)}}
 | 
			
		||||
 | 
			
		||||
@ -9,7 +9,7 @@ export default function Profile() {
 | 
			
		||||
 | 
			
		||||
            <ol className="relative border-s border-gray-700 left-2">                  
 | 
			
		||||
                <li className="mb-2 ms-4">
 | 
			
		||||
                    <div className="absolute w-3 h-3 bg-gray-200 rounded-full mt-1.5 -start-1.5 border border-gray-900 bg-gray-700"></div>
 | 
			
		||||
                    <div className="absolute w-3 h-3 rounded-full mt-1.5 -start-1.5 border border-gray-900 bg-gray-700"></div>
 | 
			
		||||
                    <time className="mb-1 text-sm font-normal leading-none dark:text-gray-400">
 | 
			
		||||
                        2020 年 4 月 – 現在
 | 
			
		||||
                    </time>
 | 
			
		||||
 | 
			
		||||
@ -25,7 +25,8 @@ export default function VerticalMenu() {
 | 
			
		||||
 | 
			
		||||
    return (
 | 
			
		||||
      <RecoilRoot>
 | 
			
		||||
        <ul className="w-full text-lg font-medium text-center hover:cursor-pointer">
 | 
			
		||||
        <div className="sticky top-5">
 | 
			
		||||
            <ul className="text-lg font-medium text-center hover:cursor-pointer">
 | 
			
		||||
                <li
 | 
			
		||||
                    className={`w-full px-4 py-2 rounded-lg${page === Pages.Profile ? activeColor : ""}`}
 | 
			
		||||
                    onClick={() => {setPage(Pages.Profile)}}
 | 
			
		||||
@ -62,6 +63,7 @@ export default function VerticalMenu() {
 | 
			
		||||
                    <p>チャット</p>
 | 
			
		||||
                </li>
 | 
			
		||||
            </ul>
 | 
			
		||||
        </div>
 | 
			
		||||
      </RecoilRoot>
 | 
			
		||||
    )
 | 
			
		||||
  }
 | 
			
		||||
 | 
			
		||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user