vue-tags-input icon indicating copy to clipboard operation
vue-tags-input copied to clipboard

Set tag class from autoload

Open tyson-nw opened this issue 6 years ago • 0 comments

Is there a way that an autocomplete entry can set or extend the class of a tag? I have tried

this.autocompleteItems = response.data.map(a => {
	console.log(a.tag_type+"-tag");
	return { 
		text: a.tag,
		classes: a.tag_type,
	};
});

and

this.autocompleteItems = response.data.map(a => {
	console.log(a.tag_type+"-tag");
	return { 
		text: a.tag,
		class: a.tag_type+"-tag",
	};
});

Either way, when the tag is selected the console shows the tag I want to add but the element does not get that class name. Am I missing a step or is this broken?

<span data-v-61d92e31="" class="">Modern</span>

I am using Vue 2.6.10

Modern

tyson-nw avatar Oct 08 '19 17:10 tyson-nw