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

1427/listing management preferences #1564

Merged
merged 10 commits into from
Jul 28, 2021
Merged

1427/listing management preferences #1564

merged 10 commits into from
Jul 28, 2021

Conversation

emilyjablonski
Copy link
Collaborator

@emilyjablonski emilyjablonski commented Jul 22, 2021

Pull Request Template

Issue

Addresses #1427

  • This change addresses the issue in full
  • This change addresses only certain aspects of the issue
  • This change is a dependency for another issue
  • This change has a dependency from another issue

Description

Adds the preferences section to listings management. Check it out in partners.

The issue has some designs for separating preferences by jurisdiction but we don't currently have that data so I wasn't able to do that (unclear if that should be handled here or not, pinged the channel and commented on the issue). So for now I'm just filtering on unique preferences. Keep in mind the two housing preferences from Coliseum in our seed data are treated a little differently and purposefully do not appear on the listing page.

Type of change

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • Prototype/POC (not to merge)
  • This change is a refactor/address technical debt
  • This change requires a documentation update
  • This change requires a SQL Script

How Can This Be Tested/Reviewed?

Create a new listing in listings management and check out the new preferences section. Save the listing then re-edit it. Preview the preferences on the listing page.

Checklist:

  • My code follows the style guidelines of this project
  • I have performed a self-review of my own code
  • I have reviewed the changes in a desktop view
  • I have reviewed the changes in a mobile view
  • I have commented my code, particularly in hard-to-understand areas
  • I have made corresponding changes to the documentation
  • My changes generate no new warnings
    Note: react-beautiful-dnd is throwing a scroll warning on drag but it doesn't seem to actually be causing any issue, and based on the activity on the issue about it, I'm not sure there is anything I can do to remove the warning until they put in a fix
  • I have added tests that prove my fix is effective or that my feature works
  • New and existing unit tests pass locally with my changes
  • Any dependent changes have been merged and published in downstream modules
  • I have assigned reviewers
  • I have updated the changelog to include a description of my changes

@emilyjablonski emilyjablonski added the wip This PR is not ready for review, do not review it's a “Work In Progress” label Jul 22, 2021
@netlify
Copy link

netlify bot commented Jul 22, 2021

✔️ Deploy Preview for dev-bloom ready!

🔨 Explore the source changes: 5badfd2

🔍 Inspect the deploy log: https://app.netlify.com/sites/dev-bloom/deploys/6101953bfa92b20008fb179c

😎 Browse the preview: https://deploy-preview-1564--dev-bloom.netlify.app

@netlify
Copy link

netlify bot commented Jul 22, 2021

✔️ Deploy Preview for jovial-davinci-1d67a0 ready!

🔨 Explore the source changes: 5badfd2

🔍 Inspect the deploy log: https://app.netlify.com/sites/jovial-davinci-1d67a0/deploys/6101953bdc38720007e37502

😎 Browse the preview: https://deploy-preview-1564--jovial-davinci-1d67a0.netlify.app

@netlify
Copy link

netlify bot commented Jul 22, 2021

✔️ Deploy Preview for dev-partners-bloom ready!

🔨 Explore the source changes: 5badfd2

🔍 Inspect the deploy log: https://app.netlify.com/sites/dev-partners-bloom/deploys/6101953b486c30000726f23a

😎 Browse the preview: https://deploy-preview-1564--dev-partners-bloom.netlify.app

@netlify
Copy link

netlify bot commented Jul 22, 2021

✔️ Deploy Preview for dev-storybook-bloom ready!

🔨 Explore the source changes: 5badfd2

🔍 Inspect the deploy log: https://app.netlify.com/sites/dev-storybook-bloom/deploys/6101953b8b22e90008939f32

😎 Browse the preview: https://deploy-preview-1564--dev-storybook-bloom.netlify.app

@@ -44,7 +44,6 @@

.fixed-overlay__inner {
transition-property: transform, opacity;
transform: translate(0px, 0px);
Copy link
Collaborator Author

Choose a reason for hiding this comment

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

This was causing a visual bug in the draggable table (weird, I know) - the best suggestion from forums on the package was to remove this style. Let me know if this will cause any other issues, but removing it didn't seem to cause any changes at all.

@emilyjablonski emilyjablonski marked this pull request as ready for review July 23, 2021 17:56
@emilyjablonski emilyjablonski added ready for review and removed wip This PR is not ready for review, do not review it's a “Work In Progress” labels Jul 23, 2021
Copy link
Collaborator

@dominikx96 dominikx96 left a comment

Choose a reason for hiding this comment

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

@emilyjablonski just a few minor comments, really great work!
LGTM

inset
>
<ViewItem label={t("listings.activePreferences")} className={"mb-2"} />
{listing?.preferences.length ? (
Copy link
Collaborator

Choose a reason for hiding this comment

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

I think it would be more clear to check preferenceTableData length, instead of listing?.preferences.length because we use this data here :)

@@ -3,6 +3,7 @@ import { TableHeaders, StandardTable } from "./StandardTable"

interface MinimalTableProps {
draggable?: boolean
setData?: (data: any[]) => void
Copy link
Collaborator

Choose a reason for hiding this comment

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

I think unknown would be better as a type here.

@@ -26,6 +26,7 @@ export const TableThumbnail = (props: { children: React.ReactNode }) => {

export interface StandardTableProps {
draggable?: boolean
setData?: (data: any[]) => void
Copy link
Collaborator

Choose a reason for hiding this comment

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

See comment above.

@emilyjablonski emilyjablonski added wip This PR is not ready for review, do not review it's a “Work In Progress” and removed ready for review labels Jul 27, 2021
@emilyjablonski emilyjablonski added ready for review and removed wip This PR is not ready for review, do not review it's a “Work In Progress” labels Jul 27, 2021
@seanmalbert seanmalbert merged commit 2f67e06 into dev Jul 28, 2021
seanmalbert referenced this pull request in CityOfDetroit/bloom Jun 23, 2022
* 1427/listing management preferences

* submit and display preferences

* changelog

* dragging wip

* dragging wip 2

* save order bug

* cleanup

* add protective optionals

* pr feedback

* adds key to react fragment

Co-authored-by: seanmalbert <smabert@gmail.com>
@emilyjablonski emilyjablonski deleted the 1437/preferences branch July 20, 2022 22:58
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.

None yet

3 participants