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
Extend API Switcher to Context Selector #137
Extend API Switcher to Context Selector #137
Conversation
"react": "^16.0.0", | ||
"react-dom": "^16.0.0", | ||
"react": "^16.5.2", | ||
"react-dom": "^16.5.2", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Missing yarn.lock, was this updated with npm? Is it needed for React.Fragments, right?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
No and yes, fixing now
@@ -144,7 +144,7 @@ | |||
"css-loader": "^0.28.9", | |||
"empty": "^0.10.1", | |||
"enzyme": "^3.3.0", | |||
"enzyme-adapter-react-16": "^1.1.1", | |||
"enzyme-adapter-react-16": "^1.6.0", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
same here, update and lock the dependency
case 'monitoring': | ||
return `API: ${currentApi.service.name}` | ||
|
||
default: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
it could be useful to have default "Dashboard", and write a simple test with some of the options. Also, next iteration applying flow types and define currentApi
, since we are relying on it calling 2 methods.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
How about Choose an API as default case?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🥇
What this PR does / why we need it:
Refactors and extends current API switcher into a ContextSelector component. It features a quick link to Audience before the usual API browser and also displays the name of the current context.
Which issue(s) this PR fixes
https://issues.jboss.org/browse/THREESCALE-1395