From 6aae5989c593a43d53128250d387a543e87074b2 Mon Sep 17 00:00:00 2001 From: Yvonne Yip Date: Tue, 30 Jul 2013 10:56:02 -0700 Subject: [PATCH 01/18] polymer-overlay: refactor example --- polymer-overlay/index.html | 66 +++++++++++++++++++++++--------------- 1 file changed, 41 insertions(+), 25 deletions(-) diff --git a/polymer-overlay/index.html b/polymer-overlay/index.html index 232273c..c3dc106 100644 --- a/polymer-overlay/index.html +++ b/polymer-overlay/index.html @@ -37,6 +37,39 @@ + + + + ( open styling: )
-
- +

Dialog

Lorem ipsum dolor sit amet, consectetur adipiscing elit. Sed fringilla sapien sed enim sollicitudin laoreet. Suspendisse suscipit, metus ac volutpat sodales, libero magna semper lacus, molestie fringilla massa orci ut arcu. Nullam sodales urna sit amet odio vehicula mattis.


Ut aliquam vulputate congue. Vestibulum pretium pretium nulla quis sollicitudin. Praesent lacinia congue erat nec mattis. Fusce commodo lacus est. Duis turpis eros, ultrices sed aliquet non, blandit egestas velit. Integer a augue nec lorem tristique hendrerit. Curabitur imperdiet risus id enim bibendum vestibulum. Integer id magna at arcu faucibus fermentum vel a augue. Sed fringilla venenatis dolor, in blandit magna molestie luctus. Vestibulum dignissim posuere ultrices. Aenean urna nisl, tincidunt vitae iaculis ut, pharetra nec eros.



I agree with this wholeheartedly. -
- + Thank you. -
+


-
+

-
- +

Dialog 2

I'm dizzy.


