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

General Bug Fixes/Additons #96

Merged
merged 96 commits into from
Oct 23, 2018
Merged

General Bug Fixes/Additons #96

merged 96 commits into from
Oct 23, 2018

Conversation

walmat
Copy link
Owner

@walmat walmat commented Oct 18, 2018

/fixes #88

Encapsulated is a bit of work that needs to be merged to master and rebased onto the parsing branch.

You can view the full list of items on the issue (some of them I've decided to wait until a later date to implement).

This shouldn't be merged just yet until I figure out how to iron out the bugs with the captcha windows fixed in recent commits

  • fix build / add tests

walmat and others added 27 commits October 13, 2018 15:45
This commit changes the styling for multi value selects to allow for horizontal scrolling when selected items overflow the select containers area. This is done by setting `flex-wrap` to `nowrap` and `overflow-x` to `scroll` on the value container (when we are a multi value container), and setting the `flex-shrink` to 0 on multi value items.
@walmat walmat requested a review from pr1sm October 18, 2018 21:52
Copy link
Collaborator

@pr1sm pr1sm left a comment

Choose a reason for hiding this comment

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

Nice job on the Tests!

Just a couple of small things to fix

frontend/src/__tests__/constants/getAllSizes.test.jsx Outdated Show resolved Hide resolved
frontend/src/__tests__/navbar/navbar.test.jsx Outdated Show resolved Hide resolved
frontend/src/settings/settings.jsx Show resolved Hide resolved
frontend/src/state/reducers/tasks/taskListReducer.js Outdated Show resolved Hide resolved
@@ -0,0 +1,65 @@
class Token {
Copy link
Collaborator

Choose a reason for hiding this comment

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

Bumping this since I don't think it's been resolved yet.
https://github.com/walmat/nebula/pull/96/files#r226848357

@pr1sm pr1sm mentioned this pull request Oct 23, 2018
@pr1sm
Copy link
Collaborator

pr1sm commented Oct 23, 2018

Coverage looks great too! 💯

Copy link
Collaborator

@pr1sm pr1sm left a comment

Choose a reason for hiding this comment

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

Just a couple more changes, then I think this will be good to go

frontend/src/state/reducers/server/serverReducer.js Outdated Show resolved Hide resolved
errors: Object.assign({}, state.edits.errors, action.errors),
product: initialTaskStates.edit.product,
change = {
...state.edits,
Copy link
Collaborator

Choose a reason for hiding this comment

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

This should go inside the edits object, not inside change itself. This is probably why the tests are all failing.

Copy link
Owner Author

Choose a reason for hiding this comment

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

any tips?

if (action.value) {
            change = {
              edits: {
                ...state.edits,
                errors: Object.assign({}, state.edits.errors, action.errors),
                product: {
                  raw: action.value,
                },
              },
            };
            if (!action.value || !action.value.startsWith('http')) {
              break;
            }
            const URL = parseURL(action.value);
            if (!URL || !URL.path) {
              break;
            }
            const site = getAllSites().filter(s => s.value.split('/')[2] === URL.host);
            if (site.length === 0) {
              break;
            }
            console.log(change);
            change = {
              ...change,
              edits: {
                ...change.edits,
                site: {
                  url: site[0].value,
                  name: site[0].label,
                },
                username: null,
                password: null,
              },
            };
          } else {
            change = {
              edits: {
                ...state.edits,
                errors: Object.assign({}, state.edits.errors, action.errors),
                product: initialTaskStates.edit.product,
              },
            };
          }

Copy link
Collaborator

Choose a reason for hiding this comment

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

Is there a need for the else case at the end? If we don't have a value passed with the action, there should be no change, right?

Copy link
Owner Author

Choose a reason for hiding this comment

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

Idk I was working backwards and comparing it to when it worked. Seems to be a bug when edits.product === null

break;
}
change = {
...change,
Copy link
Collaborator

Choose a reason for hiding this comment

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

This line is also redundant since at this point, change is only an object that contains an edits object, which we explicitly redefine in the line below.

Copy link
Collaborator

@pr1sm pr1sm left a comment

Choose a reason for hiding this comment

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

I think this is good to go!

@pr1sm
Copy link
Collaborator

pr1sm commented Oct 23, 2018

merging...

@pr1sm pr1sm merged commit 3860687 into master Oct 23, 2018
@walmat walmat deleted the issue_88 branch October 23, 2018 20:37
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.

General Bug Fixes / Additions Pre-launch
2 participants