diff --git a/apps/builder/src/components/combobox.tsx b/apps/builder/src/components/combobox.tsx index e77c4a49f..3fbea883e 100644 --- a/apps/builder/src/components/combobox.tsx +++ b/apps/builder/src/components/combobox.tsx @@ -20,7 +20,11 @@ const Root = forwardRef>( gutter: 4, placement: "bottom-start", }} - className={cn(props.className, colorMode === "dark" && "dark")} + className={cn( + "items-start", + props.className, + colorMode === "dark" && "dark", + )} /> ); }, @@ -34,8 +38,14 @@ const Label = forwardRef( Label.displayName = ArkCombobox.Label.displayName; const Control = forwardRef( - (props, ref) => { - return ; + ({ className, ...props }, ref) => { + return ( + + ); }, ); Control.displayName = ArkCombobox.Control.displayName; diff --git a/apps/builder/src/features/forge/components/ForgeAutocompleteInput.tsx b/apps/builder/src/features/forge/components/ForgeAutocompleteInput.tsx index 9ebb23662..35443074a 100644 --- a/apps/builder/src/features/forge/components/ForgeAutocompleteInput.tsx +++ b/apps/builder/src/features/forge/components/ForgeAutocompleteInput.tsx @@ -1,6 +1,7 @@ import { MoreInfoTooltip } from "@/components/MoreInfoTooltip"; import { Combobox } from "@/components/combobox"; import { Field } from "@/components/field"; +import { useParentModal } from "@/features/graph/providers/ParentModalProvider"; import { VariablesButton } from "@/features/variables/components/VariablesButton"; import { useDebounce } from "@/hooks/useDebounce"; import { useInjectableInputValue } from "@/hooks/useInjectableInputValue"; @@ -66,6 +67,7 @@ export const AutocompleteInput = ({ items: Item[] | undefined; }) => { const inputRef = useRef(null); + const { ref: parentModalRef } = useParentModal(); const { value: inputValue, setValue: setInputValue, @@ -124,7 +126,7 @@ export const AutocompleteInput = ({ )} )} -
+
@@ -138,7 +140,7 @@ export const AutocompleteInput = ({ )}
- + {filteredCollection.size > 0 && (filteredCollection.size > 1 || diff --git a/apps/builder/src/features/graph/components/ZoomButtons.tsx b/apps/builder/src/features/graph/components/ZoomButtons.tsx index e2c09ae05..cd3aa7f59 100644 --- a/apps/builder/src/features/graph/components/ZoomButtons.tsx +++ b/apps/builder/src/features/graph/components/ZoomButtons.tsx @@ -16,7 +16,6 @@ export const ZoomButtons = ({ right="40px" bgColor={useColorModeValue("white", "gray.950")} rounded="md" - zIndex={1} spacing="0" shadow="md" > diff --git a/apps/builder/src/features/graph/components/nodes/block/SettingsModal.tsx b/apps/builder/src/features/graph/components/nodes/block/SettingsModal.tsx index c4cec0678..ce94a1a58 100644 --- a/apps/builder/src/features/graph/components/nodes/block/SettingsModal.tsx +++ b/apps/builder/src/features/graph/components/nodes/block/SettingsModal.tsx @@ -1,40 +1,30 @@ import { useParentModal } from "@/features/graph/providers/ParentModalProvider"; -import { - Modal, - ModalBody, - type ModalBodyProps, - ModalCloseButton, - ModalContent, - ModalFooter, - ModalHeader, - ModalOverlay, -} from "@chakra-ui/react"; +import { Portal } from "@ark-ui/react"; +import { Dialog } from "@ark-ui/react/dialog"; +import { dialogClassNames } from "@typebot.io/ui/components/Dialog"; import type React from "react"; type Props = { isOpen: boolean; onClose: () => void; + children: React.ReactNode; }; -export const SettingsModal = ({ - isOpen, - onClose, - ...props -}: Props & ModalBodyProps) => { +export const SettingsModal = ({ isOpen, onClose, children }: Props) => { const { ref } = useParentModal(); - const handleMouseDown = (e: React.MouseEvent) => { - e.stopPropagation(); - }; return ( - - - - - - - {props.children} - - - + (e.open ? undefined : onClose())} + > + + + + + {children} + + + + ); }; diff --git a/apps/landing-page/app/features/pricing/TiersDialog.tsx b/apps/landing-page/app/features/pricing/TiersDialog.tsx index f67266784..5247021a8 100644 --- a/apps/landing-page/app/features/pricing/TiersDialog.tsx +++ b/apps/landing-page/app/features/pricing/TiersDialog.tsx @@ -11,6 +11,7 @@ import { import { Dialog, Portal } from "@ark-ui/react"; import { proChatTiers } from "@typebot.io/billing/constants"; import { formatPrice } from "@typebot.io/billing/helpers/formatPrice"; +import { dialogClassNames } from "@typebot.io/ui/components/Dialog"; import { CloseIcon } from "@typebot.io/ui/icons/CloseIcon"; export const TiersDialog = ({ @@ -22,10 +23,12 @@ export const TiersDialog = ({ }) => ( (!e.open ? onClose() : null)}> - - - - Chats pricing table + + + + + Chats pricing table +