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

Fix wordpress__components & wordpress__compose type mismatch after change to React v18 #63716

Merged
merged 6 commits into from Dec 29, 2022

Conversation

danieliser
Copy link
Contributor

Please fill in this template.

Select one of these and delete the others:

If changing an existing definition:

  • Provide a URL to documentation or source code which provides context for the suggested changes: Upgrade React packages to v18 WordPress/gutenberg#45235
  • If this PR brings the type definitions up to date with a new version of the JS library, update the version number in the header.

@typescript-bot
Copy link
Contributor

typescript-bot commented Dec 24, 2022

@danieliser Thank you for submitting this PR!

This is a live comment which I will keep updated.

2 packages in this PR

Code Reviews

Because this PR edits multiple packages, it can be merged once it's reviewed by a DT maintainer.

You can test the changes of this PR in the Playground.

Status

  • ✅ No merge conflicts
  • ✅ Continuous integration tests have passed
  • 🕐 A DT maintainer needs to approve changes which affect more than one package

Once every item on this list is checked, I'll ask you for permission to merge and publish the changes.


Diagnostic Information: What the bot saw about this PR
{
  "type": "info",
  "now": "-",
  "pr_number": 63716,
  "author": "danieliser",
  "headCommitOid": "e22ca61a9561b2cdf1920913b1a7675e888b345f",
  "mergeBaseOid": "04d5ce209125122ab55ad7502c88a5ef05c1b9a8",
  "lastPushDate": "2022-12-24T07:55:09.000Z",
  "lastActivityDate": "2022-12-28T07:06:09.000Z",
  "hasMergeConflict": false,
  "isFirstContribution": false,
  "tooManyFiles": false,
  "hugeChange": false,
  "popularityLevel": "Well-liked by everyone",
  "pkgInfo": [
    {
      "name": "wordpress__components",
      "kind": "edit",
      "files": [
        {
          "path": "types/wordpress__components/index.d.ts",
          "kind": "definition"
        },
        {
          "path": "types/wordpress__components/package.json",
          "kind": "package-meta-ok"
        }
      ],
      "owners": [
        "dsifford",
        "sirreal",
        "p-jackson",
        "sarayourfriend",
        "michaelhthomas",
        "manzoorwanijk",
        "bastolen"
      ],
      "addedOwners": [],
      "deletedOwners": [],
      "popularityLevel": "Well-liked by everyone"
    },
    {
      "name": "wordpress__compose",
      "kind": "edit",
      "files": [
        {
          "path": "types/wordpress__compose/index.d.ts",
          "kind": "definition"
        },
        {
          "path": "types/wordpress__compose/package.json",
          "kind": "package-meta-ok"
        }
      ],
      "owners": [
        "dsifford"
      ],
      "addedOwners": [],
      "deletedOwners": [],
      "popularityLevel": "Well-liked by everyone"
    }
  ],
  "reviews": [
    {
      "type": "approved",
      "reviewer": "sirreal",
      "date": "2022-12-28T07:06:09.000Z",
      "isMaintainer": false
    },
    {
      "type": "approved",
      "reviewer": "noahtallen",
      "date": "2022-12-27T20:05:54.000Z",
      "isMaintainer": false
    }
  ],
  "mainBotCommentID": 1364444605,
  "ciResult": "pass"
}

@typescript-bot typescript-bot added this to Waiting for Code Reviews in New Pull Request Status Board Dec 24, 2022
@typescript-bot
Copy link
Contributor

🔔 @dsifford @sirreal @p-jackson @sarayourfriend @michaelhthomas @manzoorwanijk @bastolen — please review this PR in the next few days. Be sure to explicitly select Approve or Request Changes in the GitHub UI so I know what's going on.

@danieliser
Copy link
Contributor Author

@typescript-bot Test changes were not necessary as the type mismatch came from a dependency version mismatch.

@DangerBotOSS
Copy link

DangerBotOSS commented Dec 24, 2022

Inspecting the JavaScript source for this package found some properties that are not in the .d.ts files.
The check for missing properties isn't always right, so take this list as advice, not a requirement.

wordpress__components (unpkg)

was missing the following properties:

  1. CustomGradientPicker
  2. DuotonePicker
  3. DuotoneSwatch
  4. GradientPicker
  5. GuidePage
as well as these 6 other properties...

Line, SearchControl, TextHighlight, ToolbarDropdownMenu, ToolbarItem, useBaseControlProps

wordpress__compose (unpkg)

was missing the following properties:

  1. pipe
  2. useAsyncList
  3. useConstrainedTabbing
  4. useCopyOnClick
  5. useCopyToClipboard
as well as these 15 other properties...

useDebounce, useDisabled, useFocusOnMount, useFocusReturn, useFocusableIframe, useInstanceId, useIsomorphicLayoutEffect, useKeyboardShortcut, useMergeRefs, usePrevious, useRefEffect, useResizeObserver, useThrottle, useViewportMatch, useWarnOnChange

Generated by 🚫 dangerJS against e22ca61

@typescript-bot typescript-bot moved this from Waiting for Code Reviews to Needs Maintainer Review in New Pull Request Status Board Dec 24, 2022
@danieliser danieliser changed the title Fix wordpress__components type mismatch after change to React v18 Fix wordpress__components & wordpress__compose type mismatch after change to React v18 Dec 24, 2022
@typescript-bot typescript-bot moved this from Needs Maintainer Review to Waiting for Code Reviews in New Pull Request Status Board Dec 24, 2022
@danieliser
Copy link
Contributor Author

Didn't realize this PR included the update for @types/wordpress__compose as well, so bumped the version for it as well. Same issue fixed in both packages still.

@typescript-bot typescript-bot moved this from Waiting for Code Reviews to Needs Maintainer Review in New Pull Request Status Board Dec 24, 2022
Copy link
Contributor

@noahtallen noahtallen left a comment

Choose a reason for hiding this comment

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

Makes sense to me, but I don't know if it will accept my approval!

@typescript-bot typescript-bot added the Other Approved This PR was reviewed and signed-off by a community member. label Dec 27, 2022
@danieliser
Copy link
Contributor Author

danieliser commented Dec 28, 2022

@noahtallen - thanks, seems to have resolved everything we were seeing with react/JSX component type mismatches and loading of multiple @type/wordpress__ version library conflicts.

@typescript-bot typescript-bot added the Owner Approved A listed owner of this package signed off on the pull request. label Dec 28, 2022
@sandersn sandersn merged commit acfd64b into DefinitelyTyped:master Dec 29, 2022
@typescript-bot typescript-bot removed this from Needs Maintainer Review in New Pull Request Status Board Dec 29, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Edits multiple packages Other Approved This PR was reviewed and signed-off by a community member. Owner Approved A listed owner of this package signed off on the pull request. Untested Change This PR does not touch tests
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

6 participants