Skip to content

Commit

Permalink
[update] version 7.0.3
Browse files Browse the repository at this point in the history
  • Loading branch information
AlexKlimenkov committed Mar 15, 2024
1 parent 0823989 commit 3a753b4
Show file tree
Hide file tree
Showing 13 changed files with 165 additions and 76 deletions.
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# dhtmlxScheduler #

[![dhtmlx.com](https://img.shields.io/badge/made%20by-DHTMLX-blue)](https://dhtmlx.com/)
[![npm: v.7.0.2](https://img.shields.io/badge/npm-v.7.0.2-blue.svg)](https://www.npmjs.com/package/dhtmlx-scheduler)
[![npm: v.7.0.3](https://img.shields.io/badge/npm-v.7.0.3-blue.svg)](https://www.npmjs.com/package/dhtmlx-scheduler)
[![License: GPL v2](https://img.shields.io/badge/license-GPL%20v2-blue.svg)](https://www.gnu.org/licenses/old-licenses/gpl-2.0.html)

[DHTMLX Scheduler](https://dhtmlx.com/docs/products/dhtmlxScheduler) is a JavaScript library that allows you to add a Google-like scheduler to your web app or website.
Expand Down Expand Up @@ -87,7 +87,7 @@ scheduler.parse([

## License ##

dhtmlxScheduler v.7.0.2 Standard
dhtmlxScheduler v.7.0.3 Standard

To use dhtmlxScheduler in non-GPL projects (and get Pro version of the product), please obtain Commercial/Enterprise or Ultimate license on our site https://dhtmlx.com/docs/products/dhtmlxScheduler/#licensing or contact us at sales@dhtmlx.com

Expand Down
2 changes: 1 addition & 1 deletion bower.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "scheduler",
"version": "7.0.2",
"version": "7.0.3",
"homepage": "https://dhtmlx.com/docs/products/dhtmlxScheduler/",
"description": "JavaScript event calendar. Allows to manage events and appointments in different views",
"main": [
Expand Down
109 changes: 66 additions & 43 deletions codebase/dhtmlxscheduler.es.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion codebase/dhtmlxscheduler.es.js.map

Large diffs are not rendered by default.

20 changes: 10 additions & 10 deletions codebase/dhtmlxscheduler.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion codebase/dhtmlxscheduler.js.map

Large diffs are not rendered by default.

44 changes: 37 additions & 7 deletions codebase/sources/dhtmlxscheduler.es.js
Original file line number Diff line number Diff line change
Expand Up @@ -4264,7 +4264,7 @@ function extend$c(scheduler2) {
cs2 += " " + cse;
}
var bg_color = ev.color ? "--dhx-scheduler-event-background:" + ev.color + ";" : "";
var color = ev.textColor ? "--dhx-scheduler-event-text:" + ev.textColor + ";" : "";
var color = ev.textColor ? "--dhx-scheduler-event-color:" + ev.textColor + ";" : "";
var style_text = ["position:absolute", "top:" + y + "px", "left:" + x + "px", "width:" + (x2 - x - (timed ? 1 : 0)) + "px", "height:" + (this.xy.bar_height - 2) + "px", color, bg_color, ev._text_style || ""].join(";");
var html = "<div event_id='" + ev.id + "' " + this.config.event_attribute + "='" + ev.id + "' class='" + cs2 + "' style='" + style_text + "'" + this._waiAria.eventBarAttrString(ev) + ">";
if (resizable) {
Expand Down Expand Up @@ -7612,7 +7612,7 @@ class DatePicker {
}
}
function factoryMethod(extensionManager) {
const scheduler2 = { version: "7.0.2" };
const scheduler2 = { version: "7.0.3" };
extend$n(scheduler2);
extend$i(scheduler2);
extend$j(scheduler2);
Expand Down Expand Up @@ -8063,7 +8063,13 @@ function agenda_view(scheduler2) {
const selectedId = scheduler2.getState().select_id;
const cls = scheduler2.templates.event_class(calendarEvent.start_date, calendarEvent.end_date, calendarEvent);
const description = scheduler2.templates.agenda_text(calendarEvent.start_date, calendarEvent.end_date, calendarEvent);
return `<div class="dhx_cal_agenda_event_line ${cls || ""} ${calendarEvent.id == selectedId ? "dhx_cal_agenda_event_line_selected" : ""}" ${scheduler2.config.event_attribute}="${calendarEvent.id}">
let style = "";
if (calendarEvent.color || calendarEvent.textColor) {
const bg = calendarEvent.color ? "--dhx-scheduler-event-background:" + calendarEvent.color + ";" : "";
const color = calendarEvent.textColor ? "--dhx-scheduler-event-color:" + calendarEvent.textColor + ";" : "";
style = ` style="${bg}${color}" `;
}
return `<div class="dhx_cal_agenda_event_line ${cls || ""} ${calendarEvent.id == selectedId ? "dhx_cal_agenda_event_line_selected" : ""}" ${style} ${scheduler2.config.event_attribute}="${calendarEvent.id}">
<div class="dhx_cal_agenda_event_line_marker"></div>
<div class="dhx_cal_agenda_event_line_time">${dates}</div>
<div class="dhx_cal_agenda_event_line_text">${description}</div>
Expand Down Expand Up @@ -9173,9 +9179,13 @@ function marker(scheduler2) {
}
if (section) {
if (scheduler2.matrix && scheduler2.matrix[mode]) {
label += ", " + scheduler2.templates[mode + "_scale_label"](section.key, section.label, section);
const timeline = scheduler2.matrix[mode];
const sectionObject = timeline.y_unit[timeline.order[section]];
label += ", " + scheduler2.templates[mode + "_scale_label"](sectionObject.key, sectionObject.label, sectionObject);
} else if (scheduler2._props && scheduler2._props[mode]) {
label += ", " + scheduler2.templates[mode + "_scale_text"](section.key, section.label, section);
const units = scheduler2._props[mode];
const sectionObject = units.options[units.order[section]];
label += ", " + scheduler2.templates[mode + "_scale_text"](sectionObject.key, sectionObject.label, sectionObject);
}
}
for (var i = 0; i < divs.length; i++) {
Expand Down Expand Up @@ -9247,8 +9257,25 @@ function marker(scheduler2) {
if (!(min_date < end_date && max_date > start_date))
return blocks;
var block = this.createElement();
var start_pos = scheduler2._timeline_getX({ start_date }, false, view_opts) - 1;
var end_pos = scheduler2._timeline_getX({ start_date: end_date }, false, view_opts) - 1;
let start_pos;
let end_pos;
function set_date_part(source, target) {
target.setDate(1);
target.setFullYear(source.getFullYear());
target.setMonth(source.getMonth());
target.setDate(source.getDate());
}
if (!scheduler2.getView().days) {
start_pos = scheduler2._timeline_getX({ start_date }, false, view_opts);
end_pos = scheduler2._timeline_getX({ start_date: end_date }, false, view_opts);
} else {
const tempStart = new Date(start_date);
set_date_part(scheduler2._min_date, tempStart);
const tempEnd = new Date(end_date);
set_date_part(scheduler2._min_date, tempEnd);
start_pos = scheduler2._timeline_getX({ start_date: tempStart }, false, view_opts);
end_pos = scheduler2._timeline_getX({ start_date: tempEnd }, false, view_opts);
}
var height = view_opts._section_height[section] - 1 || view_opts.dy - 1;
var top = 0;
if (scheduler2._isRender("cell")) {
Expand Down Expand Up @@ -12180,6 +12207,9 @@ function limit(scheduler2) {
return divs;
};
scheduler2.markTimespan = function(configuration) {
if (!this._els) {
throw new Error("`scheduler.markTimespan` can't be used before scheduler initialization. Place `scheduler.markTimespan` call after `scheduler.init`.");
}
var rebuild_els = false;
if (!this._els["dhx_cal_data"]) {
scheduler2.get_elements();
Expand Down
2 changes: 1 addition & 1 deletion codebase/sources/dhtmlxscheduler.es.js.map

Large diffs are not rendered by default.

44 changes: 37 additions & 7 deletions codebase/sources/dhtmlxscheduler.js
Original file line number Diff line number Diff line change
Expand Up @@ -4268,7 +4268,7 @@
cs2 += " " + cse;
}
var bg_color = ev.color ? "--dhx-scheduler-event-background:" + ev.color + ";" : "";
var color = ev.textColor ? "--dhx-scheduler-event-text:" + ev.textColor + ";" : "";
var color = ev.textColor ? "--dhx-scheduler-event-color:" + ev.textColor + ";" : "";
var style_text = ["position:absolute", "top:" + y + "px", "left:" + x + "px", "width:" + (x2 - x - (timed ? 1 : 0)) + "px", "height:" + (this.xy.bar_height - 2) + "px", color, bg_color, ev._text_style || ""].join(";");
var html = "<div event_id='" + ev.id + "' " + this.config.event_attribute + "='" + ev.id + "' class='" + cs2 + "' style='" + style_text + "'" + this._waiAria.eventBarAttrString(ev) + ">";
if (resizable) {
Expand Down Expand Up @@ -7616,7 +7616,7 @@
}
}
function factoryMethod(extensionManager) {
const scheduler2 = { version: "7.0.2" };
const scheduler2 = { version: "7.0.3" };
extend$n(scheduler2);
extend$i(scheduler2);
extend$j(scheduler2);
Expand Down Expand Up @@ -8067,7 +8067,13 @@
const selectedId = scheduler2.getState().select_id;
const cls = scheduler2.templates.event_class(calendarEvent.start_date, calendarEvent.end_date, calendarEvent);
const description = scheduler2.templates.agenda_text(calendarEvent.start_date, calendarEvent.end_date, calendarEvent);
return `<div class="dhx_cal_agenda_event_line ${cls || ""} ${calendarEvent.id == selectedId ? "dhx_cal_agenda_event_line_selected" : ""}" ${scheduler2.config.event_attribute}="${calendarEvent.id}">
let style = "";
if (calendarEvent.color || calendarEvent.textColor) {
const bg = calendarEvent.color ? "--dhx-scheduler-event-background:" + calendarEvent.color + ";" : "";
const color = calendarEvent.textColor ? "--dhx-scheduler-event-color:" + calendarEvent.textColor + ";" : "";
style = ` style="${bg}${color}" `;
}
return `<div class="dhx_cal_agenda_event_line ${cls || ""} ${calendarEvent.id == selectedId ? "dhx_cal_agenda_event_line_selected" : ""}" ${style} ${scheduler2.config.event_attribute}="${calendarEvent.id}">
<div class="dhx_cal_agenda_event_line_marker"></div>
<div class="dhx_cal_agenda_event_line_time">${dates}</div>
<div class="dhx_cal_agenda_event_line_text">${description}</div>
Expand Down Expand Up @@ -9177,9 +9183,13 @@
}
if (section) {
if (scheduler2.matrix && scheduler2.matrix[mode]) {
label += ", " + scheduler2.templates[mode + "_scale_label"](section.key, section.label, section);
const timeline = scheduler2.matrix[mode];
const sectionObject = timeline.y_unit[timeline.order[section]];
label += ", " + scheduler2.templates[mode + "_scale_label"](sectionObject.key, sectionObject.label, sectionObject);
} else if (scheduler2._props && scheduler2._props[mode]) {
label += ", " + scheduler2.templates[mode + "_scale_text"](section.key, section.label, section);
const units = scheduler2._props[mode];
const sectionObject = units.options[units.order[section]];
label += ", " + scheduler2.templates[mode + "_scale_text"](sectionObject.key, sectionObject.label, sectionObject);
}
}
for (var i = 0; i < divs.length; i++) {
Expand Down Expand Up @@ -9251,8 +9261,25 @@
if (!(min_date < end_date && max_date > start_date))
return blocks;
var block = this.createElement();
var start_pos = scheduler2._timeline_getX({ start_date }, false, view_opts) - 1;
var end_pos = scheduler2._timeline_getX({ start_date: end_date }, false, view_opts) - 1;
let start_pos;
let end_pos;
function set_date_part(source, target) {
target.setDate(1);
target.setFullYear(source.getFullYear());
target.setMonth(source.getMonth());
target.setDate(source.getDate());
}
if (!scheduler2.getView().days) {
start_pos = scheduler2._timeline_getX({ start_date }, false, view_opts);
end_pos = scheduler2._timeline_getX({ start_date: end_date }, false, view_opts);
} else {
const tempStart = new Date(start_date);
set_date_part(scheduler2._min_date, tempStart);
const tempEnd = new Date(end_date);
set_date_part(scheduler2._min_date, tempEnd);
start_pos = scheduler2._timeline_getX({ start_date: tempStart }, false, view_opts);
end_pos = scheduler2._timeline_getX({ start_date: tempEnd }, false, view_opts);
}
var height = view_opts._section_height[section] - 1 || view_opts.dy - 1;
var top = 0;
if (scheduler2._isRender("cell")) {
Expand Down Expand Up @@ -12184,6 +12211,9 @@
return divs;
};
scheduler2.markTimespan = function(configuration) {
if (!this._els) {
throw new Error("`scheduler.markTimespan` can't be used before scheduler initialization. Place `scheduler.markTimespan` call after `scheduler.init`.");
}
var rebuild_els = false;
if (!this._els["dhx_cal_data"]) {
scheduler2.get_elements();
Expand Down
2 changes: 1 addition & 1 deletion codebase/sources/dhtmlxscheduler.js.map

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion codebase/sources/less/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "dhtmlx-scheduler-skins",
"version": "7.0.2",
"version": "7.0.3",
"description": "Less sources and a build tool for DHTMLXScheduler skins",
"scripts": {
"build": "node scripts.js --file=theme",
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "dhtmlx-scheduler",
"version": "7.0.2",
"version": "7.0.3",
"description": "JavaScript event calendar. Allows to manage events and appointments in different views",
"main": "codebase/dhtmlxscheduler.es.js",
"types": "codebase/dhtmlxscheduler.es.d.ts",
Expand Down
6 changes: 6 additions & 0 deletions whatsnew.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,9 @@
### 7.0.3

Issue with textColor property not applying in the Month view has been resolved
Fix for the color property not functioning in the Agenda view
Corrected an error that occurred when using Keyboard Navigation in Day Timeline view.

### 7.0.2

Compatibility regressions with DHTMLX Suite
Expand Down

0 comments on commit 3a753b4

Please sign in to comment.