Error when using Chinese in tokens

4 posts, 2 answers
  1. Benson
    Benson avatar
    3 posts
    Member since:
    Aug 2017

    Posted 30 Aug Link to this post

    Hi, 

    I am using trial version of UI pro, and this error appears only in IOS, while work well in Android.

    it has no problem when i add Chinese text in a token, the pop up list showing suggested labels also works correctly.

    But When a token is selected, it shows mis-decoded text in the TextView,

    onTokenAdded also is triggered, however args.token is null when the text is Chinese.

    Any suggestion how to solve this?

    Thanks

    Ben

    The code snippets are:

    ******* js ********

        var titles = [
                "How I Met Your Mother S01E01",
                "How I Met Your Mother S01E02",
                "老爸老媽浪漫史 S01E01",
                "老爸老媽浪漫史 S01E02",
            ];

        for (var i = 0; i < titles.length; i++) {
            var token = new autocompleteModule.TokenModel(titles[i]);
            token.id = titles[i];
            items.push(token);
        };

     

    exports.onTokenAdded = function(args){
        alert(JSON.stringify(args.token));
    }

        pageData.set("items", items);

        ****** xml *******

           <au:RadAutoCompleteTextView 
            items="{{ items }}" 
            completionMode="Contains"  
            layoutMode="Wrap" 
            displayMode="Tokens" 
            suggestMode="Suggest"
            tokenAdded="onTokenAdded" 
            tokenRemoved="onTokenRemoved"
            >

     

     

  2. Answer
    Nikolay Iliev
    Admin
    Nikolay Iliev avatar
    295 posts

    Posted 30 Aug Link to this post

    Hello Benson,

    Thank you for your interest in NativeScript and for reporting this issue.

    After testing with the provided snippets containing Chinese symbols I can confirm that indeed the issue is fully reproducible on iOS. We logged the issue as a bug here and our develo0pment team will investigate the cause of this behavior. Please keep track on the logged issue for possible solutions and also any stable fix that will be rele4ased will be linked to the issue as well.

    Sorry for any inconvenience this issue might have caused and once again thank you for reporting this one back to us.

    Regards,
    Nikolay Iliev
    Progress Telerik
    Did you know that you can open private support tickets which are reviewed and answered within 24h by the same team who built the components? This is available in our UI for NativeScript Pro + Support offering.
  3. Benson
    Benson avatar
    3 posts
    Member since:
    Aug 2017

    Posted 30 Aug in reply to Nikolay Iliev Link to this post

    Thanks for help.

    btw, Japanese also wont work. I guess all multi-byte characters wont work.

    Ben

  4. Answer
    Nikolay Iliev
    Admin
    Nikolay Iliev avatar
    295 posts

    Posted 30 Aug Link to this post

    Hi Benson,

    Thank you for the additional info - I have updated the issue accordingly.
    Please stay tuned and track the issue for a possible workaround and for fix updates.

    Regards,
    Nikolay Iliev
    Progress Telerik
    Did you know that you can open private support tickets which are reviewed and answered within 24h by the same team who built the components? This is available in our UI for NativeScript Pro + Support offering.
Back to Top