';
content = content.replace('{s}', '« ' + sanitizer.sanitize(input.value) + ' »');
} else {
var cleanText = sanitizer.sanitize(suggestion.text)
var boldText = cleanText.replace(reg, function (optionText) {
return '' + optionText + ''
});
var subText = sanitizer.sanitize(suggestion.subText);
subText = subText.replace(suggestion.artistName, function (optionText) {
return optionText.replace(reg, function (boldText) {
return '' + boldText + ''
})
});
var cssClass = suggestion.type === 'artist' ? 'img-circle border' : '';
content = '
' +
'' +
'
' +
'' + boldText + '' +
'' + subText + '' +
'
' +
'
';
}
itemElement.innerHTML = content;
return itemElement;
},
onSelect: function (element, autocomplete) {
document.dispatchEvent(new CustomEvent('am.gtag.search', {'detail': {'term': autocomplete.value}}))
savedSearch(sanitizer.sanitize(autocomplete.value), element);
},
emptyMsg: '无效',
preventSubmit: false,
showOnFocus: true,
// Required to set the final position of the results
// By default result tag is applied at the bottom of the document with fixed style
// when we want it in the defined tag ( Styles are also customized )
customize: function (input, inputRect, container, maxHeight) {
resultContainer.append($(container))
}
};
}
function savedSearch(string, element) {
if (!element.url) {
element.url = url.replace("term", string)
}
var formData = new FormData();
formData.append('string', string);
formData.append('nbResults', nbResults);
try {
if (navigator.sendBeacon) {
navigator.sendBeacon('/zh/saved--search/artwork', formData)
} else {
var xhr = new XMLHttpRequest();
xhr.open('post', '/zh/saved--search/artwork', false);
xhr.send(formData);
}
} catch (e) {
}
window.location.href = element.url
}
document.addEventListener('am.gtag.search', function (e) {
var term = e.detail.term
gtag("event", "search", {
search_term: term
});
});
})
})();
Hi, I am an oil painting artist living in Denmark.
Growing up in a traditional Chinese family, I am good at saying things that please others, I am good at hiding my feelings. No one knows who I really am, not even myself. I always have friends around but somehow I still feel lonely all the time. I suffer from socializing but business is about socializing, I dream of being an artist but I have to work to live.
Yep, that is a long-story-short version of my struggling life. However, I am still grateful since it normally throws inspiration to me for my art (what else I can ask for :) ). My painting is my way of speaking to myself and showing my inside out.
Now, finding myself and making peace with my life has become part of my journey. So, what is behind my mask? I hope I will have the answer one day. What is behind your mask? Only you can answer it.
Hi, I am an oil painting artist living in Denmark.
Growing up in a traditional Chinese family, I am good at saying things that please others, I am good at hiding my feelings. No one knows who I really am, not even myself. I always have friends around but somehow I still feel lonely all the time. I suffer from socializing but business is about socializing, I dream of being an artist but I have to work to live.
Yep, that is a long-story-short version of my struggling life. However, I am still grateful since it normally throws inspiration to me for my art (what else I can ask for :) ). My painting is my way of speaking to myself and showing my inside out.
Now, finding myself and making peace with my life has become part of my journey. So, what is behind my mask? I hope I will have the answer one day. What is behind your mask? Only you can answer it.