Skip to content

Commit

Permalink
Merge pull request #168 from williamtroup/2.8.4
Browse files Browse the repository at this point in the history
2.8.4
  • Loading branch information
William Troup authored Oct 8, 2023
2 parents 4f99141 + 588a97d commit 401423a
Show file tree
Hide file tree
Showing 33 changed files with 339 additions and 341 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ Calendar.js
[![Tweet](https://img.shields.io/twitter/url/http/shields.io.svg?style=social)](https://twitter.com/intent/tweet?text=Calendar.js%2C%20a%20free%20JavaScript%20library&url=https://github.com/williamtroup/Calendar.js&hashtags=calendar,javascript,responsive,events)
</h1>
<p align="center">One of the world's easiest, most powerful, and fully responsive JavaScript Calendars!</p>
<p align="center">v2.8.3</p>
<p align="center">v2.8.4</p>
<br />

<h1>What views does Calendar.js support?</h1>
Expand Down
2 changes: 1 addition & 1 deletion dist/calendar.binding.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
/*! Calendar.js v2.8.3 | (c) Bunoon | GNU AGPLv3 License */
/*! Calendar.js v2.8.4 | (c) Bunoon | GNU AGPLv3 License */
(function(documentObject) {
var _attribute_Name = "data-binding-calendar";
documentObject.addEventListener("DOMContentLoaded", function() {
Expand Down
2 changes: 1 addition & 1 deletion dist/calendar.binding.min.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion dist/calendar.jquery.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
/*! Calendar.js v2.8.3 | (c) Bunoon | GNU AGPLv3 License */
/*! Calendar.js v2.8.4 | (c) Bunoon | GNU AGPLv3 License */
(function($) {
$.fn.calendarJs = function(options) {
var instances = [];
Expand Down
2 changes: 1 addition & 1 deletion dist/calendar.jquery.min.js
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
/*! Calendar.js v2.8.3 | (c) Bunoon | GNU AGPLv3 License */
/*! Calendar.js v2.8.4 | (c) Bunoon | GNU AGPLv3 License */
(function(b){b.fn.calendarJs=function(c){var a=[];this.each(function(){a.push(new calendarJs(this,c))});return a}})(jQuery);
50 changes: 22 additions & 28 deletions dist/calendar.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
/*! Calendar.js v2.8.3 | (c) Bunoon | GNU AGPLv3 License */
/*! Calendar.js v2.8.4 | (c) Bunoon | GNU AGPLv3 License */
function calendarJs(elementOrId, options, searchOptions) {
function build(newStartDateTime, fullRebuild, forceRefreshViews) {
_currentDate = isDefinedDate(newStartDateTime) ? newStartDateTime : new Date();
Expand Down Expand Up @@ -969,7 +969,7 @@ function calendarJs(elementOrId, options, searchOptions) {
}
function toggleDatePickerModeVisible(e) {
cancelBubble(e);
closeAnyOtherDatePickers();
hideAllElementsAcrossInstances("calendar calendar-shown", "calendar calendar-hidden");
if (!_datePickerVisible) {
_element_Calendar.className = "calendar calendar-shown";
build(new Date(_currentDate_ForDatePicker), !_initialized);
Expand Down Expand Up @@ -1006,18 +1006,6 @@ function calendarJs(elementOrId, options, searchOptions) {
_datePickerInput.value = getCustomFormattedDateText(_options.datePickerSelectedDateFormat, date);
_datePickerHiddenInput.value = padNumber(date.getDate()) + "/" + padNumber(date.getMonth()) + "/" + date.getFullYear();
}
function closeAnyOtherDatePickers() {
var elements = _document.getElementsByClassName("calendar calendar-shown");
var elementsArray = [].slice.call(elements);
var elementsArrayLength = elementsArray.length;
var elementsArrayIndex = 0;
for (; elementsArrayIndex < elementsArrayLength; elementsArrayIndex++) {
var element = elementsArray[elementsArrayIndex];
if (element.id !== _elementID) {
element.className = "calendar calendar-hidden";
}
}
}
function getDataPickerInputValueDate() {
var values = _datePickerHiddenInput.value.split("/");
var valuesDate = null;
Expand Down Expand Up @@ -1263,7 +1251,9 @@ function calendarJs(elementOrId, options, searchOptions) {
itemClosed = true;
}
hideTooltip();
hideAllContextMenusAcrossInstances();
hideAllElementsAcrossInstances("calendar-context-menu");
hideAllElementsAcrossInstances("years-drop-down");
hideAllElementsAcrossInstances("years-drop-down-no-months");
if (hideSearchHistoryDropDown) {
hideSearchHistoryDropDownMenu();
}
Expand Down Expand Up @@ -3086,18 +3076,6 @@ function calendarJs(elementOrId, options, searchOptions) {
}
return closed;
}
function hideAllContextMenusAcrossInstances() {
var elements = _document.getElementsByClassName("calendar-context-menu");
var elementsArray = [].slice.call(elements);
var elementsArrayLength = elementsArray.length;
var elementsArrayIndex = 0;
for (; elementsArrayIndex < elementsArrayLength; elementsArrayIndex++) {
var element = elementsArray[elementsArrayIndex];
if (element.id !== _elementID) {
element.style.display = "none";
}
}
}
function isContextMenuVisible(element) {
return element !== null && element.style.display === "block";
}
Expand Down Expand Up @@ -6660,6 +6638,22 @@ function calendarJs(elementOrId, options, searchOptions) {
}
_elements_InDocumentBody = [];
}
function hideAllElementsAcrossInstances(className, hideClassName) {
var elements = _document.getElementsByClassName(className);
var elementsArray = [].slice.call(elements);
var elementsArrayLength = elementsArray.length;
var elementsArrayIndex = 0;
for (; elementsArrayIndex < elementsArrayLength; elementsArrayIndex++) {
var element = elementsArray[elementsArrayIndex];
if (element.id !== _elementID) {
if (isDefined(hideClassName)) {
element.className = hideClassName;
} else {
element.style.display = "none";
}
}
}
}
function buildRadioButton(container, labelText, groupName, onChangeEvent) {
var lineContents = createElement("div", "radio-button-container");
container.appendChild(lineContents);
Expand Down Expand Up @@ -8911,7 +8905,7 @@ function calendarJs(elementOrId, options, searchOptions) {
return this;
};
this.getVersion = function() {
return "2.8.3";
return "2.8.4";
};
this.getId = function() {
return _elementID;
Expand Down
5 changes: 3 additions & 2 deletions dist/calendar.js.css
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Calendar.js Library v2.8.3
* Calendar.js Library v2.8.4
*
* Copyright 2023 Bunoon
* Released under the GNU AGPLv3 license
Expand Down Expand Up @@ -4006,6 +4006,7 @@ div.calendar-context-menu div.separator {
height: 12px;
border-top: 4px solid var(--title-bar-button-color);
border-radius: 50%;
box-sizing: content-box;
}
.ib-pin:not(.ib-no-hover):hover {
transition: all 0.3s;
Expand All @@ -4026,7 +4027,7 @@ div.calendar-context-menu div.separator {
transform: translate(-50%);
background-color: var(--title-bar-button-color);
width: 4px;
height: calc(100% - 4px - 2px);
height: 6px;
border-bottom-left-radius: 50%;
border-bottom-right-radius: 50%;
top: 0;
Expand Down
2 changes: 1 addition & 1 deletion dist/calendar.js.css.map

Large diffs are not rendered by default.

4 changes: 2 additions & 2 deletions dist/calendar.js.min.css

Large diffs are not rendered by default.

Loading

0 comments on commit 401423a

Please sign in to comment.