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

Bump preact from 10.21.0 to 10.22.0 #1560

Merged
merged 3 commits into from
May 20, 2024

Conversation

dependabot[bot]
Copy link
Contributor

@dependabot dependabot bot commented on behalf of github May 20, 2024

Bumps preact from 10.21.0 to 10.22.0.

Release notes

Sourced from preact's releases.

10.22.0

Features

Types

Maintenance

Fixes

Commits
  • 494f084 10.22.0 (#4385)
  • cece8c3 fix isolated rerenders (#4382)
  • 6449692 Merge pull request #4378 from preactjs/types/popover
  • 598765e feat: Add popover types
  • 1b4e683 Merge pull request #4377 from preactjs/ci/compressed-size
  • d12d306 Merge branch 'main' into ci/compressed-size
  • bfdd189 Merge pull request #4376 from preactjs/debug/button-anchor-nesting
  • 06a2df1 Merge branch 'main' into debug/button-anchor-nesting
  • c29caa3 Merge pull request #4375 from preactjs/debug/tr-warning
  • 4523933 ci: Skip running compressed-size builds twice
  • Additional commits viewable in compare view

Dependabot compatibility score

Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting @dependabot rebase.


Dependabot commands and options

You can trigger Dependabot actions by commenting on this PR:

  • @dependabot rebase will rebase this PR
  • @dependabot recreate will recreate this PR, overwriting any edits that have been made to it
  • @dependabot merge will merge this PR after your CI passes on it
  • @dependabot squash and merge will squash and merge this PR after your CI passes on it
  • @dependabot cancel merge will cancel a previously requested merge and block automerging
  • @dependabot reopen will reopen this PR if it is closed
  • @dependabot close will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually
  • @dependabot show <dependency name> ignore conditions will show all of the ignore conditions of the specified dependency
  • @dependabot ignore this major version will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)
  • @dependabot ignore this minor version will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)
  • @dependabot ignore this dependency will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)

@dependabot dependabot bot added the dependencies Pull requests that update a dependency file label May 20, 2024
@robertknight robertknight requested a review from acelaya May 20, 2024 11:53
@robertknight
Copy link
Member

I added a couple of changes to fix issues that came up with this update. You might want to be aware of them @acelaya .

Copy link
Contributor

@acelaya acelaya left a comment

Choose a reason for hiding this comment

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

Thanks!

@@ -287,7 +287,7 @@ function SelectMain<T>({
const buttonRef = useSyncedRef(elementRef);
const defaultButtonId = useId();
const extraProps = useMemo(
() => (listboxAsPopover ? { popover: '' } : {}),
() => (listboxAsPopover ? { popover: 'auto' } : {}),
Copy link
Contributor

@acelaya acelaya May 20, 2024

Choose a reason for hiding this comment

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

The typecheck still fails, as it infers 'auto' as string. One option is setting 'auto' as const, but since now popover is part of the type, you can also move this logic to a regular prop where the value is dynamically set to auto or false, and I would expect that, in the second case, the attribute is not set at all in the DOM node.

Copy link
Member

Choose a reason for hiding this comment

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

🤦 - Indeed. I ran the tests locally but forgot to run typechecking. I moved popover to be an unconditionally set prop, but had to use the value undefined rather than false for the case where listboxAsPopover is disabled, since Preact is not handling boolean values correctly for this prop.

Copy link
Member

Choose a reason for hiding this comment

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

I filed an upstream issue about handling boolean values for this prop: preactjs/preact#4391.

Bumps [preact](https://github.com/preactjs/preact) from 10.21.0 to 10.22.0.
- [Release notes](https://github.com/preactjs/preact/releases)
- [Commits](preactjs/preact@10.21.0...10.22.0)

---
updated-dependencies:
- dependency-name: preact
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
@robertknight robertknight force-pushed the dependabot/npm_and_yarn/preact-10.22.0 branch from d29a10c to 1ae0459 Compare May 20, 2024 13:50
Preact's latest typings allow setting popover to a boolean value, but this still
renders `popover="true"` and "true" is an invalid value. Instead set the value
to "auto" which is the default value [1].

[1] https://developer.mozilla.org/en-US/docs/Web/HTML/Global_attributes/popover
The latest Preact release warns about `<tr>` elements that have a `<table>` as
their direct parent. See preactjs/preact#4375.
@robertknight robertknight force-pushed the dependabot/npm_and_yarn/preact-10.22.0 branch from 1ae0459 to c81e90e Compare May 20, 2024 14:05
Copy link

codecov bot commented May 20, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 100.00%. Comparing base (9f2f6ed) to head (c81e90e).
Report is 1 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff            @@
##              main     #1560   +/-   ##
=========================================
  Coverage   100.00%   100.00%           
=========================================
  Files           62        62           
  Lines         1037      1036    -1     
  Branches       394       394           
=========================================
- Hits          1037      1036    -1     

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

@robertknight robertknight merged commit 18ebdfb into main May 20, 2024
4 checks passed
@robertknight robertknight deleted the dependabot/npm_and_yarn/preact-10.22.0 branch May 20, 2024 14:10
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
dependencies Pull requests that update a dependency file
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants