@colijnit/corecomponents_v12 255.1.11 → 255.1.13
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/bundles/colijnit-corecomponents_v12.umd.js +376 -17
- package/bundles/colijnit-corecomponents_v12.umd.js.map +1 -1
- package/colijnit-corecomponents_v12.metadata.json +1 -1
- package/esm2015/lib/components/calendar/calendar-template.component.js +6 -4
- package/esm2015/lib/components/hour-scheduling/components/hour-scheduling-test-object/hour-scheduling-test-object.component.js +2 -2
- package/esm2015/lib/components/hour-scheduling/hour-scheduling.component.js +24 -12
- package/esm2015/lib/components/hour-scheduling-expandable/components/hour-scheduling-expandable-template/hour-scheduling-expandable-template.component.js +55 -0
- package/esm2015/lib/components/hour-scheduling-expandable/hour-scheduling-expandable.component.js +316 -0
- package/esm2015/lib/components/hour-scheduling-expandable/hour-scheduling-expandable.module.js +25 -0
- package/esm2015/lib/components/input-number-picker/input-number-picker.component.js +2 -1
- package/esm2015/lib/core/enum/core-components-icon.enum.js +1 -1
- package/esm2015/lib/core/enum/filterItem-mode.enum.js +3 -3
- package/esm2015/public-api.js +5 -1
- package/fesm2015/colijnit-corecomponents_v12.js +420 -17
- package/fesm2015/colijnit-corecomponents_v12.js.map +1 -1
- package/lib/components/hour-scheduling/components/hour-scheduling-test-object/style/_layout.scss +2 -0
- package/lib/components/hour-scheduling/components/hour-scheduling-test-object/style/_theme.scss +2 -2
- package/lib/components/hour-scheduling/hour-scheduling.component.d.ts +4 -3
- package/lib/components/hour-scheduling/style/_layout.scss +2 -0
- package/lib/components/hour-scheduling-expandable/components/hour-scheduling-expandable-template/hour-scheduling-expandable-template.component.d.ts +10 -0
- package/lib/components/hour-scheduling-expandable/components/hour-scheduling-expandable-template/style/_layout.scss +4 -0
- package/lib/components/hour-scheduling-expandable/components/hour-scheduling-expandable-template/style/_material-definition.scss +0 -0
- package/lib/components/hour-scheduling-expandable/components/hour-scheduling-expandable-template/style/_theme.scss +4 -0
- package/lib/components/hour-scheduling-expandable/components/hour-scheduling-expandable-template/style/material.scss +4 -0
- package/lib/components/hour-scheduling-expandable/hour-scheduling-expandable.component.d.ts +76 -0
- package/lib/components/hour-scheduling-expandable/hour-scheduling-expandable.module.d.ts +2 -0
- package/lib/components/hour-scheduling-expandable/style/_layout.scss +103 -0
- package/lib/components/hour-scheduling-expandable/style/_material-definition.scss +0 -0
- package/lib/components/hour-scheduling-expandable/style/_theme.scss +4 -0
- package/lib/components/hour-scheduling-expandable/style/material.scss +4 -0
- package/package.json +1 -1
- package/public-api.d.ts +4 -0
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { OnInit, ChangeDetectorRef, TemplateRef, EventEmitter } from '@angular/core';
|
|
1
|
+
import { OnInit, ChangeDetectorRef, TemplateRef, EventEmitter, NgZone } from '@angular/core';
|
|
2
2
|
import { DatePipe } from '@angular/common';
|
|
3
3
|
interface SchedulingObject {
|
|
4
4
|
start: number;
|
|
@@ -10,7 +10,7 @@ interface SchedulingObject {
|
|
|
10
10
|
export declare class HourSchedulingComponent implements OnInit {
|
|
11
11
|
private cdRef;
|
|
12
12
|
private datePipe;
|
|
13
|
-
|
|
13
|
+
private zone;
|
|
14
14
|
hourLabels: string[];
|
|
15
15
|
scheduledObjects: {
|
|
16
16
|
[hour: string]: SchedulingObject[];
|
|
@@ -31,7 +31,8 @@ export declare class HourSchedulingComponent implements OnInit {
|
|
|
31
31
|
currentHour: string;
|
|
32
32
|
data: string;
|
|
33
33
|
}>;
|
|
34
|
-
|
|
34
|
+
showClass: boolean;
|
|
35
|
+
constructor(cdRef: ChangeDetectorRef, datePipe: DatePipe, zone: NgZone);
|
|
35
36
|
ngOnInit(): void;
|
|
36
37
|
ngOnDestroy(): void;
|
|
37
38
|
generateTimeBlocks(): void;
|
|
@@ -22,6 +22,7 @@
|
|
|
22
22
|
}
|
|
23
23
|
.drag-over {
|
|
24
24
|
background-color: rgba(26, 115, 232, 0.2);
|
|
25
|
+
transition: background-color 0.3s ease;
|
|
25
26
|
}
|
|
26
27
|
.object-display {
|
|
27
28
|
display: flex;
|
|
@@ -33,6 +34,7 @@
|
|
|
33
34
|
border-style: solid;
|
|
34
35
|
border-color: #F5F5FC;
|
|
35
36
|
border-width: 1px 0 1px 0;
|
|
37
|
+
transition: background-color 0.3s ease;
|
|
36
38
|
&.has-objects {
|
|
37
39
|
cursor: grab;
|
|
38
40
|
background: #F5F5FC;
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { TemplateRef } from "@angular/core";
|
|
2
|
+
export declare class HourSchedulingExpandableTemplateComponent {
|
|
3
|
+
objectTemplate: TemplateRef<any>;
|
|
4
|
+
objects: Object[];
|
|
5
|
+
onDragStartCustom: Function;
|
|
6
|
+
onResizeStart: Function;
|
|
7
|
+
onSelectBlock: Function;
|
|
8
|
+
showClass(): boolean;
|
|
9
|
+
onExpandableDragStart(event: DragEvent, obj: Object, onDragStartCustom: Function): void;
|
|
10
|
+
}
|
|
File without changes
|
|
@@ -0,0 +1,76 @@
|
|
|
1
|
+
import { ChangeDetectorRef, ElementRef, EventEmitter, OnInit, TemplateRef } from '@angular/core';
|
|
2
|
+
import { DatePipe } from '@angular/common';
|
|
3
|
+
interface SchedulingObject {
|
|
4
|
+
start: Date;
|
|
5
|
+
end: Date;
|
|
6
|
+
title?: string;
|
|
7
|
+
subTitle?: string;
|
|
8
|
+
height?: number;
|
|
9
|
+
top?: number;
|
|
10
|
+
id: number | string;
|
|
11
|
+
selected: boolean;
|
|
12
|
+
showTopResizer?: boolean;
|
|
13
|
+
showBottomResizer?: boolean;
|
|
14
|
+
[key: string]: any;
|
|
15
|
+
}
|
|
16
|
+
export declare class HourSchedulingExpandableComponent implements OnInit {
|
|
17
|
+
private cdRef;
|
|
18
|
+
private datePipe;
|
|
19
|
+
private eRef;
|
|
20
|
+
hourLabels: string[];
|
|
21
|
+
scheduledObjects: SchedulingObject[];
|
|
22
|
+
private resizing;
|
|
23
|
+
private resizeDirection;
|
|
24
|
+
private initialY;
|
|
25
|
+
private initialHeight;
|
|
26
|
+
private initialTop;
|
|
27
|
+
private currentResizingObject;
|
|
28
|
+
private currentDraggingObject;
|
|
29
|
+
private MIN_HEIGHT;
|
|
30
|
+
private _schedule;
|
|
31
|
+
set schedule(value: Object);
|
|
32
|
+
get schedule(): Object;
|
|
33
|
+
startTimeProp: string;
|
|
34
|
+
endTimeProp: string;
|
|
35
|
+
objectsProp: string;
|
|
36
|
+
childProp: string;
|
|
37
|
+
customTemplate: TemplateRef<any>;
|
|
38
|
+
idProp: string;
|
|
39
|
+
timeChangeEvent: EventEmitter<Object>;
|
|
40
|
+
newObjectPlanEvent: EventEmitter<{
|
|
41
|
+
currentHour: string;
|
|
42
|
+
data: string;
|
|
43
|
+
}>;
|
|
44
|
+
showClass: boolean;
|
|
45
|
+
onResize(event: {
|
|
46
|
+
target: {
|
|
47
|
+
innerWidth: any;
|
|
48
|
+
};
|
|
49
|
+
}): void;
|
|
50
|
+
clickOut(event: {
|
|
51
|
+
target: any;
|
|
52
|
+
}): void;
|
|
53
|
+
constructor(cdRef: ChangeDetectorRef, datePipe: DatePipe, eRef: ElementRef);
|
|
54
|
+
ngOnInit(): void;
|
|
55
|
+
private _calculateSchedulingObjectProperties;
|
|
56
|
+
private _findNextObject;
|
|
57
|
+
private _findPreviousObject;
|
|
58
|
+
renderObjects(): void;
|
|
59
|
+
onSelectBlock(obj: SchedulingObject): void;
|
|
60
|
+
onDragStartCustom(obj: SchedulingObject): void;
|
|
61
|
+
handleDrop(dragEvent: DragEvent, hour: string): void;
|
|
62
|
+
allowDrop(event: DragEvent, hour: string): boolean;
|
|
63
|
+
onResizeStart(event: MouseEvent, obj: SchedulingObject, direction: 'top' | 'bottom'): void;
|
|
64
|
+
onResizing(event: MouseEvent): void;
|
|
65
|
+
onResizeEnd(event: MouseEvent): void;
|
|
66
|
+
timeDifference(date1: Date, date2: Date): number;
|
|
67
|
+
generateTimeBlocks(): void;
|
|
68
|
+
dateToUnixEpoch(date: Date): number;
|
|
69
|
+
addMinutes(date: Date, minutes: number): Date;
|
|
70
|
+
tryParseJSONObject(jsonString: string): any;
|
|
71
|
+
addHalfHour(hour: string): string;
|
|
72
|
+
convertTZ(date: any, tzString: any): Date;
|
|
73
|
+
convertDateToEuropean(date: Date): Date;
|
|
74
|
+
handleDeselectAll(): void;
|
|
75
|
+
}
|
|
76
|
+
export {};
|
|
@@ -0,0 +1,103 @@
|
|
|
1
|
+
|
|
2
|
+
|
|
3
|
+
@include export-module('cc-hour-scheduling-expandable-layout') {
|
|
4
|
+
.co-hour-scheduling-expandable {
|
|
5
|
+
display: flex;
|
|
6
|
+
flex-direction: column;
|
|
7
|
+
padding: 30px 0;
|
|
8
|
+
background: #FFF;
|
|
9
|
+
|
|
10
|
+
.custom-scheduled-object {
|
|
11
|
+
position: absolute;
|
|
12
|
+
width: 75%;
|
|
13
|
+
margin: 0 0 0 50px;
|
|
14
|
+
top: var(--top);
|
|
15
|
+
height: var(--height);
|
|
16
|
+
border: 1px solid black;
|
|
17
|
+
|
|
18
|
+
.top-resizer, .bottom-resizer {
|
|
19
|
+
height: 5px;
|
|
20
|
+
}
|
|
21
|
+
|
|
22
|
+
.top-resizer {
|
|
23
|
+
cursor: n-resize;
|
|
24
|
+
}
|
|
25
|
+
|
|
26
|
+
.bottom-resizer {
|
|
27
|
+
cursor: s-resize;
|
|
28
|
+
}
|
|
29
|
+
|
|
30
|
+
&.selected {
|
|
31
|
+
border: 1px solid red;
|
|
32
|
+
}
|
|
33
|
+
}
|
|
34
|
+
|
|
35
|
+
.wrapper {
|
|
36
|
+
position: relative;
|
|
37
|
+
}
|
|
38
|
+
|
|
39
|
+
.scheduled-objects {
|
|
40
|
+
display: flex;
|
|
41
|
+
flex-direction: column;
|
|
42
|
+
height: 100%;
|
|
43
|
+
|
|
44
|
+
}
|
|
45
|
+
.time-block {
|
|
46
|
+
display: flex;
|
|
47
|
+
justify-content: space-between;
|
|
48
|
+
align-items: flex-start;
|
|
49
|
+
background-color: #ffffff;
|
|
50
|
+
}
|
|
51
|
+
|
|
52
|
+
.hour-label {
|
|
53
|
+
font-weight: bold;
|
|
54
|
+
width: 60px;
|
|
55
|
+
padding: 0 10px;
|
|
56
|
+
position: relative;
|
|
57
|
+
top: -10px;
|
|
58
|
+
}
|
|
59
|
+
.drag-over {
|
|
60
|
+
background-color: rgba(26, 115, 232, 0.2);
|
|
61
|
+
transition: background-color 0.3s ease;
|
|
62
|
+
}
|
|
63
|
+
.object-display {
|
|
64
|
+
display: flex;
|
|
65
|
+
width: 100%;
|
|
66
|
+
flex-direction: column;
|
|
67
|
+
.object-half {
|
|
68
|
+
padding: 5px;
|
|
69
|
+
min-height: 30px;
|
|
70
|
+
border-style: solid;
|
|
71
|
+
border-color: #F5F5FC;
|
|
72
|
+
border-width: 1px 0 1px 0;
|
|
73
|
+
transition: background-color 0.3s ease;
|
|
74
|
+
&.has-objects {
|
|
75
|
+
cursor: grab;
|
|
76
|
+
background: #F5F5FC;
|
|
77
|
+
border: 1px solid #F5F5FC;
|
|
78
|
+
&:hover {
|
|
79
|
+
background-color: rgba(26, 115, 232, 0.2);
|
|
80
|
+
}
|
|
81
|
+
&.active {
|
|
82
|
+
background-color: rgba(26, 115, 232, 0.2);
|
|
83
|
+
border: 1px solid #1A73E8;
|
|
84
|
+
}
|
|
85
|
+
}
|
|
86
|
+
}
|
|
87
|
+
}
|
|
88
|
+
|
|
89
|
+
.scheduled-object {
|
|
90
|
+
padding: 0.5em;
|
|
91
|
+
background-color: #4CAF50;
|
|
92
|
+
color: white;
|
|
93
|
+
border-radius: 3px;
|
|
94
|
+
cursor: pointer;
|
|
95
|
+
display: flex;
|
|
96
|
+
flex-direction: column;
|
|
97
|
+
|
|
98
|
+
.title {
|
|
99
|
+
font-weight: bold;
|
|
100
|
+
}
|
|
101
|
+
}
|
|
102
|
+
}
|
|
103
|
+
}
|
|
File without changes
|
package/package.json
CHANGED
package/public-api.d.ts
CHANGED
|
@@ -127,4 +127,8 @@ export * from './lib/service/base-module.service';
|
|
|
127
127
|
export * from './lib/translation/core-components-translation.module';
|
|
128
128
|
export * from './lib/translation/core-components-translation.service';
|
|
129
129
|
export * from './lib/components/hour-scheduling/hour-scheduling.component';
|
|
130
|
+
export * from './lib/components/hour-scheduling-expandable/hour-scheduling-expandable.component';
|
|
131
|
+
export * from './lib/components/hour-scheduling-expandable/components/hour-scheduling-expandable-template/hour-scheduling-expandable-template.component';
|
|
130
132
|
export * from './lib/components/hour-scheduling/hour-scheduling.module';
|
|
133
|
+
export * from './lib/components/hour-scheduling-expandable/hour-scheduling-expandable.module';
|
|
134
|
+
export * from './lib/components/hour-scheduling-expandable/hour-scheduling-expandable.module';
|