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

Multiselect's value is an array of strings #80

Merged
merged 3 commits into from
Dec 8, 2020

Conversation

jasalisbury
Copy link

Description of change
The multiselect component used an array of objects for the value with the shape [{ label: ..., value: ... }]. This PR updates the value to be an array of strings.

Add testing library linter and fix all the violations.

I had a good fight getting the new linter to work in VS code. If you find eslint inside vs code no longer works after pulling this change down try to set

    "eslint.workingDirectories": [
        ".", "./frontend"
    ],

in your vscode settings.json file.

How to test

  1. Pull down code, install dependencies
  2. Fill out an activity report, make sure your console is open
  3. Click submit, in your console any multiselect field should have a value like ["one", "two", ...], while previously the value would be [{label: "one", value: "one"}, ...]

Issue(s)

Checklist

  • [n/a] Meets issue criteria
  • Code tested
  • [n/a] Meets accessibility standards (WCAG 2.1 Levels A, AA)
  • [n/a] Documentation updated

The multiselect component used an array of objects for the value with
the shape [{ label: ..., value: ... }]. This commint updates the value
to be an array of strings.

Add testing library linter.
Conflicts:
	frontend/src/components/__tests__/DatePicker.js
	frontend/src/pages/ActivityReport/__tests__/index.js
	frontend/yarn.lock
Copy link
Collaborator

@kryswisnaskas kryswisnaskas left a comment

Choose a reason for hiding this comment

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

Looks good!

@jasalisbury jasalisbury merged commit e536ba3 into main Dec 8, 2020
@jasalisbury jasalisbury deleted the js-98-multiselect-array-value branch December 8, 2020 20:49
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.

2 participants