-
-
Notifications
You must be signed in to change notification settings - Fork 150
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
feat(templates): Profile tables are now responsive with accordion in smaller screens #4453
Conversation
|
57c10e4
to
fb3a1ca
Compare
fb3a1ca
to
065489c
Compare
@mlissner I'd say this is almost ready, but I just noticed that the notes tables have a button in the last header to search notes, which isn't shown in the mobile version. I guess I could add it somewhere else and display it in mobile only, like above the table? or I could move the button entirely. let me know what you think |
I think it's fine that the search isn't there in mobile. Thus is the way with mobile.... |
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.
@elisa-a-v The code looks great! I have a few suggestions to improve the responsive design:
-
I think we could enhance the animation of the up/down arrow. Currently, it seems to rotate around one of its vertices. A more common approach is to rotate the arrow around its center point. Here's a GIF demonstrating the desired behavior:
- Current implementation:
- Desired behaviour
-
I noticed that the
fa-list
icon is a bit too close to the text in the accordion header. I think adding a non-breaking space between the icon and the text would improve the visual spacing. Here's a screenshot: -
While reviewing the notes table, I noticed that the modal window for updating a note isn't centered correctly on smaller screens. Here's a screenshot:
While this issue might be out of scope for this specific PR, I'm flagging it here as it's related to our overall responsive design efforts.
Thanks Eduardo. It's probably worth fixing #2, but I don't think it's worth bothering on 1 or 3, since we'll be revamping the details and switching to tailwind fairly soon. A little funkiness temporarily is fine, I think. |
Normally I'd say yes, Elisa, I love filing bugs, but I think these will just get fixed no matter what in our design overhaul. Eduardo, merge if you're ready! Thank you both! |
This PR makes profile tables responsive by adding an accordion feature that hides columns in smaller screens. To do this a script and some CSS was implemented that allows to easily make any table responsive.
To make tables responsive, include a script with
src="{% static "js/responsive-table.js" %}"
, add the class.responsive-table-wrapper
to the<table>
element, and add an attributedata-label
to each<th>
element to be labelled in the mobile version with stacked columns.Docket alerts:
Docket notes:
Opinion notes: