Skip to content
assets browser
Branch: master
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
core
panel
static/icon
test
.gitignore
LICENSE
README.md
main.js
package.json

README.md

AssetDB Browser

Usages

Clone github

In Core Level

Step 1: Initialize asset-db

var AssetDB = require('../asset-db');
Editor.assetdb = new AssetDB({
    'cwd': 'your/project/path',
    'library': 'library',
});

Step 2: Register Panel Window and Selection

// register panel window
Editor.Panel.templateUrl = 'app://your/window.html';

// register selections
Editor.Selection.register('asset');

Step 3: Mount and Open Window

Editor.assetdb.mount('your/mounting/path', 'assets', function () {
    Editor.assetdb.init(function () {
        // open your window...
    });
});

In Page Level

<head>
    <script type="text/javascript" src="editor-framework://page/page-init.js"></script>
    <link rel="import" href="editor-framework://page/ui/ui.html">
    <script>
        Editor.require('app://asset-db');
    </script>
</head>
You can’t perform that action at this time.