Skip to content

Commit

Permalink
1.8.0: Upgrade to Polymer 1.8.0
Browse files Browse the repository at this point in the history
  • Loading branch information
Download committed Feb 25, 2017
1 parent 2773add commit 38a5838
Show file tree
Hide file tree
Showing 525 changed files with 96,017 additions and 25,385 deletions.
1,586 changes: 793 additions & 793 deletions README.md

Large diffs are not rendered by default.

8 changes: 2 additions & 6 deletions bower.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "polymer-cdn",
"version": "1.7.0.2",
"version": "1.8.0",
"main": "polymer.js",
"homepage": "https://github.com/Download/polymer-cdn",
"authors": [
Expand Down Expand Up @@ -30,10 +30,6 @@
"app-elements": "polymerelements/app-elements#latest",
"google-web-components": "GoogleWebComponents/google-web-components#latest",
"molecules": "polymerelements/molecules#latest",
"polymerfire": "firebase/polymerfire#0.10.2"
},
"resolutions": {
"polymerfire": "0.10.2",
"firebase": ">= 3.5.1 < 4.0"
"polymerfire": "firebase/polymerfire#latest"
}
}
13 changes: 7 additions & 6 deletions lib/app-elements/.bower.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "app-elements",
"version": "0.10.0",
"version": "0.10.1",
"homepage": "https://github.com/PolymerElements/app-elements",
"authors": [
"The Polymer Authors"
Expand All @@ -11,7 +11,8 @@
"keywords": [
"web-components",
"polymer",
"app"
"app",
"element-collection"
],
"license": "http://polymer.github.io/LICENSE.txt",
"private": true,
Expand All @@ -24,16 +25,16 @@
],
"dependencies": {
"app-layout": "PolymerElements/app-layout#^0.10.0",
"app-localize-behavior": "PolymerElements/app-localize-behavior#^0.9.0",
"app-localize-behavior": "PolymerElements/app-localize-behavior#^0.10.0",
"app-pouchdb": "PolymerElements/app-pouchdb#^0.9.0",
"app-route": "PolymerElements/app-route#^0.9.0",
"app-storage": "PolymerElements/app-storage#^0.9.0"
},
"_release": "0.10.0",
"_release": "0.10.1",
"_resolution": {
"type": "version",
"tag": "v0.10.0",
"commit": "75855bc1478e03442376250b3d01c0cfc92fd8b5"
"tag": "v0.10.1",
"commit": "e06b2f179425b8b2c4361d9f54186c16d9024251"
},
"_source": "git://github.com/polymerelements/app-elements.git",
"_target": "*",
Expand Down
2 changes: 1 addition & 1 deletion lib/app-elements/app-elements.html
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
<link rel="import" href="../app-pouchdb/app-pouchdb-conflict-resolution.html">
<link rel="import" href="../app-pouchdb/app-pouchdb-sync.html">
<link rel="import" href="../app-storage/app-network-status-behavior.html">
<link rel="import" href="../app-storage/app-localstorage-document/app-localstorage-document.html">
<link rel="import" href="../app-storage/app-localstorage/app-localstorage-document.html">
<link rel="import" href="../app-storage/app-indexeddb-mirror/app-indexeddb-mirror.html">
<link rel="import" href="../app-route/app-location.html">
<link rel="import" href="../app-route/app-route.html">
7 changes: 4 additions & 3 deletions lib/app-elements/bower.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "app-elements",
"version": "0.10.0",
"version": "0.10.1",
"homepage": "https://github.com/PolymerElements/app-elements",
"authors": [
"The Polymer Authors"
Expand All @@ -11,7 +11,8 @@
"keywords": [
"web-components",
"polymer",
"app"
"app",
"element-collection"
],
"license": "http://polymer.github.io/LICENSE.txt",
"private": true,
Expand All @@ -24,7 +25,7 @@
],
"dependencies": {
"app-layout": "PolymerElements/app-layout#^0.10.0",
"app-localize-behavior": "PolymerElements/app-localize-behavior#^0.9.0",
"app-localize-behavior": "PolymerElements/app-localize-behavior#^0.10.0",
"app-pouchdb": "PolymerElements/app-pouchdb#^0.9.0",
"app-route": "PolymerElements/app-route#^0.9.0",
"app-storage": "PolymerElements/app-storage#^0.9.0"
Expand Down
8 changes: 4 additions & 4 deletions lib/app-layout/.bower.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "app-layout",
"version": "0.10.5",
"version": "0.10.7",
"description": "A set of layout elements for your app",
"authors": [
"The Polymer Authors"
Expand Down Expand Up @@ -42,11 +42,11 @@
},
"ignore": [],
"private": true,
"_release": "0.10.5",
"_release": "0.10.7",
"_resolution": {
"type": "version",
"tag": "v0.10.5",
"commit": "df716eeaca72fb44608dc7032ec3c601af6e405b"
"tag": "v0.10.7",
"commit": "a28a9ac9e5937ac1bab83939f00256d232c91b65"
},
"_source": "git://github.com/PolymerElements/app-layout.git",
"_target": "^0.10.0",
Expand Down
23 changes: 12 additions & 11 deletions lib/app-layout/.travis.yml
Original file line number Diff line number Diff line change
@@ -1,22 +1,23 @@
language: node_js
sudo: required
dist: trusty
node_js: stable
node_js: '6'
addons:
sauce_connect: true
firefox: '46.0'
firefox: latest
apt:
sources:
- google-chrome
- google-chrome
packages:
- google-chrome-stable
- google-chrome-stable
before_script:
- npm install -g bower polylint web-component-tester
- bower install
- npm install -g bower polylint web-component-tester
- bower install
script:
- xvfb-run wct
- if [ "${TRAVIS_PULL_REQUEST}" = "false" ]; then wct -s 'default'; fi
- xvfb-run wct
- 'if [ "${TRAVIS_PULL_REQUEST}" = "false" ]; then wct -s ''default''; fi'
env:
global:
- secure: aLLRRtzSz/QImXYAEO7lBZcmp8xhXH28J6HONXOboy8H2eQmie0kAG8EIL1EYw1OMomAwawvh9BMJqhJHiLg23h6+asXdEaYefF+QDKIKh11dCZFUPJ71DAwKOLQpL+3D4iV/Wmndr4dIEGASCUdPufoBbmG1ZVY5dGkQYG8TO7mAOwzCciPNRaHws5fkMhWbm+tzWCDrIoMOWKDBZiAk4Rm7pXQ7c+Vnr07R0qrWlsCuiaMMc9J34q0bqrzmnV+EWjqKHXzhv1hJEbKHvO73cJorwtdpkeqLi1UsdkDCBuA8soxLSicCcpFe7eMkpr9WrbuJZ5QOEVlq+qb3aW9tH5wABiXSL4K8J7otvaXgRIaTg6i5pRGrivmNAOS6YXzT7oQAdmfFxHSpUr4OeV3Nvm9Ik7p8sOLHMGj4Eo00djjPtbO9MutF3CBLvYuEmdfa0BRXe3WqeJdaCVyYiMAPG7lYqz+aNAl6O4qAVRLMzXIRl/+vF2cso/rG7SsZORSuMk34NZhdXiH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MpJiEPs70CLXdx8Q7psX56RKjDHunFpXf5M4/SQIEmVFVi2PLoUymWlpvdBc=
84 changes: 70 additions & 14 deletions lib/app-layout/README.md
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
# App Layout [![Build Status](https://travis-ci.org/PolymerElements/app-layout.svg?branch=master)](https://travis-ci.org/PolymerElements/app-layout) [![Published on webcomponents.org](https://img.shields.io/badge/webcomponents.org-published-blue.svg)](https://beta.webcomponents.org/element/PolymerElements/app-layout)

[<img src="https://app-layout-assets.appspot.com/assets/docs/app-layout.png" width="300" height="210">](https://polymerelements.github.io/app-layout/)
A collection of elements, along with guidelines and templates that can be used to structure your app’s layout.

<!---
```
<custom-element-demo>
<custom-element-demo height="368">
<template>
<script src="../webcomponentsjs/webcomponents-lite.min.js"></script>
<link rel="import" href="app-drawer/app-drawer.html">
Expand All @@ -15,15 +15,22 @@
<link rel="import" href="../paper-icon-button/paper-icon-button.html">
<link rel="import" href="../paper-progress/paper-progress.html">
<style is="custom-style">
body {
html, body {
margin: 0;
font-family: 'Roboto', 'Noto', sans-serif;
-webkit-font-smoothing: antialiased;
background: #f1f1f1;
max-height: 368px;
}
app-toolbar {
background-color: #4285f4;
color: #fff;
}
paper-icon-button {
--paper-icon-button-ink-color: white;
}
paper-icon-button + [main-title] {
margin-left: 24px;
}
Expand All @@ -46,6 +53,9 @@
background-color: #B0BEC5;
}
}
sample-content {
padding-top: 64px;
}
</style>
<next-code-block></next-code-block>
</template>
Expand All @@ -67,11 +77,21 @@
<sample-content size="10"></sample-content>
```

https://polymerelements.github.io/app-layout/
## Install

```bash
$ bower install PolymerElements/app-layout --save
```

## Import

```html
<link rel="import" href="/bower_components/app-layout/app-layout.html">
```

For additional documentation, please check out [Responsive app layout](https://www.polymer-project.org/1.0/toolbox/app-layout).
## What is inside

A set of layout elements for your app. It includes:
### Elements

- [app-box](/app-box) - A container element that can have scroll effects - visual effects based on scroll position.

Expand All @@ -89,14 +109,50 @@ A set of layout elements for your app. It includes:

- [app-toolbar](/app-toolbar) - A horizontal toolbar containing items that can be used for label, navigation, search and actions.

### Install
### Templates

```bash
$ bower install PolymerElements/app-layout --save
```
The templates are a means to define, illustrate and share best practices in App Layout. Pick a template and customize it:

### Import
- **Getting started**
([Demo](https://polymerelements.github.io/app-layout/templates/getting-started) - [Source](/templates/getting-started))

```html
<link rel="import" href="/bower_components/app-layout/app-layout.html">
```
- **Landing page**
([Demo](https://polymerelements.github.io/app-layout/templates/landing-page) - [Source](/templates/landing-page))

- **Publishing: Zuperkülblog**
([Demo](https://polymerelements.github.io/app-layout/templates/publishing) - [Source](/templates/publishing))

- **Shop: Shrine**
([Demo](https://polymerelements.github.io/app-layout/templates/shrine) - [Source](/templates/shrine))

- **Blog: Pesto**
([Demo](https://polymerelements.github.io/app-layout/templates/pesto) - [Source](/templates/pesto))

- **Scroll effects: Test drive**
([Demo](https://polymerelements.github.io/app-layout/templates/test-drive) - [Source](/templates/test-drive))

### Patterns

Sample code for various UI patterns:

- **Transform navigation:**
As more screen space is available, side navigation can transform into tabs.
([Demo](https://polymerelements.github.io/app-layout/patterns/transform-navigation/index.html) - [Source](/patterns/transform-navigation/x-app.html))

- **Expand Card:**
Content cards may expand to take up more horizontal space.
([Demo](https://polymerelements.github.io/app-layout/patterns/expand-card/index.html) - [Source](/patterns/expand-card/index.html))

## Users

Here are some web apps built with App Layout:

- [Google I/O 2016](https://events.google.com/io2016/)
- [Polymer summit](https://www.polymer-project.org/summit)
- [Pica](https://frankiefu.github.io/pica/)

## Tools and References

- [Responsive App Layout](https://www.polymer-project.org/1.0/toolbox/app-layout)
- [Polymer App Toolbox](https://www.polymer-project.org/1.0/toolbox/)
- [Material Design Adaptive UI Pattern](https://www.google.com/design/spec/layout/adaptive-ui.html#adaptive-ui-patterns)
53 changes: 26 additions & 27 deletions lib/app-layout/app-drawer/app-drawer.html
Original file line number Diff line number Diff line change
Expand Up @@ -236,6 +236,14 @@
noFocusTrap: {
type: Boolean,
value: false
},

/**
* Disables swiping on the drawer.
*/
disableSwipe: {
type: Boolean,
value: false
}
},

Expand Down Expand Up @@ -265,14 +273,6 @@
Polymer.RenderStatus.afterNextRender(this, function() {
this._styleTransitionDuration(this.transitionDuration);
this._boundEscKeydownHandler = this._escKeydownHandler.bind(this);
this._resetDrawerState();

// contentContainer will transition on opened state changed, and scrim will
// transition on persistent state changed when opened - these are the
// transitions we are interested in.
this.$.scrim.addEventListener('transitionend', this._transitionend.bind(this));
this.$.contentContainer.addEventListener('transitionend', this._transitionend.bind(this));

this.addEventListener('keydown', this._tabKeydownHandler.bind(this))

// Only listen for horizontal track so you can vertically scroll inside the drawer.
Expand Down Expand Up @@ -353,7 +353,7 @@
},

_track: function(event) {
if (this.persistent) {
if (this.persistent || this.disableSwipe) {
return;
}

Expand Down Expand Up @@ -429,8 +429,9 @@
}

if (isInEndState) {
// Reset drawer state now since there will be no transitionend event.
this._resetDrawerState();
this.debounce('_resetDrawerState', this._resetDrawerState);
} else {
this.debounce('_resetDrawerState', this._resetDrawerState, this.transitionDuration);
}

this._styleTransitionDuration(this.transitionDuration);
Expand Down Expand Up @@ -502,21 +503,12 @@

// Calculate the amount of time needed to finish the transition based on the
// initial slope of the timing function.
this._styleTransitionDuration(this._FLING_INITIAL_SLOPE * dx / velocity);
var t = this._FLING_INITIAL_SLOPE * dx / velocity
this._styleTransitionDuration(t);
this._styleTransitionTimingFunction(this._FLING_TIMING_FUNCTION);

this._resetDrawerTranslate();
},

_transitionend: function() {
// If the drawer was flinging, we need to reset the style attributes.
if (this._drawerState === this._DRAWER_STATE.FLINGING) {
this._styleTransitionDuration(this.transitionDuration);
this._styleTransitionTimingFunction('');
this.style.visibility = '';
}

this._resetDrawerState();
this.debounce('_resetDrawerState', this._resetDrawerState, t);
},

_styleTransitionDuration: function(duration) {
Expand Down Expand Up @@ -551,6 +543,14 @@

_resetDrawerState: function() {
var oldState = this._drawerState;

// If the drawer was flinging, we need to reset the style attributes.
if (oldState === this._DRAWER_STATE.FLINGING) {
this._styleTransitionDuration(this.transitionDuration);
this._styleTransitionTimingFunction('');
this.style.visibility = '';
}

if (this.opened) {
this._drawerState = this.persistent ?
this._DRAWER_STATE.OPENED_PERSISTENT : this._DRAWER_STATE.OPENED;
Expand Down Expand Up @@ -637,10 +637,9 @@
},

_openedPersistentChanged: function() {
if (this.transitionDuration === 0) {
// Reset drawer state now since there will be no transitionend event.
this._resetDrawerState();
}
// Use a debounce timer instead of transitionend since transitionend won't fire when
// app-drawer is display: none.
this.debounce('_resetDrawerState', this._resetDrawerState, this.transitionDuration);
},

_MIN_FLING_THRESHOLD: 0.2,
Expand Down
Loading

0 comments on commit 38a5838

Please sign in to comment.