@worktile/gantt 19.0.7 → 19.0.8-next.1

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.
package/gantt-upper.d.ts CHANGED
@@ -1,15 +1,15 @@
1
- import { TemplateRef, EventEmitter, ElementRef, ChangeDetectorRef, NgZone, SimpleChanges, InjectionToken, OnInit, OnDestroy, OnChanges } from '@angular/core';
1
+ import { BooleanInput } from '@angular/cdk/coercion';
2
+ import { SelectionModel } from '@angular/cdk/collections';
3
+ import { ChangeDetectorRef, ElementRef, EventEmitter, InjectionToken, NgZone, OnChanges, OnDestroy, OnInit, SimpleChanges, TemplateRef } from '@angular/core';
2
4
  import { Subject } from 'rxjs';
3
- import { GanttItem, GanttGroup, GanttViewType, GanttLoadOnScrollEvent, GanttDragEvent, GanttGroupInternal, GanttItemInternal, GanttBarClickEvent, GanttLinkDragEvent, GanttToolbarOptions } from './class';
4
- import { GanttView, GanttViewOptions } from './views/view';
5
- import { Dictionary } from './utils/helpers';
5
+ import { GanttBarClickEvent, GanttDragEvent, GanttGroup, GanttGroupInternal, GanttItem, GanttItemInternal, GanttLinkDragEvent, GanttLoadOnScrollEvent, GanttToolbarOptions, GanttViewType } from './class';
6
+ import { GanttBaselineItem, GanttBaselineItemInternal } from './class/baseline';
7
+ import { GanttLinkOptions } from './class/link';
6
8
  import { GanttDragContainer } from './gantt-drag-container';
7
9
  import { GanttConfigService, GanttGlobalConfig, GanttStyleOptions } from './gantt.config';
8
- import { GanttLinkOptions } from './class/link';
9
- import { SelectionModel } from '@angular/cdk/collections';
10
- import { BooleanInput } from '@angular/cdk/coercion';
11
- import { GanttBaselineItem, GanttBaselineItemInternal } from './class/baseline';
12
10
  import { NgxGanttTableComponent } from './table/gantt-table.component';
11
+ import { Dictionary } from './utils/helpers';
12
+ import { GanttView, GanttViewOptions } from './views/view';
13
13
  import * as i0 from "@angular/core";
14
14
  export declare abstract class GanttUpper implements OnChanges, OnInit, OnDestroy {
15
15
  protected elementRef: ElementRef<HTMLElement>;
@@ -42,7 +42,7 @@ export declare abstract class GanttUpper implements OnChanges, OnInit, OnDestroy
42
42
  dragEnded: EventEmitter<GanttDragEvent<unknown>>;
43
43
  barClick: EventEmitter<GanttBarClickEvent<unknown>>;
44
44
  viewChange: EventEmitter<GanttView>;
45
- expandChange: EventEmitter<GanttItemInternal | GanttGroupInternal>;
45
+ expandChange: EventEmitter<GanttItemInternal | GanttGroupInternal | (GanttItemInternal | GanttGroupInternal)[]>;
46
46
  barTemplate: TemplateRef<any>;
47
47
  rangeTemplate: TemplateRef<any>;
48
48
  itemTemplate: TemplateRef<any>;
@@ -52,7 +52,6 @@ export declare abstract class GanttUpper implements OnChanges, OnInit, OnDestroy
52
52
  toolbarTemplate: TemplateRef<any>;
53
53
  configService: GanttConfigService;
54
54
  linkable: boolean;
55
- computeAllRefs: boolean;
56
55
  linkDragEnded: EventEmitter<GanttLinkDragEvent<unknown>>;
57
56
  view: GanttView;
58
57
  items: GanttItemInternal[];
@@ -74,7 +73,7 @@ export declare abstract class GanttUpper implements OnChanges, OnInit, OnDestroy
74
73
  config: GanttGlobalConfig);
75
74
  private createView;
76
75
  private setupGroups;
77
- private setupItems;
76
+ protected setupItems(): void;
78
77
  private setupBaselineItems;
79
78
  private setupExpandedState;
80
79
  private getViewDate;
@@ -1,7 +1,7 @@
1
1
  import { CdkVirtualScrollViewport, ViewportRuler } from '@angular/cdk/scrolling';
2
- import { AfterViewChecked, AfterViewInit, ChangeDetectorRef, ElementRef, EventEmitter, NgZone, OnChanges, OnInit, QueryList, SimpleChanges, TemplateRef } from '@angular/core';
2
+ import { AfterViewChecked, AfterViewInit, ChangeDetectorRef, ElementRef, EventEmitter, NgZone, OnChanges, OnInit, QueryList, TemplateRef } from '@angular/core';
3
3
  import { Observable } from 'rxjs';
