Skip to content

Commit 4d76902

Browse files
committed
feat: remove unused constants
1 parent 737f849 commit 4d76902

File tree

4 files changed

+4
-16
lines changed

4 files changed

+4
-16
lines changed

packages/botonic-react/src/constants.js

-12
Original file line numberDiff line numberDiff line change
@@ -33,25 +33,13 @@ export const COLORS = {
3333

3434
export const WEBCHAT = {
3535
DEFAULTS: {
36-
WIDTH: 300,
37-
HEIGHT: 450,
38-
TITLE: 'Botonic',
3936
LOGO: BotonicLogo,
4037
URL_ICON: UrlIcon,
41-
PLACEHOLDER: 'Ask me something...',
42-
FONT_FAMILY: "'Noto Sans JP', sans-serif",
43-
BORDER_RADIUS_TOP_CORNERS: '6px 6px 0px 0px',
4438
ELEMENT_WIDTH: 222,
4539
ELEMENT_MARGIN_RIGHT: 6,
4640
STORAGE_KEY: 'botonicState',
4741
HOST_ID: 'root',
4842
ID: 'botonic-webchat',
49-
BUTTON_AUTO_DISABLE: false,
50-
BUTTON_DISABLED_STYLE: {
51-
opacity: 0.5,
52-
cursor: 'auto',
53-
pointerEvents: 'none',
54-
},
5543
},
5644
CUSTOM_PROPERTIES: {
5745
// General

packages/botonic-react/src/webchat-app.tsx

+1-1
Original file line numberDiff line numberDiff line change
@@ -71,7 +71,7 @@ export class WebchatApp {
7171
enableAttachments,
7272
enableUserInput,
7373
enableAnimations,
74-
hostId = 'root',
74+
hostId = WEBCHAT.DEFAULTS.HOST_ID,
7575
shadowDOM = false,
7676
defaultDelay,
7777
defaultTyping,

packages/botonic-react/src/webchat/styles.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,7 @@ export const ErrorMessage = styled.div`
4949
border-radius: 5px;
5050
align-items: center;
5151
justify-content: center;
52-
font-family: ${WEBCHAT.DEFAULTS.FONT_FAMILY};
52+
font-family: ${props => props.theme.style.fontFamily};
5353
`
5454

5555
export const DarkBackgroundMenu = styled.div`

packages/botonic-react/src/webchat/theme/default-theme.ts

+2-2
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ export const defaultTheme: WebchatTheme = {
66
width: '300px',
77
height: '450px',
88
borderRadius: '10px',
9-
fontFamily: WEBCHAT.DEFAULTS.FONT_FAMILY,
9+
fontFamily: "'Noto Sans JP', sans-serif",
1010
fontSize: '16px',
1111
position: 'fixed',
1212
right: '20px',
@@ -25,7 +25,7 @@ export const defaultTheme: WebchatTheme = {
2525
bottom: '0px',
2626
},
2727
header: {
28-
title: WEBCHAT.DEFAULTS.TITLE,
28+
title: 'Botonic',
2929
subtitle: '',
3030
image: WEBCHAT.DEFAULTS.LOGO,
3131
style: {

0 commit comments

Comments
 (0)