Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: prepare for TS defs generation [skip ci] #157

Merged
merged 2 commits into from
May 11, 2020
Merged

Conversation

web-padawan
Copy link
Member

Fixes #156

Generated TS definitions files look like this:

vaadin-app-layout.d.ts

import {PolymerElement} from '@polymer/polymer/polymer-element.js';

import {beforeNextRender, afterNextRender} from '@polymer/polymer/lib/utils/render-status.js';

import {ThemableMixin} from '@vaadin/vaadin-themable-mixin/vaadin-themable-mixin.js';

import {ElementMixin} from '@vaadin/vaadin-element-mixin/vaadin-element-mixin.js';

import {FlattenedNodesObserver} from '@polymer/polymer/lib/utils/flattened-nodes-observer.js';

import {html} from '@polymer/polymer/lib/utils/html-tag.js';

declare class AppLayoutElement extends
  ElementMixin(
  ThemableMixin(
  PolymerElement)) {
  primarySection: PrimarySection;
  drawerOpened: boolean;
  readonly overlay: boolean;
  static dispatchCloseOverlayDrawerEvent(): void;
  connectedCallback(): void;
  disconnectedCallback(): void;
  _afterFirstRender(): void;
  _updateDrawerSize(): void;
  _updateOffsetSize(): void;
  _updateDrawerHeight(): void;
  _updateOverlayMode(): void;
  _close(): void;
  _updateTouchOptimizedMode(): void;
  _blockAnimationUntilAfterNextRender(): void;
}

declare global {
  interface HTMLElementTagNameMap {
    "vaadin-app-layout": AppLayoutElement;
  }
}

export {AppLayoutElement};

import {PrimarySection} from '../@types/interfaces';

vaadin-drawer-toggle.d.ts

import {ButtonElement} from '@vaadin/vaadin-button/src/vaadin-button.js';

import {html} from '@polymer/polymer/lib/utils/html-tag.js';

declare class DrawerToggleElement extends ButtonElement {
  ariaLabel: string|null|undefined;
}

declare global {
  interface HTMLElementTagNameMap {
    "vaadin-drawer-toggle": DrawerToggleElement;
  }
}

export {DrawerToggleElement};

@Haprog Haprog self-assigned this May 11, 2020
Copy link

@Haprog Haprog left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

  1. vaadin-app-layout: method __closeOverlayDrawer() should have explicit @private annotation.

@web-padawan web-padawan merged commit e68664d into 2.2 May 11, 2020
@web-padawan web-padawan deleted the gen-ts-defs branch May 11, 2020 12:56
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants