changeset 64754a696aff in sao:default
details: https://hg.tryton.org/sao?cmd=changeset;node=64754a696aff
description:
        Add workaround for dynamic datalist on Firefox

        This is related to https://bugzilla.mozilla.org/show_bug.cgi?id=1474137

        issue8454
        review257651002
diffstat:

 src/screen.js    |  5 ++++-
 src/view/form.js |  3 +++
 2 files changed, 7 insertions(+), 1 deletions(-)

diffs (28 lines):

diff -r d3d2d9a2cc92 -r 64754a696aff src/screen.js
--- a/src/screen.js     Mon Jul 08 18:51:36 2019 +0200
+++ b/src/screen.js     Mon Jul 08 21:26:20 2019 +0200
@@ -34,7 +34,10 @@
             this.filter_button.click(this.search_box.bind(this));
             this.search_entry = jQuery('<input/>', {
                 'class': 'form-control mousetrap',
-                'placeholder': Sao.i18n.gettext('Search')
+                'placeholder': Sao.i18n.gettext('Search'),
+                // workaround for
+                // https://bugzilla.mozilla.org/show_bug.cgi?id=1474137
+                'autocomplete': 'off',
             });
             this.search_list = jQuery('<datalist/>');
             this.search_list.uniqueId();
diff -r d3d2d9a2cc92 -r 64754a696aff src/view/form.js
--- a/src/view/form.js  Mon Jul 08 18:51:36 2019 +0200
+++ b/src/view/form.js  Mon Jul 08 21:26:20 2019 +0200
@@ -1251,6 +1251,9 @@
                 this.datalist = jQuery('<datalist/>').appendTo(this.el);
                 this.datalist.uniqueId();
                 this.input.attr('list', this.datalist.attr('id'));
+                // workaround for
+                // https://bugzilla.mozilla.org/show_bug.cgi?id=1474137
+                this.input.attr('autocomplete', 'off');
             }
             this.el.change(this.focus_out.bind(this));
 

Reply via email to