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

[Backport workspace] Left navigation menu adjustment (#192) #233

Merged
merged 6 commits into from
Oct 26, 2023
Merged

[Backport workspace] Left navigation menu adjustment (#192) #233

merged 6 commits into from
Oct 26, 2023

Conversation

yuye-aws
Copy link
Collaborator

@yuye-aws yuye-aws commented Oct 18, 2023

Description

This is the backport PR from #192. Changes include:

  1. Nav link service
  2. WorkspaceObject type
  3. Bring back custom nav link in left menu
  4. Add unit tests for nav links and filtering logic.

Issues Resolved

Screenshot

Testing the changes

Check List

  • All tests pass
    • yarn test:jest
    • yarn test:jest_integration
    • yarn test:ftr
  • New functionality includes testing.
  • New functionality has been documented.
  • Update CHANGELOG.md
  • Commits are signed per the DCO using --signoff

yuye-aws and others added 5 commits October 18, 2023 11:04
* add util function to filter workspace feature by wildcard

Signed-off-by: Yulong Ruan <ruanyl@amazon.com>

* resolve conflict

Signed-off-by: yuye-aws <yuyezhu@amazon.com>

* update tests and snapshots

Signed-off-by: yuye-aws <yuyezhu@amazon.com>

* small adjustment to left menu

Signed-off-by: yuye-aws <yuyezhu@amazon.com>

* resolve git conflict

Signed-off-by: yuye-aws <yuyezhu@amazon.com>

* rename nav link service function

Signed-off-by: yuye-aws <yuyezhu@amazon.com>

* unit test for workspace plugin.ts

Signed-off-by: yuye-aws <yuyezhu@amazon.com>

* update snapshots

Signed-off-by: yuye-aws <yuyezhu@amazon.com>

* optimize code

Signed-off-by: yuye-aws <yuyezhu@amazon.com>

* optimize code

Signed-off-by: yuye-aws <yuyezhu@amazon.com>

* optimize code

Signed-off-by: yuye-aws <yuyezhu@amazon.com>

* optimize code

Signed-off-by: yuye-aws <yuyezhu@amazon.com>

* optimize code

Signed-off-by: yuye-aws <yuyezhu@amazon.com>

* optimize code

Signed-off-by: yuye-aws <yuyezhu@amazon.com>

---------

Signed-off-by: Yulong Ruan <ruanyl@amazon.com>
Signed-off-by: yuye-aws <yuyezhu@amazon.com>
Co-authored-by: Yulong Ruan <ruanyl@amazon.com>
Signed-off-by: yuye-aws <yuyezhu@amazon.com>
Signed-off-by: yuye-aws <yuyezhu@amazon.com>
Signed-off-by: yuye-aws <yuyezhu@amazon.com>
Signed-off-by: yuye-aws <yuyezhu@amazon.com>
Signed-off-by: yuye-aws <yuyezhu@amazon.com>
@codecov-commenter
Copy link

codecov-commenter commented Oct 18, 2023

Codecov Report

Merging #233 (942484f) into workspace (7a72a73) will decrease coverage by 10.86%.
Report is 1 commits behind head on workspace.
The diff coverage is 57.71%.

@@              Coverage Diff               @@
##           workspace     #233       +/-   ##
==============================================
- Coverage      66.19%   55.34%   -10.86%     
==============================================
  Files           3431     3149      -282     
  Lines          65952    62254     -3698     
  Branches       10616    10078      -538     
==============================================
- Hits           43659    34456     -9203     
- Misses         19645    25677     +6032     
+ Partials        2648     2121      -527     
Flag Coverage Δ
Linux_1 30.88% <57.71%> (+0.31%) ⬆️
Linux_2 ?
Linux_3 42.78% <5.88%> (+0.01%) ⬆️
Linux_4 34.53% <5.88%> (+<0.01%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

Files Coverage Δ
src/core/public/chrome/chrome_service.mock.ts 83.33% <ø> (-16.67%) ⬇️
src/core/public/chrome/chrome_service.tsx 1.33% <ø> (-85.34%) ⬇️
...c/core/public/workspace/workspaces_service.mock.ts 100.00% <100.00%> (ø)
src/plugins/workspace/common/constants.ts 100.00% <ø> (ø)
...nents/workspace_creator/workspace_cancel_modal.tsx 100.00% <100.00%> (ø)
...components/workspace_creator/workspace_creator.tsx 76.47% <ø> (ø)
...ents/workspace_creator/workspace_icon_selector.tsx 100.00% <100.00%> (ø)
src/plugins/workspace/public/plugin.ts 68.65% <100.00%> (+28.35%) ⬆️
src/core/public/chrome/ui/header/nav_link.tsx 13.04% <0.00%> (-56.53%) ⬇️
src/core/public/workspace/workspaces_service.ts 0.00% <0.00%> (-88.89%) ⬇️
... and 5 more

... and 696 files with indirect coverage changes

📣 We’re building smart automated test selection to slash your CI/CD build times. Learn more

@yuye-aws yuye-aws merged commit f4dfa30 into ruanyl:workspace Oct 26, 2023
25 of 27 checks passed
@opensearch-workspace-development

The backport to workspace-pr-integr failed:

The process '/usr/bin/git' failed with exit code 128

To backport manually, run these commands in your terminal:

# Navigate to the root of your repository
cd $(git rev-parse --show-toplevel)
# Fetch latest updates from GitHub
git fetch
# Create a new working tree
git worktree add ../.worktrees/OpenSearch-Dashboards/backport-workspace-pr-integr workspace-pr-integr
# Navigate to the new working tree
pushd ../.worktrees/OpenSearch-Dashboards/backport-workspace-pr-integr
# Create a new branch
git switch --create backport/backport-233-to-workspace-pr-integr
# Cherry-pick the merged commit of this pull request and resolve the conflicts
git cherry-pick -x --mainline 1 f4dfa3094f8aed8d0c606b2c32729c31db9b79ee
# Push it to GitHub
git push --set-upstream origin backport/backport-233-to-workspace-pr-integr
# Go back to the original working tree
popd
# Delete the working tree
git worktree remove ../.worktrees/OpenSearch-Dashboards/backport-workspace-pr-integr

Then, create a pull request where the base branch is workspace-pr-integr and the compare/head branch is backport/backport-233-to-workspace-pr-integr.

@yuye-aws yuye-aws deleted the backport/backport-192-to-workspace branch January 3, 2024 09:24
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.

3 participants