mirror of
https://github.com/bitwarden/browser.git
synced 2024-11-29 12:55:21 +01:00
stubbed out folders and sync settings pages
This commit is contained in:
parent
142bc779d3
commit
ef4b97b336
@ -125,13 +125,41 @@
|
|||||||
data: { authorize: true },
|
data: { authorize: true },
|
||||||
params: { animation: null }
|
params: { animation: null }
|
||||||
})
|
})
|
||||||
|
|
||||||
.state('help', {
|
.state('help', {
|
||||||
url: '/help',
|
url: '/help',
|
||||||
templateUrl: 'app/settings/views/settingsHelp.html',
|
templateUrl: 'app/settings/views/settingsHelp.html',
|
||||||
controller: 'settingsHelpController',
|
controller: 'settingsHelpController',
|
||||||
data: { authorize: true },
|
data: { authorize: true },
|
||||||
params: { animation: null }
|
params: { animation: null }
|
||||||
|
})
|
||||||
|
.state('sync', {
|
||||||
|
url: '/sync',
|
||||||
|
templateUrl: 'app/settings/views/settingsSync.html',
|
||||||
|
controller: 'settingsSyncController',
|
||||||
|
data: { authorize: true },
|
||||||
|
params: { animation: null }
|
||||||
|
})
|
||||||
|
|
||||||
|
.state('folders', {
|
||||||
|
url: '/folders',
|
||||||
|
templateUrl: 'app/settings/views/settingsFolders.html',
|
||||||
|
controller: 'settingsFoldersController',
|
||||||
|
data: { authorize: true },
|
||||||
|
params: { animation: null }
|
||||||
|
})
|
||||||
|
.state('addFolder', {
|
||||||
|
url: '/folders',
|
||||||
|
templateUrl: 'app/settings/views/settingsAddFolder.html',
|
||||||
|
controller: 'settingsFoldersController',
|
||||||
|
data: { authorize: true },
|
||||||
|
params: { animation: null }
|
||||||
|
})
|
||||||
|
.state('editFolder?folderId', {
|
||||||
|
url: '/folders',
|
||||||
|
templateUrl: 'app/settings/views/settingsEditFolder.html',
|
||||||
|
controller: 'settingsFoldersController',
|
||||||
|
data: { authorize: true },
|
||||||
|
params: { animation: null }
|
||||||
});
|
});
|
||||||
})
|
})
|
||||||
.run(function ($rootScope, userService, loginService, tokenService, $state) {
|
.run(function ($rootScope, userService, loginService, tokenService, $state) {
|
||||||
|
6
src/popup/app/settings/settingsAddFolderController.js
Normal file
6
src/popup/app/settings/settingsAddFolderController.js
Normal file
@ -0,0 +1,6 @@
|
|||||||
|
angular
|
||||||
|
.module('bit.settings')
|
||||||
|
|
||||||
|
.controller('settingsAddFolderController', function ($scope) {
|
||||||
|
|
||||||
|
});
|
6
src/popup/app/settings/settingsEditFolderController.js
Normal file
6
src/popup/app/settings/settingsEditFolderController.js
Normal file
@ -0,0 +1,6 @@
|
|||||||
|
angular
|
||||||
|
.module('bit.settings')
|
||||||
|
|
||||||
|
.controller('settingsEditFolderController', function ($scope) {
|
||||||
|
|
||||||
|
});
|
6
src/popup/app/settings/settingsFoldersController.js
Normal file
6
src/popup/app/settings/settingsFoldersController.js
Normal file
@ -0,0 +1,6 @@
|
|||||||
|
angular
|
||||||
|
.module('bit.settings')
|
||||||
|
|
||||||
|
.controller('settingsFoldersController', function ($scope) {
|
||||||
|
|
||||||
|
});
|
6
src/popup/app/settings/settingsSyncController.js
Normal file
6
src/popup/app/settings/settingsSyncController.js
Normal file
@ -0,0 +1,6 @@
|
|||||||
|
angular
|
||||||
|
.module('bit.settings')
|
||||||
|
|
||||||
|
.controller('settingsSyncController', function ($scope) {
|
||||||
|
|
||||||
|
});
|
24
src/popup/app/settings/views/settingsAddFolder.html
Normal file
24
src/popup/app/settings/views/settingsAddFolder.html
Normal file
@ -0,0 +1,24 @@
|
|||||||
|
<form name="theForm" ng-submit="theForm.$valid && save(folder)" bit-form="savePromise">
|
||||||
|
<div class="header">
|
||||||
|
<div class="left">
|
||||||
|
<a ng-click="close()" href="">Cancel</a>
|
||||||
|
</div>
|
||||||
|
<div class="right">
|
||||||
|
<button type="submit" class="btn btn-link" ng-show="!theForm.$loading">Save</button>
|
||||||
|
<i class="fa fa-spinner fa-lg" ng-show="theForm.$loading" ng-class="{'fa-spin' : theForm.$loading}"></i>
|
||||||
|
</div>
|
||||||
|
<div class="title">Add Folder</div>
|
||||||
|
</div>
|
||||||
|
<div class="content">
|
||||||
|
<div class="list">
|
||||||
|
<div class="list-section">
|
||||||
|
<div class="list-section-items">
|
||||||
|
<div class="list-section-item">
|
||||||
|
<label for="name" class="item-label">Name</label>
|
||||||
|
<input id="name" type="text" name="Name" ng-model="folder.name">
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</form>
|
24
src/popup/app/settings/views/settingsEditFolder.html
Normal file
24
src/popup/app/settings/views/settingsEditFolder.html
Normal file
@ -0,0 +1,24 @@
|
|||||||
|
<form name="theForm" ng-submit="theForm.$valid && save(folder)" bit-form="savePromise">
|
||||||
|
<div class="header">
|
||||||
|
<div class="left">
|
||||||
|
<a ng-click="close()" href="">Cancel</a>
|
||||||
|
</div>
|
||||||
|
<div class="right">
|
||||||
|
<button type="submit" class="btn btn-link" ng-show="!theForm.$loading">Save</button>
|
||||||
|
<i class="fa fa-spinner fa-lg" ng-show="theForm.$loading" ng-class="{'fa-spin' : theForm.$loading}"></i>
|
||||||
|
</div>
|
||||||
|
<div class="title">Edit Folder</div>
|
||||||
|
</div>
|
||||||
|
<div class="content">
|
||||||
|
<div class="list">
|
||||||
|
<div class="list-section">
|
||||||
|
<div class="list-section-items">
|
||||||
|
<div class="list-section-item">
|
||||||
|
<label for="name" class="item-label">Name</label>
|
||||||
|
<input id="name" type="text" name="Name" ng-model="folder.name">
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</form>
|
27
src/popup/app/settings/views/settingsFolders.html
Normal file
27
src/popup/app/settings/views/settingsFolders.html
Normal file
@ -0,0 +1,27 @@
|
|||||||
|
<div class="header">
|
||||||
|
<div class="left">
|
||||||
|
<a ui-sref="tabs.settings({animation: 'out-slide-right'})"><i class="fa fa-chevron-left"></i> Settings</a>
|
||||||
|
</div>
|
||||||
|
<div class="right">
|
||||||
|
<a href="" ng-click="addFolder()"><i class="fa fa-plus fa-lg"></i></a>
|
||||||
|
</div>
|
||||||
|
<div class="title">Folders</div>
|
||||||
|
</div>
|
||||||
|
<div class="content">
|
||||||
|
<div ng-if="folders.length">
|
||||||
|
<div class="list">
|
||||||
|
<div class="list-grouped">
|
||||||
|
<a ng-click="editFolder(folder)" class="list-grouped-item"
|
||||||
|
ng-repeat="folder in theFolders = (folders | orderBy: ['name'])">
|
||||||
|
<span class="text">{{folder.name}}</span>
|
||||||
|
</a>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="centered-message" ng-if="loaded && !folders.length">
|
||||||
|
<p>No folders to list. <a href="" ng-click="addFolder()">Add one</a></p>
|
||||||
|
</div>
|
||||||
|
<div class="page-loading" ng-if="!loaded">
|
||||||
|
<i class="fa fa-lg fa-spinner fa-spin"></i>
|
||||||
|
</div>
|
||||||
|
</div>
|
9
src/popup/app/settings/views/settingsSync.html
Normal file
9
src/popup/app/settings/views/settingsSync.html
Normal file
@ -0,0 +1,9 @@
|
|||||||
|
<div class="header">
|
||||||
|
<div class="left">
|
||||||
|
<a ui-sref="tabs.settings({animation: 'out-slide-right'})"><i class="fa fa-chevron-left"></i> Settings</a>
|
||||||
|
</div>
|
||||||
|
<div class="title">Sync</div>
|
||||||
|
</div>
|
||||||
|
<div class="content">
|
||||||
|
|
||||||
|
</div>
|
@ -68,6 +68,10 @@
|
|||||||
<script src="app/settings/settingsController.js"></script>
|
<script src="app/settings/settingsController.js"></script>
|
||||||
<script src="app/settings/settingsHelpController.js"></script>
|
<script src="app/settings/settingsHelpController.js"></script>
|
||||||
<script src="app/settings/settingsAboutController.js"></script>
|
<script src="app/settings/settingsAboutController.js"></script>
|
||||||
|
<script src="app/settings/settingsSyncController.js"></script>
|
||||||
|
<script src="app/settings/settingsFoldersController.js"></script>
|
||||||
|
<script src="app/settings/settingsAddFolderController.js"></script>
|
||||||
|
<script src="app/settings/settingsEditFolderController.js"></script>
|
||||||
|
|
||||||
<script src="app/tools/toolsModule.js"></script>
|
<script src="app/tools/toolsModule.js"></script>
|
||||||
<script src="app/tools/toolsController.js"></script>
|
<script src="app/tools/toolsController.js"></script>
|
||||||
|
Loading…
Reference in New Issue
Block a user