-
Notifications
You must be signed in to change notification settings - Fork 355
Allow editing of existing text #196
Comments
Actually now that I think of it maybe the cleanest way to do this would be to display the text set in the response initially.
would display a prompt with "Some editable text" in it already |
Yes correct, that would be the recommended way to achieve such "dynamic" input components. |
I'm going to close this since its been resolved. Thanks again for following through with this @MarkusFreitag |
Umm, so are you saying this should work? Because at least the example I gave, does not |
Ah sorry! I was under the impression @MarkusFreitag had tested it and verified it worked. I'm going to reopen this ticket and assign it a |
Ah okay. I might be willing to explore if I can implement this. I'm just a bit new with the different ways go modules are built as I've only made my own modules using the new go module feature and I'm not quite sure how to start contributing to for example this project. Can you give me a quick run down on how to build and test this project? |
Awesome! I'd love to help you anyway I can. This project uses run to handle various tasks so once you have downloaded that with Also, if you prefer or want more immediate feedback, feel free to reach out on the gopher slack channel! |
Okay, cool. I got run installed, but the tests are failing. Should they pass currently? Do you have own channel for this project on gophers slack? |
Nope, you can just DM me 😄 They should be passing (travis has a green light). Wanna send me some screenshots of what you're seeing? |
@syvanpera Do you have anything public? I'd be happy to dig in. |
Unfortunately not yet, I've been way too busy lately and next week I'm on vacation so this is going to take a while. |
Up on this feature which would also interest me, has there been any particular progress? And when the temp file is opened in text editor, the file is pre filled with |
So, my mistake. After exploring the code, the method does exist via the Editor. You must pass a default value and set the AppendDefault bool to true.
|
Has anyone been able to do this with the |
I do not think it's possible with the current state of Survey, but I think it could be possible with minimal changes. I've made a spike here: master...mislav:default-editable
I do not think that Survey can shoehorn this new behavior of Default in a backwards-compatible way, but maybe there could be a new option that the user could opt into for each prompt? |
I couldn't find a way to edit some existing text using survey. You can set the Default text for a prompt, which will show it as a grey text next to the prompt and is used if no input is given. But I'd like to be able to edit this default text and save that when enter is pressed.
The text was updated successfully, but these errors were encountered: