JS degration and use custom themes

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
6 messages Options
Reply | Threaded
Open this post in threaded view
|

JS degration and use custom themes

Stefan Nagtegaal
Is it me or is *a lot* of owncloud 5 functionality relying heavely on Javascript, which do not degrade gracefully in browser whixh do not support or has disabled the use of Javascript?
Is this intentionally, or are these bug reports?

There is quite some HTML generated through the js-files. I can not see why this would be required to be in the JS, and not could be handled through PHP.
When we could split functionality (through PHP) and user experience improvements (mostly js), we could support more browsers and make owncloud much easier to theme.
At the moment if someone would like to override the looks of a simple form, the JS file from the (core) app is required to be included and edited inside the theme. In my opinion this could and should be handled in another way.

If people would like some examples, Im happy to provide any..

Kind regards,


Stefan Nagtegaal


Verzonden vanaf Samsung Mobile

_______________________________________________
Owncloud mailing list
[hidden email]
https://mail.kde.org/mailman/listinfo/owncloud
Reply | Threaded
Open this post in threaded view
|

Re: JS degration and use custom themes

Bernhard Posselt
Yes, its your typical jQuery project. JavaScript is not the problem, the problem is like you said the often missing seperation between view and logic and that makes it at least for me incredibly hard to understand the code.

The solution is to use a proper JS framework like AngularJS http://angularjs.org/ but this has been introduced very recently to people. Also we have too less time for too many bugs, so people dont really have the time to rewrite stuff.

Everyone who wants to improve the code/fix bugs is welcome though. Just contact the people on the IRC/mailinglist if you need help.

PS: Disabling JS is not an option.

On 03/01/2013 08:02 AM, development wrote:
Is it me or is *a lot* of owncloud 5 functionality relying heavely on Javascript, which do not degrade gracefully in browser whixh do not support or has disabled the use of Javascript?
Is this intentionally, or are these bug reports?

There is quite some HTML generated through the js-files. I can not see why this would be required to be in the JS, and not could be handled through PHP.
When we could split functionality (through PHP) and user experience improvements (mostly js), we could support more browsers and make owncloud much easier to theme.
At the moment if someone would like to override the looks of a simple form, the JS file from the (core) app is required to be included and edited inside the theme. In my opinion this could and should be handled in another way.

If people would like some examples, Im happy to provide any..

Kind regards,


Stefan Nagtegaal


Verzonden vanaf Samsung Mobile


_______________________________________________
Owncloud mailing list
[hidden email]
https://mail.kde.org/mailman/listinfo/owncloud


_______________________________________________
Owncloud mailing list
[hidden email]
https://mail.kde.org/mailman/listinfo/owncloud
Reply | Threaded
Open this post in threaded view
|

Re: JS degration and use custom themes

Daniel Molkentin
While I generally agree, Bernhard, I think this misses the OPs point.

Stefan, ownCloud is - by it's very nature - a web application. Creating well-working instant-feedback web applications without the use of JS simply is not possible. So generally, the requirement of JS is not a bug, and we will not support browsers that have JS disabled.

If however, there are special, valid use case that would make pure HTML desireble (e.g. for automation), please bring it forward, although usually this is where the REST or WebDAV-APIs are usually more useful. So what are your use cases?

Daniel

On 03/01/2013 08:29 AM, Bernhard Posselt wrote:
Yes, its your typical jQuery project. JavaScript is not the problem, the problem is like you said the often missing seperation between view and logic and that makes it at least for me incredibly hard to understand the code.

The solution is to use a proper JS framework like AngularJS http://angularjs.org/ but this has been introduced very recently to people. Also we have too less time for too many bugs, so people dont really have the time to rewrite stuff.

Everyone who wants to improve the code/fix bugs is welcome though. Just contact the people on the IRC/mailinglist if you need help.

PS: Disabling JS is not an option.

