Привет. Есть https://xbsoftware.ru/produkty/enjoyhint/
Кто-то EnjoyHint ставил на КС?
Застрял тут Cannot read property ‘enjoyHintElementSelector’ of undefined
Это пробовал https://github.com/darron1217/enjoyhint.js/issues/8#issuecomment-675171679
Привет. Есть https://xbsoftware.ru/produkty/enjoyhint/
Кто-то EnjoyHint ставил на КС?
Застрял тут Cannot read property ‘enjoyHintElementSelector’ of undefined
Это пробовал https://github.com/darron1217/enjoyhint.js/issues/8#issuecomment-675171679
Спасибо, интересно
Раз полезно, тогда уточню
< script>
var showed_tutorial_ = "{$showed_tutorial}";
var URL = "{fn_url("habb_js")}";
var company_id = "{$company_id}";
{literal}
(function(_, $) {
$(_.doc).ready(function(){
if(showed_tutorial_ !== '1'){
console.log(" ready enjoyhint s"+showed_tutorial_);
let enjoyhint_instance = new EnjoyHint({
onEnd:function(){ modify_tags_for_tutorial(true); },
onSkip:function(){ modify_tags_for_tutorial(true); }
});
modify_tags_for_tutorial();
let enjoyhint_script_steps = [
{
'click .btn-bar .btn-toolbar .dropleft .pull-right' : 'Это календарь'
}
];
enjoyhint_instance.set(enjoyhint_script_steps);
enjoyhint_instance.run();
set_showed_1();
}
function modify_tags_for_tutorial(invert=false){
let top_panel = $(".navbar-admin-top.cm-sticky-scroll");
if(invert){
// Tags to edit == return to what it was without Hints
top_panel.css('position', 'sticky');
} else {
// Tags to edit
top_panel.css('position', 'unset');
}
}
function set_showed_1(){
let fd = new FormData();
fd.append( 'what', 'set_showed_1' );
fd.append( 'is_ajax', '1' );
fd.append( 'company_id', company_id );
$.ajax({
url: URL,
data: fd,
dataType: 'jsonp',
processData: false,
contentType: false,
type: 'POST',
success: function(data){
console.log(" d "+data);
console.log(data);
//if(data.force_redirection) $.redirect(data.force_redirection);// закоментировано!
},
error: function(xhr, status, error) {
console.log('error hjs40');
console.log(xhr);
},
});
}
})
}(Tygh, Tygh.$));
{/literal}
< / script >