angular-breakpoints
Advanced tools
Comparing version 1.0.0 to 1.0.1
@@ -40,2 +40,3 @@ "use strict"; | ||
} | ||
// Unsubscribe to the resize event | ||
BreakpointsService.prototype.unsubscribe = function () { | ||
@@ -47,2 +48,3 @@ if (this.subscription) { | ||
}; | ||
// Subscribe to the resize event | ||
BreakpointsService.prototype.subscribe = function () { | ||
@@ -58,2 +60,3 @@ var _this = this; | ||
}; | ||
// Sets the customized breakpoints | ||
BreakpointsService.prototype.setBreakpoints = function (breakpoints) { | ||
@@ -64,2 +67,3 @@ if (breakpoints) { | ||
}; | ||
// Returns a breakpoint event, with the fallback breakpoint if none were found | ||
BreakpointsService.prototype.getBreakpointEvent = function (name) { | ||
@@ -73,5 +77,7 @@ if (!name) { | ||
}; | ||
// Returns the current window size | ||
BreakpointsService.prototype.getWindowSize = function () { | ||
return { width: window.innerWidth, height: window.innerHeight }; | ||
}; | ||
// Returns the first breakpoint that match the current size | ||
BreakpointsService.prototype.getBreakpoint = function (currentSize) { | ||
@@ -78,0 +84,0 @@ var keys = Object.keys(this.breakpoints); |
{ | ||
"name": "angular-breakpoints", | ||
"version": "1.0.0", | ||
"version": "1.0.1", | ||
"description": "Angular 2 service to programmatically listen to breakpoints", | ||
@@ -5,0 +5,0 @@ "main": "index.js", |
@@ -0,3 +1,6 @@ | ||
[![NPM Version](https://img.shields.io/npm/v/angular-breakpoints.svg)](https://npmjs.com/package/angular-breakpoints) | ||
# angular-breakpoints | ||
`angular-breakpoints` is a little angular service to listen programmatically to breakpoints. | ||
@@ -4,0 +7,0 @@ |
@@ -17,2 +17,2 @@ { | ||
] | ||
} | ||
} |
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
Major refactor
Supply chain riskPackage has recently undergone a major refactor. It may be unstable or indicate significant internal changes. Use caution when updating to versions that include significant changes.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
99
13569
8
222
1