-
Notifications
You must be signed in to change notification settings - Fork 2
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Font, color and margins style for Discussions UI #95
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
just a few comments on the React changes
<Link to="/">Discussions</Link> | ||
<span>></span> | ||
<Link to={`/channel/${channel.name}`}>{channel.title}</Link> | ||
{channel.title} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This should probably remain a <Link />
- we show the ChannelBreadcrumbs
component on the page for each post, so it supplies a link back to the subreddit the post is from.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
OK, that is fine.
static/js/containers/ChannelPage.js
Outdated
@@ -55,6 +56,7 @@ class ChannelPage extends React.Component { | |||
<ChannelSidebar channel={channel} /> | |||
</Card> | |||
</div> | |||
<br className="clear"/> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
is there any way we can avoid using <br />
? I just find it yucky, haha
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I am open to any solutions you can come up with, although this is in my opinion, a basic failure with the CSS model and contained floats inside divs. But I am open to any way you'd prefer to do this. I do want those divs actually contained inside the container div though.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Maybe I just don't understand what it's doing, but if I delete this element I don't see any changes in the display on the page. I'll leave it in for now if it's necessary.
I will be out today and tomorrow. @aliceriot , can you make the required changes and merge the PR? |
One further comment: The channel page UI, and the Home page both use a "Post Summary" component, that displays the Post title, post author, number of comments, and upvoting. The Post Details page is currently reusing this same component. But we should really create a different component for the Post Details page as the design is really not the same as it is on the channel/home page. |
On the |
8f9363e
to
a2399c3
Compare
Codecov Report
@@ Coverage Diff @@
## master #95 +/- ##
==========================================
+ Coverage 95.52% 95.53% +0.01%
==========================================
Files 89 89
Lines 2033 2038 +5
Branches 63 63
==========================================
+ Hits 1942 1947 +5
Misses 82 82
Partials 9 9
Continue to review full report at Codecov.
|
The post display component is identical on the channel page and the home page, and yse I did see that there is an "expanded" version. But I think the layout on the actual post page is significantly different enough to warrant a different component and different html. The # of comments is down below, next to the comments UI, the upvoting is in a different location, etc |
About using the break with class="clear"... yes it is a workaround. And I think you might not see any visual changes on the page. But the two floated divs are not actually contained inside the container div. I do want to have that working,as I think, otherwise, we will not be able to apply box property rules to the container etc. |
it seems like setting |
I'll leave it as-is for now and we can discuss when you're in |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
look good functionally, but noted one thing:
static/js/components/PostDisplay.js
Outdated
@@ -46,19 +44,23 @@ export default class PostDisplay extends React.Component { | |||
return ( | |||
<div className="post-summary"> | |||
<div className="upvotes"> | |||
<button> ⇑</button> | |||
<img className="upvote-arrow" src="/static/images/upvote_arrow.png" /> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is there a reason for the move away from a <button>
? This has accessibility issues and has no native disabled
behavior (which is something I'm doing in #93, which will merge soon too).
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
let's defer to what you have in #93 for now
b23e5b0
to
ef71a7a
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
👍 when tests pass
This adjusts styles on a few things, mainly tweaking colors and adjusting layout / margins. It also: - adds a title prop to `<Card />`, which will add a consistently formatted title - does some CSS cleanup / reorganization
ef71a7a
to
e4130ad
Compare
What are the relevant tickets?
This is the First round of style changes for the discussions. I am going to submit small incremental PRs as I go along with this.
What's this PR do?
Sets some of the basic colors, fonts, etc for discussions.
What Issue is this related to
#85