All notable changes to this project will be documented in this file. This project adheres to Semantic Versioning.
- Fix import error for enketo-transformer/web (#184)
- Move libxslt to (optional) peerDependencies, devDependencies (#181)
- Web compatibility (#171)
- Fix: include build artifacts when publishing (#167)
- Type checking and simplification of tests (#157)
- Convert remainder of library to TypeScript, Vite build, include type checking in CI (#158)
- Optimize expensive XPath expressions in HTML transform (#165)
- Replace request with undici (Node's official fetch package), update dependencies, patch vulnerabilities (#155)
- Fixed special string.replace sequences in Markdown (#153)
- Fixed regression when transforming forms with no media mapping, when the form has binary defaults or references jr: URLs in markdown. (#152)
- Fixed mangling of markdown-produced HTML next to top-level text nodes when a mediamap is provided (#150)
- Code style/formatting: Prettier + Airbnb ESLint preset (#146)
- When a
<select>
is readonly, its<option>
s are disabled (#139)
- Preserve query parameters in media mapping URLs
- Escape all jr:// media URLs, always use media mapping
- Upgraded node, npm, and other dependencies
- Support for
odk:setgeopoint
.
- Changed form id attribute to data-form-id to support spaces.
- Output explicitly set default languages differently than the first-defined language.
- Setvalue/xforms-value-changed inside a select multiple question is not working.
- Setvalue/odk-instance-first-load actions do not copy custom OpenClinica attributes.
- Setvalue/odk-instance-first-load and setvalue/odk-new-repeat actions are not properly added for radiobutton and checkbox questions.
- If the same repeat question has both a setvalue/odk-instance-first-load as well as a setvalue/xforms-value-changed, the output can get messed up.
- If a ref or nodeset attribute starts with a space, the absolute path is not determined correctly.
- Ordered markdown lists should always be preceded by a newline character (partially reverted change in 1.40.2) because it's very common to number labels in forms.
- An openclinica transformation mode that passes all custom bind attributes in the OpenClinica namespace including custom 'Msg' attributes in the right place.
- When a
setvalue
element has novalue
attribute and no textContent, the output fordata-setvalue
is incorrect.
- Markdown lists no longer require preceding newline.
- Markdown ordered lists detect non-1 numbering start.
- Add rel="noopener" to markdown links.
- Textarea contains unnecessary space character.
- Output may contain a language
<select/>
that is self-closing and therefore invalid HTML.
- Support for multiple setvalue/xforms-value-changed actions under a single question.
- GET /support/htmlform API endpoint for developers to easily check HTML form output in developer console.
- Node 8 compatibility.
- Node 12 now required.
- Model attributes not copied.
- Support for setvalue action with the xforms-value-changed event.
- Support for setvalue action with the odk-new-repeat and odk-instance-first-load events.
- Support for binary defaults.
- Moved enketo-xslt to this repo.
- XML dateTime is now converted to HTML input type="datetime-local".
- Rank output is a HTML syntax error.
- Support for "picker" appearance on range question.
- Guidance hints are now added as a
<details>
element.
- Support for orx:max-pixels
columns-flex
is nowcolumns-pack
(last-minute spec change).
- Convert deprecated select/1 appearances to new appearances.
- Sorani (Kurdish) not detected as RTL + other general issues with RTL detection.
- Print hints are now guidance hints (
form="guidance"
) to comply with ODK XForms Specification.
- Propagate custom oc:constraint-type and oc:required-type attributes.
- Correct deprecated "form-data-post" value for method attribute of submission element to "post".
- Security warnings when using web API.
- No longer apply the 'note' class on readonly questions.
- Randomize() doesn't work for itemsets that use itext() labels.
- ODK namespace for
<rank>
was changed to "http://www.opendatakit.org/xforms".
- Support for Ranking widget.
- Support for Range widget.
- Support for
<sup>
and<sup>
(superscript and subscript).
- In Markdown, make a distinction between paragraphs (2+ subsequent new lines) and simple new lines.
- In Markdown, newline characters are not converted if they follow a heading.
- Markdown headers not limited from h1-h6 as they should be.
- Support for appearance "new", "new-front", "new-rear" on media upload questions.
- Markdown headers preceded by whitespace fail to render as header.
- Deliberate whitespace after or before header tags is trimmed when it shouldn't be.
- Support for escaping # characters in markdown.
- Markdown headers now work at the start of any line, even if not followed by a newline.
- Markdown headers in the middle of a string are not always ignored.
- Pass oc:external attribute (custom).
- Readonly questions do not get custom constraint message.
- Facilitate incorporation into a executable application.
- Support for escaping * and _ characters in markdown.
- Proper IANA language tag inclusion in XForm does not prevent/override (weak) directionality detection.
- Fails to build on Windows (10).
- Workaround for an XLSForm limitation by moving "no-collapse" appearance of repeat to its parent group.
- Npm refuses to install previous version with enketo-xslt 1.15.2, since December 19th 2017 or before.
- No support for groups without
ref
attribute with a repeat child.
- Workaround for an XLSForm limitation by moving "compact" appearance of repeat to its parent group.
- Support for very custom 'kb:flash' body attribute (KoBoToolbox).
- "or-branch" class on calculated items without a form control.
- Support for appearance="numbers" on text inputs.
- Optional support for oc:relevantMsg.
- Readonly select options do not get the disabled attribute.
- Copy image-customization form control attribute (KoBo client-specific customization).
- Repeat output now includes a repeat-info element. Warning: backwards-incompatible change
- Only add 'note' class to readonly questions that do not have a calculate bind attribute.
- Updated XSLT module
- Support for select1 with autocomplete appearance -> HTML datalist.
- Media labels for itemsets are missing the data-itext-id attribute.
- Ability to pass an XForm preprocessor function.
- Output a languageMap property to the result.
- Support for "accept" attribute for upload mediatype.
- Missing debug module dependency.
- Add transformerVersion property to transformation result.
- Add preload attributes to form control elements.
- Readonly syntax changes matching enketo-core 4.14.1+.
- Ability to disable markdown rendering.
- Show "*" for all questions where the
required
attribute is not""
and not"false()"
. - Switched to enketo namespace for "for" attribute.
- If incorrect XForms without /meta/instanceID are provided, add these nodes.
- No readonly support for select minimal
- Proper support for namespaces. Warning: requires enketo-core 4.7.0+!
- Support for comment feature.
- Markdown headers not followed by newline are not converted.
- Span containing link not coverted.
- Rogue newline characters appear in empty outputs.
- Outputs cannot be formatted in markdown.
- Updated minor modules (to force a version change).
- Updated libxslt module.
- Href source is not replaced.
- Added or-big-image class to image links
- Minor under-the-hood changes
- Support for big-image.
- Support for jr:requiredMsg.
- Support for rows input attribute (alias of multiline appearance).
- Support for dynamic required binding attributes.
- Markdown renders multiple span elements on same line as one span.
- Node 4.x and 5.x compatibility.
- Node 0.12 compatibility (second try).
- String containing just a <span> without other markdown, is not converted.
- Media sources in model not being replaced.
- First labels/hints consisting only of whitespace are selected to determine directionality.
- Directionality for '-' returns rtl directionality (default).
- Full-featured POST /transform API endpoint
- Instead of manifest parameter a media map is now required (Warning!)
- Markdown lists created items if space behind bullet was missing.
- Markdown lists were created if first item not preceded by new line. See issue
- Markdown lists not formed correctly.
- Markdown lists require newline character to start (too strict).
- Markdown multiple emphasis (or strong) markup in same line converts as one.
- Reverted node 0.12 fix. It is now again incompatible with 0.12.
- Missing outputs from transformation result.
- XSLT warning messages for output and itemset.
- node 0.12 compatibility
- Moved markdown support from enketo-core, added additional support, and expanded to all labels and hints (Warning: use only with enketo-core 4.2.0+ ).
- Default directionality ltr if first text element contains only whitespaces.
- Rtl detection not working if no itext hints present.
- Languages in form selector oddly aligned if mix of ltr and rtl languages is used (FF).
- Simple select questions get the simple-select class. Update enketo-core!
- Directionality not detected when forms contain no itext.
- Prefer first hint when determining directionality of language.
- Preferred language name syntax in XForms is now "Name Of Language (tag)".
- Right-to-left detection of languages that cannot be found in IANA registry.
- Default language attribute value processed to match form language tags.
- Exact language description now ranked first (Dari fix).
- Language names starting with 'fa' get incorrect directionality
- Directionality of language tag with region (e.g. ar-IR) not determined correctly.
- Post-process lang attributes to create valid HTML.
- Determine language directionality.
- Changes in transformation library itself do not update version.
- Default 'ltr' directionality added to languages in language selector.
- Switched from node_xslt to node-libxslt. May require updating npm's internal node-gyp (Warning:be careful).
- Triggers do not get the same attributes as radio buttons.
- Theme-swapping feature.
- Required="false()" is seen as required.
- Default constraint and default required message now added by XSL.
- API: GET /transform endpoint