@azure/communication-react 1.18.0 → 1.18.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/dist-cjs/communication-react/index.js +13 -29
- package/dist/dist-cjs/communication-react/index.js.map +1 -1
- package/dist/dist-esm/acs-ui-common/src/telemetryVersion.js +1 -1
- package/dist/dist-esm/acs-ui-common/src/telemetryVersion.js.map +1 -1
- package/dist/dist-esm/react-components/src/components/Dialpad/Dialpad.js +2 -2
- package/dist/dist-esm/react-components/src/components/Dialpad/Dialpad.js.map +1 -1
- package/dist/dist-esm/react-components/src/components/MeetingConferencePhoneInfo.d.ts +0 -5
- package/dist/dist-esm/react-components/src/components/MeetingConferencePhoneInfo.js +3 -23
- package/dist/dist-esm/react-components/src/components/MeetingConferencePhoneInfo.js.map +1 -1
- package/dist/dist-esm/react-components/src/components/index.d.ts +1 -0
- package/dist/dist-esm/react-components/src/components/index.js +2 -0
- package/dist/dist-esm/react-components/src/components/index.js.map +1 -1
- package/dist/dist-esm/react-components/src/components/utils/formatPhoneNumber.d.ts +2 -2
- package/dist/dist-esm/react-components/src/components/utils/formatPhoneNumber.js +6 -2
- package/dist/dist-esm/react-components/src/components/utils/formatPhoneNumber.js.map +1 -1
- package/dist/dist-esm/react-composites/src/composites/CallComposite/components/NetworkReconnectTile.js +3 -3
- package/dist/dist-esm/react-composites/src/composites/CallComposite/components/NetworkReconnectTile.js.map +1 -1
- package/dist/dist-esm/react-composites/src/composites/common/MeetingPhoneInfoPaneContent.js +2 -2
- package/dist/dist-esm/react-composites/src/composites/common/MeetingPhoneInfoPaneContent.js.map +1 -1
- package/package.json +1 -2
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"telemetryVersion.js","sourceRoot":"","sources":["../../../../preprocess-dist/acs-ui-common/src/telemetryVersion.js"],"names":[],"mappings":";AAAA,uCAAuC;AACvC,kCAAkC;AAElC,wCAAwC;AAExC,MAAM,CAAC,OAAO,GAAG,QAAQ,CAAC","sourcesContent":["// Copyright (c) Microsoft Corporation.\n// Licensed under the MIT License.\n\n// GENERATED FILE. DO NOT EDIT MANUALLY.\n\nmodule.exports = '1.18.
|
1
|
+
{"version":3,"file":"telemetryVersion.js","sourceRoot":"","sources":["../../../../preprocess-dist/acs-ui-common/src/telemetryVersion.js"],"names":[],"mappings":";AAAA,uCAAuC;AACvC,kCAAkC;AAElC,wCAAwC;AAExC,MAAM,CAAC,OAAO,GAAG,QAAQ,CAAC","sourcesContent":["// Copyright (c) Microsoft Corporation.\n// Licensed under the MIT License.\n\n// GENERATED FILE. DO NOT EDIT MANUALLY.\n\nmodule.exports = '1.18.1';\n"]}
|
@@ -15,7 +15,7 @@ import { concatStyleSets, DefaultButton, FocusZone, mergeStyles, Stack, Text, Te
|
|
15
15
|
import { useState } from 'react';
|
16
16
|
import { useLocale } from '../../localization';
|
17
17
|
import { buttonStyles, containerStyles, iconButtonStyles, digitStyles, letterStyles, textFieldStyles } from '../styles/Dialpad.styles';
|
18
|
-
import {
|
18
|
+
import { _formatPhoneNumber } from '../utils/formatPhoneNumber';
|
19
19
|
import useLongPress from '../utils/useLongPress';
|
20
20
|
import { dtmfFrequencies, Tone } from './DTMFToneGenerator';
|
21
21
|
const dialPadButtonsDefault = [[{
|
@@ -163,7 +163,7 @@ const DialpadContainer = (props) => {
|
|
163
163
|
setText(modifiedInput);
|
164
164
|
};
|
165
165
|
return React.createElement(Stack, { className: mergeStyles(containerStyles(theme), (_a = props.styles) === null || _a === void 0 ? void 0 : _a.root), "data-test-id": "dialpadContainer", "data-ui-id": "dialpadContainer", horizontalAlign: 'center' },
|
166
|
-
dialpadMode === 'dialer' && React.createElement(TextField, { styles: concatStyleSets(textFieldStyles(theme, plainTextValue !== ''), (_b = props.styles) === null || _b === void 0 ? void 0 : _b.textField), value: textFieldValue ? textFieldValue :
|
166
|
+
dialpadMode === 'dialer' && React.createElement(TextField, { styles: concatStyleSets(textFieldStyles(theme, plainTextValue !== ''), (_b = props.styles) === null || _b === void 0 ? void 0 : _b.textField), value: textFieldValue ? textFieldValue : _formatPhoneNumber(plainTextValue),
|
167
167
|
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
168
168
|
onChange: (e) => {
|
169
169
|
setText(e.target.value);
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"Dialpad.js","sourceRoot":"","sources":["../../../../../../preprocess-dist/react-components/src/components/Dialpad/Dialpad.tsx"],"names":[],"mappings":"AAAA,uCAAuC;AACvC,kCAAkC;;;;;;;;;;AAElC,OAAO,KAAK,EAAE,EAAE,SAAS,EAAE,MAAM,EAAE,MAAM,OAAO,CAAC;AAEjD,OAAO,EAAE,UAAU,EAAE,MAAM,iBAAiB,CAAC;AAC7C,OAAO,EAAE,eAAe,EAAE,aAAa,EAAE,SAAS,EAAE,WAAW,EAAE,KAAK,EAAE,IAAI,EAAE,SAAS,EAAE,QAAQ,EAAE,MAAM,iBAAiB,CAAC;AAE3H,OAAO,EAAE,QAAQ,EAAE,MAAM,OAAO,CAAC;AACjC,OAAO,EAAE,SAAS,EAAE,MAAM,oBAAoB,CAAC;AAC/C,OAAO,EAAE,YAAY,EAAE,eAAe,EAAE,gBAAgB,EAAE,WAAW,EAAE,YAAY,EAAE,eAAe,EAAE,MAAM,0BAA0B,CAAC;AACvI,OAAO,EAAE,iBAAiB,EAAE,MAAM,4BAA4B,CAAC;AAC/D,OAAO,YAAY,MAAM,uBAAuB,CAAC;AACjD,OAAO,EAAE,eAAe,EAAuB,IAAI,EAAE,MAAM,qBAAqB,CAAC;AAuGjF,MAAM,qBAAqB,GAA6B,CAAC,CAAC;YACxD,KAAK,EAAE,GAAG;SACX,EAAE;YACD,KAAK,EAAE,GAAG;YACV,MAAM,EAAE,KAAK;SACd,EAAE;YACD,KAAK,EAAE,GAAG;YACV,MAAM,EAAE,KAAK;SACd,CAAC,EAAE,CAAC;YACH,KAAK,EAAE,GAAG;YACV,MAAM,EAAE,KAAK;SACd,EAAE;YACD,KAAK,EAAE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AAC,GAAG,CAAC,CAAC,MAAM,EAAE,WAAW,EAAE,EAAE,CAAC,oBAAC,aAAa,IAAC,GAAG,EAAE,UAAU,WAAW,EAAE;gBAClF;;;;;;;;;;;;;;;;kBAgBE,CAAC,KAAK,EAAE,WAAW,GAAG,QAAQ,GAAG,IAAI,CAAC,MAAM,EAAE,KAAK,EAAE,MAAM,CAAC,KAAK,EAAE,MAAM,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,EAAE,KAAK,CAAC,MAAM,EAAE,OAAO,EAAE,cAAc,EAAE,WAAW,EAAE,kBAAkB,EAAE,gBAAgB,EAAE,gBAAgB,EAAE,oBAAoB,EAAE,oBAAoB,CAAC,OAAO,EAAE,mBAAmB,EAAE,mBAAmB,GAAI,CAAC,CACvS,CAAC;QACf,CAAC,CAAC,CACU,CACN,CAAC;AACb,CAAC,CAAC;AAEF;;;;;GAKG;AACH,MAAM,CAAC,MAAM,OAAO,GAAG,CAAC,KAAmB,EAAe,EAAE;IAC1D,MAAM,aAAa,GAAG,SAAS,EAAE,CAAC,OAAO,CAAC,OAAO,CAAC;IAClD,MAAM,OAAO,mCACR,aAAa,GACb,KAAK,CAAC,OAAO,CACjB,CAAC;IACF,OAAO,oBAAC,gBAAgB,kBAAC,OAAO,EAAE,OAAO,IAAM,KAAK,EAAI,CAAC;AAC3D,CAAC,CAAC;AACF,MAAM,aAAa,GAAG,CAAC,KAAa,EAAU,EAAE;IAC9C,sFAAsF;IACtF,OAAO,KAAK,CAAC,OAAO,CAAC,WAAW,EAAE,EAAE,CAAC,CAAC;AACxC,CAAC,CAAC","sourcesContent":["// Copyright (c) Microsoft Corporation.\n// Licensed under the MIT License.\n\nimport React, { useEffect, useRef } from 'react';\nimport { IStyle, IButtonStyles, ITextFieldStyles } from '@fluentui/react';\nimport { IconButton } from '@fluentui/react';\nimport { concatStyleSets, DefaultButton, FocusZone, mergeStyles, Stack, Text, TextField, useTheme } from '@fluentui/react';\nimport { _formatString } from '@internal/acs-ui-common';\nimport { useState } from 'react';\nimport { useLocale } from '../../localization';\nimport { buttonStyles, containerStyles, iconButtonStyles, digitStyles, letterStyles, textFieldStyles } from '../styles/Dialpad.styles';\nimport { formatPhoneNumber } from '../utils/formatPhoneNumber';\nimport useLongPress from '../utils/useLongPress';\nimport { dtmfFrequencies, DtmfFrequenciesKeys, Tone } from './DTMFToneGenerator';\n\n/**\n * Strings of {@link Dialpad} that can be overridden.\n *\n * @public\n */\nexport interface DialpadStrings {\n placeholderText: string;\n deleteButtonAriaLabel?: string;\n}\n\n/**\n * Styles for {@link Dialpad} component.\n *\n * @public\n */\nexport interface DialpadStyles {\n root?: IStyle;\n button?: IButtonStyles;\n textField?: Partial<ITextFieldStyles>;\n digit?: IStyle;\n letter?: IStyle;\n deleteIcon?: IButtonStyles;\n}\n\n/**\n * DTMF tone for PSTN calls.\n *\n * @public\n */\nexport type DtmfTone = 'A' | 'B' | 'C' | 'D' | 'Flash' | 'Num0' | 'Num1' | 'Num2' | 'Num3' | 'Num4' | 'Num5' | 'Num6' | 'Num7' | 'Num8' | 'Num9' | 'Pound' | 'Star';\n\n/**\n * Modes of the dialpad component.\n * @public\n */\nexport type DialpadMode = 'dtmf' | 'dialer';\n\n/**\n * Modes of how the longpress handlers can be tiggered.\n * @public\n */\nexport type LongPressTrigger = 'mouseAndTouch' | 'touch';\n\n/**\n * Props for {@link Dialpad} component.\n *\n * @public\n */\nexport interface DialpadProps {\n strings?: DialpadStrings;\n /**\n * function to send dtmf tones on button click\n */\n onSendDtmfTone?: (dtmfTone: DtmfTone) => Promise<void>;\n /**\n * Callback for dialpad button behavior\n */\n onClickDialpadButton?: (buttonValue: string, buttonIndex: number) => void;\n /**\n * set dialpad textfield content\n */\n textFieldValue?: string;\n /**\n * on change function for text field, provides an unformatted plain text\n */\n onChange?: (input: string) => void;\n /**\n * flag to determine when to show/hide delete button, default true\n */\n showDeleteButton?: boolean;\n /**\n * Determines what kind of device that the user is on and should respect that based on interaction\n * interfaces available to the user\n */\n longPressTrigger?: LongPressTrigger;\n /**\n * Styles for customizing the dialpad component\n */\n styles?: DialpadStyles;\n /**\n * Disables DTMF sounds when dialpad buttons are pressed. the actual\n * tones are still sent to the call.\n */\n disableDtmfPlayback?: boolean;\n /**\n * Dialer mode for the dialpad. The dtmf mode is for sending dtmf tones and the appearence of\n * the dialpad is changed like hiding the input box. When using dialer mode the input box is there\n * and can be edited to change the number being dialed.\n */\n dialpadMode?: DialpadMode;\n /**\n * Audio context for generating DTMF tones. If this if not provided the dialpad will create one iteslf.\n */\n dtmfAudioContext?: AudioContext;\n}\ntype DialpadButtonContent = {\n /** Number displayed on each dialpad button */\n digit: DtmfFrequenciesKeys;\n /** Letters displayed on each dialpad button */\n letter?: string;\n};\nconst dialPadButtonsDefault: DialpadButtonContent[][] = [[{\n digit: '1'\n}, {\n digit: '2',\n letter: 'ABC'\n}, {\n digit: '3',\n letter: 'DEF'\n}], [{\n digit: '4',\n letter: 'GHI'\n}, {\n digit: '5',\n letter: 'JKL'\n}, {\n digit: '6',\n letter: 'MNO'\n}], [{\n digit: '7',\n letter: 'PQRS'\n}, {\n digit: '8',\n letter: 'TUV'\n}, {\n digit: '9',\n letter: 'WXYZ'\n}], [{\n digit: '*'\n}, {\n digit: '0',\n letter: '+'\n}, {\n digit: '#'\n}]];\nconst DtmfTones: DtmfTone[] = ['Num1', 'Num2', 'Num3', 'Num4', 'Num5', 'Num6', 'Num7', 'Num8', 'Num9', 'Star', 'Num0', 'Pound'];\nconst DialpadButton = (props: {\n digit: DtmfFrequenciesKeys;\n letter?: string;\n styles?: DialpadStyles;\n index: number;\n onClick: (input: string, index: number) => void;\n onLongPress: (input: string, index: number) => void;\n longPressTrigger: LongPressTrigger;\n dtmfToneAudioContext: AudioContext;\n disableDtmfPlayback?: boolean;\n}): JSX.Element => {\n const theme = useTheme();\n const {\n digit,\n index,\n onClick,\n onLongPress,\n longPressTrigger,\n dtmfToneAudioContext,\n disableDtmfPlayback\n } = props;\n const [buttonPressed, setButtonPressed] = useState(false);\n const dtmfToneSound = useRef<Tone>(new Tone(dtmfToneAudioContext, dtmfFrequencies[digit].f1, dtmfFrequencies[digit].f2));\n const useLongPressProps = React.useMemo(() => ({\n onClick: async () => {\n onClick(digit, index);\n },\n onLongPress: async () => {\n onLongPress(digit, index);\n },\n touchEventsOnly: longPressTrigger === 'touch'\n }), [digit, index, longPressTrigger, onClick, onLongPress]);\n const longPressHandlers = useLongPress(useLongPressProps);\n return <DefaultButton data-test-id={`dialpad-button-${props.index}`} styles={concatStyleSets(buttonStyles(theme), props.styles?.button)} {...longPressHandlers} onKeyDown={e => {\n if ((e.key === 'Enter' || e.key === ' ') && !buttonPressed) {\n if (!disableDtmfPlayback) {\n dtmfToneSound.current.play();\n }\n longPressHandlers.onKeyDown();\n setButtonPressed(true);\n return;\n }\n if (e.key === 'Tab' || e.key === 'ArrowLeft' || e.key === 'ArrowRight' || e.key === 'ArrowUp' || e.key === 'ArrowDown') {\n dtmfToneSound.current.stop();\n return;\n }\n longPressHandlers.onKeyDown();\n }} onKeyUp={e => {\n if ((e.key === 'Enter' || e.key === ' ') && buttonPressed) {\n dtmfToneSound.current.stop();\n longPressHandlers.onKeyUp();\n setButtonPressed(false);\n }\n longPressHandlers.onKeyUp();\n }} onMouseDown={() => {\n if (!disableDtmfPlayback) {\n dtmfToneSound.current.play();\n }\n longPressHandlers.onMouseDown();\n }} onMouseUp={() => {\n dtmfToneSound.current.stop();\n longPressHandlers.onMouseUp();\n }} onMouseLeave={() => {\n dtmfToneSound.current.stop();\n }} onTouchStart={() => {\n if (!disableDtmfPlayback) {\n dtmfToneSound.current.play();\n }\n longPressHandlers.onTouchStart();\n }} onTouchEnd={() => {\n dtmfToneSound.current.stop();\n longPressHandlers.onTouchEnd();\n }}>\n <Stack>\n <Text className={mergeStyles(digitStyles(theme), props.styles?.digit)}>{props.digit}</Text>\n\n <Text className={mergeStyles(letterStyles(theme), props.styles?.letter)}>{props.letter ?? ' '}</Text>\n </Stack>\n </DefaultButton>;\n};\nconst DialpadContainer = (props: {\n strings: DialpadStrings;\n onSendDtmfTone?: (dtmfTone: DtmfTone) => Promise<void>;\n /** Callback for dialpad button behavior */\n onClickDialpadButton?: (buttonValue: string, buttonIndex: number) => void;\n /** Pass in custom content to dialpad textfield */\n textFieldValue?: string;\n /** on change function for text field, provides an unformatted plain text */\n onChange?: (input: string) => void;\n /** boolean input to determine when to show/hide delete button, default true */\n showDeleteButton?: boolean;\n /** boolean input to determine if dialpad is in mobile view, default false */\n longPressTrigger?: LongPressTrigger;\n styles?: DialpadStyles;\n disableDtmfPlayback?: boolean;\n dialpadMode?: DialpadMode;\n dtmfAudioContext?: AudioContext;\n}): JSX.Element => {\n const theme = useTheme();\n const {\n onSendDtmfTone,\n onClickDialpadButton,\n textFieldValue,\n onChange,\n showDeleteButton = true,\n longPressTrigger = 'mouseAndTouch',\n disableDtmfPlayback,\n dialpadMode = 'dialer',\n dtmfAudioContext\n } = props;\n const dtmfToneAudioContext = useRef(dtmfAudioContext ? dtmfAudioContext : new AudioContext());\n const [plainTextValue, setPlainTextValue] = useState(textFieldValue ?? '');\n const plainTextValuePreviousRenderValue = useRef(plainTextValue);\n useEffect(() => {\n if (plainTextValuePreviousRenderValue.current !== plainTextValue) {\n onChange?.(plainTextValue);\n }\n plainTextValuePreviousRenderValue.current = plainTextValue;\n }, [plainTextValuePreviousRenderValue, plainTextValue, onChange]);\n useEffect(() => {\n setText(textFieldValue ?? '');\n }, [textFieldValue]);\n const onClickDialpad = (input: string, index: number): void => {\n setText(plainTextValue + input);\n if (onSendDtmfTone) {\n onSendDtmfTone(DtmfTones[index]);\n }\n if (onClickDialpadButton) {\n onClickDialpadButton(input, index);\n }\n };\n const onLongPressDialpad = (input: string, index: number): void => {\n if (input === '0' && index === 10) {\n setText(plainTextValue + '+');\n } else {\n setText(plainTextValue + input);\n }\n if (onSendDtmfTone) {\n onSendDtmfTone(DtmfTones[index]);\n }\n if (onClickDialpadButton) {\n onClickDialpadButton(input, index);\n }\n };\n\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n const setText = (input: string): void => {\n // remove non-valid characters from input: letters,special characters excluding +, *,#\n const plainInput = sanitizeInput(input);\n setPlainTextValue(plainInput);\n };\n const deleteNumbers = (): void => {\n const modifiedInput = plainTextValue.substring(0, plainTextValue.length - 1);\n setText(modifiedInput);\n };\n return <Stack className={mergeStyles(containerStyles(theme), props.styles?.root)} data-test-id=\"dialpadContainer\" data-ui-id=\"dialpadContainer\" horizontalAlign={'center'}>\n {dialpadMode === 'dialer' && <TextField styles={concatStyleSets(textFieldStyles(theme, plainTextValue !== ''), props.styles?.textField)} value={textFieldValue ? textFieldValue : formatPhoneNumber(plainTextValue)}\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n onChange={(e: any) => {\n setText(e.target.value);\n }} onClick={e => {\n e.preventDefault();\n }} placeholder={props.strings.placeholderText} data-test-id=\"dialpad-input\" onRenderSuffix={(): JSX.Element => <>\n {showDeleteButton && plainTextValue.length !== 0 && <IconButton ariaLabel={props.strings.deleteButtonAriaLabel} onClick={deleteNumbers} styles={concatStyleSets(iconButtonStyles(theme), props.styles?.deleteIcon)} iconProps={{\n iconName: 'DialpadBackspace'\n }} />}\n </>} />}\n <FocusZone>\n {dialPadButtonsDefault.map((rows, rowIndex) => {\n return <Stack horizontal key={`row_${rowIndex}`} horizontalAlign=\"stretch\" tokens={{\n childrenGap: '1rem'\n }}>\n {rows.map((button, columnIndex) => <DialpadButton key={`button_${columnIndex}`}\n /* row index = 0\n columnIndex: (0,1,2) => (0,1,2)\n row index = 1\n columnIndex: (0,1,2)=> (3,4,5)\n row index = 2\n columnIndex: (0,1,2)=> (6,7,8)\n row index = 3\n columnIndex: (0,1,2)=> (9,10,11)\n columnIndex + rowIndex*rows.length calculates the corresponding index for each button\n dialpad index:\n 0 1 2\n 3 4 5\n 6 7 8\n 9 10 11\n then use this index to locate the corresponding dtmf tones\n DtmfTones[index]\n */ index={columnIndex + rowIndex * rows.length} digit={button.digit} letter={button.letter} styles={props.styles} onClick={onClickDialpad} onLongPress={onLongPressDialpad} longPressTrigger={longPressTrigger} dtmfToneAudioContext={dtmfToneAudioContext.current} disableDtmfPlayback={disableDtmfPlayback} />)}\n </Stack>;\n })}\n </FocusZone>\n </Stack>;\n};\n\n/**\n * A component to allow users to enter phone number through clicking on dialpad/using keyboard\n * It will return empty component for stable builds\n *\n * @public\n */\nexport const Dialpad = (props: DialpadProps): JSX.Element => {\n const localeStrings = useLocale().strings.dialpad;\n const strings = {\n ...localeStrings,\n ...props.strings\n };\n return <DialpadContainer strings={strings} {...props} />;\n};\nconst sanitizeInput = (input: string): string => {\n // remove non-valid characters from input: letters,special characters excluding +, *,#\n return input.replace(/[^\\d*#+]/g, '');\n};"]}
|
1
|
+
{"version":3,"file":"Dialpad.js","sourceRoot":"","sources":["../../../../../../preprocess-dist/react-components/src/components/Dialpad/Dialpad.tsx"],"names":[],"mappings":"AAAA,uCAAuC;AACvC,kCAAkC;;;;;;;;;;AAElC,OAAO,KAAK,EAAE,EAAE,SAAS,EAAE,MAAM,EAAE,MAAM,OAAO,CAAC;AAEjD,OAAO,EAAE,UAAU,EAAE,MAAM,iBAAiB,CAAC;AAC7C,OAAO,EAAE,eAAe,EAAE,aAAa,EAAE,SAAS,EAAE,WAAW,EAAE,KAAK,EAAE,IAAI,EAAE,SAAS,EAAE,QAAQ,EAAE,MAAM,iBAAiB,CAAC;AAE3H,OAAO,EAAE,QAAQ,EAAE,MAAM,OAAO,CAAC;AACjC,OAAO,EAAE,SAAS,EAAE,MAAM,oBAAoB,CAAC;AAC/C,OAAO,EAAE,YAAY,EAAE,eAAe,EAAE,gBAAgB,EAAE,WAAW,EAAE,YAAY,EAAE,eAAe,EAAE,MAAM,0BAA0B,CAAC;AACvI,OAAO,EAAE,kBAAkB,EAAE,MAAM,4BAA4B,CAAC;AAChE,OAAO,YAAY,MAAM,uBAAuB,CAAC;AACjD,OAAO,EAAE,eAAe,EAAuB,IAAI,EAAE,MAAM,qBAA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,EAAE,CAAC,CAAC;AACxC,CAAC,CAAC","sourcesContent":["// Copyright (c) Microsoft Corporation.\n// Licensed under the MIT License.\n\nimport React, { useEffect, useRef } from 'react';\nimport { IStyle, IButtonStyles, ITextFieldStyles } from '@fluentui/react';\nimport { IconButton } from '@fluentui/react';\nimport { concatStyleSets, DefaultButton, FocusZone, mergeStyles, Stack, Text, TextField, useTheme } from '@fluentui/react';\nimport { _formatString } from '@internal/acs-ui-common';\nimport { useState } from 'react';\nimport { useLocale } from '../../localization';\nimport { buttonStyles, containerStyles, iconButtonStyles, digitStyles, letterStyles, textFieldStyles } from '../styles/Dialpad.styles';\nimport { _formatPhoneNumber } from '../utils/formatPhoneNumber';\nimport useLongPress from '../utils/useLongPress';\nimport { dtmfFrequencies, DtmfFrequenciesKeys, Tone } from './DTMFToneGenerator';\n\n/**\n * Strings of {@link Dialpad} that can be overridden.\n *\n * @public\n */\nexport interface DialpadStrings {\n placeholderText: string;\n deleteButtonAriaLabel?: string;\n}\n\n/**\n * Styles for {@link Dialpad} component.\n *\n * @public\n */\nexport interface DialpadStyles {\n root?: IStyle;\n button?: IButtonStyles;\n textField?: Partial<ITextFieldStyles>;\n digit?: IStyle;\n letter?: IStyle;\n deleteIcon?: IButtonStyles;\n}\n\n/**\n * DTMF tone for PSTN calls.\n *\n * @public\n */\nexport type DtmfTone = 'A' | 'B' | 'C' | 'D' | 'Flash' | 'Num0' | 'Num1' | 'Num2' | 'Num3' | 'Num4' | 'Num5' | 'Num6' | 'Num7' | 'Num8' | 'Num9' | 'Pound' | 'Star';\n\n/**\n * Modes of the dialpad component.\n * @public\n */\nexport type DialpadMode = 'dtmf' | 'dialer';\n\n/**\n * Modes of how the longpress handlers can be tiggered.\n * @public\n */\nexport type LongPressTrigger = 'mouseAndTouch' | 'touch';\n\n/**\n * Props for {@link Dialpad} component.\n *\n * @public\n */\nexport interface DialpadProps {\n strings?: DialpadStrings;\n /**\n * function to send dtmf tones on button click\n */\n onSendDtmfTone?: (dtmfTone: DtmfTone) => Promise<void>;\n /**\n * Callback for dialpad button behavior\n */\n onClickDialpadButton?: (buttonValue: string, buttonIndex: number) => void;\n /**\n * set dialpad textfield content\n */\n textFieldValue?: string;\n /**\n * on change function for text field, provides an unformatted plain text\n */\n onChange?: (input: string) => void;\n /**\n * flag to determine when to show/hide delete button, default true\n */\n showDeleteButton?: boolean;\n /**\n * Determines what kind of device that the user is on and should respect that based on interaction\n * interfaces available to the user\n */\n longPressTrigger?: LongPressTrigger;\n /**\n * Styles for customizing the dialpad component\n */\n styles?: DialpadStyles;\n /**\n * Disables DTMF sounds when dialpad buttons are pressed. the actual\n * tones are still sent to the call.\n */\n disableDtmfPlayback?: boolean;\n /**\n * Dialer mode for the dialpad. The dtmf mode is for sending dtmf tones and the appearence of\n * the dialpad is changed like hiding the input box. When using dialer mode the input box is there\n * and can be edited to change the number being dialed.\n */\n dialpadMode?: DialpadMode;\n /**\n * Audio context for generating DTMF tones. If this if not provided the dialpad will create one iteslf.\n */\n dtmfAudioContext?: AudioContext;\n}\ntype DialpadButtonContent = {\n /** Number displayed on each dialpad button */\n digit: DtmfFrequenciesKeys;\n /** Letters displayed on each dialpad button */\n letter?: string;\n};\nconst dialPadButtonsDefault: DialpadButtonContent[][] = [[{\n digit: '1'\n}, {\n digit: '2',\n letter: 'ABC'\n}, {\n digit: '3',\n letter: 'DEF'\n}], [{\n digit: '4',\n letter: 'GHI'\n}, {\n digit: '5',\n letter: 'JKL'\n}, {\n digit: '6',\n letter: 'MNO'\n}], [{\n digit: '7',\n letter: 'PQRS'\n}, {\n digit: '8',\n letter: 'TUV'\n}, {\n digit: '9',\n letter: 'WXYZ'\n}], [{\n digit: '*'\n}, {\n digit: '0',\n letter: '+'\n}, {\n digit: '#'\n}]];\nconst DtmfTones: DtmfTone[] = ['Num1', 'Num2', 'Num3', 'Num4', 'Num5', 'Num6', 'Num7', 'Num8', 'Num9', 'Star', 'Num0', 'Pound'];\nconst DialpadButton = (props: {\n digit: DtmfFrequenciesKeys;\n letter?: string;\n styles?: DialpadStyles;\n index: number;\n onClick: (input: string, index: number) => void;\n onLongPress: (input: string, index: number) => void;\n longPressTrigger: LongPressTrigger;\n dtmfToneAudioContext: AudioContext;\n disableDtmfPlayback?: boolean;\n}): JSX.Element => {\n const theme = useTheme();\n const {\n digit,\n index,\n onClick,\n onLongPress,\n longPressTrigger,\n dtmfToneAudioContext,\n disableDtmfPlayback\n } = props;\n const [buttonPressed, setButtonPressed] = useState(false);\n const dtmfToneSound = useRef<Tone>(new Tone(dtmfToneAudioContext, dtmfFrequencies[digit].f1, dtmfFrequencies[digit].f2));\n const useLongPressProps = React.useMemo(() => ({\n onClick: async () => {\n onClick(digit, index);\n },\n onLongPress: async () => {\n onLongPress(digit, index);\n },\n touchEventsOnly: longPressTrigger === 'touch'\n }), [digit, index, longPressTrigger, onClick, onLongPress]);\n const longPressHandlers = useLongPress(useLongPressProps);\n return <DefaultButton data-test-id={`dialpad-button-${props.index}`} styles={concatStyleSets(buttonStyles(theme), props.styles?.button)} {...longPressHandlers} onKeyDown={e => {\n if ((e.key === 'Enter' || e.key === ' ') && !buttonPressed) {\n if (!disableDtmfPlayback) {\n dtmfToneSound.current.play();\n }\n longPressHandlers.onKeyDown();\n setButtonPressed(true);\n return;\n }\n if (e.key === 'Tab' || e.key === 'ArrowLeft' || e.key === 'ArrowRight' || e.key === 'ArrowUp' || e.key === 'ArrowDown') {\n dtmfToneSound.current.stop();\n return;\n }\n longPressHandlers.onKeyDown();\n }} onKeyUp={e => {\n if ((e.key === 'Enter' || e.key === ' ') && buttonPressed) {\n dtmfToneSound.current.stop();\n longPressHandlers.onKeyUp();\n setButtonPressed(false);\n }\n longPressHandlers.onKeyUp();\n }} onMouseDown={() => {\n if (!disableDtmfPlayback) {\n dtmfToneSound.current.play();\n }\n longPressHandlers.onMouseDown();\n }} onMouseUp={() => {\n dtmfToneSound.current.stop();\n longPressHandlers.onMouseUp();\n }} onMouseLeave={() => {\n dtmfToneSound.current.stop();\n }} onTouchStart={() => {\n if (!disableDtmfPlayback) {\n dtmfToneSound.current.play();\n }\n longPressHandlers.onTouchStart();\n }} onTouchEnd={() => {\n dtmfToneSound.current.stop();\n longPressHandlers.onTouchEnd();\n }}>\n <Stack>\n <Text className={mergeStyles(digitStyles(theme), props.styles?.digit)}>{props.digit}</Text>\n\n <Text className={mergeStyles(letterStyles(theme), props.styles?.letter)}>{props.letter ?? ' '}</Text>\n </Stack>\n </DefaultButton>;\n};\nconst DialpadContainer = (props: {\n strings: DialpadStrings;\n onSendDtmfTone?: (dtmfTone: DtmfTone) => Promise<void>;\n /** Callback for dialpad button behavior */\n onClickDialpadButton?: (buttonValue: string, buttonIndex: number) => void;\n /** Pass in custom content to dialpad textfield */\n textFieldValue?: string;\n /** on change function for text field, provides an unformatted plain text */\n onChange?: (input: string) => void;\n /** boolean input to determine when to show/hide delete button, default true */\n showDeleteButton?: boolean;\n /** boolean input to determine if dialpad is in mobile view, default false */\n longPressTrigger?: LongPressTrigger;\n styles?: DialpadStyles;\n disableDtmfPlayback?: boolean;\n dialpadMode?: DialpadMode;\n dtmfAudioContext?: AudioContext;\n}): JSX.Element => {\n const theme = useTheme();\n const {\n onSendDtmfTone,\n onClickDialpadButton,\n textFieldValue,\n onChange,\n showDeleteButton = true,\n longPressTrigger = 'mouseAndTouch',\n disableDtmfPlayback,\n dialpadMode = 'dialer',\n dtmfAudioContext\n } = props;\n const dtmfToneAudioContext = useRef(dtmfAudioContext ? dtmfAudioContext : new AudioContext());\n const [plainTextValue, setPlainTextValue] = useState(textFieldValue ?? '');\n const plainTextValuePreviousRenderValue = useRef(plainTextValue);\n useEffect(() => {\n if (plainTextValuePreviousRenderValue.current !== plainTextValue) {\n onChange?.(plainTextValue);\n }\n plainTextValuePreviousRenderValue.current = plainTextValue;\n }, [plainTextValuePreviousRenderValue, plainTextValue, onChange]);\n useEffect(() => {\n setText(textFieldValue ?? '');\n }, [textFieldValue]);\n const onClickDialpad = (input: string, index: number): void => {\n setText(plainTextValue + input);\n if (onSendDtmfTone) {\n onSendDtmfTone(DtmfTones[index]);\n }\n if (onClickDialpadButton) {\n onClickDialpadButton(input, index);\n }\n };\n const onLongPressDialpad = (input: string, index: number): void => {\n if (input === '0' && index === 10) {\n setText(plainTextValue + '+');\n } else {\n setText(plainTextValue + input);\n }\n if (onSendDtmfTone) {\n onSendDtmfTone(DtmfTones[index]);\n }\n if (onClickDialpadButton) {\n onClickDialpadButton(input, index);\n }\n };\n\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n const setText = (input: string): void => {\n // remove non-valid characters from input: letters,special characters excluding +, *,#\n const plainInput = sanitizeInput(input);\n setPlainTextValue(plainInput);\n };\n const deleteNumbers = (): void => {\n const modifiedInput = plainTextValue.substring(0, plainTextValue.length - 1);\n setText(modifiedInput);\n };\n return <Stack className={mergeStyles(containerStyles(theme), props.styles?.root)} data-test-id=\"dialpadContainer\" data-ui-id=\"dialpadContainer\" horizontalAlign={'center'}>\n {dialpadMode === 'dialer' && <TextField styles={concatStyleSets(textFieldStyles(theme, plainTextValue !== ''), props.styles?.textField)} value={textFieldValue ? textFieldValue : _formatPhoneNumber(plainTextValue)}\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n onChange={(e: any) => {\n setText(e.target.value);\n }} onClick={e => {\n e.preventDefault();\n }} placeholder={props.strings.placeholderText} data-test-id=\"dialpad-input\" onRenderSuffix={(): JSX.Element => <>\n {showDeleteButton && plainTextValue.length !== 0 && <IconButton ariaLabel={props.strings.deleteButtonAriaLabel} onClick={deleteNumbers} styles={concatStyleSets(iconButtonStyles(theme), props.styles?.deleteIcon)} iconProps={{\n iconName: 'DialpadBackspace'\n }} />}\n </>} />}\n <FocusZone>\n {dialPadButtonsDefault.map((rows, rowIndex) => {\n return <Stack horizontal key={`row_${rowIndex}`} horizontalAlign=\"stretch\" tokens={{\n childrenGap: '1rem'\n }}>\n {rows.map((button, columnIndex) => <DialpadButton key={`button_${columnIndex}`}\n /* row index = 0\n columnIndex: (0,1,2) => (0,1,2)\n row index = 1\n columnIndex: (0,1,2)=> (3,4,5)\n row index = 2\n columnIndex: (0,1,2)=> (6,7,8)\n row index = 3\n columnIndex: (0,1,2)=> (9,10,11)\n columnIndex + rowIndex*rows.length calculates the corresponding index for each button\n dialpad index:\n 0 1 2\n 3 4 5\n 6 7 8\n 9 10 11\n then use this index to locate the corresponding dtmf tones\n DtmfTones[index]\n */ index={columnIndex + rowIndex * rows.length} digit={button.digit} letter={button.letter} styles={props.styles} onClick={onClickDialpad} onLongPress={onLongPressDialpad} longPressTrigger={longPressTrigger} dtmfToneAudioContext={dtmfToneAudioContext.current} disableDtmfPlayback={disableDtmfPlayback} />)}\n </Stack>;\n })}\n </FocusZone>\n </Stack>;\n};\n\n/**\n * A component to allow users to enter phone number through clicking on dialpad/using keyboard\n * It will return empty component for stable builds\n *\n * @public\n */\nexport const Dialpad = (props: DialpadProps): JSX.Element => {\n const localeStrings = useLocale().strings.dialpad;\n const strings = {\n ...localeStrings,\n ...props.strings\n };\n return <DialpadContainer strings={strings} {...props} />;\n};\nconst sanitizeInput = (input: string): string => {\n // remove non-valid characters from input: letters,special characters excluding +, *,#\n return input.replace(/[^\\d*#+]/g, '');\n};"]}
|
@@ -51,11 +51,6 @@ export interface MeetingConferencePhoneInfoModalProps {
|
|
51
51
|
* a component for setting spoken languages
|
52
52
|
*/
|
53
53
|
export declare const MeetingConferencePhoneInfoModal: (props: MeetingConferencePhoneInfoModalProps) => JSX.Element;
|
54
|
-
/**
|
55
|
-
* @internal
|
56
|
-
* format phone number
|
57
|
-
*/
|
58
|
-
export declare const formatPhoneNumber: (phoneNumber: string) => string;
|
59
54
|
/**
|
60
55
|
* @internal
|
61
56
|
* format phone number link
|
@@ -11,9 +11,8 @@ import { themedPhoneInfoModalStyle, titleClassName, titleContainerClassName, pho
|
|
11
11
|
/* @conditional-compile-remove(teams-meeting-conference) */
|
12
12
|
import { useLocale } from '../localization';
|
13
13
|
/* @conditional-compile-remove(teams-meeting-conference) */
|
14
|
-
import { isPossiblePhoneNumber, parsePhoneNumber } from 'libphonenumber-js';
|
15
|
-
/* @conditional-compile-remove(teams-meeting-conference) */
|
16
14
|
import { _pxToRem } from "../../../acs-ui-common/src";
|
15
|
+
import { _formatPhoneNumber } from './utils/formatPhoneNumber';
|
17
16
|
/* @conditional-compile-remove(teams-meeting-conference) */
|
18
17
|
/**
|
19
18
|
* @public
|
@@ -54,7 +53,7 @@ export const MeetingConferencePhoneInfoModal = (props) => {
|
|
54
53
|
React.createElement(Text, { className: stepTextStyle }, strings === null || strings === void 0 ? void 0 : strings.meetingConferencePhoneInfoModalDialIn)))),
|
55
54
|
React.createElement(Stack.Item, { className: phoneInfoStep }, conferencePhoneInfoList.map((phoneNumber, index) => React.createElement(Stack.Item, { key: index },
|
56
55
|
React.createElement(Text, { className: phoneInfoTextStyle },
|
57
|
-
|
56
|
+
_formatPhoneNumber(phoneNumber.phoneNumber, true),
|
58
57
|
' ',
|
59
58
|
phoneNumber.isTollFree ? strings.meetingConferencePhoneInfoModalTollFree : strings.meetingConferencePhoneInfoModalToll),
|
60
59
|
React.createElement("br", null),
|
@@ -83,25 +82,6 @@ export const MeetingConferencePhoneInfoModal = (props) => {
|
|
83
82
|
React.createElement(Text, { className: stepTextStyle }, strings === null || strings === void 0 ? void 0 : strings.meetingConferencePhoneInfoModalWait)))))));
|
84
83
|
};
|
85
84
|
/* @conditional-compile-remove(teams-meeting-conference) */
|
86
|
-
/**
|
87
|
-
* @internal
|
88
|
-
* format phone number
|
89
|
-
*/
|
90
|
-
export const formatPhoneNumber = (phoneNumber) => {
|
91
|
-
var _a;
|
92
|
-
if (!phoneNumber) {
|
93
|
-
return '';
|
94
|
-
}
|
95
|
-
let enchantedPhoneNumber = phoneNumber;
|
96
|
-
if (!phoneNumber.startsWith('+')) {
|
97
|
-
enchantedPhoneNumber = `+${phoneNumber}`;
|
98
|
-
}
|
99
|
-
if (isPossiblePhoneNumber(enchantedPhoneNumber)) {
|
100
|
-
return ((_a = parsePhoneNumber(enchantedPhoneNumber)) === null || _a === void 0 ? void 0 : _a.formatInternational()) || enchantedPhoneNumber;
|
101
|
-
}
|
102
|
-
return phoneNumber;
|
103
|
-
};
|
104
|
-
/* @conditional-compile-remove(teams-meeting-conference) */
|
105
85
|
/**
|
106
86
|
* @internal
|
107
87
|
* format phone number link
|
@@ -116,7 +96,7 @@ export const formatPhoneNumberLink = (phoneNumber) => {
|
|
116
96
|
*/
|
117
97
|
export const formatPhoneNumberInfo = (phoneNumber, strings) => {
|
118
98
|
const templateText = phoneNumber.country && phoneNumber.city ? strings === null || strings === void 0 ? void 0 : strings.meetingConferencePhoneInfoModalTollGeoData : '';
|
119
|
-
return (templateText === null || templateText === void 0 ? void 0 : templateText.replace('{
|
99
|
+
return (templateText === null || templateText === void 0 ? void 0 : templateText.replace('{country}', phoneNumber.country || '').replace('{city}', phoneNumber.city || '').trim()) || '';
|
120
100
|
};
|
121
101
|
/* @conditional-compile-remove(teams-meeting-conference) */
|
122
102
|
/**
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"MeetingConferencePhoneInfo.js","sourceRoot":"","sources":["../../../../../preprocess-dist/react-components/src/components/MeetingConferencePhoneInfo.tsx"],"names":[],"mappings":"AAAA,uCAAuC;AACvC,kCAAkC;AAElC,2DAA2D;AAC3D,OAAO,KAAK,EAAE,EAAE,WAAW,EAAE,MAAM,OAAO,CAAC;AAC3C,2DAA2D;AAC3D,OAAO,EAAE,OAAO,EAAE,MAAM,OAAO,CAAC;AAChC,2DAA2D;AAC3D,OAAO,EAAgB,KAAK,EAAE,KAAK,EAAE,QAAQ,EAAE,IAAI,EAAE,UAAU,EAAE,IAAI,EAAE,MAAM,iBAAiB,CAAC;AAE/F,2DAA2D;AAC3D,OAAO,EAAE,yBAAyB,EAAE,cAAc,EAAE,uBAAuB,EAAE,kBAAkB,EAAE,aAAa,EAAE,wBAAwB,EAAE,aAAa,EAAE,aAAa,EAAE,uBAAuB,EAAE,kBAAkB,EAAE,M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-compile-remove(teams-meeting-conference) */\nimport React, { useCallback } from 'react';\n/* @conditional-compile-remove(teams-meeting-conference) */\nimport { useMemo } from 'react';\n/* @conditional-compile-remove(teams-meeting-conference) */\nimport { IModalStyles, Modal, Stack, useTheme, Text, IconButton, Icon } from '@fluentui/react';\n\n/* @conditional-compile-remove(teams-meeting-conference) */\nimport { themedPhoneInfoModalStyle, titleClassName, titleContainerClassName, phoneInfoTextStyle, phoneInfoIcon, phoneInfoInctructionLine, phoneInfoStep, stepTextStyle, infoConnectionLinkStyle, phoneInfoIconStyle } from './styles/TeamsMeetingConferenceInfo';\n/* @conditional-compile-remove(teams-meeting-conference) */\nimport { _preventDismissOnEvent } from '@internal/acs-ui-common';\n/* @conditional-compile-remove(teams-meeting-conference) */\nimport { useLocale } from '../localization';\n/* @conditional-compile-remove(teams-meeting-conference) */\nimport { isPossiblePhoneNumber, parsePhoneNumber } from 'libphonenumber-js';\n/* @conditional-compile-remove(teams-meeting-conference) */\nimport { _pxToRem } from '@internal/acs-ui-common';\n\n/* @conditional-compile-remove(teams-meeting-conference) */\n/**\n * strings for phone info modal\n * @public\n */\nexport interface MeetingConferencePhoneInfoModalStrings {\n /**\n * Header for the phone info modal\n */\n meetingConferencePhoneInfoModalTitle: string;\n /**\n * Phone number instruction\n */\n meetingConferencePhoneInfoModalDialIn: string;\n /**\n * Meeting ID instruction\n */\n meetingConferencePhoneInfoModalMeetingId: string;\n /**\n * Wait for phone connection\n */\n meetingConferencePhoneInfoModalWait: string;\n /**\n * Toll Free Phone Label\n */\n meetingConferencePhoneInfoModalTollFree: string;\n /**\n * Toll Phone Label\n */\n meetingConferencePhoneInfoModalToll: string;\n /**\n * Toll Phone Label without geo data\n */\n meetingConferencePhoneInfoModalTollGeoData: string;\n /**\n * No phone number available message\n */\n meetingConferencePhoneInfoModalNoPhoneAvailable: string;\n}\n\n/* @conditional-compile-remove(teams-meeting-conference) */\n/**\n * @public\n * MeetingConferencePhoneInfoModal Component Props.\n */\nexport interface MeetingConferencePhoneInfoModalProps {\n conferencePhoneInfoList: ConferencePhoneInfo[];\n showModal?: boolean;\n onDismissMeetingPhoneInfoSettings?: () => void;\n}\n\n/* @conditional-compile-remove(teams-meeting-conference) */\n/**\n * @public\n * a component for setting spoken languages\n */\nexport const MeetingConferencePhoneInfoModal = (props: MeetingConferencePhoneInfoModalProps): JSX.Element => {\n const {\n conferencePhoneInfoList,\n showModal,\n onDismissMeetingPhoneInfoSettings\n } = props;\n const theme = useTheme();\n const strings = useLocale().strings.meetingConferencePhoneInfo;\n const onDismiss = useCallback((): void => {\n if (onDismissMeetingPhoneInfoSettings) {\n onDismissMeetingPhoneInfoSettings();\n }\n }, [onDismissMeetingPhoneInfoSettings]);\n const PhoneInfoModalStyle: Partial<IModalStyles> = useMemo(() => themedPhoneInfoModalStyle(theme), [theme]);\n return <>\n <Modal titleAriaId={strings?.meetingConferencePhoneInfoModalTitle} isOpen={showModal} onDismiss={onDismiss} isBlocking={true} styles={PhoneInfoModalStyle}>\n <Stack horizontal horizontalAlign=\"space-between\" verticalAlign=\"center\" className={titleContainerClassName}>\n <Text className={titleClassName}>{strings?.meetingConferencePhoneInfoModalTitle}</Text>\n <IconButton iconProps={{\n iconName: 'Cancel'\n }} ariaLabel={strings?.meetingConferencePhoneInfoModalTitle} onClick={onDismiss} style={{\n color: theme.palette.black\n }} />\n </Stack>\n {conferencePhoneInfoList.length === 0 && <Stack horizontal>\n <Text className={stepTextStyle}>{strings?.meetingConferencePhoneInfoModalNoPhoneAvailable}</Text>\n </Stack>}\n {conferencePhoneInfoList.length > 0 && <Stack>\n <Stack horizontal horizontalAlign=\"space-between\" className={phoneInfoInctructionLine}>\n <Stack.Item style={{\n display: 'flex'\n }}>\n <Stack horizontal className={phoneInfoStep}>\n <Stack className={infoConnectionLinkStyle(theme)}></Stack>\n <Stack.Item className={phoneInfoIcon(theme)}>\n <Stack verticalAlign=\"center\" horizontalAlign=\"center\">\n <Icon iconName=\"JoinByPhoneDialStepIcon\" className={phoneInfoIconStyle(theme)} />\n </Stack>\n </Stack.Item>\n <Stack.Item>\n <Text className={stepTextStyle}>{strings?.meetingConferencePhoneInfoModalDialIn}</Text>\n </Stack.Item>\n </Stack>\n </Stack.Item>\n <Stack.Item className={phoneInfoStep}>\n {conferencePhoneInfoList.map((phoneNumber, index) => <Stack.Item key={index}>\n <Text className={phoneInfoTextStyle}>\n {formatPhoneNumber(phoneNumber.phoneNumber)}{' '}\n {phoneNumber.isTollFree ? strings.meetingConferencePhoneInfoModalTollFree : strings.meetingConferencePhoneInfoModalToll}\n </Text>\n <br />\n <Text className={phoneInfoTextStyle}> {formatPhoneNumberInfo(phoneNumber, strings)}</Text>\n </Stack.Item>)}\n </Stack.Item>\n </Stack>\n <Stack horizontal horizontalAlign=\"space-between\" verticalAlign=\"center\" className={phoneInfoInctructionLine}>\n <Stack.Item style={{\n display: 'flex'\n }}>\n <Stack horizontal>\n <Stack className={infoConnectionLinkStyle(theme)}></Stack>\n <Stack.Item className={phoneInfoIcon(theme)}>\n <Stack verticalAlign=\"center\" horizontalAlign=\"center\">\n <Icon iconName=\"JoinByPhoneConferenceIdIcon\" className={phoneInfoIconStyle(theme)} />\n </Stack>\n </Stack.Item>\n <Stack.Item>\n <Text className={stepTextStyle}>{strings?.meetingConferencePhoneInfoModalMeetingId}</Text>\n </Stack.Item>\n </Stack>\n </Stack.Item>\n <Text className={phoneInfoTextStyle}>{formatMeetingId(conferencePhoneInfoList[0].conferenceId)}</Text>\n </Stack>\n <Stack horizontal horizontalAlign=\"space-between\" verticalAlign=\"center\">\n <Stack horizontal>\n <Stack.Item className={phoneInfoIcon(theme)} style={{\n marginLeft: _pxToRem(2)\n }}>\n <Icon iconName=\"JoinByPhoneWaitToBeAdmittedIcon\" className={phoneInfoIconStyle(theme)} />\n </Stack.Item>\n <Stack.Item>\n <Text className={stepTextStyle}>{strings?.meetingConferencePhoneInfoModalWait}</Text>\n </Stack.Item>\n </Stack>\n </Stack>\n </Stack>}\n </Modal>\n </>;\n};\n\n/* @conditional-compile-remove(teams-meeting-conference) */\n/**\n * @internal\n * format phone number\n */\nexport const formatPhoneNumber = (phoneNumber: string): string => {\n if (!phoneNumber) {\n return '';\n }\n let enchantedPhoneNumber = phoneNumber;\n if (!phoneNumber.startsWith('+')) {\n enchantedPhoneNumber = `+${phoneNumber}`;\n }\n if (isPossiblePhoneNumber(enchantedPhoneNumber)) {\n return parsePhoneNumber(enchantedPhoneNumber)?.formatInternational() || enchantedPhoneNumber;\n }\n return phoneNumber;\n};\n\n/* @conditional-compile-remove(teams-meeting-conference) */\n/**\n * @internal\n * format phone number link\n */\nexport const formatPhoneNumberLink = (phoneNumber: ConferencePhoneInfo): string => {\n return `tel:+${phoneNumber.phoneNumber},,${phoneNumber.conferenceId}#`;\n};\n\n/* @conditional-compile-remove(teams-meeting-conference) */\n/**\n * @internal\n * format phone number\n */\nexport const formatPhoneNumberInfo = (phoneNumber: ConferencePhoneInfo, strings: MeetingConferencePhoneInfoModalStrings | undefined): string => {\n const templateText = phoneNumber.country && phoneNumber.city ? strings?.meetingConferencePhoneInfoModalTollGeoData : '';\n return templateText?.replace('{phoneNumber}', formatPhoneNumber(phoneNumber.phoneNumber)).replace('{country}', phoneNumber.country || '').replace('{city}', phoneNumber.city || '').trim() || '';\n};\n\n/* @conditional-compile-remove(teams-meeting-conference) */\n/**\n * @internal\n * format meeting id\n */\nexport const formatMeetingId = (meetingId?: string): string => {\n if (!meetingId) {\n return '';\n }\n if (meetingId?.length !== 9) {\n return meetingId;\n }\n return [meetingId.slice(0, 3), meetingId.slice(3, 6), meetingId.slice(6, 9)].join(' ') + '#';\n};\n\n/* @conditional-compile-remove(teams-meeting-conference) */\n/**\n * @public\n * Information for conference phone info\n */\nexport interface ConferencePhoneInfo {\n phoneNumber: string;\n conferenceId: string;\n isTollFree: boolean;\n country?: string;\n city?: string;\n}"]}
|
1
|
+
{"version":3,"file":"MeetingConferencePhoneInfo.js","sourceRoot":"","sources":["../../../../../preprocess-dist/react-components/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AC,YAAY,GAAG,CAAC;AACzE,CAAC,CAAC;AAEF,2DAA2D;AAC3D;;;GAGG;AACH,MAAM,CAAC,MAAM,qBAAqB,GAAG,CAAC,WAAgC,EAAE,OAA2D,EAAU,EAAE;IAC7I,MAAM,YAAY,GAAG,WAAW,CAAC,OAAO,IAAI,WAAW,CAAC,IAAI,CAAC,CAAC,CAAC,OAAO,aAAP,OAAO,uBAAP,OAAO,CAAE,0CAA0C,CAAC,CAAC,CAAC,EAAE,CAAC;IACxH,OAAO,CAAA,YAAY,aAAZ,YAAY,uBAAZ,YAAY,CAAE,OAAO,CAAC,WAAW,EAAE,WAAW,CAAC,OAAO,IAAI,EAAE,EAAE,OAAO,CAAC,QAAQ,EAAE,WAAW,CAAC,IAAI,IAAI,EAAE,EAAE,IAAI,EAAE,KAAI,EAAE,CAAC;AAC9H,CAAC,CAAC;AAEF,2DAA2D;AAC3D;;;GAGG;AACH,MAAM,CAAC,MAAM,eAAe,GAAG,CAAC,SAAkB,EAAU,EAAE;IAC5D,IAAI,CAAC,SAAS,EAAE,CAAC;QACf,OAAO,EAAE,CAAC;IACZ,CAAC;IACD,IAAI,CAAA,SAAS,aAAT,SAAS,uBAAT,SAAS,CAAE,MAAM,MAAK,CAAC,EAAE,CAAC;QAC5B,OAAO,SAAS,CAAC;IACnB,CAAC;IACD,OAAO,CAAC,SAAS,CAAC,KAAK,CAAC,CAAC,EAAE,CAAC,CAAC,EAAE,SAAS,CAAC,KAAK,CAAC,CAAC,EAAE,CAAC,CAAC,EAAE,SAAS,CAAC,KAAK,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,CAAC,IAAI,CAAC,GAAG,CAAC,GAAG,GAAG,CAAC;AAC/F,CAAC,CAAC","sourcesContent":["// Copyright (c) Microsoft Corporation.\n// Licensed under the MIT License.\n\n/* @conditional-compile-remove(teams-meeting-conference) */\nimport React, { useCallback } from 'react';\n/* @conditional-compile-remove(teams-meeting-conference) */\nimport { useMemo } from 'react';\n/* @conditional-compile-remove(teams-meeting-conference) */\nimport { IModalStyles, Modal, Stack, useTheme, Text, IconButton, Icon } from '@fluentui/react';\n\n/* @conditional-compile-remove(teams-meeting-conference) */\nimport { themedPhoneInfoModalStyle, titleClassName, titleContainerClassName, phoneInfoTextStyle, phoneInfoIcon, phoneInfoInctructionLine, phoneInfoStep, stepTextStyle, infoConnectionLinkStyle, phoneInfoIconStyle } from './styles/TeamsMeetingConferenceInfo';\n/* @conditional-compile-remove(teams-meeting-conference) */\nimport { _preventDismissOnEvent } from '@internal/acs-ui-common';\n/* @conditional-compile-remove(teams-meeting-conference) */\nimport { useLocale } from '../localization';\n/* @conditional-compile-remove(teams-meeting-conference) */\nimport { _pxToRem } from '@internal/acs-ui-common';\nimport { _formatPhoneNumber } from './utils/formatPhoneNumber';\n\n/* @conditional-compile-remove(teams-meeting-conference) */\n/**\n * strings for phone info modal\n * @public\n */\nexport interface MeetingConferencePhoneInfoModalStrings {\n /**\n * Header for the phone info modal\n */\n meetingConferencePhoneInfoModalTitle: string;\n /**\n * Phone number instruction\n */\n meetingConferencePhoneInfoModalDialIn: string;\n /**\n * Meeting ID instruction\n */\n meetingConferencePhoneInfoModalMeetingId: string;\n /**\n * Wait for phone connection\n */\n meetingConferencePhoneInfoModalWait: string;\n /**\n * Toll Free Phone Label\n */\n meetingConferencePhoneInfoModalTollFree: string;\n /**\n * Toll Phone Label\n */\n meetingConferencePhoneInfoModalToll: string;\n /**\n * Toll Phone Label without geo data\n */\n meetingConferencePhoneInfoModalTollGeoData: string;\n /**\n * No phone number available message\n */\n meetingConferencePhoneInfoModalNoPhoneAvailable: string;\n}\n\n/* @conditional-compile-remove(teams-meeting-conference) */\n/**\n * @public\n * MeetingConferencePhoneInfoModal Component Props.\n */\nexport interface MeetingConferencePhoneInfoModalProps {\n conferencePhoneInfoList: ConferencePhoneInfo[];\n showModal?: boolean;\n onDismissMeetingPhoneInfoSettings?: () => void;\n}\n\n/* @conditional-compile-remove(teams-meeting-conference) */\n/**\n * @public\n * a component for setting spoken languages\n */\nexport const MeetingConferencePhoneInfoModal = (props: MeetingConferencePhoneInfoModalProps): JSX.Element => {\n const {\n conferencePhoneInfoList,\n showModal,\n onDismissMeetingPhoneInfoSettings\n } = props;\n const theme = useTheme();\n const strings = useLocale().strings.meetingConferencePhoneInfo;\n const onDismiss = useCallback((): void => {\n if (onDismissMeetingPhoneInfoSettings) {\n onDismissMeetingPhoneInfoSettings();\n }\n }, [onDismissMeetingPhoneInfoSettings]);\n const PhoneInfoModalStyle: Partial<IModalStyles> = useMemo(() => themedPhoneInfoModalStyle(theme), [theme]);\n return <>\n <Modal titleAriaId={strings?.meetingConferencePhoneInfoModalTitle} isOpen={showModal} onDismiss={onDismiss} isBlocking={true} styles={PhoneInfoModalStyle}>\n <Stack horizontal horizontalAlign=\"space-between\" verticalAlign=\"center\" className={titleContainerClassName}>\n <Text className={titleClassName}>{strings?.meetingConferencePhoneInfoModalTitle}</Text>\n <IconButton iconProps={{\n iconName: 'Cancel'\n }} ariaLabel={strings?.meetingConferencePhoneInfoModalTitle} onClick={onDismiss} style={{\n color: theme.palette.black\n }} />\n </Stack>\n {conferencePhoneInfoList.length === 0 && <Stack horizontal>\n <Text className={stepTextStyle}>{strings?.meetingConferencePhoneInfoModalNoPhoneAvailable}</Text>\n </Stack>}\n {conferencePhoneInfoList.length > 0 && <Stack>\n <Stack horizontal horizontalAlign=\"space-between\" className={phoneInfoInctructionLine}>\n <Stack.Item style={{\n display: 'flex'\n }}>\n <Stack horizontal className={phoneInfoStep}>\n <Stack className={infoConnectionLinkStyle(theme)}></Stack>\n <Stack.Item className={phoneInfoIcon(theme)}>\n <Stack verticalAlign=\"center\" horizontalAlign=\"center\">\n <Icon iconName=\"JoinByPhoneDialStepIcon\" className={phoneInfoIconStyle(theme)} />\n </Stack>\n </Stack.Item>\n <Stack.Item>\n <Text className={stepTextStyle}>{strings?.meetingConferencePhoneInfoModalDialIn}</Text>\n </Stack.Item>\n </Stack>\n </Stack.Item>\n <Stack.Item className={phoneInfoStep}>\n {conferencePhoneInfoList.map((phoneNumber, index) => <Stack.Item key={index}>\n <Text className={phoneInfoTextStyle}>\n {_formatPhoneNumber(phoneNumber.phoneNumber, true)}{' '}\n {phoneNumber.isTollFree ? strings.meetingConferencePhoneInfoModalTollFree : strings.meetingConferencePhoneInfoModalToll}\n </Text>\n <br />\n <Text className={phoneInfoTextStyle}> {formatPhoneNumberInfo(phoneNumber, strings)}</Text>\n </Stack.Item>)}\n </Stack.Item>\n </Stack>\n <Stack horizontal horizontalAlign=\"space-between\" verticalAlign=\"center\" className={phoneInfoInctructionLine}>\n <Stack.Item style={{\n display: 'flex'\n }}>\n <Stack horizontal>\n <Stack className={infoConnectionLinkStyle(theme)}></Stack>\n <Stack.Item className={phoneInfoIcon(theme)}>\n <Stack verticalAlign=\"center\" horizontalAlign=\"center\">\n <Icon iconName=\"JoinByPhoneConferenceIdIcon\" className={phoneInfoIconStyle(theme)} />\n </Stack>\n </Stack.Item>\n <Stack.Item>\n <Text className={stepTextStyle}>{strings?.meetingConferencePhoneInfoModalMeetingId}</Text>\n </Stack.Item>\n </Stack>\n </Stack.Item>\n <Text className={phoneInfoTextStyle}>{formatMeetingId(conferencePhoneInfoList[0].conferenceId)}</Text>\n </Stack>\n <Stack horizontal horizontalAlign=\"space-between\" verticalAlign=\"center\">\n <Stack horizontal>\n <Stack.Item className={phoneInfoIcon(theme)} style={{\n marginLeft: _pxToRem(2)\n }}>\n <Icon iconName=\"JoinByPhoneWaitToBeAdmittedIcon\" className={phoneInfoIconStyle(theme)} />\n </Stack.Item>\n <Stack.Item>\n <Text className={stepTextStyle}>{strings?.meetingConferencePhoneInfoModalWait}</Text>\n </Stack.Item>\n </Stack>\n </Stack>\n </Stack>}\n </Modal>\n </>;\n};\n\n/* @conditional-compile-remove(teams-meeting-conference) */\n/**\n * @internal\n * format phone number link\n */\nexport const formatPhoneNumberLink = (phoneNumber: ConferencePhoneInfo): string => {\n return `tel:+${phoneNumber.phoneNumber},,${phoneNumber.conferenceId}#`;\n};\n\n/* @conditional-compile-remove(teams-meeting-conference) */\n/**\n * @internal\n * format phone number\n */\nexport const formatPhoneNumberInfo = (phoneNumber: ConferencePhoneInfo, strings: MeetingConferencePhoneInfoModalStrings | undefined): string => {\n const templateText = phoneNumber.country && phoneNumber.city ? strings?.meetingConferencePhoneInfoModalTollGeoData : '';\n return templateText?.replace('{country}', phoneNumber.country || '').replace('{city}', phoneNumber.city || '').trim() || '';\n};\n\n/* @conditional-compile-remove(teams-meeting-conference) */\n/**\n * @internal\n * format meeting id\n */\nexport const formatMeetingId = (meetingId?: string): string => {\n if (!meetingId) {\n return '';\n }\n if (meetingId?.length !== 9) {\n return meetingId;\n }\n return [meetingId.slice(0, 3), meetingId.slice(3, 6), meetingId.slice(6, 9)].join(' ') + '#';\n};\n\n/* @conditional-compile-remove(teams-meeting-conference) */\n/**\n * @public\n * Information for conference phone info\n */\nexport interface ConferencePhoneInfo {\n phoneNumber: string;\n conferenceId: string;\n isTollFree: boolean;\n country?: string;\n city?: string;\n}"]}
|
@@ -97,6 +97,7 @@ export * from './Caption';
|
|
97
97
|
export * from './StartCaptionsButton';
|
98
98
|
export * from './CaptionsSettingsModal';
|
99
99
|
export * from './MeetingConferencePhoneInfo';
|
100
|
+
export { _formatPhoneNumber } from './utils/formatPhoneNumber';
|
100
101
|
export { _ErrorBoundary } from './ErrorBoundary';
|
101
102
|
export * from './Notification';
|
102
103
|
export * from './NotificationStack';
|
@@ -53,6 +53,8 @@ export * from './StartCaptionsButton';
|
|
53
53
|
export * from './CaptionsSettingsModal';
|
54
54
|
/* @conditional-compile-remove(teams-meeting-conference) */
|
55
55
|
export * from './MeetingConferencePhoneInfo';
|
56
|
+
/* @conditional-compile-remove(teams-meeting-conference) */
|
57
|
+
export { _formatPhoneNumber } from './utils/formatPhoneNumber';
|
56
58
|
export { _ErrorBoundary } from './ErrorBoundary';
|
57
59
|
/* @conditional-compile-remove(notifications) */
|
58
60
|
export * from './Notification';
|
@@ -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AA6B,EAAE,MAAM,6CAA6C,CAAC;AAG5F,cAAc,kBAAkB,CAAC;AACjC,cAAc,WAAW,CAAC;AAC1B,cAAc,uBAAuB,CAAC;AACtC,cAAc,yBAAyB,CAAC;AAExC,2DAA2D;AAC3D,cAAc,8BAA8B,CAAC;AAC7C,OAAO,EAAE,cAAc,EAAE,MAAM,iBAAiB,CAAC;AACjD,gDAAgD;AAChD,cAAc,gBAAgB,CAAC;AAC/B,gDAAgD;AAChD,cAAc,qBAAqB,CAAC","sourcesContent":["// Copyright (c) Microsoft Corporation.\n// Licensed under the MIT License.\n\nexport { TypingIndicator } from './TypingIndicator';\nexport type { TypingIndicatorProps, TypingIndicatorStrings, TypingIndicatorStylesProps } from './TypingIndicator';\nexport { ErrorBar } from './ErrorBar';\nexport type { ActiveErrorMessage, ErrorBarProps, ErrorBarStrings, ErrorType } from './ErrorBar';\nexport { GridLayout } from './GridLayout';\nexport type { GridLayoutProps, GridLayoutStyles } from './GridLayout';\nexport { SendBox } from './SendBox';\nexport { ImageOverlay } from './ImageOverlay';\nexport type { ImageOverlayStrings } from './ImageOverlay';\nexport type { SendBoxProps, SendBoxStrings, SendBoxStylesProps } from './SendBox'; // TODO: This component is exported only for testing purposes. Remove this when this component is added to composites\n// TODO: This component is exported only for testing purposes. Remove this when this component is added to composites\nexport type { ImageOverlayProps } from './ImageOverlay';\nexport type { InlineImageOptions, InlineImage } from './ChatMessage/ChatMessageContent';\nexport { MessageStatusIndicator } from './MessageStatusIndicator';\nexport type { MessageStatusIndicatorProps, MessageStatusIndicatorStrings } from './MessageStatusIndicator';\nexport { MessageThread } from './MessageThread';\nexport type { MessageProps, MessageThreadProps, MessageThreadStrings, MessageThreadStyles, JumpToNewMessageButtonProps, MessageRenderer, UpdateMessageCallback, CancelEditCallback } from './MessageThread';\nexport { StreamMedia } from './StreamMedia';\nexport type { StreamMediaProps } from './StreamMedia';\nexport type { LoadingState } from './StreamMedia';\nexport { ParticipantItem } from './ParticipantItem';\nexport type { ParticipantItemProps, ParticipantItemStrings, ParticipantItemStyles } from './ParticipantItem';\nexport { ParticipantList } from './ParticipantList';\nexport type { ParticipantListItemStyles, ParticipantListProps, ParticipantListStyles, ParticipantMenuItemsCallback } from './ParticipantList';\nexport { Announcer } from './Announcer';\nexport type { AnnouncerProps } from './Announcer';\nexport { VideoGallery } from './VideoGallery';\nexport type { VideoGalleryProps, VideoGalleryStrings, VideoGalleryStyles, VideoGalleryLayout, VideoTileContextualMenuProps, VideoTileDrawerMenuProps, VideoTilesOptions } from './VideoGallery';\nexport type { OverflowGalleryPosition } from './VideoGallery';\nexport type { LocalVideoTileSize } from './VideoGallery';\nexport type { HorizontalGalleryStyles } from './HorizontalGallery';\nexport { LocalVideoCameraCycleButton } from './LocalVideoCameraButton';\nexport type { LocalVideoCameraCycleButtonProps } from './LocalVideoCameraButton';\nexport { CameraButton } from './CameraButton';\nexport type { CameraButtonContextualMenuStyles, CameraButtonProps, CameraButtonStrings, CameraButtonStyles } from './CameraButton';\nexport { ControlBar } from './ControlBar';\nexport type { ControlBarProps, ControlBarLayout } from './ControlBar';\nexport { ControlBarButton } from './ControlBarButton';\nexport type { ControlBarButtonProps, ControlBarButtonStrings, ControlBarButtonStyles } from './ControlBarButton';\nexport { EndCallButton } from './EndCallButton';\nexport type { EndCallButtonProps, EndCallButtonStrings } from './EndCallButton';\nexport { MicrophoneButton } from './MicrophoneButton';\nexport type { MicrophoneButtonStyles, MicrophoneButtonContextualMenuStyles, MicrophoneButtonProps, MicrophoneButtonStrings } from './MicrophoneButton';\nexport { DevicesButton, generateDefaultDeviceMenuProps as _generateDefaultDeviceMenuProps } from './DevicesButton';\nexport type { OptionsDevice, DevicesButtonProps, DevicesButtonStrings, DevicesButtonStyles, DevicesButtonContextualMenuStyles, DeviceMenuProps as _DeviceMenuProps, DeviceMenuStrings as _DeviceMenuStrings, DeviceMenuStyles as _DeviceMenuStyles } from './DevicesButton';\nexport { ParticipantsButton } from './ParticipantsButton';\nexport type { ParticipantsButtonContextualMenuStyles, ParticipantsButtonProps, ParticipantsButtonStrings, ParticipantsButtonStyles } from './ParticipantsButton';\nexport { ScreenShareButton } from './ScreenShareButton';\nexport type { ScreenShareButtonProps, ScreenShareButtonStrings } from './ScreenShareButton';\nexport { RaiseHandButton } from './RaiseHandButton';\nexport type { RaiseHandButtonProps, RaiseHandButtonStrings } from './RaiseHandButton';\nexport { ReactionButton } from './ReactionButton';\nexport type { ReactionButtonProps, ReactionButtonStrings } from './ReactionButton';\nexport { VideoTile } from './VideoTile';\nexport type { VideoTileProps, VideoTileStylesProps, VideoTileStrings } from './VideoTile';\nexport { _PictureInPictureInPicture } from './PictureInPictureInPicture/PictureInPictureInPicture';\nexport type { _PictureInPictureInPictureProps, _PictureInPictureInPictureStrings } from './PictureInPictureInPicture/PictureInPictureInPicture';\nexport type { _PictureInPictureInPictureTileProps, _TileOrientation } from './PictureInPictureInPicture/PictureInPictureInPictureTile';\nexport * from './Drawer';\nexport * from './Attachment/AttachmentCard';\nexport * from './Attachment/AttachmentCardGroup';\nexport * from './ModalClone/ModalClone';\nexport * from './Attachment/AttachmentDownloadCards';\nexport type { _AttachmentUploadCardsStrings } from './Attachment/AttachmentUploadCards';\nexport { _useContainerHeight, _useContainerWidth } from './utils/responsive';\nexport { _ComplianceBanner } from './ComplianceBanner';\nexport type { _ComplianceBannerProps, _ComplianceBannerStrings } from './ComplianceBanner';\nexport { Dialpad } from './Dialpad/Dialpad';\nexport type { DialpadProps, DialpadStrings, DialpadStyles, DtmfTone } from './Dialpad/Dialpad';\nexport type { DialpadMode, LongPressTrigger } from './Dialpad/Dialpad';\nexport { _StarSurvey } from './Survey/StarSurvey/StarSurvey';\nexport type { _StarSurveyProps, _StarSurveyStrings } from './Survey/StarSurvey/StarSurvey';\nexport * from './Survey/SurveyTypes';\nexport { _TagsSurvey } from './Survey/TagsSurvey/TagsSurvey';\nexport type { _TagsSurveyProps, _TagsSurveyStrings, _IssueCategory, _SurveyTag } from './Survey/TagsSurvey/TagsSurvey';\nexport { _LocalVideoTile } from './LocalVideoTile';\nexport { _RemoteVideoTile } from './RemoteVideoTile';\nexport { _HighContrastAwareIcon } from './HighContrastAwareIcon';\nexport type { _HighContrastAwareIconProps } from './HighContrastAwareIcon';\nexport { UnsupportedBrowser } from './UnsupportedBrowser';\nexport type { UnsupportedBrowserStrings, UnsupportedBrowserProps } from './UnsupportedBrowser';\nexport { UnsupportedBrowserVersion } from './UnsupportedBrowserVersion';\nexport type { UnsupportedBrowserVersionStrings, UnsupportedBrowserVersionProps } from './UnsupportedBrowserVersion';\nexport { UnsupportedOperatingSystem } from './UnsupportedOperatingSystem';\nexport type { UnsupportedOperatingSystemStrings, UnsupportedOperatingSystemProps } from './UnsupportedOperatingSystem';\nexport { _TroubleshootingGuideErrorBar } from './TroubleshootingGuideErrorBar';\nexport type { _TroubleshootingGuideErrorBarStrings, _TroubleshootingGuideErrorBarProps } from './TroubleshootingGuideErrorBar';\nexport { _DevicePermissionDropdown } from './DevicePermissions/DevicePermissionDropdown';\nexport type { _DevicePermissionDropdownStrings, _DevicePermissionDropdownProps, _PermissionConstraints } from './DevicePermissions/DevicePermissionDropdown';\nexport { _VideoEffectsItem } from './VideoEffects/VideoEffectsItem';\nexport type { _VideoEffectsItemProps, _VideoEffectsItemStyles } from './VideoEffects/VideoEffectsItem';\nexport { _VideoEffectsItemNoBackground, _VideoEffectsItemBlur, _VideoEffectsItemAddImage } from './VideoEffects/PresetVideoEffectsItems';\nexport { _VideoBackgroundEffectsPicker } from './VideoEffects/VideoBackgroundEffectsPicker';\nexport type { _VideoBackgroundEffectsPickerProps, _VideoBackgroundEffectChoiceOption, _VideoBackgroundEffectsPickerStyles } from './VideoEffects/VideoBackgroundEffectsPicker';\nexport type { VerticalGalleryStyles, VerticalGalleryStrings, VerticalGalleryControlBarStyles } from './VerticalGallery';\nexport * from './CaptionsBanner';\nexport * from './Caption';\nexport * from './StartCaptionsButton';\nexport * from './CaptionsSettingsModal';\n\n/* @conditional-compile-remove(teams-meeting-conference) */\nexport * from './MeetingConferencePhoneInfo';\nexport { _ErrorBoundary } from './ErrorBoundary';\n/* @conditional-compile-remove(notifications) */\nexport * from './Notification';\n/* @conditional-compile-remove(notifications) */\nexport * from './NotificationStack';"]}
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../preprocess-dist/react-components/src/components/index.ts"],"names":[],"mappings":"AAAA,uCAAuC;AACvC,kCAAkC;AAElC,OAAO,EAAE,eAAe,EAAE,MAAM,mBAAmB,CAAC;AAEpD,OAAO,EAAE,QAAQ,EAAE,MAAM,YAAY,CAAC;AAEtC,OAAO,EAAE,UAAU,EAAE,MAAM,cAAc,CAAC;AAE1C,OAAO,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC;AACpC,OAAO,EAAE,YAAY,EAAE,MAAM,gBAAgB,CAAC;AAM9C,OAAO,EAAE,sBAAsB,EAAE,MAAM,0BAA0B,CAAC;AAElE,OAAO,EAAE,aAAa,EAAE,MAAM,iBAAiB,CAAC;AAEhD,OAAO,EAAE,WAAW,EAAE,MAAM,eAAe,CAAC;AAG5C,OAAO,EAAE,eAAe,EAAE,MAAM,mBAAmB,CAAC;AAEpD,OAAO,EAAE,eAAe,EAAE,MAAM,mBAAmB,CAAC;AAEpD,OAAO,EAAE,SAAS,EAAE,MAAM,aAAa,CAAC;AAExC,OAAO,EAAE,YAAY,EAAE,MAAM,gBAAgB,CAAC;AAK9C,OAAO,EAAE,2BAA2B,EAAE,MAAM,0BAA0B,CAAC;AAEvE,OAAO,EAAE,YAAY,EAAE,MAAM,gBAAgB,CAAC;AAE9C,OAAO,EAAE,UAAU,EAAE,MAAM,cAAc,CAAC;AAE1C,OAAO,EAAE,gBAAgB,EAAE,MAAM,oBAAoB,CAAC;AAEtD,OAAO,EAAE,aAAa,EAAE,MAAM,iBAAiB,CAAC;AAEhD,OAAO,EAAE,gBAAgB,EAAE,MAAM,oBAAoB,CAAC;AAEtD,OAAO,EAAE,aAAa,EAAE,8BAA8B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AE,iBAAiB,EAAE,MAAM,iCAAiC,CAAC;AAEpE,OAAO,EAAE,6BAA6B,EAAE,qBAAqB,EAAE,yBAAyB,EAAE,MAAM,wCAAwC,CAAC;AACzI,OAAO,EAAE,6BAA6B,EAAE,MAAM,6CAA6C,CAAC;AAG5F,cAAc,kBAAkB,CAAC;AACjC,cAAc,WAAW,CAAC;AAC1B,cAAc,uBAAuB,CAAC;AACtC,cAAc,yBAAyB,CAAC;AAExC,2DAA2D;AAC3D,cAAc,8BAA8B,CAAC;AAC7C,2DAA2D;AAC3D,OAAO,EAAE,kBAAkB,EAAE,MAAM,2BAA2B,CAAC;AAC/D,OAAO,EAAE,cAAc,EAAE,MAAM,iBAAiB,CAAC;AACjD,gDAAgD;AAChD,cAAc,gBAAgB,CAAC;AAC/B,gDAAgD;AAChD,cAAc,qBAAqB,CAAC","sourcesContent":["// Copyright (c) Microsoft Corporation.\n// Licensed under the MIT License.\n\nexport { TypingIndicator } from './TypingIndicator';\nexport type { TypingIndicatorProps, TypingIndicatorStrings, TypingIndicatorStylesProps } from './TypingIndicator';\nexport { ErrorBar } from './ErrorBar';\nexport type { ActiveErrorMessage, ErrorBarProps, ErrorBarStrings, ErrorType } from './ErrorBar';\nexport { GridLayout } from './GridLayout';\nexport type { GridLayoutProps, GridLayoutStyles } from './GridLayout';\nexport { SendBox } from './SendBox';\nexport { ImageOverlay } from './ImageOverlay';\nexport type { ImageOverlayStrings } from './ImageOverlay';\nexport type { SendBoxProps, SendBoxStrings, SendBoxStylesProps } from './SendBox'; // TODO: This component is exported only for testing purposes. Remove this when this component is added to composites\n// TODO: This component is exported only for testing purposes. Remove this when this component is added to composites\nexport type { ImageOverlayProps } from './ImageOverlay';\nexport type { InlineImageOptions, InlineImage } from './ChatMessage/ChatMessageContent';\nexport { MessageStatusIndicator } from './MessageStatusIndicator';\nexport type { MessageStatusIndicatorProps, MessageStatusIndicatorStrings } from './MessageStatusIndicator';\nexport { MessageThread } from './MessageThread';\nexport type { MessageProps, MessageThreadProps, MessageThreadStrings, MessageThreadStyles, JumpToNewMessageButtonProps, MessageRenderer, UpdateMessageCallback, CancelEditCallback } from './MessageThread';\nexport { StreamMedia } from './StreamMedia';\nexport type { StreamMediaProps } from './StreamMedia';\nexport type { LoadingState } from './StreamMedia';\nexport { ParticipantItem } from './ParticipantItem';\nexport type { ParticipantItemProps, ParticipantItemStrings, ParticipantItemStyles } from './ParticipantItem';\nexport { ParticipantList } from './ParticipantList';\nexport type { ParticipantListItemStyles, ParticipantListProps, ParticipantListStyles, ParticipantMenuItemsCallback } from './ParticipantList';\nexport { Announcer } from './Announcer';\nexport type { AnnouncerProps } from './Announcer';\nexport { VideoGallery } from './VideoGallery';\nexport type { VideoGalleryProps, VideoGalleryStrings, VideoGalleryStyles, VideoGalleryLayout, VideoTileContextualMenuProps, VideoTileDrawerMenuProps, VideoTilesOptions } from './VideoGallery';\nexport type { OverflowGalleryPosition } from './VideoGallery';\nexport type { LocalVideoTileSize } from './VideoGallery';\nexport type { HorizontalGalleryStyles } from './HorizontalGallery';\nexport { LocalVideoCameraCycleButton } from './LocalVideoCameraButton';\nexport type { LocalVideoCameraCycleButtonProps } from './LocalVideoCameraButton';\nexport { CameraButton } from './CameraButton';\nexport type { CameraButtonContextualMenuStyles, CameraButtonProps, CameraButtonStrings, CameraButtonStyles } from './CameraButton';\nexport { ControlBar } from './ControlBar';\nexport type { ControlBarProps, ControlBarLayout } from './ControlBar';\nexport { ControlBarButton } from './ControlBarButton';\nexport type { ControlBarButtonProps, ControlBarButtonStrings, ControlBarButtonStyles } from './ControlBarButton';\nexport { EndCallButton } from './EndCallButton';\nexport type { EndCallButtonProps, EndCallButtonStrings } from './EndCallButton';\nexport { MicrophoneButton } from './MicrophoneButton';\nexport type { MicrophoneButtonStyles, MicrophoneButtonContextualMenuStyles, MicrophoneButtonProps, MicrophoneButtonStrings } from './MicrophoneButton';\nexport { DevicesButton, generateDefaultDeviceMenuProps as _generateDefaultDeviceMenuProps } from './DevicesButton';\nexport type { OptionsDevice, DevicesButtonProps, DevicesButtonStrings, DevicesButtonStyles, DevicesButtonContextualMenuStyles, DeviceMenuProps as _DeviceMenuProps, DeviceMenuStrings as _DeviceMenuStrings, DeviceMenuStyles as _DeviceMenuStyles } from './DevicesButton';\nexport { ParticipantsButton } from './ParticipantsButton';\nexport type { ParticipantsButtonContextualMenuStyles, ParticipantsButtonProps, ParticipantsButtonStrings, ParticipantsButtonStyles } from './ParticipantsButton';\nexport { ScreenShareButton } from './ScreenShareButton';\nexport type { ScreenShareButtonProps, ScreenShareButtonStrings } from './ScreenShareButton';\nexport { RaiseHandButton } from './RaiseHandButton';\nexport type { RaiseHandButtonProps, RaiseHandButtonStrings } from './RaiseHandButton';\nexport { ReactionButton } from './ReactionButton';\nexport type { ReactionButtonProps, ReactionButtonStrings } from './ReactionButton';\nexport { VideoTile } from './VideoTile';\nexport type { VideoTileProps, VideoTileStylesProps, VideoTileStrings } from './VideoTile';\nexport { _PictureInPictureInPicture } from './PictureInPictureInPicture/PictureInPictureInPicture';\nexport type { _PictureInPictureInPictureProps, _PictureInPictureInPictureStrings } from './PictureInPictureInPicture/PictureInPictureInPicture';\nexport type { _PictureInPictureInPictureTileProps, _TileOrientation } from './PictureInPictureInPicture/PictureInPictureInPictureTile';\nexport * from './Drawer';\nexport * from './Attachment/AttachmentCard';\nexport * from './Attachment/AttachmentCardGroup';\nexport * from './ModalClone/ModalClone';\nexport * from './Attachment/AttachmentDownloadCards';\nexport type { _AttachmentUploadCardsStrings } from './Attachment/AttachmentUploadCards';\nexport { _useContainerHeight, _useContainerWidth } from './utils/responsive';\nexport { _ComplianceBanner } from './ComplianceBanner';\nexport type { _ComplianceBannerProps, _ComplianceBannerStrings } from './ComplianceBanner';\nexport { Dialpad } from './Dialpad/Dialpad';\nexport type { DialpadProps, DialpadStrings, DialpadStyles, DtmfTone } from './Dialpad/Dialpad';\nexport type { DialpadMode, LongPressTrigger } from './Dialpad/Dialpad';\nexport { _StarSurvey } from './Survey/StarSurvey/StarSurvey';\nexport type { _StarSurveyProps, _StarSurveyStrings } from './Survey/StarSurvey/StarSurvey';\nexport * from './Survey/SurveyTypes';\nexport { _TagsSurvey } from './Survey/TagsSurvey/TagsSurvey';\nexport type { _TagsSurveyProps, _TagsSurveyStrings, _IssueCategory, _SurveyTag } from './Survey/TagsSurvey/TagsSurvey';\nexport { _LocalVideoTile } from './LocalVideoTile';\nexport { _RemoteVideoTile } from './RemoteVideoTile';\nexport { _HighContrastAwareIcon } from './HighContrastAwareIcon';\nexport type { _HighContrastAwareIconProps } from './HighContrastAwareIcon';\nexport { UnsupportedBrowser } from './UnsupportedBrowser';\nexport type { UnsupportedBrowserStrings, UnsupportedBrowserProps } from './UnsupportedBrowser';\nexport { UnsupportedBrowserVersion } from './UnsupportedBrowserVersion';\nexport type { UnsupportedBrowserVersionStrings, UnsupportedBrowserVersionProps } from './UnsupportedBrowserVersion';\nexport { UnsupportedOperatingSystem } from './UnsupportedOperatingSystem';\nexport type { UnsupportedOperatingSystemStrings, UnsupportedOperatingSystemProps } from './UnsupportedOperatingSystem';\nexport { _TroubleshootingGuideErrorBar } from './TroubleshootingGuideErrorBar';\nexport type { _TroubleshootingGuideErrorBarStrings, _TroubleshootingGuideErrorBarProps } from './TroubleshootingGuideErrorBar';\nexport { _DevicePermissionDropdown } from './DevicePermissions/DevicePermissionDropdown';\nexport type { _DevicePermissionDropdownStrings, _DevicePermissionDropdownProps, _PermissionConstraints } from './DevicePermissions/DevicePermissionDropdown';\nexport { _VideoEffectsItem } from './VideoEffects/VideoEffectsItem';\nexport type { _VideoEffectsItemProps, _VideoEffectsItemStyles } from './VideoEffects/VideoEffectsItem';\nexport { _VideoEffectsItemNoBackground, _VideoEffectsItemBlur, _VideoEffectsItemAddImage } from './VideoEffects/PresetVideoEffectsItems';\nexport { _VideoBackgroundEffectsPicker } from './VideoEffects/VideoBackgroundEffectsPicker';\nexport type { _VideoBackgroundEffectsPickerProps, _VideoBackgroundEffectChoiceOption, _VideoBackgroundEffectsPickerStyles } from './VideoEffects/VideoBackgroundEffectsPicker';\nexport type { VerticalGalleryStyles, VerticalGalleryStrings, VerticalGalleryControlBarStyles } from './VerticalGallery';\nexport * from './CaptionsBanner';\nexport * from './Caption';\nexport * from './StartCaptionsButton';\nexport * from './CaptionsSettingsModal';\n\n/* @conditional-compile-remove(teams-meeting-conference) */\nexport * from './MeetingConferencePhoneInfo';\n/* @conditional-compile-remove(teams-meeting-conference) */\nexport { _formatPhoneNumber } from './utils/formatPhoneNumber';\nexport { _ErrorBoundary } from './ErrorBoundary';\n/* @conditional-compile-remove(notifications) */\nexport * from './Notification';\n/* @conditional-compile-remove(notifications) */\nexport * from './NotificationStack';"]}
|
@@ -1,13 +1,17 @@
|
|
1
1
|
// Copyright (c) Microsoft Corporation.
|
2
2
|
// Licensed under the MIT License.
|
3
3
|
/**
|
4
|
-
* @
|
4
|
+
* @internal
|
5
5
|
*/
|
6
|
-
export const
|
6
|
+
export const _formatPhoneNumber = (phoneNumber, enchant) => {
|
7
7
|
// if input value is falsy eg if the user deletes the input, then just return
|
8
8
|
if (!phoneNumber) {
|
9
9
|
return phoneNumber;
|
10
10
|
}
|
11
|
+
// Only enchant North American phone numbers that begin with country code (1)
|
12
|
+
if (enchant && phoneNumber[0] === '1' && phoneNumber.length === 11) {
|
13
|
+
phoneNumber = `+${phoneNumber}`;
|
14
|
+
}
|
11
15
|
// if phone number starts with 1, format like 1 (xxx)xxx-xxxx.
|
12
16
|
// if phone number starts with +, we format like +x (xxx)xxx-xxxx.
|
13
17
|
// For now we are only supporting NA phone number formatting with country code +x
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"formatPhoneNumber.js","sourceRoot":"","sources":["../../../../../../preprocess-dist/react-components/src/components/utils/formatPhoneNumber.ts"],"names":[],"mappings":"AAAA,uCAAuC;AACvC,kCAAkC;AAElC;;GAEG;AACH,MAAM,CAAC,MAAM,
|
1
|
+
{"version":3,"file":"formatPhoneNumber.js","sourceRoot":"","sources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AAW,CAAC;IACtD,CAAC;IAED,2EAA2E;IAC3E,uBAAuB;IACvB,IAAI,iBAAiB,GAAG,CAAC,EAAE,CAAC;QAC1B,OAAO,GAAG,aAAa,IAAI,WAAW,CAAC,KAAK,CAAC,CAAC,EAAE,CAAC,CAAC,KAAK,WAAW,CAAC,KAAK,CAAC,CAAC,CAAC,EAAE,CAAC;IAChF,CAAC;IAED,2EAA2E;IAC3E,mCAAmC;IACnC,OAAO,GAAG,aAAa,IAAI,WAAW,CAAC,KAAK,CAAC,CAAC,EAAE,CAAC,CAAC,KAAK,WAAW,CAAC,KAAK,CAAC,CAAC,EAAE,CAAC,CAAC,IAAI,WAAW,CAAC,KAAK,CAAC,CAAC,EAAE,WAAW,CAAC,MAAM,CAAC,EAAE,CAAC;AAC/H,CAAC,CAAC","sourcesContent":["// Copyright (c) Microsoft Corporation.\n// Licensed under the MIT License.\n\n/**\n * @internal\n */\nexport const _formatPhoneNumber = (phoneNumber: string, enchant?: boolean): string => {\n // if input value is falsy eg if the user deletes the input, then just return\n if (!phoneNumber) {\n return phoneNumber;\n }\n\n // Only enchant North American phone numbers that begin with country code (1)\n if (enchant && phoneNumber[0] === '1' && phoneNumber.length === 11) {\n phoneNumber = `+${phoneNumber}`;\n }\n\n // if phone number starts with 1, format like 1 (xxx)xxx-xxxx.\n // if phone number starts with +, we format like +x (xxx)xxx-xxxx.\n // For now we are only supporting NA phone number formatting with country code +x\n // first we chop off the countrycode then we add it on when returning\n let countryCodeNA = '';\n if (phoneNumber[0] === '1') {\n countryCodeNA = '1 ';\n phoneNumber = phoneNumber.slice(1, phoneNumber.length);\n } else if (phoneNumber[0] === '+') {\n countryCodeNA = phoneNumber.slice(0, 2) + ' ';\n phoneNumber = phoneNumber.slice(2, phoneNumber.length);\n }\n\n // phoneNumberLength is used to know when to apply our formatting for the phone number\n const phoneNumberLength = phoneNumber.length;\n\n // we need to return the value with no formatting if its less then four digits\n // this is to avoid weird behavior that occurs if you format the area code too early\n // if phoneNumberLength is greater than 10 we don't do any formatting\n\n if (phoneNumberLength < 4 || phoneNumberLength > 10) {\n // no formatting in this case, remove ' ' behind countrycode\n return countryCodeNA.replace(' ', '') + phoneNumber;\n }\n\n // if phoneNumberLength is greater than 4 and less the 7 we start to return\n // the formatted number\n if (phoneNumberLength < 7) {\n return `${countryCodeNA}(${phoneNumber.slice(0, 3)}) ${phoneNumber.slice(3)}`;\n }\n\n // finally, if the phoneNumberLength is greater then seven, we add the last\n // bit of formatting and return it.\n return `${countryCodeNA}(${phoneNumber.slice(0, 3)}) ${phoneNumber.slice(3, 6)}-${phoneNumber.slice(6, phoneNumber.length)}`;\n};"]}
|
@@ -18,7 +18,7 @@ import { useSelector } from '../hooks/useSelector';
|
|
18
18
|
/* @conditional-compile-remove(teams-meeting-conference) */
|
19
19
|
import { phoneInfoTextStyle, phoneInfoIcon, phoneInfoInstructionLine, phoneInfoStep, phoneInfoIconStyle, phoneInfoLabelStyle, titleClassName, titleContainerClassName, infoConnectionLinkStyle } from '../../common/styles/TeamsMeetingConferenceInfo.style';
|
20
20
|
/* @conditional-compile-remove(teams-meeting-conference) */
|
21
|
-
import { formatPhoneNumberInfo,
|
21
|
+
import { formatPhoneNumberInfo, _formatPhoneNumber, formatPhoneNumberLink } from "../../../../../react-components/src";
|
22
22
|
/* @conditional-compile-remove(teams-meeting-conference) */
|
23
23
|
import { _pxToRem } from "../../../../../acs-ui-common/src";
|
24
24
|
/* @conditional-compile-remove(teams-meeting-conference) */
|
@@ -60,8 +60,8 @@ export const NetworkReconnectTile = (props) => {
|
|
60
60
|
React.createElement(Text, { className: phoneInfoLabelStyle }, localeStrings.meetingConferencePhoneInfoModalDialIn)))),
|
61
61
|
React.createElement(Stack.Item, { className: phoneInfoStep }, meetingCoordinates.map((phoneNumber, index) => React.createElement(Stack.Item, { key: index },
|
62
62
|
React.createElement(Text, { className: phoneInfoTextStyle },
|
63
|
-
props.isMobile && React.createElement(Link, { className: phoneInfoTextStyle, href: formatPhoneNumberLink(phoneNumber) },
|
64
|
-
!props.isMobile && React.createElement(Text, { className: phoneInfoTextStyle },
|
63
|
+
props.isMobile && React.createElement(Link, { className: phoneInfoTextStyle, href: formatPhoneNumberLink(phoneNumber) }, _formatPhoneNumber(phoneNumber.phoneNumber, true)),
|
64
|
+
!props.isMobile && React.createElement(Text, { className: phoneInfoTextStyle }, _formatPhoneNumber(phoneNumber.phoneNumber, true)),
|
65
65
|
' ',
|
66
66
|
phoneNumber.isTollFree ? localeStrings.meetingConferencePhoneInfoModalTollFree : localeStrings.meetingConferencePhoneInfoModalToll),
|
67
67
|
React.createElement("br", null),
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"NetworkReconnectTile.js","sourceRoot":"","sources":["../../../../../../../preprocess-dist/react-composites/src/composites/CallComposite/components/NetworkReconnectTile.tsx"],"names":[],"mappings":"AAAA,uCAAuC;AACvC,kCAAkC;AAElC,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,EAAsB,QAAQ,EAAE,4CAAmC;AAC1E,OAAO,EAAE,sBAAsB,EAAE,MAAM,0BAA0B,CAAC;AAClE,OAAO,EAAE,WAAW,EAAE,KAAK,EAAE,IAAI,EAAE,MAAM,iBAAiB,CAAC;AAC3D,2DAA2D;AAC3D,iDAAiD;AACjD,OAAO,EAAE,IAAI,EAAE,MAAM,iBAAiB,CAAC;AACvC,OAAO,EAAE,SAAS,EAAE,MAAM,oBAAoB,CAAC;AAC/C,OAAO,EAAE,cAAc,EAAE,gBAAgB,EAAE,mBAAmB,EAAE,UAAU,EAAE,MAAM,uCAAuC,CAAC;AAC1H,OAAO,EAAE,WAAW,EAAE,MAAM,sBAAsB,CAAC;AACnD,OAAO,EAAE,iBAAiB,EAAE,MAAM,oBAAoB,CAAC;AACvD,2DAA2D;AAC3D,OAAO,EAAE,0BAA0B,EAAE,iBAAiB,EAAE,MAAM,4BAA4B,CAAC;AAC3F,2DAA2D;AAC3D,OAAO,EAAE,WAAW,EAAE,MAAM,sBAAsB,C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IAAI,oBAAC,KAAK,IAAC,SAAS,EAAE,uBAAuB,CAAC,KAAK,CAAC,GAAU;4BAC9E,oBAAC,KAAK,CAAC,IAAI,IAAC,SAAS,EAAE,aAAa,CAAC,KAAK,CAAC;gCACzC,oBAAC,IAAI,IAAC,QAAQ,EAAC,6BAA6B,EAAC,SAAS,EAAE,kBAAkB,CAAC,KAAK,CAAC,GAAI,CAC1E;4BACb,oBAAC,KAAK,CAAC,IAAI;gCACT,oBAAC,IAAI,IAAC,SAAS,EAAE,mBAAmB,IACjC,aAAa,CAAC,wCAAwC,CAClD,CACI,CACP,CACG;oBACb,oBAAC,IAAI,IAAC,SAAS,EAAE,kBAAkB;wBAAG,kBAAkB,CAAC,CAAC,CAAC,CAAC,YAAY;4BAAS,CAC3E;gBACP,CAAC,KAAK,CAAC,QAAQ,IAAI,oBAAC,KAAK,IAAC,UAAU,QAAC,eAAe,EAAC,eAAe,EAAC,aAAa,EAAC,QAAQ,EAAC,SAAS,EAAE,wBAAwB;oBAC5H,oBAAC,KAAK,IAAC,UAAU;wBACf,oBAAC,KAAK,CAAC,IAAI,IAAC,SAAS,EAAE,aAAa,CAAC,KAAK,CAAC,EAAE,KAAK,EAAE;gCAChE,UAAU,EAAE,QAAQ,CAAC,CAAC,CAAC;6BACxB;4BACe,oBAAC,IAAI,IAAC,QAAQ,EAAC,iCAAiC,EAAC,SAAS,EAAE,kBAAkB,CAAC,KAAK,CAAC,GAAI,CAC9E;wBACb,oBAAC,KAAK,CAAC,IAAI;4BACT,oBAAC,IAAI,IAAC,SAAS,EAAE,mBAAmB,IACjC,aAAa,CAAC,mCAAmC,CAC7C,CACI,CACP,CACF,CACJ,CACR,IAAM,QAAQ,EAAI,CAAC;AACnC,CAAC,CAAC","sourcesContent":["// Copyright (c) Microsoft Corporation.\n// Licensed under the MIT License.\n\nimport React from 'react';\nimport { VideoGalleryStream, useTheme } from '@internal/react-components';\nimport { ExpandedLocalVideoTile } from './ExpandedLocalVideoTile';\nimport { mergeStyles, Stack, Text } from '@fluentui/react';\n/* @conditional-compile-remove(teams-meeting-conference) */\n// eslint-disable-next-line no-restricted-imports\nimport { Icon } from '@fluentui/react';\nimport { useLocale } from '../../localization';\nimport { containerStyle, moreDetailsStyle, titleContainerStyle, titleStyle } from '../styles/NetworkReconnectTile.styles';\nimport { useHandlers } from '../hooks/useHandlers';\nimport { CallCompositeIcon } from '../../common/icons';\n/* @conditional-compile-remove(teams-meeting-conference) */\nimport { getTeamsMeetingCoordinates, getIsTeamsMeeting } from '../selectors/baseSelectors';\n/* @conditional-compile-remove(teams-meeting-conference) */\nimport { useSelector } from '../hooks/useSelector';\n/* @conditional-compile-remove(teams-meeting-conference) */\nimport { phoneInfoTextStyle, phoneInfoIcon, phoneInfoInstructionLine, phoneInfoStep, phoneInfoIconStyle, phoneInfoLabelStyle, titleClassName, titleContainerClassName, infoConnectionLinkStyle } from '../../common/styles/TeamsMeetingConferenceInfo.style';\n/* @conditional-compile-remove(teams-meeting-conference) */\nimport { formatPhoneNumberInfo, formatPhoneNumber, formatPhoneNumberLink } from '@internal/react-components';\n/* @conditional-compile-remove(teams-meeting-conference) */\nimport { _pxToRem } from '@internal/acs-ui-common';\n/* @conditional-compile-remove(teams-meeting-conference) */\nimport { Link } from '@fluentui/react';\n\n/**\n * @private\n */\nexport interface NetworkReconnectTileProps {\n localParticipantVideoStream: VideoGalleryStream;\n /* @conditional-compile-remove(teams-meeting-conference) */\n isMobile?: boolean;\n}\n\n/**\n * @private\n */\nexport const NetworkReconnectTile = (props: NetworkReconnectTileProps): JSX.Element => {\n const videoStream = props.localParticipantVideoStream;\n const isVideoReady = videoStream?.isAvailable ?? false;\n const palette = useTheme().palette;\n const strings = useLocale().strings.call;\n /* @conditional-compile-remove(teams-meeting-conference) */\n const localeStrings = useLocale().component.strings.meetingConferencePhoneInfo;\n /* @conditional-compile-remove(teams-meeting-conference) */\n const theme = useTheme();\n const handlers = useHandlers(ExpandedLocalVideoTile);\n\n /* @conditional-compile-remove(teams-meeting-conference) */\n const isTeamsMeeting = useSelector(getIsTeamsMeeting);\n /* @conditional-compile-remove(teams-meeting-conference) */\n const meetingCoordinates = useSelector(getTeamsMeetingCoordinates);\n return <ExpandedLocalVideoTile localParticipantVideoStream={props.localParticipantVideoStream} overlayContent={<Stack verticalFill horizontalAlign=\"center\" verticalAlign=\"center\" className={mergeStyles(containerStyle)} aria-atomic>\n <Stack horizontal className={mergeStyles(titleContainerStyle)}>\n <CallCompositeIcon iconName=\"NetworkReconnectIcon\" className={mergeStyles(titleStyle(palette, isVideoReady))} />\n <Text className={mergeStyles(titleStyle(palette, isVideoReady))} aria-live={'assertive'}>\n {strings.networkReconnectTitle}\n </Text>\n </Stack>\n <Text className={mergeStyles(moreDetailsStyle(palette, isVideoReady))} aria-live={'assertive'}>\n {strings.networkReconnectMoreDetails}\n </Text>\n {/* @conditional-compile-remove(teams-meeting-conference) */isTeamsMeeting && meetingCoordinates && meetingCoordinates.length > 0 && <Stack>\n <Stack horizontal horizontalAlign=\"center\" verticalAlign=\"center\" className={titleContainerClassName}>\n <Text className={titleClassName}>{localeStrings.meetingConferencePhoneInfoModalTitle}</Text>\n </Stack>\n <Stack horizontal horizontalAlign=\"space-between\" className={phoneInfoInstructionLine}>\n <Stack className={infoConnectionLinkStyle(theme)}></Stack>\n <Stack.Item>\n <Stack horizontal className={phoneInfoStep}>\n <Stack.Item className={phoneInfoIcon(theme)}>\n <Stack verticalAlign=\"center\" horizontalAlign=\"center\">\n <Icon iconName=\"JoinByPhoneDialStepIcon\" className={phoneInfoIconStyle(theme)} />\n </Stack>\n </Stack.Item>\n <Stack.Item>\n <Text className={phoneInfoLabelStyle}>\n {localeStrings.meetingConferencePhoneInfoModalDialIn}\n </Text>\n </Stack.Item>\n </Stack>\n </Stack.Item>\n <Stack.Item className={phoneInfoStep}>\n {meetingCoordinates.map((phoneNumber, index) => <Stack.Item key={index}>\n <Text className={phoneInfoTextStyle}>\n {props.isMobile && <Link className={phoneInfoTextStyle} href={formatPhoneNumberLink(phoneNumber)}>\n {formatPhoneNumber(phoneNumber.phoneNumber)}\n </Link>}\n {!props.isMobile && <Text className={phoneInfoTextStyle}>{formatPhoneNumber(phoneNumber.phoneNumber)}</Text>}{' '}\n {phoneNumber.isTollFree ? localeStrings.meetingConferencePhoneInfoModalTollFree : localeStrings.meetingConferencePhoneInfoModalToll}\n </Text>\n <br />\n <Text className={phoneInfoTextStyle}>\n {' '}\n {formatPhoneNumberInfo(phoneNumber, localeStrings)}\n </Text>\n </Stack.Item>)}\n </Stack.Item>\n </Stack>\n <Stack horizontal horizontalAlign=\"space-between\" verticalAlign=\"center\" className={phoneInfoInstructionLine}>\n <Stack.Item>\n <Stack horizontal>\n {!props.isMobile && <Stack className={infoConnectionLinkStyle(theme)}></Stack>}\n <Stack.Item className={phoneInfoIcon(theme)}>\n <Icon iconName=\"JoinByPhoneConferenceIdIcon\" className={phoneInfoIconStyle(theme)} />\n </Stack.Item>\n <Stack.Item>\n <Text className={phoneInfoLabelStyle}>\n {localeStrings.meetingConferencePhoneInfoModalMeetingId}\n </Text>\n </Stack.Item>\n </Stack>\n </Stack.Item>\n <Text className={phoneInfoTextStyle}>{meetingCoordinates[0].conferenceId}#</Text>\n </Stack>\n {!props.isMobile && <Stack horizontal horizontalAlign=\"space-between\" verticalAlign=\"center\" className={phoneInfoInstructionLine}>\n <Stack horizontal>\n <Stack.Item className={phoneInfoIcon(theme)} style={{\n marginLeft: _pxToRem(2)\n }}>\n <Icon iconName=\"JoinByPhoneWaitToBeAdmittedIcon\" className={phoneInfoIconStyle(theme)} />\n </Stack.Item>\n <Stack.Item>\n <Text className={phoneInfoLabelStyle}>\n {localeStrings.meetingConferencePhoneInfoModalWait}\n </Text>\n </Stack.Item>\n </Stack>\n </Stack>}\n </Stack>}\n </Stack>} {...handlers} />;\n};"]}
|
1
|
+
{"version":3,"file":"NetworkReconnectTile.js","sourceRoot":"","sources":["../../../../../../../preprocess-dist/react-composites/src/composites/CallComposite/components/NetworkReconnectT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AC3E;gBACP,CAAC,KAAK,CAAC,QAAQ,IAAI,oBAAC,KAAK,IAAC,UAAU,QAAC,eAAe,EAAC,eAAe,EAAC,aAAa,EAAC,QAAQ,EAAC,SAAS,EAAE,wBAAwB;oBAC5H,oBAAC,KAAK,IAAC,UAAU;wBACf,oBAAC,KAAK,CAAC,IAAI,IAAC,SAAS,EAAE,aAAa,CAAC,KAAK,CAAC,EAAE,KAAK,EAAE;gCAChE,UAAU,EAAE,QAAQ,CAAC,CAAC,CAAC;6BACxB;4BACe,oBAAC,IAAI,IAAC,QAAQ,EAAC,iCAAiC,EAAC,SAAS,EAAE,kBAAkB,CAAC,KAAK,CAAC,GAAI,CAC9E;wBACb,oBAAC,KAAK,CAAC,IAAI;4BACT,oBAAC,IAAI,IAAC,SAAS,EAAE,mBAAmB,IACjC,aAAa,CAAC,mCAAmC,CAC7C,CACI,CACP,CACF,CACJ,CACR,IAAM,QAAQ,EAAI,CAAC;AACnC,CAAC,CAAC","sourcesContent":["// Copyright (c) Microsoft Corporation.\n// Licensed under the MIT License.\n\nimport React from 'react';\nimport { VideoGalleryStream, useTheme } from '@internal/react-components';\nimport { ExpandedLocalVideoTile } from './ExpandedLocalVideoTile';\nimport { mergeStyles, Stack, Text } from '@fluentui/react';\n/* @conditional-compile-remove(teams-meeting-conference) */\n// eslint-disable-next-line no-restricted-imports\nimport { Icon } from '@fluentui/react';\nimport { useLocale } from '../../localization';\nimport { containerStyle, moreDetailsStyle, titleContainerStyle, titleStyle } from '../styles/NetworkReconnectTile.styles';\nimport { useHandlers } from '../hooks/useHandlers';\nimport { CallCompositeIcon } from '../../common/icons';\n/* @conditional-compile-remove(teams-meeting-conference) */\nimport { getTeamsMeetingCoordinates, getIsTeamsMeeting } from '../selectors/baseSelectors';\n/* @conditional-compile-remove(teams-meeting-conference) */\nimport { useSelector } from '../hooks/useSelector';\n/* @conditional-compile-remove(teams-meeting-conference) */\nimport { phoneInfoTextStyle, phoneInfoIcon, phoneInfoInstructionLine, phoneInfoStep, phoneInfoIconStyle, phoneInfoLabelStyle, titleClassName, titleContainerClassName, infoConnectionLinkStyle } from '../../common/styles/TeamsMeetingConferenceInfo.style';\n/* @conditional-compile-remove(teams-meeting-conference) */\nimport { formatPhoneNumberInfo, _formatPhoneNumber, formatPhoneNumberLink } from '@internal/react-components';\n/* @conditional-compile-remove(teams-meeting-conference) */\nimport { _pxToRem } from '@internal/acs-ui-common';\n/* @conditional-compile-remove(teams-meeting-conference) */\nimport { Link } from '@fluentui/react';\n\n/**\n * @private\n */\nexport interface NetworkReconnectTileProps {\n localParticipantVideoStream: VideoGalleryStream;\n /* @conditional-compile-remove(teams-meeting-conference) */\n isMobile?: boolean;\n}\n\n/**\n * @private\n */\nexport const NetworkReconnectTile = (props: NetworkReconnectTileProps): JSX.Element => {\n const videoStream = props.localParticipantVideoStream;\n const isVideoReady = videoStream?.isAvailable ?? false;\n const palette = useTheme().palette;\n const strings = useLocale().strings.call;\n /* @conditional-compile-remove(teams-meeting-conference) */\n const localeStrings = useLocale().component.strings.meetingConferencePhoneInfo;\n /* @conditional-compile-remove(teams-meeting-conference) */\n const theme = useTheme();\n const handlers = useHandlers(ExpandedLocalVideoTile);\n\n /* @conditional-compile-remove(teams-meeting-conference) */\n const isTeamsMeeting = useSelector(getIsTeamsMeeting);\n /* @conditional-compile-remove(teams-meeting-conference) */\n const meetingCoordinates = useSelector(getTeamsMeetingCoordinates);\n return <ExpandedLocalVideoTile localParticipantVideoStream={props.localParticipantVideoStream} overlayContent={<Stack verticalFill horizontalAlign=\"center\" verticalAlign=\"center\" className={mergeStyles(containerStyle)} aria-atomic>\n <Stack horizontal className={mergeStyles(titleContainerStyle)}>\n <CallCompositeIcon iconName=\"NetworkReconnectIcon\" className={mergeStyles(titleStyle(palette, isVideoReady))} />\n <Text className={mergeStyles(titleStyle(palette, isVideoReady))} aria-live={'assertive'}>\n {strings.networkReconnectTitle}\n </Text>\n </Stack>\n <Text className={mergeStyles(moreDetailsStyle(palette, isVideoReady))} aria-live={'assertive'}>\n {strings.networkReconnectMoreDetails}\n </Text>\n {/* @conditional-compile-remove(teams-meeting-conference) */isTeamsMeeting && meetingCoordinates && meetingCoordinates.length > 0 && <Stack>\n <Stack horizontal horizontalAlign=\"center\" verticalAlign=\"center\" className={titleContainerClassName}>\n <Text className={titleClassName}>{localeStrings.meetingConferencePhoneInfoModalTitle}</Text>\n </Stack>\n <Stack horizontal horizontalAlign=\"space-between\" className={phoneInfoInstructionLine}>\n <Stack className={infoConnectionLinkStyle(theme)}></Stack>\n <Stack.Item>\n <Stack horizontal className={phoneInfoStep}>\n <Stack.Item className={phoneInfoIcon(theme)}>\n <Stack verticalAlign=\"center\" horizontalAlign=\"center\">\n <Icon iconName=\"JoinByPhoneDialStepIcon\" className={phoneInfoIconStyle(theme)} />\n </Stack>\n </Stack.Item>\n <Stack.Item>\n <Text className={phoneInfoLabelStyle}>\n {localeStrings.meetingConferencePhoneInfoModalDialIn}\n </Text>\n </Stack.Item>\n </Stack>\n </Stack.Item>\n <Stack.Item className={phoneInfoStep}>\n {meetingCoordinates.map((phoneNumber, index) => <Stack.Item key={index}>\n <Text className={phoneInfoTextStyle}>\n {props.isMobile && <Link className={phoneInfoTextStyle} href={formatPhoneNumberLink(phoneNumber)}>\n {_formatPhoneNumber(phoneNumber.phoneNumber, true)}\n </Link>}\n {!props.isMobile && <Text className={phoneInfoTextStyle}>\n {_formatPhoneNumber(phoneNumber.phoneNumber, true)}\n </Text>}{' '}\n {phoneNumber.isTollFree ? localeStrings.meetingConferencePhoneInfoModalTollFree : localeStrings.meetingConferencePhoneInfoModalToll}\n </Text>\n <br />\n <Text className={phoneInfoTextStyle}>\n {' '}\n {formatPhoneNumberInfo(phoneNumber, localeStrings)}\n </Text>\n </Stack.Item>)}\n </Stack.Item>\n </Stack>\n <Stack horizontal horizontalAlign=\"space-between\" verticalAlign=\"center\" className={phoneInfoInstructionLine}>\n <Stack.Item>\n <Stack horizontal>\n {!props.isMobile && <Stack className={infoConnectionLinkStyle(theme)}></Stack>}\n <Stack.Item className={phoneInfoIcon(theme)}>\n <Icon iconName=\"JoinByPhoneConferenceIdIcon\" className={phoneInfoIconStyle(theme)} />\n </Stack.Item>\n <Stack.Item>\n <Text className={phoneInfoLabelStyle}>\n {localeStrings.meetingConferencePhoneInfoModalMeetingId}\n </Text>\n </Stack.Item>\n </Stack>\n </Stack.Item>\n <Text className={phoneInfoTextStyle}>{meetingCoordinates[0].conferenceId}#</Text>\n </Stack>\n {!props.isMobile && <Stack horizontal horizontalAlign=\"space-between\" verticalAlign=\"center\" className={phoneInfoInstructionLine}>\n <Stack horizontal>\n <Stack.Item className={phoneInfoIcon(theme)} style={{\n marginLeft: _pxToRem(2)\n }}>\n <Icon iconName=\"JoinByPhoneWaitToBeAdmittedIcon\" className={phoneInfoIconStyle(theme)} />\n </Stack.Item>\n <Stack.Item>\n <Text className={phoneInfoLabelStyle}>\n {localeStrings.meetingConferencePhoneInfoModalWait}\n </Text>\n </Stack.Item>\n </Stack>\n </Stack>}\n </Stack>}\n </Stack>} {...handlers} />;\n};"]}
|
@@ -6,7 +6,7 @@ import { Stack, Text, useTheme, Icon, Link } from '@fluentui/react';
|
|
6
6
|
/* @conditional-compile-remove(teams-meeting-conference) */
|
7
7
|
import React from 'react';
|
8
8
|
/* @conditional-compile-remove(teams-meeting-conference) */
|
9
|
-
import { formatPhoneNumberInfo,
|
9
|
+
import { formatPhoneNumberInfo, _formatPhoneNumber, formatPhoneNumberLink } from "../../../../react-components/src";
|
10
10
|
/* @conditional-compile-remove(teams-meeting-conference) */
|
11
11
|
import { phoneInfoTextStyle, phoneInfoIcon, phoneInfoInstructionLine, phoneInfoStep, phoneInfoIconStyle, phoneInfoLabelStyle, phoneInfoContainerTokens, phoneInfoContainerStyle } from './styles/TeamsMeetingConferenceInfo.style';
|
12
12
|
/* @conditional-compile-remove(teams-meeting-conference) */
|
@@ -33,7 +33,7 @@ export const MeetingPhoneInfoPaneContent = (props) => {
|
|
33
33
|
React.createElement(Stack.Item, null,
|
34
34
|
React.createElement(Text, { className: phoneInfoLabelStyle }, localeStrings.meetingConferencePhoneInfoModalDialIn)))),
|
35
35
|
React.createElement(Stack.Item, { className: phoneInfoStep }, conferencePhoneInfoList.map((phoneNumber, index) => React.createElement(Stack.Item, { key: index },
|
36
|
-
React.createElement(Link, { className: phoneInfoTextStyle, href: formatPhoneNumberLink(phoneNumber) },
|
36
|
+
React.createElement(Link, { className: phoneInfoTextStyle, href: formatPhoneNumberLink(phoneNumber) }, _formatPhoneNumber(phoneNumber.phoneNumber, true)),
|
37
37
|
React.createElement(Text, { className: phoneInfoTextStyle },
|
38
38
|
' ',
|
39
39
|
phoneNumber.isTollFree ? localeStrings.meetingConferencePhoneInfoModalTollFree : localeStrings.meetingConferencePhoneInfoModalToll),
|
package/dist/dist-esm/react-composites/src/composites/common/MeetingPhoneInfoPaneContent.js.map
CHANGED
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"MeetingPhoneInfoPaneContent.js","sourceRoot":"","sources":["../../../../../../preprocess-dist/react-composites/src/composites/common/MeetingPhoneInfoPaneContent.tsx"],"names":[],"mappings":"AAAA,uCAAuC;AACvC,kCAAkC;AAElC,2DAA2D;AAC3D,iDAAiD;AACjD,OAAO,EAAE,KAAK,EAAE,IAAI,EAAE,QAAQ,EAAE,IAAI,EAAE,IAAI,EAAE,MAAM,iBAAiB,CAAC;AAGpE,2DAA2D;AAC3D,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,2DAA2D;AAC3D,OAAO,EAAuB,qBAAqB,EAAE,
|
1
|
+
{"version":3,"file":"MeetingPhoneInfoPaneContent.js","sourceRoot":"","sources":["../../../../../../preprocess-dist/react-composites/src/composites/common/MeetingPhoneInfoPaneContent.tsx"],"names":[],"mappings":"AAAA,uCAAuC;AACvC,kCAAkC;AAElC,2DAA2D;AAC3D,iDAAiD;AACjD,OAAO,EAAE,KAAK,EAAE,IAAI,EAAE,QAAQ,EAAE,IAAI,EAAE,IAAI,EAA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,IAAI,IAAC,SAAS,EAAE,aAAa,CAAC,KAAK,CAAC;gCACzC,oBAAC,IAAI,IAAC,QAAQ,EAAC,6BAA6B,EAAC,SAAS,EAAE,kBAAkB,CAAC,KAAK,CAAC,GAAI,CAC1E;4BACb,oBAAC,KAAK,CAAC,IAAI;gCACT,oBAAC,IAAI,IAAC,SAAS,EAAE,mBAAmB,IACjC,aAAa,CAAC,wCAAwC,CAClD,CACI,CACP,CACG;oBACb,oBAAC,IAAI,IAAC,SAAS,EAAE,kBAAkB;wBAAG,uBAAuB,CAAC,CAAC,CAAC,CAAC,YAAY;4BAAS,CAChF;gBACR,oBAAC,KAAK,IAAC,UAAU,QAAC,eAAe,EAAC,eAAe,EAAC,aAAa,EAAC,QAAQ,EAAC,SAAS,EAAE,wBAAwB;oBAC1G,oBAAC,KAAK,IAAC,UAAU;wBACf,oBAAC,KAAK,CAAC,IAAI,IAAC,SAAS,EAAE,aAAa,CAAC,KAAK,CAAC;4BACzC,oBAAC,IAAI,IAAC,QAAQ,EAAC,iCAAiC,EAAC,SAAS,EAAE,kBAAkB,CAAC,KAAK,CAAC,GAAI,CAC9E;wBACb,oBAAC,KAAK,CAAC,IAAI;4BACT,oBAAC,IAAI,IAAC,SAAS,EAAE,mBAAmB,IAAG,aAAa,CAAC,mCAAmC,CAAQ,CACrF,CACP,CACF,CACF,CACJ,CAAC;IACb,CAAC;IACD,OAAO,oBAAC,KAAK,IAAC,YAAY,QAAC,MAAM,EAAE,uBAAuB,EAAE,MAAM,EAAE,wBAAwB,gBAAa,yBAAyB,GAAS,CAAC;AAC9I,CAAC,CAAC","sourcesContent":["// Copyright (c) Microsoft Corporation.\n// Licensed under the MIT License.\n\n/* @conditional-compile-remove(teams-meeting-conference) */\n// eslint-disable-next-line no-restricted-imports\nimport { Stack, Text, useTheme, Icon, Link } from '@fluentui/react';\n/* @conditional-compile-remove(teams-meeting-conference) */\nimport { _DrawerMenuItemProps } from '@internal/react-components';\n/* @conditional-compile-remove(teams-meeting-conference) */\nimport React from 'react';\n/* @conditional-compile-remove(teams-meeting-conference) */\nimport { ConferencePhoneInfo, formatPhoneNumberInfo, _formatPhoneNumber, formatPhoneNumberLink } from '@internal/react-components';\n/* @conditional-compile-remove(teams-meeting-conference) */\nimport { phoneInfoTextStyle, phoneInfoIcon, phoneInfoInstructionLine, phoneInfoStep, phoneInfoIconStyle, phoneInfoLabelStyle, phoneInfoContainerTokens, phoneInfoContainerStyle } from './styles/TeamsMeetingConferenceInfo.style';\n/* @conditional-compile-remove(teams-meeting-conference) */\nimport { useLocale } from '../localization';\n\n/* @conditional-compile-remove(teams-meeting-conference) */\n/**\n * @private\n */\nexport const MeetingPhoneInfoPaneContent = (props: {\n mobileView?: boolean;\n conferencePhoneInfoList?: ConferencePhoneInfo[];\n}): JSX.Element => {\n const {\n conferencePhoneInfoList\n } = props;\n const theme = useTheme();\n const localeStrings = useLocale().component.strings.meetingConferencePhoneInfo;\n if (props.mobileView) {\n return <Stack verticalFill styles={phoneInfoContainerStyle} tokens={phoneInfoContainerTokens} data-ui-id=\"phone-info-pane-content\">\n {(conferencePhoneInfoList === undefined || conferencePhoneInfoList.length === 0) && <Stack horizontal>\n <Text className={phoneInfoTextStyle}>{localeStrings.meetingConferencePhoneInfoModalNoPhoneAvailable}</Text>\n </Stack>}\n {conferencePhoneInfoList && conferencePhoneInfoList.length > 0 && <Stack>\n <Stack horizontal horizontalAlign=\"space-between\" className={phoneInfoInstructionLine}>\n <Stack.Item>\n <Stack horizontal className={phoneInfoStep}>\n <Stack.Item className={phoneInfoIcon(theme)}>\n <Stack verticalAlign=\"center\" horizontalAlign=\"center\">\n <Icon iconName=\"JoinByPhoneDialStepIcon\" className={phoneInfoIconStyle(theme)} />\n </Stack>\n </Stack.Item>\n <Stack.Item>\n <Text className={phoneInfoLabelStyle}>{localeStrings.meetingConferencePhoneInfoModalDialIn}</Text>\n </Stack.Item>\n </Stack>\n </Stack.Item>\n <Stack.Item className={phoneInfoStep}>\n {conferencePhoneInfoList.map((phoneNumber, index) => <Stack.Item key={index}>\n <Link className={phoneInfoTextStyle} href={formatPhoneNumberLink(phoneNumber)}>\n {_formatPhoneNumber(phoneNumber.phoneNumber, true)}\n </Link>\n <Text className={phoneInfoTextStyle}>\n {' '}\n {phoneNumber.isTollFree ? localeStrings.meetingConferencePhoneInfoModalTollFree : localeStrings.meetingConferencePhoneInfoModalToll}\n </Text>\n <br />\n <Text className={phoneInfoTextStyle}> {formatPhoneNumberInfo(phoneNumber, localeStrings)}</Text>\n </Stack.Item>)}\n </Stack.Item>\n </Stack>\n <Stack horizontal horizontalAlign=\"space-between\" verticalAlign=\"center\" className={phoneInfoInstructionLine}>\n <Stack.Item>\n <Stack horizontal>\n <Stack.Item className={phoneInfoIcon(theme)}>\n <Icon iconName=\"JoinByPhoneConferenceIdIcon\" className={phoneInfoIconStyle(theme)} />\n </Stack.Item>\n <Stack.Item>\n <Text className={phoneInfoLabelStyle}>\n {localeStrings.meetingConferencePhoneInfoModalMeetingId}\n </Text>\n </Stack.Item>\n </Stack>\n </Stack.Item>\n <Text className={phoneInfoTextStyle}>{conferencePhoneInfoList[0].conferenceId}#</Text>\n </Stack>\n <Stack horizontal horizontalAlign=\"space-between\" verticalAlign=\"center\" className={phoneInfoInstructionLine}>\n <Stack horizontal>\n <Stack.Item className={phoneInfoIcon(theme)}>\n <Icon iconName=\"JoinByPhoneWaitToBeAdmittedIcon\" className={phoneInfoIconStyle(theme)} />\n </Stack.Item>\n <Stack.Item>\n <Text className={phoneInfoLabelStyle}>{localeStrings.meetingConferencePhoneInfoModalWait}</Text>\n </Stack.Item>\n </Stack>\n </Stack>\n </Stack>}\n </Stack>;\n }\n return <Stack verticalFill styles={phoneInfoContainerStyle} tokens={phoneInfoContainerTokens} data-ui-id=\"phone-info-pane-content\"></Stack>;\n};"]}
|
package/package.json
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
{
|
2
2
|
"name": "@azure/communication-react",
|
3
|
-
"version": "1.18.
|
3
|
+
"version": "1.18.1",
|
4
4
|
"sideEffects": false,
|
5
5
|
"description": "React library for building modern communication user experiences utilizing Azure Communication Services",
|
6
6
|
"keywords": [
|
@@ -39,7 +39,6 @@
|
|
39
39
|
"events": "^3.3.0",
|
40
40
|
"html-react-parser": "^5.1.10",
|
41
41
|
"immer": "10.1.1",
|
42
|
-
"libphonenumber-js": "^1.11.4",
|
43
42
|
"memoize-one": "^5.2.1",
|
44
43
|
"nanoid": "3.3.6",
|
45
44
|
"react-linkify": "^1.0.0-alpha",
|