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

[workspace]Fix/the UI of workspace list table #8219

Merged

Conversation

Qxisylolo
Copy link
Contributor

@Qxisylolo Qxisylolo commented Sep 18, 2024

Description

This pr fixes the style of workspace list table(addressing issues 217-227, and 232-233) by:

  1. Change the default number of the rows displayed in the table to 20
  2. tooltip misalignment can be fixed with pr [Bug] Fix the tooltip display misalignment issue #8202
  3. some styles associated with padding and compressed search bar/ filters

Screenshot

截屏2024-10-09 17 09 10 截屏2024-10-09 17 09 22 截屏2024-10-09 17 09 25

Changelog

  • fix: Fix/the UI of workspace list table

Check List

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

Copy link

codecov bot commented Sep 29, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 60.87%. Comparing base (f06a478) to head (e3dab00).
Report is 2 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #8219      +/-   ##
==========================================
+ Coverage   60.86%   60.87%   +0.01%     
==========================================
  Files        3808     3808              
  Lines       91209    91209              
  Branches    14410    14410              
==========================================
+ Hits        55514    55528      +14     
+ Misses      32154    32140      -14     
  Partials     3541     3541              
Flag Coverage Δ
Linux_1 29.04% <100.00%> (+0.02%) ⬆️
Linux_2 56.38% <ø> (ø)
Linux_3 37.92% <ø> (?)
Linux_4 29.01% <ø> (ø)
Windows_1 29.05% <100.00%> (+0.02%) ⬆️
Windows_2 56.34% <ø> (ø)
Windows_3 37.93% <ø> (ø)
Windows_4 29.01% <ø> (ø)

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

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@Qxisylolo Qxisylolo force-pushed the fix/the-UI-of-workspace-list-table branch from 92c2b34 to 4886299 Compare October 9, 2024 09:12
opensearch-changeset-bot bot added a commit to Qxisylolo/OpenSearch-Dashboards that referenced this pull request Oct 9, 2024
@Qxisylolo Qxisylolo force-pushed the fix/the-UI-of-workspace-list-table branch from c378907 to 0f61a69 Compare October 9, 2024 09:16
@ruanyl ruanyl added workspace and removed 2.17.1 labels Oct 29, 2024
Copy link
Member

@ruanyl ruanyl left a comment

Choose a reason for hiding this comment

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

I see there is a conflict now, you may need to address :)

return isDashboardAdmin ? (
<>
<EuiButton color="danger" iconType="trash" onClick={onClick}>
Delete {selection.length} {selection.length > 1 ? 'workspaces' : 'workspace'}
Copy link
Member

Choose a reason for hiding this comment

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

Let's add i18n for the text, take this as example:

<FormattedMessage
  id="dataSourcesManagement.dataSourcesTable.dissociateSelectedDataSources"
  defaultMessage="{selectionSize, plural, one {Remove # association} other {Remove # associations}}"
  values={{ selectionSize: selectedDataSources.length }}
/>

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Thanks for your comments, already updated.

@Qxisylolo Qxisylolo force-pushed the fix/the-UI-of-workspace-list-table branch from 0f61a69 to 9bf0be9 Compare October 31, 2024 06:01
opensearch-changeset-bot bot added a commit to Qxisylolo/OpenSearch-Dashboards that referenced this pull request Oct 31, 2024
Comment on lines 355 to 361
{i18n.translate('workspace.list.page.delete.button.info', {
defaultMessage: 'Delete {num} workspace{pluralSuffix, select, true {} other {s}}',
values: {
num: selection.length,
pluralSuffix: selection.length === 1,
},
})}
Copy link
Member

Choose a reason for hiding this comment

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

Suggested change
{i18n.translate('workspace.list.page.delete.button.info', {
defaultMessage: 'Delete {num} workspace{pluralSuffix, select, true {} other {s}}',
values: {
num: selection.length,
pluralSuffix: selection.length === 1,
},
})}
{i18n.translate('workspace.list.page.delete.button.info', {
defaultMessage:
'{selectedCount, plural, one {Delete # workspace} other {Delete # workspaces}}',
values: {
selectedCount: selection.length,
},
})}

Copy link
Contributor Author

Choose a reason for hiding this comment

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

thank you! already updated.

@Qxisylolo Qxisylolo force-pushed the fix/the-UI-of-workspace-list-table branch from 7176e0f to f52af39 Compare November 11, 2024 07:15
@ruanyl ruanyl merged commit 9d21b81 into opensearch-project:main Dec 19, 2024
69 checks passed
opensearch-trigger-bot bot pushed a commit that referenced this pull request Dec 19, 2024
* fix/ fix the_UI_of_workspace_list

Signed-off-by: Qxisylolo <[email protected]>

* fix/ fix the_UI_of_workspace_list_mostly_done

Signed-off-by: Qxisylolo <[email protected]>

* fix/ fix the_UI_of_workspace_list_typo_mistake

Signed-off-by: Qxisylolo <[email protected]>

* fix/the-UI-of-workspace-list-table, delete owner filter

Signed-off-by: Qxisylolo <[email protected]>

* fix/the-UI-of-workspace-list-table, fix a small bug

Signed-off-by: Qxisylolo <[email protected]>

* resolve comments, add tests

Signed-off-by: Qxisylolo <[email protected]>

* solve conflicts, update tests

Signed-off-by: Qxisylolo <[email protected]>

* Changeset file for PR #8219 created/updated

---------

Signed-off-by: Qxisylolo <[email protected]>
Co-authored-by: opensearch-changeset-bot[bot] <154024398+opensearch-changeset-bot[bot]@users.noreply.github.com>
Co-authored-by: Yulong Ruan <[email protected]>
(cherry picked from commit 9d21b81)
Signed-off-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
SuZhou-Joe pushed a commit that referenced this pull request Dec 24, 2024
* fix/ fix the_UI_of_workspace_list



* fix/ fix the_UI_of_workspace_list_mostly_done



* fix/ fix the_UI_of_workspace_list_typo_mistake



* fix/the-UI-of-workspace-list-table, delete owner filter



* fix/the-UI-of-workspace-list-table, fix a small bug



* resolve comments, add tests



* solve conflicts, update tests



* Changeset file for PR #8219 created/updated

---------




(cherry picked from commit 9d21b81)

Signed-off-by: Qxisylolo <[email protected]>
Signed-off-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
Co-authored-by: opensearch-changeset-bot[bot] <154024398+opensearch-changeset-bot[bot]@users.noreply.github.com>
Co-authored-by: Yulong Ruan <[email protected]>
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