Commit message (Collapse) | Author | Age | Files | Lines | |
---|---|---|---|---|---|
* | util.dataforms: Add support for XEP-0122: Data Forms Validation | Kim Alvefur | 2018-09-01 | 1 | -1/+36 |
| | | | | Initially only basic validation of xs:integer | ||||
* | util.dataforms: Allow field names to be different from the 'var' attribute | Kim Alvefur | 2018-09-01 | 1 | -2/+2 |
| | | | | | | This should allow the usage of long prefixes and namespace-like names to be contained to the XML representation of the form, so that the code can use more convenient names. | ||||
* | util.dataforms: Allow passing the current values to be used in stead of ↵ | Kim Alvefur | 2018-08-05 | 1 | -2/+4 |
| | | | | omitted fields | ||||
* | util.dataforms: Normalize indentation | Kim Alvefur | 2018-08-04 | 1 | -3/+3 |
| | |||||
* | util.dataforms: Only allow overriding of options when passed via the :form ↵ | Kim Alvefur | 2018-08-03 | 1 | -9/+8 |
| | | | | method | ||||
* | util.dataforms: Allow overriding default options even if the form has such | Kim Alvefur | 2018-08-03 | 1 | -1/+1 |
| | |||||
* | util.dataforms: Allow passing dynamically generated options as values (fixes ↵ | Kim Alvefur | 2018-08-03 | 1 | -2/+9 |
| | | | | | | | traceback) This is awkward but there’s currently no better way to do this, short of dynamically generating the entire form each time | ||||
* | util.dataforms: Exclude descriptive text fields from forms of type 'submit' | Kim Alvefur | 2018-08-03 | 1 | -9/+13 |
| | | | | | The receiving end presumably already have the original form, so these potentially long text fields are of little value. | ||||
* | util.dataforms: Skip all fields for the 'cancel' form type | Kim Alvefur | 2018-08-03 | 1 | -0/+3 |
| | | | | | | | | | | | XEP-0004 says: > a data form of type "cancel" SHOULD NOT contain any <field/> elements. The title and instructions don't seem to be of much value in this case either. I'm not aware of 'cancel' being used anywhere, so this should break nothing. Early return is always nice. | ||||
* | util.dataforms: Only include options in 'form' type forms | Kim Alvefur | 2018-08-03 | 1 | -1/+1 |
| | | | | Options should not be needed in other types of forms. | ||||
* | util.dataforms: Set default value for form type argument | Kim Alvefur | 2018-08-03 | 1 | -1/+2 |
| | |||||
* | util.dataforms: Detach generation of options from values (fixes #1177) | Kim Alvefur | 2018-08-03 | 1 | -30/+21 |
| | |||||
* | util.dataforms: Ensure fields have names when collecting data (fixes ↵ | Kim Alvefur | 2018-07-15 | 1 | -1/+1 |
| | | | | traceback, thanks Martin) | ||||
* | util.dataforms: More robust handling of field values, especially booleans | Matthew Wild | 2018-07-07 | 1 | -2/+7 |
| | | | | | Ensure that a non-nil data[field_name] always overrides the field's default, and that values of boolean 'false' are always rendered in the form. | ||||
* | util.dataforms: Add support for field descriptions in <desc> | Kim Alvefur | 2018-06-27 | 1 | -0/+4 |
| | |||||
* | util.dataforms: Add a simple function for identifying form types | Kim Alvefur | 2018-06-02 | 1 | -0/+16 |
| | | | | | This is meant to allow identifying forms without parsing them completely. | ||||
* | util.dataforms: Remove string conversion to let util.stanza validate types | Kim Alvefur | 2018-06-02 | 1 | -4/+4 |
| | |||||
* | vairious: Add annotation when an empty environment is set [luacheck] | Kim Alvefur | 2018-02-28 | 1 | -0/+1 |
| | |||||
* | util.dataforms: Don't include list options in result forms (fixes #983) | Matthew Wild | 2017-09-23 | 1 | -18/+22 |
| | |||||
* | util.dataforms: Fix including default value for list-single when given as ↵ | Kim Alvefur | 2016-05-29 | 1 | -1/+1 |
| | | | | field.value[].default | ||||
* | util.dataforms: Allow separation of options from values in list fields | Kim Alvefur | 2016-05-27 | 1 | -4/+12 |
| | |||||
* | util.dataforms: Track which fields are included in a form | Kim Alvefur | 2015-12-08 | 1 | -2/+4 |
| | |||||
* | util.dataforms: Fix interaction of required fields and empty string values ↵ | Kim Alvefur | 2015-09-12 | 1 | -3/+4 |
| | | | | (fixes #521) | ||||
* | util.dataforms: Refactor parsing to reuse simple text parser instead of ↵ | Kim Alvefur | 2015-09-12 | 1 | -26/+21 |
| | | | | duplicate code | ||||
* | util.*: Remove use of module() function, make all module functions local and ↵ | Kim Alvefur | 2015-02-21 | 1 | -3/+5 |
| | | | | return them in a table at the end | ||||
* | util.dataforms: Rename unused loop counter to '_' [luacheck] | Matthew Wild | 2015-05-06 | 1 | -1/+1 |
| | |||||
* | util.dataforms: Remove unused import of pairs() (thanks luacheck) | Matthew Wild | 2015-05-06 | 1 | -1/+1 |
| | |||||
* | Merge 0.9->0.10 | Waqas Hussain | 2014-10-08 | 1 | -1/+1 |
|\ | |||||
| * | util/dataforms: Make sure we iterate over field tags | daurnimator | 2014-10-07 | 1 | -1/+1 |
| | | |||||
* | | Merge 0.9->0.10 | Kim Alvefur | 2014-04-23 | 1 | -0/+9 |
|\| | |||||
| * | util.dataforms: Add support for XEP-0221: Data Forms Media Element | Kim Alvefur | 2014-04-22 | 1 | -0/+9 |
| | | |||||
* | | Remove all trailing whitespace | Florian Zeitz | 2013-08-09 | 1 | -4/+4 |
|/ | |||||
* | util.dataforms: Return nil for empty list-mutli responses, to be consistent ↵ | Florian Zeitz | 2013-06-14 | 1 | -1/+5 |
| | | | | with other readers | ||||
* | util.dataforms: Add support for generating type='fixed' fields | Florian Zeitz | 2013-02-11 | 1 | -1/+1 |
| | |||||
* | util.dataforms: Fix parsing of -multi fields | Florian Zeitz | 2012-06-12 | 1 | -5/+5 |
| | |||||
* | util.dataforms: Don't return invalid JIDs in jid-single. | Kim Alvefur | 2012-05-17 | 1 | -1/+1 |
| | |||||
* | util.dataforms: Fix validation of booleans. | Kim Alvefur | 2012-05-17 | 1 | -1/+1 |
| | |||||
* | util.dataforms: Do field validation and normalization in field readers. | Kim Alvefur | 2012-05-17 | 1 | -101/+53 |
| | |||||
* | util.dataforms: Fix verfication for booleans | Florian Zeitz | 2011-12-03 | 1 | -1/+1 |
| | |||||
* | util.dataforms: Fix form verification | Florian Zeitz | 2011-12-02 | 1 | -7/+13 |
| | |||||
* | util.dataforms: Add field verification logic | Florian Zeitz | 2011-08-11 | 1 | -10/+81 |
| | |||||
* | Monster whitespace commit (beware the whitespace monster). | Waqas Hussain | 2010-10-16 | 1 | -7/+7 |
| | |||||
* | util.dataforms: Add list-multi support | Florian Zeitz | 2010-07-15 | 1 | -0/+22 |
| | |||||
* | util.dataforms: Capability to set default for list-single | Florian Zeitz | 2010-07-15 | 1 | -0/+5 |
| | |||||
* | Update copyright headers for 2010 | Matthew Wild | 2010-03-22 | 1 | -2/+2 |
| | |||||
* | util.dataforms: Add optional type parameters (defaults to 'form') | Matthew Wild | 2010-01-22 | 1 | -2/+2 |
| | |||||
* | util.dataforms: Don't require type when parsing form XML | Florian Zeitz | 2009-11-25 | 1 | -1/+7 |
| | |||||
* | util.dataforms: Support for jid-multi field type | Florian Zeitz | 2009-11-06 | 1 | -0/+11 |
| | |||||
* | util.dataforms: Only add value to rendered form if supplied in the data | Florian Zeitz | 2009-10-30 | 1 | -32/+34 |
| | |||||
* | util.dataforms: Incorporate slightly modified patch for list-single type ↵ | Matthew Wild | 2009-10-16 | 1 | -1/+11 |
| | | | | from Florob |