Skip to content

Conversation

@LianaHarris360
Copy link
Member

Summary

Description of the change(s) you made

This PR resolves the confusion surrounding the question mark icon in the disabled License input field, which previously made it unclear if the question mark icon was interactive. It ensures that even when the input is disabled, users can still access information about licenses and removes the modal opening another modal functionality.

Screenshots (if applicable)

Before:

AboutLicensesBefore.mov

After:

AboutLicensesAfter.mov

disabledlicense


References

Closes #4679

Comments

  • Removed AboutLicensesModal.vue and contents within to LicenseDropdown.vue
  • Removed mutation SET_SHOW_ABOUT_LICENSES and references.
  • Removed isAboutLicensesModalOpen getter.
  • Added basic-link KButton to LicenseDropdown.vue and toggling functionality.

Contributor's Checklist

PR process:

  • If this is an important user-facing change, PR or related issue the CHANGELOG label been added to this PR. Note: items with this label will be added to the CHANGELOG at a later time
  • If this includes an internal dependency change, a link to the diff is provided
  • The docs label has been added if this introduces a change that needs to be updated in the user docs?
  • If any Python requirements have changed, the updated requirements.txt files also included in this PR
  • Opportunities for using Google Analytics here are noted
  • Migrations are safe for a large db

Studio-specifc:

  • All user-facing strings are translated properly
  • The notranslate class been added to elements that shouldn't be translated by Google Chrome's automatic translation feature (e.g. icons, user-generated text)
  • All UI components are LTR and RTL compliant
  • Views are organized into pages, components, and layouts directories as described in the docs
  • Users' storage used is recalculated properly on any changes to main tree files
  • If there new ways this uses user data that needs to be factored into our Privacy Policy, it has been noted.

Testing:

  • Code is clean and well-commented
  • Contributor has fully tested the PR manually
  • If there are any front-end changes, before/after screenshots are included
  • Critical user journeys are covered by Gherkin stories
  • Any new interactions have been added to the QA Sheet
  • Critical and brittle code paths are covered by unit tests

Reviewer's Checklist

This section is for reviewers to fill out.

  • Automated test coverage is satisfactory
  • PR is fully functional
  • PR has been tested for accessibility regressions
  • External dependency files were updated if necessary (yarn and pip)
  • Documentation is updated
  • Contributor is in AUTHORS.md

Copy link
Member

@marcellamaki marcellamaki left a comment

Choose a reason for hiding this comment

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

Hi Liana - this looks good thank you for working on it. I also did manual QA and it is working as expected, and since these strings were pre-existing, I did the review in Spanish and confirmed that they were all being imported and referenced correctly.

A (very tiny) nitpick change and also a clarifying question, but overall this seems more-or-less ready to go.

},
data() {
return {
reqeuestFormStrings: crossComponentTranslator(RequestForm),
Copy link
Member

Choose a reason for hiding this comment

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

A small nitpick and a curiosity question:

  1. there's a typo here reqeuest (it's working, though! the spelling is consistent. but a nice small cleanup)
  2. It seems like even though I had problems with the modal interaction previously, it was working for you with the correct text (modal-in-modal, as originally designed). I'm wondering how the strings were working? I don't see crossComponent translator used in the deleted file. It's not a problem! I'm just trying to figure it out for the sake of a comprehensive review 😄

Copy link
Member Author

Choose a reason for hiding this comment

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

  1. Thanks for catching this, not sure how I missed it!
  2. I believe the problems you were having was because the License input was disabled. I noticed this happening when it is unable to be edited I think because it is not in its original location. The strings worked fine but they were directly in the deleted file so instead of adding them over again in LicenseDropdown.vue, I decided to use the crossComponent translator. I was unsure if adding the same strings to LicenseDropdown.vue would import the translated strings the correct way.

Copy link
Member

Choose a reason for hiding this comment

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

okay thank you @LianaHarris360!

Copy link
Member

@AlexVelezLl AlexVelezLl left a comment

Choose a reason for hiding this comment

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

Code changes looks good to me! Just noted a little thing with the styles of the dropdown icon.

I think its also worth noting that this change is also going to change the edit all details modal, I guess this is the intended behaviour, but just noting it just in case 😅.

image

:hide-selected="isMixedLicense"
:menu-props="{ ...menuProps, maxHeight: 250 }"
class="ma-0"
:class="{ 'with-trailing-input-icon': box }"
Copy link
Member

Choose a reason for hiding this comment

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

We had this class to include the trailing icon for the about licenses modal. As we are removing this, we need to remove also this line and/or fix these alignment styles, and all the related styles here https://github.com/LianaHarris360/studio/blob/0cefdcec13a859cb739914fdb6cd0fabb65c99d9/contentcuration/contentcuration/frontend/shared/views/LicenseDropdown.vue#L242, as this cause this little misalign in the dropdown icon.

image

Copy link
Member Author

Choose a reason for hiding this comment

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

Thanks for pointing this out, I was wondering about this misalignment but didn't initially see where it was being set. Now I can get it fixed!

Copy link
Member Author

Choose a reason for hiding this comment

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

The input selection arrow alignment is now fixed :)
EditSourceModal

Copy link
Member

Choose a reason for hiding this comment

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

Hi Liana! It seems we now have this little bug when we select an option with less width 😅 :

image

image

Copy link
Member Author

@LianaHarris360 LianaHarris360 Sep 10, 2024

Choose a reason for hiding this comment

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

I believe this bug was present before these changes were made. I attempted to edit the source on unstable and encountered the same issue. Adding a minimum width fixes it! I also noticed it had a slightly darker background than the rest of the inputs in the EditSource modal and updated that as well.

EditSourceLicense.mov

Full Edit Details page view:
EditDetailsPage

@marcellamaki
Copy link
Member

this change is also going to change the edit all details modal, I guess this is the intended behaviour, but just noting it just in case - @AlexVelezLl

hmmmmm. this is a good point, @AlexVelezLl, thank you for raising. I don't know if we want to change this within the edit modal or not. @LianaHarris360 can I think on this for a day? I don't think it's necessarily a problem if we do. I just want to make sure we're being intentional. (cc @akolson and @radinamatic)

@marcellamaki marcellamaki self-assigned this Sep 10, 2024
@akolson
Copy link
Member

akolson commented Sep 12, 2024

I think this is ready to merge. Any additional issues, which I don’t see as blockers, can be addressed in a follow-up issue. cc @marcellamaki.

@AlexVelezLl could you please create an issue with the details and approve this so it can be merged?

Thanks @LianaHarris360 for the fix and follow through.

Copy link
Member

@AlexVelezLl AlexVelezLl left a comment

Choose a reason for hiding this comment

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

Thanks Liana! Looks good to me! @akolson I son see any aditional issues, just finishing the decisioin whether we want this version in the "edit all details" modal, although imo there is no problem with that, and it would be good for concistency. Thanks!

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.

Add helper text for the "?" in the license/source modal

4 participants