Skip to content

Conversation

@broccolinisoup
Copy link
Member

@broccolinisoup broccolinisoup commented Oct 17, 2024

Closes https://github.com/github/primer/issues/3922, https://github.com/github/primer/issues/4104

Implementing empty state for SelectPanel. Default message and the ability to customise them when there is no item to show either in the first load or when filtering (Under primer_react_select_panel_with_modern_action_list FF).

Changelog

New

  • SelectPanel.Message child component
  • When there is no item to show after the initial load, we now show a message. There is a default message and ability to customise it.
<SelectPanel .....>
  <SelectPanel.Message variant="empty" title={`No label found`}>
    Start creating some labels
  </SelectPanel.Message>
</SelectPanel>
  • When there is no item to show after user filters the result, we now show a message. There is a default message and ability to customise it.
<SelectPanel .....>
  <SelectPanel.Message variant="noResults" title={`No language found for `}>
    Adjust your search term to find other languages
  </SelectPanel.Message>
</SelectPanel>
No initial Item
Screenshot of the select panel that doesn't have any items to show. There is a message says You haven't created any projects yet. Start your first project to organise your issues.
No filtered Item demo

Video description:

Rewatch.Screen.Recording.-.2024-10-24.at.1.55.52.PM.mp4

Changed

  • SelectPanel accepts children now

Removed

Rollout strategy

  • Patch release
  • Minor release
  • Major release; if selected, include a written rollout or migration plan
  • None; if selected, include a brief description as to why

Testing & Reviewing

  • This and This are a good stories to test the behaviour. Please note primer_react_select_panel_with_modern_action_list FF must be on

Merge checklist

@changeset-bot
Copy link

changeset-bot bot commented Oct 17, 2024

🦋 Changeset detected

Latest commit: d3d6875

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 1 package
Name Type
@primer/react Minor

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

@github-actions github-actions bot added the staff Author is a staff member label Oct 17, 2024
@github-actions
Copy link
Contributor

👋 Hi, this pull request contains changes to the source code that github/github depends on. If you are GitHub staff, we recommend testing these changes with github/github using the integration workflow. Thanks!

@github-actions github-actions bot added the integration-tests: recommended This change needs to be tested for breaking changes. See https://arc.net/l/quote/tdmpakpm label Oct 17, 2024
@github-actions github-actions bot temporarily deployed to storybook-preview-5142 October 17, 2024 04:59 Inactive
@github-actions
Copy link
Contributor

github-actions bot commented Oct 17, 2024

size-limit report 📦

Path Size
packages/react/dist/browser.esm.js 105.78 KB (-0.01% 🔽)
packages/react/dist/browser.umd.js 106.17 KB (+0.04% 🔺)

@broccolinisoup broccolinisoup changed the title select panel empty state SelectPanel: Implement empty state Oct 17, 2024
@broccolinisoup broccolinisoup changed the base branch from main to revert-5136-revert-4929-select_panel_loading_states October 21, 2024 00:31
textInputProps={extendedTextInputProps}
loading={loading || isLoading}
loadingType={loadingType()}
// hack because the deprecated ActionList does not support this prop
Copy link
Contributor

Choose a reason for hiding this comment

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

Ohhhh nice way to bridge this!

Copy link
Member

Choose a reason for hiding this comment

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

jijiji

@github-actions
Copy link
Contributor

👋 Hi, there are new commits since the last successful integration test. We recommend running the integration workflow once more, unless you are sure the new changes do not affect github/github. Thanks!

@francinelucca francinelucca added the update snapshots 🤖 Command that updates VRT snapshots on the pull request label Mar 25, 2025
@github-actions github-actions bot removed the update snapshots 🤖 Command that updates VRT snapshots on the pull request label Mar 25, 2025
@github-actions
Copy link
Contributor

👋 Hi, there are new commits since the last successful integration test. We recommend running the integration workflow once more, unless you are sure the new changes do not affect github/github. Thanks!

@github-actions
Copy link
Contributor

👋 Hi, there are new commits since the last successful integration test. We recommend running the integration workflow once more, unless you are sure the new changes do not affect github/github. Thanks!

@github-actions
Copy link
Contributor

👋 Hi, there are new commits since the last successful integration test. We recommend running the integration workflow once more, unless you are sure the new changes do not affect github/github. Thanks!

@github-actions github-actions bot requested a deployment to storybook-preview-5142 March 25, 2025 22:07 Abandoned
@francinelucca francinelucca added this pull request to the merge queue Mar 25, 2025
Merged via the queue into main with commit 769a048 Mar 25, 2025
44 checks passed
@francinelucca francinelucca deleted the select-panel-empty-state branch March 25, 2025 23:26
@primer primer bot mentioned this pull request Mar 25, 2025
TylerJDev added a commit that referenced this pull request Mar 26, 2025
francinelucca added a commit that referenced this pull request Mar 26, 2025
Copy link
Member

Choose a reason for hiding this comment

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

test

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

integration-tests: passing Changes in this PR do NOT cause breaking changes in gh/gh integration-tests: recommended This change needs to be tested for breaking changes. See https://arc.net/l/quote/tdmpakpm staff Author is a staff member status: review needed

Projects

None yet

Development

Successfully merging this pull request may close these issues.

10 participants