@seniorsistemas/angular-components 16.13.2 → 17.1.0

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.
Files changed (70) hide show
  1. package/bundles/seniorsistemas-angular-components.umd.js +1829 -24
  2. package/bundles/seniorsistemas-angular-components.umd.js.map +1 -1
  3. package/bundles/seniorsistemas-angular-components.umd.min.js +2 -2
  4. package/bundles/seniorsistemas-angular-components.umd.min.js.map +1 -1
  5. package/components/gantt/components/gantt/arrow.d.ts +16 -0
  6. package/components/gantt/components/gantt/bar.d.ts +43 -0
  7. package/components/gantt/components/gantt/gantt-options.d.ts +2 -0
  8. package/components/gantt/components/gantt/gantt.d.ts +66 -0
  9. package/components/gantt/components/gantt/popup.d.ts +11 -0
  10. package/components/gantt/components/gantt/utils/date-utils.d.ts +13 -0
  11. package/components/gantt/components/gantt/utils/svg-utils.d.ts +11 -0
  12. package/components/gantt/components/side-table/side-table.component.d.ts +7 -0
  13. package/components/gantt/gantt.component.d.ts +21 -0
  14. package/components/gantt/gantt.module.d.ts +2 -0
  15. package/components/gantt/index.d.ts +3 -0
  16. package/components/gantt/models/index.d.ts +3 -0
  17. package/components/gantt/models/options.d.ts +21 -0
  18. package/components/gantt/models/task.d.ts +21 -0
  19. package/components/gantt/models/view-mode.d.ts +9 -0
  20. package/components/switch/index.d.ts +2 -0
  21. package/components/switch/switch.component.d.ts +21 -0
  22. package/components/switch/switch.module.d.ts +2 -0
  23. package/esm2015/components/gantt/components/gantt/arrow.js +82 -0
  24. package/esm2015/components/gantt/components/gantt/bar.js +236 -0
  25. package/esm2015/components/gantt/components/gantt/gantt-options.js +16 -0
  26. package/esm2015/components/gantt/components/gantt/gantt.js +767 -0
  27. package/esm2015/components/gantt/components/gantt/popup.js +68 -0
  28. package/esm2015/components/gantt/components/gantt/utils/date-utils.js +126 -0
  29. package/esm2015/components/gantt/components/gantt/utils/svg-utils.js +119 -0
  30. package/esm2015/components/gantt/components/side-table/side-table.component.js +26 -0
  31. package/esm2015/components/gantt/gantt.component.js +112 -0
  32. package/esm2015/components/gantt/gantt.module.js +19 -0
  33. package/esm2015/components/gantt/index.js +4 -0
  34. package/esm2015/components/gantt/models/index.js +2 -0
  35. package/esm2015/components/gantt/models/options.js +1 -0
  36. package/esm2015/components/gantt/models/task.js +1 -0
  37. package/esm2015/components/gantt/models/view-mode.js +11 -0
  38. package/esm2015/components/switch/index.js +3 -0
  39. package/esm2015/components/switch/switch.component.js +86 -0
  40. package/esm2015/components/switch/switch.module.js +15 -0
  41. package/esm2015/public-api.js +3 -1
  42. package/esm2015/seniorsistemas-angular-components.js +25 -24
  43. package/esm5/components/gantt/components/gantt/arrow.js +81 -0
  44. package/esm5/components/gantt/components/gantt/bar.js +271 -0
  45. package/esm5/components/gantt/components/gantt/gantt-options.js +16 -0
  46. package/esm5/components/gantt/components/gantt/gantt.js +883 -0
  47. package/esm5/components/gantt/components/gantt/popup.js +59 -0
  48. package/esm5/components/gantt/components/gantt/utils/date-utils.js +134 -0
  49. package/esm5/components/gantt/components/gantt/utils/svg-utils.js +121 -0
  50. package/esm5/components/gantt/components/side-table/side-table.component.js +27 -0
  51. package/esm5/components/gantt/gantt.component.js +114 -0
  52. package/esm5/components/gantt/gantt.module.js +22 -0
  53. package/esm5/components/gantt/index.js +4 -0
  54. package/esm5/components/gantt/models/index.js +2 -0
  55. package/esm5/components/gantt/models/options.js +1 -0
  56. package/esm5/components/gantt/models/task.js +1 -0
  57. package/esm5/components/gantt/models/view-mode.js +11 -0
  58. package/esm5/components/switch/index.js +3 -0
  59. package/esm5/components/switch/switch.component.js +88 -0
  60. package/esm5/components/switch/switch.module.js +18 -0
  61. package/esm5/public-api.js +3 -1
  62. package/esm5/seniorsistemas-angular-components.js +25 -24
  63. package/fesm2015/seniorsistemas-angular-components.js +1647 -2
  64. package/fesm2015/seniorsistemas-angular-components.js.map +1 -1
  65. package/fesm5/seniorsistemas-angular-components.js +1802 -2
  66. package/fesm5/seniorsistemas-angular-components.js.map +1 -1
  67. package/package.json +1 -1
  68. package/public-api.d.ts +2 -0
  69. package/seniorsistemas-angular-components.d.ts +24 -23
  70. package/seniorsistemas-angular-components.metadata.json +1 -1
@@ -8605,6 +8605,1710 @@ var EditableOverlayModule = /** @class */ (function () {
8605
8605
  return EditableOverlayModule;
8606
8606
  }());
8607
8607
 
