-
Notifications
You must be signed in to change notification settings - Fork 10
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
Fixed few bugs present in NewHomePage look #443
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -11,3 +11,8 @@ | |
height: 100%; | ||
width: 100%; | ||
} | ||
|
||
.panel-with-radius { | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. @saimedhi This radius style should only be applied to the containers within the Visual Editor. The "Manage workflow/Create workflow" page should use the default containers. |
||
border-radius: 4px; | ||
overflow: hidden; | ||
} |
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. This has introduced a regression, the bottom panel seems to be getting cut off now. And because of this, if collapsing the Inspector panel, the button to reopen it is no longer visible. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. |
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -39,20 +39,20 @@ export const renderApp = ( | |
params.element | ||
); | ||
|
||
const EXPECTED_BASE_PATH = `/app/${PLUGIN_ID}#`; | ||
const handleLinkClick = (event: MouseEvent) => { | ||
const anchorTag = (event.target as HTMLElement).closest( | ||
'a' | ||
) as HTMLAnchorElement | null; | ||
|
||
const unlistenParentHistory = params.history.listen(() => { | ||
if ( | ||
hideInAppSideNavBar && | ||
window.location.pathname.endsWith(`/app/${PLUGIN_ID}`) | ||
) { | ||
window.location.href = EXPECTED_BASE_PATH; | ||
if (anchorTag && anchorTag.href.endsWith(`/app/${PLUGIN_ID}`)) { | ||
window.location.href = anchorTag.href + '#'; | ||
window.dispatchEvent(new HashChangeEvent('hashchange')); | ||
} | ||
}); | ||
}; | ||
document.addEventListener('click', handleLinkClick); | ||
Comment on lines
+42
to
+52
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. If I understand correctly, this is performing this logic for every mouse click? This could add a performance hit, and feels like a workaround to me. Can you take a look at AD plugins, or reach out to core OSD team to get better insight on how to fix the problem? There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. This workaround is done to handle below scenario:
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Understandable. But I still have the same concerns as mentioned. Can you follow up with AD plugin and/or core OSD team? |
||
|
||
return () => { | ||
ReactDOM.unmountComponentAtNode(params.element); | ||
unlistenParentHistory(); | ||
document.removeEventListener('click', handleLinkClick); | ||
}; | ||
}; |
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.
Have you discussed with @opensearch-project/opensearch-ux on this change?
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.
Yes, UX team suggested to
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.
@saimedhi Which navigation is this referring to? Does this only apply to the old look and feel?
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.
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.
@saimedhi As mentioned in #444, we can hide this navigation on both list page, create page, and visual editor.