Socket
Socket
Sign inDemoInstall

angular-ui-layout

Package Overview
Dependencies
0
Maintainers
2
Versions
13
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

Comparing version 1.2.2 to 1.2.3

2

package.json
{
"name": "angular-ui-layout",
"version": "1.2.2",
"version": "1.2.3",
"description": "This directive allows you to split !",

@@ -5,0 +5,0 @@ "devDependencies": {

@@ -7,3 +7,3 @@ 'use strict';

angular.module('ui.layout', [])
.controller('uiLayoutCtrl', ['$scope', '$attrs', '$element', '$timeout', 'LayoutContainer', function uiLayoutCtrl($scope, $attrs, $element, $timeout, LayoutContainer) {
.controller('uiLayoutCtrl', ['$scope', '$attrs', '$element', '$timeout', '$window', 'LayoutContainer', function uiLayoutCtrl($scope, $attrs, $element, $timeout, $window, LayoutContainer) {
var ctrl = this;

@@ -145,3 +145,6 @@ var opts = angular.extend({}, $scope.$eval($attrs.uiLayout), $scope.$eval($attrs.options));

(mouseEvent.originalEvent && mouseEvent.originalEvent[ctrl.sizeProperties.mouseProperty]) ||
(mouseEvent.targetTouches ? mouseEvent.targetTouches[0][ctrl.sizeProperties.mouseProperty] : 0);
// jQuery does touches weird, see #82
($window.jQuery ?
(mouseEvent.originalEvent ? mouseEvent.originalEvent.targetTouches[0][ctrl.sizeProperties.mouseProperty] : 0) :
(mouseEvent.targetTouches ? mouseEvent.targetTouches[0][ctrl.sizeProperties.mouseProperty] : 0));

@@ -235,5 +238,5 @@ lastPos = mousePos - offset($element)[ctrl.sizeProperties.offsetPos];

var child = ctrl.containers[i].element;
opts.maxSizes[i] = child.attr('max-size') || opts.maxSizes[i] || null;
opts.minSizes[i] = child.attr('min-size') || opts.minSizes[i] || null;
opts.sizes[i] = child.attr('size') || opts.sizes[i] || 'auto';
opts.maxSizes[i] = child.attr('max-size') || child.attr('data-max-size') || opts.maxSizes[i] || null;
opts.minSizes[i] = child.attr('min-size') || child.attr('data-min-size') || opts.minSizes[i] || null;
opts.sizes[i] = child.attr('size') || child.attr('data-size') || opts.sizes[i] || 'auto';
//opts.collapsed[i] = child.attr('collapsed') || opts.collapsed[i] || false;

@@ -563,3 +566,3 @@

function onResize() {
scope.$apply(function() {
scope.$evalAsync(function() {
ctrl.updateDisplay();

@@ -566,0 +569,0 @@ });

@@ -141,5 +141,23 @@ 'use strict';

function createDataSizedDirective(notation) {
element = createDirective(null, '<div ui-layout><header ui-layout-container data-size="' + notation + '"></header><footer ui-layout-container></footer></div>');
$header = element.children().eq(0)[0];
$footer = element.children().eq(2)[0];
return element;
}
function testSizeNotation(notation, actualSize) {
element = createSizedDirective(notation);
test(element, notation, actualSize);
element.remove();
element = createDataSizedDirective(notation);
test(element, notation, actualSize);
element.remove();
}
function test(element, notation, actualSize) {
layoutBounds = element[0].getBoundingClientRect();

@@ -160,3 +178,2 @@ headerBounds = $header.getBoundingClientRect();

element.remove();
}

@@ -204,5 +221,23 @@

function createDataSizedDirective(notation) {
element = createDirective(null, '<div ui-layout><header ui-layout-container size="1px" data-min-size="' + notation + '"></header><footer ui-layout-container></footer></div>');
$header = element.children().eq(0)[0];
$footer = element.children().eq(2)[0];
return element;
}
function testSizeNotation(notation, minSize) {
element = createSizedDirective(notation);
test(element, notation, minSize);
element.remove();
element = createDataSizedDirective(notation);
test(element, notation, minSize);
element.remove();
}
function test(element, notation, minSize) {
layoutBounds = element[0].getBoundingClientRect();

@@ -222,4 +257,2 @@ headerBounds = $header.getBoundingClientRect();

}
element.remove();
}

@@ -256,5 +289,22 @@

function createDataSizedDirective(notation) {
element = createDirective(null, '<div ui-layout><header ui-layout-container size="100%" data-max-size="' + notation + '"></header><footer ui-layout-container></footer></div>');
$header = element.children().eq(0)[0];
$footer = element.children().eq(2)[0];
return element;
}
function testSizeNotation(notation, maxSize) {
element = createSizedDirective(notation);
test(element, notation, maxSize);
element.remove();
element = createDataSizedDirective(notation);
test(element, notation, maxSize);
element.remove();
}
function test(element, notation, maxSize) {
layoutBounds = element[0].getBoundingClientRect();

@@ -275,3 +325,2 @@ headerBounds = $header.getBoundingClientRect();

element.remove();
}

@@ -278,0 +327,0 @@

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc