Skip to content

Commit 7385653

Browse files
committed
chore(*): replace inheritDoc with summary comment
1 parent 60443b3 commit 7385653

19 files changed

+311
-88
lines changed

projects/igniteui-angular/src/lib/combo/combo-add-item.component.ts

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -16,9 +16,6 @@ export class IgxComboAddItemComponent extends IgxComboItemComponent {
1616
public set selected(value: boolean) {
1717
}
1818

19-
/**
20-
* @inheritDoc
21-
*/
2219
public clicked(event?) {// eslint-disable-line
2320
this.comboAPI.disableTransitions = false;
2421
this.comboAPI.add_custom_item();

projects/igniteui-angular/src/lib/combo/combo-item.component.ts

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -95,9 +95,6 @@ export class IgxComboItemComponent extends IgxDropDownItemComponent {
9595
return rect.y >= parentDiv.y;
9696
}
9797

98-
/**
99-
* @inheritDoc
100-
*/
10198
public clicked(event): void {
10299
this.comboAPI.disableTransitions = false;
103100
if (!this.isSelectable) {

projects/igniteui-angular/src/lib/drop-down/drop-down-item.component.ts

Lines changed: 27 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,11 @@ import { IgxDropDownItemBaseDirective } from './drop-down-item.base';
1414
})
1515
export class IgxDropDownItemComponent extends IgxDropDownItemBaseDirective {
1616
/**
17-
* @inheritDoc
17+
* Sets/gets if the given item is focused
18+
* ```typescript
19+
* let mySelectedItem = this.dropdown.selectedItem;
20+
* let isMyItemFocused = mySelectedItem.focused;
21+
* ```
1822
*/
1923
public get focused(): boolean {
2024
let focusedState = this._focused;
@@ -27,15 +31,29 @@ export class IgxDropDownItemComponent extends IgxDropDownItemBaseDirective {
2731
}
2832

2933
/**
30-
* @inheritDoc
34+
* Sets/gets if the given item is focused
35+
* ```typescript
36+
* let mySelectedItem = this.dropdown.selectedItem;
37+
* let isMyItemFocused = mySelectedItem.focused;
38+
* ```
3139
*/
32-
public set focused(value: boolean) {
40+
public set focused(value: boolean) {
3341
this._focused = value;
3442
}
3543
/**
36-
* @inheritDoc
44+
* Sets/Gets if the item is the currently selected one in the dropdown
45+
*
46+
* ```typescript
47+
* let mySelectedItem = this.dropdown.selectedItem;
48+
* let isMyItemSelected = mySelectedItem.selected; // true
49+
* ```
50+
*
51+
* Two-way data binding
52+
* ```html
53+
* <igx-drop-down-item [(selected)]='model.isSelected'></igx-drop-down-item>
54+
* ```
3755
*/
38-
public get selected(): boolean {
56+
public get selected(): boolean {
3957
if (this.hasIndex) {
4058
const item = this.selection.first_item(`${this.dropDown.id}`);
4159
return item ? item.index === this._index && item.value === this.value : false;
@@ -44,9 +62,10 @@ export class IgxDropDownItemComponent extends IgxDropDownItemBaseDirective {
4462
}
4563

4664
/**
47-
* @inheritDoc
65+
* Sets/Gets if the item is the currently selected one in the dropdown
66+
*
4867
*/
49-
public set selected(value: boolean) {
68+
public set selected(value: boolean) {
5069
if (this.isHeader) {
5170
return;
5271
}
@@ -66,10 +85,7 @@ export class IgxDropDownItemComponent extends IgxDropDownItemBaseDirective {
6685
}
6786
}
6887

69-
/**
70-
* @inheritDoc
71-
*/
72-
public clicked(event): void {
88+
public clicked(event): void {
7389
if (!this.isSelectable) {
7490
this.ensureItemFocus();
7591
return;

projects/igniteui-angular/src/lib/grids/grid/grid.component.ts

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1065,7 +1065,12 @@ export class IgxGridComponent extends IgxGridBaseDirective implements GridType,
10651065
}
10661066

10671067
/**
1068-
* @inheritDoc
1068+
*
1069+
* Returns an array of the current cell selection in the form of `[{ column.field: cell.value }, ...]`.
1070+
*
1071+
* @remarks
1072+
* If `formatters` is enabled, the cell value will be formatted by its respective column formatter (if any).
1073+
* If `headers` is enabled, it will use the column header (if any) instead of the column field.
10691074
*/
10701075
public getSelectedData(formatters = false, headers = false): any[] {
10711076
if (this.groupingExpressions.length || this.hasDetails) {

projects/igniteui-angular/src/lib/grids/tree-grid/tree-grid.component.ts

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -673,7 +673,12 @@ export class IgxTreeGridComponent extends IgxGridBaseDirective implements GridTy
673673
}
674674

675675
/**
676-
* @inheritDoc
676+
*
677+
* Returns an array of the current cell selection in the form of `[{ column.field: cell.value }, ...]`.
678+
*
679+
* @remarks
680+
* If `formatters` is enabled, the cell value will be formatted by its respective column formatter (if any).
681+
* If `headers` is enabled, it will use the column header (if any) instead of the column field.
677682
*/
678683
public getSelectedData(formatters = false, headers = false): any[] {
679684
let source = [];

projects/igniteui-angular/src/lib/select/select-positioning-strategy.ts

Lines changed: 15 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,9 @@ import { Optional } from '@angular/core';
88

99
/** @hidden @internal */
1010
export class SelectPositioningStrategy extends BaseFitPositionStrategy implements IPositionStrategy {
11-
/** @inheritDoc */
11+
/**
12+
* PositionSettings to use when position the component in the overlay
13+
*/
1214
public settings: PositionSettings;
1315

1416
private _selectDefaultSettings = {
@@ -30,7 +32,18 @@ export class SelectPositioningStrategy extends BaseFitPositionStrategy implement
3032
this.settings = Object.assign({}, this._selectDefaultSettings, settings);
3133
}
3234

33-
/** @inheritDoc */
35+
/**
36+
* Position the element based on the PositionStrategy implementing this interface.
37+
*
38+
* @param contentElement The HTML element to be positioned
39+
* @param size Size of the element
40+
* @param document reference to the Document object
41+
* @param initialCall should be true if this is the initial call to the method
42+
* @param target attaching target for the component to show
43+
* ```typescript
44+
* settings.positionStrategy.position(content, size, document, true);
45+
* ```
46+
*/
3447
public position(contentElement: HTMLElement,
3548
size: Size,
3649
document?: Document,

projects/igniteui-angular/src/lib/services/overlay/position/auto-position-strategy.ts

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,12 @@ import { BaseFitPositionStrategy } from './base-fit-position-strategy';
99
*/
1010
export class AutoPositionStrategy extends BaseFitPositionStrategy {
1111

12-
/** @inheritDoc */
12+
/**
13+
* Fits the element into viewport according to the position settings
14+
*
15+
* @param element element to fit in viewport
16+
* @param connectedFit connectedFit object containing all necessary parameters
17+
*/
1318
protected fitInViewport(element: HTMLElement, connectedFit: ConnectedFit) {
1419
const transformString: string[] = [];
1520
if (connectedFit.fitHorizontal.back < 0 || connectedFit.fitHorizontal.forward < 0) {

projects/igniteui-angular/src/lib/services/overlay/position/base-fit-position-strategy.ts

Lines changed: 12 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,18 @@ export abstract class BaseFitPositionStrategy extends ConnectedPositioningStrate
55
protected _initialSize: Size;
66
protected _initialSettings: PositionSettings;
77

8-
/** @inheritDoc */
8+
/**
9+
* Position the element based on the PositionStrategy implementing this interface.
10+
*
11+
* @param contentElement The HTML element to be positioned
12+
* @param size Size of the element
13+
* @param document reference to the Document object
14+
* @param initialCall should be true if this is the initial call to the method
15+
* @param target attaching target for the component to show
16+
* ```typescript
17+
* settings.positionStrategy.position(content, size, document, true);
18+
* ```
19+
*/
920
public position(
1021
contentElement: HTMLElement, size: Size, document?: Document, initialCall?: boolean, target?: Point | HTMLElement): void {
1122
const targetElement = target || this.settings.target;

projects/igniteui-angular/src/lib/services/overlay/position/connected-positioning-strategy.ts

Lines changed: 24 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,9 @@ import { IPositionStrategy } from './IPositionStrategy';
1515
* It is possible to either pass a start point or an HTMLElement as a positioning base.
1616
*/
1717
export class ConnectedPositioningStrategy implements IPositionStrategy {
18-
/** @inheritDoc */
18+
/**
19+
* PositionSettings to use when position the component in the overlay
20+
*/
1921
public settings: PositionSettings;
2022

2123
private _defaultSettings: PositionSettings = {
@@ -32,15 +34,25 @@ export class ConnectedPositioningStrategy implements IPositionStrategy {
3234
this.settings = Object.assign({}, this._defaultSettings, settings);
3335
}
3436

35-
/** @inheritDoc */
37+
/**
38+
* Position the element based on the PositionStrategy implementing this interface.
39+
*
40+
* @param contentElement The HTML element to be positioned
41+
* @param size Size of the element
42+
* @param document reference to the Document object
43+
* @param initialCall should be true if this is the initial call to the method
44+
* @param target attaching target for the component to show
45+
* ```typescript
46+
* settings.positionStrategy.position(content, size, document, true);
47+
* ```
48+
*/
3649
public position(contentElement: HTMLElement, size: Size, document?: Document, initialCall?: boolean, target?: Point | HTMLElement): void {
3750
const targetElement = target || this.settings.target;
38-
const rects = this.calculateElementRectangles(contentElement, targetElement);
51+
const rects = this.calculateElementRectangles(contentElement, targetElement);
3952
this.setStyle(contentElement, rects.targetRect, rects.elementRect, {});
4053
}
4154

4255
/**
43-
* @inheritDoc
4456
* Creates clone of this position strategy
4557
* @returns clone of this position strategy
4658
*/
@@ -53,12 +65,12 @@ export class ConnectedPositioningStrategy implements IPositionStrategy {
5365
*
5466
* @returns target and element DomRect objects
5567
*/
56-
protected calculateElementRectangles(contentElement, target: Point | HTMLElement):
57-
{ targetRect: Partial<DOMRect>; elementRect: Partial<DOMRect> } {
58-
return {
59-
targetRect: Util.getTargetRect(target),
60-
elementRect: contentElement.getBoundingClientRect() as DOMRect
61-
};
68+
protected calculateElementRectangles(contentElement, target: Point | HTMLElement):
69+
{ targetRect: Partial<DOMRect>; elementRect: Partial<DOMRect> } {
70+
return {
71+
targetRect: Util.getTargetRect(target),
72+
elementRect: contentElement.getBoundingClientRect() as DOMRect
73+
};
6274
}
6375

6476
/**
@@ -70,8 +82,8 @@ export class ConnectedPositioningStrategy implements IPositionStrategy {
7082
* @param elementRect Bounding rectangle of the element
7183
*/
7284
protected setStyle(element: HTMLElement, targetRect: Partial<DOMRect>, elementRect: Partial<DOMRect>, connectedFit: ConnectedFit) {
73-
const horizontalOffset = connectedFit.horizontalOffset ? connectedFit.horizontalOffset : 0;
74-
const verticalOffset = connectedFit.verticalOffset ? connectedFit.verticalOffset : 0;
85+
const horizontalOffset = connectedFit.horizontalOffset ? connectedFit.horizontalOffset : 0;
86+
const verticalOffset = connectedFit.verticalOffset ? connectedFit.verticalOffset : 0;
7587
const startPoint: Point = {
7688
x: targetRect.right + targetRect.width * this.settings.horizontalStartPoint + horizontalOffset,
7789
y: targetRect.bottom + targetRect.height * this.settings.verticalStartPoint + verticalOffset

projects/igniteui-angular/src/lib/services/overlay/position/container-position-strategy.ts

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,9 @@ export class ContainerPositionStrategy extends GlobalPositionStrategy {
1010
super(settings);
1111
}
1212

13-
/** @inheritDoc */
13+
/**
14+
* Position the element based on the PositionStrategy implementing this interface.
15+
*/
1416
public position(contentElement: HTMLElement): void {
1517
contentElement.classList.add('igx-overlay__content--relative');
1618
contentElement.parentElement.classList.add('igx-overlay__wrapper--flex-container');

0 commit comments

Comments
 (0)