Expose toggle layout method

pull/126/head
MattIPv4 2019-11-19 15:47:00 +00:00
parent 6ee5f8c06d
commit 83dda7efea
1 changed files with 3 additions and 2 deletions

View File

@ -832,7 +832,7 @@
} }
}; };
$scope.toggleLayout = function() { $window.toggleLayout = function() {
if ($scope.layout === 'default') { if ($scope.layout === 'default') {
$scope.layout = 'do'; $scope.layout = 'do';
$scope.tabs_site.unshift({ $scope.tabs_site.unshift({
@ -843,6 +843,7 @@
$scope.layout = 'default'; $scope.layout = 'default';
$scope.tabs_site.shift(); $scope.tabs_site.shift();
} }
doMasonry();
}; };
@ -1344,7 +1345,7 @@
initMasonry(); initMasonry();
if ($window.LAYOUT && $window.LAYOUT !== $scope.layout) { if ($window.LAYOUT && $window.LAYOUT !== $scope.layout) {
$scope.toggleLayout(); $window.toggleLayout();
} }
}; };
} }