Commit Graph

4973 Commits

Author SHA1 Message Date
90d984d27d Remove signin prefill from docker compose (#9597)
I think this was affecting the 1-click install
2025-01-14 11:46:17 +01:00
f0287d273d Add containsAny filter comparators in rest api (#9595)
- add missing `containsAny` filter comparator to filter multiSelect
fields
- fix app break if object with same name created
- fix flash when clicking on choose plan
### Before


https://github.com/user-attachments/assets/71709912-63e8-40f8-bc52-3ec0a62746bb


### After



https://github.com/user-attachments/assets/93ee02c2-e3d9-4bab-8b6a-62813fd40b2b
2025-01-14 11:40:02 +01:00
5eeee6a7ed Add readonly mode to form fields - 2nd part (#9582)
In this PR, I implemented or confirmed that the read-only mode works for
the following fields:

- [x] FormUuidFieldInput
- [x] FormRawJsonFieldInput
- [x] FormPhoneFieldInput
- [x] FormEmailsFieldInput
- [x] FormLinksFieldInput
- [x] FormAddressFieldInput
- [x] FormFullNameFieldInput
2025-01-14 11:34:26 +01:00
21a6dff2c9 1-click install take latest version from docker (#9592)
There was a small issue where if you used the 1-click install script
right after it was tagged on Github but before it was built and
published to Docker hub, then it would fail
2025-01-14 10:20:47 +01:00
21e2295ade Support old relation filter value format (#9590)
Fix production bug caused by old relation filter value.

**Draft, not tested yet at all, working on it right now.**

---------

Co-authored-by: ad-elias <elias@autodiligence.com>
Co-authored-by: Charles Bochet <charles@twenty.com>
2025-01-13 21:45:39 +01:00
e893c4dcce Workflow fast follows batch (#9587)
- Add icon chevron on select
- Fix event step label
- Fix generate function output
2025-01-13 18:31:15 +01:00
f9a90a6561 Fix featureFlag not matching gql type (#9585)
## Context

<img width="1349" alt="Screenshot 2025-01-13 at 17 18 24"
src="https://github.com/user-attachments/assets/4f5da0e9-0245-41c6-bde2-4d52e0ba34ed"
/>

Feature flags are stored in DB and then cast as FeatureFlag gql type
from its corresponding enum.
This means if a value from the DB does not match that enum type, the gql
server will reject the call when returning the object in the resolver.
(see screenshot above)

To solve that, we want to do 2 things:
- The ORM should still return the feature flag even if it's not valid,
this is actually in the DB so we don't want to "hide" that, however we
now have a warning message.
- The service is not changed for the same reason, the limitation comes
from gql behaviour so this is not the goal of the service nor the ORM to
act on it (except the warning message)
- The resolver should be updated, here we want to filter-out non-valid
feature flags so it does not break the API.

Because featureFlags used to be auto-generated by nestjsquery and we
want to change its behavior, I had to manually create a resolveField for
featureFlags and remove the auto-generated one. That means we lose some
features such as filter/sort coming from nestjs-query pagination (which
is something we will want to implement once we will remove nestjs-query
but that's a whole other subject)
2025-01-13 18:30:16 +01:00
55bae60f69 Fix wrong domainName for redirect url (#9586)
Closes https://github.com/twentyhq/twenty/issues/9097

Fixes the redirect url of stripe `checkout` and `billingPortal` sessions

## Before


https://github.com/user-attachments/assets/4ccab325-41e1-494e-854a-9d9a72e534f1

## After


https://github.com/user-attachments/assets/740b07f4-84b0-4670-a5b6-2684fde640c8
2025-01-13 17:03:01 +00:00
17850b76ab Aggregate queries follow up (#9581)
In this PR

- fixing Collapse on view groups views: aggregate bar should be included
in the collapse (@magrinj )
- respect the html table pattern: the aggregate bar is now a <tr>
element included in a <table> (before that, it was a <tr> not included
in anything)
- add a top-border on the aggregate bar
- introduce short labels for the on-cell value display (display "Empty"
instead of "Count empty" to lighten the interface)
- remove the feature flag !
2025-01-13 17:20:35 +01:00
739611afa8 Migrate copilot to command menu (#9522)
Open copilot chat inside command menu


https://github.com/user-attachments/assets/60d83a77-6e96-4daa-98b0-33b7c1157d9a
2025-01-13 17:12:31 +01:00
86c4decdbd Refactored sort dropdown hooks (#9584)
- Removed useObjectSortDropdown hook
- Removed useSortDropdown hook
2025-01-13 17:07:05 +01:00
530a18558b 9426 migrate workflow pages to command menu (#9515)
Closes twentyhq/core-team-issues#53 

- Removes command menu top bar text input when the user is not on root
page
- Fixes bug when resetting command menu context
- Added animations on command menu open and close
- Refactored workflow visualizer code to remove unnecessary rerenders
and props drilling


https://github.com/user-attachments/assets/1da3adb8-220b-407b-9279-30354d3100d3
2025-01-13 16:53:57 +01:00
330addbc0b Refech code after code update (#9577)
- fixes code step update, then close code step, then open code step,
code not up to date
2025-01-13 15:53:56 +01:00
9ebe519e66 Finalize the readonly for a few form fields #1 (#9524)
There are many fields so I will cut my work in several small PRs.

Here, I updated the following fields:

- [x] `FormBooleanFieldInput`
- [x] `FormCurrencyFieldInput`
- [x] `FormNumberFieldInput`
- [x] `FormDateFieldInput`
- [x] `FormDateTimeFieldInput`
- [x] `FormMultiSelectFieldInput`
- [x] `FormSelectFieldInput`

The updates in the components are relatively small. I wrote Storybook
tests, and this is why the PR is quite big.

The changes in the components should mostly the same.

I added a disabled state to some inputs.

I created a specialized `VariableChip` as its styles started diverging
from the original `SortOrFilterChip`.
2025-01-13 15:07:41 +01:00
b81879dead fix: drop record group feature flag (#9575) 2025-01-13 14:50:27 +01:00
6314cdb36c fix: remove sticky shadow from RecordTableActionRow (#9576) 2025-01-13 14:48:33 +01:00
cc2d6154e7 fix: table acton row wrong stroke (#9574)
As requested by @Bonapara the stroke of `RecordTableActionRow` should be
in `sm` instead of `md`.
2025-01-13 14:42:37 +01:00
719344f980 Refactor record sort dropdown (#9578)
- Refactored all sort dropdown states to V2
- Added ObjectSortDropdownComponentInstanceContext
- Cleaned some constants
2025-01-13 14:42:02 +01:00
5783d68d62 Remove serverless functions on version archivation (#9535)
Fixes https://github.com/twentyhq/core-team-issues/issues/52
- contrary to title, we do not remove serverless functions on workflow
version archivation because serverless fucntion might be used in another
workflow version
- we fix the serverless funciton version displayed in the code step
- we allow test function version in step display right drawer
- we delete serverless function only when serverless function has no
published version
2025-01-13 13:09:57 +00:00
8643eaa28f Aggregate footer should have pseudo element only if there is horizontal scroll (#9559)
fixes
https://discord.com/channels/1130383047699738754/1326614903414587534/1326903218214666261
2025-01-13 13:40:33 +01:00
61c5acb982 fix: StyledMenuItemBase remove spacing when no icon (#9573) 2025-01-13 11:42:39 +01:00
002cbd3b78 Fixing phone search functionality (#9466)
This PR targets twentyhq/core-team-issues#85. 

@FelixMalfait As we discussed I have made those changes . Could you
please test it at your end?

---------

Co-authored-by: Charles Bochet <charles@twenty.com>
2025-01-13 10:54:00 +01:00
128abb2b85 fix: error thrown when switching between table with/without record group (#9571)
Fix an error when switching between a table with and without record
group.
2025-01-13 10:48:13 +01:00
34ee64a36c [Microsoft integration] getFullMessageList (#9544)
Creation of the GmailGetMessageListService
Implementation of the driver to MS Graph API getFullMessageList
2025-01-13 10:13:37 +01:00
c1847054f8 Playwright E2E test - sign up with invite link via email (#9332)
Related to
https://github.com/twentyhq/twenty/issues/8469#issuecomment-2471573054

---------

Co-authored-by: Félix Malfait <felix@twenty.com>
2025-01-12 21:52:30 +01:00
ba77091b06 fix: reset table selection when navigating away from index page (#9140)
Fixes #9132 

## Purpose
Currently, when navigating away from an index page and returning,
previously checked selections remain checked. This fix ensures the
selection context is properly reset on navigation.

## Changes
- Add `RecordIndexResetSelectionEffect` component to handle selection
cleanup
- Integrate effect into `RecordIndexPage`
- Uses existing `useResetTableRowSelection` hook to clear selections

## Testing
1. Go to any index page (e.g., Companies)
2. Select some records using checkboxes
3. Navigate to a detail page
4. Return to the index page
5. Verify that no records are selected

## Demo
I've recorded a short video demonstrating how this PR fixes the issue:

[Loom Video
Link](https://www.loom.com/share/72ca46a5dc194b5092e1944a985fa0d2?sid=55c95d8b-2376-4ac5-b406-6483aa7e341f)

Before fix: Selections persist after navigation
After fix: Selections are properly reset

---------

Co-authored-by: Lucas Bordeau <bordeau.lucas@gmail.com>
Co-authored-by: Charles Bochet <charles@twenty.com>
2025-01-11 11:23:07 +01:00
9ed9b310f7 Update links in docs to current release (#9553)
As this was missing I just updated to reference the files from the
current release tag
2025-01-10 21:58:30 +01:00
9d735b8562 Try migrating to depot (#9555) 2025-01-10 21:46:26 +01:00
5ec28afac9 Fix Storybook tests (#9554)
Finally fixing the storybook tests!
2025-01-10 20:54:10 +01:00
2e0169b954 Aggregate follow-up (#9547)
In this PR
- fix [some UI
regressions](https://discord.com/channels/1130383047699738754/1327189577575956514/1327189577575956514)
introduced by work on view groups
- address some follow-ups:
1. [Menu should keep selected when the menu is
open](https://discord.com/channels/1130383047699738754/1326607851824877639/1326607851824877639)
2.
[Cropping](https://discord.com/channels/1130383047699738754/1326610578869063800/1326610578869063800)
3. [Put earliest date / latest date in a separate "Date"
submenu](https://discord.com/channels/1130383047699738754/1326856023985618966/1326856023985618966)
- Refactor around date aggregate operations
2025-01-10 20:01:36 +01:00
873f20bc0e [CI][FRONT] Storybook tests sharding (#9448)
# Introduction
The idea here is to improve perf nor fluidity of both storybook build
and tests execution duration.

## Levers:
- Storybook tests
[shards](https://storybook.js.org/docs/writing-tests/test-runner)
- Refactored storybook's build caching using `actions/cache/restore` and
`actions/cache/save` to avoid useless computation with we wanna just
write or retrieve it
- Running storybook build with --test
[flag](https://storybook.js.org/docs/api/main-config/main-config-build)
( please note that we only disable docs addons in order to keep coverage
up and running )

closes https://github.com/twentyhq/core-team-issues/issues/49
2025-01-10 18:40:03 +01:00
b40f58a512 refactor(admin-panel): standardize FeatureFlagKey usage (#9548)
Replaced string-based feature flag keys with the typed FeatureFlagKey
enum across the admin panel module and related front-end hooks. This
ensures stronger type safety, reduces potential errors, and improves
consistency in handling feature flags.
2025-01-10 18:38:50 +01:00
ed51bff2f4 Clean up object record filter (#9550)
Last clean up of object dropdown filter states v1. 

Removed old state scope context component.
2025-01-10 18:37:29 +01:00
4efa959401 Fix apollo cache for workflow cmd+k (#9549)
When a workflow was activate, the previous activated version was still
available in cmd+k
This is because we were only updating entities in cache after
activation.
We also need to update the queries stored in cache, because this is
where the cmd+k look to know which workflow is active.


https://github.com/user-attachments/assets/750cc24a-7583-4641-856c-0f9892d26331
2025-01-10 18:33:10 +01:00
11a47264a7 fix: fix regression on multiItem input field when no item (#9543)
### Context
Fix on [8904 issue](https://github.com/twentyhq/twenty/issues/8904)
([PR](https://github.com/twentyhq/twenty/pull/9439)) introduces a
regression when field has no item.
Background should be lighter.
<img width="250" alt="Screenshot 2025-01-10 at 16 08 03"
src="https://github.com/user-attachments/assets/1eb39455-f24a-4301-9a72-7a9a8f5c8382"
/>


### Solution
Conditional styling, displayed only when MultiInput has item
<img width="250" alt="Screenshot 2025-01-10 at 16 08 20"
src="https://github.com/user-attachments/assets/6bc02aa0-0430-4207-8163-c31d66751f3e"
/>

Co-authored-by: etiennejouan <jouan.etienne@gmail.com>
2025-01-10 18:32:52 +01:00
4ca03d0066 fix(auth): handle error properly in loadCurrentUser (#9539)
Updated the loadCurrentUser function to throw specific errors when an
API error occurs. This improves clarity and error handling, replacing
the generic "No current user result" exception.

Fix #9536
2025-01-10 17:21:33 +01:00
07fa58b042 docs(server-commands): fix typo in command to generate migrations (#9545)
- the command had `--migration:generate` instead of `migration:generate`
written in the doc
- when copy pasting it we got this error
```
Not enough non-option arguments: got 0, need at least 1
```
- after removing the extra `--` it worked as expected
2025-01-10 17:21:15 +01:00
b46bc84dab Fix mail import gmail driver when message has been deleted (#9546)
We forgot to ignore messages that were removed
2025-01-10 16:52:29 +01:00
d1170668df refactor: update import paths for FeatureFlagKey (#9542)
Replaced references to '~/generated-metadata/graphql' with
'~/generated/graphql' across multiple files. This change ensures
uniformity in import paths and aligns with the updated directory
structure.
2025-01-10 16:20:10 +01:00
92c119ed43 Add suggested values for variable dropdown (#9437)
<img width="378" alt="Capture d’écran 2025-01-07 à 15 37 20"
src="https://github.com/user-attachments/assets/c15abcac-684a-4c3b-ad12-62cf91afe927"
/>

Here is a first version:
- simple fields have a suggested value
- composite do not, but sub values of composite do
- json, arrays or complex values do not
2025-01-10 16:18:37 +01:00
5648c3b31c [refactor]: Remove isSSOEnabled logic throughout the codebase (#9462)
Eliminated all references to `isSSOEnabled` across the frontend,
backend, and configuration files. This change simplifies the codebase by
removing unnecessary feature flag checks, associated logic, and
environment variables. The SSO feature remains available without
reliance on this flag.
2025-01-10 14:45:35 +01:00
e58edc3bc1 Removed useFilterDropdown hook (#9537)
Removed useFilterDropdown hook and its many calls which were only
exporting states.

The test has been removed because it was used to do the equivalent of
testing Recoil states, so it wasn't useful anymore.
2025-01-10 14:45:17 +01:00
7b2debf6fb Add error marker when invalid main function (#9489)
## Before

![image](https://github.com/user-attachments/assets/f6af6721-0896-48b5-8556-9d2a9c19de06)

## After

![image](https://github.com/user-attachments/assets/c59407c8-8244-4906-9d05-713909a19c33)
2025-01-10 14:29:58 +01:00
ddcb3dfd28 Feature flags env variable gating (#9481)
closes #9032

---------

Co-authored-by: Antoine Moreaux <moreaux.antoine@gmail.com>
2025-01-10 14:04:00 +01:00
75bf9e3c69 fix(admin-panel): resolve feature flag key mismatch (#9530)
Update feature flag handling by mapping input keys to enum values. This
ensures compatibility and prevents potential runtime errors when
updating workspace feature flags.
2025-01-10 12:30:42 +01:00
c716a30d92 Refactored empty filter (#9532)
Refactored empty filter function and removed it from useFilterDropdown
hook
2025-01-10 12:30:01 +01:00
654a0bb79e Fix CI Server 2025-01-10 12:29:22 +01:00
0a798a6671 Feat/view groups fast follow (#9513)
Fix #9512 

- 🟠 [Icon should be
lighter](https://discord.com/channels/1130383047699738754/1326487470895923222)
The current weight is the same as in Figma, waiting for confirmation
- 🟠 [None has an unwanted margin
left](https://discord.com/channels/1130383047699738754/1326493647796961323)
This component is used in lot of places, removing the padding left can
brake other places
- 🟢 [All cells should have a the same right
design](https://discord.com/channels/1130383047699738754/1326489001926066176)
- 🔴 [Group Sorting should not "freeze" when mouse is
release](https://discord.com/channels/1130383047699738754/1326494381795966996)
Can't find a good way to fix it, seems more related to the fact it's
running in debug mode.
- 🟢 [Alignment
issue](https://discord.com/channels/1130383047699738754/1326486523822084140)
- 🟢 [View record count
error](https://discord.com/channels/1130383047699738754/1326491489466978365)
- 🟢 [Vertically align tags and
numbers/count](https://discord.com/channels/1130383047699738754/1326490661800902728)
- 🟢 [Display "Calculate" only on hover in view
groups](https://discord.com/channels/1130383047699738754/1326490411929436191)
- 🟢 [Aggregates height in view groups is 28px instead of
32px](https://discord.com/channels/1130383047699738754/1326489587127943188)
- 🟠 [Picker under the
aggregate](https://discord.com/channels/1130383047699738754/1326487940557439039)
Can't reproduce the issue
- 🟢 [Icon should not be
hoverable](https://discord.com/channels/1130383047699738754/1326477402360123425)
- 🟢 [Crop long view
titles](https://discord.com/channels/1130383047699738754/1326477009576136755)
- 🟢 [Removing the group by on opportunities (group by none) give an
white
screen](https://discord.com/channels/1130383047699738754/1324651927962910750)
2025-01-09 19:12:57 +01:00
1f1cac3b00 chore: update returned attachement fullPath (#9516)
### Solution

fullPath prop on attachement (when returned by backend) is updated to
'domain + path' (formerly 'path').

Consequently, getFileAbsoluteURI util in front is removed.

closes #8763

---------

Co-authored-by: etiennejouan <jouan.etienne@gmail.com>
2025-01-09 19:12:36 +01:00
4c8c338316 Update ci runner for sb build 2025-01-09 18:58:36 +01:00