UNPKG

@bothub-chat/ui

Version:

Bothub UI Components

23 lines (22 loc) 2.82 kB
import{styled as t,css as e}from"styled-components";import{animated as o}from"@react-spring/web";import{ScrollableTabs as i}from"../../scrollable-tabs/index.js";import{TextField as a}from"../../text-field/index.js";const n=t(o.div).withConfig({displayName:"styled__SelectModalStyled",componentId:"sc-6z9s36-0"})(["display:flex;position:absolute;z-index:",";width:","px;min-width:200px;width:100%;box-sizing:border-box;transition:opacity 0.2s;"," ",""],({theme:t})=>t.zIndex.select,({$contentWidth:t})=>t,({$disablePortal:t,$placement:o})=>{if(t)switch(o){case"bottom-center":case"bottom-left":return e` top: unset !important; left: 0 !important; bottom: 0 !important; right: unset !important; `;default:return e` top: unset !important; left: 0 !important; bottom: 100% !important; right: unset !important; `}},({$isOpen:t})=>!t&&e` opacity: 0; pointer-events: none; `),d=t.div.withConfig({displayName:"styled__SelectModalPositionWrapper",componentId:"sc-6z9s36-1"})(["display:flex;position:absolute;",";box-sizing:border-box;padding:6px 0 6px 8px;border:1px solid ",";border-radius:10px;background:",";backdrop-filter:blur(16px);-webkit-backdrop-filter:blur(16px);",""],({$width:t,$compactWidth:o})=>!o&&e` width: ${t||"100%"}; `,({theme:t})=>t.colors.grayScale.gray2,({theme:t,$blur:e})=>e?"light"===t.mode?"rgba(255, 255, 255, 0.65)":"rgba(18, 24, 37, 0.75)":"light"===t.mode?t.default.colors.base.white:t.colors.grayScale.gray4,({$placement:t})=>t.includes("top")?e` bottom: 0px; margin-bottom: 10px; `:e` top: 0px; margin-top: 10px; `),s=t.div.withConfig({displayName:"styled__SelectModalContent",componentId:"sc-6z9s36-2"})(["display:flex;width:100%;"]),l=t.div.withConfig({displayName:"styled__SelectModalGroups",componentId:"sc-6z9s36-3"})(["display:flex;flex-direction:column;align-items:flex-start;width:100%;gap:","px;"],({$size:t})=>{switch(t){case"small":return 4;case"md":return 6;case"large":return 8}}),r=t.div.withConfig({displayName:"styled__SelectModalTabsContainer",componentId:"sc-6z9s36-4"})(["width:100%;padding-right:8px;"]),p=t(i).attrs({variant:"secondary",component:"button"}).withConfig({displayName:"styled__SelectModalTabs",componentId:"sc-6z9s36-5"})([""]),c=t(a).attrs({fullWidth:!0,variant:"secondary"}).withConfig({displayName:"styled__SelectModalSearch",componentId:"sc-6z9s36-6"})(["padding-right:8px;"]),m=t.div.withConfig({displayName:"styled__SelectModalAfter",componentId:"sc-6z9s36-7"})(["width:calc(100% - 6px);"]);export{m as SelectModalAfter,s as SelectModalContent,l as SelectModalGroups,d as SelectModalPositionWrapper,c as SelectModalSearch,n as SelectModalStyled,p as SelectModalTabs,r as SelectModalTabsContainer};