Skip to content
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

Form elements #13

Open
pigworker opened this issue Mar 13, 2020 · 1 comment
Open

Form elements #13

pigworker opened this issue Mar 13, 2020 · 1 comment
Labels
enhancement New feature or request

Comments

@pigworker
Copy link
Contributor

Pandoc does allow us to write form elements, but only in that we're allowed to write things like

`<input type=text name="foo">`{=html}

`<input type=submit>`{=html}

I think we should write less and achieve more. We need some way to signal the existence of form fields to the shonkier runtime, so that field value requests can be handled. We should also be able to attach a preprocessor to a form field which eats text and emits a value or aborts; field value requests should yield the output of the preprocessor.
(One day, when our language is typed, the preprocessor will be type directed.)

We could have something like

`'foo`{.in type=text size=12}

to signal a form field bound to the atom 'foo. To access this field, invoke

'field('foo)

We might, further, write

`'bar <- parser`{.in type=text size=100}

where parser is an expression yielding a function which eats string literals.

@pigworker pigworker added the enhancement New feature or request label Mar 13, 2020
@pigworker
Copy link
Contributor Author

This is alive. We need to wire this up to some sort of ontological model. We also need to get some more active field manipulation happening in the javascript runtime.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant