Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

ionic2-calendar

Package Overview
Dependencies
Maintainers
1
Versions
95
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

ionic2-calendar - npm Package Compare versions

Comparing version 0.3.14 to 0.3.15

16

dayview.js

@@ -134,7 +134,15 @@ import { DatePipe } from '@angular/common';

DayViewComponent.createDateObjects = function (startTime, startHour, endHour, timeInterval) {
var rows = [], time, currentHour = startTime.getHours(), currentDate = startTime.getDate();
for (var hour = startHour; hour < endHour; hour += 1) {
for (var interval = 0; interval < timeInterval; interval += 1) {
var rows = [], time, currentHour = startTime.getHours(), currentDate = startTime.getDate(), hourStep, minStep;
if (timeInterval < 1) {
hourStep = Math.floor(1 / timeInterval);
minStep = 60;
}
else {
hourStep = 1;
minStep = Math.floor(60 / timeInterval);
}
for (var hour = startHour; hour < endHour; hour += hourStep) {
for (var interval = 0; interval < 60; interval += minStep) {
time = new Date(startTime.getTime());
time.setHours(currentHour + hour, 60 * interval / timeInterval);
time.setHours(currentHour + hour, interval);
time.setDate(currentDate);

@@ -141,0 +149,0 @@ rows.push({

{
"name": "ionic2-calendar",
"version": "0.3.14",
"version": "0.3.15",
"description": "Ionic2 calendar component",

@@ -5,0 +5,0 @@ "keywords": [

@@ -140,9 +140,17 @@ import { DatePipe } from '@angular/common';

WeekViewComponent.createDateObjects = function (startTime, startHour, endHour, timeInterval) {
var times = [], currentHour = startTime.getHours(), currentDate = startTime.getDate();
for (var hour = startHour; hour < endHour; hour += 1) {
for (var interval = 0; interval < timeInterval; interval += 1) {
var times = [], currentHour = startTime.getHours(), currentDate = startTime.getDate(), hourStep, minStep;
if (timeInterval < 1) {
hourStep = Math.floor(1 / timeInterval);
minStep = 60;
}
else {
hourStep = 1;
minStep = Math.floor(60 / timeInterval);
}
for (var hour = startHour; hour < endHour; hour += hourStep) {
for (var interval = 0; interval < 60; interval += minStep) {
var row = [];
for (var day = 0; day < 7; day += 1) {
var time = new Date(startTime.getTime());
time.setHours(currentHour + hour, 60 * interval / timeInterval);
time.setHours(currentHour + hour, interval);
time.setDate(currentDate + day);

@@ -149,0 +157,0 @@ row.push({

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

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

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc