Skip to content
This repository has been archived by the owner on Jan 5, 2019. It is now read-only.

UseCase: Delete a picture #38

Closed
tordans opened this issue Nov 1, 2018 · 1 comment
Closed

UseCase: Delete a picture #38

tordans opened this issue Nov 1, 2018 · 1 comment

Comments

@tordans
Copy link

tordans commented Nov 1, 2018

This might be solved in a way I did not understand yet.
But just in case it is not, here is my use case:

In my mind, using actiontext in an app that is behind a login (eg basecamp) is different from using it publicly, eg to create a public blog post or edit a public profile description.
The main difference is the importance of "truly" deleting an image.

UseCase

  • I create a public blogpost with actiontext and publish it. The post has a few images that are now saved in the cloud.
  • For some reason, I need to delete one or more of those images. Because of copy right. Or privacy reasons. Or …
  • Fist step is to remove it from the body of the blogpost in actiontext and update the post.

However, I assume this does not trigger the deletion of the image itself in the cloud. Which in this use case is required to really comply with eg privacy laws.

A sub-case for this would be to upload images in trix but then abandon the post (not click save). I am not sure if the image is already in the cloud, but if it is, its a similar problem: How do I get rid of it. However, in this case its less urgent since the image was not public yet; its just an image I want deleted that is on someones cloud storage, somewhere.

Based on this, I wonder …

  • … should the recommended use of actiontext include a list of files associated with the text-block, so I have a place where I can click the "delete this image"-button?
  • … should/can this list be synced to the content of the text?
    • as in: remove or warn if I delete an image that is in use
    • or: the editor notices the fact that I removed an image from my blogpost and asks me if I want to delete it from the "harddrive" as well
  • … should this list be part of the trix-UI or something somewhere outside the editor-box?
  • … is there a way to create a backoffice view that lists images that are associated with a text-block but not used inside the text (and similar cases, like the sub-case above). Eg: does actiontext save the associated image ids or just the public url as part of the blogpost?

Thanks

@georgeclaghorn
Copy link
Contributor

georgeclaghorn commented Nov 1, 2018

However, I assume this does not trigger the deletion of the image itself in the cloud.

It does. Action Text uses an Active Storage writer method under the hood, which causes files removed from the rich-text body to be purged.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants