diff --git a/Phraseanet-production-client/dist/production.js b/Phraseanet-production-client/dist/production.js
index 591d8f01de..f4a76e6ca5 100644
--- a/Phraseanet-production-client/dist/production.js
+++ b/Phraseanet-production-client/dist/production.js
@@ -11578,7 +11578,11 @@ var thesaurusService = function thesaurusService(services) {
(0, _jquery2.default)('#THPD_T_tree', $container).removeClass('draggingOver');
(0, _jquery2.default)('#THPD_T_tree>LI', $container).removeClass('draggingOver');
- var target = (0, _jquery2.default)(event.toElement);
+ // the event relates from the whole tx zone (
), we must find the exact element of the mouseup
+ // too bad, jquery does not seem to handle that in a cross-browser way.
+ var target = typeof event.toElement === 'undefined' ? (0, _jquery2.default)(event.originalEvent.target) // ffox
+ : (0, _jquery2.default)(event.toElement); // chrome
+
var sbas_id = target.data('sbas_id').toString(); // set on html by ThesaurusXmlHttpController.php
var tx_term_id = target.data('tx_term_id').toString(); // set on html by ThesaurusXmlHttpController.php
diff --git a/Phraseanet-production-client/dist/production.min.js b/Phraseanet-production-client/dist/production.min.js
index 591d8f01de..f4a76e6ca5 100644
--- a/Phraseanet-production-client/dist/production.min.js
+++ b/Phraseanet-production-client/dist/production.min.js
@@ -11578,7 +11578,11 @@ var thesaurusService = function thesaurusService(services) {
(0, _jquery2.default)('#THPD_T_tree', $container).removeClass('draggingOver');
(0, _jquery2.default)('#THPD_T_tree>LI', $container).removeClass('draggingOver');
- var target = (0, _jquery2.default)(event.toElement);
+ // the event relates from the whole tx zone (), we must find the exact element of the mouseup
+ // too bad, jquery does not seem to handle that in a cross-browser way.
+ var target = typeof event.toElement === 'undefined' ? (0, _jquery2.default)(event.originalEvent.target) // ffox
+ : (0, _jquery2.default)(event.toElement); // chrome
+
var sbas_id = target.data('sbas_id').toString(); // set on html by ThesaurusXmlHttpController.php
var tx_term_id = target.data('tx_term_id').toString(); // set on html by ThesaurusXmlHttpController.php
diff --git a/Phraseanet-production-client/src/components/thesaurus/index.js b/Phraseanet-production-client/src/components/thesaurus/index.js
index 51144defee..c30f15e916 100644
--- a/Phraseanet-production-client/src/components/thesaurus/index.js
+++ b/Phraseanet-production-client/src/components/thesaurus/index.js
@@ -201,7 +201,13 @@ const thesaurusService = services => {
$('#THPD_T_tree', $container).removeClass('draggingOver');
$('#THPD_T_tree>LI', $container).removeClass('draggingOver');
- const target = $(event.toElement);
+ // the event relates from the whole tx zone (), we must find the exact element of the mouseup
+ // too bad, jquery does not seem to handle that in a cross-browser way.
+ const target = typeof(event.toElement) === 'undefined' ?
+ $(event.originalEvent.target) // ffox
+ :
+ $(event.toElement); // chrome
+
const sbas_id = target.data('sbas_id').toString(); // set on html by ThesaurusXmlHttpController.php
const tx_term_id = target.data('tx_term_id').toString(); // set on html by ThesaurusXmlHttpController.php