8000 modified · rankdeveloper/funcode@753d766 · GitHub
[go: up one dir, main page]

Skip to content 8000

Commit 753d766

Browse files
committed
modified
1 parent ceababb commit 753d766

File tree

1 file changed

+31
-47
lines changed

1 file changed

+31
-47
lines changed

java/script.js

Lines changed: 31 additions & 47 deletions
Original file line numberDiff line numberDiff line change
@@ -27,42 +27,42 @@ const detailsMap = {};
2727
arr1.forEach(pro => {
2828
const type = pro.type;
2929

30-
const basic_pro=(pro.type=="basic")?139:''
31-
const count_exceptionH_pro=(pro.type=="exception Handling")?13:''
32-
const count_delegationE_pro=(pro.type=="delegationEventModel")?20:''
33-
34-
// array
35-
// 2darray
36-
// awt
37-
// dataConversion
38-
// string
39-
// inheritance
40-
// input_output
41-
// jdbc
42-
// oop
43-
// strings
44-
// basic
45-
// function
46-
// 2dArray
47-
// delegationEventModel
48-
// exception Handling
49-
30+
const basic_pro = (pro.type == "basic") ? 139 : ''
31+
const count_exceptionH_pro = (pro.type == "exception Handling") ? 13 : ''
32+
const count_delegationE_pro = (pro.type == "delegationEventModel") ? 20 : ''
33+
34+
// array
35+
// 2darray
36+
// awt
37+
// dataConversion
38+
// string
39+
// inheritance
40+
// input_output
41+
// jdbc
42+
// oop
43+
// strings
44+
// basic
45+
// function
46+
// 2dArray
47+
// delegationEventModel
48+
// exception Handling
49+
5050

5151
// Check if the details element for the current type already exists
5252
if (!detailsMap[type]) {
5353
// If it doesn't exist, create a new details element and append it to the container
5454
const details = document.createElement("details");
55-
55+
5656
details.innerHTML = `<summary>
5757
${type}
5858
${count_exceptionH_pro}
5959
${basic_pro}
6060
${count_delegationE_pro}
61-
${pro.type=="array"?1:''} ${pro.type=="2darray"?12:''} ${pro.type=="awt"?2:''}
62-
${pro.type=="dataConversion"?1:''} ${pro.type=="strings"?4:''} ${pro.type=="inheritance"?1:''}
63-
${pro.type=="input_output"?2:''} ${pro.type=="jdbc"?2:''} ${pro.type=="oop"?2:''}
64-
${pro.type=="function"?10:''}
65-
${pro.type=="2dArray"?10:''}
61+
${pro.type == "array" ? 1 : ''} ${pro.type == "2darray" ? 12 : ''} ${pro.type == "awt" ? 2 : ''}
62+
${pro.type == "dataConversion" ? 1 : ''} ${pro.type == "strings" ? 4 : ''} ${pro.type == "inheritance" ? 1 : ''}
63+
${pro.type == "input_output" ? 2 : ''} ${pro.type == "jdbc" ? 2 : ''} ${pro.type == "oop" ? 2 : ''}
64+
${pro.type == "function" ? 10 : ''}
65+
${pro.type == "2dArray" ? 10 : ''}
6666
</summary><ul></ul>`;
6767
container.appendChild(details);
6868
detailsMap[type] = details;
@@ -93,8 +93,9 @@ arr1.map(pro => {
9393
</div>
9494
9595
<br>
96-
<button class="outputbtn">Output</button>
97-
<div class="output-box" style="border:1px solid red;">
96+
<button class="outputbtn" style="cursor:none;padding:5px 20px;
97+
outline:none;">Output</button>
98+
<div class="output-box" style="padding: 10px;margin-top: 1rem;border: 1px solid grey;">
9899
99100
<div>${pro.output}</p>
100101
</div>
@@ -123,25 +124,8 @@ function copyToClipboard(txt) {
123124
}
124125

125126

126-
function search() {
127-
var input, filter, ul, li, a, i;
128-
input = document.getElementById("search");
129-
var details = document.getElementsByTagName("details");
130-
var summary = document.getElementsByTagName("summary")
131-
filter = input.value.toUpperCase();
132-
ul = document.getElementById("topic");
133-
li = ul.getElementsByTagName("li");
134-
for (i = 0; i < details.length; i++) {
135-
summary = li[i].getElementsByTagName("a")[0];
136-
if (a.innerHTML.toUpperCase().indexOf(filter) > -1) {
137-
// li[i].style.display = "";
138-
details[i].style.display=""
139-
} else {
140-
// li[i].style.display = "none";
141-
details[i].style.display="none"
142-
}
143-
}
144-
}
127+
128+
145129

146130

147131
const sButton = document.querySelectorAll(".item");

0 commit comments

Comments
 (0)
0