makula-schedule 2.3.7 → 2.3.9

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -376,7 +376,11 @@ var SchedulerData = exports["default"] = /*#__PURE__*/function () {
376
376
  var resourceTableConfigWidth = this.getResourceTableConfigWidth();
377
377
  var schedulerWidth = this.getSchedulerWidth();
378
378
  var resourceTableWidth = this.isResourceViewResponsive() ? parseInt(schedulerWidth * Number(resourceTableConfigWidth.slice(0, -1)) / 100, 10) : resourceTableConfigWidth;
379
- if (this.isSchedulerResponsive() && this.isResourceViewResponsive() && this.getContentTableWidth() + resourceTableWidth < schedulerWidth) resourceTableWidth = schedulerWidth - this.getContentTableWidth();
379
+ // Only expand resource table in non-week views when there's extra space
380
+ if (this.viewType !== _default.ViewType.Week && this.isSchedulerResponsive() && this.getContentTableWidth() + resourceTableWidth < schedulerWidth) resourceTableWidth = schedulerWidth - this.getContentTableWidth();
381
+ console.log('schedulerWidth', schedulerWidth);
382
+ console.log('resourceTableConfigWidth', resourceTableConfigWidth);
383
+ console.log('resourceTableWidth', resourceTableWidth);
380
384
  return resourceTableWidth;
381
385
  }
382
386
  }, {
@@ -384,7 +388,18 @@ var SchedulerData = exports["default"] = /*#__PURE__*/function () {
384
388
  value: function getContentCellWidth() {
385
389
  var contentCellConfigWidth = this.getContentCellConfigWidth();
386
390
  var schedulerWidth = this.getSchedulerWidth();
387
- return this.isContentViewResponsive() ? parseInt(schedulerWidth * Number(contentCellConfigWidth.slice(0, -1)) / 100, 10) : contentCellConfigWidth;
391
+ if (this.isContentViewResponsive()) {
392
+ var resourceTableConfigWidth = this.getResourceTableConfigWidth();
393
+ var isResourceTableFixed = typeof resourceTableConfigWidth === 'number';
394
+
395
+ // For week view with fixed resource table, calculate cell width as percentage of remaining space
396
+ var baseWidth = schedulerWidth;
397
+ if (this.viewType === _default.ViewType.Week && isResourceTableFixed) {
398
+ baseWidth = schedulerWidth - resourceTableConfigWidth;
399
+ }
400
+ return parseInt(baseWidth * Number(contentCellConfigWidth.slice(0, -1)) / 100, 10);
401
+ }
402
+ return contentCellConfigWidth;
388
403
  }
389
404
  }, {
390
405
  key: "getContentTableWidth",
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "makula-schedule",
3
- "version": "2.3.7",
3
+ "version": "2.3.9",
4
4
  "description": "React Big Schedule is a powerful and intuitive scheduler and resource planning solution built with React. Seamlessly integrate this modern browser-compatible component into your applications to effectively manage time, appointments, and resources. With drag-and-drop functionality, interactive UI, and granular views, react-big-schedule empowers users to effortlessly schedule and allocate resources with precision. Enhance productivity and streamline your workflow with this React-based solution, designed to optimize time management and simplify calendar-based operations. Perfect for applications requiring advanced scheduling capabilities, react-big-schedule offers a seamless and intuitive experience for managing appointments, resource allocation, and time slots. Unlock the potential of your React projects with react-big-schedule and revolutionize the way you handle scheduling and resource planning. It is the updated version of react-big-scheduler",
5
5
  "keywords": [
6
6
  "react-big-schedule",