Code Monkey home page Code Monkey logo

rbb-website's People

Contributors

adriantnare avatar agbanusi avatar allcontributors[bot] avatar andrewchough avatar asaki222 avatar ashtine avatar bcgoss avatar billy-le avatar brewswain avatar chrisdemars avatar domitriusclark avatar jakeleboeuf avatar jbolda avatar jlengstorf avatar jordanandree avatar jtschwartz avatar kieranklaassen avatar llexical avatar m0nica avatar magnificode avatar mbifulco avatar mmosholder avatar molebox avatar qmaximillian avatar racedale avatar ryancharris avatar seharlan avatar shapirone avatar subject026 avatar thugdebugger avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

rbb-website's Issues

Build GlobalHeader component

Global Header

Figma: https://www.figma.com/file/Lo1ZcBOO9t4QRbX2I0PwBQ/RBB?node-id=427%3A670

The GlobalHeader component should consist of a SVG version of the RBB logo that when clicked, navigates to the home page.

Pages in the navigation should follow this structure:

Home (slug: "/")
About (slug: "/about")
Businesses (slug: "/businesses")
Allies (slug: "/allies")
Resources (slug: "/resources")

Desktop

7fa5b65f8cc7ad01b9d8ebb66f18dc02

Small Screens

d054007d30bce659c067e907169e0cf6

As screen size is reduced, the navigation within the GlobalHeader should become hidden behind a hotdog menu. Upon click of the hotdog, the navigation will appear in a row layout.

Create ResultCard component structure

Trello: https://trello.com/c/g5OZn1z8

The ResultCard has two variations:

ResultCard Default State

Screen Shot 2020-06-05 at 10 50 53 AM

The ResultCard default state should output the following data from Airtable:

  • Business Image - Does not exist in Airtable currently, read on.
    • Use image if available. If no image available, pull from fallback asset for the business category.
    • This data does not currently exist in the database. Write conditionals to prepare for this, leverage a random unsplash image https://source.unsplash.com/random as a stub for the fallback.
  • Business Name
  • Business Category
  • Business Blurb
    • This data does not currently exist in the database. Write conditionals to prepare for this.
  • Business Location
  • Business Buttons
    • 1 - 2 buttons
    • Website URL button text dependent on business category
      • Entertainment: Learn more
      • Food and beverage: Order
      • Health and wellness: Learn more
      • Professional services: Contact
      • Retail: Shop
    • If no donate URL, the Website button takes full width.
    • If there is a donate URL provided, second button appears to the right, with button text “Donate”
  • Report Link
    • mailto: link, use placeholder email for now.

ResultCard Basic

Screen Shot 2020-06-05 at 11 00 29 AM

This variation does not utilize a Business image, but instead leverages a background color.

  • Business Name
  • Business Location
  • Business Blurb
    • This data does not currently exist in the database. Write conditionals to prepare for this.
  • Business Button
    • 1 Button
    • Website URL. Button text "Website"
  • Report Link
    • mailto: link, use placeholder email for now.

Add gating functionality to the Allies page

Ally Page Gating

Figma Desktop: https://www.figma.com/file/Lo1ZcBOO9t4QRbX2I0PwBQ/RBB?node-id=1155%3A9992
Figma Mobile: https://www.figma.com/file/Lo1ZcBOO9t4QRbX2I0PwBQ/RBB?node-id=1155%3A10056

When a user visits the Allies page for the first time, they should be presented with a popup asking them to agree to our terms and conditions (link TBD). Upon checking the checkbox, the modal will be closed, and the AllyFeed will be rendered.

Functionally, we want to prevent easy scraping of our user's data. So in order to help cut down on that we require folks to accept terms and conditions before they view the list. We need to ensure that no data is shown until the terms and conditions have been clicked, instead, behind this modal we will show a grid of "Skeleton" elements (https://chakra-ui.com/skeleton). Once the checkbox has been clicked, localStorage should be used to ensure that user does not have to accept the terms and conditions again, the modal should close, and the Skeleton elements should be re-rendered with real data.

Add NoResults Component

NoResults

