d2tools/res/app.js

58 lines
1.2 KiB
JavaScript
Raw Normal View History

2021-03-23 08:13:54 +00:00
$(document).ready(function () {
$('.form-text').hide();
$('.help').click(function () {
2021-03-25 09:03:08 +00:00
// $('.form-text').slideToggle();
2021-03-23 08:13:54 +00:00
});
2021-03-25 09:03:08 +00:00
$('.op1').val(this.checked);
$('.op1').change(function () {
2021-03-23 08:13:54 +00:00
if (this.checked) {
$('option[disabled="disabled"]').hide();
} else {
$('option[disabled="disabled"]').show();
}
});
2021-03-25 09:03:08 +00:00
$('.w-select').change(function () {
$('.a-select').each(function (i, v) {
2021-03-23 08:13:54 +00:00
v.value = '';
v.required = '';
});
2021-03-25 09:03:08 +00:00
2021-03-23 08:13:54 +00:00
x = $(this).find(':selected').text();
y = document.getElementById('item');
y.value = x;
2021-03-25 09:03:08 +00:00
});
$('.a-select').change(function () {
$('.w-select').each(function (i, v) {
2021-03-23 08:13:54 +00:00
v.value = '';
v.required = '';
});
2021-03-25 09:03:08 +00:00
2021-03-23 08:13:54 +00:00
x = $(this).find(':selected').text();
y = document.getElementById('item');
2021-03-25 09:03:08 +00:00
y.value = x;
});
$(".btnconfig").click(function () {
2021-03-24 15:37:21 +00:00
$(".ctrl-config").hide();
$("#loading").show();
2021-03-25 09:03:08 +00:00
2021-03-24 15:37:21 +00:00
});
2021-03-25 09:03:08 +00:00
$('.help').hover(function () {
2021-03-25 09:03:08 +00:00
$(".fa-help").remove();
$(this).next().fadeToggle("slow").css({
"position": "absolute",
"z-index": "1000",
2021-03-25 09:03:08 +00:00
"background": "#eee",
"color": "black !important",
"border": "1px solid #aaa",
"width": "300px",
2021-03-25 09:03:08 +00:00
});
});
});