-
Notifications
You must be signed in to change notification settings - Fork 78
[Call Readiness] Unsupported Browser UI #2334
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
Merged
Merged
Changes from 9 commits
Commits
Show all changes
26 commits
Select commit
Hold shift + click to select a range
8d65741
create new view for the composite
dmceachernmsft 62b14b7
Add base component and strings
dmceachernmsft 128a0ea
remove button
dmceachernmsft 637b487
create new story files
dmceachernmsft 20a53b9
add story book content and build
dmceachernmsft 776332c
fix icons
dmceachernmsft 0c639f5
Merge branch 'main' into dmceachernmsft/unsupportedBrowserUI
dmceachernmsft 62275b3
move styles to own file
dmceachernmsft 5fee8e3
Merge branch 'dmceachernmsft/unsupportedBrowserUI' of https://github.…
dmceachernmsft f4031f9
Merge branch 'main' into dmceachernmsft/unsupportedBrowserUI
dmceachernmsft 4eb1fa0
add CC for unsupported browser
dmceachernmsft 9d65d96
more CC work
dmceachernmsft 0d3d0e1
Change files
dmceachernmsft f562e9a
fix linter errors
dmceachernmsft b508922
Merge branch 'main' into dmceachernmsft/unsupportedBrowserUI
dmceachernmsft e344c64
Merge branch 'main' into dmceachernmsft/unsupportedBrowserUI
dmceachernmsft 81ecd76
make component beta
dmceachernmsft 7084c58
remove console
dmceachernmsft 26f9460
fix cc error
dmceachernmsft 061a4a2
make supporting types interfaces
dmceachernmsft 3a161f3
build API
dmceachernmsft 26d9c62
Merge branch 'main' into dmceachernmsft/unsupportedBrowserUI
dmceachernmsft 9478170
fix cc
dmceachernmsft 4aea0e0
Merge branch 'main' of https://github.com/Azure/communication-ui-libr…
dmceachernmsft 8a0b829
rebuild api
dmceachernmsft de34437
fix nits
dmceachernmsft File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
65 changes: 65 additions & 0 deletions
65
packages/react-components/src/components/UnsupportedBrowser.tsx
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,65 @@ | ||
| // Copyright (c) Microsoft Corporation. | ||
| // Licensed under the MIT license. | ||
|
|
||
| import { Icon, Link, Stack, Text } from '@fluentui/react'; | ||
| import { _pxToRem } from '@internal/acs-ui-common'; | ||
| import React from 'react'; | ||
| /* @conditional-compile-remove(call-readiness) */ | ||
| import { useLocale } from '../localization'; | ||
| import { | ||
| containerStyles, | ||
| linkTextStyles, | ||
| mainTextStyles, | ||
| secondaryTextStyles | ||
| } from './styles/UnsupportedBrowser.styles'; | ||
|
|
||
| /** | ||
| * @beta | ||
| */ | ||
| export type UnsupportedBrowserStrings = { | ||
| primaryText: string; | ||
| secondaryText: string; | ||
| moreHelpLink: string; | ||
| }; | ||
|
|
||
| /** | ||
| * @internal | ||
| */ | ||
| export type _UnsupportedBrowserProps = { | ||
| onTroubleShootingClick: () => void; | ||
| strings: UnsupportedBrowserStrings; | ||
| }; | ||
|
|
||
| /** | ||
| * @internal | ||
| */ | ||
| export const _UnsupportedBrowserContainer = (props: _UnsupportedBrowserProps): JSX.Element => { | ||
| const { onTroubleShootingClick, strings } = props; | ||
| console.log('test2'); | ||
| return ( | ||
| <Stack styles={containerStyles}> | ||
| <Icon iconName="UnsupportedBrowserWarning"></Icon> | ||
|
dmceachernmsft marked this conversation as resolved.
Outdated
|
||
| <Text styles={mainTextStyles}>{strings.primaryText}</Text> | ||
| <Text styles={secondaryTextStyles}>{strings.secondaryText}</Text> | ||
| <Link | ||
| styles={linkTextStyles} | ||
| onClick={() => { | ||
| onTroubleShootingClick(); | ||
| }} | ||
| > | ||
| {strings.moreHelpLink} | ||
| </Link> | ||
| </Stack> | ||
| ); | ||
| }; | ||
|
|
||
| /** | ||
| * | ||
| * @internal | ||
| */ | ||
| export const _UnsupportedBrowser = (props: _UnsupportedBrowserProps): JSX.Element => { | ||
| console.log('test1'); | ||
| /* @conditional-compile-remove(call-readiness) */ | ||
| const strings = useLocale().strings.UnsupportedBrowser; | ||
| return <_UnsupportedBrowserContainer {...props} strings={strings} />; | ||
| }; | ||
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
50 changes: 50 additions & 0 deletions
50
packages/react-components/src/components/styles/UnsupportedBrowser.styles.tsx
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,50 @@ | ||
| // Copyright (c) Microsoft Corporation. | ||
| // Licensed under the MIT license. | ||
|
|
||
| import { ILinkStyles, IStackStyles, ITextStyles } from '@fluentui/react'; | ||
| import { _pxToRem } from '@internal/acs-ui-common'; | ||
|
|
||
| /** | ||
| * @internal | ||
| */ | ||
| export const mainTextStyles: ITextStyles = { | ||
| root: { | ||
| fontWeight: 600, | ||
| fontSize: _pxToRem(20), | ||
| lineHeight: _pxToRem(28), | ||
| paddingBottom: '1rem', | ||
| margin: 'auto' | ||
| } | ||
| }; | ||
|
|
||
| /** | ||
| * @internal | ||
| */ | ||
| export const secondaryTextStyles: ITextStyles = { | ||
| root: { | ||
| margin: 'auto', | ||
| fontWeight: 400, | ||
| paddingBottom: '0.5rem' | ||
| } | ||
| }; | ||
|
|
||
| /** | ||
| * @internal | ||
| */ | ||
| export const linkTextStyles: ILinkStyles = { | ||
| root: { | ||
| margin: 'auto', | ||
| fontWeight: 600, | ||
| textAlign: 'inherit' | ||
| } | ||
| }; | ||
|
|
||
| /** | ||
| * @internal | ||
| */ | ||
| export const containerStyles: IStackStyles = { | ||
| root: { | ||
| padding: '2rem', | ||
| maxWidth: '25.374rem' | ||
| } | ||
| }; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
20 changes: 20 additions & 0 deletions
20
packages/react-composites/src/composites/CallComposite/pages/UnsupportedBrowser.tsx
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,20 @@ | ||
| // Copyright (c) Microsoft Corporation. | ||
| // Licensed under the MIT license. | ||
|
|
||
| import React from 'react'; | ||
|
|
||
| /** | ||
| * @internal | ||
| */ | ||
| export type UnsupportedBrowserProps = { | ||
| onTroubleshootingClick: () => void; | ||
| // strings type from new component... | ||
| }; | ||
|
|
||
| /** | ||
| * | ||
| * @internal | ||
| */ | ||
| export const UnsupportedBrowser = (props: UnsupportedBrowserProps): JSX.Element => { | ||
| return <></>; | ||
| }; |
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.