4
- import { GanttGroupInternal, GanttItem, GanttItemInternal, GanttLineClickEvent, GanttLinkDragEvent, GanttSelectedEvent, GanttTableDragEndedEvent, GanttTableDragStartedEvent, GanttViewType, GanttVirtualScrolledIndexChangeEvent } from './class';
4
+ import { GanttGroupInternal, GanttItem, GanttItemInternal, GanttLineClickEvent, GanttLinkDragEvent, GanttSelectedEvent, GanttTableDragEndedEvent, GanttTableDragStartedEvent, GanttVirtualScrolledIndexChangeEvent } from './class';
5
5
  import { GanttUpper } from './gantt-upper';
6
6
  import { GanttGlobalConfig } from './gantt.config';
7
7
  import { NgxGanttRootComponent } from './root.component';
@@ -43,19 +43,18 @@ export declare class NgxGanttComponent extends GanttUpper implements OnInit, OnC
43
43
  private draggingItem;
44
44
  constructor(elementRef: ElementRef<HTMLElement>, cdr: ChangeDetectorRef, ngZone: NgZone, viewportRuler: ViewportRuler, config: GanttGlobalConfig);
45
45
  ngOnInit(): void;
46
- ngOnChanges(changes: SimpleChanges): void;
46
+ computeRefs(): void;
47
+ setupItems(): void;
47
48
  ngAfterViewInit(): void;
48
49
  ngAfterViewChecked(): void;
49
50
  private buildFlatItems;
50
51
  private afterExpand;
51
- private computeTempDataRefs;
52
52
  private appendDraggingItemToViewportItems;
53
53
  expandChildren(item: GanttItemInternal): void;
54
54
  selectItem(selectEvent: GanttSelectedEvent): void;
55
55
  scrollToToday(): void;
56
56
  scrollToDate(date: number | Date | GanttDate): void;
57
57
  scrolledIndexChange(index: number): void;
58
- changeView(type: GanttViewType): void;
59
58
  expandGroups(expanded: boolean): void;
60
59
  expandGroup(group: GanttGroupInternal): void;
61
60
  itemDragStarted(event: GanttTableDragStartedEvent): void;
