Kim Alvefur
7cafc69278
util.dataforms: Add support for validating (integer) ranges
6 years ago
Kim Alvefur
d0835ef1cf
util.dataforms: Add more XEP-0211 media element test coverage
5 years ago
Kim Alvefur
5b16babafb
util.dataforms: Convert media element sizes to avoid error on Lua 5.3
...
The stanza API does not accept number values and threw an error due to
the height and width attributes of the media element (XEP-0221).
This part had no test coverage previously, explaining why it was not
discovered until now.
5 years ago
Kim Alvefur
d1b1a7fa33
util.dataforms: Improve descriptions in tests
6 years ago
Kim Alvefur
080c294fe8
util.dataforms: Add support for XEP-0122: Data Forms Validation
...
Initially only basic validation of xs:integer
7 years ago
Kim Alvefur
367e73a610
util.dataforms: Allow field names to be different from the 'var' attribute
...
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.
7 years ago
Kim Alvefur
6e61be70af
util.dataforms: Allow passing the current values to be used in stead of omitted fields
8 years ago
Kim Alvefur
211253c16c
util.dataforms: Add failing test for #1177
8 years ago
Kim Alvefur
531971e0b5
util.dataforms: Include a fixed field in test
8 years ago
Kim Alvefur
7bc9f73c73
util.dataforms: Add a simple function for identifying form types
...
This is meant to allow identifying forms without parsing them
completely.
8 years ago
Kim Alvefur
e8da59435a
util.dataforms: Add initial tests
...
This covers basic form generation, that the fields have the correct
attributes, children and text content.
8 years ago