Devographics / Monorepo

Monorepo containing the State of JS apps
surveyform-sigma.vercel.app
Other
124 stars 50 forks source link

initialCustomCount option for TextList #279

Closed LeaVerou closed 11 months ago

LeaVerou commented 11 months ago

I suspect these are not all the changes required, since TS still complains that initialCustomCount is not in QuestionMetadata, but figured I'd get some feedback

netlify[bot] commented 11 months ago

Deploy request for css2023 pending review.

Visit the deploys page to approve it

Name Link
Latest commit 98a7b2853edf62f69a70e69ed43c0838e0e5ca60
netlify[bot] commented 11 months ago

Deploy request for stateofjs2022 pending review.

Visit the deploys page to approve it

Name Link
Latest commit 98a7b2853edf62f69a70e69ed43c0838e0e5ca60
netlify[bot] commented 11 months ago

Deploy request for tokyodev2022 pending review.

Visit the deploys page to approve it

Name Link
Latest commit 98a7b2853edf62f69a70e69ed43c0838e0e5ca60
netlify[bot] commented 11 months ago

Deploy Preview for devographics-static failed.

Name Link
Latest commit 98a7b2853edf62f69a70e69ed43c0838e0e5ca60
Latest deploy log https://app.netlify.com/sites/devographics-static/deploys/64f69a91aac0a60008ba8f16
netlify[bot] commented 11 months ago

Deploy Preview for state-of-graphql canceled.

Name Link
Latest commit 98a7b2853edf62f69a70e69ed43c0838e0e5ca60
Latest deploy log https://app.netlify.com/sites/state-of-graphql/deploys/64f69a912e33e200088c1c60
netlify[bot] commented 11 months ago

Deploy Preview for devographics-graphiql2 canceled.

Name Link
Latest commit 98a7b2853edf62f69a70e69ed43c0838e0e5ca60
Latest deploy log https://app.netlify.com/sites/devographics-graphiql2/deploys/64f69a910fc09e00086a41b6
vercel[bot] commented 11 months ago

@LeaVerou is attempting to deploy a commit to the Devographics Team on Vercel.

A member of the Team first needs to authorize it.

netlify[bot] commented 11 months ago

Deploy Preview for stateofjs canceled.

Name Link
Latest commit 98a7b2853edf62f69a70e69ed43c0838e0e5ca60
Latest deploy log https://app.netlify.com/sites/stateofjs/deploys/64f69a91daca7c000842e075
netlify[bot] commented 11 months ago

Deploy Preview for stateofcss canceled.

Name Link
Latest commit 98a7b2853edf62f69a70e69ed43c0838e0e5ca60
Latest deploy log https://app.netlify.com/sites/stateofcss/deploys/64f69a912fa6a70008e6e616
netlify[bot] commented 11 months ago

Deploy Preview for devographics-graphiql-internal canceled.

Name Link
Latest commit 98a7b2853edf62f69a70e69ed43c0838e0e5ca60
Latest deploy log https://app.netlify.com/sites/devographics-graphiql-internal/deploys/64f69a91f8fe9c0008e60356
netlify[bot] commented 11 months ago

Deploy Preview for graphiql-devographics canceled.

Name Link
Latest commit 98a7b2853edf62f69a70e69ed43c0838e0e5ca60
Latest deploy log https://app.netlify.com/sites/graphiql-devographics/deploys/64f69a919c8ea60008ba7066
SachaG commented 11 months ago

My worry is that it will seem weird to respondents if some questions have one item from the start, others have two, others have three, etc. If the idea is that one item is not enough to show you can enter multiple items, what if we always showed two empty items by default? Would that alleviate the need for that setting? I just want to avoid adding more properties to the API if we can help it.

LeaVerou commented 11 months ago

My worry is that it will seem weird to respondents if some questions have one item from the start, others have two, others have three, etc. If the idea is that one item is not enough to show you can enter multiple items, what if we always showed two empty items by default? Would that alleviate the need for that setting? I just want to avoid adding more properties to the API if we can help it.

Maybe we can show two by default for single-line inputs and one for multiline?

SachaG commented 11 months ago

Given that we also have non-textlist fields that don't "multiply" when you interact with them, I think maybe just making every textList field have two empty fields by default would be a good way to help respondents identify them visually?

eric-burel commented 11 months ago

Outside of the option altering the value doesn't work as expected, we want the value to be what the user typed in, so instead it's better to extend the "lastItem" part to be an array. It should be possible, then I need to be careful with the input indexes