botframework-webchat-fluent-theme 4.17.0-main.20240416.4ff01ae → 4.17.0-main.20240416.e3f5401
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/botframework-webchat-fluent-theme.development.js +2065 -357
- package/dist/botframework-webchat-fluent-theme.development.js.map +1 -1
- package/dist/botframework-webchat-fluent-theme.production.min.js +3 -1
- package/dist/botframework-webchat-fluent-theme.production.min.js.map +1 -1
- package/dist/index.js +632 -333
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +516 -217
- package/dist/index.mjs.map +1 -1
- package/package.json +5 -4
- package/src/components/Theme.tsx +65 -4
- package/src/components/dropZone/index.tsx +31 -6
- package/src/components/sendbox/AddAttachmentButton.tsx +17 -5
- package/src/components/sendbox/Attachments.tsx +12 -3
- package/src/components/sendbox/ErrorMessage.tsx +13 -2
- package/src/components/sendbox/TelephoneKeypadToolbarButton.tsx +1 -1
- package/src/components/sendbox/TextArea.tsx +70 -9
- package/src/components/sendbox/Toolbar.tsx +55 -4
- package/src/components/sendbox/index.tsx +69 -9
- package/src/components/suggestedActions/SuggestedAction.tsx +43 -3
- package/src/components/suggestedActions/index.tsx +29 -6
- package/src/components/telephoneKeypad/private/Button.tsx +67 -5
- package/src/components/telephoneKeypad/private/TelephoneKeypad.tsx +35 -4
- package/src/index.ts +0 -3
- package/src/private/useStyleToEmotionObject.ts +32 -0
- package/src/styles/index.ts +15 -0
- package/src/tsconfig.json +1 -2
- package/dist/botframework-webchat-fluent-theme.development.css.map +0 -1
- package/dist/botframework-webchat-fluent-theme.production.min.css.map +0 -1
- package/dist/index.css.map +0 -1
- package/src/components/Theme.module.css +0 -60
- package/src/components/dropZone/index.module.css +0 -23
- package/src/components/sendbox/AddAttachmentButton.module.css +0 -10
- package/src/components/sendbox/Attachments.module.css +0 -7
- package/src/components/sendbox/ErrorMessage.module.css +0 -9
- package/src/components/sendbox/TextArea.module.css +0 -61
- package/src/components/sendbox/Toolbar.module.css +0 -49
- package/src/components/sendbox/index.module.css +0 -58
- package/src/components/suggestedActions/SuggestedAction.module.css +0 -34
- package/src/components/suggestedActions/index.module.css +0 -23
- package/src/components/telephoneKeypad/private/Button.module.css +0 -62
- package/src/components/telephoneKeypad/private/TelephoneKeypad.module.css +0 -30
- package/src/env.d.ts +0 -7
- package/src/styles/injectStyle.ts +0 -9
- package/src/styles/useStyles.ts +0 -19
- package/src/styles.ts +0 -4
|
@@ -1,58 +0,0 @@
|
|
|
1
|
-
:global(.webchat-fluent) .sendbox {
|
|
2
|
-
color: var(--webchat-colorNeutralForeground1);
|
|
3
|
-
font-family: var(--webchat-fontFamilyBase);
|
|
4
|
-
padding: 0 10px 10px;
|
|
5
|
-
text-rendering: optimizeLegibility;
|
|
6
|
-
}
|
|
7
|
-
|
|
8
|
-
:global(.webchat-fluent) .sendbox__sendbox {
|
|
9
|
-
background-color: var(--webchat-colorNeutralBackground1);
|
|
10
|
-
border-radius: var(--webchat-borderRadiusLarge);
|
|
11
|
-
border: 1px solid var(--webchat-colorNeutralStroke1);
|
|
12
|
-
display: grid;
|
|
13
|
-
font-family: var(--webchat-fontFamilyBase);
|
|
14
|
-
font-size: 14px;
|
|
15
|
-
gap: 6px;
|
|
16
|
-
line-height: 20px;
|
|
17
|
-
padding: 8px;
|
|
18
|
-
position: relative;
|
|
19
|
-
|
|
20
|
-
&:focus-within {
|
|
21
|
-
border-color: var(--webchat-colorNeutralStroke1Selected);
|
|
22
|
-
/* TODO clarify with design the color:
|
|
23
|
-
- Teams is using colorCompoundBrandForeground1
|
|
24
|
-
- Fluent is using colorCompoundBrandStroke
|
|
25
|
-
- we are using colorCompoundBrandForeground1Hover */
|
|
26
|
-
box-shadow: inset 0 -6px 0 -3px var(--webchat-colorCompoundBrandForeground1Hover);
|
|
27
|
-
}
|
|
28
|
-
}
|
|
29
|
-
|
|
30
|
-
:global(.webchat-fluent) .sendbox__sendbox-text {
|
|
31
|
-
background-color: transparent;
|
|
32
|
-
border: none;
|
|
33
|
-
flex: auto;
|
|
34
|
-
font-family: var(--webchat-fontFamilyBase);
|
|
35
|
-
font-size: 14px;
|
|
36
|
-
line-height: 20px;
|
|
37
|
-
outline: none;
|
|
38
|
-
padding: 4px 4px 0;
|
|
39
|
-
resize: none;
|
|
40
|
-
}
|
|
41
|
-
|
|
42
|
-
:global(.webchat-fluent) .sendbox__sendbox-controls {
|
|
43
|
-
align-items: center;
|
|
44
|
-
display: flex;
|
|
45
|
-
padding-inline-start: 4px;
|
|
46
|
-
}
|
|
47
|
-
|
|
48
|
-
:global(.webchat-fluent) .sendbox__text-counter {
|
|
49
|
-
color: var(--webchat-colorNeutralForeground4);
|
|
50
|
-
cursor: default;
|
|
51
|
-
font-family: var(--webchat-fontFamilyNumeric);
|
|
52
|
-
font-size: 10px;
|
|
53
|
-
line-height: 14px;
|
|
54
|
-
}
|
|
55
|
-
|
|
56
|
-
:global(.webchat-fluent) .sendbox__text-counter--error {
|
|
57
|
-
color: var(--webchat-colorStatusDangerForeground1);
|
|
58
|
-
}
|
|
@@ -1,34 +0,0 @@
|
|
|
1
|
-
:global(.webchat-fluent) .suggested-action {
|
|
2
|
-
align-items: center;
|
|
3
|
-
background: transparent;
|
|
4
|
-
border-radius: 8px;
|
|
5
|
-
border: 1px solid var(--webchat-colorBrandStroke2);
|
|
6
|
-
cursor: pointer;
|
|
7
|
-
display: flex;
|
|
8
|
-
font-size: 12px;
|
|
9
|
-
gap: 4px;
|
|
10
|
-
padding: 4px 8px 4px;
|
|
11
|
-
text-align: start;
|
|
12
|
-
transition: all .15s ease-out;
|
|
13
|
-
|
|
14
|
-
@media (hover: hover) {
|
|
15
|
-
&:not([aria-disabled="true"]):hover {
|
|
16
|
-
background-color: var(--webchat-colorBrandBackground2Hover);
|
|
17
|
-
color: var(--webchat-colorBrandForeground2Hover)
|
|
18
|
-
}
|
|
19
|
-
}
|
|
20
|
-
&:not([aria-disabled="true"]):active {
|
|
21
|
-
background-color: var(--webchat-colorBrandBackground2Pressed);
|
|
22
|
-
color: var(--webchat-colorBrandForeground2Pressed)
|
|
23
|
-
}
|
|
24
|
-
&[aria-disabled="true"] {
|
|
25
|
-
color: var(--webchat-colorNeutralForegroundDisabled);
|
|
26
|
-
cursor: not-allowed
|
|
27
|
-
}
|
|
28
|
-
}
|
|
29
|
-
|
|
30
|
-
:global(.webchat-fluent) .suggested-action__image {
|
|
31
|
-
font-size: 12px;
|
|
32
|
-
height: 1em;
|
|
33
|
-
width: 1em;
|
|
34
|
-
}
|
|
@@ -1,23 +0,0 @@
|
|
|
1
|
-
|
|
2
|
-
:global(.webchat-fluent) .suggested-actions {
|
|
3
|
-
align-items: flex-end;
|
|
4
|
-
align-self: flex-end;
|
|
5
|
-
display: flex;
|
|
6
|
-
flex-direction: column;
|
|
7
|
-
gap: 8px;
|
|
8
|
-
|
|
9
|
-
&:not(:empty) {
|
|
10
|
-
padding-block-end: 8px;
|
|
11
|
-
padding-inline-start: 4px
|
|
12
|
-
}
|
|
13
|
-
|
|
14
|
-
&.suggested-actions--flow {
|
|
15
|
-
flex-direction: row;
|
|
16
|
-
flex-wrap: wrap;
|
|
17
|
-
justify-content: flex-end;
|
|
18
|
-
}
|
|
19
|
-
|
|
20
|
-
&.suggested-actions--stacked {
|
|
21
|
-
flex-direction: column
|
|
22
|
-
}
|
|
23
|
-
}
|
|
@@ -1,62 +0,0 @@
|
|
|
1
|
-
|
|
2
|
-
:global(.webchat-fluent) .telephone-keypad__button {
|
|
3
|
-
-webkit-user-select: none;
|
|
4
|
-
align-items: center;
|
|
5
|
-
appearance: none;
|
|
6
|
-
/* backgroundColor: isDarkTheme() || isHighContrastTheme() ? black : white, */
|
|
7
|
-
background-color: White;
|
|
8
|
-
border-radius: 100%;
|
|
9
|
-
|
|
10
|
-
/* Whitelabel styles */
|
|
11
|
-
/* border: `solid 1px ${isHighContrastTheme() ? white : isDarkTheme() ? gray160 : gray40}`, */
|
|
12
|
-
/* color: inherit; */
|
|
13
|
-
|
|
14
|
-
border: solid 1px var(--webchat-colorNeutralStroke1);
|
|
15
|
-
color: var(--webchat-colorGray200);
|
|
16
|
-
font-weight: var(--webchat-fontWeightSemibold);
|
|
17
|
-
|
|
18
|
-
cursor: pointer;
|
|
19
|
-
display: flex;
|
|
20
|
-
flex-direction: column;
|
|
21
|
-
height: 60px;
|
|
22
|
-
opacity: 0.7;
|
|
23
|
-
padding: 0;
|
|
24
|
-
position: relative;
|
|
25
|
-
touch-action: none;
|
|
26
|
-
user-select: none;
|
|
27
|
-
width: 60px;
|
|
28
|
-
|
|
29
|
-
&:hover {
|
|
30
|
-
/* backgroundColor: isHighContrastTheme() ? gray210 : isDarkTheme() ? gray150 : gray30 */
|
|
31
|
-
background-color: var(--webchat-colorGray30)
|
|
32
|
-
}
|
|
33
|
-
}
|
|
34
|
-
|
|
35
|
-
:global(.webchat-fluent) .telephone-keypad__button__ruby {
|
|
36
|
-
/* color: isHighContrastTheme() ? white : isDarkTheme() ? gray40 : gray160, */
|
|
37
|
-
color: var(--webchat-colorGray190);
|
|
38
|
-
font-size: 10px;
|
|
39
|
-
}
|
|
40
|
-
|
|
41
|
-
:global(.webchat-fluent) .telephone-keypad__button__text {
|
|
42
|
-
font-size: 24px;
|
|
43
|
-
margin-top: 8px;
|
|
44
|
-
}
|
|
45
|
-
|
|
46
|
-
:global(.webchat-fluent) .telephone-keypad--horizontal {
|
|
47
|
-
& .telephone-keypad__button {
|
|
48
|
-
height: 32px;
|
|
49
|
-
justify-content: center;
|
|
50
|
-
margin: 8px 4px;
|
|
51
|
-
width: 32px;
|
|
52
|
-
};
|
|
53
|
-
|
|
54
|
-
.telephone-keypad__button__ruby {
|
|
55
|
-
display: none;
|
|
56
|
-
}
|
|
57
|
-
|
|
58
|
-
& .telephone-keypad__button__text {
|
|
59
|
-
font-size: 20px;
|
|
60
|
-
margin-top: 0;
|
|
61
|
-
}
|
|
62
|
-
}
|
|
@@ -1,30 +0,0 @@
|
|
|
1
|
-
|
|
2
|
-
:global(.webchat-fluent) .telephone-keypad {
|
|
3
|
-
/* Commented out whitelabel styles for now. */
|
|
4
|
-
/* background: getHighContrastDarkThemeColor(highContrastColor: black, darkThemeColor: gray190, string, defaultColor: gray10), */
|
|
5
|
-
/* borderRadius: '8px 8px 0px 0px; */
|
|
6
|
-
/* boxShadow: '-3px 0px 7px 0px rgba(0, 0, 0, 0.13), -0.6px 0px 1.8px 0px rgba(0, 0, 0, 0.10)', */
|
|
7
|
-
|
|
8
|
-
align-items: center;
|
|
9
|
-
background: var(--webchat-colorNeutralBackground1);
|
|
10
|
-
/* border: isHighContrastTheme() ? `1px solid ${white}` : none; */
|
|
11
|
-
border: none;
|
|
12
|
-
border-radius: var(--webchat-borderRadiusXLarge);
|
|
13
|
-
/* boxShadow: var(--shadow16); */
|
|
14
|
-
display: flex;
|
|
15
|
-
flex-direction: column;
|
|
16
|
-
font-family: var(--webchat-fontFamilyBase);
|
|
17
|
-
justify-content: center;
|
|
18
|
-
/* margin: var(--spacingHorizontalMNudge)' */
|
|
19
|
-
}
|
|
20
|
-
|
|
21
|
-
:global(.webchat-fluent) .telephone-keypad__box {
|
|
22
|
-
box-sizing: border-box;
|
|
23
|
-
display: grid;
|
|
24
|
-
gap: 16px;
|
|
25
|
-
grid-template-columns: repeat(3, 1fr);
|
|
26
|
-
grid-template-rows: repeat(4, 1fr);
|
|
27
|
-
justify-items: center;
|
|
28
|
-
padding: 16px;
|
|
29
|
-
width: 100%;
|
|
30
|
-
}
|
package/src/env.d.ts
DELETED
|
@@ -1,9 +0,0 @@
|
|
|
1
|
-
export const injectedStyles = '@--INJECTED-STYLES-CONTENT--@';
|
|
2
|
-
|
|
3
|
-
export default function injectStyles() {
|
|
4
|
-
if (globalThis.document) {
|
|
5
|
-
const style = document.createElement('style');
|
|
6
|
-
style.append(document.createTextNode(injectedStyles));
|
|
7
|
-
document.head.appendChild(style);
|
|
8
|
-
}
|
|
9
|
-
}
|
package/src/styles/useStyles.ts
DELETED
|
@@ -1,19 +0,0 @@
|
|
|
1
|
-
import { useMemo } from 'react';
|
|
2
|
-
|
|
3
|
-
function useStyles<T extends CSSModuleClasses>(styles: T): T {
|
|
4
|
-
// @ts-expect-error: entries/fromEntries don't allow to specify keys type
|
|
5
|
-
return useMemo(
|
|
6
|
-
() =>
|
|
7
|
-
Object.freeze(
|
|
8
|
-
Object.fromEntries(
|
|
9
|
-
Object.entries(styles).map(([baseClassName, resultClassName]) => [
|
|
10
|
-
baseClassName,
|
|
11
|
-
`${baseClassName} ${resultClassName}`
|
|
12
|
-
])
|
|
13
|
-
)
|
|
14
|
-
),
|
|
15
|
-
[styles]
|
|
16
|
-
);
|
|
17
|
-
}
|
|
18
|
-
|
|
19
|
-
export default useStyles;
|
package/src/styles.ts
DELETED