0

I am trying to customize Microsoft web chat with React project:

  • npm install botframework-webchat@master

In the previous version I have customized web UI by forking the master, but at this time I don't want to lose updates in master, here is the reference I have followed Microsoft Bot Webchat.

I am trying to edit user/bot icons with respective images and I don't need upload button shown below

enter image description here

tried to create middleware, and a custom component which extends actual component but no luck, I am not sure it is possible with the latest master. Please guide me how we can do.

p u
  • 1,395
  • 1
  • 17
  • 30
Venuu Munnuruu
  • 285
  • 1
  • 6
  • 17

1 Answers1

1

Finally got with styling:

import { createStyleSet } from 'botframework-webchat;

const styleSet = createStyleSet({});

styleSet.uploadButton = { ...styleSet.uploadButton,
  display: 'none'
};

styleSet.avatar = {...styleSet.avatar,
  backgroundImage: `url(${imageUrl})`
};

while returning send properties to the component as

botAvatarInitials= ' '
userAvatarInitials= ' '
styleSet={styleSet}`
Venuu Munnuruu
  • 285
  • 1
  • 6
  • 17