ahmedkandel / nova-s3-multipart-upload

A Laravel Nova resource tool to upload files directly to Amazon S3. You can (upload | download | delete) single, multiple, small or big files.
MIT License
23 stars 22 forks source link

Go to file resource if are relationship type #4

Closed andresilvagomez closed 3 years ago

ahmedkandel commented 3 years ago

Thanks, good addition but please keep in mind that not every relationship has a corresponding resource. Maybe the files are stored in relationship model but the model has no Nova resource. In this case the link will give 404 error.

The idea of <a> tag does not follow the Nova UI, I mean would be better to have an icon SVG like the view one that is used to view a resource detail page.

andresilvagomez commented 3 years ago
Captura de Pantalla 2020-12-06 a la(s) 10 54 01 a  m

Maybe a link something like that?

ahmedkandel commented 3 years ago

Yes the eye icon is better but still you need to check if the relationship resource exists.

andresilvagomez commented 3 years ago

Righ but the icon is to show the document in the navigation according with the other one PR

In this case I represented it like a relationship with link in the name

ahmedkandel commented 3 years ago

I think the eye icon is better for the show resource details while for the open in browser PR use this SVG https://github.com/tailwindlabs/heroicons/blob/master/optimized/outline/external-link.svg

andresilvagomez commented 3 years ago

@ahmedkandel changes are ready

andresilvagomez commented 3 years ago

@ahmedkandel

ahmedkandel commented 3 years ago

Hey, @andresilvagomez I am thinking about a much wider usage of this feature. Not only a link or a button to model resource But a feature/method to allow the user to create links or buttons e.g. ->linkTo('/nova/videos/{id}') then the package replace {id} with the model id we may also support other routes paramters. Also, think about support for Vue Router in order not to reload pages if the link goes to an internal nova route.

What do you think?

andresilvagomez commented 3 years ago

@ahmedkandel I agree with you :) totally, but then could you release a new tag with the last PR, and I will work in this feature today!!

ahmedkandel commented 3 years ago

@andresilvagomez no need for new releases just sync your fork with the upstream. Please close this PR and create a new clean one with the updated feature.

andresilvagomez commented 3 years ago

@andresilvagomez no need for new releases just sync your fork with the upstream. Please close this PR and create a new clean one with the updated feature.

@ahmedkandel no is really create a new release tag. to start using new features available in the projects

ahmedkandel commented 3 years ago

@andresilvagomez you can start using the new features without waiting for a release by installing the dev-master branch as following composer require "ahmedkandel/nova-s3-multipart-upload:master".

We are currently working on other updates and once they are ready will release a new version.

ahmedkandel commented 3 years ago

@ahmedkandel I agree with you :) totally, but then could you release a new tag with the last PR, and I will work in this feature today!!

@andresilvagomez are you working already on this or shall I?