Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

4810 display participants in the right drawer of the calendar event #4896

Conversation

bosiraphael
Copy link
Contributor

Closes #4810

  • Introduces a new component ExpandableList which uses intersection observers to display the maximum number of elements possible

Copy link
Member

@charlesBochet charlesBochet left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good work!
I've left comments!
Could we add stories on all these components?

@@ -0,0 +1,109 @@
import React, { ReactElement, useState } from 'react';
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

move it to ui or nobody will find it! We are missing a story on this component too :)

import React from 'react';
import { useInView } from 'react-intersection-observer';

export const IntersectionObserverWrapper = ({
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm a bit worried about performances here to be honnest. Having one on the page is fined. Having many will impact the performance. I don't see a workaround. It looks like we need:

  • this ExpandableList component or the one that has been forced to 2 chips for ActivityTarget
  • an expandableList for table view that do not care about the intersection observer and is hiding the overflow with CSS without computing anything

I would love to discuss this with Design

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

variant === 'bold' ? theme.font.weight.medium : theme.font.weight.regular};
`;

export const ParticipantChip = ({
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

can this be abstracted (not necessarily in this PR) to a regular chip? Feels weird to have something specific for Participant

Copy link
Member

@charlesBochet charlesBochet left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you! I still think we could add more stories but we can create issues for that!

@bosiraphael bosiraphael merged commit c0b3a87 into main Apr 12, 2024
6 of 9 checks passed
@bosiraphael bosiraphael deleted the 4810-display-participants-in-the-right-drawer-of-the-calendar-event branch April 12, 2024 08:33
arnavsaxena17 pushed a commit to arnavsaxena17/twenty that referenced this pull request Oct 6, 2024
…wentyhq#4896)

Closes twentyhq#4810

- Introduces a new component `ExpandableList` which uses intersection
observers to display the maximum number of elements possible
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Display participants in the right drawer of the calendar event
3 participants