Skip to content

Commit

Permalink
Add react scroll
Browse files Browse the repository at this point in the history
  • Loading branch information
thai321 committed Sep 27, 2017
1 parent 23929f8 commit 32fccbf
Show file tree
Hide file tree
Showing 6 changed files with 126 additions and 65 deletions.
56 changes: 33 additions & 23 deletions FrontEnd/components/user_show/user_show.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -214,36 +214,46 @@ class UserShow extends React.Component {
};

return (
<div className="container-fluid">
<div className="user-index-info">
<div className="card">
<div className="img-thumbnail">
<img className="card-img-top" src={user.image_url} />
</div>
<div className="card-block card-user-title">
<h4 className="card-title">{user.username}</h4>
{displayFollow()}
<div>
<div className="user-show-info">
<div>User informationdsfs df sf</div>
<div>User informationdsfs df sf</div>
<div>User informationdsfs df sf</div>
<div>User informationdsfs df sf</div>
<div>User informationdsfs df sf</div>
<div>User informationdsfs df sf</div>
</div>
<div className="container-fluid">
<div className="user-index-info">
<div className="card">
<div className="img-thumbnail">
<img className="card-img-top" src={user.image_url} />
</div>
<div className="card-block card-user-title">
<h4 className="card-title">{user.username}</h4>
{displayFollow()}
</div>
</div>
{displayUpload()}
</div>
<a href="/">soidjfosjdfjsfdo</a>
<div className={`project-text-user-show ${hidePublish}`}>
<h2>{publishText}</h2>
</div>
{displayUpload()}
</div>
<a href="/">soidjfosjdfjsfdo</a>
<div className={`project-text-user-show ${hidePublish}`}>
<h2>{publishText}</h2>
</div>

{this.displayProjects('Published')}
{this.displayProjects('Published')}

<div className={`project-text-user-show ${hideUnPublish}`}>
<h2>{UnpublishText}</h2>
</div>
<div className={`project-text-user-show ${hideUnPublish}`}>
<h2>{UnpublishText}</h2>
</div>

{this.displayProjects('UnPublished')}
{this.displayProjects('UnPublished')}

{this.displayFavorite()}
{this.displayFavorite()}

<FavoriteShowContainer user={user} />
<UserFollowContainer user={user} />
<FavoriteShowContainer user={user} />
<UserFollowContainer user={user} />
</div>
</div>
);
}
Expand Down
120 changes: 79 additions & 41 deletions app/assets/javascripts/bundle.js
Original file line number Diff line number Diff line change
Expand Up @@ -54064,59 +54064,97 @@ var UserShow = function (_React$Component) {

return _react2.default.createElement(
'div',
{ className: 'container-fluid' },
null,
_react2.default.createElement(
'div',
{ className: 'user-index-info' },
{ className: 'user-show-info' },
_react2.default.createElement(
'div',
{ className: 'card' },
_react2.default.createElement(
'div',
{ className: 'img-thumbnail' },
_react2.default.createElement('img', { className: 'card-img-top', src: user.image_url })
),
_react2.default.createElement(
'div',
{ className: 'card-block card-user-title' },
_react2.default.createElement(
'h4',
{ className: 'card-title' },
user.username
),
displayFollow()
)
null,
'User informationdsfs df sf'
),
_react2.default.createElement(
'div',
null,
'User informationdsfs df sf'
),
_react2.default.createElement(
'div',
null,
'User informationdsfs df sf'
),
_react2.default.createElement(
'div',
null,
'User informationdsfs df sf'
),
_react2.default.createElement(
'div',
null,
'User informationdsfs df sf'
),
displayUpload()
),
_react2.default.createElement(
'a',
{ href: '/' },
'soidjfosjdfjsfdo'
),
_react2.default.createElement(
'div',
{ className: 'project-text-user-show ' + hidePublish },
_react2.default.createElement(
'h2',
'div',
null,
publishText
'User informationdsfs df sf'
)
),
this.displayProjects('Published'),
_react2.default.createElement(
'div',
{ className: 'project-text-user-show ' + hideUnPublish },
{ className: 'container-fluid' },
_react2.default.createElement(
'h2',
null,
UnpublishText
)
),
this.displayProjects('UnPublished'),
this.displayFavorite(),
_react2.default.createElement(_favorite_show_container2.default, { user: user }),
_react2.default.createElement(_user_follow_container2.default, { user: user })
'div',
{ className: 'user-index-info' },
_react2.default.createElement(
'div',
{ className: 'card' },
_react2.default.createElement(
'div',
{ className: 'img-thumbnail' },
_react2.default.createElement('img', { className: 'card-img-top', src: user.image_url })
),
_react2.default.createElement(
'div',
{ className: 'card-block card-user-title' },
_react2.default.createElement(
'h4',
{ className: 'card-title' },
user.username
),
displayFollow()
)
),
displayUpload()
),
_react2.default.createElement(
'a',
{ href: '/' },
'soidjfosjdfjsfdo'
),
_react2.default.createElement(
'div',
{ className: 'project-text-user-show ' + hidePublish },
_react2.default.createElement(
'h2',
null,
publishText
)
),
this.displayProjects('Published'),
_react2.default.createElement(
'div',
{ className: 'project-text-user-show ' + hideUnPublish },
_react2.default.createElement(
'h2',
null,
UnpublishText
)
),
this.displayProjects('UnPublished'),
this.displayFavorite(),
_react2.default.createElement(_favorite_show_container2.default, { user: user }),
_react2.default.createElement(_user_follow_container2.default, { user: user })
)
);
}
}
Expand Down
2 changes: 1 addition & 1 deletion app/assets/javascripts/bundle.js.map

Large diffs are not rendered by default.

3 changes: 3 additions & 0 deletions app/assets/stylesheets/components/user_show.scss
Original file line number Diff line number Diff line change
Expand Up @@ -40,3 +40,6 @@
.submit-btn {
margin-left: 100px;
}

.user-show-info {
}
9 changes: 9 additions & 0 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,7 @@
"react-quill": "^1.1.0",
"react-redux": "^5.0.6",
"react-router-dom": "^4.2.2",
"react-scroll": "^1.5.4",
"redux": "^3.7.2",
"redux-logger": "^3.0.6",
"redux-thunk": "^2.2.0",
Expand Down

0 comments on commit 32fccbf

Please sign in to comment.