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

[NOJIRA][BpkLoadingButton|BpkCloseButton]: fix loading console errors #3430

Merged
merged 2 commits into from
May 10, 2024

Conversation

mungodewar
Copy link
Contributor

Several console.error messages caused by incorrect rest statements and prop types fixed

Remember to include the following changes:

  • Ensure the PR title includes the name of the component you are changing so it's clear in the release notes for consumers of the changes in the version e.g [KOA-123][BpkButton] Updating the colour
  • README.md (If you have created a new component)
  • Component README.md
  • Tests
  • Storybook examples created/updated
  • For breaking changes or deprecating components/properties, migration guides added to the description of the PR. If the guide has large changes, consider creating a new Markdown page inside the component's docs folder and link it here

@mungodewar mungodewar added the patch Patch production bug label May 10, 2024
Copy link

Warnings
⚠️

Package source files (e.g. packages/package-name/src/Component.js) were updated, but snapshots weren't. Have you checked that the tests still pass?

⚠️

Package source files (e.g. packages/package-name/src/Component.tsx) were updated, but type files weren't. Have you checked that no types have changed?

Browser support

If this is a visual change, make sure you've tested it in multiple browsers.

Generated by 🚫 dangerJS against 2a63597

Copy link

Visit https://backpack.github.io/storybook-prs/3430 to see this build running in a browser.

});

it('should render correctly with a "href" attribute', () => {
const { asFragment } = render(
<BpkLoadingButton href="#">My button</BpkLoadingButton>,
);
expect(asFragment()).toMatchSnapshot();
expect(error).not.toHaveBeenCalled();
});

it('should render correctly with a "primaryOnDark" attribute', () => {
const { asFragment } = render(
<BpkLoadingButton primaryOnDark>My button</BpkLoadingButton>,
Copy link
Member

Choose a reason for hiding this comment

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

Any reason our tests are still doing the old way and not actually using it as it should be?

With one test just working with an attribute?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

The api of BpkLoadingButton hasn't changed, just the underlying implementation.

@mungodewar mungodewar merged commit 5803c9a into main May 10, 2024
9 of 10 checks passed
@mungodewar mungodewar deleted the nojira-md-fix-loading-btn-console-err branch May 10, 2024 09:45
mungodewar added a commit that referenced this pull request May 10, 2024
…#3430)

* fix loading button console error

* fix close button prop type
FireRedNinja pushed a commit that referenced this pull request May 22, 2024
…#3430)

* fix loading button console error

* fix close button prop type
KathyWang0208 pushed a commit that referenced this pull request May 27, 2024
…#3430)

* fix loading button console error

* fix close button prop type
KathyWang0208 pushed a commit that referenced this pull request May 27, 2024
…#3430)

* fix loading button console error

* fix close button prop type
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
patch Patch production bug
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants