jersou / markdown-explorer

Easily explore, view and edit markdown documentation of a file tree
MIT License
65 stars 8 forks source link

why ui-sortable cannot work #20

Open wo4wangle opened 3 years ago

wo4wangle commented 3 years ago

Hi, I want to drag files/folders in the file tree . I find that angularjs ui-sortable could support it, but I cannot enable it in this project.

I try ui-sortable like this :

        <ol class="tree-nodes"
            ui-sortable="sortableOptions"
            ng-model="node.nodes"
            ng-show="node.expanded || vm.isExpandLocked">
            <li ng-repeat="node in vm.sortFolder(node.nodes)"
                class="tree-node"
                ng-include="'nodes_renderer.html'">
            </li>
        </ol>

    <div class="tree-root">
        <ol ui-sortable="sortableOptions" class="tree-nodes" ng-model="vm.fsTree.nodes">
            <li ng-repeat="node in vm.sortFolder(vm.fsTree.nodes)" class="tree-node" ng-include="'nodes_renderer.html'">
            </li>
        </ol>
    </div>

could you give me some hints to bring ui-sortable into effect, thanks!