package/gantt.config.d.ts CHANGED
@@ -16,7 +16,7 @@ export interface GanttDateFormat {
16
16
  export interface GanttDateOptions {
17
17
  /**
18
18
  * @deprecated dateOptions is deprecated, use i18n locale setting instead
19
- * http://gantt.ngnice.com/guides/configuration/i18n
19
+ * https://worktile.github.io/ngx-gantt/guides/configuration/i18n
20
20
  */
21
21
  locale?: Locale;
22
22
  timeZone?: string;
@@ -29,7 +29,7 @@ export interface GanttStyleOptions {
29
29
  }
30
30
  export interface GanttGlobalConfig {
31
31
  locale?: GanttI18nLocale | string;
32
- /** @deprecated dateFormat is deprecated, please configure through i18n. http://gantt.ngnice.com/guides/configuration/i18n */
32
+ /** @deprecated dateFormat is deprecated, please configure through i18n. https://worktile.github.io/ngx-gantt/guides/configuration/i18n */
33
33
  dateFormat?: GanttDateFormat;
34
34
  dateOptions?: GanttDateOptions;
35
35
  linkOptions?: GanttLinkOptions;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@worktile/gantt",
3
- "version": "19.0.7",
3
+ "version": "19.0.8-next.1",
4
4
  "schematics": "./schematics/collection.json",
5
5
  "author": "walkerkay001",
6
6
  "license": "MIT",
package/public-api.d.ts CHANGED
@@ -1,24 +1,24 @@
1
- export * from './gantt.module';
2
- export * from './gantt-upper';
3
- export * from './root.component';
4
- export * from './gantt.component';
5
- export * from './table/gantt-table.component';
6
- export * from './table/gantt-column.component';
1
+ export * from './class';
7
2
  export * from './components/bar/bar.component';
8
- export * from './components/range/range.component';
9
3
  export * from './components/baseline/baseline.component';
10
- export * from './components/toolbar/toolbar.component';
4
+ export * from './components/calendar/grid/calendar-grid.component';
5
+ export * from './components/calendar/header/calendar-header.component';
6
+ export * from './components/drag-backdrop/drag-backdrop.component';
11
7
  export * from './components/loader/loader.component';
12
- export * from './utils/date';
13
- export * from './class';
14
- export * from './views/view';
15
- export { GanttI18nLocaleConfig, GanttI18nLocale, GANTT_I18N_LOCALE_TOKEN, zhHansLocale, zhHantLocale, enUsLocale, jaJpLocale, deDeLocale, ruRuLocale } from './i18n';
16
- export { registerView } from './views/factory';
8
+ export * from './components/range/range.component';
9
+ export * from './components/scrollbar/scrollbar.component';
10
+ export * from './components/toolbar/toolbar.component';
17
11
  export * from './gantt-item-upper';
18
- export * from './gantt.pipe';
19
12
  export * from './gantt-print.service';
13
+ export * from './gantt-upper';
14
+ export * from './gantt.component';
20
15
  export * from './gantt.config';
21
- export * from './components/calendar/header/calendar-header.component';
22
- export * from './components/calendar/grid/calendar-grid.component';
23
- export * from './components/drag-backdrop/drag-backdrop.component';
24
- export * from './components/scrollbar/scrollbar.component';
16
+ export * from './gantt.module';
17
+ export * from './gantt.pipe';
18
+ export { deDeLocale, enUsLocale, GANTT_I18N_LOCALE_TOKEN, GanttI18nLocale, GanttI18nLocaleConfig, jaJpLocale, ruRuLocale, zhHansLocale, zhHantLocale } from './i18n';
19
+ export * from './root.component';
20
+ export * from './table/gantt-column.component';
21
+ export * from './table/gantt-table.component';
22
+ export * from './utils/date';
23
+ export { registerView } from './views/factory';
24
+ export * from './views/view';
package/views/day.d.ts CHANGED
@@ -9,7 +9,7 @@ export declare class GanttViewDay extends GanttView {
9
9
  viewStartOf(date: GanttDate): GanttDate;
10
10
  viewEndOf(date: GanttDate): GanttDate;
11
11
  getPrimaryWidth(): number;
12
- getDayOccupancyWidth(): number;
12
+ getDayOccupancyWidth(date: GanttDate): number;
13
13
  getPrimaryDatePoints(): GanttDatePoint[];
14
14
  getSecondaryDatePoints(): GanttDatePoint[];
15
15
  }
@@ -1,10 +1,10 @@
1
- import { GanttViewOptions, GanttViewDate, GanttView } from './view';
2
- import { GanttViewMonth } from './month';
3
1
  import { GanttViewType } from '../class/view-type';
4
- import { GanttViewQuarter } from './quarter';
5
2
  import { GanttViewDay } from './day';
3
+ import { GanttViewHour } from './hour';
4
+ import { GanttViewMonth } from './month';
5
+ import { GanttViewQuarter } from './quarter';
6
+ import { GanttView, GanttViewDate, GanttViewOptions } from './view';
6
7
  import { GanttViewWeek } from './week';
7
8
  import { GanttViewYear } from './year';
8
- import { GanttViewHour } from './hour';
9
9
  export declare function registerView<T extends typeof GanttView>(type: string, view: T): void;
10
- export declare function createViewFactory(type: GanttViewType, start: GanttViewDate, end: GanttViewDate, options?: GanttViewOptions): GanttViewMonth | GanttViewQuarter | GanttViewDay | GanttViewWeek | GanttViewYear | GanttViewHour;
10
+ export declare function createViewFactory(type: GanttViewType, start: GanttViewDate, end: GanttViewDate, options?: GanttViewOptions): GanttViewDay | GanttViewHour | GanttViewMonth | GanttViewQuarter | GanttViewWeek | GanttViewYear;
package/views/view.d.ts CHANGED
@@ -25,6 +25,10 @@ export interface GanttViewOptions {
25
25
  };
26
26
  datePrecisionUnit?: 'day' | 'hour' | 'minute';
27
27
  dragPreviewDateFormat?: string;
28
+ hoilday?: {
29
+ isHoliday: (GanttDate: any) => boolean;
30
+ hideHoliday: boolean;
31
+ };
28
32
  [key: string]: any;
29
33
  }
30
34
  export declare abstract class GanttView {
@@ -61,6 +65,7 @@ export declare abstract class GanttView {
61
65
  abstract getDayOccupancyWidth(date: GanttDate): number;
62
66
  abstract getPrimaryDatePoints(): GanttDatePoint[];
63
67
  abstract getSecondaryDatePoints(): GanttDatePoint[];
68
+ protected hideHoliday(date: GanttDate): boolean;
64
69
  startOfPrecision(date: GanttDate): GanttDate;
65
70
  endOfPrecision(date: GanttDate): GanttDate;
66
71
  differenceByPrecisionUnit(dateLeft: GanttDate, dateRight: GanttDate): number;