On 03/01/2013 08:02 AM, development wrote:
Is it me or is *a lot* of owncloud 5 functionality relying heavely on Javascript, which do not degrade gracefully in browser whixh do not support or has disabled the use of Javascript?
Is this intentionally, or are these bug reports?

There is quite some HTML generated through the js-files. I can not see why this would be required to be in the JS, and not could be handled through PHP.
When we could split functionality (through PHP) and user experience improvements (mostly js), we could support more browsers and make owncloud much easier to theme.
At the moment if someone would like to override the looks of a simple form, the JS file from the (core) app is required to be included and edited inside the theme. In my opinion this could and should be handled in another way.

If people would like some examples, Im happy to provide any..

Kind regards,


Stefan Nagtegaal


Verzonden vanaf Samsung Mobile


_______________________________________________
Owncloud mailing list
[hidden email]
https://mail.kde.org/mailman/listinfo/owncloud



_______________________________________________
Owncloud mailing list
[hidden email]
https://mail.kde.org/mailman/listinfo/owncloud


-- 
www.owncloud.com - Your Data, Your Cloud, Your Way!

ownCloud GmbH, GF: Markus Rex, Holger Dyroff
Schloßäckerstrasse 26a, 90443 Nürnberg, HRB 28050 (AG Nürnberg)

_______________________________________________
Owncloud mailing list
[hidden email]
https://mail.kde.org/mailman/listinfo/owncloud
Reply | Threaded
Open this post in threaded view
|

Re: JS degration and use custom themes

Stefan Nagtegaal
In reply to this post by Stefan Nagtegaal
The point to be noted is, that if you properly separate functionality (PHP) from user interface (HTML) and user experience (JS), custom themes could live longer in it's current form.

Currently Im trying to make some custom themes. To properly theme most aspects of OC, i *must* copy almost an entire app (like files/calender, etc) to my themes directory and rewrite more than 50% of the code to give it another look. Thats awfull, and directly explains why there are no themes available in the current repository other than the rediculously simple responsive-theme. (No offense though)

I could live with the fact that owncloud requires JS to be enabled in the browser. I only think that to make theming easier for non-programmers this is a step that needs to be taken.
Seperate things and make functionality rely on id,s in JS. Make the id start with "js-..." So themers know it triggers certain functionality in the js-files.
The looks of oc could be done with ids/classes, like it is now.
All the generated/build HTML inside the JS-files should be in seperate templates, which could easily be overridden by themers.

Im willing to work on this, but I need more opinions on the approach and some sort of approval for this plan.

Hope to have things cleared up a bit.

Kind regards,


Stefan Nagtegaal



-------- Oorspronkelijk bericht --------
Van: Daniel Molkentin <[hidden email]>
Datum:
Aan: [hidden email]
Onderwerp: Re: [Owncloud] JS degration and use custom themes


While I generally agree, Bernhard, I think this misses the OPs point.

Stefan, ownCloud is - by it's very nature - a web application. Creating well-working instant-feedback web applications without the use of JS simply is not possible. So generally, the requirement of JS is not a bug, and we will not support browsers that have JS disabled.

If however, there are special, valid use case that would make pure HTML desireble (e.g. for automation), please bring it forward, although usually this is where the REST or WebDAV-APIs are usually more useful. So what are your use cases?

Daniel

On 03/01/2013 08:29 AM, Bernhard Posselt wrote:
Yes, its your typical jQuery project. JavaScript is not the problem, the problem is like you said the often missing seperation between view and logic and that makes it at least for me incredibly hard to understand the code.

The solution is to use a proper JS framework like AngularJS http://angularjs.org/ but this has been introduced very recently to people. Also we have too less time for too many bugs, so people dont really have the time to rewrite stuff.

Everyone who wants to improve the code/fix bugs is welcome though. Just contact the people on the IRC/mailinglist if you need help.

PS: Disabling JS is not an option.

