woodybury / rn-emoji-picker

React ⚛️ Native ☎️ Emoji 😊 Picker ⛏️ | super light weight, dark/light mode, 0 dependencies, 6.45 kB
MIT License
19 stars 5 forks source link

Draft: Default section prop and a couple of tweak / fixes. #3

Closed Julioevm closed 2 years ago

Julioevm commented 2 years ago

I PR adds:

Julioevm commented 2 years ago

@woodybury I'm not able to test out these changes, the example app is not connecting to my device, let me know if you can give it a try, thanks!

woodybury commented 2 years ago

@Julioevm nice! Thanks for this. Looks good albeit one issue:

enabledCategories = categories.values()['key'] yields empty obj? I think .values() returns an iterator? If you use a map instead that seems to work, e.g. categories.map(c => c.key). Either way can you move the calc out of the default props, maybe export a const categoryKeys from the constants file?

Other than that it's testing well. Nice catch w/ the width!

Can you update example on the readme and example app?

                onChangeRecent={setRecent} // callback to update recent storage - arr of emoji objs
                // backgroundColor={'#000'} // optional custom bg color
                // enabledCategories={['emotion', 'emojis', 'activities', 'flags', 'food', 'places', 'nature']}
                // defaultCategory={'food'} // optional custom default category

`

Julioevm commented 2 years ago

Thanks for the feedback! I'll take a look at your suggestions tomorrow

On Mon, 10 Oct 2022, 19:30 woodbury shortridge, @.***> wrote:

@Julioevm https://github.com/Julioevm nice! Thanks for this. Looks good albeit one issue:

enabledCategories = categories.values()['key'] yields empty obj? I think .values() returns an iterator? If you use a map instead that seems to work, e.g. categories.map(c => c.key). Either way can you move the calc out of the default props, maybe export a const categoryKeys from the constants file?

Other than that it's testing well. Nice catch w/ the width!

Can you update example on the readme and example app?

            onChangeRecent={setRecent} // callback to update recent storage - arr of emoji objs
            // backgroundColor={'#000'} // optional custom bg color
            // enabledCategories={['emotion', 'emojis', 'activities', 'flags', 'food', 'places', 'nature']}
            // defaultCategory={'food'} // optional custom default category

`

— Reply to this email directly, view it on GitHub https://github.com/woodybury/rn-emoji-picker/pull/3#issuecomment-1273623960, or unsubscribe https://github.com/notifications/unsubscribe-auth/AJHWPCIIC4XGXV6R4KJBULLWCRHBPANCNFSM6AAAAAARANLSFA . You are receiving this because you were mentioned.Message ID: @.***>

Julioevm commented 2 years ago

@woodybury Applied your suggestions, let me know if there's anything else!

woodybury commented 2 years ago

@Julioevm great published 1.1.6 https://www.npmjs.com/package/rn-emoji-picker