Skip to content

Commit

Permalink
chore: add JSDoc for custom events [skip ci] (#2103)
Browse files Browse the repository at this point in the history
  • Loading branch information
web-padawan authored Dec 15, 2020
1 parent b0cbba4 commit d7329f5
Show file tree
Hide file tree
Showing 12 changed files with 43 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/vaadin-grid-filter.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,8 @@ export interface GridFilterEventMap extends HTMLElementEventMap, GridFilterEleme
* <template>[[item.name.first]]</template>
* </vaadin-grid-column>
* ```
*
* @fires {CustomEvent} value-changed - Fired when the `value` property changes.
*/
declare class GridFilterElement extends HTMLElement {
/**
Expand Down
1 change: 1 addition & 0 deletions src/vaadin-grid-filter.js
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@ import '@vaadin/vaadin-text-field/src/vaadin-text-field.js';
* </vaadin-grid-column>
* ```
*
* @fires {CustomEvent} value-changed - Fired when the `value` property changes.
*/
class GridFilterElement extends PolymerElement {
static get template() {
Expand Down
2 changes: 2 additions & 0 deletions src/vaadin-grid-selection-column.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,8 @@ export interface GridSelectionColumnEventMap extends HTMLElementEventMap, GridSe
* selection for all the items at once.
*
* __The default content can also be overridden__
*
* @fires {CustomEvent} select-all-changed - Fired when the `selectAll` property changes.
*/
declare class GridSelectionColumnElement extends GridColumnElement {
/**
Expand Down
2 changes: 2 additions & 0 deletions src/vaadin-grid-selection-column.js
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,8 @@ import '@vaadin/vaadin-checkbox/src/vaadin-checkbox.js';
* selection for all the items at once.
*
* __The default content can also be overridden__
*
* @fires {CustomEvent} select-all-changed - Fired when the `selectAll` property changes.
*/
class GridSelectionColumnElement extends GridColumnElement {
static get template() {
Expand Down
2 changes: 2 additions & 0 deletions src/vaadin-grid-sort-column.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,8 @@ export interface GridSortColumnEventMap extends HTMLElementEventMap, GridSortCol
* <vaadin-grid-column>
* ...
* ```
*
* @fires {CustomEvent} direction-changed - Fired when the `direction` property changes.
*/
declare class GridSortColumnElement extends GridColumnElement {
/**
Expand Down
2 changes: 2 additions & 0 deletions src/vaadin-grid-sort-column.js
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,8 @@ import './vaadin-grid-sorter.js';
* <vaadin-grid-column>
* ...
* ```
*
* @fires {CustomEvent} direction-changed - Fired when the `direction` property changes.
*/
class GridSortColumnElement extends GridColumnElement {
static get template() {
Expand Down
3 changes: 3 additions & 0 deletions src/vaadin-grid-sorter.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,9 @@ export interface GridSorterEventMap extends HTMLElementEventMap, GridSorterEleme
* Attribute | Description | Part name
* -------------|-------------|------------
* `direction` | Sort direction of a sorter | :host
*
* @fires {CustomEvent} direction-changed - Fired when the `direction` property changes.
* @fires {CustomEvent} sorter-changed - Fired when the `path` or `direction` property changes.
*/
declare class GridSorterElement extends HTMLElement {
/**
Expand Down
3 changes: 3 additions & 0 deletions src/vaadin-grid-sorter.js
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,9 @@ document.head.appendChild($_documentContainer.content);
* -------------|-------------|------------
* `direction` | Sort direction of a sorter | :host
*
* @fires {CustomEvent} direction-changed - Fired when the `direction` property changes.
* @fires {CustomEvent} sorter-changed - Fired when the `path` or `direction` property changes.
*
* @extends HTMLElement
*/
class GridSorterElement extends ThemableMixin(DirMixin(PolymerElement)) {
Expand Down
2 changes: 2 additions & 0 deletions src/vaadin-grid-tree-toggle.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,8 @@ export interface GridTreeToggleEventMap extends HTMLElementEventMap, GridTreeTog
* Custom CSS property | Description | Default
* ---|---|---
* `--vaadin-grid-tree-toggle-level-offset` | Visual offset step for each tree sublevel | `1em`
*
* @fires {CustomEvent} expanded-changed - Fired when the `expanded` property changes.
*/
declare class GridTreeToggleElement extends ThemableMixin(HTMLElement) {
/**
Expand Down
2 changes: 2 additions & 0 deletions src/vaadin-grid-tree-toggle.js
Original file line number Diff line number Diff line change
Expand Up @@ -64,6 +64,8 @@ document.head.appendChild($_documentContainer.content);
* ---|---|---
* `--vaadin-grid-tree-toggle-level-offset` | Visual offset step for each tree sublevel | `1em`
*
* @fires {CustomEvent} expanded-changed - Fired when the `expanded` property changes.
*
* @extends HTMLElement
* @mixes ThemableMixin
*/
Expand Down
11 changes: 11 additions & 0 deletions src/vaadin-grid.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -329,6 +329,17 @@ export interface GridEventMap extends HTMLElementEventMap, GridElementEventMap {
* `drop-disabled` | Set to a row that can't be dropped on top of | row
*
* See [ThemableMixin – how to apply styles for shadow parts](https://github.com/vaadin/vaadin-themable-mixin/wiki)
*
* @fires {CustomEvent} active-item-changed - Fired when the `activeItem` property changes.
* @fires {CustomEvent} cell-activate - Fired when the cell is activated with click or keyboard.
* @fires {CustomEvent} column-reorder - Fired when the columns in the grid are reordered.
* @fires {CustomEvent} column-resize - Fired when the grid column resize is finished.
* @fires {CustomEvent} expanded-items-changed - Fired when the `expandedItems` property changes.
* @fires {CustomEvent} grid-dragstart - Fired when starting to drag grid rows.
* @fires {CustomEvent} grid-dragend - Fired when the dragging of the rows ends.
* @fires {CustomEvent} grid-drop - Fired when a drop occurs on top of the grid.
* @fires {CustomEvent} loading-changed - Fired when the `loading` property changes.
* @fires {CustomEvent} selected-items-changed - Fired when the `selectedItems` property changes.
*/
declare class GridElement extends ElementMixin(
ThemableMixin(
Expand Down
11 changes: 11 additions & 0 deletions src/vaadin-grid.js
Original file line number Diff line number Diff line change
Expand Up @@ -251,6 +251,17 @@ const TOUCH_DEVICE = (() => {
*
* See [ThemableMixin – how to apply styles for shadow parts](https://github.com/vaadin/vaadin-themable-mixin/wiki)
*
* @fires {CustomEvent} active-item-changed - Fired when the `activeItem` property changes.
* @fires {CustomEvent} cell-activate - Fired when the cell is activated with click or keyboard.
* @fires {CustomEvent} column-reorder - Fired when the columns in the grid are reordered.
* @fires {CustomEvent} column-resize - Fired when the grid column resize is finished.
* @fires {CustomEvent} expanded-items-changed - Fired when the `expandedItems` property changes.
* @fires {CustomEvent} grid-dragstart - Fired when starting to drag grid rows.
* @fires {CustomEvent} grid-dragend - Fired when the dragging of the rows ends.
* @fires {CustomEvent} grid-drop - Fired when a drop occurs on top of the grid.
* @fires {CustomEvent} loading-changed - Fired when the `loading` property changes.
* @fires {CustomEvent} selected-items-changed - Fired when the `selectedItems` property changes.
*
* @extends ScrollerElement
* @mixes ElementMixin
* @mixes ThemableMixin
Expand Down

0 comments on commit d7329f5

Please sign in to comment.