├── .gitignore ├── .travis.yml ├── LICENSE ├── README.md ├── lib ├── at_error.html ├── at_error.js ├── at_form.html ├── at_form.js ├── at_input.html ├── at_input.js ├── at_message.html ├── at_message.js ├── at_nav_button.html ├── at_nav_button.js ├── at_oauth.html ├── at_oauth.js ├── at_polymer.css ├── at_pwd_form.html ├── at_pwd_form.js ├── at_pwd_form_btn.html ├── at_pwd_form_btn.js ├── at_pwd_link.html ├── at_pwd_link.js ├── at_reCaptcha.html ├── at_reCaptcha.js ├── at_resend_verification_email_link.html ├── at_resend_verification_email_link.js ├── at_result.html ├── at_result.js ├── at_sep.html ├── at_sep.js ├── at_signin_link.html ├── at_signin_link.js ├── at_signup_link.html ├── at_signup_link.js ├── at_social.html ├── at_social.js ├── at_terms_link.html ├── at_terms_link.js ├── at_title.html ├── at_title.js └── full_page_at_form.html ├── package.js └── tests └── tests.js /.gitignore: -------------------------------------------------------------------------------- 1 | .build* 2 | versions.json 3 | .versions 4 | -------------------------------------------------------------------------------- /.travis.yml: -------------------------------------------------------------------------------- 1 | sudo: required 2 | language: node_js 3 | node_js: 4 | - "0.10" 5 | before_install: 6 | - "curl -L http://git.io/ejPSng | /bin/sh" 7 | env: 8 | - TEST_COMMAND=meteor 9 | -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- 1 | The MIT License (MIT) 2 | 3 | Copyright (c) 2014 splendido 4 | 5 | Permission is hereby granted, free of charge, to any person obtaining a copy 6 | of this software and associated documentation files (the "Software"), to deal 7 | in the Software without restriction, including without limitation the rights 8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 9 | copies of the Software, and to permit persons to whom the Software is 10 | furnished to do so, subject to the following conditions: 11 | 12 | The above copyright notice and this permission notice shall be included in all 13 | copies or substantial portions of the Software. 14 | 15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 21 | SOFTWARE. -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | [![Meteor Icon](http://icon.meteor.com/package/useraccounts:polymer)](https://atmospherejs.com/useraccounts/polymer) 2 | [![Build Status](https://travis-ci.org/meteor-useraccounts/polymer.svg?branch=master)](https://travis-ci.org/meteor-useraccounts/polymer) 3 | 4 | useraccounts:polymer 5 | ===================================== 6 | 7 | WORK IN PROGRESS - let us know about any problem you might encounter ;) 8 | 9 | ## TODOs 10 | 11 | - Add keyboard events so enter submits the form 12 | 13 | This package depends on [useraccounts:core](https://atmospherejs.com/useraccounts/core) 14 | 15 | Learn more [here](http://useraccounts.meteor.com) or have a look at the full [documentation](https://github.com/meteor-useraccounts/core). 16 | 17 | 18 | ## Bring Your Own Polymer 19 | 20 | Adding this package with `meteor add useraccounts:polymer` does not add any other packages providing Polymer. This is to let you choose the flavour you prefer! Or using an Atmosphere package, or straight up with bower! 21 | 22 | 23 | ## ADD theses imports manually 24 | 25 | This package does not automatically add the imports for the elements needed. If you don't have them imported already you should include these imports: 26 | 27 | ```HTML 28 | 29 | 30 | 31 | 32 | 33 | ``` 34 | 35 | ## Contributing 36 | 37 | Anyone is welcome to contribute. Fork, make your changes, and then submit a pull request. 38 | 39 | Thanks to all those who have contributed code changes to [this package](https://github.com/meteor-useraccounts/unstyled/graphs/contributors) as well as to the [core package](https://github.com/meteor-useraccounts/core/graphs/contributors) and all who have helped by submitting bug reports and feature ideas. 40 | -------------------------------------------------------------------------------- /lib/at_error.html: -------------------------------------------------------------------------------- 1 | 8 | -------------------------------------------------------------------------------- /lib/at_error.js: -------------------------------------------------------------------------------- 1 | // Simply 'inherites' helpers from AccountsTemplates 2 | Template.atError.helpers(AccountsTemplates.atErrorHelpers); -------------------------------------------------------------------------------- /lib/at_form.html: -------------------------------------------------------------------------------- 1 | 40 | -------------------------------------------------------------------------------- /lib/at_form.js: -------------------------------------------------------------------------------- 1 | // Simply 'inherites' helpers from AccountsTemplates 2 | Template.atForm.helpers(AccountsTemplates.atFormHelpers); -------------------------------------------------------------------------------- /lib/at_input.html: -------------------------------------------------------------------------------- 1 | 4 | 5 | 32 | 33 | 40 | 41 | 52 | 53 | 63 | 64 | 67 | -------------------------------------------------------------------------------- /lib/at_input.js: -------------------------------------------------------------------------------- 1 | _.each(AccountsTemplates.atInputRendered, function(callback){ 2 | Template.atInput.onRendered(callback); 3 | Template.atHiddenInput.onRendered(callback); 4 | }); 5 | 6 | // Simply 'inherites' helpers from AccountsTemplates 7 | Template.atInput.helpers(AccountsTemplates.atInputHelpers); 8 | 9 | // Simply 'inherites' events from AccountsTemplates 10 | Template.atInput.events(AccountsTemplates.atInputEvents); 11 | 12 | // Simply 'inherites' helpers from AccountsTemplates 13 | Template.atTextInput.helpers(AccountsTemplates.atInputHelpers); 14 | 15 | // Simply 'inherites' helpers from AccountsTemplates 16 | Template.atCheckboxInput.helpers(AccountsTemplates.atInputHelpers); 17 | 18 | // Simply 'inherites' helpers from AccountsTemplates 19 | Template.atSelectInput.helpers(AccountsTemplates.atInputHelpers); 20 | 21 | // Simply 'inherites' helpers from AccountsTemplates 22 | Template.atRadioInput.helpers(AccountsTemplates.atInputHelpers); 23 | 24 | // Simply 'inherites' helpers from AccountsTemplates 25 | Template.atHiddenInput.helpers(AccountsTemplates.atInputHelpers); 26 | -------------------------------------------------------------------------------- /lib/at_message.html: -------------------------------------------------------------------------------- 1 | 6 | -------------------------------------------------------------------------------- /lib/at_message.js: -------------------------------------------------------------------------------- 1 | // Simply 'inherites' helpers from AccountsTemplates 2 | Template.atMessage.helpers(AccountsTemplates.atMessageHelpers); 3 | -------------------------------------------------------------------------------- /lib/at_nav_button.html: -------------------------------------------------------------------------------- 1 | 5 | -------------------------------------------------------------------------------- /lib/at_nav_button.js: -------------------------------------------------------------------------------- 1 | // Simply 'inherites' helpers from AccountsTemplates 2 | Template.atNavButton.helpers(AccountsTemplates.atNavButtonHelpers); 3 | 4 | // Simply 'inherites' events from AccountsTemplates 5 | Template.atNavButton.events(AccountsTemplates.atNavButtonEvents); -------------------------------------------------------------------------------- /lib/at_oauth.html: -------------------------------------------------------------------------------- 1 | 8 | -------------------------------------------------------------------------------- /lib/at_oauth.js: -------------------------------------------------------------------------------- 1 | // Simply 'inherites' helpers from AccountsTemplates 2 | Template.atOauth.helpers(AccountsTemplates.atOauthHelpers); -------------------------------------------------------------------------------- /lib/at_polymer.css: -------------------------------------------------------------------------------- 1 | #at-google { 2 | background-color: #dd4b39; 3 | color: white; 4 | } 5 | 6 | .at-error { 7 | color: #db4437; 8 | } 9 | 10 | .at-form { 11 | flex-basis: 400px; 12 | padding: 16px; 13 | } 14 | 15 | .at-btn { 16 | background-color: #4285f4; 17 | color: white; 18 | } 19 | 20 | .at-btn.submit { 21 | margin-top: 8px; 22 | } 23 | 24 | .at-input { 25 | width: 100%; 26 | } 27 | 28 | a paper-button { 29 | color: #4285f4; 30 | text-decoration: none; 31 | } 32 | 33 | .at-sep{ 34 | border-top: 1px solid #e0e0e0; 35 | margin-top: 32px; 36 | padding-top: 8px; 37 | } 38 | 39 | #at-nav-button { 40 | color: white; 41 | } 42 | -------------------------------------------------------------------------------- /lib/at_pwd_form.html: -------------------------------------------------------------------------------- 1 | 17 | -------------------------------------------------------------------------------- /lib/at_pwd_form.js: -------------------------------------------------------------------------------- 1 | // Simply 'inherites' helpers from AccountsTemplates 2 | Template.atPwdForm.helpers(AccountsTemplates.atPwdFormHelpers); 3 | 4 | // Simply 'inherites' events from AccountsTemplates 5 | Template.atPwdForm.events(AccountsTemplates.atPwdFormEvents); -------------------------------------------------------------------------------- /lib/at_pwd_form_btn.html: -------------------------------------------------------------------------------- 1 | 9 | -------------------------------------------------------------------------------- /lib/at_pwd_form_btn.js: -------------------------------------------------------------------------------- 1 | // Simply 'inherites' helpers from AccountsTemplates 2 | Template.atPwdFormBtn.helpers(AccountsTemplates.atPwdFormBtnHelpers); 3 | 4 | 5 | Template.atPwdFormBtn.events = { 6 | 'click #at-btn-polymer': function(event,template) { 7 | event.preventDefault(); 8 | template.find('button[type=submit]').click(); 9 | } 10 | }; 11 | -------------------------------------------------------------------------------- /lib/at_pwd_link.html: -------------------------------------------------------------------------------- 1 | 12 | -------------------------------------------------------------------------------- /lib/at_pwd_link.js: -------------------------------------------------------------------------------- 1 | // Simply 'inherites' helpers from AccountsTemplates 2 | Template.atPwdLink.helpers(AccountsTemplates.atPwdLinkHelpers); 3 | 4 | // Simply 'inherites' events from AccountsTemplates 5 | Template.atPwdLink.events(AccountsTemplates.atPwdLinkEvents); -------------------------------------------------------------------------------- /lib/at_reCaptcha.html: -------------------------------------------------------------------------------- 1 | 4 | -------------------------------------------------------------------------------- /lib/at_reCaptcha.js: -------------------------------------------------------------------------------- 1 | // Simply 'inherites' rendered callback from AccountsTemplates 2 | Template.atReCaptcha.rendered = AccountsTemplates.atReCaptchaRendered; 3 | 4 | // Simply 'inherites' helpers from AccountsTemplates 5 | Template.atReCaptcha.helpers(AccountsTemplates.atReCaptchaHelpers); 6 | -------------------------------------------------------------------------------- /lib/at_resend_verification_email_link.html: -------------------------------------------------------------------------------- 1 | 9 | -------------------------------------------------------------------------------- /lib/at_resend_verification_email_link.js: -------------------------------------------------------------------------------- 1 | // Simply 'inherites' helpers from AccountsTemplates 2 | Template.atResendVerificationEmailLink.helpers(AccountsTemplates.atResendVerificationEmailLinkHelpers); 3 | 4 | // Simply 'inherites' events from AccountsTemplates 5 | Template.atResendVerificationEmailLink.events(AccountsTemplates.atResendVerificationEmailLinkEvents); 6 | -------------------------------------------------------------------------------- /lib/at_result.html: -------------------------------------------------------------------------------- 1 | 6 | -------------------------------------------------------------------------------- /lib/at_result.js: -------------------------------------------------------------------------------- 1 | // Simply 'inherites' helpers from AccountsTemplates 2 | Template.atResult.helpers(AccountsTemplates.atResultHelpers); -------------------------------------------------------------------------------- /lib/at_sep.html: -------------------------------------------------------------------------------- 1 | 6 | -------------------------------------------------------------------------------- /lib/at_sep.js: -------------------------------------------------------------------------------- 1 | // Simply 'inherites' helpers from AccountsTemplates 2 | Template.atSep.helpers(AccountsTemplates.atSepHelpers); -------------------------------------------------------------------------------- /lib/at_signin_link.html: -------------------------------------------------------------------------------- 1 | 12 | -------------------------------------------------------------------------------- /lib/at_signin_link.js: -------------------------------------------------------------------------------- 1 | // Simply 'inherites' helpers from AccountsTemplates 2 | Template.atSigninLink.helpers(AccountsTemplates.atSigninLinkHelpers); 3 | 4 | // Simply 'inherites' events from AccountsTemplates 5 | Template.atSigninLink.events(AccountsTemplates.atSigninLinkEvents); -------------------------------------------------------------------------------- /lib/at_signup_link.html: -------------------------------------------------------------------------------- 1 | 12 | -------------------------------------------------------------------------------- /lib/at_signup_link.js: -------------------------------------------------------------------------------- 1 | // Simply 'inherites' helpers from AccountsTemplates 2 | Template.atSignupLink.helpers(AccountsTemplates.atSignupLinkHelpers); 3 | 4 | // Simply 'inherites' events from AccountsTemplates 5 | Template.atSignupLink.events(AccountsTemplates.atSignupLinkEvents); -------------------------------------------------------------------------------- /lib/at_social.html: -------------------------------------------------------------------------------- 1 | 7 | -------------------------------------------------------------------------------- /lib/at_social.js: -------------------------------------------------------------------------------- 1 | // Simply 'inherites' helpers from AccountsTemplates 2 | Template.atSocial.helpers(AccountsTemplates.atSocialHelpers); 3 | 4 | // Simply 'inherites' events from AccountsTemplates 5 | Template.atSocial.events(AccountsTemplates.atSocialEvents); 6 | Template.atSocial.events({ 7 | 'click paper-button': AccountsTemplates.atSocialEvents["click button"] 8 | }); 9 | 10 | 11 | Template.atSocial.helpers({ 12 | iconClass: function() { 13 | var classStr = this._id; 14 | if (classStr[0] === "g" && classStr[1] === "o") 15 | classStr = "gplus"; 16 | return classStr; 17 | }, 18 | }); 19 | -------------------------------------------------------------------------------- /lib/at_terms_link.html: -------------------------------------------------------------------------------- 1 | 17 | -------------------------------------------------------------------------------- /lib/at_terms_link.js: -------------------------------------------------------------------------------- 1 | // Simply 'inherites' helpers from AccountsTemplates 2 | Template.atTermsLink.helpers(AccountsTemplates.atTermsLinkHelpers); 3 | 4 | // Simply 'inherites' events from AccountsTemplates 5 | Template.atTermsLink.events(AccountsTemplates.atTermsLinkEvents); -------------------------------------------------------------------------------- /lib/at_title.html: -------------------------------------------------------------------------------- 1 | 6 | -------------------------------------------------------------------------------- /lib/at_title.js: -------------------------------------------------------------------------------- 1 | // Simply 'inherites' helpers from AccountsTemplates 2 | Template.atTitle.helpers(AccountsTemplates.atTitleHelpers); -------------------------------------------------------------------------------- /lib/full_page_at_form.html: -------------------------------------------------------------------------------- 1 | 8 | -------------------------------------------------------------------------------- /package.js: -------------------------------------------------------------------------------- 1 | Package.describe({ 2 | summary: 'Accounts Templates for polymer', 3 | version: '1.14.2', 4 | name: 'useraccounts:polymer', 5 | git: 'https://github.com/meteor-useraccounts/polymer.git', 6 | }); 7 | 8 | Package.on_use(function(api, where) { 9 | api.versionsFrom('METEOR@1.0'); 10 | 11 | api.use([ 12 | 'templating', 13 | 'underscore', 14 | ], 'client'); 15 | 16 | api.use([ 17 | 'useraccounts:core', 18 | ], ['client', 'server']); 19 | 20 | // Requires all routing packages loads before this asking for weak dependencies. 21 | api.use('useraccounts:flow-routing@1.14.2', ['client', 'server'], {weak: true}); 22 | api.use('useraccounts:iron-routing@1.14.2', ['client', 'server'], {weak: true}); 23 | 24 | api.imply([ 25 | 'useraccounts:core@1.14.2', 26 | ], ['client', 'server']); 27 | 28 | api.add_files([ 29 | 'lib/at_error.html', 30 | 'lib/at_error.js', 31 | 'lib/at_form.html', 32 | 'lib/at_form.js', 33 | 'lib/at_input.html', 34 | 'lib/at_input.js', 35 | 'lib/at_message.html', 36 | 'lib/at_message.js', 37 | 'lib/at_nav_button.html', 38 | 'lib/at_nav_button.js', 39 | 'lib/at_oauth.html', 40 | 'lib/at_oauth.js', 41 | 'lib/at_pwd_form.html', 42 | 'lib/at_pwd_form.js', 43 | 'lib/at_pwd_form_btn.html', 44 | 'lib/at_pwd_form_btn.js', 45 | 'lib/at_pwd_link.html', 46 | 'lib/at_pwd_link.js', 47 | 'lib/at_reCaptcha.html', 48 | 'lib/at_reCaptcha.js', 49 | 'lib/at_result.html', 50 | 'lib/at_result.js', 51 | 'lib/at_sep.html', 52 | 'lib/at_sep.js', 53 | 'lib/at_signin_link.html', 54 | 'lib/at_signin_link.js', 55 | 'lib/at_signup_link.html', 56 | 'lib/at_signup_link.js', 57 | 'lib/at_social.html', 58 | 'lib/at_social.js', 59 | 'lib/at_terms_link.html', 60 | 'lib/at_terms_link.js', 61 | 'lib/at_resend_verification_email_link.html', 62 | 'lib/at_resend_verification_email_link.js', 63 | 'lib/at_title.html', 64 | 'lib/at_title.js', 65 | 'lib/full_page_at_form.html', 66 | 'lib/at_polymer.css' 67 | ], ['client']); 68 | }); 69 | 70 | Package.on_test(function(api) { 71 | api.use([ 72 | 'useraccounts:polymer', 73 | 'useraccounts:core@1.14.2', 74 | ]); 75 | 76 | api.use([ 77 | 'accounts-password', 78 | 'tinytest', 79 | 'test-helpers' 80 | ], ['client', 'server']); 81 | 82 | api.add_files([ 83 | 'tests/tests.js' 84 | ], ['client', 'server']); 85 | }); 86 | -------------------------------------------------------------------------------- /tests/tests.js: -------------------------------------------------------------------------------- 1 | 2 | // TODO: write tests!!! --------------------------------------------------------------------------------