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

Add prominent link to CC tools and clarify site purpose (Fixes #793) #810

Merged
merged 6 commits into from
Oct 3, 2024

Conversation

MohdMuslim92
Copy link
Contributor

@MohdMuslim92 MohdMuslim92 commented Oct 2, 2024

Fixes

Description

This pull request resolves an issue where users might mistakenly visit this site while looking for Creative Commons (CC) licenses/tools, which could lead to confusion about the purpose of the site.

To address this:

  • Added a prominent button to the hero section of the homepage labeled "Share your work using our licenses/tools" linking to the Creative Commons Share Your Work page.
  • Clarified the site’s purpose by adding a notice near the top of the homepage, informing visitors that this site is for developers contributing to Creative Commons, but anyone can use CC tools to share their work.

Technical details

  • Modified content/contents.lr to include the new button and the clarification notice on the homepage.
  • Updated webpack/sass/home-page.scss to style the new button in the hero section and improve the overall layout.

Screenshots

new button

Checklist

  • My pull request has a descriptive title (not a vague title like Update index.md).
  • My pull request targets the default branch of the repository (main or master).
  • My commit messages follow best practices.
  • My code follows the established code style of the repository.
  • I added or updated tests for the changes I made (if applicable).
  • I added or updated documentation (if applicable).
  • I tried running the project locally and verified that there are no
    visible errors.

Developer Certificate of Origin

For the purposes of this DCO, "license" is equivalent to "license or public domain dedication," and "open source license" is equivalent to "open content license or public domain dedication."

Developer Certificate of Origin
Developer Certificate of Origin
Version 1.1

Copyright (C) 2004, 2006 The Linux Foundation and its contributors.
1 Letterman Drive
Suite D4700
San Francisco, CA, 94129

Everyone is permitted to copy and distribute verbatim copies of this
license document, but changing it is not allowed.


Developer's Certificate of Origin 1.1

By making a contribution to this project, I certify that:

(a) The contribution was created in whole or in part by me and I
    have the right to submit it under the open source license
    indicated in the file; or

(b) The contribution is based upon previous work that, to the best
    of my knowledge, is covered under an appropriate open source
    license and I have the right under that license to submit that
    work with modifications, whether created in whole or in part
    by me, under the same open source license (unless I am
    permitted to submit under a different license), as indicated
    in the file; or

(c) The contribution was provided directly to me by some other
    person who certified (a), (b) or (c) and I have not modified
    it.

(d) I understand and agree that this project and the contribution
    are public and that a record of the contribution (including all
    personal information I submit with it, including my sign-off) is
    maintained indefinitely and may be redistributed consistent with
    this project or the open source license(s) involved.

- Added a button linking to the Creative Commons 'Share your work' page.
- Updated hero section to include comments for better code clarity.
- Included explanatory text about the site's purpose for developers and general users.
- Included a new caption explaining the site's focus on developer contributions.
- Added a link to Creative Commons tools in the footer for easier navigation.
- Minor formatting adjustments.
- Added comments to clarify the styling for the hero section, including title, description, and links.
- Improved button layout using flexbox, with comments explaining width, padding, and alignment choices.
- Enhanced readability by documenting key CSS properties for future maintainability.
@MohdMuslim92 MohdMuslim92 requested review from a team as code owners October 2, 2024 03:24
@MohdMuslim92 MohdMuslim92 requested review from TimidRobot, Shafiya-Heena and akmadian and removed request for a team October 2, 2024 03:24
Copy link
Member

@TimidRobot TimidRobot left a comment

Choose a reason for hiding this comment

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

I like the direction of this PR!

Please:

  1. Remove "Follow us on twitter" button
  2. Move "Share your work using our licenses/tools" button below "This site is for developers looking to contribute, but anyone can use CC tools to share their works." text
  3. Update "Share your work using our licenses/tools" button to use color of now-removed Twitter button
  4. Update styling of "This site is for developers looking to contribute, but anyone can use CC tools to share their works." text to match "We work on code and products [...]" text
Screenshot 2024-10-02 at 06 12 16

@TimidRobot
Copy link
Member

Please also remove footer notice

@possumbilities
Copy link
Contributor

I would also add the internal vertical padding for the text on the button is inconsistent with the other buttons and needs to be adjusted as well.

@MohdMuslim92
Copy link
Contributor Author

Thank you for the detailed feedback! I've made the suggested updates, but I need some help on the last feedback from @possumbilities.

As it's clear, the text within the button is too long. How do I go about that? Should I make the text smaller and fit it in one line, or split it into two lines like it is currently, but adjust the padding appropriately?

If I make the text one line, I would need to reduce the font size to avoid the design extending horizontally, which would otherwise cause horizontal scrolling on smaller devices and impact the user experience. Could you guide me on which approach would be best?

Thank you again for your time and guidance!

@possumbilities
Copy link
Contributor

@MohdMuslim92 I think the most direct solution is to correct the padding. Buttons should be able to allow text-wrapping, and grow in height without them overflowing the bounds of the button, or breaking the internal spacing. I would strongly urge against altering the font-size, that may result in poor Accessibility.

A button shouldn't expect a particular length of text, though long text on buttons should have some limit (the longer it is the more disruptive it is to the button's scannability.

@MohdMuslim92
Copy link
Contributor Author

Thanks again for the detailed feedback! I've made the suggested updates and pushed the changes. Please let me know if there's anything else that needs attention.

@TimidRobot TimidRobot self-assigned this Oct 3, 2024
Copy link
Member

@TimidRobot TimidRobot left a comment

Choose a reason for hiding this comment

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

I realize, now, that we're fighting an assumption that is encoded in the Lektor model and theme template. That assumption is that there is a single paragraph in the description followed by one or more links.

The long term solution is to refactor the theme, which is beyond the scope of this PR.

A shorter term solution is to move the description into the link section so the paragraphs and buttons can be intermingled.

  1. modify template
    --- themes/vocabulary_theme/templates/blocks/hero.html
    +++ themes/vocabulary_theme/templates/blocks/hero.html
    @@ -7,9 +7,6 @@
         </div>
         <div class="columns margin-right-0">
           <div class="column is-5">
    -        <p class="hero-description">
    -          {{ this.description }}
    -        </p>
             {{ this.links }}
           </div>
         </div>
  2. modify content
    --- content/contents.lr
    +++ content/contents.lr
    @@ -9,24 +9,18 @@ title:
     
     We have been building <span class="has-text-forest-green">free software</span> at <span class="has-text-gold">Creative Commons</span> for over a decade.
     ----
    -description:
    -
    -We work on code and products that support digital creativity and sharing, from usability of our legal tools to enabling discovery of CC-licensed content.
    -----
     links:
     
    -<!-- Container for the hero section links -->
    +<p class="hero-description">We work on code and products that support digital creativity and sharing, from usability of our legal tools to enabling discovery of CC-licensed content.</p>
     <div class="hero-links">
       <!-- Button linking to the developer community page -->
       <a class="button small is-success row" href="/community">
         Join the Developer Community
       </a>
    +</div>
     
    -  <!-- Informational text about the purpose of the site -->
    -  <div class = "hero-notice">
    -    This site is for developers looking to contribute, but anyone can use CC tools to share their works.
    -  </div>
    -
    +<p class="hero-description">This site is for developers looking to contribute, but anyone can use CC tools to share their works.</p>
    +<div class="hero-links">
       <!-- Button linking to the Creative Commons "Share your work" page -->
       <a class="button small row" href="https://creativecommons.org/share-your-work/">
         Share your work using our licenses/tools
  3. modify styles (per code comment)
  4. Update PR description (ex. new screenshot)

webpack/sass/home-page.scss Outdated Show resolved Hide resolved
webpack/sass/home-page.scss Outdated Show resolved Hide resolved
themes/vocabulary_theme/templates/layout.html Show resolved Hide resolved
@MohdMuslim92
Copy link
Contributor Author

Hi @TimidRobot,

Thank you for your feedback! I’ve made the suggested changes and updated the pull request description

Please let me know if there’s anything else you’d like me to address. Looking forward to your review!

Best.

Copy link
Member

@TimidRobot TimidRobot left a comment

Choose a reason for hiding this comment

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

Great work!

@TimidRobot TimidRobot merged commit a9be63a into creativecommons:main Oct 3, 2024
1 check passed
@MohdMuslim92
Copy link
Contributor Author

Thank you all for your valuable feedback and guidance throughout this PR! I really appreciate your time and help in getting this merged. Looking forward to contributing more in the future!

Best regards,

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Archived in project
Development

Successfully merging this pull request may close these issues.

[Feature] Redirect end users to the main site for licenses/tools
3 participants