Skip to content
This repository was archived by the owner on Dec 19, 2024. It is now read-only.
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 2 additions & 4 deletions bower.json
Original file line number Diff line number Diff line change
Expand Up @@ -21,8 +21,7 @@
"dependencies": {
"polymer": "Polymer/polymer#1.9 - 2",
"iron-behaviors": "PolymerElements/iron-behaviors#1 - 2",
"iron-overlay-behavior": "PolymerElements/iron-overlay-behavior#^2.2.0",
"neon-animation": "PolymerElements/neon-animation#1 - 2"
"iron-overlay-behavior": "PolymerElements/iron-overlay-behavior#^2.2.0"
},
"devDependencies": {
"iron-component-page": "PolymerElements/iron-component-page#1 - 2",
Expand All @@ -38,8 +37,7 @@
"dependencies": {
"polymer": "Polymer/polymer#^1.9",
"iron-behaviors": "PolymerElements/iron-behaviors#^1.0.0",
"iron-overlay-behavior": "PolymerElements/iron-overlay-behavior#^2.2.0",
"neon-animation": "PolymerElements/neon-animation#^1.0.0"
"iron-overlay-behavior": "PolymerElements/iron-overlay-behavior#^2.2.0"
},
"devDependencies": {
"iron-component-page": "PolymerElements/iron-component-page#^1.0.0",
Expand Down
3 changes: 1 addition & 2 deletions demo/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,7 @@
<link rel="import" href="../../iron-image/iron-image.html">
<link rel="import" href="../../iron-demo-helpers/demo-snippet.html">
<link rel="import" href="../../iron-demo-helpers/demo-pages-shared-styles.html">
<link rel="import" href="../../neon-animation/web-animations.html">


<link rel="import" href="x-select.html">

<custom-style><style is="custom-style" include="demo-pages-shared-styles">
Expand Down
2 changes: 0 additions & 2 deletions demo/x-select.html
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,6 @@
-->

<link rel="import" href="../iron-dropdown.html">
<link rel="import" href="../../neon-animation/neon-animations.html">
<link rel="import" href="grow-height-animation.html">

<dom-module id="x-select">
<template>
Expand Down
6 changes: 0 additions & 6 deletions iron-dropdown-scroll-manager-extra.d.ts

This file was deleted.

2 changes: 1 addition & 1 deletion iron-dropdown-scroll-manager.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,6 @@
* iron-dropdown-scroll-manager.html
*/

/// <reference path="../iron-overlay-behavior/iron-scroll-manager.d.ts" />
/// <reference path="bower_components\iron-overlay-behavior\iron-scroll-manager.d.ts" />
/// <reference path="iron-dropdown-scroll-manager-extra.d.ts" />

52 changes: 39 additions & 13 deletions iron-dropdown.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,10 +8,9 @@
* iron-dropdown.html
*/

/// <reference path="../polymer/types/polymer.d.ts" />
/// <reference path="../iron-behaviors/iron-control-state.d.ts" />
/// <reference path="../iron-overlay-behavior/iron-overlay-behavior.d.ts" />
/// <reference path="../neon-animation/neon-animation-runner-behavior.d.ts" />
/// <reference path="bower_components\polymer\polymer.d.ts" />
/// <reference path="bower_components\iron-behaviors\iron-control-state.d.ts" />
/// <reference path="bower_components\iron-overlay-behavior\iron-overlay-behavior.d.ts" />
/// <reference path="iron-dropdown-scroll-manager.d.ts" />

/**
Expand All @@ -37,7 +36,7 @@
* hidden until the dropdown element has `opened` set to true, or when the `open`
* method is called on the element.
*/
interface IronDropdownElement extends Polymer.Element, Polymer.IronControlState, Polymer.IronA11yKeysBehavior, Polymer.IronOverlayBehavior, Polymer.NeonAnimationRunnerBehavior {
interface IronDropdownElement extends Polymer.Element, Polymer.IronControlState, Polymer.IronA11yKeysBehavior, Polymer.IronOverlayBehavior {

/**
* The orientation against which to align the dropdown content
Expand Down Expand Up @@ -69,6 +68,22 @@ interface IronDropdownElement extends Polymer.Element, Polymer.IronControlState,
*/
closeAnimationConfig: object|null|undefined;

/**
* The animation that will be played on open. This replaces the
* deprecated openAnimationConfig. Entries here will override the
* animationConfig settings. You can enter your own animation
* by setting it to the css class name.
*/
openAnimation: string|null|undefined;

/**
* The animation that will be played on close. This replaces the
* deprecated closeAnimationConfig. Entries here will override the
* animationConfig settings. You can enter your own animation
* by setting it to the css class name.
*/
closeAnimation: string|null|undefined;

/**
* If provided, this will be the element that will be focused when
* the dropdown opens.
Expand Down Expand Up @@ -120,20 +135,31 @@ interface IronDropdownElement extends Polymer.Element, Polymer.IronControlState,
* Apply focus to focusTarget or containedElement
*/
_applyFocus(): void;
_addListeners(): void;
_removeListeners(): void;

/**
* Called when animation finishes on the dropdown (when opening or
* closing). Responsible for "completing" the process of opening or
* closing the dropdown by positioning it or setting its display to
* none.
* Constructs the final animation config using deprecated neon-animation
* design. New method is to use openAnimation and closeAnimation which
* directly selects animation.
* This work-around is restricted to one animation and if a value is found
* writes the value found into the openAnimation.
*/
_onNeonAnimationFinish(): void;
_updateAnimationConfig(): void;

/**
* Constructs the final animation config from different properties used
* to configure specific parts of the opening and closing animations.
* Replaces Neon-Animation playAnimation - just calls show and hide.
*
* @param type Either `open` or `close`
*/
_updateAnimationConfig(): void;
playAnimation(type: string): void;
_openAnimation(): void;
_closeAnimation(): void;

/**
* Cancels the animation and either fully open or fully close's iron-dropdown
*/
cancelAnimation(): void;

/**
* Updates the overlay position based on configured horizontal
Expand Down
Loading