e995e84621
https://github.com/user-attachments/assets/09550210-76c5-4a40-83b6-9ab785ca10c3 https://github.com/user-attachments/assets/352427fc-0a2a-4f1b-86e9-db99daea0018 --------- Co-authored-by: Félix Malfait <felix.malfait@gmail.com> Co-authored-by: Félix Malfait <felix@twenty.com>
11 lines
394 B
TypeScript
11 lines
394 B
TypeScript
import { COMPOSITE_FIELD_TYPE_SUB_FIELDS_NAMES } from 'twenty-shared/constants';
|
|
import { type FieldMetadataType } from 'twenty-shared/types';
|
|
|
|
const compositeSubFieldMaps = COMPOSITE_FIELD_TYPE_SUB_FIELDS_NAMES as Record<
|
|
string,
|
|
Record<string, string>
|
|
>;
|
|
|
|
export const getCompositeSubfieldNames = (fieldType: FieldMetadataType) =>
|
|
Object.values(compositeSubFieldMaps[fieldType] ?? {});
|