formio.js: [BUG] Address component does not render correctly in HTML mode
Environment
Local using latest build https://unpkg.com/formiojs@latest/dist/formio.full.min.js
- Formio.js version: Lastest
- Browser: All
Steps to Reproduce
- Display a form using viewAsHTML or renderMode: ‘html’
Expected behavior
Should display for the submission without controls and data. No way to display only data with current builds.
Observed behavior
- viewAsHTML does not remove controls as it did in 3.x
- renderMode does not render any values.
Example
https://jsfiddle.net/0Lvtaxes/
<div id='formio'></div>
<!-- jquery -->
<script src="https://code.jquery.com/jquery-3.4.1.min.js"></script>
<!-- bootstrap -->
<link rel="stylesheet" href="https://stackpath.bootstrapcdn.com/bootstrap/4.3.1/css/bootstrap.min.css" integrity="sha384-ggOyR0iXCbMQv3Xipma34MD+dH/1fQ784/j6cY/iJTQUOhcWr7x9JvoRxT2MZw1T" crossorigin="anonymous">
<script src="https://stackpath.bootstrapcdn.com/bootstrap/4.3.1/js/bootstrap.min.js" integrity="sha384-JjSmVgyd0p3pXB1rRibZUAYoIIy6OrQ6VrjIEaFf/nJGzIxFDsf4x0xIM+B07jRM" crossorigin="anonymous"></script>
<!-- formio -->
<link rel='stylesheet' href='https://unpkg.com/formiojs@latest/dist/formio.full.min.css'>
<script src='https://unpkg.com/formiojs@latest/dist/formio.full.min.js'></script>
<!-- code -->
<script type='text/javascript'>
Formio.createForm(document.getElementById('formio'), 'https://examples.form.io/example', {
readOnly: true,
renderMode: 'html'
}).then(function(form) {
form.submission = {
data: {
firstName: 'Joe',
lastName: 'Smith',
email: 'joe@example.com'
}
};
});
</script>
About this issue
- Original URL
- State: closed
- Created 5 years ago
- Comments: 18 (4 by maintainers)
@aiwebb -
form.redraw()
works for me but the Google Address field value show as[object Object]
.@themattkenney We are hoping to get this item fixed with a new build by early next week.