Figma Desktop: https://www.figma.com/file/Lo1ZcBOO9t4QRbX2I0PwBQ/RBB?node-id=1155%3A11025
Figma Mobile: https://www.figma.com/file/Lo1ZcBOO9t4QRbX2I0PwBQ/RBB?node-id=1155%3A11093

When a user filters for Businesses or Allies, and their filter yields no results, they should be presented with a component that contains a Heading, Paragraph, and Airtable form embed via iframe src (use a placeholder for the Airtable form for now).

Styling should be handled through the use of ChakraUI components, and theme variables should be used where possible for things like font styles, colors, and spacing.

If possible, this component should be interchangeable between User Types (Businesses, and Allies).

If possible, through props, a Developer should be able to edit the heading, paragraph, and iframe src.

If reuse of this component isn't viable, two separate NoBusinessResults and NoAllyResults can be created, where the content is handled within the components themselves.

Some "Learn More" links are broken

Steps

  1. Load https://www.rebuildblackbusiness.com/businesses in any browser (I tried FF, Safari and Chrome on macOS)
  2. Scroll down to the card for "Wild Haven Botanica LLC"
  3. Click the "Learn More" button

Expected

User ends up at https://www.wildhavenbotanica.com

Actual

User ends up at https://www.rebuildblackbusiness.com/www.wildhavenbotanica.com

More details

Seems like some of the business urls in your data (in airtable?) are being treated as relative links because they don't start with the protocol.

Screenshot

business url treated as relative url

Add Keys to Pagination

  • If you go to /businesses the following warning is displayed Warning: Each child in a list should have a unique "key" prop. Check the render method of Pagination. See https://fb.me/react-warning-keys for more information.

Create Pagination logic

Pagination

Leverage gatsby-node.js to create a pre-filtered page of data per each of the 50 states. This will create some nice SEO opportunities to have a URL per state of black owned businesses. It will also allow us to properly categorize data that does not have complete information, and ensure that they can still be included and searched for on the site.

Logo very pixelated on 4k desktop screen

The heading site logo looks quite pixelated on my 4k display. The issue seems to persist across all pages. Please see below for example:

image

The issue also shows up at mobile size:

image

Create ContentBlock component and variations

ContentBlock

Figma: https://www.figma.com/file/Lo1ZcBOO9t4QRbX2I0PwBQ/RBB?node-id=429%3A57

Leveraging Chakra UI components, we need to build out a ContentBlock component that can accept a few parameters in order to output the different variations on the home page.

Customization Options

The content block should be a single Higher Order Component that allows us to add any content within it. Primarily this content will be Headings, Paragraphs, and Buttons.

As a Developer, I should be able to customize the background color that is used on an individual block and whether it is a fade, or tint.

As a Developer I should be able to customize the image that appears as the background for this block.

As a Developer I should be able to choose to have the text appear on the left, right or in the center of the block.

Customization Examples

Left aligned content, black background that fades over a custom img src, Heading, Paragraph, and 2 Buttons as children of the Higher Order Component.

Desktop
ContentBlock--Left--Black

Right aligned content, white background that fades over a custom img src, Heading, Paragraph with an inline link, and 2 buttons as children of the Higher Order Component

Desktop

ContentBlock--Right--White

Center aligned content, color tint over a custom img src, Paragraph, and one button that spans the width of the content

ContentBlock--Center

Responsive

The ContentBlock should be responsive, the content will center, span the full width, and the background color will become a tint over the background image on smaller screens

Mobile
ContentBlock--Left--Black-mobile

Layout Home Page

Figma: https://www.figma.com/file/Lo1ZcBOO9t4QRbX2I0PwBQ/RBB?node-id=0%3A1

Leveraging Chakra UI components and already existing ContentBlock and PrimaryButton components, we need to layout the home page to match up to UI designs.

Trello:
https://trello.com/c/UfKtiYcc/11-layout-homepage-content

Image Assets:

  • Cloudinary ID for Fist image: assets/home-header-bg
  • (Alternate) Cloudinary ID for Fist image: assets/home-header-bg-space
  • Cloudinary ID for Contact image1: assets/cta1-bg
  • Cloudinary ID for Contact image2: assets/cta2-bg
  • (Alternate) Cloudinary ID for Contact image2: assets/cta2-bg-space
  • Cloudinary ID for Contact image3: assets/cta3-bg

