Skip to content

Convert EuiScreenReaderOnly and EuiBadgeNotification to TS#1341

Merged
chandlerprall merged 4 commits intoelastic:masterfrom
chandlerprall:typescripted-01
Dec 3, 2018
Merged

Convert EuiScreenReaderOnly and EuiBadgeNotification to TS#1341
chandlerprall merged 4 commits intoelastic:masterfrom
chandlerprall:typescripted-01

Conversation

@chandlerprall
Copy link
Contributor

@chandlerprall chandlerprall commented Dec 2, 2018

Summary

  • converted EuiScreenReaderOnly and EuiBadgeNotification, their tests, and examples to TS.
  • added support for interface ... extends to ts->proptypes generation
  • fixed bug in ts->proptypes where a component that doesn't use jsx couldn't import PropTypes
  • fixed bug in exporting CommonProps from components/index.d.ts

Checklist

- [ ] This was checked in mobile
- [ ] This was checked in IE11
- [ ] This was checked in dark mode

  • Any props added have proper autodocs
    - [ ] Documentation examples were added
  • A changelog entry exists and is marked appropriately
    - [ ] This was checked for breaking changes and labeled appropriately
  • Jest tests were updated or added to match the most common scenarios
    - [ ] This was checked against keyboard-only and screenreader scenarios
    - [ ] This required updates to Framer X components

import classNames from 'classnames';

export interface EuiScreenReaderOnlyProps {
children: React.ReactElement<any>;
Copy link
Contributor

Choose a reason for hiding this comment

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

If it were me, I'd import ReactElement 🤷‍♂️

@chandlerprall
Copy link
Contributor Author

@pugnascotia updated!

@chandlerprall chandlerprall merged commit f3a6e56 into elastic:master Dec 3, 2018
@chandlerprall chandlerprall deleted the typescripted-01 branch December 3, 2018 17:23
@snide snide mentioned this pull request Dec 7, 2018
3 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants