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

ViewCampaignPage.tsx: Refactoring #1540

Closed

Conversation

sashko9807
Copy link
Member

@sashko9807 sashko9807 commented Aug 2, 2023

The current ViewCampaignPage, is structured in a kind of an anti-pattern way, for react. Will give better explanation later.

Closes #1536 Hopefully

@github-actions
Copy link

github-actions bot commented Aug 2, 2023

❌ Not all tests have run for this PR. Please add the run tests label to trigger them.

@igoychev
Copy link
Contributor

igoychev commented Aug 8, 2023

are you working on this one?
Just thought to test it and saw the text description is wider than before.
Screenshot 2023-08-08 at 09 33 33

@ani-kalpachka
Copy link
Member

ani-kalpachka commented Aug 9, 2023

@igoychev @sashko9807 This style issue is most probably caused by removing <StyledGrid item xs={12} md={8}> in CampaignDetails.tsx.

@sashko9807
Copy link
Member Author

sashko9807 commented Aug 9, 2023

are you working on this one? Just thought to test it and saw the text description is wider than before.

@igoychev did you by any chance, use the mxeditor to insert the text of the campaign from the image above, because I am not able to reproduce this in local environment(image below).

Its good thing to keep in mind when , that when inserting an image or video using React Quill, the editor adds its own CSS classes to the elements, thus switching to MxEditor, is not exactly backwards compatible, with campaigns whose texts were added using React Quill.

That's the main reason I implemented the QuillStyleWrapper, though it might still need some adjustments.(I haven't tried it with text inputs from mxeditor)

image

@sashko9807
Copy link
Member Author

Seems like removing unnecessary re-renders doesn't actually solve the issue, as I thought.
Closing for now, as there isn't any visible performance benefits, and could be re-implemented later on.

@sashko9807 sashko9807 closed this Aug 9, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Video load slowly
3 participants