amotify
Version:
UI Component for React,NextJS,esbuild
2 lines (1 loc) • 704 B
JavaScript
import{b as t,c as l,d as p}from"../chunk-C5N2D3ZX.js";import{jsx as o}from"react/jsx-runtime";import{useEffect as s}from"react";import{Box as c,Flex as x}from"../atoms";import S from"./Input";const m=f=>{let i=f,{tabIndex:u,tabs:b,onTabChange:a,componentDidMount:n}=i,r=p(i,["tabIndex","tabs","onTabChange","componentDidMount"]);return s(()=>{n&&n()},[]),o(x,l(t({position:"relative",overflow:"auto",flexWrap:!1},r),{freeCSS:t({zIndex:3,whiteSpace:"nowrap"},r.freeCSS),children:o(c,{margin:[0,"auto"],children:o(S.Segmented.Bottomline,{value:u,fontColor:"inherit",gap:0,override:"force",options:b.map((e,d)=>({value:d,label:e})),onUpdateValidValue:e=>{a&&a(e)}})})}))};export{m as TabBar,m as default};