On 03/01/2013 08:02 AM, development wrote:
Is it me or is *a lot* of owncloud 5 functionality relying heavely on Javascript, which do not degrade gracefully in browser whixh do not support or has disabled the use of Javascript?
Is this intentionally, or are these bug reports?

There is quite some HTML generated through the js-files. I can not see why this would be required to be in the JS, and not could be handled through PHP.
When we could split functionality (through PHP) and user experience improvements (mostly js), we could support more browsers and make owncloud much easier to theme.
At the moment if someone would like to override the looks of a simple form, the JS file from the (core) app is required to be included and edited inside the theme. In my opinion this could and should be handled in another way.

If people would like some examples, Im happy to provide any..

Kind regards,


Stefan Nagtegaal


Verzonden vanaf Samsung Mobile


_______________________________________________
Owncloud mailing list
[hidden email]
https://mail.kde.org/mailman/listinfo/owncloud



_______________________________________________
Owncloud mailing list
[hidden email]
https://mail.kde.org/mailman/listinfo/owncloud


-- 
www.owncloud.com - Your Data, Your Cloud, Your Way!

ownCloud GmbH, GF: Markus Rex, Holger Dyroff
Schloßäckerstrasse 26a, 90443 Nürnberg, HRB 28050 (AG Nürnberg)

_______________________________________________
Owncloud mailing list
[hidden email]
https://mail.kde.org/mailman/listinfo/owncloud
Reply | Threaded
Open this post in threaded view
|

Re: JS degration and use custom themes

Daniel Molkentin
In reply to this post by Daniel Molkentin
On 03/01/2013 08:42 AM, Daniel Molkentin wrote:
While I generally agree, Bernhard, I think this misses the OPs point.

Disregard that, sorry Bernhard, of course your argument is valid :-) MVC would be very much desirable. I should have read the full OP :-)
-- 
www.owncloud.com - Your Data, Your Cloud, Your Way!

ownCloud GmbH, GF: Markus Rex, Holger Dyroff
Schloßäckerstrasse 26a, 90443 Nürnberg, HRB 28050 (AG Nürnberg)

_______________________________________________
Owncloud mailing list
[hidden email]
https://mail.kde.org/mailman/listinfo/owncloud
Reply | Threaded
Open this post in threaded view
|

Re: JS degration and use custom themes

Stefan Nagtegaal
In reply to this post by Stefan Nagtegaal

Op 1 mrt. 2013, om 12:42 heeft Diederik de Haas <[hidden email]> het volgende geschreven:

> On Friday 01 March 2013 08:02:32 development wrote:
>> There is quite some HTML generated through the js-files. I can not see why
>> this would be required to be in the JS, and not could be handled through
>> PHP. When we could split functionality (through PHP) and user experience
>> improvements (mostly js)
>
> I hope they'll listen to your recommendations. Not that I'm interested in
> creating themes (or have the skills for it), but it would make owncloud better!
>
> Keep up the good work :)
>
> Diederik

Indeed, it would.. The major advantage of it would be that is will be more widely adopted by bigger firms and organizations. The community around OwnCloud will grow, once it is easier to white label things.
White labeling relies heavily on theming.
When the community grows, OwnCloud will get more people aboard that will have understanding of it's code and so, OwnCloud will benefit from that.

Apart from all that, things will become *much* easier to understand once we split out design (HTML) vs functionality (PHP core and JS).

As a sidenote: I'm not bashing on OwnCloud. Not at all.  I think it has a tremendous potential to become something _really_ big, I absolutely *love* the functionality, but the overall implementation and separation of code vs design could be much, much better..

I've quite some experience with the open source project Drupal, of which I designed the default theme. We struggled with the same problems there, and I have seen that when we did actually separated the code there was an enormous hit on developers/designers and users which adopted and contributed back to Drupal.

I'm willing to put a lot of time in making things better, but unfortunately I can not do such a major overhaul on my own.

Kind regards,


Stefan




_______________________________________________
Owncloud mailing list
[hidden email]
https://mail.kde.org/mailman/listinfo/owncloud