Skip to content
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

Updating style assets #110

Merged
merged 44 commits into from
Jul 2, 2024
Merged

Updating style assets #110

merged 44 commits into from
Jul 2, 2024

Conversation

acholyn
Copy link
Collaborator

@acholyn acholyn commented Jun 18, 2024

Have improved our basic components in alignment with the new mockups and have added some basis for mobile viewing:

film list view on desktop - new cards that are common across the main models (image at top of film cards will be better integrated in future as background [tbc]), more consistent buttons, new header layout + background (word logo to be updated in future)

image

same view on mobile:

image

footer on desktop: (streamlined code and more responsive + collaborator logos)
image

on mobile: (decision to not include own logo based on looking at other companies' mobile footers)
image

  • have updated some colouring to better match with the scheme outlined in the mockups
  • have updated previews for videos on frontend and admin to work with mediacentral
  • have updated fonts in accordance with mockups
  • have abstracted pagination to be used on list views as desired
  • minor updates to bibliography page for readability

closes #106 , #99 , #105

@acholyn acholyn requested review from tcouch and p-j-smith June 18, 2024 10:24
Copy link
Collaborator

@tcouch tcouch left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks fantastic, and code looks well organised. Sorry I don't know more about CSS to give more constructive feedback.

If I had to nitpick I'd say the transition where the side menu pops out is a little bit quick, and maybe the colour change on hover for the site title is unnecessary? But also feel free to ignore me because clearly you know what you're doing.

acholyn and others added 9 commits June 27, 2024 12:06
Migrations for 'mod_app':
  mod_app/migrations/0023_alter_bibliographyitem_full_citation_and_more.py
    - Alter field full_citation on bibliographyitem
    - Alter field short_citation on bibliographyitem
    - Alter field format_type on film
    - Alter field bibliography on projectnote
    - Create model Feedback
Copy link
Collaborator

@p-j-smith p-j-smith left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

sorry I don't know enough to give a very useful review here, but the site looks great! Just a few questions to help my understanding

@@ -22,6 +22,7 @@ class VideoInline(PreviewMixin, s3BrowserButtonMixin, admin.TabularInline):
"grp-collapse",
"grp-closed",
]
exclude = ("file",)
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

is this now excluded because files are no longer used for videos (only links)?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

yep! All the other models that are based on links can still use files, and technically speaking, you could add a file to a video instance still, but you'd have to do it through the command line. This just disables it from being shown in the admin frontend so the researchers can't use it

margin-bottom: 1rem;
display: flex;
columns: 2;
margin: 1vw 6vw;
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

just curious why the change from rem to vw?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It might just be personal bias but I felt like it worked a bit better for responsiveness - maybe since it's based off the width of the screen instead of an element?

mod_app/static/js/dynamicTagColours.js Outdated Show resolved Hide resolved
'<img src="{}" style="max-width: 15rem;" />',
obj.url,
)
if obj.__class__.__name__ == "Video":
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
if obj.__class__.__name__ == "Video":
if isinstance(obj, Video):

would it make sense to do this instead (and add from mod_app.models.support_models import Video to the imports? Or perhaps obj._meta.verbose_name == "Video"?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'll try it! I know I ran into circular import issues before but it might not be the case with this file

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The isinstance didn't seem to work when I tested it, is there a particular benefit to using obj._meta.verbose_name == "Video" instead of the obj.__class__.__name__?

@acholyn
Copy link
Collaborator Author

acholyn commented Jul 1, 2024

Aylin would like us to use Montserrat Bold for the header instead of Impact and remove the film strip styling for the footer. Content should be dark-mode forward with queries for light mode preference, also a toggle option to view the site in light or dark mode

@acholyn acholyn merged commit b704a93 into development Jul 2, 2024
2 of 3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

redoing mockups
3 participants