-
Notifications
You must be signed in to change notification settings - Fork 2.5k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
#6950 Add new icons to Object Fields Data types. Before: ![image](https://github.com/user-attachments/assets/55697e31-841d-435e-8c70-13ff1c59268d) After: ![image](https://github.com/user-attachments/assets/bd43f0ec-d3f7-4ecf-a95f-87a030f68e24) ![image](https://github.com/user-attachments/assets/369893a9-35be-43f8-bfcb-55149effa78a)
- Loading branch information
Showing
45 changed files
with
703 additions
and
48 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,24 +1,23 @@ | ||
import { | ||
IconCalendarEvent, | ||
IconCalendarTime, | ||
IconCheck, | ||
IconCoins, | ||
IconComponent, | ||
IconCreativeCommonsSa, | ||
IconFilePencil, | ||
IconJson, | ||
IconKey, | ||
IconLink, | ||
IconMail, | ||
IconMap, | ||
IconNumbers, | ||
IconPhone, | ||
IconRelationManyToMany, | ||
IconTag, | ||
IconTags, | ||
IconTextSize, | ||
IconTwentyStar, | ||
IconUser, | ||
IllustrationIconCalendarEvent, | ||
IllustrationIconCalendarTime, | ||
IllustrationIconCurrency, | ||
IllustrationIconJson, | ||
IllustrationIconLink, | ||
IllustrationIconMail, | ||
IllustrationIconMap, | ||
IllustrationIconNumbers, | ||
IllustrationIconOneToMany, | ||
IllustrationIconPhone, | ||
IllustrationIconSetting, | ||
IllustrationIconStar, | ||
IllustrationIconTag, | ||
IllustrationIconTags, | ||
IllustrationIconText, | ||
IllustrationIconToggle, | ||
IllustrationIconUid, | ||
IllustrationIconUser, | ||
} from 'twenty-ui'; | ||
|
||
import { CurrencyCode } from '@/object-record/record-field/types/CurrencyCode'; | ||
|
@@ -39,100 +38,100 @@ export type SettingsFieldTypeConfig = { | |
export const SETTINGS_FIELD_TYPE_CONFIGS = { | ||
[FieldMetadataType.Uuid]: { | ||
label: 'Unique ID', | ||
Icon: IconKey, | ||
Icon: IllustrationIconUid, | ||
exampleValue: '00000000-0000-0000-0000-000000000000', | ||
category: 'Advanced', | ||
}, | ||
[FieldMetadataType.Text]: { | ||
label: 'Text', | ||
Icon: IconTextSize, | ||
Icon: IllustrationIconText, | ||
exampleValue: | ||
'Lorem ipsum dolor sit amet, consectetur adipiscing elit. Vestibulum magna enim, dapibus non enim in, lacinia faucibus nunc. Sed interdum ante sed felis facilisis, eget ultricies neque molestie. Mauris auctor, justo eu volutpat cursus, libero erat tempus nulla, non sodales lorem lacus a est.', | ||
category: 'Basic', | ||
}, | ||
[FieldMetadataType.Numeric]: { | ||
label: 'Numeric', | ||
Icon: IconNumbers, | ||
Icon: IllustrationIconNumbers, | ||
exampleValue: 2000, | ||
category: 'Basic', | ||
}, | ||
[FieldMetadataType.Number]: { | ||
label: 'Number', | ||
Icon: IconNumbers, | ||
Icon: IllustrationIconNumbers, | ||
exampleValue: 2000, | ||
category: 'Basic', | ||
}, | ||
[FieldMetadataType.Link]: { | ||
label: 'Link', | ||
Icon: IconLink, | ||
Icon: IllustrationIconLink, | ||
exampleValue: { url: 'www.twenty.com', label: '' }, | ||
category: 'Basic', | ||
}, | ||
[FieldMetadataType.Links]: { | ||
label: 'Links', | ||
Icon: IconLink, | ||
Icon: IllustrationIconLink, | ||
exampleValue: { primaryLinkUrl: 'twenty.com', primaryLinkLabel: '' }, | ||
category: 'Basic', | ||
}, | ||
[FieldMetadataType.Boolean]: { | ||
label: 'True/False', | ||
Icon: IconCheck, | ||
Icon: IllustrationIconToggle, | ||
exampleValue: true, | ||
category: 'Basic', | ||
}, | ||
[FieldMetadataType.DateTime]: { | ||
label: 'Date and Time', | ||
Icon: IconCalendarTime, | ||
Icon: IllustrationIconCalendarTime, | ||
exampleValue: DEFAULT_DATE_VALUE.toISOString(), | ||
category: 'Basic', | ||
}, | ||
[FieldMetadataType.Date]: { | ||
label: 'Date', | ||
Icon: IconCalendarEvent, | ||
Icon: IllustrationIconCalendarEvent, | ||
exampleValue: DEFAULT_DATE_VALUE.toISOString(), | ||
category: 'Basic', | ||
}, | ||
[FieldMetadataType.Select]: { | ||
label: 'Select', | ||
Icon: IconTag, | ||
Icon: IllustrationIconTag, | ||
category: 'Basic', | ||
}, | ||
[FieldMetadataType.MultiSelect]: { | ||
label: 'Multi-select', | ||
Icon: IconTags, | ||
Icon: IllustrationIconTags, | ||
category: 'Basic', | ||
}, | ||
[FieldMetadataType.Currency]: { | ||
label: 'Currency', | ||
Icon: IconCoins, | ||
Icon: IllustrationIconCurrency, | ||
exampleValue: { amountMicros: 2000000000, currencyCode: CurrencyCode.USD }, | ||
category: 'Basic', | ||
}, | ||
[FieldMetadataType.Relation]: { | ||
label: 'Relation', | ||
Icon: IconRelationManyToMany, | ||
Icon: IllustrationIconOneToMany, | ||
category: 'Relation', | ||
}, | ||
[FieldMetadataType.Email]: { | ||
label: 'Email', | ||
Icon: IconMail, | ||
Icon: IllustrationIconMail, | ||
category: 'Basic', | ||
}, | ||
[FieldMetadataType.Emails]: { | ||
label: 'Emails', | ||
Icon: IconMail, | ||
Icon: IllustrationIconMail, | ||
exampleValue: { primaryEmail: '[email protected]' }, | ||
category: 'Basic', | ||
}, | ||
[FieldMetadataType.Phone]: { | ||
label: 'Phone', | ||
Icon: IconPhone, | ||
Icon: IllustrationIconPhone, | ||
exampleValue: '+1234-567-890', | ||
category: 'Basic', | ||
}, | ||
[FieldMetadataType.Phones]: { | ||
label: 'Phones', | ||
Icon: IconPhone, | ||
Icon: IllustrationIconPhone, | ||
exampleValue: { | ||
primaryPhoneNumber: '234-567-890', | ||
primaryPhoneCountryCode: '+1', | ||
|
@@ -141,19 +140,19 @@ export const SETTINGS_FIELD_TYPE_CONFIGS = { | |
}, | ||
[FieldMetadataType.Rating]: { | ||
label: 'Rating', | ||
Icon: IconTwentyStar, | ||
Icon: IllustrationIconStar, | ||
exampleValue: '3', | ||
category: 'Basic', | ||
}, | ||
[FieldMetadataType.FullName]: { | ||
label: 'Full Name', | ||
Icon: IconUser, | ||
Icon: IllustrationIconUser, | ||
exampleValue: { firstName: 'John', lastName: 'Doe' }, | ||
category: 'Advanced', | ||
}, | ||
[FieldMetadataType.Address]: { | ||
label: 'Address', | ||
Icon: IconMap, | ||
Icon: IllustrationIconMap, | ||
exampleValue: { | ||
addressStreet1: '456 Oak Street', | ||
addressStreet2: 'Unit 3B', | ||
|
@@ -168,20 +167,20 @@ export const SETTINGS_FIELD_TYPE_CONFIGS = { | |
}, | ||
[FieldMetadataType.RawJson]: { | ||
label: 'JSON', | ||
Icon: IconJson, | ||
Icon: IllustrationIconJson, | ||
exampleValue: { key: 'value' }, | ||
|
||
category: 'Basic', | ||
}, | ||
[FieldMetadataType.RichText]: { | ||
label: 'Rich Text', | ||
Icon: IconFilePencil, | ||
Icon: IllustrationIconSetting, | ||
exampleValue: { key: 'value' }, | ||
category: 'Basic', | ||
}, | ||
[FieldMetadataType.Actor]: { | ||
label: 'Actor', | ||
Icon: IconCreativeCommonsSa, | ||
Icon: IllustrationIconSetting, | ||
category: 'Basic', | ||
}, | ||
} as const satisfies Record< | ||
|
8 changes: 8 additions & 0 deletions
8
packages/twenty-ui/src/display/icon/assets/illustration-calendar-event.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
9 changes: 9 additions & 0 deletions
9
packages/twenty-ui/src/display/icon/assets/illustration-calendar-time.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
13 changes: 13 additions & 0 deletions
13
packages/twenty-ui/src/display/icon/assets/illustration-currency.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
5 changes: 5 additions & 0 deletions
5
packages/twenty-ui/src/display/icon/assets/illustration-json.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
17 changes: 17 additions & 0 deletions
17
packages/twenty-ui/src/display/icon/assets/illustration-link.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
14 changes: 14 additions & 0 deletions
14
packages/twenty-ui/src/display/icon/assets/illustration-mail.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
14 changes: 14 additions & 0 deletions
14
packages/twenty-ui/src/display/icon/assets/illustration-map.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Oops, something went wrong.