-
+ From 22443fdbd6fbff3e408cbc75fae9d3d14e138c14 Mon Sep 17 00:00:00 2001 From: Michael Ries Date: Wed, 31 Jul 2013 15:42:28 -0600 Subject: [PATCH 02/18] update the process for contributing --- CONTRIBUTING.md | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index 9a37da3..3c71fdb 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -21,20 +21,20 @@ Other projects require a similar agreement: jQuery, Firefox, Apache, Node, and m Here's an easy guide that should get you up and running: -1. Fork the project on github and pull down your copy. - > replace the {{ username }} with your username and {{ repository }} with the repository name +1. Fork the project on github +2. Pull down the polymer-all project. - git clone git@github.com:{{ username }}/{{ repository }}.git --recursive + git clone git@github.com:Polymer/polymer-all --recursive - Note the `--recursive`. This is necessary for submodules to initialize properly. If you don't do a recursive clone, you'll have to init them manually: - - git submodule init - git submodule update - -2. Development happens on the `master` branch. Get yourself on it! +3. Go to the polymer-elements directory and switch it to point to your origin. + git remote remove origin + git remote add origin git@github.com:{{ username }}/{{ repository }} + git fetch origin git checkout master +4. Pull down node dependencies. In your polymer-elements directory run 'npm install' this will pull down the tools used for executing the test. + That's it for the one time setup. Now you're ready to make a change. ## Submitting a pull request From 0c6af8c803e3c13b708b11df498cbd99c129d809 Mon Sep 17 00:00:00 2001 From: Michael Ries Date: Wed, 31 Jul 2013 15:59:11 -0600 Subject: [PATCH 03/18] adding section to talk about running tests --- CONTRIBUTING.md | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index 3c71fdb..032e038 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -37,6 +37,17 @@ Here's an easy guide that should get you up and running: That's it for the one time setup. Now you're ready to make a change. +## Running the tests + +To run the tests make sure you have a webserver running with its docroot pointing to the polymer-all directory. Then navigate to /polymer-elements/test/runner.html + +For Example: + + cd polymer-all + ruby -rwebrick -e'WEBrick::HTTPServer.new(:Port => 4000, :DocumentRoot => Dir.pwd).start' + +Then in your browser open: http://localhost:4000/polymer-elements/test/runner.html + ## Submitting a pull request We iterate fast! To avoid potential merge conflicts, it's a good idea to pull from the main project before making a change and submitting a pull request. The easiest way to do this is setup a remote called `upstream` and do a pull before working on a change: From c5af8e95c13dd5cc7f2e574e10d90c2da15f6485 Mon Sep 17 00:00:00 2001 From: Yvonne Yip Date: Thu, 1 Aug 2013 18:44:27 -0700 Subject: [PATCH 04/18] polymer-overlay: use polymer-scope=controller --- polymer-overlay/polymer-overlay.css | 9 +++++++++ polymer-overlay/polymer-overlay.html | 5 ++++- 2 files changed, 13 insertions(+), 1 deletion(-) diff --git a/polymer-overlay/polymer-overlay.css b/polymer-overlay/polymer-overlay.css index 821b061..ef3c3f4 100644 --- a/polymer-overlay/polymer-overlay.css +++ b/polymer-overlay/polymer-overlay.css @@ -129,3 +129,12 @@ We address this by using script based positioning =( animation-name: polymer-overlay-shakeFadeOut; } } + +.backdrop { + position: fixed; + left: 0; + top: 0; + bottom: 0; + right: 0; + background: rgba(0, 0, 0, 0.25); +} diff --git a/polymer-overlay/polymer-overlay.html b/polymer-overlay/polymer-overlay.html index 08587c9..d1264ce 100644 --- a/polymer-overlay/polymer-overlay.html +++ b/polymer-overlay/polymer-overlay.html @@ -71,8 +71,8 @@ --> - + From 6a3743bfe58c3711f6cca493023fd23dbe226511 Mon Sep 17 00:00:00 2001 From: frankiefu Date: Mon, 5 Aug 2013 19:13:41 -0700 Subject: [PATCH 12/18] fix missing () --- polymer-localstorage/polymer-localstorage.html | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/polymer-localstorage/polymer-localstorage.html b/polymer-localstorage/polymer-localstorage.html index 4c2002c..37809cd 100644 --- a/polymer-localstorage/polymer-localstorage.html +++ b/polymer-localstorage/polymer-localstorage.html @@ -89,6 +89,6 @@ } } }); - }); + })(); From 18ba97d8e8725c41de3dfe0e6abd13941ad7e0f4 Mon Sep 17 00:00:00 2001 From: Yvonne Yip Date: Fri, 2 Aug 2013 12:18:29 -0700 Subject: [PATCH 13/18] polymer-overlay: fix for polyfill --- polymer-overlay/polymer-overlay.css | 38 ++++++++++++++++++++++++++++ polymer-overlay/polymer-overlay.html | 4 +-- 2 files changed, 40 insertions(+), 2 deletions(-) diff --git a/polymer-overlay/polymer-overlay.css b/polymer-overlay/polymer-overlay.css index 73790d3..92c575a 100644 --- a/polymer-overlay/polymer-overlay.css +++ b/polymer-overlay/polymer-overlay.css @@ -130,6 +130,44 @@ We address this by using script based positioning =( } } +.polymer-overlay { + position: fixed; + z-index: 10; + outline: none; + display: none; + opacity: 0.99; + -webkit-transition: opacity 0.001s; + transition: opacity 0.001s; +} + +/* + The revealed class exists because it's necessary to 'show' a node + before applying a transition. When an overlay is opened, it is + immediately revealed (display: block) and then asynchronously the + opened or closing classes are added. + + Because we don't want to actually show the node before a transition + or animation is applied, when the node is + revealed, it is made display: block but visibility: hidden. + It is then made visibility: visible when it is opened. +*/ + +.revealed { + display: block; + visibility: hidden; +} + +.revealed.opened { + opacity: 1; + display: block; + visibility: visible; +} + +.revealed.closing { + display: block; + visibility: visible; +} + .backdrop { position: fixed; left: 0; diff --git a/polymer-overlay/polymer-overlay.html b/polymer-overlay/polymer-overlay.html index d1264ce..e6bf97d 100644 --- a/polymer-overlay/polymer-overlay.html +++ b/polymer-overlay/polymer-overlay.html @@ -256,10 +256,10 @@ continueRenderOpened: function() { this.target.classList.toggle('opened', this.opened); this.target.classList.toggle('closing', !this.opened); - //this.animating = this.asyncMethod('completeOpening', null, this.timeout); + this.animating = this.asyncMethod('completeOpening', null, this.timeout); }, completeOpening: function() { - //clearTimeout(this.animating); + clearTimeout(this.animating); this.animating = null; this.target.classList.remove('closing'); this.target.classList.toggle('revealed', this.opened); From 52088953374af0220b0cdf7af742131465055798 Mon Sep 17 00:00:00 2001 From: Yvonne Yip Date: Mon, 5 Aug 2013 21:34:44 -0700 Subject: [PATCH 14/18] polymer-grid: allow external items --- polymer-list/polymer-grid.html | 28 +++++++++++++++------------- 1 file changed, 15 insertions(+), 13 deletions(-) diff --git a/polymer-list/polymer-grid.html b/polymer-list/polymer-grid.html index e398108..4dfc977 100644 --- a/polymer-list/polymer-grid.html +++ b/polymer-list/polymer-grid.html @@ -94,7 +94,7 @@ - + From ea120c637c6493a9259278615c032f2e42650f76 Mon Sep 17 00:00:00 2001 From: frankiefu Date: Tue, 6 Aug 2013 11:18:59 -0700 Subject: [PATCH 17/18] adjust tests since polymer-selector now adds tap listener after ready() --- test/html/polymer-selector-activate-event.html | 1 + test/html/polymer-selector-multi.html | 14 ++++++++------ 2 files changed, 9 insertions(+), 6 deletions(-) diff --git a/test/html/polymer-selector-activate-event.html b/test/html/polymer-selector-activate-event.html index 6184095..55e3c7b 100644 --- a/test/html/polymer-selector-activate-event.html +++ b/test/html/polymer-selector-activate-event.html @@ -31,6 +31,7 @@ assert.equal(s.selected, 1); done(); }); + Platform.flush(); assert.equal(s.selected, 0); s.children[1].dispatchEvent(new CustomEvent('tap', {bubbles: true})); }); diff --git a/test/html/polymer-selector-multi.html b/test/html/polymer-selector-multi.html index 066fb88..bd49877 100644 --- a/test/html/polymer-selector-multi.html +++ b/test/html/polymer-selector-multi.html @@ -39,14 +39,16 @@ eventCounter++; } }); - s.selected = [0, 2]; setTimeout(function() { - assert.equal(eventCounter, 2); - assert.isTrue(s.children[0].classList.contains('polymer-selected')); - assert.isTrue(s.children[2].classList.contains('polymer-selected')); - done(); + s.selected = [0, 2]; + Platform.flush(); + setTimeout(function() { + assert.equal(eventCounter, 2); + assert.isTrue(s.children[0].classList.contains('polymer-selected')); + assert.isTrue(s.children[2].classList.contains('polymer-selected')); + done(); + }.bind(this), 0); }.bind(this), 0); - }); From 6b089762fd7a90357d65de88d50c0e628b0df0a2 Mon Sep 17 00:00:00 2001 From: frankiefu Date: Wed, 7 Aug 2013 13:03:54 -0700 Subject: [PATCH 18/18] add missing import and move isContainer to prototype --- polymer-flex-layout/polymer-flex-panel.html | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/polymer-flex-layout/polymer-flex-panel.html b/polymer-flex-layout/polymer-flex-panel.html index 2551312..9411452 100644 --- a/polymer-flex-layout/polymer-flex-panel.html +++ b/polymer-flex-layout/polymer-flex-panel.html @@ -3,8 +3,15 @@ Use of this source code is governed by a BSD-style license that can be found in the LICENSE file. --> - + + + +