@colijnit/corecomponents_v12 262.1.16 → 262.1.18

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/index.d.ts CHANGED
@@ -2406,6 +2406,8 @@ declare abstract class BaseSimpleGridComponent implements DoCheck {
2406
2406
  singleColumnIndex(row: Object): number;
2407
2407
  protected dataHasChanged(): void;
2408
2408
  protected prepareDataRow(row: any, index: number): Promise<void>;
2409
+ protected repeatSortOnDataChange(): void;
2410
+ protected setData(value: Object[]): void;
2409
2411
  private _setColumns;
2410
2412
  private _prepareData;
2411
2413
  private _prepareDataRows;
@@ -2427,6 +2429,7 @@ declare class SimpleGridComponent extends BaseSimpleGridComponent {
2427
2429
  private _formMaster;
2428
2430
  readonly defaultTextAlign: ColumnAlign;
2429
2431
  readonly scrollDirections: typeof ScrollDirection;
2432
+ private _previouslySortedColumn;
2430
2433
  set headerCells(cells: any);
2431
2434
  rowElements: QueryList<ElementRef>;
2432
2435
  showAdd: boolean;
@@ -2484,7 +2487,8 @@ declare class SimpleGridComponent extends BaseSimpleGridComponent {
2484
2487
  toggleSettingsMenu(): void;
2485
2488
  toggleColumnMenu(col: any): void;
2486
2489
  hideColumn(col: any): void;
2487
- sortColumn(col: any, columnValue: string): void;
2490
+ sortColumn(col: any, columnValue: string, preserveSortDirection?: boolean): void;
2491
+ protected repeatSortOnDataChange(): void;
2488
2492
  showAllColumns(): void;
2489
2493
  exportToExcel(): void;
2490
2494
  goToPreviousPage(): void;
@@ -3435,19 +3439,28 @@ declare class TooltipDirective implements OnDestroy, OnInit {
3435
3439
  private _injector;
3436
3440
  private _sanitizer;
3437
3441
  set tooltip(str: string);
3442
+ orientation: CoDirection;
3438
3443
  private _elementRef;
3439
3444
  private _tooltipMessage;
3440
3445
  private _componentRef;
3446
+ private _showTimeoutId;
3447
+ private _autoHideTimeoutId;
3448
+ private readonly _mouseEnterHandler;
3449
+ private readonly _mouseLeaveHandler;
3450
+ private readonly _scrollHandler;
3441
3451
  constructor(elementRef: ElementRef, _compFactoryResolver: ComponentFactoryResolver, _appRef: ApplicationRef, _injector: Injector, _sanitizer: DomSanitizer);
3442
3452
  ngOnDestroy(): void;
3443
3453
  ngOnInit(): void;
3444
3454
  private _handleScroll;
3445
- private _handleMouseMove;
3446
- private _showTooltip;
3455
+ private _startShowTimeout;
3456
+ private _resolveDelay;
3457
+ private _clearShowTimeout;
3447
3458
  private _removeTooltip;
3459
+ private _startAutoHideTimeout;
3460
+ private _clearAutoHideTimeout;
3448
3461
  private _createTooltipComponent;
3449
3462
  static ɵfac: i0.ɵɵFactoryDeclaration<TooltipDirective, never>;
3450
- static ɵdir: i0.ɵɵDirectiveDeclaration<TooltipDirective, "[tooltip]", never, { "tooltip": { "alias": "tooltip"; "required": false; }; }, {}, never, never, false, never>;
3463
+ static ɵdir: i0.ɵɵDirectiveDeclaration<TooltipDirective, "[tooltip]", never, { "tooltip": { "alias": "tooltip"; "required": false; }; "orientation": { "alias": "tooltipOrientation"; "required": false; }; }, {}, never, never, false, never>;
3451
3464
  }
3452
3465
 
3453
3466
  declare class TooltipComponent implements AfterViewInit, OnDestroy {
@@ -3457,21 +3470,32 @@ declare class TooltipComponent implements AfterViewInit, OnDestroy {
3457
3470
  set hostElement(value: HTMLElement);
3458
3471
  get hostElement(): HTMLElement;
3459
3472
  toolTip: SafeHtml | string;
3473
+ orientation: CoDirection;
3460
3474
  tooltipClosed: EventEmitter<void>;
3461
3475
  showClass(): boolean;
3462
3476
  top: number;
3463
3477
  left: number;
3464
- bottom: boolean;
3478
+ get isTop(): boolean;
3479
+ get isBottom(): boolean;
3480
+ get isLeft(): boolean;
3481
+ get isRight(): boolean;
3465
3482
  animate: boolean;
3483
+ private _resolvedOrientation;
3466
3484
  private _hostElement;
3467
3485
  private _documentClickListener;
3468
3486
  constructor(_elementRef: ElementRef, _changeDetector: ChangeDetectorRef, _renderer: Renderer2);
3469
3487
  ngAfterViewInit(): void;
3470
3488
  ngOnDestroy(): void;
3471
3489
  private _positionTooltip;
3490
+ private _resolveOrientation;
3491
+ private _fits;
3492
+ private _availableSpace;
3493
+ private _calculateLeft;
3494
+ private _calculateTop;
3495
+ private _positionArrow;
3472
3496
  private closeTooltip;
3473
3497
  static ɵfac: i0.ɵɵFactoryDeclaration<TooltipComponent, never>;
3474
- static ɵcmp: i0.ɵɵComponentDeclaration<TooltipComponent, "co-tooltip", never, { "hostElement": { "alias": "hostElement"; "required": false; }; "toolTip": { "alias": "toolTip"; "required": false; }; }, { "tooltipClosed": "tooltipClosed"; }, never, never, false, never>;
3498
+ static ɵcmp: i0.ɵɵComponentDeclaration<TooltipComponent, "co-tooltip", never, { "hostElement": { "alias": "hostElement"; "required": false; }; "toolTip": { "alias": "toolTip"; "required": false; }; "orientation": { "alias": "orientation"; "required": false; }; }, { "tooltipClosed": "tooltipClosed"; }, never, never, false, never>;
3475
3499
  }
3476
3500
 
3477
3501
  declare class TooltipModule {
@@ -10,7 +10,7 @@
10
10
  align-items: center;
11
11
  column-gap: 10px;
12
12
  padding: $co-tooltip-padding;
13
- z-index: 999999;
13
+ z-index: $co-tooltip-z-index;
14
14
  border-radius: $co-tooltip-border-radius;
15
15
  border: $co-tooltip-border;
16
16
 
@@ -23,30 +23,73 @@
23
23
  pointer-events: none;
24
24
  position: absolute;
25
25
  width: 0;
26
- bottom: -20px;
27
26
  }
28
27
 
29
28
  &::after {
30
- left: 20px;
31
- border-width: 10px;
29
+ border-width: $co-tooltip-arrow-size;
32
30
  }
33
31
 
34
32
  &::before {
35
- margin-left: 12px;
36
- border-width: 8px;
33
+ border-width: $co-tooltip-arrow-inner-size;
37
34
  z-index: 1;
38
- bottom: -16px;
39
35
  }
36
+
37
+ @if not $co-tooltip-has-border {
38
+ &::after {
39
+ display: none;
40
+ }
41
+ }
42
+
43
+ // The arrow sits on the edge facing the host: --co-tooltip-arrow-center is the offset along that edge.
44
+ &.top {
45
+ &::after {
46
+ left: calc(#{$co-tooltip-arrow-center} - #{$co-tooltip-arrow-size});
47
+ bottom: calc(-2 * #{$co-tooltip-arrow-size});
48
+ }
49
+
50
+ &::before {
51
+ left: calc(#{$co-tooltip-arrow-center} - #{$co-tooltip-arrow-inner-size});
52
+ bottom: calc(-2 * #{$co-tooltip-arrow-inner-size});
53
+ }
54
+ }
55
+
40
56
  &.bottom {
41
- &::after,
57
+ &::after {
58
+ left: calc(#{$co-tooltip-arrow-center} - #{$co-tooltip-arrow-size});
59
+ top: calc(-2 * #{$co-tooltip-arrow-size});
60
+ }
61
+
42
62
  &::before {
43
- bottom: 100%;
63
+ left: calc(#{$co-tooltip-arrow-center} - #{$co-tooltip-arrow-inner-size});
64
+ top: calc(-2 * #{$co-tooltip-arrow-inner-size});
44
65
  }
45
66
  }
67
+
68
+ &.left {
69
+ &::after {
70
+ top: calc(#{$co-tooltip-arrow-center} - #{$co-tooltip-arrow-size});
71
+ right: calc(-2 * #{$co-tooltip-arrow-size});
72
+ }
73
+
74
+ &::before {
75
+ top: calc(#{$co-tooltip-arrow-center} - #{$co-tooltip-arrow-inner-size});
76
+ right: calc(-2 * #{$co-tooltip-arrow-inner-size});
77
+ }
78
+ }
79
+
80
+ &.right {
81
+ &::after {
82
+ top: calc(#{$co-tooltip-arrow-center} - #{$co-tooltip-arrow-size});
83
+ left: calc(-2 * #{$co-tooltip-arrow-size});
84
+ }
85
+
86
+ &::before {
87
+ top: calc(#{$co-tooltip-arrow-center} - #{$co-tooltip-arrow-inner-size});
88
+ left: calc(-2 * #{$co-tooltip-arrow-inner-size});
89
+ }
90
+ }
91
+ .title {
92
+ font-weight: $co-tooltip-title-font-weight;
93
+ }
46
94
  }
47
- //.validation-error-content {
48
- // display: flex;
49
- // flex-direction: row;
50
- // align-items: center;
51
- //}
52
95
  }
@@ -1,8 +1,34 @@
1
+ @use "sass:list";
2
+ @use "sass:meta";
3
+
4
+ :root {
5
+ --co-tooltip-arrow-size: 10px;
6
+ --co-tooltip-arrow-inner-size: 8px;
7
+ --co-tooltip-arrow-center: 30px;
8
+ --co-tooltip-z-index: 9999999999;
9
+ // Read by TooltipDirective (getComputedStyle), not applied by CSS.
10
+ --co-tooltip-show-delay: 400ms;
11
+ --co-tooltip-auto-hide-delay: 10000ms; // 0 disables the auto-hide guard
12
+ }
13
+
1
14
  $co-tooltip-font-family: $cc-font-family !default;
2
15
  $co-tooltip-font-size: $cc-font-size-default !default;
3
16
  $co-tooltip-padding: 10px !default;
4
- $co-tooltip-background-color: $cc-color-form-input-background-focus !default;
5
- $co-tooltip-color: $cc-color-font !default;
6
- $co-tooltip-border: 2px solid !default;
7
- $co-tooltip-border-color: black !default;
17
+ $co-tooltip-background-color: $cc-color-tooltip-default !default;
18
+ $co-tooltip-color: white !default;
19
+ $co-tooltip-border: 1px solid !default;
20
+ $co-tooltip-border-color: gray !default;
8
21
  $co-tooltip-border-radius: 5px !default;
22
+ $co-tooltip-arrow-size: var(--co-tooltip-arrow-size) !default;
23
+ $co-tooltip-arrow-inner-size: var(--co-tooltip-arrow-inner-size) !default;
24
+ $co-tooltip-arrow-center: var(--co-tooltip-arrow-center) !default;
25
+ $co-tooltip-z-index: var(--co-tooltip-z-index) !default;
26
+
27
+ // Derived from the border shorthand so the arrow rim follows whatever the consumer sets.
28
+ $co-tooltip-border-width: if(meta.type-of($co-tooltip-border) == list, list.nth($co-tooltip-border, 1), $co-tooltip-border) !default;
29
+ $co-tooltip-has-border: meta.type-of($co-tooltip-border-width) == number and $co-tooltip-border-width > 0 !default;
30
+
31
+ $co-tooltip-title-font-family: $cc-font-family !default;
32
+ $co-tooltip-title-font-size: $cc-font-size-default !default;
33
+ $co-tooltip-title-font-color: $co-tooltip-color !default;
34
+ $co-tooltip-title-font-weight: bold !default;
@@ -4,30 +4,49 @@
4
4
  color: $co-tooltip-color;
5
5
  border-color: $co-tooltip-border-color;
6
6
 
7
- &::after {
8
- border-bottom-color: transparent;
9
- border-top-color: $co-tooltip-border-color;
7
+ // Each orientation colours the border edge that forms the visible triangle.
8
+ &.top {
9
+ &::after {
10
+ border-top-color: $co-tooltip-border-color;
11
+ }
12
+
13
+ &::before {
14
+ border-top-color: $co-tooltip-background-color;
15
+ }
10
16
  }
11
17
 
12
- &::before {
13
- border-bottom-color: transparent;
14
- border-top-color: $co-tooltip-background-color;
18
+ &.bottom {
19
+ &::after {
20
+ border-bottom-color: $co-tooltip-border-color;
21
+ }
22
+
23
+ &::before {
24
+ border-bottom-color: $co-tooltip-background-color;
25
+ }
15
26
  }
16
27
 
17
- @if $co-tooltip-border == "none" {
28
+ &.left {
18
29
  &::after {
19
- display: none;
30
+ border-left-color: $co-tooltip-border-color;
31
+ }
32
+
33
+ &::before {
34
+ border-left-color: $co-tooltip-background-color;
20
35
  }
21
36
  }
22
- &.bottom {
37
+
38
+ &.right {
23
39
  &::after {
24
- border-top-color: transparent;
25
- border-bottom-color: $co-tooltip-border-color;
40
+ border-right-color: $co-tooltip-border-color;
26
41
  }
42
+
27
43
  &::before {
28
- border-top-color: transparent;
29
- border-bottom-color: $co-tooltip-background-color;
44
+ border-right-color: $co-tooltip-background-color;
30
45
  }
31
46
  }
47
+
48
+ .title {
49
+ color: $co-tooltip-title-font-color;
50
+ }
32
51
  }
33
52
  }
@@ -48,6 +48,7 @@ $cc-color-text-main: #22313C !default;
48
48
  $cc-color-input-positive: #d7ead7 !default;
49
49
  $cc-color-input-important: $cc-color-light !default;
50
50
  $cc-color-input-info: #e4e6eb !default;
51
+ $cc-color-tooltip-default: #2e3350 !default;
51
52
  $cc-color-active-accent: #8faba6 !default;
52
53
  $cc-color-less-light: #F7FAFA !default;
53
54
  $cc-color-border: #CCCCCC !default;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@colijnit/corecomponents_v12",
3
- "version": "262.1.16",
3
+ "version": "262.1.18",
4
4
  "description": "Colijn IT core components for Angular 20",
5
5
  "private": false,
6
6
  "peerDependencies": {