mirror of
https://github.com/vale981/accounts-ui
synced 2025-03-04 17:31:41 -05:00
Merge pull request #3 from studiointeract/master
Update changes from soruce
This commit is contained in:
commit
d17467ada1
5 changed files with 26 additions and 7 deletions
|
@ -50,7 +50,7 @@ session@1.1.5
|
|||
softwarerero:accounts-t9n@1.3.3
|
||||
spacebars@1.0.11
|
||||
spacebars-compiler@1.0.11
|
||||
std:accounts-ui@1.2.6
|
||||
std:accounts-ui@1.2.9
|
||||
tmeasday:check-npm-versions@0.3.0
|
||||
tracker@1.0.13
|
||||
ui@1.0.11
|
||||
|
|
13
CHANGELOG.md
13
CHANGELOG.md
|
@ -1,5 +1,18 @@
|
|||
# ChangeLog
|
||||
|
||||
### v1.2.9
|
||||
10-November-2016
|
||||
|
||||
* #73 – in constructor, we should use `props` and not `this.props`
|
||||
* #78 – Move react packages to peerDependencies
|
||||
* Added support for React Router Link in buttons.
|
||||
|
||||
### v1.2.8
|
||||
26-October-2016
|
||||
|
||||
* #70 – Added link to new material UI package.
|
||||
* #71 – make sure nextProps.formState actually exists before overwriting state
|
||||
|
||||
### v1.2.7
|
||||
19-October-2016
|
||||
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
# React Accounts UI
|
||||
|
||||
Current version 1.2.6
|
||||
Current version 1.2.9
|
||||
|
||||
## Features
|
||||
|
||||
|
@ -193,8 +193,8 @@ Meteor.startup( () => {
|
|||
<Router history={ browserHistory }>
|
||||
<Route path="/" component={ App }>
|
||||
<IndexRoute component={ Index } />
|
||||
<Route path="/signin" component={ Accounts.ui.LoginForm } formState={ STATES.SIGN_IN } />
|
||||
<Route path="/signup" component={ Accounts.ui.LoginForm } formState={ STATES.SIGN_UP } />
|
||||
<Route path="/signin" component={() => <Accounts.ui.LoginForm formState={STATES.SIGN_IN} />} />
|
||||
<Route path="/signup" component={() => <Accounts.ui.LoginForm formState={STATES.SIGN_UP} />} />
|
||||
<Route path="/hello/:name" component={ Hello } />
|
||||
</Route>
|
||||
<Route path="/admin" component={ App }>
|
||||
|
|
|
@ -1,5 +1,6 @@
|
|||
import React from 'react';
|
||||
import { Accounts } from 'meteor/accounts-base';
|
||||
try { import { Link } from 'react-router'; } catch(e) {}
|
||||
|
||||
export class Button extends React.Component {
|
||||
render () {
|
||||
|
@ -12,7 +13,12 @@ export class Button extends React.Component {
|
|||
onClick
|
||||
} = this.props;
|
||||
if (type == 'link') {
|
||||
return <a href={ href } className={ className } onClick={ onClick }>{ label }</a>;
|
||||
// Support React Router.
|
||||
if (Link && href) {
|
||||
return <Link to={ href } className={ className }>{ label }</Link>;
|
||||
} else {
|
||||
return <a href={ href } className={ className } onClick={ onClick }>{ label }</a>;
|
||||
}
|
||||
}
|
||||
return <button className={ className }
|
||||
type={ type }
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
Package.describe({
|
||||
name: 'std:accounts-ui',
|
||||
version: '1.2.8',
|
||||
summary: 'Accounts UI for React in Meteor 1.3',
|
||||
version: '1.2.9',
|
||||
summary: 'Accounts UI for React in Meteor 1.3+',
|
||||
git: 'https://github.com/studiointeract/accounts-ui',
|
||||
documentation: 'README.md'
|
||||
});
|
||||
|
|
Loading…
Add table
Reference in a new issue