Brak opisu

dom111 e1951b4786 Fix MOVE operations on non-Apache hosts. Fixes #89. 2 lat temu
.github 730f91ba5f Adding functional test. 2 lat temu
assets 82294e5d7d Refine Nginx example with docker-compose file 2 lat temu
build 5934c135e0 Remove regeneration of header.html. Merges #93 2 lat temu
docker 82294e5d7d Refine Nginx example with docker-compose file 2 lat temu
examples 82294e5d7d Refine Nginx example with docker-compose file 2 lat temu
src e1951b4786 Fix MOVE operations on non-Apache hosts. Fixes #89. 2 lat temu
tests e1951b4786 Fix MOVE operations on non-Apache hosts. Fixes #89. 2 lat temu
translations 82294e5d7d Refine Nginx example with docker-compose file 2 lat temu
.editorconfig c2fbfc77b5 Rewritten from the ground up using ES modules and trying to separate the 5 lat temu
.gitattributes c2fbfc77b5 Rewritten from the ground up using ES modules and trying to separate the 5 lat temu
.gitignore 30cb29f8bd Replace webpack with esbuild. 3 lat temu
.prettierignore 30cb29f8bd Replace webpack with esbuild. 3 lat temu
.prettierrc 30cb29f8bd Replace webpack with esbuild. 3 lat temu
LICENSE 4ec02b7cdd Add MIT license 6 lat temu
Makefile 730f91ba5f Adding functional test. 2 lat temu
README.md 65d65ebfe1 Bump version and update README. 2 lat temu
TODO.md 8de745f124 Add `pushstate` when previews are opened in lightbox and `popstate` when closed. Still work to do with potentially managing the `popstate` handler for files too. Potentially addresses the main problem in #59. 2 lat temu
docker-compose.nginx.yml 82294e5d7d Refine Nginx example with docker-compose file 2 lat temu
docker-compose.yml 82294e5d7d Refine Nginx example with docker-compose file 2 lat temu
esbuild.js 30cb29f8bd Replace webpack with esbuild. 3 lat temu
index.html 730f91ba5f Adding functional test. 2 lat temu
jest-puppeteer.config.js 30cb29f8bd Replace webpack with esbuild. 3 lat temu
jest.config.functional.chrome.ts 730f91ba5f Adding functional test. 2 lat temu
jest.config.functional.firefox.ts 730f91ba5f Adding functional test. 2 lat temu
jest.config.unit.ts 30cb29f8bd Replace webpack with esbuild. 3 lat temu
package-lock.json a75d5bdb14 Fix test runner and build. 2 lat temu
package.json e1951b4786 Fix MOVE operations on non-Apache hosts. Fixes #89. 2 lat temu
tsconfig.json d51b38f966 Add first pass at i18n (using i18next). 2 lat temu

README.md

webdav-js

A simple way to administer a WebDAV filesystem from your browser.

The original aim for this project was to provide a bookmarklet for use when you want to administer a WebDAV server, without the need for using a third party application.

The application has since been rewritten to not rely on jQuery and use more modern methods and provide a single runtime file. Now that there's more separation between the interface code and the library code, I'd like to investigate using other frontend approaches to see which I prefer (and also to weigh up the differences between the currently available frameworks). There's still work to do around code separation and hopefully this will be something I can continue to work on (as time allows) I feel it's at least as stable as the previous version.

Features

  • Browse, upload, download, rename, delete entries and create directories.
  • File preview for image, video, audio, font, text, PDF files.
  • Basic keyboard navigation.
  • A (very) simple gallery browser for preview-able files.

Localisation

Currently, the library contains text translated to English, German and Portuguese. If you use this and would like it to be localised to your language please submit a PR including the translation (using en.json as a template) and adding the language in UI.js.

Tested in:

  • Chrome
  • Firefox
  • Edge

Implementations

Bookmarklet:

javascript:["https://cdn.jsdelivr.net/gh/dom111/webdav-js/assets/css/style-min.css","https://cdn.jsdelivr.net/gh/dom111/webdav-js/src/webdav-min.js"].forEach((function(e,s){/css$/.test(e)?((s=document.createElement("link")).href=e,s.rel="stylesheet"):(s=document.createElement("script")).src=e,document.head.appendChild(s)}));

or drag this link directly

Apache:

There is also an example for how you could set up Apache in the examples/ directory (one using a locally hosted version of the library, and one using a CDN).

Think you have another example implementation that would be good to showcase? Fork this repository and make a PR!

Test the library

Included in the package is a docker-compose.yml file that can spawn an Alpine Linux Apache WebDAV server that uses the example Apache configuration so you can see the library in action if you don't have a WebDAV server at your disposal.

To start it, run:

docker-compose up

and navigate to http://localhost:8080/.

Contributing

If you feel this can be improved (I'm certain it can!), please feel free to fork it and submit a PR.

Localisation would be a great start if you'd like to help!

To start making changes, ensure you install all the dependencies and build the application:

make build

After making changes, ensure you rebuild the application:

make build

Once your changes have compiled you can test using the Docker container.

Tests

To run the unit and functional tests:

make build
docker-compose up -d
make test