Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@
},
"dependencies": {
"@tanstack/react-query": "^5.83.0",
"attio": "0.0.1-experimental.20250829.2",
"attio": "0.0.1-experimental.20250915",
"event-target-polyfill": "^0.0.4",
"match-sorter": "8.0.3",
"react": "19.0.0",
Expand Down
16 changes: 3 additions & 13 deletions src/components/comboboxes/companies-combobox.tsx
Original file line number Diff line number Diff line change
@@ -1,31 +1,21 @@
import type {FormApi} from "attio/client"
import type {LogCustomerRequestFormSchema} from "../log-customer-request-dialog"
import {companiesProvider} from "./companies-options-provider"

export function CompaniesCombobox({
Combobox,
companyId,
}: {
Combobox: FormApi<LogCustomerRequestFormSchema>["Combobox"]
Combobox: FormApi<LogCustomerRequestFormSchema>["Experimental_RecordCombobox"]
companyId?: string
}) {
if (companyId) {
return (
<Combobox
label="Company"
name="companyRecordId"
options={companiesProvider}
__experimental_decorated
disabled
/>
)
return <Combobox label="Company" name="companyRecordId" recordTypes="company" disabled />
}
return (
<Combobox
label="Company"
name="companyRecordId"
__experimental_decorated
options={companiesProvider}
recordTypes="company"
placeholder="Select a company..."
searchPlaceholder="Search companies..."
/>
Expand Down
33 changes: 0 additions & 33 deletions src/components/comboboxes/companies-options-provider.ts

This file was deleted.

27 changes: 17 additions & 10 deletions src/components/log-customer-request-dialog.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -33,15 +33,22 @@ export function LogCustomerRequestDialog({
attachmentUrl?: string
onDone: () => void
}) {
const {Form, TextInput, SubmitButton, Combobox, Experimental_RichTextInput, WithState} =
useForm(formSchema, {
companyRecordId,
description,
addTo: "",
title: "",
team: "",
attachmentUrl,
})
const {
Form,
TextInput,
SubmitButton,
Combobox,
Experimental_RichTextInput,
WithState,
Experimental_RecordCombobox,
} = useForm(formSchema, {
companyRecordId,
description,
addTo: "",
title: "",
team: "",
attachmentUrl,
})
return (
<Form
onSubmit={async (values) => {
Expand Down Expand Up @@ -89,7 +96,7 @@ export function LogCustomerRequestDialog({
}
}}
>
<CompaniesCombobox Combobox={Combobox} companyId={companyRecordId} />
<CompaniesCombobox Combobox={Experimental_RecordCombobox} companyId={companyRecordId} />

<Experimental_RichTextInput
label="Customer request details"
Expand Down