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

[NO-TICKET] Upgrade React types to fix Storybook 8 branch #3080

Commits on May 9, 2024

  1. WIP: Try upgrading the react types and working through errors

    Here's the summary of errors we're starting with:
    
    ```
    Found 109 errors in 28 files.
    
    Errors  Files
         4  packages/design-system/src/components/Accordion/Accordion.stories.tsx:8
         3  packages/design-system/src/components/Alert/Alert.stories.tsx:6
         1  packages/design-system/src/components/Autocomplete/utils.tsx:15
        11  packages/design-system/src/components/ChoiceList/ChoiceList.stories.tsx:7
         4  packages/design-system/src/components/Drawer/Drawer.stories.tsx:29
        12  packages/design-system/src/components/Dropdown/Dropdown.stories.tsx:8
         6  packages/design-system/src/components/Dropdown/Dropdown.tsx:171
         1  packages/design-system/src/components/Dropdown/DropdownMenuOption.tsx:66
         5  packages/design-system/src/components/HelpDrawer/HelpDrawer.stories.tsx:29
         4  packages/design-system/src/components/IdleTimeout/IdleTimeout.stories.tsx:10
         4  packages/design-system/src/components/PrivacySettingsDialog/PrivacySettingsDialog.stories.tsx:17
         6  packages/design-system/src/components/Spinner/Spinner.stories.tsx:6
        23  packages/design-system/src/components/TextField/TextField.stories.tsx:10
         2  packages/design-system/src/components/Tooltip/Tooltip.tsx:357
         1  packages/design-system/src/components/UsaBanner/UsaBanner.stories.tsx:5
         1  packages/design-system/src/components/web-components/ds-accordion/ds-accordion.tsx:22
         1  packages/design-system/src/components/web-components/preactement/define.test.tsx:35
         1  packages/docs/src/components/content/ContentRenderer.tsx:111
         1  packages/docs/src/components/content/EmbeddedExample.tsx:17
         2  packages/docs/src/components/layout/SideNav/SideNav.tsx:25
         2  packages/docs/src/components/layout/TableOfContents.tsx:43
         1  packages/docs/src/components/page-templates/BlogPage.tsx:18
         1  packages/docs/src/pages/blog.tsx:33
         2  packages/ds-healthcare-gov/src/components/Accordion/Accordion.stories.tsx:8
         2  packages/ds-medicare-gov/src/components/Card/Card.stories.tsx:6
         5  packages/ds-medicare-gov/src/components/HelpDrawer/HelpDrawer.stories.tsx:31
         1  packages/ds-medicare-gov/src/components/SimpleFooter/SimpleFooter.stories.tsx:6
         2  packages/ds-medicare-gov/src/components/Stars/stars.stories.tsx:6
    ```
    pwolfert committed May 9, 2024
    Configuration menu
    Copy the full SHA
    4335def View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    ffc035d View commit details
    Browse the repository at this point in the history
  3. Remove custom docs config for Drawer storybook page and fix VRTs

    Add new interaction VRTs for dialog and drawer, and don't have any of the stories open them automatically
    pwolfert committed May 9, 2024
    Configuration menu
    Copy the full SHA
    c930062 View commit details
    Browse the repository at this point in the history
  4. Trying to fix missing Drawer story controls but failing

    I was hoping fixing these types would do it.
    pwolfert committed May 9, 2024
    Configuration menu
    Copy the full SHA
    0809b23 View commit details
    Browse the repository at this point in the history
  5. Configuration menu
    Copy the full SHA
    f4fac88 View commit details
    Browse the repository at this point in the history
  6. Configuration menu
    Copy the full SHA
    6cb099b View commit details
    Browse the repository at this point in the history

Commits on May 10, 2024

  1. Down to 24 errors

    pwolfert committed May 10, 2024
    Configuration menu
    Copy the full SHA
    8b91729 View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    cc34a68 View commit details
    Browse the repository at this point in the history
  3. Huh, the errors just go away after making some edits to the yarn lock…

    …file
    
    I think I'll go back and undo some of my previous commits to see if I need them
    pwolfert committed May 10, 2024
    Configuration menu
    Copy the full SHA
    e7e45cd View commit details
    Browse the repository at this point in the history
  4. Configuration menu
    Copy the full SHA
    3b3a832 View commit details
    Browse the repository at this point in the history
  5. Revert "Ignore errors coming from react-aria types"

    This reverts commit f4fac88.
    pwolfert committed May 10, 2024
    Configuration menu
    Copy the full SHA
    88d5e54 View commit details
    Browse the repository at this point in the history
  6. Revert more of the react-aria changes

    This reverts part of commit ffc035d.
    pwolfert committed May 10, 2024
    Configuration menu
    Copy the full SHA
    0d65126 View commit details
    Browse the repository at this point in the history
  7. I can revert this change too

    pwolfert committed May 10, 2024
    Configuration menu
    Copy the full SHA
    19b9ff8 View commit details
    Browse the repository at this point in the history
  8. Oh no, these new arg tables do not look good

    It seems as though the type inference has gotten worse in this version. Instead of the type for Badge `size` being listed as `big` (only supports big), it is now reported as `literal`. For `string | React.ReactNode`, it only says `union`. Instead of `type` being `checkbox` and `radio`, it’s `union`. Instead of `ReactNode` for `React.ReactNode`, it prints out as `ReactReactNode`
    pwolfert committed May 10, 2024
    Configuration menu
    Copy the full SHA
    6811f4b View commit details
    Browse the repository at this point in the history

Commits on May 17, 2024

  1. Revert "Oh no, these new arg tables do not look good"

    This reverts commit 6811f4b.
    pwolfert committed May 17, 2024
    Configuration menu
    Copy the full SHA
    a36984b View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    6284f0c View commit details
    Browse the repository at this point in the history