DEV: Set composer upload btn selectors in component (#14324)
This commit is contained in:
parent
cb0b39d16e
commit
cb1210da35
|
@ -90,6 +90,8 @@ export function cleanUpComposerUploadMarkdownResolver() {
|
|||
export default Component.extend(ComposerUpload, {
|
||||
classNameBindings: ["showToolbar:toolbar-visible", ":wmd-controls"],
|
||||
|
||||
fileUploadElementId: "file-uploader",
|
||||
mobileFileUploaderId: "mobile-file-upload",
|
||||
shouldBuildScrollMap: true,
|
||||
scrollMap: null,
|
||||
processPreview: true,
|
||||
|
|
|
@ -331,9 +331,11 @@ export default Mixin.create({
|
|||
|
||||
_bindMobileUploadButton() {
|
||||
if (this.site.mobileView) {
|
||||
this.mobileUploadButton = document.getElementById("mobile-file-upload");
|
||||
this.mobileUploadButtonEventListener = function mobileButtonEventListener() {
|
||||
document.getElementById("file-uploader").click();
|
||||
this.mobileUploadButton = document.getElementById(
|
||||
this.mobileFileUploaderId
|
||||
);
|
||||
this.mobileUploadButtonEventListener = () => {
|
||||
document.getElementById(this.fileUploadElementId).click();
|
||||
};
|
||||
this.mobileUploadButton.addEventListener(
|
||||
"click",
|
||||
|
|
Loading…
Reference in New Issue