Commit Graph

167 Commits

Author SHA1 Message Date
Lucas Bordeau
de9321dcd9
Fixed sync between record value context selector and record store (#5517)
This PR introduces many improvements over the new profiling story
feature, with new tests and some refactor with main :
- Added use-context-selector for getting value faster in display fields
and created useRecordFieldValue() hook and RecordValueSetterEffect to
synchronize states
- Added performance test command in CI
- Refactored ExpandableList drill-downs with FieldFocusContext
- Refactored field button icon logic into getFieldButtonIcon util
- Added RelationFieldDisplay perf story
- Added RecordTableCell perf story
- First split test of useField.. hook with useRelationFieldDisplay()
- Fixed problem with set cell soft focus
- Isolated logic between display / soft focus and edit mode in the
related components to optimize performances for display mode.
- Added warmupRound config for performance story decorator
- Added variance in test reporting
2024-05-24 16:52:05 +02:00
rostaklein
a9813447f3
feat: fetch and parse full gmail message (#5160)
first part of https://github.com/twentyhq/twenty/issues/4108
related PR https://github.com/twentyhq/twenty/pull/5081

---------

Co-authored-by: Charles Bochet <charles@twenty.com>
2024-05-20 17:29:35 +02:00
Thomas Trompette
4d479ee8ea
Remove relations for remotes (#5455)
For remotes, we will only create the foreign key, without the relation
metadata. Expected behavior will be:
- possible to create an activity. But the remote object will not be
displayed in the relations of the activity
- the remote objects should not be available in the search for relations

Also switched the number settings to an enum, since we now have to
handle `BigInt` case.

---------

Co-authored-by: Thomas Trompette <thomast@twenty.com>
2024-05-20 16:37:35 +02:00
Aditya Pimpalkar
2828492945
chore: add nx/project.json to twenty-chrome-extension (#5217)
Fix for `build` CI on `twenty-chrome-extension`

---------

Co-authored-by: Thaïs Guigon <guigon.thais@gmail.com>
2024-05-06 11:33:48 +02:00
Thaïs
fc87a51acf
fix: fix storybook:build memory allocation error in CI (#5284) 2024-05-03 19:19:21 +02:00
Weiko
abf0f4664d
Fix yoga patch user id cache (#5285)
Co-authored-by: Charles Bochet <charles@twenty.com>
2024-05-03 18:47:31 +02:00
Charles Bochet
11a7db5672
Fix workspace schema caching when user is not logged in (#5173)
In this PR:
- Follow up on #5170 as we did not take into account not logged in users
- only apply throttler on root fields to avoid performance overhead
2024-04-25 14:45:14 +02:00
Lucas Bordeau
52f4c34cd6
Cache yoga conditional schema (#5170)
In this PR I'm introducing a new patch on @graphql-yoga/nestjs package.

This patch overrides a previous patch that was made to compute the
conditionnal schema on each request,

Here we use a cache map to compute only once per schema workspace cache
version.

This allows us to have sub 100ms query time.
2024-04-25 14:01:32 +02:00
Ady Beraud
5d2d6bae08
Remove SQLite from twenty-website (#5142)
Removed SQLite from twenty-website

---------

Co-authored-by: Ady Beraud <a.beraud96@gmail.com>
Co-authored-by: Félix Malfait <felix.malfait@gmail.com>
2024-04-24 17:02:02 +02:00
martmull
87a9ecee28
D gamer007/add microsoft oauth (#5103)
Need to create a new branch because original branch name is `main` and
we cannot push additional commits
Linked to https://github.com/twentyhq/twenty/pull/4718


![image](https://github.com/twentyhq/twenty/assets/29927851/52b220e7-770a-4ffe-b6e9-468605c2b8fa)

![image](https://github.com/twentyhq/twenty/assets/29927851/7a7a4737-f09f-4d9b-8962-5a9b8c71edc1)

---------

Co-authored-by: DGamer007 <prajapatidhruv266@gmail.com>
2024-04-24 14:56:02 +02:00
Hinson Chan
3b0f81e7e1
5125 - fix npx nx start does not exit gracefully (#5133)
Fixes: https://github.com/twentyhq/twenty/issues/5125

Updated nx version that includes fix (see fix PR:
https://github.com/nrwl/nx/pull/22895, release confirming fix:
https://github.com/nrwl/nx/releases/tag/18.3.3)

<img width="291" alt="image"
src="https://github.com/twentyhq/twenty/assets/68029599/b72b4a5c-9957-445d-b8b2-8352122cade8">
2024-04-24 11:53:53 +02:00
Aditya Pimpalkar
c63ee519ea
feat: oauth for chrome extension (#4870)
Previously we had to create a separate API key to give access to chrome
extension so we can make calls to the DB. This PR includes logic to
initiate a oauth flow with PKCE method which redirects to the
`Authorise` screen to give access to server tokens.

Implemented in this PR- 
1. make `redirectUrl` a non-nullable parameter 
2. Add `NODE_ENV` to environment variable service
3. new env variable `CHROME_EXTENSION_REDIRECT_URL` on server side
4. strict checks for redirectUrl
5. try catch blocks on utils db query methods
6. refactor Apollo Client to handle `unauthorized` condition
7. input field to enter server url (for self-hosting)
8. state to show user if its already connected
9. show error if oauth flow is cancelled by user

Follow up PR -
Renew token logic

---------

Co-authored-by: Félix Malfait <felix@twenty.com>
2024-04-24 11:45:16 +02:00
Ady Beraud
0a7f82333b
Make Github stars dynamic and improve database init (#5000)
I extracted the init database logic into its own file. 
You can now run it with yarn database:init.
Added database entry for GitHub stars. 

Do you want me to remove the init route or is it used for something else
?

---------

Co-authored-by: Ady Beraud <a.beraud96@gmail.com>
Co-authored-by: Félix Malfait <felix.malfait@gmail.com>
2024-04-24 09:44:44 +02:00
Marie
ff39ba5a15
[fix] Support non latin characters in schema names (#5063)
Fixes #4943

## How was it tested?
Local (front + /metadata)
Unit tests for utils

---------

Co-authored-by: Weiko <corentin@twenty.com>
2024-04-23 13:37:29 +02:00
Pacifique LINJANJA
627a6bda29
Update twenty-front commands (#4667)
# This PR

- Moves dev and ci scripts to the `project.json` file in the
twenty-front package
- Adds a project.json file in the root of the project with the main
start command that start both twenty-server and twenty-front
applications concurrently
- Updates the script command of the root project with the start:prod
command (replacing the start command which will be used in dev with the
help of nx)
- Add a start:prod command in the twenty-front app, replacing the start
command (now used for dev purpose)

Issue ref #4645 

@charlesBochet @FelixMalfait please let me know how can I improve it

---------

Co-authored-by: Thaïs Guigon <guigon.thais@gmail.com>
2024-04-17 18:06:02 +02:00
Thomas Trompette
6fa2aee624
Introduce remote table entity (#4994)
We will require remote table entity to map distant table name and local
foreign table name.
Introducing the entity:
- new source of truth to know if a table is sync or not
- created synchronously at the same time as metadata and foreign table

Adding a few more changes:
- exception rather than errors so the user can see these
- `pluralize` library that will allow to stop adding `Remote` suffix on
names

---------

Co-authored-by: Thomas Trompette <thomast@twenty.com>
2024-04-17 10:52:10 +02:00
Lucas Bordeau
19a3be7b1b
Date picker for Date and DateTime field input (#4981)
- Implemented correct mask for Date and DateTime field in
InternalDatePicker
- Use only keyDown event and click outside in InternalDatePicker and
DateInput
- Refactored InternalDatePicker UI to have month and year displayed
- Fixed bug and synchronized date value between the different inputs
that can change it

---------

Co-authored-by: gitstart-twenty <gitstart-twenty@users.noreply.github.com>
Co-authored-by: v1b3m <vibenjamin6@gmail.com>
Co-authored-by: Matheus <matheus_benini@hotmail.com>
2024-04-16 16:58:08 +02:00
Félix Malfait
9aa24ed803
Compile with swc on twenty-server (#4863)
Experiment using swc instead of tsc (as we did the switch on
twenty-front)

It's **much** faster (at least 5x) but has stricter requirements.
I fixed the build but there's still an error while starting the server,
opening this PR for discussion.

Checkout the branch and try `nx build:swc twenty-server`

Read: https://docs.nestjs.com/recipes/swc#common-pitfalls
2024-04-14 09:09:51 +02:00
gitstart-app[bot]
efcb5dc6d4
New Datetime field picker (#4907)
### Description
New Datetime field picker

### Refs
https://github.com/twentyhq/twenty/issues/4376

### Demo


https://github.com/twentyhq/twenty/assets/140154534/32656323-972c-413a-9986-a78efffae1b4


Fixes #4376

---------

Co-authored-by: gitstart-twenty <gitstart-twenty@users.noreply.github.com>
Co-authored-by: v1b3m <vibenjamin6@gmail.com>
Co-authored-by: Matheus <matheus_benini@hotmail.com>
Co-authored-by: Lucas Bordeau <bordeau.lucas@gmail.com>
Co-authored-by: Charles Bochet <charles@twenty.com>
2024-04-13 19:07:51 +02:00
brendanlaschke
ca9cc86742
Storybook fix dark mode (#4865)
preview has now also a dark background & added a one click change theme
button

<img width="994" alt="Bildschirmfoto 2024-04-06 um 18 27 45"
src="https://github.com/twentyhq/twenty/assets/48770548/95f12617-e48f-4492-9b51-13410aff43ee">
2024-04-11 17:28:12 +02:00
Félix Malfait
65e665c74c
Add Sentry types to dependencies (#4825)
Someone reported an error during install that might be due to missing
types import.
2024-04-04 19:09:49 +02:00
Thaïs
c5349291c8
chore: setup twenty-ui absolute path alias (#4732)
Split from https://github.com/twentyhq/twenty/pull/4518

- Setup `@ui/*` as an internal alias to reference `twenty-ui/src`.
- Configures twenty-front to understand the `@ui/*` alias on development
mode, so twenty-ui can be hot reloaded.
- When building on production mode, twenty-front needs twenty-ui to be
built beforehand (which is automatic with the `dependsOn` option).
- Configures twenty-front to understand the `@ui/*` alias when launching
tests, so there is no need to re-build twenty-ui for tests.

---------

Co-authored-by: Lucas Bordeau <bordeau.lucas@gmail.com>
2024-04-04 15:38:01 +02:00
Thaïs
bf8ee99ebb
chore: use common eslint config for most packages (#4705)
Split from https://github.com/twentyhq/twenty/pull/4518

Related to #4766 

Mutualizes eslint config between projects.
I didn't include `twenty-server` in this PR as this was causing too many
lint errors.
2024-04-04 12:05:26 +02:00
Charles Bochet
514417245a
Add JsDom to server dependencies (#4740)
We were missing `JsDom` dependencies in the package.json generated by nx
while running `twenty-server`: `yarn nx build:packageJson`

Detailed explanation: 
- we are currently using nx paradigm which is to put dependencies of all
projets at root, which enables global package migrations for the whole
monorepo
- for production containers, we only want specific project dependency to
be added. This is done by running `yarn nx build:packageJson` on
`twenty-server`. Nx is statically analyzing twenty-server dependencies
and generating a tailored package.json that production containers can
later use.
- However, `nx` static analysis is not flawless and is missing some
packages. We are going to stop using it as the value is not there yet
but the burden for developers is high. The guideline is to put back
project dependencies into specific package `package.json`
- Therefore, I'm adding `jsdom` to twenty-server `package.json`
2024-04-02 12:07:12 +02:00
Thaïs
a3e5cf37b0
chore: upgrade Nx to v18.1.3 (#4706)
Split from https://github.com/twentyhq/twenty/pull/4518

- Upgrades dependencies and applies automatic config migrations with the
command: `npx nx migrate nx` (see
https://nx.dev/nx-api/nx/documents/migrate)
- Fixes lint errors after upgrading `@typescript-eslint`

Note: it was not possible (for now) to migrate Nx to the latest stable
version (v18.2.1) because it upgrades Typescript to v5.4.3, which seems
to cause a bug on install when Yarn tries to apply its native patches.
Might be a bug on the Yarn side.
2024-04-01 13:16:50 +02:00
brendanlaschke
aacb3763e7
Fix overlay scroll gaps (#4512)
* fix overlay scroll leaving gap

* fixed tests

---------

Co-authored-by: Félix Malfait <felix.malfait@gmail.com>
2024-03-31 10:53:37 +02:00
martmull
ab028b8c22
60 fix svg xcc vulnerability (#4660)
* Add domPurify

* Sanitize svg files

* Add is-svg package

* Use isSvg package

* Revert "Use isSvg package"

This reverts commit 05014b5107.

* Revert "Add is-svg package"

This reverts commit ad3e206ea6.

* Code review returns
2024-03-26 16:10:45 +01:00
Charles Bochet
2ae59a801f Fix missing lodash type dependency breaking front container build 2024-03-25 16:26:28 +01:00
bosiraphael
96cad2accd
4398 decouple contacts and companies creation from messages import (#4590)
* emit event

* create queue and listener

* filter participants with role 'from'

* create job

* Add job to job module

* Refactoring

* Refactor contact creation in CreateCompanyAndContactService

* update job

* wip

* add getByHandlesWithoutPersonIdAndWorkspaceMemberId to calendar event attendee repository

* refactoring

* refactoring

* Revert "refactoring"

This reverts commit e5434f0b87.

* fix nest imports

* add await

* fix contact creation condition

* emit contact creation event after calendar-full-sync

* add await

* add missing transactionManager

* calendar event attendees personId update is working

* messageParticipant and calendarEventAttendee update is working as intended

* rename module

* fix lodash import

* add test

* update package.json
2024-03-22 18:44:14 +01:00
bosiraphael
5665656b05
4489 timebox finish google calendar full sync (#4615)
* add lodash differenceWith

* add awaits

* update sync cursor is working

* add logs

* use isSyncEnabled information to enqueue jobs

* add decorator InjectObjectMetadataRepository

* fix gmail-full-sync
2024-03-22 18:10:55 +01:00
Quentin G
1aa48d3bf7
feat: merge front and server dockerfiles and optimize build (#4589)
* feat: merge front and server dockerfiles and optimize build

* fix: update image label

* fix: bring back support for REACT_APP_SERVER_BASE_URL injection at runtime

* fix: remove old entries & add nx cache in dockerignore

* feat: generate frontend config at runtime using Nest

* fix: format and filename

* feat: use the EnvironmentService and leave default blank

* feat: add support for DB migrations
2024-03-21 19:22:21 +01:00
Lucas Bordeau
cc0e3c8a9a
Fixed TS error with blocknote/react package (#4601) 2024-03-21 12:10:09 +01:00
Jérémy M
e5c1309e8c
feat: wip server folder structure (#4573)
* feat: wip server folder structure

* fix: merge

* fix: wrong merge

* fix: remove unused file

* fix: comment

* fix: lint

* fix: merge

* fix: remove console.log

* fix: metadata graphql arguments broken
2024-03-20 16:23:46 +01:00
Aditya Pimpalkar
da12710fe9
feat: multi-workspace (frontend) (#4232)
* select workspace component

* generateJWT mutation

* workspaces state and hooks

* requested changes

* mutation fix

* requested changes

* user workpsace delete call

* migration to drop and createt user workspace

* revert select props

* add DropdownMenu

* seperate multi-workspace dropdown as component

* Signup button displayed accurately

* update seed data for multi-workspace

* lint fix

* lint fix

* css fix

* lint fix

* state fix

* isDefined check

* refactor

* add default workspace constants for logo and name

* update migration

* lint fix

* isInviteMode check on sign-in/up

* removeWorkspaceMember mutation

* import fixes

* prop name fix

* backfill migration

* handle edge cases

* refactor

* remove migration query

* delete user on no-workspace found condition

* emit workspaceMember.deleted

* Fix event class and unrelated fix linked to a previously missing dependency

* Edit migration (I did it in prod manually)

* Revert changes

* Fix tests

* Fix conflicts

---------

Co-authored-by: Félix Malfait <felix.malfait@gmail.com>
2024-03-20 14:43:41 +01:00
Charles Bochet
cfb0cce9b8
Refactor Views by cleaning the code, relying on apolloCache and improving performances (#4516)
* Wip refactoring view

* Post merge conflicts

* Fix review

* Add create view capability

* Fix create object missing view

* Fix tests
2024-03-20 14:21:58 +01:00
brendanlaschke
017b09ba35
Blocknote custom slash menu (#4517)
blocknote v12, cleaned up blockschema & specs, added custom slash menu
2024-03-20 08:38:05 +01:00
Jérémy M
94487f6737
feat: refactor folder structure (#4498)
* feat: wip refactor folder structure

* Fix

* fix position

---------

Co-authored-by: Charles Bochet <charles@twenty.com>
2024-03-15 14:40:58 +01:00
Félix Malfait
42e86c7c82
Enable backend to serve frontend (#4461)
Basic POC to have frontend served by backend
2024-03-14 11:53:10 +01:00
Abdullah
8c0680b918
Setup the foundation for Twenty UI library. (#4423)
* feat: create a separate package for twenty-ui, extract the pill component with hard-coded theme values into it, and use the component inside twenty-front to complete the setup

* feat: extract the light and the dark theme into twenty-ui and update the AppThemeProvider component inside twenty-front to consume themes from twenty-ui

* fix: create a decorator inside preview.tsx to provide a default theme to storybook development server

* fix: remove redundant type declarations and revert back the naming convention for theme declarations

* fix: introduce a default value for pill label within the story for development server

* fix: introduce the nx script into package.json for twenty-ui and resolve imports for theme type within the package

* fix: remove the pill component from the twenty-front package along with the story for it

* fix: revert the package versions to those before running the nx cli command for storybook init

* feat: update readme to include details for building the ui library and starting the storybook development server

* fix: include details about twenty-ui inside jest.config for twenty-front to complete front-jest job

* - Added preview head for font
- Added theme addon for light/dark switch
- Added ComponentDecorator

---------

Co-authored-by: Lucas Bordeau <bordeau.lucas@gmail.com>
2024-03-13 14:21:18 +01:00
Charles Bochet
4e1e4e2c4c
Upgrade documentation UI component rendering (#4445)
Upgrade documenation UI component rendering
2024-03-13 13:26:46 +01:00
gitstart-app[bot]
17511be0cf
TWNTY-3794 - ESLint rule: only take explicit boolean predicates in if statements (#4354)
* ESLint rule: only take explicit boolean predicates in if statements

Co-authored-by: v1b3m <vibenjamin6@gmail.com>
Co-authored-by: Toledodev <rafael.toledo@engenharia.ufjf.br>

* Merge main

Co-authored-by: v1b3m <vibenjamin6@gmail.com>
Co-authored-by: Toledodev <rafael.toledo@engenharia.ufjf.br>

* Fix frontend linter errors

Co-authored-by: v1b3m <vibenjamin6@gmail.com>
Co-authored-by: Toledodev <rafael.toledo@engenharia.ufjf.br>

* Fix jest

Co-authored-by: v1b3m <vibenjamin6@gmail.com>
Co-authored-by: Toledodev <rafael.toledo@engenharia.ufjf.br>

* Refactor according to review

Co-authored-by: v1b3m <vibenjamin6@gmail.com>
Co-authored-by: Toledodev <rafael.toledo@engenharia.ufjf.br>

* Refactor according to review

Co-authored-by: v1b3m <vibenjamin6@gmail.com>
Co-authored-by: Toledodev <rafael.toledo@engenharia.ufjf.br>

* Fix lint on new code

Co-authored-by: v1b3m <vibenjamin6@gmail.com>
Co-authored-by: Toledodev <rafael.toledo@engenharia.ufjf.br>

---------

Co-authored-by: gitstart-twenty <gitstart-twenty@users.noreply.github.com>
Co-authored-by: v1b3m <vibenjamin6@gmail.com>
Co-authored-by: Toledodev <rafael.toledo@engenharia.ufjf.br>
2024-03-09 10:48:19 +01:00
Thaïs
92aa0bd888
feat: add Month headers to Show Page Calendar tab (#4326)
Closes #4288
2024-03-08 06:22:23 -03:00
Weiko
41bed57be9
[backend] add cache storage module (#4320)
* [backend] add cache storage module

* update docs

* update default TTL to a week
2024-03-07 14:07:01 +01:00
Thaïs
91e5e7598b
refactor: use react-hook-form in Settings Data Model Object pages (#4271)
Related issue: #3836
2024-03-05 07:52:19 -03:00
bosiraphael
735e75b3b1
Fix domain name parsing on company creation (#4297)
* add domain parsing library

* change package for psl

* trying to fix error

* fix

* update

* remove unused function
2024-03-04 17:50:41 +01:00
Tate Thurston
8625a71f15
Add export as csv (#4034)
* Add export as csv

Resolves 2183.

* collect over paginated data

* refactor

* add tests

* parameterize pageSize (limit)

* use pageInfo for onCompleted callback

* json column variable naming

* omit relations from csv exports
2024-02-29 17:45:44 +01:00
gitstart-app[bot]
f543191552
TWNTY-3825 - ESLint rule: const naming (#4171)
* ESLint rule: const naming

Co-authored-by: v1b3m <vibenjamin6@gmail.com>
Co-authored-by: KlingerMatheus <klinger.matheus@gitstart.dev>

* Refactor according to review

Co-authored-by: v1b3m <vibenjamin6@gmail.com>
Co-authored-by: KlingerMatheus <klinger.matheus@gitstart.dev>

* refactor: Reverts changes on `twenty-server`

Co-authored-by: KlingerMatheus <klinger.matheus@gitstart.dev>
Co-authored-by: v1b3m <vibenjamin6@gmail.com>

---------

Co-authored-by: gitstart-twenty <gitstart-twenty@users.noreply.github.com>
Co-authored-by: v1b3m <vibenjamin6@gmail.com>
Co-authored-by: KlingerMatheus <klinger.matheus@gitstart.dev>
2024-02-25 13:52:48 +01:00
Kanav Arora
a9b0f88521
MQ Facepaint introduced (#4169)
* MQ Facepaint introduced

* Remove useDeviceType

---------

Co-authored-by: Félix Malfait <felix.malfait@gmail.com>
2024-02-24 21:38:27 +01:00
Thaïs
3d809d5317
feat: add Display calendar settings (#4164)
* feat: add Color calendar setting

Closes #4067

* fix: fix wrong imports

* feat: add Display calendar settings

Closes #4068

* feat: add 12h/24h in Format option labels

* fix tests

* Fix

* Fix

---------

Co-authored-by: Charles Bochet <charles@twenty.com>
2024-02-24 12:50:32 +01:00
martmull
d4fac2ea70
45 create billing core tables (#4096)
* Add self billing feature flag

* Add two core tables for billing

* Remove useless imports

* Remove graphql decorators

* Rename subscriptionProduct table
2024-02-21 18:17:09 +01:00
Thaïs
ec20117e80
chore: make twenty-server nest command scripts depend on twenty-email… (#4055)
chore: make twenty-server nest command scripts depend on twenty-emails build

Closes #4013
2024-02-20 14:35:09 +01:00
brendanlaschke
595b2f9e6f
Webhook Docs (#3966)
* add webhook docs, openapi v3.1, stoplight v8

* *.*
2024-02-16 15:01:37 +01:00
Jérémy M
990cb107a1
feat: workspace health target column map fix (#3932)
* feat: workspace health fix target column map

* fix: remove log

* feat: refactor health fixer

* fix: default-value issue and health check not working with composite

* fix: enhance target column map fix

* feat: create workspace migrations for target-column-map issues

* feat: enhance workspace-health issue detection
2024-02-15 18:04:12 +01:00
Charles Bochet
4613f64910
Add proper ORM and postgres support (#3978)
* Add postgresql support

* Fixes

* Fix perfs
2024-02-14 17:53:50 +01:00
Weiko
0b2ffb0ee6
add rimraf to server dependencies (#3977) 2024-02-14 16:56:37 +01:00
Thaïs
e011ecbd6f
POC: generate twenty-server package.json with Nx (#3654)
* POC: generate twenty-server package.json with Nx

* Re-add passport

* Fix instal

---------

Co-authored-by: Charles Bochet <charles@twenty.com>
2024-02-13 22:16:21 +01:00
Weiko
458e8c839f
Add workspacePreQueryHook module (#3879)
* rebase

* reorganise messaging folders

* fix

* fix after review

* fix yarn lock
2024-02-13 18:23:29 +01:00
Kanav Arora
263c940da6
Added Single Command for Frontend + Backend (#3909)
* Added single command

* Fix according to review

---------

Co-authored-by: Charles Bochet <charles@twenty.com>
2024-02-13 12:23:29 +01:00
Abdullah
1265dc74d0
Closes #2413 - Building a chrome extension for twenty to store person/company data into a workspace. (#3430)
* build: create a new vite project for chrome extension

* feat: configure theme per the frontend codebase for chrome extension

* feat: inject the add to twenty button into linkedin profile page

* feat: create the api key form ui and render it on the options page

* feat: inject the add to twenty button into linkedin company page

* feat: scrape required data from both the user profile and the company profile

* refactor: move modules into options because it is the only page using react for now

* fix: show add to twenty button without having to reload the single page application

* fix: extract domain of the business website instead of scrapping the industry type

* feat: store api key to local storage and open options page when trying to store data without setting a key

* feat: send data to the backend upon click and store it to the database

* fix: open options page upon clicking the extension icon

* fix: update terminology from user to person to match the codebase convention

* fix: adopt chrome extension to monorepo approach using nx and get the development server working

* fix: update vite config for build command to work per the requirement

* feat: add instructions in the readme file to install the extension for local testing

* fix: move server base url to a dotenv file and replace the hard-coded url

* feat: permit user to configure a custom route for the server from the options page

* fix: fetch api key and route from local storage and display on options page to inform users of their choices

* fix: move front base url to dotenv and replace the hard-coded url

* fix: remove the trailing slash from person and company linkedin username

* fix: improve code commenting to explain implementation somewhat better

* ci: introduce a workflow to build chrome extension to ensure it can be published

* fix: format files to display code in a consistent manner per the prettier configuration in codebase

* fix: improve the commenting significantly to explain important and hard-to-understand parts of the code

* fix: remove unused permissions from the manifest file for publishing to the chrome web store

* Add nx

* Fix vale

---------

Co-authored-by: Charles Bochet <charles@twenty.com>
2024-02-12 12:30:23 +01:00
Lucas Bordeau
cca72da708
Activity cache injection (#3791)
* WIP

* Minor fixes

* Added TODO

* Fix post merge

* Fix

* Fixed warnings

* Fixed comments

* Fixed comments

* Fixed naming

* Removed comment

* WIP

* WIP 2

* Finished working version

* Fixes

* Fixed typing

* Fixes

* Fixes

* Fixes

* Naming fixes

* WIP

* Fix import

* WIP

* Working version on title

* Fixed create record id overwrite

* Removed unecessary callback

* Masterpiece

* Fixed delete on click outside drawer or delete

* Cleaned

* Cleaned

* Cleaned

* Minor fixes

* Fixes

* Fixed naming

* WIP

* Fix

* Fixed create from target inline cell

* Removed console.log

* Fixed delete activity optimistic effect

* Fixed no title

* Fixed debounce and title body creation

---------

Co-authored-by: Charles Bochet <charles@twenty.com>
2024-02-09 14:51:30 +01:00
Charles Bochet
3fc18aeec1 Fix twenty-server build 2024-02-09 11:18:58 +01:00
Charles Bochet
3d7b5902e6 Fix twenty-server build 2024-02-09 11:14:02 +01:00
Weiko
99e2dd6899
[messaging] Add messageParticipant matching once people emails are updated (#3887)
* poc nest event emitter

* add match message participant listener

* add workspacemember listener

* fix after review

* fix deep-equal
2024-02-08 17:42:33 +01:00
Joe S
850eab8f8f
Add rate limiting in the server using built in Nest.js capability (#3566)
* Add rate limiting in the server using built in Nest.js capability

* Generatekey based on ip address when an http request is sent

* Update env var types to number for ttl and limit

* Remove unused env variables

* Use getRequest utility function

* fix: remove dist from path

* fix: adding .env variables

* fix: remove unused functions

* feat: throttler plugin

* Fix according to review

---------

Co-authored-by: Jérémy Magrin <jeremy.magrin@gmail.com>
Co-authored-by: Charles Bochet <charles@twenty.com>
2024-02-07 18:11:32 +01:00
brendanlaschke
230e957119
blocknote update 0.11.2 (#3766) 2024-02-05 15:02:33 +01:00
Félix Malfait
a5989a470c
Improve Documentation (#3795)
* Begin docs improvement

* Keep improving documentation

* Upgrade Docusarus

* Fix broken links
2024-02-05 15:01:37 +01:00
Anoop P
c56153cab1
Update sandpack-react to latest version (#3770)
fix: update sandpack-react to resolve broken documentation
2024-02-02 18:13:15 +01:00
Jérémy M
cdc51add7d
feat: add user to sentry (#3467)
* feat: wip add user to sentry

* feat: wip interceptor

* feat: wip add user to sentry

* feat: add user into sentry errors

* fix: hide stack trace in production

* fix: properly log commands and handle exceptions

* fix: filter command exceptions

* feat: handle jobs errors
2024-02-01 16:14:08 +01:00
martmull
68e65e9526
Fix zapier (#3688)
* Fix zapier testing

* Fix zapier create action

* Add timezone to dates
2024-02-01 15:19:42 +01:00
Charles Bochet
f68de1a299
Board improvements (#3694)
* New board improvements

* Improve board

* Fix
2024-01-30 15:24:03 +01:00
Jérémy M
73f6876641
feat: workspace sync (#3505)
* feat: wip workspace sync

* feat: wip lot of debugging

* feat: refactor and fix sync

* fix: clean

fix: clean

* feat: add simple comparator tests

* fix: remove debug

* feat: wip drop table

* fix: main merge

* fix: some issues, and prepare storage system to handle complex deletion

* feat: wip clean and fix

* fix: reflect issue when using array instead of map and clean

* fix: test & sync

* fix: yarn files

* fix: unecesary if-else

* fix: if condition not needed

* fix: remove debug

* fix: replace EQUAL by SKIP

* fix: sync metadata relation not applied properly

* fix: lint issues

* fix: merge issue
2024-01-30 14:40:55 +01:00
Thaïs
a654205dbc
chore: set up twenty-emails config so build isn't needed in development (#3619)
* chore: set up twenty-emails config so build isn't needed in development

* fix: fix script dependency

* chore: use @vitejs/plugin-react-swc

* Remove useless dependancy

* Fix typing

* chore: use baseUrl in twenty-emails

* chore: fix docker server prod build

* refactor: optimize Docker file and tsconfig

* fix: fix WORKDIR in docker

---------

Co-authored-by: martmull <martmull@hotmail.fr>
2024-01-29 06:17:12 -03:00
martmull
0982c78a85
Fix missing package in twenty-emails (#3631) 2024-01-26 10:53:38 +01:00
bosiraphael
b0c14ba5b9
3571 remove reply quotations from emails (#3630)
* lib is working

* update

* plural
2024-01-25 18:26:29 +01:00
Charles Bochet
3f0743493b
Fix Continuous Deployment script after adding twenty-emails package (#3589)
* Fix cd

* Fix server

* Fix server

* Fix server

* Fix server

* Fix

* Fix docs

* Fix
2024-01-23 12:30:03 +01:00
Charles Bochet
a7265fa3b4
Remove flag relation select (#3588)
* Remove feature flag on relation and select

* Move packages back to twenty-server to enable smaller build without using nx

* Fix package.json
2024-01-23 09:59:00 +01:00
martmull
e358d677f9
Move emails to dedicated package (#3542)
* Add new package

* Add twenty-emails package

* Use generated files from twenty-emails in twenty-server

* Fix deleted file

* Import emails templates properly
2024-01-22 16:21:56 +01:00
gitstart-app[bot]
d8c9a94e14
TWNTY-3381 - Add tests for modules/apollo (#3530)
Add tests for `modules/apollo`

Co-authored-by: gitstart-twenty <gitstart-twenty@users.noreply.github.com>
Co-authored-by: v1b3m <vibenjamin6@gmail.com>
2024-01-18 11:25:27 +01:00
Charles Bochet
2628ee0f27 Revert blocknote upgrade because it's breakind design 2024-01-18 10:56:39 +01:00
brendanlaschke
f6f4e6c769
Update blocknote (#3517)
* update blocknote, remove feature flag

* Fix backend

---------

Co-authored-by: Charles Bochet <charles@twenty.com>
2024-01-18 09:40:00 +01:00
martmull
bb91917ff8
Improve webhook (#3459)
* Add trigger record

* Merge triggers

* Merge creates

* Fix libraries

* Fix create merged key

* Rename file

* Remove list Record Ids

* Revert "Rename file"

This reverts commit 2e72e05793.

* Revert "Revert "Rename file""

This reverts commit e2d93fa027.

* Revert "Remove list Record Ids"

This reverts commit 6653fb6ccd.

* Remove namePlural field

* Use name singular for webhooks

* Send webhook metadata

* Extract resource from zapier webhook

* Fix package.json

* Fix package.json

* Update payload

* Fix package.json

* Update payload

* Update payload

* Rename file

* Use wildcard in webhook events

* Fix nameSingular

* Code review returns

* Code review returns
2024-01-16 15:31:09 +01:00
Charles Bochet
e6c9e8d09b Upgrade sentry profiling package 2024-01-11 22:50:01 +01:00
Thaïs
985c2f321e
feat: add link to relation filtered table in Record Show Page (#3261)
* feat: add link to relation filtered table in Record Show Page

Closes #3125

* refactor: use generateFindManyRecordsQuery for optimization

* Fixes from review

* Minor fixes

---------

Co-authored-by: Lucas Bordeau <bordeau.lucas@gmail.com>
2024-01-11 20:51:06 +01:00
martmull
b3d9bed91d
Enforce email templating (#3355)
* Add react-email

* WIP

* Fix import error

* Rename services

* Update logging

* Update email template

* Update email template

* Add Base Email template

* Move to proper place

* Remove test files

* Update logo

* Add email theme

* Revert "Remove test files"

This reverts commit fe062dd051.

* Add email theme 2

* Revert "Revert "Remove test files""

This reverts commit 6c6471273a.

* Revert "Revert "Revert "Remove test files"""

This reverts commit f851333c24.

* Revert "Revert "Revert "Revert "Remove test files""""

This reverts commit 7838e19e88.

* Fix theme
2024-01-11 20:29:20 +01:00
Lucas Bordeau
e2bdf0ce45
Recursively turn relation connection into records (#3334)
* Use new ObjectRecordConnection

* Use new records without connection in GraphQLView

* Added playwright for storybook tests

* Fixed lint

* Fixed test and tsc

* Fixed storybook tests

* wip tests

* Added useMapConnectionToRecords unit test

---------

Co-authored-by: Charles Bochet <charles@twenty.com>
2024-01-11 20:27:59 +01:00
brendanlaschke
f34516d422
Update react-hotkeys-hook (#3269)
- update react-hotkeys-hook
2024-01-11 08:47:38 +01:00
Lucas Bordeau
71034849d3
Added vite-plugin-checker to twenty-front (#3289)
* Added vite-plugin-checker to twenty-front

* Installed vite-plugin-checker globally
2024-01-08 12:01:58 +01:00
martmull
ae5558d8b5
Add mail driver (#3205)
* Add node mailer packages

* Init mailer module

* Add logger transport

* Use env variable to get transport

* Revert "Add node mailer packages"

This reverts commit 3fb954f0ca.

* Add nodemailer

* Use driver pattern

* Use logger

* Fix yarn install

* Code review returns

* Add configuration examples for smtp

* Fix merge conflict

* Add missing packages

* Fix ci
2024-01-05 16:08:19 +01:00
Charles Bochet
f7034d6e7d
Embrace nx monorepo structure with root package.json (#3255)
* Upgrade to node 18.17.1 and regroup dependencies in root package.json

* Sort package.json

* Fix lint

* Migrate zapier
2024-01-05 14:59:58 +01:00
Jeong Min Cho
4552b88435
Added @graphiql/explorer-plugin in twenty docs package (#3244)
* Added plugin-explorer in twenty-docs gql page and updated graphiql version

* Cleaned up graphql file (#3087)

* Added plugin-explorer style and modified useEffect to adapt it (#3087)

* Updated the yarn lock file (#3087)
2024-01-05 09:17:28 +01:00
Charles Bochet
c15e138d72
Fix nx lint setup (#3234)
* Fix nx lint setup

* Fixes

* Fixes

* Add missing metadata

Fixes

Fix

Fixes

* Fix
2024-01-04 16:39:57 +01:00
Thaïs
8483cf0b4b
POC: chore: use Nx workspace lint rules (#3163)
* chore: use Nx workspace lint rules

Closes #3162

* Fix lint

* Fix lint on BE

* Fix tests

---------

Co-authored-by: Charles Bochet <charles@twenty.com>
2024-01-03 23:07:25 +01:00
Félix Malfait
858c294f14
Website improvements 4 (#3182)
* Add contributor individual page

* Improve mobile menu

* Fix

* Remove yarn.lock from twenty-website

* Add yarn to gitingore

* Fix linter
2023-12-31 10:41:53 +01:00
Félix Malfait
c422045ea6
Marketing improvements 3 (#3175)
* Improve marketing website

* User guide with icons

* Add TOC

* Linter

* Basic GraphQL playground

* Very basic contributors page

* Failed attempt to integrate REST playground

* Yarn

* Begin contributors DB

* Improve contributors page
2023-12-29 11:17:32 +01:00
Félix Malfait
5ef5bbdc4d
Marketing website POC (#3139)
First website POC
2023-12-23 10:08:55 +01:00
Deepak Kumar
46ab88cb9c
GH-2829 Add Sentry on frontend (#3111)
* GH-2829 pass sentry dsn key from backend in ClientConfig

* GH-2829 add Sentry library on frontend

* GH-2829 fetch dsnKey in GQL and add a state

* GH-2829 initialize Sentry on frontend

* GH-2829 fix linting issues

* Update yarn.lock

* GH-2829 update graphql schema for clientConfig

* GH-2829 remove Sentry comments

* GH-2829 rename sentry state

* GH-2829 rename dsnKey to dsn

* GH-2829 refactor to use componentEffect for sentry initialization

* GH-2829 fix linting issues

* GH-2829 update Graphql types

---------

Co-authored-by: Charles Bochet <charles@twenty.com>
2023-12-21 23:50:24 +01:00
martmull
b1841d0e2f
2114 timebox make sure the zapier integrations supports custom objects (#3091)
* Fix build command

* Add hidden trigger to fetch object names

* Remove useless actions

* Rename createObject to createRecord
2023-12-20 18:41:30 +01:00
bosiraphael
5afcab4e78
3011 fill the messagerecipient table when fetching messages (#3073)
* wip

* trying to parse display names and emails

* add nodemailer mailparser

* mail parsing is working

* add personId and workspaceMemberId

* add date to messages

* Fix PR

* Run tsc on bigger machine

* Fix lint

---------

Co-authored-by: Charles Bochet <charles@twenty.com>
2023-12-19 17:08:54 +01:00
Félix Malfait
fff51a2d91
Basic data enrichment (#3023)
* Add Enrich to frontend

* Naive backend implementation

* Add work email check

* Rename Enrich to Quick Action

* Refactor logic to a separate service

* Refacto to separate IntelligenceService

* Small fixes

* Missing Break statement

* Address PR comments

* Create company interface

* Improve edge case handling

* Use httpService instead of Axios

* Fix server tests
2023-12-18 15:45:30 +01:00
martmull
3ac4102c3c
2915 rest api documentation (#3020)
* Init rest-api page

* Add ugly form to fetch open api schema

* Clean code

* Make the form design more acceptable

* Update doc

* Use local storage

* Update design

* Add isLoading

* Fix typo

* Fix long lines

* Code review returns

* Remove staging and local url from servers
2023-12-15 18:13:13 +01:00