Interface: CompanySwitcherProps
Defined in: components/CompanySwitcher.tsx:15
Properties
graphqlClient?
optionalgraphqlClient?:GraphQLClient
Defined in: components/CompanySwitcher.tsx:20
GraphQL client for the Propeller SDK
icon?
optionalicon?:string
Defined in: components/CompanySwitcher.tsx:23
Icon identifier for the company switcher trigger button.
Default
'default-company-switch-icon'
labels?
optionallabels?:Record<string,string>
Defined in: components/CompanySwitcher.tsx:33
Translated labels keyed by the slugs used inside the component (see
getLabel calls). Missing keys fall back to the English defaults.
onCompanyChange
onCompanyChange: (
company) =>void
Defined in: components/CompanySwitcher.tsx:29
Callback fired when the user selects a company.
Parameters
company
Company
Returns
void
selectedCompanyId?
optionalselectedCompanyId?:number
Defined in: components/CompanySwitcher.tsx:26
Currently selected company ID (from CompanyContext). Syncs the switcher with external state.
user
user:
Contact
Defined in: components/CompanySwitcher.tsx:17
The contact to whom the companies are assigned. Default company is user.company, all companies are in user.companies.