Skip to content

Add type definitions for StyleOptions#3818

Merged
corinagum merged 21 commits intomicrosoft:masterfrom
corinagum:types-b
Mar 30, 2021
Merged

Add type definitions for StyleOptions#3818
corinagum merged 21 commits intomicrosoft:masterfrom
corinagum:types-b

Conversation

@corinagum
Copy link
Copy Markdown
Contributor

@corinagum corinagum commented Mar 29, 2021

Fixes #2100

Changelog Entry

  • Resolves #2100. Add types declarations for Style Options in api bundle, by @corinagum, in PR #3818

Description

By popular request! This set of changes provides type declarations for Web Chat's style options.

Design

Types file is exported to /types under api package.

Specific Changes

  • Clean up of StyleOption props
    • Several props were spread across two defaultStyleOptions.js :o
    • Update several props from null / empty string default value to undefined
    • Alphabetize props by category
  • Delete defaultStyleOptions.js in /component/Styles/ package
  • Add typescript linting to eslint
  • I have added tests and executed them locally
  • I have updated CHANGELOG.md
  • I have updated documentation

Review Checklist

This section is for contributors to review your work.

  • Accessibility reviewed (tab order, content readability, alt text, color contrast)
  • Browser and platform compatibilities reviewed
  • CSS styles reviewed (minimal rules, no z-index)
  • Documents reviewed (docs, samples, live demo)
  • Internationalization reviewed (strings, unit formatting)
  • package.json and package-lock.json reviewed
  • Security reviewed (no data URIs, check for nonce leak)
  • Tests reviewed (coverage, legitimacy)

Comment thread __tests__/types/typesCheck.js Outdated
Comment thread __tests__/types/typesCheck.js
Comment thread __tests__/types/typesCheck.js Outdated
Comment thread packages/api/src/index.tsx Outdated
Comment thread packages/bundle/src/index.ts Outdated
Comment thread packages/component/src/Styles/createStyleSet.ts Outdated
Comment thread packages/component/src/Styles/createStyleSet.ts Outdated
Comment thread packages/playground/src/App.js
Copy link
Copy Markdown
Contributor

@compulim compulim left a comment

Choose a reason for hiding this comment

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

Minor changes.

Comment thread packages/playground/src/App.js
@corinagum corinagum merged commit a13bfd8 into microsoft:master Mar 30, 2021
@corinagum corinagum mentioned this pull request Mar 31, 2021
@compulim compulim mentioned this pull request Jun 9, 2021
11 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.

Need a way to obtain webchat.d.ts file

2 participants