-
Notifications
You must be signed in to change notification settings - Fork 166
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Speaker dropdown select -v2 #210
Conversation
Updating from BBC repo
Updating from BBC
Updating from BBC master
…ad-only-mode Fix 133 speaker not editable in read only mode
bbc/react-transcript-editor@master...philmcmahon:update-all-speakers#diff-cdf6a9957d22ff2efacaaf5fb2876a8aR58 it works but does not seem to rerender after change
only missing onChange for select to be fully working + styling
1. ✅All seems good, the features seem to be working as expected. 2. 🐛However when using select inside the
I think this is a draftJs problem, see facebookarchive/draft-js#1085 3. 🚀I've also updated draftJs to the latest version as the console kept complaining that current version of draft uses an older version of React. |
Raised issue facebookarchive/draft-js#2204 |
Sorry capturing GIFs don't work with licecap (probably to do with Firefox...) :( so having to use old school image capturing. In a more narrow set up (960) the drop-down seems to disappear. 1 Click speaker2 Drop down menu disappears3 ... but not really |
Would be nice to fixOrdering of string "numbers" is 1, 100, 11, 2Just capturing this: the ordering of numbers is not the greatest, but this is the nature of treating numbers as strings. As @pietrop said, if people are thinking to only have up to 5 speakers (also assuming that they have real names not numbers), it's not a problem. Long speaker names overlap with button |
via @emettely possible fix to investigate https://draftjs.org/docs/advanced-topics-block-components.html#recommendations-and-other-notes
|
Is your Pull Request request related to another issue in this repository ?
Improving #208, #141 - #141 (comment)
alternative approach to #209, with no external dependencies introduced.
Describe what the PR does
State whether the PR is ready for review or whether it needs extra work
Ready for review + one small draftJs bug #210 (comment)
Additional context
Initially considered to do an auto complete dropdown as suggested by @scentless-apprentice
and tried to use react-select in this PR #209 to help with that. But then decided to scrap it and use html select element directly, combining it with features from #208
Other considerations
WrapperBlock
editable, I think we set the focus of cursor to be on the text of the editor only, and forgot how we did it, to be able to look into how to tweak that. However using select combined withprompt
that is not necessary for a first version.