Skip to content

Fix #798 hide upload button#883

Merged
compulim merged 1 commit intomicrosoft:masterfrom
compulim:feat-hide-upload
Mar 7, 2018
Merged

Fix #798 hide upload button#883
compulim merged 1 commit intomicrosoft:masterfrom
compulim:feat-hide-upload

Conversation

@compulim
Copy link
Copy Markdown
Contributor

@compulim compulim commented Mar 7, 2018

New prop showUploadButton to hide upload button. It is default to true.

@compulim compulim requested review from billba and eanders-ms March 7, 2018 20:02
@compulim compulim changed the title Hide upload button #798 Fix #798 hide upload button Mar 7, 2018
@compulim compulim merged commit 036624d into microsoft:master Mar 7, 2018
@compulim compulim deleted the feat-hide-upload branch March 7, 2018 20:15
@compulim compulim added this to the 0.12.0 milestone Mar 9, 2018
@ernestoguimaraes
Copy link
Copy Markdown

Is there anyway to enable upload button using the backhannel feature that, when a specific event was triggered, i show it to the user?

@compulim
Copy link
Copy Markdown
Contributor Author

compulim commented May 3, 2018

@ernestoguimaraes Yes it's possible.

I assume you are embedding Web Chat using React. If you set the props.showUploadButton to false, the upload button will hide right away. The switch is on-the-fly and does not re-render the control.

So you will listen to backchannel, when you get the signal, you set it in your React code, done. 😃

@nmssalman
Copy link
Copy Markdown

nmssalman commented Aug 9, 2018

still im not clear with that..how can i remove the image upload button from the chat window?

@jvanderbiest
Copy link
Copy Markdown

jvanderbiest commented Apr 23, 2019

@nmssalman

still im not clear with that..how can i remove the image upload button from the chat window?

window.WebChat.renderWebChat({
    ...
    styleOptions: { hideUploadButton: false }
}, document.getElementById('bot'));

@lumayara
Copy link
Copy Markdown

lumayara commented May 13, 2019

@jvanderbiest

still im not clear with that..how can i remove the image upload button from the chat window?

window.WebChat.renderWebChat({
    ...
    styleOptions: { hideUploadButton: false }
}, document.getElementById('bot'));

This did not work for me :/

@junczhu
Copy link
Copy Markdown

junczhu commented Mar 12, 2021

@ernestoguimaraes Yes it's possible.

I assume you are embedding Web Chat using React. If you set the props.showUploadButton to false, the upload button will hide right away. The switch is on-the-fly and does not re-render the control.

So you will listen to backchannel, when you get the signal, you set it in your React code, done. 😃

@compulim Hello William,

Is there a way to do the configuration for a iframe like the following?

<iframe src='https://webchat.botframework.com/embed/directline-csharp?s=YOUR_SECRET_HERE' style='min-width: 400px; width: 100%; min-height: 500px;'></iframe>

@corinagum
Copy link
Copy Markdown
Contributor

@CharingJC iframe Web Chat does not have a way to modify style options. Only default iframe props can be assigned (width, etc).

@junczhu
Copy link
Copy Markdown

junczhu commented Mar 13, 2021 via email

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

8 participants