-
Notifications
You must be signed in to change notification settings - Fork 30
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #27 from FuriosoJack/newComponents
Newcomponents
- Loading branch information
Showing
39 changed files
with
5,730 additions
and
5 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,81 @@ | ||
{ | ||
"name": "iron-form", | ||
"version": "2.2.1", | ||
"description": "Wrapper around native form that submits native and custom elements", | ||
"keywords": [ | ||
"web-components", | ||
"polymer", | ||
"form" | ||
], | ||
"authors": [ | ||
"The Polymer Authors" | ||
], | ||
"main": "iron-form.html", | ||
"private": true, | ||
"repository": { | ||
"type": "git", | ||
"url": "git://github.com/PolymerElements/iron-form.git" | ||
}, | ||
"license": "http://polymer.github.io/LICENSE.txt", | ||
"homepage": "https://github.com/PolymerElements/iron-form", | ||
"ignore": [], | ||
"dependencies": { | ||
"polymer": "Polymer/polymer#1.9 - 2", | ||
"iron-ajax": "PolymerElements/iron-ajax#1 - 2" | ||
}, | ||
"devDependencies": { | ||
"iron-component-page": "PolymerElements/iron-component-page#1 - 2", | ||
"iron-demo-helpers": "PolymerElements/iron-demo-helpers#1 - 2", | ||
"paper-button": "PolymerElements/paper-button#1 - 2", | ||
"paper-checkbox": "PolymerElements/paper-checkbox#1 - 2", | ||
"paper-dropdown-menu": "PolymerElements/paper-dropdown-menu#1 - 2", | ||
"paper-input": "PolymerElements/paper-input#1 - 2", | ||
"paper-item": "PolymerElements/paper-item#1 - 2", | ||
"paper-listbox": "PolymerElements/paper-listbox#1 - 2", | ||
"paper-spinner": "PolymerElements/paper-spinner#1 - 2", | ||
"paper-styles": "PolymerElements/paper-styles#1 - 2", | ||
"web-animations-js": "web-animations/web-animations-js#^2.2", | ||
"web-component-tester": "Polymer/web-component-tester#^6.0.0", | ||
"webcomponentsjs": "webcomponents/webcomponentsjs#^1.0.0" | ||
}, | ||
"variants": { | ||
"1.x": { | ||
"dependencies": { | ||
"polymer": "Polymer/polymer#^1.9", | ||
"iron-ajax": "PolymerElements/iron-ajax#^1.0.0" | ||
}, | ||
"devDependencies": { | ||
"iron-component-page": "PolymerElements/iron-component-page#^1.0.0", | ||
"iron-demo-helpers": "PolymerElements/iron-demo-helpers#^1.0.0", | ||
"paper-button": "PolymerElements/paper-button#^1.0.0", | ||
"paper-checkbox": "PolymerElements/paper-checkbox#^1.0.0", | ||
"paper-dropdown-menu": "PolymerElements/paper-dropdown-menu#^1.0.0", | ||
"paper-input": "PolymerElements/paper-input#^1.0.0", | ||
"paper-item": "PolymerElements/paper-item#^1.0.0", | ||
"paper-menu": "PolymerElements/paper-menu#^1.0.0", | ||
"paper-spinner": "PolymerElements/paper-spinner#^1.0.0", | ||
"paper-styles": "PolymerElements/paper-styles#^1.0.0", | ||
"test-fixture": "PolymerElements/test-fixture#^1.0.0", | ||
"web-animations-js": "web-animations/web-animations-js#^2.2", | ||
"web-component-tester": "Polymer/web-component-tester#^4.0.0", | ||
"webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" | ||
}, | ||
"resolutions": { | ||
"webcomponentsjs": "^0.7" | ||
} | ||
} | ||
}, | ||
"resolutions": { | ||
"webcomponentsjs": "^1.0.0" | ||
}, | ||
"_release": "2.2.1", | ||
"_resolution": { | ||
"type": "version", | ||
"tag": "v2.2.1", | ||
"commit": "6f4ab6112a21dc3a4c5fe7abb8095c48eca19e26" | ||
}, | ||
"_source": "https://github.com/PolymerElements/iron-form.git", | ||
"_target": "^2.2.1", | ||
"_originalSource": "PolymerElements/iron-form", | ||
"_direct": true | ||
} |
Validating CODEOWNERS rules …
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
* @notwaldorf | ||
/.travis.yml @azakus |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
<!-- Instructions: https://github.com/PolymerElements/iron-form/CONTRIBUTING.md#filing-issues --> | ||
### Description | ||
<!-- Example: The `paper-foo` element causes the page to turn pink when clicked. --> | ||
|
||
### Expected outcome | ||
|
||
<!-- Example: The page stays the same color. --> | ||
|
||
### Actual outcome | ||
|
||
<!-- Example: The page turns pink. --> | ||
|
||
### Live Demo | ||
<!-- Example: https://jsbin.com/cagaye/edit?html,output --> | ||
|
||
### Steps to reproduce | ||
|
||
<!-- Example | ||
1. Put a `paper-foo` element in the page. | ||
2. Open the page in a web browser. | ||
3. Click the `paper-foo` element. | ||
--> | ||
|
||
### Browsers Affected | ||
<!-- Check all that apply --> | ||
- [ ] Chrome | ||
- [ ] Firefox | ||
- [ ] Safari 9 | ||
- [ ] Safari 8 | ||
- [ ] Safari 7 | ||
- [ ] Edge | ||
- [ ] IE 11 | ||
- [ ] IE 10 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
bower_components* | ||
bower-*.json | ||
node_modules |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
language: node_js | ||
sudo: required | ||
before_script: | ||
- npm install -g polymer-cli | ||
- polymer install --variants | ||
- >- | ||
npm run update-types && git diff --exit-code || (echo -e | ||
'\n\033[31mERROR:\033[0m Typings are stale. Please run "npm run | ||
update-types".' && false) | ||
env: | ||
global: | ||
- secure: >- | ||
JeSfmBNQGyT7fu9NURSHqK9miBYrieoVdCnzOIq1QRDpWEiUGJKrcWKbabA/1MrlYfbQDFwXIDGrv0hcZzf0xbDblo5s/jUnep1vq/w/IRznEDnhJelpjG6c38vlBbPQOZI3L32eu8w5BBmlXhc4XXpUGkIy94O1Iz7Tn3zkeFI/fKhMyrmgDUOuehP0EHyoKxLCyWGLV+aTRtif6TK/wn6ULwM+GvLiS7nykrnA2WoDEECAuCoIsfRD9UFoLH4dNmOoiEHGeSx3rL6aE0TV9GVpPpBkL6qe8LFJLV4GJsekVyeOnKlekbzts8joIrR62P9m2BHZMQkizyx6Tj22vF6uXI8HAvocNIbijiJPSKFRA2Ir6ZAtBKPFMv73upROSvzqT+8UjW4DM9EDQiheCZ+Hkv0cQqtSmmiS3GxrTxW622lKdg2uVbD2qH2Ac2wJNGztukKtAyR2wSyjD7R/wE2MiQrT2YlGw95aMMqVylF1CtXoUJWGXUdfT6NZ7WCjbRj3fwABBY6BT+bJioIolHORdY6QbFUJ8GASqHqYlZShd23JtM5LJeDyJrJ4oEWNJ7q+jYl5xN7zwy/W0H86bn+6JX/Lxq71kvkohpzAHwSWAuAANLYf7cIUZ7GBo1lUzWaSJ1SaW981jH9s87NnyBP2thJAnyr78T6UXjPFZYk= | ||
- secure: >- | ||
THJhGmuNJqLVeRfN2qJL1FKH3TXNwovC0z8G1GU4ML3pYbRL8oFw7nrtnofwgI99axLNEoJFZnkWcmkKRWlDHYX+LwQCUtYr3eW/pncrWGVBElr9HUgw6q0tY0o6v1Oe0Oj3kqxWuFkA1Kv8V7bHvB9ABT7CimwXDAC+uwP4SDqEtlVz8LAg6G74ywJaKg+S1gL8EHTIAGjeMSfKw4UjFAi6QKebJBsPOu8qmGrBSSdaLoDKhQb+kJqcLncJ0PB2AKC8zTzpxsDSwZizGDGLcbuFR1pnqTqISKgfpTVycTHJrEQwYsS6bTR7X86i3lcJ4H5dtI/HHaAQTmeT3JpvTfz5f9dvAuJVqimQOzdFlKM7ehhNk3j9KtED/vnQW9+0AJhOT9+7trokW++jl219QS29FOPYTxSo/XvI6iLZfOr4X0l4VhNkgHeE6EyCUoGNwDRxUvn+KcsQMk6JdHLY+lCckZ+tRFQIUjMPqjn9tB/MjBqtXxDhF5ZjaOcLufzuywKBzlMT4OkAiOGK9qFENKpTVaqvmRPPM1bjkZuzfTBJTOzWDznf2V4r65/s6ZRpoqEy0ozb7NjUEjYOR+OuZfKYVwT5VmAykKLNW3eQJc1zJjvhjghSIxOWH9AvD18UeQtEcv2J5pVFIp+BFVR25i0BH+efOwWJ49hk0o0N+Dw= | ||
node_js: stable | ||
addons: | ||
firefox: latest | ||
apt: | ||
sources: | ||
- google-chrome | ||
packages: | ||
- google-chrome-stable | ||
sauce_connect: true | ||
script: | ||
- xvfb-run polymer test | ||
- >- | ||
if [ "${TRAVIS_PULL_REQUEST}" = "false" ]; then polymer test -s 'default'; | ||
fi | ||
dist: trusty |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,77 @@ | ||
<!-- | ||
This file is autogenerated based on | ||
https://github.com/PolymerElements/ContributionGuide/blob/master/CONTRIBUTING.md | ||
If you edit that file, it will get updated everywhere else. | ||
If you edit this file, your changes will get overridden :) | ||
You can however override the jsbin link with one that's customized to this | ||
specific element: | ||
jsbin=https://jsbin.com/cagaye/edit?html,output | ||
--> | ||
|
||
# Polymer Elements | ||
## Guide for Contributors | ||
|
||
Polymer Elements are built in the open, and the Polymer authors eagerly encourage any and all forms of community contribution. When contributing, please follow these guidelines: | ||
|
||
### Filing Issues | ||
|
||
**If you are filing an issue to request a feature**, please provide a clear description of the feature. It can be helpful to describe answers to the following questions: | ||
|
||
1. **Who will use the feature?** _“As someone filling out a form…”_ | ||
2. **When will they use the feature?** _“When I enter an invalid value…”_ | ||
3. **What is the user’s goal?** _“I want to be visually notified that the value needs to be corrected…”_ | ||
|
||
**If you are filing an issue to report a bug**, please provide: | ||
|
||
1. **A clear description of the bug and related expectations.** Consider using the following example template for reporting a bug: | ||
|
||
```markdown | ||
The `paper-foo` element causes the page to turn pink when clicked. | ||
|
||
## Expected outcome | ||
|
||
The page stays the same color. | ||
|
||
## Actual outcome | ||
|
||
The page turns pink. | ||
|
||
## Steps to reproduce | ||
|
||
1. Put a `paper-foo` element in the page. | ||
2. Open the page in a web browser. | ||
3. Click the `paper-foo` element. | ||
``` | ||
|
||
2. **A reduced test case that demonstrates the problem.** If possible, please include the test case as a JSBin. Start with this template to easily import and use relevant Polymer Elements: [https://jsbin.com/cagaye/edit?html,output](https://jsbin.com/cagaye/edit?html,output). | ||
|
||
3. **A list of browsers where the problem occurs.** This can be skipped if the problem is the same across all browsers. | ||
|
||
### Submitting Pull Requests | ||
|
||
**Before creating a pull request**, please ensure that an issue exists for the corresponding change in the pull request that you intend to make. **If an issue does not exist, please create one per the guidelines above**. The goal is to discuss the design and necessity of the proposed change with Polymer authors and community before diving into a pull request. | ||
|
||
When submitting pull requests, please provide: | ||
|
||
1. **A reference to the corresponding issue** or issues that will be closed by the pull request. Please refer to these issues in the pull request description using the following syntax: | ||
|
||
```markdown | ||
(For a single issue) | ||
Fixes #20 | ||
|
||
(For multiple issues) | ||
Fixes #32, fixes #40 | ||
``` | ||
|
||
2. **A succinct description of the design** used to fix any related issues. For example: | ||
|
||
```markdown | ||
This fixes #20 by removing styles that leaked which would cause the page to turn pink whenever `paper-foo` is clicked. | ||
``` | ||
|
||
3. **At least one test for each bug fixed or feature added** as part of the pull request. Pull requests that fix bugs or add features without accompanying tests will not be considered. | ||
|
||
If a proposed change contains multiple commits, please [squash commits](https://www.google.com/url?q=http://blog.steveklabnik.com/posts/2012-11-08-how-to-squash-commits-in-a-github-pull-request) to as few as is necessary to succinctly express the change. A Polymer author can help you squash commits, so don’t be afraid to ask us if you need help with that! |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,77 @@ | ||
|
||
<!--- | ||
This README is automatically generated from the comments in these files: | ||
iron-form.html | ||
Edit those files, and our readme bot will duplicate them over here! | ||
Edit this file, and the bot will squash your changes :) | ||
The bot does some handling of markdown. Please file a bug if it does the wrong | ||
thing! https://github.com/PolymerLabs/tedium/issues | ||
--> | ||
|
||
[![Build status](https://travis-ci.org/PolymerElements/iron-form.svg?branch=master)](https://travis-ci.org/PolymerElements/iron-form) | ||
[![Published on webcomponents.org](https://img.shields.io/badge/webcomponents.org-published-blue.svg)](https://www.webcomponents.org/element/PolymerElements/iron-form) | ||
|
||
_[Demo and API docs](https://elements.polymer-project.org/elements/iron-form)_ | ||
|
||
|
||
## <iron-form> | ||
`<iron-form>` is a wrapper around the HTML `<form>` element, that can | ||
validate and submit both custom and native HTML elements. | ||
|
||
It has two modes: if `allow-redirect` is true, then after the form submission you | ||
will be redirected to the server response. Otherwise, if it is false, it will | ||
use an `iron-ajax` element to submit the form contents to the server. | ||
|
||
Example: | ||
|
||
```html | ||
<iron-form> | ||
<form method="get" action="/form/handler"> | ||
<input type="text" name="name" value="Batman"> | ||
<input type="checkbox" name="donuts" checked> I like donuts<br> | ||
<paper-checkbox name="cheese" value="yes" checked></paper-checkbox> | ||
</form> | ||
</iron-form> | ||
``` | ||
|
||
By default, a native `<button>` element (or `input type="submit"`) will submit this form. However, if you | ||
want to submit it from a custom element's click handler, you need to explicitly | ||
call the `iron-form`'s `submit` method. | ||
|
||
Example: | ||
|
||
```html | ||
<paper-button raised onclick="submitForm()">Submit</paper-button> | ||
|
||
function submitForm() { | ||
document.getElementById('iron-form').submit(); | ||
} | ||
``` | ||
|
||
### Changes in 2.0 | ||
- since type-extensions are not available in 2.0, `<iron-form>` is now a wrapper | ||
around a native `<form>` | ||
- related, since elements are now distributed to the `iron-form`, they no longer | ||
need to implement `IronFormElementBehavior` to register for submission. However | ||
they are required to have a `name` and a `value` attribute (which the behaviour | ||
also added), and to optionally implement the `validate()` method to control | ||
validation of their shadowRoot validatable elements. | ||
- the `serialize` method has been renamed to `serializeForm` (because Polymer 2.0 | ||
is already using a `serialize` method, and we can't stomp over it). | ||
- in `iron-form` 2.x, the `reset` and `submit` methods now accept an `event` as | ||
input, which will be prevented if it exists. | ||
- the `disableNativeValidationUi` property has been removed: because `iron-form` | ||
is no longer a type extension, it can't actually trigger any native UI, so | ||
this property is essentially always true. | ||
- the `contentType` property has been removed in favor of the native [`<form enctype>` | ||
attribute](https://developer.mozilla.org/en-US/docs/Web/API/HTMLFormElement/enctype); | ||
you can still use the `application/json` value e.g. | ||
```html | ||
<iron-form> | ||
<form enctype="application/json"> ... </form> | ||
</iron-form> | ||
``` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,71 @@ | ||
{ | ||
"name": "iron-form", | ||
"version": "2.1.6", | ||
"description": "Wrapper around native form that submits native and custom elements", | ||
"keywords": [ | ||
"web-components", | ||
"polymer", | ||
"form" | ||
], | ||
"authors": [ | ||
"The Polymer Authors" | ||
], | ||
"main": "iron-form.html", | ||
"private": true, | ||
"repository": { | ||
"type": "git", | ||
"url": "git://github.com/PolymerElements/iron-form.git" | ||
}, | ||
"license": "http://polymer.github.io/LICENSE.txt", | ||
"homepage": "https://github.com/PolymerElements/iron-form", | ||
"ignore": [], | ||
"dependencies": { | ||
"polymer": "Polymer/polymer#1.9 - 2", | ||
"iron-ajax": "PolymerElements/iron-ajax#1 - 2" | ||
}, | ||
"devDependencies": { | ||
"iron-component-page": "PolymerElements/iron-component-page#1 - 2", | ||
"iron-demo-helpers": "PolymerElements/iron-demo-helpers#1 - 2", | ||
"paper-button": "PolymerElements/paper-button#1 - 2", | ||
"paper-checkbox": "PolymerElements/paper-checkbox#1 - 2", | ||
"paper-dropdown-menu": "PolymerElements/paper-dropdown-menu#1 - 2", | ||
"paper-input": "PolymerElements/paper-input#1 - 2", | ||
"paper-item": "PolymerElements/paper-item#1 - 2", | ||
"paper-listbox": "PolymerElements/paper-listbox#1 - 2", | ||
"paper-spinner": "PolymerElements/paper-spinner#1 - 2", | ||
"paper-styles": "PolymerElements/paper-styles#1 - 2", | ||
"web-animations-js": "web-animations/web-animations-js#^2.2", | ||
"web-component-tester": "Polymer/web-component-tester#^6.0.0", | ||
"webcomponentsjs": "webcomponents/webcomponentsjs#^1.0.0" | ||
}, | ||
"variants": { | ||
"1.x": { | ||
"dependencies": { | ||
"polymer": "Polymer/polymer#^1.9", | ||
"iron-ajax": "PolymerElements/iron-ajax#^1.0.0" | ||
}, | ||
"devDependencies": { | ||
"iron-component-page": "PolymerElements/iron-component-page#^1.0.0", | ||
"iron-demo-helpers": "PolymerElements/iron-demo-helpers#^1.0.0", | ||
"paper-button": "PolymerElements/paper-button#^1.0.0", | ||
"paper-checkbox": "PolymerElements/paper-checkbox#^1.0.0", | ||
"paper-dropdown-menu": "PolymerElements/paper-dropdown-menu#^1.0.0", | ||
"paper-input": "PolymerElements/paper-input#^1.0.0", | ||
"paper-item": "PolymerElements/paper-item#^1.0.0", | ||
"paper-menu": "PolymerElements/paper-menu#^1.0.0", | ||
"paper-spinner": "PolymerElements/paper-spinner#^1.0.0", | ||
"paper-styles": "PolymerElements/paper-styles#^1.0.0", | ||
"test-fixture": "PolymerElements/test-fixture#^1.0.0", | ||
"web-animations-js": "web-animations/web-animations-js#^2.2", | ||
"web-component-tester": "Polymer/web-component-tester#^4.0.0", | ||
"webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" | ||
}, | ||
"resolutions": { | ||
"webcomponentsjs": "^0.7" | ||
} | ||
} | ||
}, | ||
"resolutions": { | ||
"webcomponentsjs": "^1.0.0" | ||
} | ||
} |
Oops, something went wrong.