mirror of
https://github.com/portainer/portainer.git
synced 2025-07-23 23:39:41 +02:00
feat(state): introduce endpoint state (#529)
This commit is contained in:
parent
7ebe4af77d
commit
fa4ec04c47
26 changed files with 267 additions and 122 deletions
|
@ -1,6 +1,6 @@
|
|||
angular.module('main', [])
|
||||
.controller('MainController', ['$scope', '$cookieStore',
|
||||
function ($scope, $cookieStore) {
|
||||
.controller('MainController', ['$scope', '$cookieStore', 'StateManager',
|
||||
function ($scope, $cookieStore, StateManager) {
|
||||
|
||||
/**
|
||||
* Sidebar Toggle & Cookie Control
|
||||
|
@ -10,6 +10,8 @@ function ($scope, $cookieStore) {
|
|||
return window.innerWidth;
|
||||
};
|
||||
|
||||
$scope.applicationState = StateManager.getState();
|
||||
|
||||
$scope.$watch($scope.getWidth, function(newValue, oldValue) {
|
||||
if (newValue >= mobileView) {
|
||||
if (angular.isDefined($cookieStore.get('toggle'))) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue