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

Fixed few bugs present in NewHomePage look #443

Closed
wants to merge 2 commits into from

Conversation

saimedhi
Copy link
Collaborator

@saimedhi saimedhi commented Oct 29, 2024

Description

screen-capture.23.webm

Issues Resolved

closes #442

Check List

  • New functionality includes testing.
    • All tests pass
  • New functionality has been documented.
  • Commits are signed per the DCO using --signoff

By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.
For more information on following Developer Certificate of Origin and signing off your commits, please check here.

Signed-off-by: saimedhi <[email protected]>
@saimedhi saimedhi changed the title Fixed bugs Fixed few bugs present in NewHomePage look Oct 29, 2024
@saimedhi saimedhi marked this pull request as ready for review October 29, 2024 20:26
@saimedhi saimedhi marked this pull request as draft October 29, 2024 20:26
Signed-off-by: Sai Medhini Reddy Maryada <[email protected]>
@saimedhi saimedhi marked this pull request as ready for review October 29, 2024 20:40
@saimedhi
Copy link
Collaborator Author

saimedhi commented Oct 29, 2024

@ohltyler, please take a look. In the next PR will reduce padding between panels in workflow detail page.

Copy link
Member

Choose a reason for hiding this comment

The 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.

Copy link
Member

Choose a reason for hiding this comment

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

Screenshot 2024-10-29 at 3 02 10 PM

Comment on lines +42 to +52
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);
Copy link
Member

Choose a reason for hiding this comment

The 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?

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 workaround is done to handle below scenario:

  • In the NewHomePage - workflow details page, clicking search studio from sidenav will not redirect to flow framework dashboards home page (workflows list page).
  • Reason : expected url by flow framework plugin is '/app/search-studio#' but getting '/app/search-studio'

Copy link
Member

Choose a reason for hiding this comment

The 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?

Comment on lines +45 to +51
const isWorkflowDetailPage = location.pathname.includes(
APP_PATH.WORKFLOW_DETAIL.split(':')[0]
);
const sidebar = (
<EuiPageSideBar
style={{ minWidth: 190 }}
hidden={hideInAppSideNavBar}
hidden={isWorkflowDetailPage || hideInAppSideNavBar}
Copy link
Member

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?

Copy link
Collaborator Author

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

  • Hide navigation on the old look and feel for the Visual Editor.
  • List view should show the navigation.

Copy link

@kamingleung kamingleung Oct 29, 2024

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?

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

  • The side nav shown below is only be visible on List view (old look).
Screenshot 2024-10-29 at 4 12 23 PM

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.

@@ -11,3 +11,8 @@
height: 100%;
width: 100%;
}

.panel-with-radius {
Copy link

@kamingleung kamingleung Oct 29, 2024

Choose a reason for hiding this comment

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

@saimedhi
Can we reuse the same styles from the new Discover?
It should be border-radius: 8px

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.

@saimedhi saimedhi marked this pull request as draft October 30, 2024 17:04
@saimedhi
Copy link
Collaborator Author

Closing this PR as part of this is covered in #447. Will raise separate PRs to fix each bug.

@saimedhi saimedhi closed this Oct 30, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[BUG]When clicking on workflows from workflows list not entering into workflow editor page
3 participants