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

Activity editor add File block #3146

Merged

Conversation

brendanlaschke
Copy link
Contributor

Bildschirmaufnahme.2023-12-23.um.13.38.36.mov

For now it works but its not quite production ready :)
But I think with a bit of work on cmd+c/v and drop events this could work really well - maybe we also want to change the design of the block or convert it to an inline content?

@FelixMalfait
Copy link
Member

Oh this is super cool!

@brendanlaschke brendanlaschke marked this pull request as ready for review December 29, 2023 13:57
@lucasbordeau lucasbordeau self-requested a review January 2, 2024 10:04
@lucasbordeau
Copy link
Contributor

I tried to upload a file but I only see a request UpdateOneActivity and then nothing changes, even if I refresh the page.

Copy link
Contributor

@lucasbordeau lucasbordeau left a comment

Choose a reason for hiding this comment

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

I can't get upload to work when I test, do I need to enable some feature flag ?

@brendanlaschke
Copy link
Contributor Author

brendanlaschke commented Jan 2, 2024

I can't get upload to work when I test, do I need to enable some feature flag ?

The upload method was behind the image block feature flag - it's fixed now :)

@charlesBochet
Copy link
Member

@lucasbordeau Leaving this one to you as you are working on this part


import { FileBlock } from './FileBlock';

export const blockSpecs: any = {
Copy link
Contributor

Choose a reason for hiding this comment

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

Is it possible to have a type here ?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Im not sure about the types on this one - it's kind of weird what is expected by the Blockeditor generics. Maybe you or someone else has an idea how to do this the right way :)

@lucasbordeau lucasbordeau merged commit 9def3d5 into twentyhq:main Jan 5, 2024
4 checks passed
@brendanlaschke brendanlaschke deleted the acitvities-editor-file-block branch January 15, 2024 14:22
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.

None yet

4 participants