8608
+ var moment$7 = moment_;
8609
+ var YEAR = "year";
8610
+ var MONTH = "month";
8611
+ var DAY = "day";
8612
+ var HOUR = "hour";
8613
+ var MINUTE = "minute";
8614
+ var SECOND = "second";
8615
+ var MILLISECOND = "millisecond";
8616
+ var DateUtils = /** @class */ (function () {
8617
+ function DateUtils() {
8618
+ }
8619
+ DateUtils.parse = function (date) {
8620
+ return moment$7(date).toDate();
8621
+ };
8622
+ DateUtils.toString = function (date, with_time) {
8623
+ if (with_time === void 0) { with_time = false; }
8624
+ var result = with_time ? moment$7(date, "YYYY-MM-DD hh:mm:ss.SSS") : moment$7(date, "YYYY-MM-DD");
8625
+ return result.toString();
8626
+ };
8627
+ DateUtils.format = function (date, formatString, lang) {
8628
+ if (formatString === void 0) { formatString = "YYYY-MM-DD HH:mm:ss.SSS"; }
8629
+ if (lang === void 0) { lang = "en"; }
8630
+ var monthName = moment$7(date)
8631
+ .locale(lang)
8632
+ .startOf("month")
8633
+ .format("MMMM");
8634
+ var monthNameCapitalized = monthName.charAt(0).toUpperCase() + monthName.slice(1);
8635
+ var dateToFormat = moment$7(date);
8636
+ var format_map = {
8637
+ YYYY: dateToFormat.format("YYYY"),
8638
+ MM: dateToFormat.format("MM"),
8639
+ DD: dateToFormat.format("DD"),
8640
+ HH: dateToFormat.format("HH"),
8641
+ mm: dateToFormat.format("mm"),
8642
+ ss: dateToFormat.format("ss"),
8643
+ SSS: dateToFormat.format("SSS"),
8644
+ D: dateToFormat.format("D"),
8645
+ MMMM: monthNameCapitalized,
8646
+ MMM: monthNameCapitalized,
8647
+ };
8648
+ var str = formatString;
8649
+ var formattedValues = [];
8650
+ Object.keys(format_map)
8651
+ .sort(function (a, b) { return b.length - a.length; })
8652
+ .forEach(function (key) {
8653
+ if (str.includes(key)) {
8654
+ str = str.replace(key, "$" + formattedValues.length);
8655
+ formattedValues.push(format_map[key]);
8656
+ }
8657
+ });
8658
+ formattedValues.forEach(function (value, i) {
8659
+ str = str.replace("$" + i, value);
8660
+ });
8661
+ return str;
8662
+ };
8663
+ DateUtils.diff = function (fistDate, secondDate, scale) {
8664
+ var milliseconds = moment$7(fistDate).diff(secondDate, MILLISECOND);
8665
+ var seconds = moment$7(fistDate).diff(secondDate, SECOND);
8666
+ var minutes = moment$7(fistDate).diff(secondDate, MINUTE);
8667
+ var hours = moment$7(fistDate).diff(secondDate, HOUR);
8668
+ var days = moment$7(fistDate).diff(secondDate, DAY);
8669
+ var months = moment$7(fistDate).diff(secondDate, MONTH);
8670
+ var years = moment$7(fistDate).diff(secondDate, YEAR);
8671
+ if (!scale.endsWith("s")) {
8672
+ scale += "s";
8673
+ }
8674
+ return Math.floor({
8675
+ milliseconds: milliseconds,
8676
+ seconds: seconds,
8677
+ minutes: minutes,
8678
+ hours: hours,
8679
+ days: days,
8680
+ months: months,
8681
+ years: years,
8682
+ }[scale]);
8683
+ };
8684
+ DateUtils.today = function () {
8685
+ var dateStr = moment$7().format("YYY-MM-DD");
8686
+ return new Date(dateStr);
8687
+ };
8688
+ DateUtils.now = function () {
8689
+ return moment$7().toDate();
8690
+ };
8691
+ DateUtils.add = function (date, quantity, scale) {
8692
+ return moment$7(date).add(quantity, scale).toDate();
8693
+ };
8694
+ DateUtils.startOf = function (date, scale) {
8695
+ var _a;
8696
+ var scores = (_a = {},
8697
+ _a[YEAR] = 6,
8698
+ _a[MONTH] = 5,
8699
+ _a[DAY] = 4,
8700
+ _a[HOUR] = 3,
8701
+ _a[MINUTE] = 2,
8702
+ _a[SECOND] = 1,
8703
+ _a[MILLISECOND] = 0,
8704
+ _a);
8705
+ function shouldReset(_scale) {
8706
+ var max_score = scores[scale];
8707
+ return scores[_scale] <= max_score;
8708
+ }
8709
+ var vals = [
8710
+ date.getFullYear(),
8711
+ shouldReset(YEAR) ? 0 : date.getMonth(),
8712
+ shouldReset(MONTH) ? 1 : date.getDate(),
8713
+ shouldReset(DAY) ? 0 : date.getHours(),
8714
+ shouldReset(HOUR) ? 0 : date.getMinutes(),
8715
+ shouldReset(MINUTE) ? 0 : date.getSeconds(),
8716
+ shouldReset(SECOND) ? 0 : date.getMilliseconds(),
8717
+ ];
8718
+ return new Date(vals[0], vals[1], vals[2], vals[3], vals[4], vals[5], vals[6]);
8719
+ };
8720
+ DateUtils.clone = function (date) {
8721
+ return moment$7(date).toDate();
8722
+ };
8723
+ DateUtils.getDateValues = function (date) {
8724
+ return [
8725
+ date.getFullYear(),
8726
+ date.getMonth(),
8727
+ date.getDate(),
8728
+ date.getHours(),
8729
+ date.getMinutes(),
8730
+ date.getSeconds(),
8731
+ date.getMilliseconds(),
8732
+ ];
8733
+ };
8734
+ DateUtils.getDaysInMonth = function (date) {
8735
+ return moment$7(date, "YYYY-MM").daysInMonth();
8736
+ };
8737
+ return DateUtils;
8738
+ }());
8739
+
8740
+ var $ = function (expr, con) {
8741
+ return typeof expr === 'string'
8742
+ ? (con || document).querySelector(expr)
8743
+ : expr || null;
8744
+ };
8745
+ var createSVG = function (tag, attrs) {
8746
+ var elem = document.createElementNS("http://www.w3.org/2000/svg", tag);
8747
+ for (var attr in attrs) {
8748
+ if (attr === "append_to") {
8749
+ var parent_1 = attrs.append_to;
8750
+ parent_1.appendChild(elem);
8751
+ }
8752
+ else if (attr === "innerHTML") {
8753
+ elem.innerHTML = attrs.innerHTML;
8754
+ }
8755
+ else {
8756
+ elem.setAttribute(attr, attrs[attr]);
8757
+ }
8758
+ }
8759
+ return elem;
8760
+ };
8761
+ var animateSVG = function (svgElement, attr, from, to) {
8762
+ var animatedSvgElement = getAnimationElement(svgElement, attr, from, to);
8763
+ if (animatedSvgElement === svgElement) {
8764
+ // triggered 2nd time programmatically
8765
+ // trigger artificial click event
8766
+ var event_1 = document.createEvent("HTMLEvents");
8767
+ event_1.initEvent("click", true, true);
8768
+ // event.eventName = 'click'; TODO: Ver porque esta propriedade não existe
8769
+ animatedSvgElement.dispatchEvent(event_1);
8770
+ }
8771
+ };
8772
+ var getAnimationElement = function (svgElement, attr, from, to, dur, begin) {
8773
+ if (dur === void 0) { dur = "0.4s"; }
8774
+ if (begin === void 0) { begin = "0.1s"; }
8775
+ var animEl = svgElement.querySelector("animate");
8776
+ if (animEl) {
8777
+ $.attr(animEl, {
8778
+ attributeName: attr,
8779
+ from: from,
8780
+ to: to,
8781
+ dur: dur,
8782
+ begin: "click + " + begin,
8783
+ }, null);
8784
+ return svgElement;
8785
+ }
8786
+ var animateElement = createSVG("animate", {
8787
+ attributeName: attr,
8788
+ from: from,
8789
+ to: to,
8790
+ dur: dur,
8791
+ begin: begin,
8792
+ calcMode: "spline",
8793
+ values: from + ";" + to,
8794
+ keyTimes: "0; 1",
8795
+ keySplines: cubic_bezier("ease-out"),
8796
+ });
8797
+ svgElement.appendChild(animateElement);
8798
+ return svgElement;
8799
+ };
8800
+ var ɵ0 = getAnimationElement;
8801
+ var cubic_bezier = function (name) {
8802
+ return {
8803
+ ease: ".25 .1 .25 1",
8804
+ linear: "0 0 1 1",
8805
+ "ease-in": ".42 0 1 1",
8806
+ "ease-out": "0 0 .58 1",
8807
+ "ease-in-out": ".42 0 .58 1",
8808
+ }[name];
8809
+ };
8810
+ var ɵ1 = cubic_bezier;
8811
+ $.on = function (element, event, selector, callback) {
8812
+ if (!callback) {
8813
+ callback = selector;
8814
+ $.bind(element, event, callback);
8815
+ }
8816
+ else {
8817
+ $.delegate(element, event, selector, callback);
8818
+ }
8819
+ };
8820
+ $.off = function (element, event, handler) {
8821
+ element.removeEventListener(event, handler);
8822
+ };
8823
+ $.bind = function (element, event, callback) {
8824
+ event.split(/\s+/).forEach(function (event) {
8825
+ element.addEventListener(event, callback);
8826
+ });
8827
+ };
8828
+ $.delegate = function (element, event, selector, callback) {
8829
+ element.addEventListener(event, function (e) {
8830
+ var delegatedTarget = e.target.closest(selector);
8831
+ if (delegatedTarget) {
8832
+ e.delegatedTarget = delegatedTarget;
8833
+ callback.call(this, e, delegatedTarget);
8834
+ }
8835
+ });
8836
+ };
8837
+ $.closest = function (selector, element) {
8838
+ if (!element) {
8839
+ return null;
8840
+ }
8841
+ if (element.matches(selector)) {
8842
+ return element;
8843
+ }
8844
+ // TODO: Corrigir este problema
8845
+ // return $.closest(selector, element.parentNode);
8846
+ };
8847
+ $.attr = function (element, attr, value) {
8848
+ if (!value && typeof attr === "string") {
8849
+ return element.getAttribute(attr);
8850
+ }
8851
+ if (typeof attr === "object") {
8852
+ for (var key in attr) {
8853
+ $.attr(element, key, attr[key]);
8854
+ }
8855
+ return;
8856
+ }
8857
+ element.setAttribute(attr, value);
8858
+ };
8859
+
8860
+ var ViewMode;
8861
+ (function (ViewMode) {
8862
+ ViewMode["QuarterDay"] = "quarterDay";
8863
+ ViewMode["HalfDay"] = "halfDay";
8864
+ ViewMode["Day"] = "day";
8865
+ ViewMode["Week"] = "week";
8866
+ ViewMode["Month"] = "month";
8867
+ ViewMode["Year"] = "year";
8868
+ ViewMode["Hour"] = "hour";
8869
+ })(ViewMode || (ViewMode = {}));
8870
+
8871
+ var Bar = /** @class */ (function () {
8872
+ function Bar(gantt, task) {
8873
+ this._setDefaults(gantt, task);
8874
+ this._prepare();
8875
+ this._draw();
8876
+ this._bind();
8877
+ }
8878
+ Object.defineProperty(Bar.prototype, "arrows", {
8879
+ get: function () {
8880
+ return this._arrows;
8881
+ },
8882
+ set: function (arrows) {
8883
+ this._arrows = arrows;
8884
+ },
8885
+ enumerable: true,
8886
+ configurable: true
8887
+ });
8888
+ Object.defineProperty(Bar.prototype, "task", {
8889
+ get: function () {
8890
+ return this._task;
8891
+ },
8892
+ enumerable: true,
8893
+ configurable: true
8894
+ });
8895
+ Object.defineProperty(Bar.prototype, "element", {
8896
+ get: function () {
8897
+ return this._element;
8898
+ },
8899
+ enumerable: true,
8900
+ configurable: true
8901
+ });
8902
+ Object.defineProperty(Bar.prototype, "group", {
8903
+ get: function () {
8904
+ return this._group;
8905
+ },
8906
+ enumerable: true,
8907
+ configurable: true
8908
+ });
8909
+ Bar.prototype.updateBarPosition = function (_a) {
8910
+ var _this = this;
8911
+ var x = _a.x, width = _a.width;
8912
+ var bar = this.element;
8913
+ if (x) {
8914
+ // get all x values of parent task
8915
+ var xs = this.task.dependencies.map(function (dep) {
8916
+ return _this._gantt.get_bar(dep).element.getX();
8917
+ });
8918
+ // child task must not go before parent
8919
+ var valid_x = xs.reduce(function (prev, curr) {
8920
+ return x >= curr;
8921
+ }, x);
8922
+ if (!valid_x) {
8923
+ width = null;
8924
+ return;
8925
+ }
8926
+ this._updateAttr(bar, "x", x);
8927
+ }
8928
+ if (width && width >= this._gantt.options.columnWidth) {
8929
+ this._updateAttr(bar, "width", width);
8930
+ }
8931
+ this._updateLabelPosition();
8932
+ this._updateArrowPosition();
8933
+ };
8934
+ Bar.prototype.dateChanged = function () {
8935
+ var changed = false;
8936
+ var _a = this._computeStartEndDate(), newStartDate = _a.newStartDate, newEndDate = _a.newEndDate;
8937
+ if (this.task.start !== newStartDate) {
8938
+ changed = true;
8939
+ this.task.start = newStartDate;
8940
+ }
8941
+ if (this.task.end !== newEndDate) {
8942
+ changed = true;
8943
+ this.task.end = newEndDate;
8944
+ }
8945
+ if (changed) {
8946
+ this._gantt.trigger_event("onDateChange", [
8947
+ this.task,
8948
+ newStartDate,
8949
+ DateUtils.add(newEndDate, -1, "second"),
8950
+ ]);
8951
+ }
8952
+ ;
8953
+ };
8954
+ Bar.prototype.setActionCompleted = function () {
8955
+ var _this = this;
8956
+ this._actionCompleted = true;
8957
+ setTimeout(function () {
8958
+ _this._actionCompleted = false;
8959
+ }, 1000);
8960
+ };
8961
+ Bar.prototype._setDefaults = function (gantt, task) {
8962
+ this._actionCompleted = false;
8963
+ this._gantt = gantt;
8964
+ this._task = task;
8965
+ };
8966
+ Bar.prototype._prepare = function () {
8967
+ this._prepareValues();
8968
+ this._prepareHelpers();
8969
+ };
8970
+ Bar.prototype._prepareValues = function () {
8971
+ this._invalid = this.task.invalid;
8972
+ this._height = this._gantt.options.barHeight;
8973
+ this._x = this._computeX();
8974
+ this._y = this._computeY();
8975
+ this._cornerRadius = this._gantt.options.barCornerRadius;
8976
+ this._duration = DateUtils.diff(this.task.end, this.task.start, "minute") / this._gantt.options.step / 60.0;
8977
+ this._width = this._gantt.options.columnWidth * this._duration;
8978
+ this._group = createSVG("g", {
8979
+ class: "bar-wrapper " + (this.task.custom_class || ""),
8980
+ "data-id": this.task.id,
8981
+ });
8982
+ this._barGroup = createSVG("g", {
8983
+ class: "bar-group",
8984
+ append_to: this.group,
8985
+ });
8986
+ };
8987
+ Bar.prototype._prepareHelpers = function () {
8988
+ SVGElement.prototype.getX = function () {
8989
+ return +this.getAttribute("x");
8990
+ };
8991
+ SVGElement.prototype.getY = function () {
8992
+ return +this.getAttribute("y");
8993
+ };
8994
+ SVGElement.prototype.getWidth = function () {
8995
+ return +this.getAttribute("width");
8996
+ };
8997
+ SVGElement.prototype.getHeight = function () {
8998
+ return +this.getAttribute("height");
8999
+ };
9000
+ SVGElement.prototype.getEndX = function () {
9001
+ return this.getX() + this.getWidth();
9002
+ };
9003
+ };
9004
+ Bar.prototype._draw = function () {
9005
+ this._drawBar();
9006
+ this._drawLabel();
9007
+ };
9008
+ Bar.prototype._drawBar = function () {
9009
+ this._element = createSVG("rect", {
9010
+ x: this._x,
9011
+ y: this._y,
9012
+ width: this._width,
9013
+ height: this._height,
9014
+ rx: this._cornerRadius,
9015
+ ry: this._cornerRadius,
9016
+ class: "bar",
9017
+ append_to: this._barGroup,
9018
+ fill: this.task.color,
9019
+ });
9020
+ animateSVG(this.element, "width", 0, this._width);
9021
+ if (this._invalid) {
9022
+ this.element.classList.add("bar-invalid");
9023
+ }
9024
+ };
9025
+ Bar.prototype._drawLabel = function () {
9026
+ var _this = this;
9027
+ createSVG("text", {
9028
+ x: this._x + this._width / 2,
9029
+ y: this._y + this._height / 2,
9030
+ innerHTML: this.task.showTaskName ? this.task.name : "",
9031
+ class: "bar-label",
9032
+ append_to: this._barGroup,
9033
+ });
9034
+ // labels get BBox in the next tick
9035
+ requestAnimationFrame(function () { return _this._updateLabelPosition(); });
9036
+ };
9037
+ Bar.prototype._bind = function () {
9038
+ if (!this._invalid) {
9039
+ this._setupClickEvent();
9040
+ }
9041
+ };
9042
+ Bar.prototype._setupClickEvent = function () {
9043
+ var _this = this;
9044
+ $.on(this.group, "focus " + this._gantt.options.popupTrigger, function (e) {
9045
+ // just finished a move action, wait for a few seconds
9046
+ if (!_this._actionCompleted) {
9047
+ _this._showPopup();
9048
+ _this._gantt.unselect_all();
9049
+ _this.group.classList.add("active");
9050
+ }
9051
+ }, null);
9052
+ $.on(this.group, "dblclick", function (e) {
9053
+ // just finished a move action, wait for a few seconds
9054
+ if (!_this._actionCompleted) {
9055
+ _this._gantt.trigger_event("onClick", [_this.task]);
9056
+ }
9057
+ }, null);
9058
+ };
9059
+ Bar.prototype._showPopup = function () {
9060
+ if (this._gantt.bar_being_dragged) {
9061
+ return;
9062
+ }
9063
+ var formatString = this._gantt.view_is(ViewMode.Hour)
9064
+ ? "HH:ss"
9065
+ : "MMM D";
9066
+ var start_date = DateUtils.format(this.task.start, formatString, this._gantt.options.language);
9067
+ var end_date = DateUtils.format(DateUtils.add(this.task.end, -1, "second"), formatString, this._gantt.options.language);
9068
+ var subtitle = start_date + " - " + end_date;
9069
+ this._gantt.show_popup({
9070
+ target_element: this.element,
9071
+ title: this.task.name,
9072
+ subtitle: subtitle,
9073
+ task: this.task,
9074
+ });
9075
+ };
9076
+ Bar.prototype._computeStartEndDate = function () {
9077
+ var bar = this.element;
9078
+ var xInUnits = bar.getX() / this._gantt.options.columnWidth;
9079
+ var newStartDate = DateUtils.add(this._gantt.minDate, xInUnits * this._gantt.options.step, "hour");
9080
+ var width_in_units = bar.getWidth() / this._gantt.options.columnWidth;
9081
+ var newEndDate = DateUtils.add(newStartDate, width_in_units * this._gantt.options.step, "hour");
9082
+ return { newStartDate: newStartDate, newEndDate: newEndDate };
9083
+ };
9084
+ Bar.prototype._computeX = function () {
9085
+ var _a = this._gantt.options, step = _a.step, columnWidth = _a.columnWidth;
9086
+ var diff = DateUtils.diff(this.task.start, this._gantt.minDate, "hour");
9087
+ var x = (diff / step) * columnWidth;
9088
+ if (this._gantt.view_is(ViewMode.Month)) {
9089
+ var diff_1 = DateUtils.diff(this.task.start, this._gantt.minDate, "day");
9090
+ x = (diff_1 * columnWidth) / 30;
9091
+ }
9092
+ return x;
9093
+ };
9094
+ Bar.prototype._computeY = function () {
9095
+ return (this._gantt.options.headerHeight +
9096
+ this._gantt.options.padding +
9097
+ this.task._index * (this._height + this._gantt.options.padding));
9098
+ };
9099
+ Bar.prototype._updateAttr = function (element, attr, value) {
9100
+ value = +value;
9101
+ if (!isNaN(value)) {
9102
+ element.setAttribute(attr, value);
9103
+ }
9104
+ return element;
9105
+ };
9106
+ Bar.prototype._updateLabelPosition = function () {
9107
+ var bar = this.element, label = this.group.querySelector(".bar-label");
9108
+ if (label.getBBox().width > bar.getWidth()) {
9109
+ label.classList.add("big");
9110
+ label.setAttribute("x", bar.getX() + bar.getWidth() + 5);
9111
+ }
9112
+ else {
9113
+ label.classList.remove("big");
9114
+ label.setAttribute("x", bar.getX() + bar.getWidth() / 2);
9115
+ }
9116
+ };
9117
+ Bar.prototype._updateArrowPosition = function () {
9118
+ var e_1, _a;
9119
+ this._arrows = this._arrows || [];
9120
+ try {
9121
+ for (var _b = __values(this._arrows), _c = _b.next(); !_c.done; _c = _b.next()) {
9122
+ var arrow = _c.value;
9123
+ arrow.update();
9124
+ }
9125
+ }
9126
+ catch (e_1_1) { e_1 = { error: e_1_1 }; }
9127
+ finally {
9128
+ try {
9129
+ if (_c && !_c.done && (_a = _b.return)) _a.call(_b);
9130
+ }
9131
+ finally { if (e_1) throw e_1.error; }
9132
+ }
9133
+ };
9134
+ return Bar;
9135
+ }());
9136
+
9137
+ var Popup = /** @class */ (function () {
9138
+ function Popup(parent, customHtml) {
9139
+ this.parent = parent;
9140
+ this.customHtml = customHtml;
9141
+ this.make();
9142
+ }
9143
+ Popup.prototype.show = function (options) {
9144
+ if (!options.target_element) {
9145
+ throw new Error("target_element is required to show popup");
9146
+ }
9147
+ if (!options.position) {
9148
+ options.position = "left";
9149
+ }
9150
+ var target_element = options.target_element;
9151
+ if (this.customHtml) {
9152
+ var html = this.customHtml(options.task);
9153
+ html += '<div class="pointer"></div>';
9154
+ this.parent.innerHTML = html;
9155
+ this.pointer = this.parent.querySelector(".pointer");
9156
+ }
9157
+ else {
9158
+ // set data
9159
+ this.title.innerHTML = options.title;
9160
+ this.subtitle.innerHTML = options.subtitle;
9161
+ this.parent.style.width = this.parent.clientWidth + "px";
9162
+ }
9163
+ // set position
9164
+ var positionMeta;
9165
+ if (target_element instanceof HTMLElement) {
9166
+ positionMeta = target_element.getBoundingClientRect();
9167
+ }
9168
+ else if (target_element instanceof SVGElement) {
9169
+ positionMeta = options.target_element.getBBox();
9170
+ }
9171
+ if (options.position === 'left') {
9172
+ this.parent.style.left = positionMeta.x + (positionMeta.width + 10) + "px";
9173
+ this.parent.style.top = positionMeta.y + "px";
9174
+ this.pointer.style.transform = "rotateZ(90deg)";
9175
+ this.pointer.style.left = "-7px";
9176
+ this.pointer.style.top = "2px";
9177
+ }
9178
+ // show
9179
+ this.parent.style.opacity = 1;
9180
+ };
9181
+ Popup.prototype.make = function () {
9182
+ this.parent.innerHTML = "\n <div class=\"popup\">\n <div class=\"wrp-title\">\n <span class=\"title\"></span>\n </div>\n <div class=\"wrp-subtitle\">\n <span class=\"icon fas fa-calendar-alt\"></span>\n <span class=\"subtitle\"></span>\n </div>\n <div class=\"pointer\"></div>\n </div>\n ";
9183
+ this.hide();
9184
+ this.title = this.parent.querySelector(".title");
9185
+ this.subtitle = this.parent.querySelector(".subtitle");
9186
+ this.pointer = this.parent.querySelector(".pointer");
9187
+ };
9188
+ Popup.prototype.hide = function () {
9189
+ this.parent.style.opacity = 0;
9190
+ this.parent.style.left = 0;
9191
+ };
9192
+ return Popup;
9193
+ }());
9194
+
9195
+ var Arrow = /** @class */ (function () {
9196
+ function Arrow(gantt, fromTask, toTask) {
9197
+ this._gantt = gantt;
9198
+ this._fromTask = fromTask;
9199
+ this._toTask = toTask;
9200
+ this.calculatePath();
9201
+ this.draw();
9202
+ }
9203
+ Object.defineProperty(Arrow.prototype, "fromTask", {
9204
+ get: function () {
9205
+ return this._fromTask;
9206
+ },
9207
+ enumerable: true,
9208
+ configurable: true
9209
+ });
9210
+ Object.defineProperty(Arrow.prototype, "toTask", {
9211
+ get: function () {
9212
+ return this._toTask;
9213
+ },
9214
+ enumerable: true,
9215
+ configurable: true
9216
+ });
9217
+ Object.defineProperty(Arrow.prototype, "element", {
9218
+ get: function () {
9219
+ return this._element;
9220
+ },
9221
+ enumerable: true,
9222
+ configurable: true
9223
+ });
9224
+ Arrow.prototype.update = function () {
9225
+ this.calculatePath();
9226
+ this._element.setAttribute("d", this._path);
9227
+ };
9228
+ Arrow.prototype.calculatePath = function () {
9229
+ var _this = this;
9230
+ var startX = this.fromTask.element.getX() + this.fromTask.element.getWidth() / 2;
9231
+ var condition = function () {
9232
+ return _this.toTask.element.getX() < startX + _this._gantt.options.padding &&
9233
+ startX > _this.fromTask.element.getX() + _this._gantt.options.padding;
9234
+ };
9235
+ while (condition()) {
9236
+ startX -= 10;
9237
+ }
9238
+ var startY = this._gantt.options.headerHeight +
9239
+ this._gantt.options.barHeight +
9240
+ (this._gantt.options.padding + this._gantt.options.barHeight) *
9241
+ this.fromTask.task._index +
9242
+ this._gantt.options.padding;
9243
+ var endX = this.toTask.element.getX() - this._gantt.options.padding / 2;
9244
+ var endY = this._gantt.options.headerHeight +
9245
+ this._gantt.options.barHeight / 2 +
9246
+ (this._gantt.options.padding + this._gantt.options.barHeight) *
9247
+ this.toTask.task._index +
9248
+ this._gantt.options.padding;
9249
+ var fromIsBelowTo = this.fromTask.task._index > this.toTask.task._index;
9250
+ var curve = this._gantt.options.arrowCurve;
9251
+ var clockwise = fromIsBelowTo ? 1 : 0;
9252
+ var curveY = fromIsBelowTo ? -curve : curve;
9253
+ var offset = fromIsBelowTo
9254
+ ? endY + this._gantt.options.arrowCurve
9255
+ : endY - this._gantt.options.arrowCurve;
9256
+ this._path = "\n M " + startX + " " + startY + "\n V " + offset + "\n a " + curve + " " + curve + " 0 0 " + clockwise + " " + curve + " " + curveY + "\n L " + endX + " " + endY + "\n m -5 -5\n l 5 5\n l -5 5";
9257
+ if (this.toTask.element.getX() < this.fromTask.element.getX() + this._gantt.options.padding) {
9258
+ var down1 = this._gantt.options.padding / 2 - curve;
9259
+ var down2 = this.toTask.element.getY() + this.toTask.element.getHeight() / 2 - curveY;
9260
+ var left = this.toTask.element.getX() - this._gantt.options.padding;
9261
+ this._path = "\n M " + startX + " " + startY + "\n v " + down1 + "\n a " + curve + " " + curve + " 0 0 1 -" + curve + " " + curve + "\n H " + left + "\n a " + curve + " " + curve + " 0 0 " + clockwise + " -" + curve + " " + curveY + "\n V " + down2 + "\n a " + curve + " " + curve + " 0 0 " + clockwise + " " + curve + " " + curveY + "\n L " + endX + " " + endY + "\n m -5 -5\n l 5 5\n l -5 5";
9262
+ }
9263
+ };
9264
+ Arrow.prototype.draw = function () {
9265
+ this._element = createSVG("path", {
9266
+ d: this._path,
9267
+ "data-from": this.fromTask.task.id,
9268
+ "data-to": this.toTask.task.id,
9269
+ });
9270
+ };
9271
+ return Arrow;
9272
+ }());
9273
+
9274
+ var defaultOptions = {
9275
+ headerHeight: 94,
9276
+ columnWidth: 30,
9277
+ step: 24,
9278
+ barHeight: 20,
9279
+ barCornerRadius: 0,
9280
+ arrowCurve: 4,
9281
+ padding: 24,
9282
+ viewMode: ViewMode.Day,
9283
+ dateFormat: "YYYY-MM-DD",
9284
+ popupTrigger: "click",
9285
+ customPopupHtml: null,
9286
+ language: "en",
9287
+ };
9288
+
9289
+ var Gantt = /** @class */ (function () {
9290
+ function Gantt(wrapper, tasks, options) {
9291
+ this.setup_wrapper(wrapper);
9292
+ this.setup_options(options);
9293
+ this.setup_tasks(tasks);
9294
+ // initialize with default view mode
9295
+ this.change_view_mode();
9296
+ this.bind_events();
9297
+ }
9298
+ Object.defineProperty(Gantt.prototype, "minDate", {
9299
+ get: function () {
9300
+ return this._minDate;
9301
+ },
9302
+ enumerable: true,
9303
+ configurable: true
9304
+ });
9305
+ Object.defineProperty(Gantt.prototype, "maxDate", {
9306
+ get: function () {
9307
+ return this._maxDate;
9308
+ },
9309
+ enumerable: true,
9310
+ configurable: true
9311
+ });
9312
+ Gantt.prototype.setup_wrapper = function (element) {
9313
+ var svg_element, wrapper_element;
9314
+ // CSS Selector is passed
9315
+ if (typeof element === "string") {
9316
+ element = document.querySelector(element);
9317
+ }
9318
+ // get the SVGElement
9319
+ if (element instanceof HTMLElement) {
9320
+ wrapper_element = element;
9321
+ svg_element = element.querySelector("svg");
9322
+ }
9323
+ else if (element instanceof SVGElement) {
9324
+ svg_element = element;
9325
+ }
9326
+ else {
9327
+ throw new TypeError("Frappé Gantt only supports usage of a string CSS selector, HTML DOM element or SVG DOM element for the \'element\' parameter");
9328
+ }
9329
+ // svg element
9330
+ if (!svg_element) {
9331
+ // create it
9332
+ this.$svg = createSVG("svg", {
9333
+ append_to: wrapper_element,
9334
+ class: "gantt",
9335
+ });
9336
+ }
9337
+ else {
9338
+ this.$svg = svg_element;
9339
+ this.$svg.classList.add("gantt");
9340
+ }
9341
+ // wrapper element
9342
+ this.$container = document.createElement("div");
9343
+ this.$container.classList.add("gantt-container");
9344
+ var parent_element = this.$svg.parentElement;
9345
+ parent_element.appendChild(this.$container);
9346
+ this.$container.appendChild(this.$svg);
9347
+ // popup wrapper
9348
+ this.popup_wrapper = document.createElement("div");
9349
+ this.popup_wrapper.classList.add("popup-wrapper");
9350
+ this.$container.appendChild(this.popup_wrapper);
9351
+ };
9352
+ Gantt.prototype.setup_options = function (options) {
9353
+ this.options = Object.assign({}, defaultOptions, options);
9354
+ };
9355
+ Gantt.prototype.setup_tasks = function (tasks) {
9356
+ // prepare tasks
9357
+ this.tasks = tasks.map(function (task, i) {
9358
+ //standard colors if needed
9359
+ task.color = task.color || '#7892A1';
9360
+ // convert to Date objects
9361
+ task._start = DateUtils.parse(task.start);
9362
+ task._end = DateUtils.parse(task.end);
9363
+ // make task invalid if duration too large
9364
+ if (DateUtils.diff(task._end, task._start, "year") > 10) {
9365
+ task.end = null;
9366
+ }
9367
+ // cache index
9368
+ task._index = i;
9369
+ if (typeof task._row_id === "number") {
9370
+ task._index = task._row_id;
9371
+ }
9372
+ // invalid dates
9373
+ if (!task.start && !task.end) {
9374
+ var today = DateUtils.today();
9375
+ task._start = today;
9376
+ task._end = DateUtils.add(today, 2, "day");
9377
+ }
9378
+ if (!task.start && task.end) {
9379
+ task._start = DateUtils.add(task._end, -2, 'day');
9380
+ }
9381
+ if (task.start && !task.end) {
9382
+ task._end = DateUtils.add(task._start, 2, "day");
9383
+ }
9384
+ // if hours is not set, assume the last day is full day
9385
+ // e.g: 2018-09-09 becomes 2018-09-09 23:59:59
9386
+ var task_end_values = DateUtils.getDateValues(task._end);
9387
+ if (task_end_values.slice(3).every(function (d) { return d === 0; })) {
9388
+ task._end = DateUtils.add(task._end, 24, "hour");
9389
+ }
9390
+ // invalid flag
9391
+ if (!task.start || !task.end) {
9392
+ task.invalid = true;
9393
+ }
9394
+ // dependencies
9395
+ if (typeof task.dependencies === "string" || !task.dependencies) {
9396
+ var deps = [];
9397
+ if (task.dependencies) {
9398
+ deps = task.dependencies
9399
+ .split(',')
9400
+ .map(function (d) { return d.trim(); })
9401
+ .filter(function (d) { return d; });
9402
+ }
9403
+ task.dependencies = deps;
9404
+ }
9405
+ // uids
9406
+ if (!task.id) {
9407
+ task.id = generate_id(task);
9408
+ }
9409
+ return task;
9410
+ });
9411
+ this.setup_dependencies();
9412
+ };
9413
+ Gantt.prototype.setup_dependencies = function () {
9414
+ var e_1, _a, e_2, _b;
9415
+ this.dependency_map = {};
9416
+ try {
9417
+ for (var _c = __values(this.tasks), _d = _c.next(); !_d.done; _d = _c.next()) {
9418
+ var t = _d.value;
9419
+ try {
9420
+ for (var _e = (e_2 = void 0, __values(t.dependencies)), _f = _e.next(); !_f.done; _f = _e.next()) {
9421
+ var d = _f.value;
9422
+ this.dependency_map[d] = this.dependency_map[d] || [];
9423
+ this.dependency_map[d].push(t.id);
9424
+ }
9425
+ }
9426
+ catch (e_2_1) { e_2 = { error: e_2_1 }; }
9427
+ finally {
9428
+ try {
9429
+ if (_f && !_f.done && (_b = _e.return)) _b.call(_e);
9430
+ }
9431
+ finally { if (e_2) throw e_2.error; }
9432
+ }
9433
+ }
9434
+ }
9435
+ catch (e_1_1) { e_1 = { error: e_1_1 }; }
9436
+ finally {
9437
+ try {
9438
+ if (_d && !_d.done && (_a = _c.return)) _a.call(_c);
9439
+ }
9440
+ finally { if (e_1) throw e_1.error; }
9441
+ }
9442
+ };
9443
+ Gantt.prototype.refresh = function (tasks) {
9444
+ this.setup_tasks(tasks);
9445
+ this.change_view_mode();
9446
+ };
9447
+ Gantt.prototype.change_view_mode = function (mode) {
9448
+ if (mode === void 0) { mode = this.options.viewMode; }
9449
+ this.update_view_scale(mode);
9450
+ this.setup_dates();
9451
+ this.render();
9452
+ // fire viewmode_change event
9453
+ this.trigger_event("onViewChange", [mode]);
9454
+ };
9455
+ Gantt.prototype.update_view_scale = function (view_mode) {
9456
+ this.options.viewMode = view_mode;
9457
+ // this.isHourView = false;
9458
+ if (view_mode === ViewMode.Hour) {
9459
+ this.options.step = 24 / 24;
9460
+ this.options.columnWidth = 50;
9461
+ // this.isHourView = true;
9462
+ }
9463
+ else if (view_mode === ViewMode.Day) {
9464
+ this.options.step = 24;
9465
+ this.options.columnWidth = 50;
9466
+ }
9467
+ else if (view_mode === ViewMode.HalfDay) {
9468
+ this.options.step = 24 / 2;
9469
+ this.options.columnWidth = 50;
9470
+ }
9471
+ else if (view_mode === ViewMode.QuarterDay) {
9472
+ this.options.step = 24 / 4;
9473
+ this.options.columnWidth = 50;
9474
+ }
9475
+ else if (view_mode === ViewMode.Week) {
9476
+ this.options.step = 24 * 7;
9477
+ this.options.columnWidth = 140;
9478
+ }
9479
+ else if (view_mode === ViewMode.Month) {
9480
+ this.options.step = 24 * 30;
9481
+ this.options.columnWidth = 120;
9482
+ }
9483
+ else if (view_mode === ViewMode.Year) {
9484
+ this.options.step = 24 * 365;
9485
+ this.options.columnWidth = 120;
9486
+ }
9487
+ };
9488
+ Gantt.prototype.setup_dates = function () {
9489
+ this.setup_gantt_dates();
9490
+ this.setup_date_values();
9491
+ };
9492
+ Gantt.prototype.setup_gantt_dates = function () {
9493
+ var e_3, _a;
9494
+ var _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q;
9495
+ this._minDate = null;
9496
+ this._maxDate = null;
9497
+ try {
9498
+ for (var _r = __values(this.tasks), _s = _r.next(); !_s.done; _s = _r.next()) {
9499
+ var task = _s.value;
9500
+ // set global start and end date
9501
+ if (!this.minDate || task.start < this.minDate) {
9502
+ this._minDate = task.start;
9503
+ }
9504
+ if (!this.maxDate || task.end > this.maxDate) {
9505
+ this._maxDate = task.end;
9506
+ }
9507
+ }
9508
+ }
9509
+ catch (e_3_1) { e_3 = { error: e_3_1 }; }
9510
+ finally {
9511
+ try {
9512
+ if (_s && !_s.done && (_a = _r.return)) _a.call(_r);
9513
+ }
9514
+ finally { if (e_3) throw e_3.error; }
9515
+ }
9516
+ this._realMinDate = this.minDate;
9517
+ this._realMaxDate = this.maxDate;
9518
+ switch (this.options.viewMode) {
9519
+ case ViewMode.Hour:
9520
+ this._minDate = DateUtils.add(this.minDate, -((_b = this.options.marginBeforeStart) !== null && _b !== void 0 ? _b : 1), "hour");
9521
+ this._maxDate = DateUtils.add(this.maxDate, (_c = this.options.marginAfterEnd) !== null && _c !== void 0 ? _c : 1, "hour");
9522
+ break;
9523
+ case ViewMode.QuarterDay:
9524
+ this._minDate = DateUtils.add(this.minDate, -((_d = this.options.marginBeforeStart) !== null && _d !== void 0 ? _d : 12), "hour");
9525
+ this._maxDate = DateUtils.add(this.maxDate, (_e = this.options.marginAfterEnd) !== null && _e !== void 0 ? _e : 12, "hour");
9526
+ break;
9527
+ case ViewMode.HalfDay:
9528
+ this._minDate = DateUtils.add(this.minDate, -((_f = this.options.marginBeforeStart) !== null && _f !== void 0 ? _f : 1), "day");
9529
+ this._maxDate = DateUtils.add(this.maxDate, (_g = this.options.marginAfterEnd) !== null && _g !== void 0 ? _g : 1, "day");
9530
+ break;
9531
+ case ViewMode.Day:
9532
+ this._minDate = DateUtils.add(this.minDate, -((_h = this.options.marginBeforeStart) !== null && _h !== void 0 ? _h : 3), "day");
9533
+ this._maxDate = DateUtils.add(this.maxDate, (_j = this.options.marginAfterEnd) !== null && _j !== void 0 ? _j : 3, "day");
9534
+ break;
9535
+ case ViewMode.Week:
9536
+ this._minDate = DateUtils.add(this.minDate, -((_k = this.options.marginBeforeStart) !== null && _k !== void 0 ? _k : 1), "month");
9537
+ this._maxDate = DateUtils.add(this.maxDate, (_l = this.options.marginAfterEnd) !== null && _l !== void 0 ? _l : 1, "month");
9538
+ break;
9539
+ case ViewMode.Month:
9540
+ this._minDate = DateUtils.add(this.minDate, -((_m = this.options.marginBeforeStart) !== null && _m !== void 0 ? _m : 1), "year");
9541
+ this._maxDate = DateUtils.add(this.maxDate, (_o = this.options.marginAfterEnd) !== null && _o !== void 0 ? _o : 1, "year");
9542
+ break;
9543
+ case ViewMode.Year:
9544
+ this._minDate = DateUtils.add(this.minDate, -((_p = this.options.marginBeforeStart) !== null && _p !== void 0 ? _p : 2), "year");
9545
+ this._maxDate = DateUtils.add(this.maxDate, (_q = this.options.marginAfterEnd) !== null && _q !== void 0 ? _q : 2, "year");
9546
+ break;
9547
+ }
9548
+ };
9549
+ Gantt.prototype.setup_date_values = function () {
9550
+ this.dates = [];
9551
+ var cur_date = null;
9552
+ while (cur_date === null || cur_date < this.maxDate) {
9553
+ if (!cur_date) {
9554
+ cur_date = DateUtils.clone(this.minDate);
9555
+ }
9556
+ else {
9557
+ if (this.view_is(ViewMode.Year)) {
9558
+ cur_date = DateUtils.add(cur_date, 1, "year");
9559
+ }
9560
+ else if (this.view_is(ViewMode.Month)) {
9561
+ cur_date = DateUtils.add(cur_date, 1, "month");
9562
+ }
9563
+ else {
9564
+ cur_date = DateUtils.add(cur_date, this.options.step, 'hour');
9565
+ }
9566
+ }
9567
+ this.dates.push(cur_date);
9568
+ }
9569
+ console.log("cur_date", cur_date);
9570
+ console.log("dates", this.dates);
9571
+ };
9572
+ Gantt.prototype.bind_events = function () {
9573
+ this.bind_grid_click();
9574
+ this.bind_bar_events();
9575
+ };
9576
+ Gantt.prototype.render = function () {
9577
+ this.clear();
9578
+ this.setup_layers();
9579
+ this.make_grid();
9580
+ this.make_dates();
9581
+ this.make_bars();
9582
+ this.make_arrows();
9583
+ this.map_arrows_on_bars();
9584
+ this.set_width();
9585
+ this.set_scroll_position();
9586
+ };
9587
+ Gantt.prototype.setup_layers = function () {
9588
+ var e_4, _a;
9589
+ this.layers = {};
9590
+ var layers = ["grid", "date", "arrow", "progress", "bar", "details"];
9591
+ try {
9592
+ // make group layers
9593
+ for (var layers_1 = __values(layers), layers_1_1 = layers_1.next(); !layers_1_1.done; layers_1_1 = layers_1.next()) {
9594
+ var layer = layers_1_1.value;
9595
+ this.layers[layer] = createSVG('g', {
9596
+ class: layer,
9597
+ append_to: this.$svg,
9598
+ });
9599
+ }
9600
+ }
9601
+ catch (e_4_1) { e_4 = { error: e_4_1 }; }
9602
+ finally {
9603
+ try {
9604
+ if (layers_1_1 && !layers_1_1.done && (_a = layers_1.return)) _a.call(layers_1);
9605
+ }
9606
+ finally { if (e_4) throw e_4.error; }
9607
+ }
9608
+ };
9609
+ Gantt.prototype.make_grid = function () {
9610
+ this.make_grid_background();
9611
+ this.make_grid_rows();
9612
+ this.make_grid_header();
9613
+ this.make_grid_highlights();
9614
+ this.make_grid_ticks();
9615
+ };
9616
+ Gantt.prototype.make_grid_background = function () {
9617
+ var grid_width = this.dates.length * this.options.columnWidth;
9618
+ var distinct_rows = __spread(new Set(this.tasks.map(function (x) { return x._row_id; })));
9619
+ var grid_height = this.options.headerHeight +
9620
+ this.options.padding / 2 +
9621
+ (this.options.barHeight + this.options.padding) *
9622
+ distinct_rows.length;
9623
+ createSVG("rect", {
9624
+ x: 0,
9625
+ y: 0,
9626
+ width: grid_width,
9627
+ height: grid_height,
9628
+ class: "grid-background",
9629
+ append_to: this.layers.grid,
9630
+ });
9631
+ $.attr(this.$svg, {
9632
+ height: grid_height,
9633
+ width: "100%",
9634
+ }, null);
9635
+ };
9636
+ Gantt.prototype.make_grid_rows = function () {
9637
+ var _this = this;
9638
+ var rows_layer = createSVG("g", { append_to: this.layers.grid });
9639
+ var lines_layer = createSVG("g", { append_to: this.layers.grid });
9640
+ var row_width = this.dates.length * this.options.columnWidth;
9641
+ var row_height = this.options.barHeight + this.options.padding;
9642
+ //TODO: ajustar o posicionamento das linhas
9643
+ var row_y = this.options.headerHeight + this.options.padding / 2;
9644
+ this.tasks.forEach(function (_) {
9645
+ createSVG("rect", {
9646
+ x: 0,
9647
+ y: row_y,
9648
+ width: row_width,
9649
+ height: row_height,
9650
+ class: "grid-row",
9651
+ append_to: rows_layer,
9652
+ });
9653
+ createSVG("line", {
9654
+ x1: 0,
9655
+ y1: row_y + row_height,
9656
+ x2: row_width,
9657
+ y2: row_y + row_height,
9658
+ class: "row-line",
9659
+ append_to: lines_layer,
9660
+ });
9661
+ row_y += _this.options.barHeight + _this.options.padding;
9662
+ });
9663
+ };
9664
+ Gantt.prototype.make_grid_header = function () {
9665
+ // const addIsHourView = this.isHourView ? 25 : 10
9666
+ var header_width = this.dates.length * this.options.columnWidth;
9667
+ var header_height = this.options.headerHeight + 10;
9668
+ createSVG("rect", {
9669
+ x: 0,
9670
+ y: 0,
9671
+ width: header_width,
9672
+ height: header_height,
9673
+ class: "grid-header",
9674
+ append_to: this.layers.grid,
9675
+ });
9676
+ };
9677
+ Gantt.prototype.make_grid_ticks = function () {
9678
+ var e_5, _a;
9679
+ var tick_x = 0;
9680
+ var tick_y = this.options.headerHeight + this.options.padding / 2;
9681
+ var tick_height = (this.options.barHeight + this.options.padding) *
9682
+ this.tasks.length;
9683
+ try {
9684
+ for (var _b = __values(this.dates), _c = _b.next(); !_c.done; _c = _b.next()) {
9685
+ var date = _c.value;
9686
+ var tick_class = "tick";
9687
+ // thick tick for monday
9688
+ if (this.view_is(ViewMode.Day) && date.getDate() === 1) {
9689
+ tick_class += " thick";
9690
+ }
9691
+ // thick tick for first week
9692
+ if (this.view_is(ViewMode.Week) &&
9693
+ date.getDate() >= 1 &&
9694
+ date.getDate() < 8) {
9695
+ tick_class += " thick";
9696
+ }
9697
+ // thick ticks for quarters
9698
+ if (this.view_is(ViewMode.Month) && date.getMonth() % 3 === 0) {
9699
+ tick_class += " thick";
9700
+ }
9701
+ createSVG("path", {
9702
+ d: "M " + tick_x + " " + tick_y + " v " + tick_height,
9703
+ class: tick_class,
9704
+ append_to: this.layers.grid,
9705
+ });
9706
+ if (this.view_is(ViewMode.Month)) {
9707
+ tick_x +=
9708
+ (DateUtils.getDaysInMonth(date) *
9709
+ this.options.columnWidth) /
9710
+ 30;
9711
+ }
9712
+ else {
9713
+ tick_x += this.options.columnWidth;
9714
+ }
9715
+ }
9716
+ }
9717
+ catch (e_5_1) { e_5 = { error: e_5_1 }; }
9718
+ finally {
9719
+ try {
9720
+ if (_c && !_c.done && (_a = _b.return)) _a.call(_b);
9721
+ }
9722
+ finally { if (e_5) throw e_5.error; }
9723
+ }
9724
+ };
9725
+ Gantt.prototype.make_grid_highlights = function () {
9726
+ var e_6, _a;
9727
+ if (this.view_is(ViewMode.Day)) {
9728
+ var width = this.options.columnWidth;
9729
+ var height = (this.options.barHeight + this.options.padding) *
9730
+ this.tasks.length +
9731
+ this.options.headerHeight +
9732
+ this.options.padding / 2;
9733
+ var x = 0;
9734
+ try {
9735
+ for (var _b = __values(this.dates), _c = _b.next(); !_c.done; _c = _b.next()) {
9736
+ var date = _c.value;
9737
+ var y = (this.options.headerHeight + this.options.padding) / 2;
9738
+ var isToday = date.toString() == DateUtils.today();
9739
+ var isWeekend = (date.getDay() == 0 || date.getDay() == 6);
9740
+ var className = void 0;
9741
+ if (isToday) {
9742
+ className = "today-highlight";
9743
+ y = (this.options.headerHeight + this.options.padding) / 2;
9744
+ }
9745
+ else if (isWeekend) {
9746
+ className = "weekend-highlight";
9747
+ }
9748
+ var rx = 3;
9749
+ var ry = 3;
9750
+ if (isToday || isWeekend) {
9751
+ createSVG("rect", {
9752
+ x: x,
9753
+ y: y,
9754
+ rx: rx,
9755
+ ry: ry,
9756
+ width: width,
9757
+ height: height,
9758
+ class: className,
9759
+ append_to: this.layers.grid
9760
+ });
9761
+ }
9762
+ x += this.options.columnWidth;
9763
+ }
9764
+ }
9765
+ catch (e_6_1) { e_6 = { error: e_6_1 }; }
9766
+ finally {
9767
+ try {
9768
+ if (_c && !_c.done && (_a = _b.return)) _a.call(_b);
9769
+ }
9770
+ finally { if (e_6) throw e_6.error; }
9771
+ }
9772
+ }
9773
+ };
9774
+ Gantt.prototype.make_dates = function () {
9775
+ var dates = this.get_dates_to_draw();
9776
+ var isHourView = this.view_is([ViewMode.Hour, ViewMode.QuarterDay, ViewMode.HalfDay]);
9777
+ var counter = 0;
9778
+ for (var i = 0; i < dates.length; i++) {
9779
+ var date = dates[i];
9780
+ if (isHourView && date.date >= this._realMinDate && date.date <= this._realMaxDate) {
9781
+ createSVG("text", {
9782
+ x: date.lower_x,
9783
+ y: date.lower_y,
9784
+ innerHTML: "H" + counter++ * this.options.step,
9785
+ class: "title-1",
9786
+ append_to: this.layers.date,
9787
+ });
9788
+ }
9789
+ createSVG("text", {
9790
+ x: date.lower_x,
9791
+ y: date.lower_y + 20,
9792
+ innerHTML: date.lower_text,
9793
+ class: "title-2",
9794
+ append_to: this.layers.date,
9795
+ });
9796
+ if (date.upper_text) {
9797
+ var $upper_text = createSVG("text", {
9798
+ x: date.upper_x,
9799
+ y: date.upper_y,
9800
+ innerHTML: date.upper_text,
9801
+ class: "upper-text",
9802
+ append_to: this.layers.date,
9803
+ });
9804
+ // remove out-of-bound dates
9805
+ if ($upper_text.getBBox().x2 > this.layers.grid.getBBox().width) {
9806
+ $upper_text.remove();
9807
+ }
9808
+ }
9809
+ }
9810
+ };
9811
+ Gantt.prototype.get_dates_to_draw = function () {
9812
+ var _this = this;
9813
+ var last_date = null;
9814
+ var dates = this.dates.map(function (date, i) {
9815
+ var d = _this.get_date_info(date, last_date, i);
9816
+ last_date = date;
9817
+ return d;
9818
+ });
9819
+ return dates;
9820
+ };
9821
+ Gantt.prototype.get_date_info = function (date, last_date, i) {
9822
+ if (!last_date) {
9823
+ last_date = DateUtils.add(date, 1, "year");
9824
+ }
9825
+ var date_text = {
9826
+ hourLower: DateUtils.format(date, "HH:mm", this.options.language),
9827
+ quarterDayLower: DateUtils.format(date, "HH:mm", this.options.language),
9828
+ halfDayLower: DateUtils.format(date, "HH:mm", this.options.language),
9829
+ dayLower: date.getDate() !== last_date.getDate()
9830
+ ? DateUtils.format(date, "D", this.options.language)
9831
+ : "",
9832
+ weekLower: date.getMonth() !== last_date.getMonth()
9833
+ ? DateUtils.format(date, "D MMM", this.options.language)
9834
+ : DateUtils.format(date, "D", this.options.language),
9835
+ monthLower: DateUtils.format(date, "MMMM", this.options.language),
9836
+ yearLower: DateUtils.format(date, "YYYY", this.options.language),
9837
+ quarterDayUpper: date.getDate() !== last_date.getDate()
9838
+ ? DateUtils.format(date, "D MMM", this.options.language)
9839
+ : "",
9840
+ halfDayUpper: date.getDate() !== last_date.getDate()
9841
+ ? date.getMonth() !== last_date.getMonth()
9842
+ ? DateUtils.format(date, "D MMM", this.options.language)
9843
+ : DateUtils.format(date, "D", this.options.language)
9844
+ : "",
9845
+ dayUpper: date.getMonth() !== last_date.getMonth()
9846
+ ? DateUtils.format(date, "MMMM", this.options.language)
9847
+ : "",
9848
+ weekUpper: date.getMonth() !== last_date.getMonth()
9849
+ ? DateUtils.format(date, "MMMM", this.options.language)
9850
+ : "",
9851
+ monthUpper: date.getFullYear() !== last_date.getFullYear()
9852
+ ? DateUtils.format(date, "YYYY", this.options.language)
9853
+ : "",
9854
+ yearUpper: date.getFullYear() !== last_date.getFullYear()
9855
+ ? DateUtils.format(date, "YYYY", this.options.language)
9856
+ : "",
9857
+ hour: date.getHours() !== last_date.getHours()
9858
+ ? DateUtils.format(date, "HH:mm", this.options.language)
9859
+ : "",
9860
+ };
9861
+ // Descontando 20 para adcionar uma segunda linha de informação no cabeçalho
9862
+ var base_pos = {
9863
+ x: i * this.options.columnWidth,
9864
+ lower_y: this.options.headerHeight - 20,
9865
+ upper_y: this.options.headerHeight - 20 - 25,
9866
+ };
9867
+ var x_pos = {
9868
+ hourLower: this.options.columnWidth / 2,
9869
+ hourUpper: this.options.columnWidth * 24 / 2,
9870
+ quarterDayLower: this.options.columnWidth / 2,
9871
+ quarterDayUpper: this.options.columnWidth * 4 / 2,
9872
+ halfDayLower: this.options.columnWidth / 2,
9873
+ halfDayUpper: this.options.columnWidth * 2 / 2,
9874
+ dayLower: this.options.columnWidth / 2,
9875
+ dayUpper: (this.options.columnWidth * 30) / 2,
9876
+ weekLower: 0,
9877
+ weekUpper: (this.options.columnWidth * 4) / 2,
9878
+ monthLower: this.options.columnWidth / 2,
9879
+ monthUpper: (this.options.columnWidth * 12) / 2,
9880
+ yearLower: this.options.columnWidth / 2,
9881
+ yearUpper: (this.options.columnWidth * 30) / 2,
9882
+ };
9883
+ return {
9884
+ upper_text: date_text[this.options.viewMode + "Upper"],
9885
+ lower_text: date_text[this.options.viewMode + "Lower"],
9886
+ upper_x: base_pos.x + x_pos[this.options.viewMode + "Upper"],
9887
+ upper_y: base_pos.upper_y,
9888
+ lower_x: base_pos.x + x_pos[this.options.viewMode + "Lower"],
9889
+ lower_y: base_pos.lower_y,
9890
+ date: date,
9891
+ };
9892
+ };
9893
+ Gantt.prototype.make_bars = function () {
9894
+ var _this = this;
9895
+ this.bars = this.tasks.map(function (task) {
9896
+ var bar = new Bar(_this, task);
9897
+ _this.layers.bar.appendChild(bar.group);
9898
+ return bar;
9899
+ });
9900
+ };
9901
+ Gantt.prototype.make_arrows = function () {
9902
+ var e_7, _a;
9903
+ var _this = this;
9904
+ this.arrows = [];
9905
+ var _loop_1 = function (task) {
9906
+ var arrows = [];
9907
+ arrows = task.dependencies
9908
+ .map(function (task_id) {
9909
+ var dependency = _this.get_task(task_id);
9910
+ if (!dependency)
9911
+ return;
9912
+ var arrow = new Arrow(_this, _this.bars[dependency._index], // from_task
9913
+ _this.bars[task._index] // to_task
9914
+ );
9915
+ _this.layers.arrow.appendChild(arrow.element);
9916
+ return arrow;
9917
+ })
9918
+ .filter(Boolean); // filter falsy values
9919
+ this_1.arrows = this_1.arrows.concat(arrows);
9920
+ };
9921
+ var this_1 = this;
9922
+ try {
9923
+ for (var _b = __values(this.tasks), _c = _b.next(); !_c.done; _c = _b.next()) {
9924
+ var task = _c.value;
9925
+ _loop_1(task);
9926
+ }
9927
+ }
9928
+ catch (e_7_1) { e_7 = { error: e_7_1 }; }
9929
+ finally {
9930
+ try {
9931
+ if (_c && !_c.done && (_a = _b.return)) _a.call(_b);
9932
+ }
9933
+ finally { if (e_7) throw e_7.error; }
9934
+ }
9935
+ };
9936
+ Gantt.prototype.map_arrows_on_bars = function () {
9937
+ var e_8, _a;
9938
+ var _loop_2 = function (bar) {
9939
+ bar.arrows = this_2.arrows.filter(function (arrow) {
9940
+ return (arrow.fromTask.task.id === bar.task.id ||
9941
+ arrow.toTask.task.id === bar.task.id);
9942
+ });
9943
+ };
9944
+ var this_2 = this;
9945
+ try {
9946
+ for (var _b = __values(this.bars), _c = _b.next(); !_c.done; _c = _b.next()) {
9947
+ var bar = _c.value;
9948
+ _loop_2(bar);
9949
+ }
9950
+ }
9951
+ catch (e_8_1) { e_8 = { error: e_8_1 }; }
9952
+ finally {
9953
+ try {
9954
+ if (_c && !_c.done && (_a = _b.return)) _a.call(_b);
9955
+ }
9956
+ finally { if (e_8) throw e_8.error; }
9957
+ }
9958
+ };
9959
+ Gantt.prototype.set_width = function () {
9960
+ var cur_width = this.$svg.getBoundingClientRect().width;
9961
+ var actual_width = this.$svg
9962
+ .querySelector(".grid .grid-row")
9963
+ .getAttribute("width");
9964
+ if (cur_width < actual_width) {
9965
+ this.$svg.setAttribute("width", actual_width);
9966
+ }
9967
+ };
9968
+ Gantt.prototype.set_scroll_position = function () {
9969
+ var parent_element = this.$svg.parentElement;
9970
+ if (!parent_element)
9971
+ return;
9972
+ var hours_before_first_task = DateUtils.diff(this.get_oldest_starting_date(), this.minDate, "hour");
9973
+ var scroll_pos = (hours_before_first_task / this.options.step) *
9974
+ this.options.columnWidth -
9975
+ this.options.columnWidth;
9976
+ parent_element.scrollLeft = scroll_pos;
9977
+ };
9978
+ Gantt.prototype.bind_grid_click = function () {
9979
+ var _this = this;
9980
+ $.on(this.$svg, this.options.popupTrigger, ".grid-row, .grid-header", function () {
9981
+ _this.unselect_all();
9982
+ _this.hide_popup();
9983
+ });
9984
+ };
9985
+ Gantt.prototype.bind_bar_events = function () {
9986
+ var _this = this;
9987
+ var is_dragging = false;
9988
+ var x_on_start = 0;
9989
+ var is_resizing_left = false;
9990
+ var is_resizing_right = false;
9991
+ var parent_bar_id = null;
9992
+ var bars = [];
9993
+ this.bar_being_dragged = null;
9994
+ function action_in_progress() {
9995
+ return is_dragging || is_resizing_left || is_resizing_right;
9996
+ }
9997
+ $.on(this.$svg, "mousedown", ".bar-wrapper, .handle", function (e, element) {
9998
+ var bar_wrapper = $.closest(".bar-wrapper", element);
9999
+ if (element.classList.contains("left")) {
10000
+ is_resizing_left = true;
10001
+ }
10002
+ else if (element.classList.contains("right")) {
10003
+ is_resizing_right = true;
10004
+ }
10005
+ else if (element.classList.contains("bar-wrapper")) {
10006
+ is_dragging = true;
10007
+ }
10008
+ bar_wrapper.classList.add("active");
10009
+ x_on_start = e.offsetX;
10010
+ parent_bar_id = bar_wrapper.getAttribute("data-id");
10011
+ var ids = __spread([
10012
+ parent_bar_id
10013
+ ], _this.get_all_dependent_tasks(parent_bar_id));
10014
+ bars = ids.map(function (id) { return _this.get_bar(id); });
10015
+ _this.bar_being_dragged = parent_bar_id;
10016
+ bars.forEach(function (bar) {
10017
+ var $bar = bar.element;
10018
+ $bar.ox = $bar.getX();
10019
+ $bar.oy = $bar.getY();
10020
+ $bar.owidth = $bar.getWidth();
10021
+ $bar.finaldx = 0;
10022
+ });
10023
+ });
10024
+ $.on(this.$svg, "mousemove", function (e) {
10025
+ if (!action_in_progress()) {
10026
+ return;
10027
+ }
10028
+ var dx = e.offsetX - x_on_start;
10029
+ bars.forEach(function (bar) {
10030
+ var $bar = bar.element;
10031
+ $bar.finaldx = _this.get_snap_position(dx);
10032
+ _this.hide_popup();
10033
+ if (is_resizing_left) {
10034
+ if (parent_bar_id === bar.task.id) {
10035
+ bar.updateBarPosition({
10036
+ x: $bar.ox + $bar.finaldx,
10037
+ width: $bar.owidth - $bar.finaldx,
10038
+ });
10039
+ }
10040
+ else {
10041
+ bar.updateBarPosition({
10042
+ x: $bar.ox + $bar.finaldx,
10043
+ });
10044
+ }
10045
+ }
10046
+ else if (is_resizing_right) {
10047
+ if (parent_bar_id === bar.task.id) {
10048
+ bar.updateBarPosition({
10049
+ width: $bar.owidth + $bar.finaldx,
10050
+ });
10051
+ }
10052
+ }
10053
+ else if (is_dragging) {
10054
+ bar.updateBarPosition({ x: $bar.ox + $bar.finaldx });
10055
+ }
10056
+ });
10057
+ }, null);
10058
+ document.addEventListener("mouseup", function (e) {
10059
+ if (is_dragging || is_resizing_left || is_resizing_right) {
10060
+ bars.forEach(function (bar) { return bar.group.classList.remove("active"); });
10061
+ }
10062
+ is_dragging = false;
10063
+ is_resizing_left = false;
10064
+ is_resizing_right = false;
10065
+ });
10066
+ $.on(this.$svg, "mouseup", function (e) {
10067
+ _this.bar_being_dragged = null;
10068
+ bars.forEach(function (bar) {
10069
+ var $bar = bar.element;
10070
+ if (!$bar.finaldx)
10071
+ return;
10072
+ bar.dateChanged();
10073
+ bar.setActionCompleted();
10074
+ });
10075
+ }, null);
10076
+ };
10077
+ Gantt.prototype.get_all_dependent_tasks = function (task_id) {
10078
+ var _this = this;
10079
+ var out = [];
10080
+ var to_process = [task_id];
10081
+ while (to_process.length) {
10082
+ var deps = to_process.reduce(function (acc, curr) {
10083
+ acc = acc.concat(_this.dependency_map[curr]);
10084
+ return acc;
10085
+ }, []);
10086
+ out = out.concat(deps);
10087
+ to_process = deps.filter(function (d) { return !to_process.includes(d); });
10088
+ }
10089
+ return out.filter(Boolean);
10090
+ };
10091
+ Gantt.prototype.get_snap_position = function (dx) {
10092
+ var odx = dx, rem, position;
10093
+ if (this.view_is(ViewMode.Hour)) {
10094
+ rem = dx % (this.options.columnWidth / 6);
10095
+ position = odx - rem + (rem < this.options.columnWidth / 12 ? 0 : this.options.columnWidth / 6);
10096
+ }
10097
+ else if (this.view_is(ViewMode.Week)) {
10098
+ rem = dx % (this.options.columnWidth / 7);
10099
+ position = odx - rem + (rem < this.options.columnWidth / 14 ? 0 : this.options.columnWidth / 7);
10100
+ }
10101
+ else if (this.view_is(ViewMode.Month)) {
10102
+ rem = dx % (this.options.columnWidth / 30);
10103
+ position = odx - rem + (rem < this.options.columnWidth / 60 ? 0 : this.options.columnWidth / 30);
10104
+ }
10105
+ else {
10106
+ rem = dx % this.options.columnWidth;
10107
+ position = odx - rem + (rem < this.options.columnWidth / 2 ? 0 : this.options.columnWidth);
10108
+ }
10109
+ return position;
10110
+ };
10111
+ Gantt.prototype.unselect_all = function () {
10112
+ __spread(this.$svg.querySelectorAll(".bar-wrapper")).forEach(function (el) {
10113
+ el.classList.remove("active");
10114
+ });
10115
+ };
10116
+ Gantt.prototype.view_is = function (modes) {
10117
+ var _this = this;
10118
+ if (Array.isArray(modes)) {
10119
+ return modes.some(function (mode) { return _this.options.viewMode === mode; });
10120
+ }
10121
+ return this.options.viewMode === modes;
10122
+ };
10123
+ Gantt.prototype.get_task = function (id) {
10124
+ return this.tasks.find(function (task) {
10125
+ return task.id === id;
10126
+ });
10127
+ };
10128
+ Gantt.prototype.get_bar = function (id) {
10129
+ return this.bars.find(function (bar) {
10130
+ return bar.task.id === id;
10131
+ });
10132
+ };
10133
+ Gantt.prototype.show_popup = function (options) {
10134
+ if (!this.popup) {
10135
+ this.popup = new Popup(this.popup_wrapper, this.options.customPopupHtml);
10136
+ }
10137
+ this.popup.show(options);
10138
+ };
10139
+ Gantt.prototype.hide_popup = function () {
10140
+ this.popup && this.popup.hide();
10141
+ };
10142
+ Gantt.prototype.trigger_event = function (event, args) {
10143
+ if (this.options[event]) {
10144
+ this.options[event].apply(null, args);
10145
+ }
10146
+ };
10147
+ Gantt.prototype.get_oldest_starting_date = function () {
10148
+ return this.tasks
10149
+ .map(function (task) { return task._start; })
10150
+ .reduce(function (prev_date, cur_date) {
10151
+ return cur_date <= prev_date ? cur_date : prev_date;
10152
+ });
10153
+ };
10154
+ Gantt.prototype.clear = function () {
10155
+ this.$svg.innerHTML = '';
10156
+ };
10157
+ return Gantt;
10158
+ }());
10159
+ function generate_id(task) {
10160
+ return task.name + "_" + Math.random().toString(36).slice(2, 12);
10161
+ }
10162
+
10163
+ var GanttComponent = /** @class */ (function () {
10164
+ function GanttComponent() {
10165
+ this.multipleTaskPerLine = false;
10166
+ this.showSideTable = true;
10167
+ this.viewMode = ViewMode.Day;
10168
+ this.taskClicked = new EventEmitter();
10169
+ this.taskDateChanged = new EventEmitter();
10170
+ this.viewChanged = new EventEmitter();
10171
+ }
10172
+ GanttComponent.prototype.ngOnInit = function () {
10173
+ this._validateViewMode();
10174
+ };
10175
+ GanttComponent.prototype.ngAfterViewInit = function () {
10176
+ var _this = this;
10177
+ this._gantt = new Gantt("#gantt", this._filterTask(this.tasks), {
10178
+ viewMode: this.viewMode,
10179
+ marginBeforeStart: this.marginBeforeStart,
10180
+ marginAfterEnd: this.marginAfterEnd,
10181
+ language: "pt-BR",
10182
+ onClick: function (task) { return _this.taskClicked.emit(task); },
10183
+ onDateChange: function (task, start, end) { return _this.taskDateChanged.emit({ task: task, start: start, end: end }); },
10184
+ onViewChange: function (viewMode) { return _this.viewChanged.emit(viewMode); },
10185
+ });
10186
+ };
10187
+ GanttComponent.prototype.ngOnChanges = function (changes) {
10188
+ if (!this._gantt) {
10189
+ return;
10190
+ }
10191
+ if (changes.viewMode) {
10192
+ this._gantt.options.viewMode = changes.viewMode.currentValue;
10193
+ this._gantt.change_view_mode();
10194
+ }
10195
+ if (changes.tasks) {
10196
+ this._gantt.refresh(this._filterTask(changes.tasks.currentValue));
10197
+ }
10198
+ };
10199
+ GanttComponent.prototype._filterTask = function (tasksGroups) {
10200
+ var tasks = [];
10201
+ if (this.multipleTaskPerLine) {
10202
+ tasksGroups.forEach(function (group, index) {
10203
+ tasks.push.apply(tasks, __spread(group.tasks.map(function (task) {
10204
+ return __assign(__assign({}, task), { _row_id: index });
10205
+ })));
10206
+ }, []);
10207
+ }
10208
+ else {
10209
+ var i_1 = 0;
10210
+ tasksGroups.forEach(function (group) {
10211
+ tasks.push.apply(tasks, __spread(group.tasks.map(function (task) {
10212
+ return __assign(__assign({}, task), { _row_id: i_1++ });
10213
+ })));
10214
+ }, []);
10215
+ }
10216
+ return tasks;
10217
+ };
10218
+ GanttComponent.prototype._validateViewMode = function () {
10219
+ if (![
10220
+ ViewMode.Hour,
10221
+ ViewMode.QuarterDay,
10222
+ ViewMode.HalfDay,
10223
+ ViewMode.Day,
10224
+ ViewMode.Week,
10225
+ ViewMode.Month,
10226
+ ViewMode.Year,
10227
+ ].includes(this.viewMode)) {
10228
+ throw new Error("Invalid gantt view mode");
10229
+ }
10230
+ };
10231
+ __decorate([
10232
+ Input()
10233
+ ], GanttComponent.prototype, "columnTitle", void 0);
10234
+ __decorate([
10235
+ Input()
10236
+ ], GanttComponent.prototype, "multipleTaskPerLine", void 0);
10237
+ __decorate([
10238
+ Input()
10239
+ ], GanttComponent.prototype, "showSideTable", void 0);
10240
+ __decorate([
10241
+ Input()
10242
+ ], GanttComponent.prototype, "viewMode", void 0);
10243
+ __decorate([
10244
+ Input()
10245
+ ], GanttComponent.prototype, "tasks", void 0);
10246
+ __decorate([
10247
+ Input()
10248
+ ], GanttComponent.prototype, "marginBeforeStart", void 0);
10249
+ __decorate([
10250
+ Input()
10251
+ ], GanttComponent.prototype, "marginAfterEnd", void 0);
10252
+ __decorate([
10253
+ Output()
10254
+ ], GanttComponent.prototype, "taskClicked", void 0);
10255
+ __decorate([
10256
+ Output()
10257
+ ], GanttComponent.prototype, "taskDateChanged", void 0);
10258
+ __decorate([
10259
+ Output()
10260
+ ], GanttComponent.prototype, "viewChanged", void 0);
10261
+ GanttComponent = __decorate([
10262
+ Component({
10263
+ selector: "s-gantt",
10264
+ template: "<div class=\"outer\">\n <gantt-side-table\n *ngIf=\"showSideTable\"\n [tasks]=\"tasks\"\n [columnTitle]=\"columnTitle\"\n [multipleTaskPerLine]=\"multipleTaskPerLine\">\n </gantt-side-table>\n <svg id=\"gantt\"></svg>\n</div>",
10265
+ encapsulation: ViewEncapsulation.None,
10266
+ styles: [".outer{display:-ms-flexbox;display:flex;-ms-flex-pack:center;justify-content:center;-ms-flex-align:start;align-items:flex-start;-ms-flex-line-pack:center;align-content:center;-ms-flex-wrap:nowrap;flex-wrap:nowrap;-ms-flex-direction:row;flex-direction:row}", ".gantt{border:1px solid #e0e0e0}.gantt .weekend-highlight{fill:#b8c2cc;opacity:.5;stroke:#ebeff2;stroke-width:1}.gantt .grid-background{fill:none}.gantt .grid-header,.gantt .grid-row{fill:#fff}.gantt .grid-row:nth-child(even){fill:#f5f5f5}.gantt .row-line{stroke:#ebeff2}.gantt .tick{stroke:#e0e0e0;stroke-width:.2}.gantt .tick.thick{stroke-width:.4}.gantt .today-highlight{fill:#ffe979;opacity:.5}.gantt .arrow{fill:none;stroke:#666;stroke-width:1.4}.gantt .bar{opacity:.8;stroke:#8d99a6;stroke-width:0;transition:stroke-width .3s;-webkit-user-select:none;-ms-user-select:none;user-select:none}.gantt .bar-invalid{fill:transparent;stroke:#8d99a6;stroke-dasharray:5;stroke-width:1}.gantt .bar-invalid~.bar-label{fill:#555}.gantt .bar-label{fill:#fff;text-anchor:middle;font-size:12px;font-weight:lighter}.gantt .bar-label.big{fill:#555;text-anchor:start}.gantt .bar-wrapper{cursor:pointer;outline:0}.gantt .bar-wrapper.active .bar,.gantt .bar-wrapper:hover .bar{opacity:1}.gantt .bar-wrapper.active .bar{stroke:#212533;stroke-width:2}.gantt .lower-text,.gantt .upper-text{font-size:12px;text-anchor:middle}.gantt .upper-text{fill:#555}.gantt .lower-text{fill:#333}.gantt .hide{display:none}.gantt-container{border-left:1px solid #e0e0e0;font-size:12px;overflow:auto;position:relative}.gantt-container .title-1{fill:#999;font-size:12px;font-weight:400;line-height:150%;text-anchor:middle}.gantt-container .title-2{fill:#333;font-size:14px;font-weight:400;line-height:150%;text-anchor:middle}.gantt-container .popup-wrapper{left:0;position:absolute;top:0}.gantt-container .popup-wrapper .popup{background:#0e1119;border-radius:2px;color:#fff;padding:8px;font-family:\"Open Sans\" sans-serif;line-height:150%;font-weight:400}.gantt-container .popup-wrapper .popup .wrp-title{border-bottom:1px solid #525966;padding-bottom:10px}.gantt-container .popup-wrapper .popup .wrp-title .title{font-size:14px}.gantt-container .popup-wrapper .popup .wrp-subtitle{color:#dfe2e5;padding-top:10px}.gantt-container .popup-wrapper .popup .wrp-subtitle .icon{margin-right:8px}.gantt-container .popup-wrapper .popup .wrp-subtitle .subtitle{font-size:12px}.gantt-container .popup-wrapper .popup .pointer{border:6px solid transparent;border-top-color:#0e1119;height:6px;margin-left:-4px;position:absolute}"]
10267
+ })
10268
+ ], GanttComponent);
10269
+ return GanttComponent;
10270
+ }());
10271
+
10272
+ var SideTableComponent = /** @class */ (function () {
10273
+ function SideTableComponent() {
10274
+ this.ROW_HEIGHT = 44;
10275
+ this.multipleTaskPerLine = false;
10276
+ }
10277
+ __decorate([
10278
+ Input()
10279
+ ], SideTableComponent.prototype, "columnTitle", void 0);
10280
+ __decorate([
10281
+ Input()
10282
+ ], SideTableComponent.prototype, "tasks", void 0);
10283
+ __decorate([
10284
+ Input()
10285
+ ], SideTableComponent.prototype, "multipleTaskPerLine", void 0);
10286
+ SideTableComponent = __decorate([
10287
+ Component({
10288
+ selector: 'gantt-side-table',
10289
+ template: "<div class=\"side-table\">\n <div class=\"column-title\">\n <span>{{ columnTitle }}</span>\n </div>\n <div class=\"tasks\">\n <div *ngFor=\"let task of tasks; let i = index\" class=\"task\" [ngStyle]=\"{'height.px': multipleTaskPerLine\n ? ROW_HEIGHT\n : ROW_HEIGHT * task.tasks.length}\">\n <div class=\"title\">\n {{ task.title }}\n </div>\n <div class=\"subtitle\">\n {{ task.subtitle }}\n </div>\n </div>\n </div>\n</div>",
10290
+ styles: [".side-table{background:#fff;height:100%;min-width:175px}.side-table .column-title{height:106px;border:1px solid #e0e0e0;box-sizing:border-box;display:-ms-flexbox;display:flex;-ms-flex-align:end;align-items:flex-end;-ms-flex-pack:center;justify-content:center;padding:8px}.side-table .column-title span{font-family:\"Open Sans\" sans-serif;font-size:14px;font-weight:700;line-height:150%}.side-table .task{-ms-flex-align:center;align-items:center;background-color:#fff;border:1px solid #e0e0e0;display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column;font-family:\"Open Sans\" sans-serif;font-weight:400;-ms-flex-pack:center;justify-content:center;line-height:150%;padding:5px}.side-table .task .title{color:#333;font-size:14px}.side-table .task .subtitle{color:#999;font-size:12px}"]
10291
+ })
10292
+ ], SideTableComponent);
10293
+ return SideTableComponent;
10294
+ }());
10295
+
10296
+ var GanttModule = /** @class */ (function () {
10297
+ function GanttModule() {
10298
+ }
10299
+ GanttModule = __decorate([
10300
+ NgModule({
10301
+ imports: [CommonModule],
10302
+ declarations: [
10303
+ GanttComponent,
10304
+ SideTableComponent,
10305
+ ],
10306
+ exports: [GanttComponent],
10307
+ })
10308
+ ], GanttModule);
10309
+ return GanttModule;
10310
+ }());
10311
+
8608
10312
  var HeaderComponent = /** @class */ (function () {
8609
10313
  function HeaderComponent() {
8610
10314
  }
@@ -11582,7 +13286,7 @@ function getCompletionResults(context) {
11582
13286
  startCompletionResultsSearch(context);
11583
13287
  }
11584
13288
  var cancelLastCompletionSearch = function () { };
11585
- var ɵ0 = cancelLastCompletionSearch;
13289
+ var ɵ0$1 = cancelLastCompletionSearch;
11586
13290
  var codeMirrorViewElement;
11587
13291
  /*
11588
13292
  * Starts a new completionResults's async search.
@@ -12552,6 +14256,102 @@ var SplitButtonModule = /** @class */ (function () {
12552
14256
  return SplitButtonModule;
12553
14257
  }());
12554
14258
 
14259
+ var SwitchComponent = /** @class */ (function () {
14260
+ function SwitchComponent() {
14261
+ this.readonly = false;
14262
+ this.disabled = false;
14263
+ this.valueChanged = new EventEmitter();
14264
+ this.value = false;
14265
+ }
14266
+ SwitchComponent_1 = SwitchComponent;
14267
+ SwitchComponent.prototype.onFocusIn = function () {
14268
+ var switchElement = this.switchRef.nativeElement;
14269
+ switchElement.classList.add("switch--focus");
14270
+ };
14271
+ SwitchComponent.prototype.onFocusOut = function () {
14272
+ var switchElement = this.switchRef.nativeElement;
14273
+ switchElement.classList.remove("switch--focus");
14274
+ };
14275
+ SwitchComponent.prototype.writeValue = function (value) {
14276
+ if (!this.disabled) {
14277
+ this.value = value;
14278
+ }
14279
+ };
14280
+ SwitchComponent.prototype.registerOnChange = function (onChange) {
14281
+ this._onChange = onChange;
14282
+ };
14283
+ SwitchComponent.prototype.registerOnTouched = function (onTouched) {
14284
+ this._onTouched = onTouched;
14285
+ };
14286
+ SwitchComponent.prototype.setDisabledState = function (disabled) {
14287
+ this.disabled = disabled;
14288
+ };
14289
+ SwitchComponent.prototype.toggleCheck = function () {
14290
+ this.value = !this.value;
14291
+ this.valueChanged.emit(this.value);
14292
+ if (this._onChange) {
14293
+ this._onChange(this.value);
14294
+ }
14295
+ };
14296
+ var SwitchComponent_1;
14297
+ __decorate([
14298
+ Input()
14299
+ ], SwitchComponent.prototype, "readonly", void 0);
14300
+ __decorate([
14301
+ Input()
14302
+ ], SwitchComponent.prototype, "trueLabel", void 0);
14303
+ __decorate([
14304
+ Input()
14305
+ ], SwitchComponent.prototype, "falseLabel", void 0);
14306
+ __decorate([
14307
+ Input()
14308
+ ], SwitchComponent.prototype, "inputId", void 0);
14309
+ __decorate([
14310
+ Input()
14311
+ ], SwitchComponent.prototype, "disabled", void 0);
14312
+ __decorate([
14313
+ Output()
14314
+ ], SwitchComponent.prototype, "valueChanged", void 0);
14315
+ __decorate([
14316
+ Input()
14317
+ ], SwitchComponent.prototype, "value", void 0);
14318
+ __decorate([
14319
+ ViewChild("switch", { static: true })
14320
+ ], SwitchComponent.prototype, "switchRef", void 0);
14321
+ __decorate([
14322
+ HostListener('focusin')
14323
+ ], SwitchComponent.prototype, "onFocusIn", null);
14324
+ __decorate([
14325
+ HostListener('focusout')
14326
+ ], SwitchComponent.prototype, "onFocusOut", null);
14327
+ SwitchComponent = SwitchComponent_1 = __decorate([
14328
+ Component({
14329
+ selector: 's-switch',
14330
+ template: "<div #switch class=\"switch\" [ngClass]=\"{ 'switch--disabled': disabled }\">\n <label class=\"switch-toggle\">\n <input\n #input\n [id]=\"inputId\"\n type=\"checkbox\"\n [checked]=\"value\"\n [disabled]=\"readonly || disabled\"\n (change)=\"toggleCheck()\">\n <span class=\"slider\"></span>\n </label>\n <span class=\"label\">\n {{ value ? trueLabel : falseLabel }}\n </span>\n</div>",
14331
+ providers: [{
14332
+ provide: NG_VALUE_ACCESSOR,
14333
+ useExisting: forwardRef(function () { return SwitchComponent_1; }),
14334
+ multi: true,
14335
+ }],
14336
+ styles: [".switch{display:-ms-inline-flexbox;display:inline-flex}.switch .switch-toggle{display:inline-block;height:24px;position:relative;width:40px}.switch .switch-toggle input{height:0;opacity:0;width:0}.switch .switch-toggle input:checked+.slider{background-color:#428bca;border-radius:15px}.switch .switch-toggle input:checked+.slider:before{transform:translateX(16px)}.switch .switch-toggle .slider{background-color:#a5a5b2;border-radius:15px;bottom:0;cursor:pointer;left:0;position:absolute;right:0;top:0;transition:.4s}.switch .switch-toggle .slider:before{background-color:#fff;border-radius:50%;bottom:4px;content:\"\";height:16px;left:4px;position:absolute;transition:.4s;width:16px}.switch .label{color:#212533;font-family:\"Open Sans\" sans-serif;font-size:.875rem;font-weight:400;line-height:150%;margin-left:12px}.switch--disabled{opacity:.5}.switch--focus .switch-toggle .slider{box-shadow:0 0 0 2px #428BCA80}"]
14337
+ })
14338
+ ], SwitchComponent);
14339
+ return SwitchComponent;
14340
+ }());
14341
+
14342
+ var SwitchModule = /** @class */ (function () {
14343
+ function SwitchModule() {
14344
+ }
14345
+ SwitchModule = __decorate([
14346
+ NgModule({
14347
+ imports: [CommonModule],
14348
+ declarations: [SwitchComponent],
14349
+ exports: [SwitchComponent],
14350
+ })
14351
+ ], SwitchModule);
14352
+ return SwitchModule;
14353
+ }());
14354
+
12555
14355
  var PanelComponent = /** @class */ (function () {
12556
14356
  function PanelComponent() {
12557
14357
  this.toggleable = true;
@@ -12849,5 +14649,5 @@ var fallback = {
12849
14649
  * Generated bundle index. Do not edit.
12850
14650
  */
12851
14651
 
12852
- export { AccordionComponent, AccordionModule, AccordionPanelComponent, AngularComponentsModule, AutocompleteField, BadgeColors, BadgeComponent, BadgeModule, BaseFieldComponent, BignumberField, BignumberInputDirective, BignumberInputModule, BooleanField, BooleanOptionsLabel, BreadcrumbComponent, BreadcrumbModule, Breakpoints, ButtonComponent, ButtonModule, ButtonPriority, ButtonSize, CalendarField, CalendarLocaleOptions, CalendarMaskDirective, CalendarMaskModule, ChipsField, CodeEditorModule, CollapseLinkComponent, CollapseLinkModule, ControlErrorsComponent, ControlErrorsModule, CountryPhonePickerComponent, CountryPhonePickerModule, CurrencyField, CustomFieldsComponent, CustomFieldsModule, CustomFieldsService, DEFAULT_CALENDAR_LOCALE_OPTIONS, DEFAULT_LOCALE_OPTIONS, DEFAULT_NUMBER_LOCALE_OPTIONS, DebounceUtils, DoubleClickDirective, DynamicConfig, DynamicFormComponent, DynamicFormModule, DynamicType, EditableOverlayDirective, EditableOverlayModule, EmptyStateComponent, EmptyStateModule, EnumBadgeColors, EnumColumnFieldType, EnumSeverity, ExportUtils, Field, FieldType, Fieldset, FileUploadComponent, FileUploadModule, FileValidation, FormField, GlobalSearchComponent, GlobalSearchDropdownItemComponent, GlobalSearchModule, GlobalSearchSizeEnum, HostProjectConfigsInjectionToken, ImageCropperComponent, ImageCropperModule, ImageCropperService, InfoSignDirective, InfoSignModule, Languages, LoadingStateComponent, LoadingStateDirective, LoadingStateModule, LocaleModule, LocaleOptions, LocaleService, LocalizedCurrencyPipe, LocalizedCurrencyPipeOptions, LocalizedDateImpurePipe, LocalizedDatePipe, LocalizedNumberInputDirective, LocalizedNumberInputModule, LocalizedNumberPipe, LocalizedTimeImpurePipe, LocalizedTimePipe, LongPressDirective, LookupComponent, LookupField, MaskFormatterModule, MaskFormatterPipe, MouseEventsModule, NavigationDirective, NumberAlignmentOption, NumberField, NumberInputDirective, NumberInputModule, NumberLocaleOptions, ObjectCardComponent, ObjectCardFieldComponent, ObjectCardMainComponent, ObjectCardModule, Option, Ordination, PanelComponent, PanelModule, PasswordField, PasswordStrengthComponent, PasswordStrengthDirective, PasswordStrengthModule, PasswordStrengthPositions, PasswordStrengths, ProductHeaderComponent, ProductHeaderModule, ProfilePicturePickerComponent, ProfilePicturePickerModule, ProgressBarColors, ProgressBarComponent, ProgressBarModule, RadioButtonField, RatingScaleComponent, RatingScaleModule, RationButtonOption, RowTogllerDirective, Section, SelectField, SelectOption, SidebarComponent, SidebarModule, SlidePanelComponent, SlidePanelModule, SplitButtonComponent, SplitButtonModule, SplitButtonType, StatsCardComponent, StatsCardModule, StepState, StepsComponent, StepsModule, Structure, TableFrozenPositionDirective, TableHeaderCheckboxComponent, TableHeaderCheckboxModule, TableModule, TaxCalculationLanguageConfigs, TextAreaField, TextField, Themes, ThumbnailComponent, ThumbnailModule, ThumbnailSize, TileComponent, TileModule, TimelineComponent, TimelineItem, TimelineItemSeverity, TimelineItemSize, TimelineModule, TokenListComponent, TokenListModule, TooltipModule, TooltipPosition, ValidateErrors, WorkspaceSwitchComponent, WorkspaceSwitchModule, countries, fallback, TooltipComponent as ɵa, TooltipDirective as ɵb, SelectFieldComponent as ɵba, TextAreaFieldComponent as ɵbb, TextFieldComponent as ɵbc, BooleanSwitchFieldComponent as ɵbd, PasswordFieldComponent as ɵbe, SliderFieldComponent as ɵbf, DecimalField as ɵbh, StructureModule as ɵbi, HeaderComponent as ɵbj, FooterComponent as ɵbk, NumberLocaleOptions as ɵbl, ThumbnailService as ɵbm, BorderButtonModule as ɵbn, BorderButtonComponent as ɵbo, TimelineItemModule as ɵbp, TimelineIconItemComponent as ɵbq, HorizontalTimelineModule as ɵbr, HorizontalTimelineComponent as ɵbs, VerticalTimelineModule as ɵbt, VerticalTimelineComponent as ɵbu, RangeLineComponent as ɵbv, CollapseOptionComponent as ɵbw, CollapsedItemsComponent as ɵbx, VerticalItemsComponent as ɵby, InfiniteScrollModule as ɵbz, CountryPhonePickerService as ɵc, InfiniteScrollDirective as ɵca, CustomTranslationsModule as ɵcb, CodeEditorComponent as ɵcc, CoreFacade as ɵcd, CodeMirror6Core as ɵce, LocalizedCurrencyImpurePipe as ɵd, LocalizedBignumberPipe as ɵe, LocalizedBignumberImpurePipe as ɵf, EmptyStateGoBackComponent as ɵg, FileUploadService as ɵh, InfoSignComponent as ɵi, TableColumnsComponent as ɵj, TablePagingComponent as ɵk, AutocompleteFieldComponent as ɵl, BooleanFieldComponent as ɵm, CalendarFieldComponent as ɵn, ChipsFieldComponent as ɵo, CurrencyFieldComponent as ɵp, DynamicFieldComponent as ɵq, DynamicFormDirective as ɵr, FieldsetComponent as ɵs, FileUploadComponent$1 as ɵt, LookupFieldComponent as ɵu, NumberFieldComponent as ɵv, BignumberFieldComponent as ɵw, RadioButtonComponent as ɵx, RowComponent as ɵy, SectionComponent as ɵz };
14652
+ export { AccordionComponent, AccordionModule, AccordionPanelComponent, AngularComponentsModule, AutocompleteField, BadgeColors, BadgeComponent, BadgeModule, BaseFieldComponent, BignumberField, BignumberInputDirective, BignumberInputModule, BooleanField, BooleanOptionsLabel, BreadcrumbComponent, BreadcrumbModule, Breakpoints, ButtonComponent, ButtonModule, ButtonPriority, ButtonSize, CalendarField, CalendarLocaleOptions, CalendarMaskDirective, CalendarMaskModule, ChipsField, CodeEditorModule, CollapseLinkComponent, CollapseLinkModule, ControlErrorsComponent, ControlErrorsModule, CountryPhonePickerComponent, CountryPhonePickerModule, CurrencyField, CustomFieldsComponent, CustomFieldsModule, CustomFieldsService, DEFAULT_CALENDAR_LOCALE_OPTIONS, DEFAULT_LOCALE_OPTIONS, DEFAULT_NUMBER_LOCALE_OPTIONS, DebounceUtils, DoubleClickDirective, DynamicConfig, DynamicFormComponent, DynamicFormModule, DynamicType, EditableOverlayDirective, EditableOverlayModule, EmptyStateComponent, EmptyStateModule, EnumBadgeColors, EnumColumnFieldType, EnumSeverity, ExportUtils, Field, FieldType, Fieldset, FileUploadComponent, FileUploadModule, FileValidation, FormField, GanttComponent, GanttModule, GlobalSearchComponent, GlobalSearchDropdownItemComponent, GlobalSearchModule, GlobalSearchSizeEnum, HostProjectConfigsInjectionToken, ImageCropperComponent, ImageCropperModule, ImageCropperService, InfoSignDirective, InfoSignModule, Languages, LoadingStateComponent, LoadingStateDirective, LoadingStateModule, LocaleModule, LocaleOptions, LocaleService, LocalizedCurrencyPipe, LocalizedCurrencyPipeOptions, LocalizedDateImpurePipe, LocalizedDatePipe, LocalizedNumberInputDirective, LocalizedNumberInputModule, LocalizedNumberPipe, LocalizedTimeImpurePipe, LocalizedTimePipe, LongPressDirective, LookupComponent, LookupField, MaskFormatterModule, MaskFormatterPipe, MouseEventsModule, NavigationDirective, NumberAlignmentOption, NumberField, NumberInputDirective, NumberInputModule, NumberLocaleOptions, ObjectCardComponent, ObjectCardFieldComponent, ObjectCardMainComponent, ObjectCardModule, Option, Ordination, PanelComponent, PanelModule, PasswordField, PasswordStrengthComponent, PasswordStrengthDirective, PasswordStrengthModule, PasswordStrengthPositions, PasswordStrengths, ProductHeaderComponent, ProductHeaderModule, ProfilePicturePickerComponent, ProfilePicturePickerModule, ProgressBarColors, ProgressBarComponent, ProgressBarModule, RadioButtonField, RatingScaleComponent, RatingScaleModule, RationButtonOption, RowTogllerDirective, Section, SelectField, SelectOption, SidebarComponent, SidebarModule, SlidePanelComponent, SlidePanelModule, SplitButtonComponent, SplitButtonModule, SplitButtonType, StatsCardComponent, StatsCardModule, StepState, StepsComponent, StepsModule, Structure, SwitchComponent, SwitchModule, TableFrozenPositionDirective, TableHeaderCheckboxComponent, TableHeaderCheckboxModule, TableModule, TaxCalculationLanguageConfigs, TextAreaField, TextField, Themes, ThumbnailComponent, ThumbnailModule, ThumbnailSize, TileComponent, TileModule, TimelineComponent, TimelineItem, TimelineItemSeverity, TimelineItemSize, TimelineModule, TokenListComponent, TokenListModule, TooltipModule, TooltipPosition, ValidateErrors, ViewMode, WorkspaceSwitchComponent, WorkspaceSwitchModule, countries, fallback, TooltipComponent as ɵa, TooltipDirective as ɵb, SelectFieldComponent as ɵba, TextAreaFieldComponent as ɵbb, TextFieldComponent as ɵbc, BooleanSwitchFieldComponent as ɵbd, PasswordFieldComponent as ɵbe, SliderFieldComponent as ɵbf, DecimalField as ɵbh, SideTableComponent as ɵbi, StructureModule as ɵbj, HeaderComponent as ɵbk, FooterComponent as ɵbl, NumberLocaleOptions as ɵbm, ThumbnailService as ɵbn, BorderButtonModule as ɵbo, BorderButtonComponent as ɵbp, TimelineItemModule as ɵbq, TimelineIconItemComponent as ɵbr, HorizontalTimelineModule as ɵbs, HorizontalTimelineComponent as ɵbt, VerticalTimelineModule as ɵbu, VerticalTimelineComponent as ɵbv, RangeLineComponent as ɵbw, CollapseOptionComponent as ɵbx, CollapsedItemsComponent as ɵby, VerticalItemsComponent as ɵbz, CountryPhonePickerService as ɵc, InfiniteScrollModule as ɵca, InfiniteScrollDirective as ɵcb, CustomTranslationsModule as ɵcc, CodeEditorComponent as ɵcd, CoreFacade as ɵce, CodeMirror6Core as ɵcf, LocalizedCurrencyImpurePipe as ɵd, LocalizedBignumberPipe as ɵe, LocalizedBignumberImpurePipe as ɵf, EmptyStateGoBackComponent as ɵg, FileUploadService as ɵh, InfoSignComponent as ɵi, TableColumnsComponent as ɵj, TablePagingComponent as ɵk, AutocompleteFieldComponent as ɵl, BooleanFieldComponent as ɵm, CalendarFieldComponent as ɵn, ChipsFieldComponent as ɵo, CurrencyFieldComponent as ɵp, DynamicFieldComponent as ɵq, DynamicFormDirective as ɵr, FieldsetComponent as ɵs, FileUploadComponent$1 as ɵt, LookupFieldComponent as ɵu, NumberFieldComponent as ɵv, BignumberFieldComponent as ɵw, RadioButtonComponent as ɵx, RowComponent as ɵy, SectionComponent as ɵz };
12853
14653
  //# sourceMappingURL=seniorsistemas-angular-components.js.map