22
Views
7
Comments
[ReactFilePondUpload] Bug in Javascript
reactfilepondupload
Reactive icon
Forge component by Stuart Harris
Application Type
Reactive

Hi, 


in the javascript you have a bug:

if (options.StylePanelLayout) {            

var splOption = options.StylePanelLayout.toLowerCase();            

if (splOption === 'compact' || splOptions === 'integrated' || splOptions === 'circle') {                createOptions.stylePanelLayout = splOption;            

}

    }


as you can see you are checking splOption for compact and splOptions for other values. That's why when i use integrated/circle - i get an error, that splOtptions is not defined. Could you repair that in your official version?

Thanks in advance!


BR

Alexey

Thanks Alexey! Yes, I sure can. Are you saying there is another option that is 'integrated/circle'?

I don't know that :) i can't use this one, as the check is not working, because of the additional s in the variable name. I can change it locally, but it would be better to have that in th e official version.

BR

Alexey

Ok I'll have a look and get back to you.

Kind regards,

Stuart

Thanks Alexey, It looks like FilePond also supports "integrated circle" and "compact circle". I am uploading a new version that will include those options.

I appreciate you helping to make this component better!

Kind regards,

Stuart

Hi Stuart,

You should also remove the 's' in some lines. It is 'splOption', not 'splOptions'.

Now we get the error 'splOptions is not defined' when using 'integrated' or 'circle' options

        if (options.StylePanelLayout) {

            var splOption = options.StylePanelLayout.toLowerCase();

            if (splOption === 'compact' ||

                splOptions === 'integrated' ||

                splOptions === 'circle' ||

                splOption === 'integrated circle' ||

                splOption === 'compact circle') {

                createOptions.stylePanelLayout = splOption;

            } 

        }


Best regards,

Rogier

Hi Rogier,

Thanks very much! It looks like I fixed it but didn't upload the fixed version.

I will upload a fixed version shortly.

Kind regards,

Stuart

Hi again Rogier,

I have uploaded a new version (1.3.4) with the fix for this issue.

Many thanks and kind regards,

Stuart

Community GuidelinesBe kind and respectful, give credit to the original source of content, and search for duplicates before posting.