You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@corinthia.apache.org by Peter Kelly <pm...@apache.org> on 2015/03/12 12:00:45 UTC

Web-based editor now in repository

I’ve just committed the proof-of-concept web-based app built on the editing library to the repository, in consumers/web/client. This is the same as what I mentioned yesterday on the list at http://web-demo.uxproductivity.com except that it directly references the latest .js files in the Editor/src directory, rather than the older version of the code in the one I just mentioned.

Now that it’s in the repository, feel free to have a look at and play around with it :) It’s *very* basic at the moment, but should at least be useful as a starting point.

Note that while it’s technically possible for the UI code to access all global functions provided within the editor, only some of those are meant to be public (that is, usable by UI code), while others are considered “private”. The full list of public API functions is at  https://cwiki.apache.org/confluence/display/Corinthia/API+reference - please make sure you only call those functions.

The code here is client-side only, and I have only confirmed that it works in Safari and Chrome (which are also what I use for running all the testcases for the library - see Editor/tests/testharness.html).

Depending on your setup, you may run into errors relating to the JS code being unable to load resources from the local filesystem. If this is the case, set up a local web server on your machine, with the web server root equal to the repository, and then access it via the following URL:

http://localhost:8000/consumers/web/client/index.html

If you have Python installed, you can start up a web server easily as follows:

cd ~/Corinthia
python -m SimpleHTTPServer

or if you prefer to use python3:

python3 -m http.server

With Franz already having started work on a server-side version, we may be able to get something quite usable in the not-too-distanct future. This is quite exciting!

—
Dr Peter M. Kelly
pmkelly@apache.org

PGP key: http://www.kellypmk.net/pgp-key <http://www.kellypmk.net/pgp-key>
(fingerprint 5435 6718 59F0 DD1F BFA0 5E46 2523 BAA1 44AE 2966)


RE: Web-based editor now in repository

Posted by Franz de Copenhague <fr...@outlook.com>.

> -----Original Message-----
> From: Peter Kelly [mailto:pmkelly@apache.org]
> Sent: Thursday, March 12, 2015 7:01 AM
> To: dev@corinthia.incubator.apache.org
> Subject: Web-based editor now in repository
> 
> I’ve just committed the proof-of-concept web-based app built on the editing
> library to the repository, in consumers/web/client. This is the same as what I
> mentioned yesterday on the list at http://web-demo.uxproductivity.com
> except that it directly references the latest .js files in the Editor/src directory,
> rather than the older version of the code in the one I just mentioned.
> 
> Now that it’s in the repository, feel free to have a look at and play around
> with it :) It’s *very* basic at the moment, but should at least be useful as a
> starting point.
> 
> Note that while it’s technically possible for the UI code to access all global
> functions provided within the editor, only some of those are meant to be
> public (that is, usable by UI code), while others are considered “private”. The
> full list of public API functions is at
> https://cwiki.apache.org/confluence/display/Corinthia/API+reference -
> please make sure you only call those functions.
> 
> The code here is client-side only, and I have only confirmed that it works in
> Safari and Chrome (which are also what I use for running all the testcases for
> the library - see Editor/tests/testharness.html).
> 
> Depending on your setup, you may run into errors relating to the JS code
> being unable to load resources from the local filesystem. If this is the case,
> set up a local web server on your machine, with the web server root equal to
> the repository, and then access it via the following URL:
> 
> http://localhost:8000/consumers/web/client/index.html
> 
> If you have Python installed, you can start up a web server easily as follows:
> 
> cd ~/Corinthia
> python -m SimpleHTTPServer
> 
> or if you prefer to use python3:
> 
> python3 -m http.server
> 
> With Franz already having started work on a server-side version, we may be
> able to get something quite usable in the not-too-distanct future. This is
> quite exciting!
> 
> —
> Dr Peter M. Kelly
> pmkelly@apache.org
> 
> PGP key: http://www.kellypmk.net/pgp-key
> <http://www.kellypmk.net/pgp-key> (fingerprint 5435 6718 59F0 DD1F BFA0
> 5E46 2523 BAA1 44AE 2966)

I have extended the editor proof-of-concept in a fake web-based app using the editor  that simulates a GET request of sample.docx file.

I have modified a little the files interface.js and uxeditor.js with extra parameters (iframe src and resources path) to be able to integrate the editor in a different location.

franz