Skip to content
This repository was archived by the owner on May 13, 2018. It is now read-only.

Commit 002db04

Browse files
committed
タイトル変更機能追加
1 parent fa3a1ea commit 002db04

4 files changed

Lines changed: 14 additions & 1 deletion

File tree

Dialog.js

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -38,9 +38,17 @@ window.addEventListener("DOMContentLoaded", () => {
3838

3939
onChange: (watcher) => {
4040
base.Database.get(base.Database.ONCE, `users/${watcher.newValue}`, (res) => {
41+
console.log(res);
42+
4143
DOM("#Dialogs_Profile_InfoViewer_Content_Photo").dataset.uid = watcher.newValue,
4244
DOM("#Dialogs_Profile_InfoViewer_Content_Info_Name").textContent = res.userName,
4345
DOM("#Dialogs_Profile_InfoViewer_Content_Info_Detail").textContent = res.detail;
46+
47+
if (res.links) {
48+
for (let i = 0; i < res.links.length; i++) {
49+
50+
}
51+
}
4452
});
4553
}
4654
});

Main.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -78,6 +78,7 @@ window.addEventListener("DOMContentLoaded", () => {
7878
!DOM("#Drawer") || DOM("#Drawer").classList.remove("is-visible"),
7979
!DOM("$Div.mdl-layout__obfuscator") || DOM("$Div.mdl-layout__obfuscator").classList.remove("is-visible");
8080

81+
if (DOM("$IFrame#Page").contentWindow.location.pathname != "/SimpleThread/Thread/Viewer/") DOM("#Header_Title").textContent = "Simple Thread";
8182
DOM("#Screens_Loading").setAttribute("Disabled", "");
8283
});
8384

Thread/Viewer/Viewer.js

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -37,6 +37,10 @@ window.addEventListener("DOMContentLoaded", () => {
3737
DOM('$Style[UUID="Thread_Post_Header_ActorPhoto--Manager"]').textContent = photoStyles.join("\r\n");
3838
});
3939

40+
base.Database.get(base.Database.INTERVAL, "threads/" + querys.TID, (res) => {
41+
doc.querySelector("#Header_Title").textContent = `Simple Thread == ${res.title}`;
42+
});
43+
4044
base.Database.get(base.Database.INTERVAL, "threads/" + querys.TID + "/data", (res) => {
4145
res = res.filter((post, index, parent) => {
4246
if (post) {

index.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,7 @@
4545
<Div Class = "mdl-layout mdl-js-layout mdl-layout--fixed-header">
4646
<Header ID = "Header" Class = "mdl-layout__header">
4747
<Div Class = "mdl-layout__header-row">
48-
<Span Class = "mdl-layout-title">Simple Thread</Span>
48+
<Span ID = "Header_Title" Class = "mdl-layout-title">Simple Thread</Span>
4949
<Div Class = "mdl-layout-spacer"></Div>
5050

5151
<Nav Class = "mdl-navigation">

0 commit comments

Comments
 (0)