Commit Graph

2504 Commits

Author SHA1 Message Date
885b2d62d9 Fix stories (#10851)
Fix storybook stories
<img width="1475" alt="image"
src="https://github.com/user-attachments/assets/50327d9b-f3a0-46ea-87f2-93da356ec7c9"
/>
2025-03-13 14:31:20 +01:00
da4eb1e7d2 Fix UI bug in REST API playground (#10848)
When you clicked on the left-side menu to navigate, the top bar would
disappear. This PR fixes that and the top bar always remain visible.
2025-03-13 13:15:03 +01:00
3f7315c2dc Fix test data disapear (#10846)
As title. Init input from source code only once.
2025-03-13 12:08:29 +01:00
5b34f86b6d Add Icon to roles (#10842)
## Context
Adding icon column to role table to distinguish roles.

<img width="621" alt="Screenshot 2025-03-13 at 11 02 37"
src="https://github.com/user-attachments/assets/dc7b121c-2901-4599-9638-d5dcdf443999"
/>
2025-03-13 11:34:30 +01:00
ecf282ad99 Highlight consumed variables in workflow runs (#10788)
- Create a function to resolve the variables used in the configuration
of a step
- Let the JSON tree components take a prop (`getNodeHighlighting`) to
determine whether an element must be highlighted
- Compute each element's keyPath recursively; the keyPath is passed as
an argument to the `getNodeHighlighting` function

## Demo


https://github.com/user-attachments/assets/8586f43d-53d1-41ba-ab48-08bb8c74e145

Closes https://github.com/twentyhq/core-team-issues/issues/435
2025-03-13 11:19:12 +01:00
7e291f3cff Fix close right drawer error (#10841)
fixes
https://discord.com/channels/1130383047699738754/1349485390871924796
2025-03-13 10:02:59 +00:00
638fbe2014 Fix flash when creating draft (#10814)
Always set `serverlessWorkflowVersion = 'draft'` in code steps
2025-03-13 10:16:47 +01:00
ebf56b1b19 i18n - translations (#10840)
Created by Github action

---------

Co-authored-by: Crowdin Bot <support+bot@crowdin.com>
Co-authored-by: github-actions <github-actions@twenty.com>
2025-03-13 09:48:10 +01:00
2be2b36e01 Tablist regression fix (#10832)
## Issue
https://discord.com/channels/1130383047699738754/1349428521075871846
@Devessier found a regression where the TabList was getting too tall in
some places. This happened because:
1. The ScrollWrapper inside TabList has `height: 100%` by default
2. The parent container in ShowPageSubContainer uses `display: flex`
when tabs should be shown
3. This combination makes the ScrollWrapper expand to fill the available
space

## Fix
Added a wrapper `<div>` around the ScrollWrapper in the TabList
component. This works because:
1. It creates a new flex container that contains the ScrollWrapper's
expansion
2. It preserves the flex context needed by ShowPageSubContainer for
proper layout
3. It maintains all visual styles including the tab borders

## Technical Details
While using `heightMode="fit-content"` on ScrollWrapper might seem like
a fix, it breaks the interaction between TabList and its parent
containers that use flex layout for positioning.

before: 

<img width="537" alt="Screenshot 2025-03-13 at 02 16 03"
src="https://github.com/user-attachments/assets/9d4ddc81-68e8-44fe-8d32-da1d8e52492c"
/>

after:

<img width="518" alt="Screenshot 2025-03-13 at 02 11 50"
src="https://github.com/user-attachments/assets/dc8866c9-7dc3-4b59-8c18-d08233fc2143"
/>
2025-03-13 08:44:09 +00:00
6ba4ffe4c4 i18n - translations (#10839)
Created by Github action

Co-authored-by: github-actions <github-actions@twenty.com>
2025-03-13 08:31:02 +01:00
c0ca09492c Replace connected account table with table card (#10838)
before: 
<img width="624" alt="Screenshot 2025-03-13 at 12 45 03"
src="https://github.com/user-attachments/assets/be09194a-66bb-4e39-afc1-9dd11c89dcef"
/>
after:
<img width="619" alt="Screenshot 2025-03-13 at 12 44 39"
src="https://github.com/user-attachments/assets/759f87c3-995c-4be4-8523-42f5e805ca83"
/>
2025-03-13 13:00:44 +05:30
9f9302136f Fix command O delete action on record page (#10820)
There were two issues, the hotkey scope wasn't set properly when opening
the dropdown with the shortcut and we didn't close the command menu upon
completion of the delete action.

Before:


https://github.com/user-attachments/assets/817442ae-6db4-4fc5-a637-4e2e3d9b9b70


After:


https://github.com/user-attachments/assets/b6fd07f6-6c2f-4b29-9162-f29b661ad358
2025-03-13 08:09:49 +01:00
737e17193a i18n - translations (#10835)
Created by Github action

Co-authored-by: github-actions <github-actions@twenty.com>
2025-03-12 23:33:37 +01:00
8e9a73462b i18n - translations (#10834)
Created by Github action

---------

Co-authored-by: Crowdin Bot <support+bot@crowdin.com>
Co-authored-by: github-actions <github-actions@twenty.com>
2025-03-12 23:20:10 +01:00
7468f25b80 i18n - translations (#10831)
Created by Github action

Co-authored-by: github-actions <github-actions@twenty.com>
2025-03-12 21:33:13 +01:00
8f38501aad i18n - translations (#10830)
Created by Github action

---------

Co-authored-by: Crowdin Bot <support+bot@crowdin.com>
Co-authored-by: github-actions <github-actions@twenty.com>
2025-03-12 21:20:55 +01:00
10bc939634 i18n - translations (#10829)
Created by Github action

---------

Co-authored-by: github-actions <github-actions@twenty.com>
2025-03-12 21:01:21 +01:00
c61748cd6e Admin panel fixes (#10792)
<img width="573" alt="Screenshot 2025-03-12 at 17 36 44"
src="https://github.com/user-attachments/assets/be6c20b0-626d-4a2c-810c-78a49e9f65ee"
/>
<img width="579" alt="Screenshot 2025-03-12 at 17 37 03"
src="https://github.com/user-attachments/assets/23692ff8-ac88-4104-823e-1a06b3074551"
/>
<img width="590" alt="Screenshot 2025-03-12 at 17 37 14"
src="https://github.com/user-attachments/assets/b46de1d3-a312-44cc-a54d-72208224453d"
/>
<img width="556" alt="Screenshot 2025-03-12 at 17 37 37"
src="https://github.com/user-attachments/assets/12176d49-d76d-4fb1-abe6-1f7dc5349d94"
/>
<img width="607" alt="Screenshot 2025-03-12 at 17 37 50"
src="https://github.com/user-attachments/assets/00e2edff-09db-45c5-a4df-6fd9ead830b6"
/>
2025-03-13 01:25:38 +05:30
75da64876a i18n - translations (#10828)
Created by Github action

Co-authored-by: github-actions <github-actions@twenty.com>
2025-03-12 19:37:22 +01:00
795930f4f8 i18n - translations (#10827)
Created by Github action

---------

Co-authored-by: Crowdin Bot <support+bot@crowdin.com>
Co-authored-by: github-actions <github-actions@twenty.com>
2025-03-12 19:21:36 +01:00
3f7d9ccdef i18n - translations (#10823)
Created by Github action

Co-authored-by: github-actions <github-actions@twenty.com>
2025-03-12 18:20:13 +01:00
f4a362b53a Add base form action without logic (#10811)
<img width="1298" alt="Capture d’écran 2025-03-12 à 15 32 27"
src="https://github.com/user-attachments/assets/8a3140e5-e165-445e-a718-748aa76b525c"
/>
2025-03-12 17:05:31 +00:00
a4ef820f13 i18n - translations (#10821)
Created by Github action

---------

Co-authored-by: github-actions <github-actions@twenty.com>
2025-03-12 18:01:13 +01:00
7a4f082fc5 renaming layout and changing icons (#10781)
Updating icons and renaming View Settings to Layout

Fixes : https://github.com/twentyhq/core-team-issues/issues/486
Fixes : https://github.com/twentyhq/core-team-issues/issues/484
Fixes : https://github.com/twentyhq/core-team-issues/issues/488
2025-03-12 17:49:28 +01:00
3eb1aa1b5a Fix alignment and background icon color on record page header (#10817)
Before:
<img width="501" alt="Capture d’écran 2025-03-12 à 17 23 58"
src="https://github.com/user-attachments/assets/b9f58bc1-61e5-4a6b-905d-76eeb63f88be"
/>

After:
<img width="499" alt="Capture d’écran 2025-03-12 à 17 22 12"
src="https://github.com/user-attachments/assets/30c95603-77e9-4647-b233-8c0ea2a27df8"
/>
2025-03-12 17:46:07 +01:00
89faccad4f i18n - translations (#10816)
Created by Github action

Co-authored-by: github-actions <github-actions@twenty.com>
2025-03-12 17:36:55 +01:00
69f6796021 i18n - translations (#10813)
Created by Github action

---------

Co-authored-by: Crowdin Bot <support+bot@crowdin.com>
Co-authored-by: github-actions <github-actions@twenty.com>
2025-03-12 17:21:20 +01:00
a818e76d61 i18n - translations (#10812)
Created by Github action

Co-authored-by: github-actions <github-actions@twenty.com>
2025-03-12 16:34:04 +01:00
daa501549e 271 remove is command menu v2 enabled (#10809)
Closes https://github.com/twentyhq/core-team-issues/issues/271

This PR
- Removes the feature flag IS_COMMAND_MENU_V2_ENABLED
- Removes all old Right drawer components
- Removes the Action menu bar
- Removes unused Copilot page
2025-03-12 16:26:29 +01:00
1b0413bf8b Add days schedule trigger (#10800)
<img width="1470" alt="image"
src="https://github.com/user-attachments/assets/660d79ba-60c7-4874-aa82-80a7575366ba"
/>
2025-03-12 15:25:07 +00:00
bfc542290b 545 replace objects icons and names with records avatars and labelidentifiers in command menu context chips (#10787)
Closes https://github.com/twentyhq/core-team-issues/issues/545

This PR:
- Introduces `commandMenuNavigationMorphItemsState` which stores the
information about the `recordId` and the `objectMetadataItemId` for each
page
- Creates `CommandMenuContextChipEffect`, which queries the records from
the previous pages in case a record has been updated during the
navigation, to keep up to date information and stores it inside
`commandMenuNavigationRecordsState`
- `useCommandMenuContextChips` returns the context chips information
- Style updates (icons background and color)
- Updates `useCommandMenu` to set and reset these new states


https://github.com/user-attachments/assets/8886848a-721d-4709-9330-8e84ebc0d51e
2025-03-12 15:26:14 +01:00
0d7484389e Stop using labelIdentifier when adding record card (#10805)
When creating an object from kanban, we are using
`labelIdentifier.toLowerCase()` for the labelIdentifier field.
Issue is that labelIdentifier is translated.

Using `labelIdentifierField.name` instead.
2025-03-12 15:07:35 +01:00
5ddc34b182 Tablist bottom margin fix (#10801)
### Bug
The active tab bottom border appeared slightly above the TabList's light
bottom border.

### Investigation
- Initial fix: Adjusted margin-bottom to -1px in Tab component to align
borders
- This fix caused active bottom borders to disappear in tabs wrapped
with ShowPageSubContainerTabListContainer
- Found that ShowPageSubContainerTabListContainer was adding a redundant
bottom border that overlapped with TabList's border

### Solution
- Removed ShowPageSubContainerTabListContainer to eliminate the
redundant border
- Kept the -1px margin-bottom fix in Tab component
- This ensures consistent border behavior across all TabList
implementations
2025-03-12 14:45:50 +01:00
6102277de6 Settings counter alignment fix (#10802)
https://discord.com/channels/1130383047699738754/1349342363490844692
2025-03-12 13:09:54 +00:00
911647a279 Fix many bugs on advanced filters for CRUD to work (#10772)
This PR fixes many bugs on advanced filters, the goal here was to have
CRUD working with other simple filters and sorts.

In order to test this PR you'll have to run a sync metadata.

Fixes https://github.com/twentyhq/core-team-issues/issues/560

## Changed positionInViewFilterGroup field metadata type 

This PR changes the type of positionInViewFilterGroup to NUMERIC instead
of POSITION, there certainly was a confusion during the initial
development, where POSITION type seemed relevant but it is not for this
particular feature because the position in a view filter group is not
the position of a record, which is used for displaying and re-ordering
purpose in table and kanban views.

Here the positionInViewFilterGroup is a specific position concept tied
to a custom feature, and it is handled by the specific logic of this
advanced filter dropdown layout.

## Create new ids when duplicating a view

When we use create view from an existing view, the logic in
useCreateViewFromCurrentView will copy over filters, filter groups and
sorts. The problem is that it copies it with the same ids, and that if
the backend manages somehow to create new ids, the ids that are put in
parentViewFilterGroupId are corresponding to the old filter groups not
the duplicated new ones.

So we had to create a map of old id => new id so that everything that
has to be sent to the backend for creation already has the same mapping
of parent id but with new ids generated by the frontend.

## Bug with creating a simple filter

We couldn't create a simple filter when advanced filters were set, this
was because of findDuplicateRecordFilterInNonAdvancedRecordFilters which
wasn't doing what it's naming tells, it wasn't filtering on simple
filters only before looking for duplicates.

## Clean code

- Use lastChildPosition directly from
useChildRecordFiltersAndRecordFilterGroups instead of drilling it down
- Refactored AdvancedFilterDropdownButton to extract the code lower
where it is really needed in AdvancedFilterChip
- Renamed a few View to Record naming where relevant
2025-03-12 10:23:41 +00:00
4036933c84 Add console logs to code step (#10786)
Works for local and lambda drivers

## After

![image](https://github.com/user-attachments/assets/ec082cf6-4159-4a15-99b6-243c73a13773)

![image](https://github.com/user-attachments/assets/f42e3f43-5ea4-4167-b4b5-9a17826fd224)
2025-03-12 10:40:59 +01:00
d9817d6b9c Fix tabler icons load (#10782)
As per
https://github.com/tabler/tabler-icons/issues/1233#issuecomment-2428245119
2025-03-11 18:01:28 +01:00
ddeba39a2c Reset step output schema when step is removed (#10762)
When a step is deleted in a draft version, its variable are still
available in the following steps. This is because step output schema was
not reset. We needed either to refresh or to change version so output
schema gets updated.

This PR:
- migrates to a family state global + context not linked to a component
- add a reset step output schema function
- reset when a step is removed
2025-03-11 16:38:47 +00:00
680935e605 i18n - translations (#10785)
Created by Github action

Co-authored-by: github-actions <github-actions@twenty.com>
2025-03-11 17:21:25 +01:00
5bbfbf68eb i18n - translations (#10784)
Created by Github action

---------

Co-authored-by: Crowdin Bot <support+bot@crowdin.com>
Co-authored-by: github-actions <github-actions@twenty.com>
2025-03-11 17:06:05 +01:00
0516e95330 i18n - translations (#10779)
Created by Github action

---------

Co-authored-by: github-actions <github-actions@twenty.com>
2025-03-11 15:34:53 +01:00
4e44ae59f7 Delete view & copy link (#10760)
adding the delete view and copy link additional menu option

Fixes https://github.com/twentyhq/core-team-issues/issues/480
Fixes https://github.com/twentyhq/core-team-issues/issues/481
2025-03-11 15:15:00 +01:00
48bd48753b Improve twenty-front build performance (vite rollup option) (#10771)
In this PR, I'm specifying to vite build that
'@scalar/api-reference-react' is an external dependency and should not
be considered as a module we maintain (it won't get its own chunk at
build time and we won't generate sourcemaps on our end).

I'm not sure why vite is considering it internal in the first place (I
can see that it's generating .vue.js files, might be the first time we
are relying on a vue library)
2025-03-11 12:39:54 +01:00
41f3a63962 [BUGFIX] ObjectMetadata item server validation (#10699)
# Introduction
This PR contains several SNAPSHOT files explaining big +

While refactoring the Object Model settings page in
https://github.com/twentyhq/twenty/pull/10653, encountered a critical
issue when submitting either one or both names with `""` empty string
hard corrupting a workspace.

This motivate this PR reviewing server side validation

I feel like we could share zod schema between front and back

## Refactored server validation
What to expect from Names:
- Plural and singular have to be different ( case insensitive and
trimmed check )
- Contains only a-z A-Z and 0-9
- Follows camelCase
- Is not empty => Is not too short ( 1 )
- Is not too long ( 63 )
- Is case insensitive( fooBar and fOoBar now rejected )

What to expect from Labels:
- Plural and singular have to be different ( case insensitive and
trimmed check )
- Is not empty => Is not too short ( 1 )
- Is not too long ( 63 )
- Is case insensitive ( fooBar and fOoBar now rejected )

close https://github.com/twentyhq/twenty/issues/10694

## Creation integrations tests
Created new integrations tests, following
[EachTesting](https://jestjs.io/docs/api#testeachtablename-fn-timeout)
pattern and uses snapshot to assert errors message. These tests cover
several failing use cases and started to implement ones for the happy
path but object metadata item deletion is currently broken unless I'm
mistaken @Weiko is on it

## Notes
- [ ] As we've added new validation rules towards names and labels we
should scan db in order to standardize existing values using either a
migration command or manual check
- [ ] Will review in an other PR the update path, adding integrations
tests and so on
2025-03-11 12:14:37 +01:00
e5a7aab733 Fix incorrect Scalar CSS import (#10763)
CSS was loaded in a global context (full screen which might be re-used
for other use cases in the future) instead of a local context.

\+ small update on .env.example
2025-03-10 21:10:40 +01:00
dc66d2498e i18n - translations (#10765)
Created by Github action

Co-authored-by: github-actions <github-actions@twenty.com>
2025-03-10 19:36:18 +01:00
d3e6879ee3 i18n - translations (#10764)
Created by Github action

---------

Co-authored-by: Crowdin Bot <support+bot@crowdin.com>
Co-authored-by: github-actions <github-actions@twenty.com>
2025-03-10 19:21:42 +01:00
0861384351 i18n - translations (#10761)
Created by Github action

---------

Co-authored-by: github-actions <github-actions@twenty.com>
2025-03-10 19:01:21 +01:00
5fb613a8f7 Fix permissions front followup (#10758) 2025-03-10 18:56:23 +01:00
c8b44aa242 Update design for not found variables (#10756)
<img width="494" alt="Capture d’écran 2025-03-10 à 14 09 37"
src="https://github.com/user-attachments/assets/ea4a55a1-c7f0-4138-a494-592b197ec8a2"
/>
2025-03-10 17:42:38 +00:00