WikiEducationFoundation / WikiEduDashboard

Wiki Education Foundation's Wikipedia course dashboard system
https://dashboard.wikiedu.org
MIT License
392 stars 630 forks source link

Campaign > Articles table runs over container range #1883

Closed yunjuc closed 11 months ago

yunjuc commented 6 years ago

The article table under Campaign > Articles is out of the border on the live site, but looks normal on the local dev environment. https://dashboard.wikiedu.org/campaigns/spring_2018/articles

ragesoss commented 6 years ago

Hmm... I guessing it's from long course names in the last column. Maybe we can make it wrap instead?

RDenPen commented 6 years ago

I made an edit to the modules/_tables.styl file so that the td children of the .table class each had a padding of 12px 9px, which seems to pull the article table away from the edge of the screen

ragesoss commented 6 years ago

That helps a little bit just by reducing the padding between cells, but it still runs over a little bit.

I haven't been able to pin down why exactly that table isn't respecting the CSS width settings, but things like adding overflow-wrap don't seem to help.

RDenPen commented 6 years ago

trying to make the class course_title fit in the container using word-break instead of making the padding smaller on .table which hasn't had results, however adding word-break to .table makes does have effect

ragesoss commented 6 years ago

@RDenPen it looks like the main way to make sure the table fits in the container would be to use table-layout: fixed. See https://css-tricks.com/fixing-tables-long-strings/

However, it looks like it'll take a lot of tweaking to get the cell sizing working nicely with the fixed layout.

RDenPen commented 6 years ago

so I made it so the element table had a table-layout of fixed this didn't stop the articles from spilling over. I also applied word-break: break-all then the articles didn't run over the container range

siwaniagrawal commented 6 years ago

The issue has been solved? If not can I contribute to it?

ragesoss commented 6 years ago

It has not been solved and you're welcome to work on it. It's not as easy as I thought at first though.

siwaniagrawal commented 6 years ago

Well, I can give it a try :)

siwaniagrawal commented 6 years ago

articles Is this okay? Or should I make some more changes? @ragesoss

ihsavru commented 6 years ago

@siwaniagrawal The courses column looks good. It will be great if you could do the same thing to the Title column.

siwaniagrawal commented 6 years ago

Actually, I am inspecting it in the browser, Can you please guide me through the process of feeding the necessary resources so, I can recreate the same in my local.

ihsavru commented 6 years ago

@siwaniagrawal Setup the dashboard on your local machine if you haven't already. Populate your database with some courses having longer names.

siwaniagrawal commented 6 years ago

article3 I realized using text-wrap along wouldn't be enough so, had to resize the width. will this do? Or should I make some more changes?

ragesoss commented 6 years ago

@siwaniagrawal that looks nice.

siwaniagrawal commented 6 years ago

Cool, I will raise a PR after populating the DB and recreating it in my local.

Rish-av4 commented 2 years ago

I don't understand the problem statement. Like where is the problem? A little help would be appreciated.

ragesoss commented 2 years ago

The problem is that the final column of the campaign articles table extends outside the container. All the content should remain with the container with a max width of 1100px.

container

fillingtothemomo commented 11 months ago

If this issue is still open, I would like to take it. @ragesoss

ragesoss commented 11 months ago

This is fixed, I think.