Foundation.mozilla.org: Updates to Image Text2 component

Created on 20 Feb 2019  路  16Comments  路  Source: mozilla/foundation.mozilla.org

This is probably blocked by - Remove deprecated components #1902 and Updates Figuregrid2 component #2696

Related to - New Image Text Mini component #2694

Based on design in https://github.com/mozilla/foundation.mozilla.org/issues/2282, component comps https://redpen.io/tuab5adf37d05d0414 and Fellowship comps https://redpen.io/p/mga45e3eeaaf9bc071.

Styling and CMS form fields

  • [x] Keep image at 1:1 ratio
  • [x] Add styles to Test so they match our style guide (H2-H6, normal body + large body, bold, italic, list, url link)
  • [x] Add optional top divider and separate optional bottom divider (1px black)
  • [x] Vertically center the image with the content
  • [x] Mobile: halve the size of the image and left align it
  • [x] Update component name from Image Text2 to Image Text [blocked by deprecating old component #2739] - ok to hold off on name change
  • [x] Remove Small checkbox (this is now Image text mini)

@alanmoo or @Pomax can you please either add to this ticket or open a separate one that includes additional steps for determining where this component is used and how we can make sure we don't break anything while doing these updates?

Component comp

image text 2x

backend frontend wagtail

All 16 comments

It looks like we're still using ImageTextBlock on nine pages so we'll have to switch those over to ImageTextBlock2 first before we can remove the original ImageTextBlock (which is a necessary step before we can start renaming things relating to ImageBlock2. Streamfield migrations are unfortunately even more complex than standard django model renames)

Amazing that you can tell which pages are using it! I will update those tomorrow.

Ok that was painfully tedious but they're all gone now!

Super! On a CMS permissions note, can you see the "settings -> block inventory" option? I don't recall it being an explicit permission in the user group policies, but I also don't think we ever checked that everyone with CMS access can see it, even though it'd be super useful if everyone could.

Yes, I see it!

image

ah, perfect. Thanks for checking!

I guess, feel free to do the renaming later if deleted the deprecated component is a blocker.

Removing the "small" checkbox is going to impact at least one page on the existing site: https://foundation.mozilla.org/en/initiatives/responsible-cs/challenge/.

Has an audit been done to understand the effects of this (and the URL removal)?

I wonder if it might be better to rebuild this as a separate component called Image Text and deprecate ImageText2

ImageText2 (without the checkbox) has been used extensively on the site so replacing it would be a nightmare.

I can certainly do an audit of where the "small" checkbox has been used and then replace those with Image Text Mini when we have it (that's why I put mini as a higher priority to this one).

@kristinashu, any updates on the 'small' checkbox audit?

Add styles to Test so they match our style guide (H2-H6, normal body + large body, bold, italic, list, url link)

@kristinashu, what type of list(i.e. ordered/bulleted or unordered/no-bullets) did you want here?

All those text styles should be the same as the Paragraph component.

marking as blocked until https://github.com/mozilla/foundation.mozilla.org/pull/2763 is on production (not just staging)

2763 got deployed to production, marking as unblocked again.

w00t Youri! Looks like this is all done and working great!

The final step is represented in - [Wagtail Component] Remove Image Text 2 Component #2793

Was this page helpful?
0 / 5 - 0 ratings

Related issues

kristinashu picture kristinashu  路  4Comments

xmatthewx picture xmatthewx  路  4Comments

sabrinang picture sabrinang  路  5Comments

kristinashu picture kristinashu  路  3Comments

kristinashu picture kristinashu  路  5Comments