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
Add drag & drop installation #14905
Add drag & drop installation #14905
Conversation
Formdata is not supported in IE8 http://caniuse.com/#search=formdata |
First of all thank you very much for doing this. I drag and drop all the time to upload extensions and its a pain to hit the very small target so this will make a great difference We have drag and drop in one other place in Joomla which is for images within tinmyce and it would be good if you could make the language string here match. So can you change the string to "Drag and Drop ...." not just Drag Secondly I can see in the tinymce plugin for dragndrop (media\editors\tinymce\plugins\jdragdrop\plugin.js) that we have a check and an error if the users browser doesnt support drag drop. So I presume we need a similar to check here? |
I see that @dgt41 was writing the same thing at the same time as me ;) |
Thanks for the feedback, I'll try fix the IE8 and language issues later. |
Added an alert to notice IE8 users which is not support drag&drop upload. I don't have Windows now, could anyone help me to test? The language key wrote by @Dg41 is only for Tinymce plugin and hard coded the |
It works, but one has no idea that Drag and Drop is possible at looking at the UI. |
@infograf768 the same could be said of the drag and drop of images in
tinmyce ;) I dont deel it is necessary as it is a standard web pattern now
<http://www.avg.com/email-signature?utm_medium=email&utm_source=link&utm_campaign=sig-email&utm_content=webmail>
Virus-free.
www.avg.com
<http://www.avg.com/email-signature?utm_medium=email&utm_source=link&utm_campaign=sig-email&utm_content=webmail>
<#DAB4FAD8-2DD7-40BB-A1B8-4E2AA1F9FDF2>
…On 26 March 2017 at 11:25, infograf768 ***@***.***> wrote:
It works, but one has no idea that Drag and Drop is possible at looking at
the UI.
I suggest adding this information on the page.
—
You are receiving this because you commented.
Reply to this email directly, view it on GitHub
<#14905 (comment)>,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/ABPH8RwfLpGmVHvD8Kii8vaRHNWhLaClks5rpj0HgaJpZM4MpX-_>
.
--
Brian Teeman
Co-founder Joomla! and OpenSourceMatters Inc.
https://brian.teeman.net/ <http://brian.teeman.net/>
|
@@ -12,6 +12,8 @@ COM_INSTALLER_CONFIRM_UNINSTALL="Are you sure you want to uninstall? Confirming | |||
COM_INSTALLER_CURRENT_VERSION="Installed" | |||
COM_INSTALLER_DISCOVER_FILTER_SEARCH_DESC="Search in discovered extension name. Prefix with ID: to search for an extension ID." | |||
COM_INSTALLER_DISCOVER_FILTER_SEARCH_LABEL="Search Discovered Extensions" | |||
COM_INSTALLER_DRAG_ERR_UNSUPPORTEDBROWSER="Drag and drop file upload is not available for your browser. Please consider using a fully HTML5 compatible browser" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
perfect text - please add a . at the end
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Also fixed the original text from TinyMCE
I have considered about this but I didn't implement this message yet, I'm open to let people decide what to do. |
@infograf768 i guess most Users are surprised that its not working (like this PR allow). So you have experienced Users and they should got Info by Release-Data. |
I have tested this item ✅ successfully on 9641792 This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/14905. |
@infograf768 that is for the drag and drop of moving the tinymce buttons. NOT for the drag and drop image uploading ;) |
@franz-wohlkoenig it has always worked (a bit) - just that you had to drop it on the button and then click on the upload button. This PR makes it work as it should |
In many applications, when there's the opportunity to drag and drop, there's a kind of dashed border to highlight the area in which you can drag and drop the file/whatever |
Imho it should only work on the "Upload Package File" tab. To me it doesn't make much sense and could be confusing to be able to drop a file into the "Install by URL", "Install from Folder" or "Install from Web" tab. |
@asika32764 can you move the code to the file form field (maybe with an option allowdnd) ? Ps: https://github.com/joomla/joomla-cms/blob/staging/layouts/joomla/form/field/file.php |
oh i didnt spot it worked in all tabs - that is indeed confusing
<http://www.avg.com/email-signature?utm_medium=email&utm_source=link&utm_campaign=sig-email&utm_content=webmail>
Virus-free.
www.avg.com
<http://www.avg.com/email-signature?utm_medium=email&utm_source=link&utm_campaign=sig-email&utm_content=webmail>
<#DAB4FAD8-2DD7-40BB-A1B8-4E2AA1F9FDF2>
…On 26 March 2017 at 12:08, Thomas Hunziker ***@***.***> wrote:
The drag zone is whole page of the Extensions -> Manage -> Install view
and it works for 4 tabs.
Imho it should only work on the "Upload Package File" tab. To me it
doesn't make much sense and could beconfusing to be able to drop a file
into the "Install by URL", "Install from Folder" or "Install from Web" tab.
Also, the code should be added by the plugin responsible for that tab (
https://github.com/joomla/joomla-cms/blob/staging/plugins/installer/
packageinstaller/tmpl/default.php) and not by com_installer.
—
You are receiving this because you commented.
Reply to this email directly, view it on GitHub
<#14905 (comment)>,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/ABPH8dNQ1k9NDzJvmnKJibv3a1XXhSSkks5rpkcbgaJpZM4MpX-_>
.
--
Brian Teeman
Co-founder Joomla! and OpenSourceMatters Inc.
https://brian.teeman.net/ <http://brian.teeman.net/>
|
@jeckodevelopment look at how its done in the tinymce plugin we already have for image uploads. You only get the box when you are dragging and dropping - not before |
It's an idea, but it would have to work also when multiple file fields are present in a form. You can't have the whole form be the trigger area in this case. You probably need an attribute which specifies the area identifier. |
@Bakual I guess we can append (programmatically) some unique classes to the drop area and have the script loop through the classes and do it's magic |
I didn't put code in plugin because I set whole page as the drag zone. And the This concept also inspired by phpMyAdmin, it can drag file in any pages to import SQL file. (If someone always click the I can move code to plugin and make the drop zone only in
@dgt41 It is a good idea for a drag & drop file field, but it is too big to me to implement this feature since I just got one night free to do this. Let's make this PR work first and leave the new field for future PRs. |
UPDATE Based on discussion, moved code to I still set whole page as drag zone, whether we should create a dashed box depends on future discussion. |
@asika32764 lets chose the Way People expect: i guess its a dashed box, if this is best Practice. |
.css("display", "none") | ||
.css("margin-top", "-10px"); | ||
JoomlaInstaller.getLoadingOverlay() | ||
.css("top", outerDiv.position().top - $(window).scrollTop()) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Could you use tabs instead of spaces to indent these js and css?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Fix in #14924
Create a new PR in #14924 that we can discuss for the new box layout. |
Set to "closed" on behalf of @infograf768 by The JTracker Application at issues.joomla.org/joomla-cms/14905 |
Closed as we have new PR #14924 This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/14905. |
* Add drag & drop installation * Fix drag issue * Add more error message * Typo * CS * Style fix * Fix from review * Add return * Add `.` * Fix based on review * Add return url * Convert loading cover operation into object * MISC fixes * Fix indents * Add box uploader * CS * Styling * Move return val out * Moved token out
Summary of Changes
Add drag & drop file to install extension package.
The drag zone is whole page of the Extensions -> Manage -> Install view and it
works for 4 tabsnow only works forUpload package file
tab.Testing Instructions
Go to Extensions -> Manage -> Install and drag file from desktop to browser. Joomla will auto upload it to install.
Images