/**
 * token multiselect
 */
import IGDATAPOOLFE from '@dp/ig_datapool_fe.js';

const tokenMultiSelectPlugin = {
    initFields(form) {
        this.init(form);
    },
    init(form) {
	let $form = $(form);
	this.form = $form;
	$('select.dp-select2.dp-tokenizer', $form).each(function() {
	    $(this).select2();
	});
    }
};
IGDATAPOOLFE.addPlugin('tokenMultiSelect', tokenMultiSelectPlugin);
export default tokenMultiSelectPlugin;
