Skip to content

Commit 3eed690

Browse files
committed
Fix a few things
1 parent 388b2f9 commit 3eed690

File tree

5 files changed

+492
-431
lines changed

5 files changed

+492
-431
lines changed

api/modal.css

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,14 +12,16 @@
1212

1313
.st-modal {
1414
position: fixed;
15-
top: 15rem;
15+
top: 50%;
1616
width: calc(40% - 4rem);
1717
padding: 2rem;
1818
left: 30%;
1919
background-color: #fafafa;
2020
border-radius: 0.5rem;
21-
padding-top: 3rem;
21+
padding-top: 1rem;
2222
z-index: 2147483647;
23+
transform: translateY(-50%);
24+
border-top: 1rem solid #ff9f00;
2325
}
2426

2527
.st-modal h1 {

api/modals.js

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -24,9 +24,6 @@ ScratchTools.modals = {
2424
p.textContent = data.description;
2525
modal.appendChild(p);
2626

27-
var orangeBar = document.createElement("div");
28-
orangeBar.className = "st-modal-header";
29-
3027
data.components?.forEach(function (component) {
3128
if (component.type === "code") {
3229
var code = document.createElement("code");
@@ -46,7 +43,6 @@ ScratchTools.modals = {
4643
modal.appendChild(closeButton);
4744

4845
div.appendChild(modal);
49-
modal.prepend(orangeBar);
5046
document.body.appendChild(div);
5147

5248
return {

features/explore-filter/data.json

Lines changed: 46 additions & 43 deletions
Original file line numberDiff line numberDiff line change
@@ -1,48 +1,51 @@
11
{
2-
"title": "Explore Filter",
3-
"description": "Customize project and studio search results with filters on the Search, Explore, and Studio pages.",
4-
"credits": [
5-
{ "username": "Masaabu-YT", "url": "https://scratch.mit.edu/users/Masaabu-YT/" }
6-
],
7-
"type": ["Website"],
8-
"tags": ["New", "Featured"],
9-
"dynamic": true,
10-
"options": [
2+
"title": "Explore Filter",
3+
"description": "Customize project and studio search results with filters on the Search, Explore, and Studio pages.",
4+
"credits": [
5+
{
6+
"username": "Masaabu-YT",
7+
"url": "https://scratch.mit.edu/users/Masaabu-YT/"
8+
}
9+
],
10+
"type": ["Website"],
11+
"tags": ["New", "Featured"],
12+
"dynamic": true,
13+
"options": [
14+
{
15+
"id": "filter-operation",
16+
"name": "Filter operation",
17+
"type": 4,
18+
"options": [
1119
{
12-
"id": "filter-operation",
13-
"name": "Filter operation",
14-
"type": 4,
15-
"options": [
16-
{
17-
"name": "Hide",
18-
"value": "hide"
19-
},
20-
{
21-
"name": "Blur",
22-
"value": "blur"
23-
}
24-
]
20+
"name": "Blur",
21+
"value": "blur"
2522
},
2623
{
27-
"id": "keep-settings",
28-
"name": "Keep filter setting even if you change pages",
29-
"type": 1
24+
"name": "Hide",
25+
"value": "hide"
3026
}
31-
],
32-
"scripts": [
33-
{ "file": "script.js", "runOn": "/explore/*" },
34-
{ "file": "script.js", "runOn": "/search/*" },
35-
{ "file": "script.js", "runOn": "/studios/*" }
36-
],
37-
"styles": [
38-
{ "file": "style.css", "runOn": "/explore/*" },
39-
{ "file": "style.css", "runOn": "/search/*" },
40-
{ "file": "style.css", "runOn": "/studios/*" }
41-
],
42-
"resources": [
43-
{ "name": "filter-icon", "path": "/resources/filter.svg" },
44-
{ "name": "title-icon", "path": "/resources/title.svg" },
45-
{ "name": "user-icon", "path": "/resources/user.svg" },
46-
{ "name": "calendar-icon", "path": "/resources/calendar.svg" }
47-
]
48-
}
27+
]
28+
},
29+
{
30+
"id": "keep-settings",
31+
"name": "Keep filter setting even if you change pages",
32+
"type": 1
33+
}
34+
],
35+
"scripts": [
36+
{ "file": "script.js", "runOn": "/explore/*" },
37+
{ "file": "script.js", "runOn": "/search/*" },
38+
{ "file": "script.js", "runOn": "/studios/*" }
39+
],
40+
"styles": [
41+
{ "file": "style.css", "runOn": "/explore/*" },
42+
{ "file": "style.css", "runOn": "/search/*" },
43+
{ "file": "style.css", "runOn": "/studios/*" }
44+
],
45+
"resources": [
46+
{ "name": "filter-icon", "path": "/resources/filter.svg" },
47+
{ "name": "title-icon", "path": "/resources/title.svg" },
48+
{ "name": "user-icon", "path": "/resources/user.svg" },
49+
{ "name": "calendar-icon", "path": "/resources/calendar.svg" }
50+
]
51+
}

0 commit comments

Comments
 (0)