diff options
author | Roeland Jago Douma <roeland@famdouma.nl> | 2015-06-03 14:52:00 +0200 |
---|---|---|
committer | Roeland Jago Douma <roeland@famdouma.nl> | 2015-07-06 16:32:10 +0200 |
commit | c8145cdbd6160788569d00fbc267abd08ae019c9 (patch) | |
tree | 9757cbbf9ef2fd42074522c7b85124427f447224 /lib/base.php | |
parent | 14eef434fff78bf39a926b1f27220b9ad1ebb833 (diff) | |
download | nextcloud-server-c8145cdbd6160788569d00fbc267abd08ae019c9.tar.gz nextcloud-server-c8145cdbd6160788569d00fbc267abd08ae019c9.zip |
Javascript mimetype icon resolver
This makes it possible to retrieve the icon for mimetypes in javascript.
It makes no additional queries to the server to retrieve the mimetype.
* config/mimetypealiases.json added
* mimetype.js: this is where the logic resides to convert from mimetype
to icon url
* mimetypelist.js: generated file with a list of mimetype mapping (aliases)
and the list of icon files
* ./occ maintenance:mimetypesjs : new command for occ to gernerate
mimetypes.js
* unit tests updated and still work
* javascript tests added
* theming support
* folder of the theme is now present in javascript (OC.theme.folder)
Diffstat (limited to 'lib/base.php')
-rw-r--r-- | lib/base.php | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/lib/base.php b/lib/base.php index 1766fc38f89..9a682a7e90f 100644 --- a/lib/base.php +++ b/lib/base.php @@ -406,6 +406,8 @@ class OC { OC_Util::addScript('search', 'search'); OC_Util::addScript("oc-requesttoken"); OC_Util::addScript("apps"); + OC_Util::addScript('mimetype'); + OC_Util::addScript('mimetypelist'); OC_Util::addVendorScript('snapjs/dist/latest/snap'); // avatars |