1$(document).ready(function () { 2 let qjson = {} 3 let questIndex = 1 4 $(".quest .steps .step").each(function (index) { 5 $(this).attr("data-n", index + 1) 6 }) 7 $(".quest .status .event").each(function (index) { 8 $(this).attr("data-n", index + 1) 9 }) 10 function setQuestValues(n, name, value) { 11 qjson[n] = { 12 q: name, 13 a: value 14 } 15 } 16 // ÐомеÑка на пÑойденÑе Ñаги ÑÑÐ¾Ð±Ñ Ð½Ð° Ð½Ð¸Ñ Ð¼Ð¾Ð¶Ð½Ð¾ веÑнÑÑÑÑÑ 17 function setStepCompleate(n) { 18 $(".quest .event-" + n).addClass("compleate") 19 } 20 // ÑÑÑановка акÑивного Ñага 21 function setQuestActive(n) { 22 $(".quest .step").removeClass("active") 23 $(".quest .step-" + n).addClass("active") 24 $(".quest .event").removeClass("active") 25 $(".quest .event-" + n).addClass("active") 26 } 27 28 // вÑÐ±Ð¾Ñ Ð²Ð°ÑианÑа 29 $(".quest .item").on("click", function () { 30 31 $step = $(this).closest(".step") 32 $step.find(".item").removeClass("active") 33 $(this).addClass("active") 34 index = $step.attr("data-n") 35 name = $step.find(".name").text(); 36 value = $(this).find(".value").text(); 37 qjson[index] = { 38 q: name, 39 a: value 40 } 41 42 setStepCompleate(questIndex) 43 questIndex++ 44 setQuestActive(questIndex) 45 // вÑÑавлÑем в ÑоÑÐ¼Ñ 46 $(".quest .feedback input[name='value[json]']").val(JSON.stringify(qjson)) 47 $(".quest .develop").text(JSON.stringify(qjson)) 48 }) 49 50 $(".quest .event").on("click", function () { 51 if ($(this).hasClass("compleate")) { 52 questIndex = $(this).attr("data-n") 53 setQuestActive(questIndex) 54 } 55 }) 56})
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.