Desktop:
Screen Shot 2020-06-07 at 11 38 35 AM

Responsive

The layout should be responsive, the content will center, span the full width.

Mobile:
Screen Shot 2020-06-07 at 11 38 47 AM

Review & Update ReadMe

go over the readme and update it since so much has changed over the past few days leading up to launch.

  • Remove Discord Invite Link
  • Maybe remove links to Trello
  • Update terminology

Create Footer

Footer

Figma: https://www.figma.com/file/Lo1ZcBOO9t4QRbX2I0PwBQ/RBB?node-id=429%3A57

Desktop
footer

Mobile
footermob

The Footer component will be added to our <Layout /> component (https://github.com/Rebuild-Black-Business/RBB-Website/blob/master/src/components/Layout.js) and should appear on every page. It is composed of a few sections:

Social List

Individual social icons for various social media properties. For now stub these out with # as the href until we have these properties 100% set up. On hover or focus of each icon, increase size by 10%:

transform: scale(1.1)

Link List

Below the social icons is the link list, this should be the same as the link list in the navigation. A <StaticQuery> should be used to generate this link list. See https://github.com/Rebuild-Black-Business/RBB-Website/blob/master/src/components/Layout.js#L17 and https://github.com/Rebuild-Black-Business/RBB-Website/blob/master/src/components/PrimaryNav.js#L62 for how we're building this in the PrimaryNav component.

Photo Credits

The assets we use on the site are all public domain, and thus must be attributed to the photographer who took the pictures. The menuLinks object within siteMetadata here: https://github.com/Rebuild-Black-Business/RBB-Website/blob/master/gatsby-config.js#L33 should be expanded to include the Photographer's name, and URL on a per page basis.

The only photo credits we have approved are the Home page credits:

John Cameron https://unsplash.com/@john_cameron
Kelly Lacy https://instagram.com/kellymlacy
Mike Von thevoncomplex.com

The photo credit should open in a new tab.

Copyright Information

The copyright year in the footer should be dynamic and the "Terms and Conditions" bit should be a link to a (currently not created) "Terms and Conditions" page. The text for Terms and Conditions should contain non-breaking spaces so that it does not wrap in the middle on smaller screens.

Ensure all links can be tab targeted and include focus states.

Image optimizations

We're seeing long initial load times from our images. Going to work on adding some more optimizations from Cloudinary and tweaking until we see less stutter.

Ensure small screen Navigation is accessible

In our PrimaryNav component: https://github.com/Rebuild-Black-Business/RBB-Website/blob/master/src/components/PrimaryNav.js

Primarily I believe we need to add a couple of aria roles to the navigation (nav is only toggled on smaller screens).

aria-controls should be added to the <button> within the <Box> component wrapping the Hamburger menu. This should point to the ID of the navigation.

aria-expanded should be added to the <button> within the <Box> and toggled when the button is clicked.

aria-hidden should be applied to the <NavMenu> component. On desktop this will be set to false, but on mobile this should be toggled when the hamburger nav is clicked.

Create BusinessFilter Component

BusinessFilter

Since data structure has been finalized we can now work on getting the BusinessFilter functionality wired up. Here's the logic:

As a user, I should be able to optionally filter businesses by category. This field should incorporate the following:

Field type: dropdown select
Field label: Business
Field placeholder option: Select type
Dropdown options:

  • Entertainment
  • Food and beverage
  • Health and wellness
  • Professional services
  • Retail

As a user, I should be able to optionally filter businesses by City / State OR Zipcode. By leveraging this NPM package we should be able to take in "Atlanta, GA" for example, return an array of zip codes that are associated with that city state string, and return results that match any zip in that array

Field type: Text search (likely will need strict validation to ensure the "Atlanta, GA" format. Searching "Atlanta" or "ATL" will not yield any results in v0). This will accept both city state, or a zip code.

Field label: Location
Field placeholder text : Eg. "Atlanta, GA" or "30301"

As a user, I should be able to filter businesses by their level of need. This is a boolean value in the database. Businesses impacted by current events will be labelled as "In Need" in the database.

Field type: Checkbox (Should be pre-checked for v0)
Field Label: "In Immediate Need" (this is subject to change as designs are fully approved)

Use Link component only for internal links

Resolve this warning from Chakra UI:
External link https://www.instagram.com/clay.banks was detected in a Link component. Use the Link component only for internal links.

Layout About Page

Figma: https://www.figma.com/file/Lo1ZcBOO9t4QRbX2I0PwBQ/RBB?node-id=429%3A57

Leveraging Chakra UI components and already existing ContactCard components, we need to layout the home page to match up to UI designs. H2 headers should be used for "who we are", "mission", and "contact" headers

Trello:
https://trello.com/c/TeFxrCVb/43-about-page

Image Assets:

  • Cloudinary ID for Fist image: assets/people-protesting-on-street-4552840_gginry
  • Cloudinary ID for Contact image1: assets/contact-left
  • Cloudinary ID for Contact image2: assets/contact-middle
  • Cloudinary ID for Contact image3: assets/contact-right

Desktop:
RBB-about

Responsive

The layout should be responsive, the content will center, span the full width.

Mobile:
RBB-about-mobile

Match PrimaryNav to updated designs

PrimaryNav

Figma: https://www.figma.com/file/Lo1ZcBOO9t4QRbX2I0PwBQ/RBB?node-id=427%3A1426
https://www.figma.com/file/Lo1ZcBOO9t4QRbX2I0PwBQ/RBB?node-id=1156%3A6458

The alignment of the navigation items, and some small stylistic changes need to be reflected in the code. Changes include:

  • Addition of a "Subscribe" button (using our current button components which were merged in #34 )
    • On mobile, the subscribe button should span the full width of the navigation container, and the button text should be centered.
    • Functionality When a user clicks on this Subscribe button, a Modal (https://chakra-ui.com/modal) should pop up. For this task we can leverage dummy content within the modal.
  • Primary navigation items should now be aligned left
  • Background color of the nav should now be our black-000 variable

Create a utility function to convert ZIP codes from database into City, ST format.

Zip Codes

One of the primary goals of the RBB site is to ensure that we can quickly and effectively connect people with black owned businesses near them. In order to do this, we do our best to accurately generate location based data for users to filter by.

Currently in the DB we are collecting zip codes of businesses that have a storefront. Some businesses do not have a storefront and are therefore tagged as an "Online" business.

If a business has a storefront, we need to take their zip code, and display it as "City, ST" on the frontend. For example, a business has the zip code of 80219, the front end should display "Denver, CO".

This should be a utility function that we can pass an integer to, and have it return the "City, ST" format.

Explore using https://www.npmjs.com/package/zipcodes - this has features that we would like to leverage in the future as well.

No Display after search

On the business page, if a business type is selected, a location entered, and In Urgent Need selected, when search executes nothing displays below in the iframe class=airtable-embeded

Create Pagination Component

Pagination

Figma: https://www.figma.com/file/Lo1ZcBOO9t4QRbX2I0PwBQ/RBB?node-id=579%3A1516

Leveraging Chakra UI components, we need to build out a Pagination component that can support having optional ellipsis for large amounts of pages of results.

  • Given a user is on the first page + 4 more (5 pages total), the first set of ellipsis will not be shown.

Screen Shot 2020-06-06 at 10 47 19 PM

  • Given a user is on the last page - 4 less (5 pages total), the first set of ellipsis will not be shown.

Screen Shot 2020-06-06 at 10 54 10 PM

  • Given a user is somewhere in the "middle" of the results (not the previous two scenarios) then the
    middle number will be active and both sets of ellipsis will be shown

Screen Shot 2020-06-06 at 10 46 31 PM

Mobile:
Screen Shot 2020-06-06 at 10 53 12 PM

If it's quick to add, support desktop version as well. If not it's lower priority and should be created as a separate Issue, so notify @racedale & @magnificode
Desktop:
Screen Shot 2020-06-06 at 10 16 50 PM

Contact Interactions on About Page

Contact Section

AC:
Given a user clicks:

  • Business owners: then open a blank Chakra modal (content added in later story)
  • General Inquiry: mailto: (email to be provided later)
  • Volunteers: Discord link (join.rebuildblackbusiness.com)

Desktop:
Screen Shot 2020-06-07 at 11 23 32 AM

Mobile:
Screen Shot 2020-06-07 at 11 24 59 AM

Fix Cypress errors

As a developer
I want the tests to be passing to be able to ensure quality to our users

There's a few errors around navigation and a11y issues

Note:
npm run test:e2e:ci will execute Cypress tests

Add license to repo

Hi there, I lead the Open Source Initiative as well as open source at Salesforce and I'd love to be able to contribute to your project. However, in getting acquainted with the project I noticed that the various repositories lack a clear license.

Would you mind adding a LICENSE file to your repos?

I have no opinions on what license should be used (of course prefer an open source license), but a quick scan of the vendored code in this particular repo suggests MIT would be a reasonable choice. https://opensource.org/licenses/MIT

Thanks so much!

Update orange in theme for a11y

Lighthouse was failing for Background and foreground colors do not have a sufficient contrast ratio.

AC:
Update rbb-orange to #F05F37

Upgrade graphql-playground-html

Upgrade graphql-playground-html to version 1.6.22 or later.

Since this is a dependency of Gatsby this will be achieved by updating gatsby

Use npm ls graphql-playground-html to verify

Create filtering and sorting logic

Business Filtering

Screen Shot 2020-06-05 at 11 08 43 AM

Filters should be created to allow a user to filter results from the BusinessInNeedFeed component by the following criteria:

  • Business Type

    • Label: "Business"
    • Type: single select
      • Options: "Entertainment", "Food and beverage", "Health and wellness", "Professional services", "Retail"
    • Placeholder: "Select type"
  • Location

    • Label: "Location"
    • Type: text
      • Allow users to type their city. i.e "Denver" should return any business who's location includes "Denver".
    • Placeholder: "Enter city"
  • Need

    • Label: "Need"
    • Type: single select
      • For V1 this should be a "disabled" field that pre-populates with an "Impacted by protests" option.
      • For V1 this select field will not affect filtered results. The business filters will only display businesses in need.
  • Submit

    • Type: submit
    • Label: "Search"
    • On click of the submit button or on 'enter', the filtered results should appear below the filters without a page refresh.

Resource Filtering

Screen Shot 2020-06-05 at 11 19 21 AM

Filters should be created to allow a user to filter results from the SupportingOrgFeed component by the following criteria:

  • Resources For

    • Type: single select
      • Options: "Ally", "Business owner"
    • Label: "Resources for"
    • Placeholder: "Who are you?"
  • Location

    • Label: "Location"
    • Type: text
      • Allow users to type their city. i.e "Denver" should return any business who's location includes "Denver".
    • Placeholder: "Enter city"
  • Submit

    • Type: submit
    • Label: "Search"
    • On click of the submit button or on 'enter', the filtered results should appear below the filters without a page refresh.

Ally Filtering

71cb190824b43e77781da33212907e42

  • Skill

    • Type: single select
    • Label: "Skill"
    • Placeholder text: "What do you need?"
    • Options:
      • Business
      • Marketing
      • Outreach
      • Tech
      • Government
  • Location

    • Label: "Location"
    • Type: text
      • Allow users to type their city. i.e "Denver" should return any ally who's location includes "Denver".
    • Placeholder: "Enter city"
  • Submit

    • Type: submit
    • Label: "Search"
    • On click of the submit button or on 'enter', the filtered results should appear below the filters without a page refresh.

Filter Results

The results should be dynamically updated upon user hitting "Search" or hitting "return" on their keyboard as any normal form would.

IMPORTANT :: Accessibility needs to be top of mind for the results, please refer to https://developer.mozilla.org/en-US/docs/Web/Accessibility/ARIA/ARIA_Live_Regions to ensure that live updated regions are properly announced to screen readers.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.