-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathindex.html
165 lines (152 loc) · 9.81 KB
/
index.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
<!DOCTYPE html>
<html lang="en-us">
<!--
{。◕‿◕。}∩ Hello!
-->
<head>
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="chrome=1">
<meta name="HandheldFriendly" content="True">
<meta name="MobileOptimized" content="320">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<meta name="referrer" content="no-referrer">
<meta name="description" content="Bookmarklets to help you manage your personal data on social media.">
<meta property="og:title" content="Personal Data Management Tools">
<meta property="og:description" content="Bookmarklets to help you manage your personal data on social media.">
<meta property="og:image" content="https://adamdrake.github.io/pdmtools/static/img/bookmarklet-card.png">
<meta name="twitter:image" content="https://adamdrake.github.io/pdmtools/static/img/bookmarklet-card.png">
<meta name="twitter:card" content="summary_large_image">
<title>Personal Data Management Tools</title>
<!-- CSS -->
<link rel="stylesheet" href="https://adamdrake.github.io/pdmtools/static/css/style.css">
<!-- Icon -->
<link rel="shortcut icon" href="https://adamdrake.github.io/pdmtools/static/img/favbookmark.ico" id="favicon">
</head>
<body>
<section class="container">
<div class="content title">
<h1>Personal Data Management Tools</h1>
<p>Bookmarklets to help you manage your personal data on social media.</p>
</div>
<hr>
<div class="content">
<img src="https://adamdrake.github.io/pdmtools/static/img/bookmarklet.png" width="250px">
<p>Hello!</p>
<p>We're open source
<a href="https://github.com/adamdrake/pdmtools">on GitHub</a> (or just "View Source" this page!)</p>
<h2>Usage</h2>
<p>Drag the links to your bookmarks toolbar to "install," then navigate to the relevant page and click the bookmarklet
to use it.</p>
<p>You must be logged in to your account. The bookmarklets do not collect any data, only help to click buttons in
your browser. They will delete your data in the same way that you would with manual clicking. The data will
not be backed up or recoverable via the bookmarklet.</p>
<h2>Bookmarklets and Content Security Policy</h2>
<p>Some browsers block the use of bookmarklets with the intention of protecting users from malicious scripts. Firefox
is one of these. You can still use these bookmarklets by pasting the code into your browser console, or by
using an add-on such as the
<a href="https://addons.mozilla.org/en-US/firefox/addon/bookmarklets-context-menu/">bookmarklets context menu</a>.</p>
</div>
<div class="content">
<h2>Twitter</h2>
</div>
<div class="cards">
<div class="card">
<span class="bookmarklet-link">
<img src="https://adamdrake.github.io/pdmtools/static/img/bookmark-icon.png" width="25px">
<a href="javascript: (function () {function sleep(ms) {return new Promise(resolve => setTimeout(resolve, ms));};var now = new Date;var rawTweets = document.querySelectorAll('div.js-original-tweet div.content');tweets = Array.from(rawTweets).map(t => ({time: t.querySelector('div.stream-item-header small a span.js-short-timestamp').getAttribute('data-time-ms'),delete: t.querySelector('div.stream-item-header div.js-more-ProfileTweet-actions div.dropdown div.dropdown-menu ul li.js-actionDelete'),unretweet: t.querySelector('div.stream-item-footer div.js-actions div.ProfileTweet-action--retweet button.js-actionRetweet')}));async function removeTweets(max) {for (let i = 0; i < tweets.length; i++) {let stamp = new Date(parseInt(tweets[i].time));let diff = ((now - stamp) / 1000) / 3600;if (diff > max) {if (tweets[i].delete != null) {tweets[i].delete.click();await sleep(1000);document.getElementsByClassName('delete-action')[0].click();await sleep(1000);}else if (tweets[i].delete == null) {tweets[i].unretweet.click();await sleep(1000);}}}}removeTweets(prompt('Delete tweets older than __ hours:', '24'))}());">
Delete all your tweets older than a certain number of hours
</a>
</span>
<ul>
<li>
Works on your Twitter profile page: https://twitter.com/
<em>username</em>
</li>
<li>
A pop-up prompt will ask you to input the hours, e.g. "24"
</li>
</ul>
</div>
<div class="card">
<span class="bookmarklet-link">
<img src="https://adamdrake.github.io/pdmtools/static/img/bookmark-icon.png" width="25px">
<a href="javascript: (function () {
function sleep(ms) {
return new Promise(resolve => setTimeout(resolve, ms));
};
async function uncheckAll() {
var inputs = document.querySelectorAll("input[type=checkbox]");
for (var i = 0; i < inputs.length; i++) {
if (inputs[i].checked == true) {
inputs[i].click();
await sleep(1000);
}
}
}
}());">
Uncheck all of your "Interests from Twitter"
</a>
</span>
<ul>
<li>
This works on the <a href="https://mobile.twitter.com/settings/your_twitter_data/twitter_interests">Interests from Twitter section</a> of the Interests and Ads area of your Twitter settings.
</li>
</ul>
</div>
</div>
<div class="content">
<h2>LinkedIn</h2>
</div>
<div class="cards">
<div class="card">
<span class="bookmarklet-link">
<img src="https://adamdrake.github.io/pdmtools/static/img/bookmark-icon.png" width="25px">
<a href="javascript: (function () {function sleep(ms) {return new Promise(resolve => setTimeout(resolve, ms));}async function removePosts() {while (document.getElementsByClassName('control-panel-trigger').length > 0) {document.getElementsByClassName('control-panel-trigger')[0].click();await sleep(1000);document.getElementsByClassName('option-button__delete')[0].click();await sleep(1000);document.getElementsByClassName('feed-shared-decision-modal__confirm-button')[0].click();await sleep(2000);window.scrollBy(0, 20);}}removePosts();}());
">
Delete all your LinkedIn posts
</a>
</span>
<ul>
<li>
Works on: https://www.linkedin.com/in/
<em>username</em>/detail/recent-activity/
</li>
</ul>
</div>
<div class="card">
<span class="bookmarklet-link">
<img src="https://adamdrake.github.io/pdmtools/static/img/bookmark-icon.png" width="25px">
<a href="javascript: (function () {function sleep(ms) {return new Promise(resolve => setTimeout(resolve, ms));}async function deleteMessages() {while (document.getElementsByClassName('msg-thread__topcard-btn').length > 1) {document.getElementsByClassName('msg-thread__topcard-btn')[1].click();await sleep(1000);document.getElementsByClassName('msg-topcard__full-width-action-button delete')[0].click();await sleep(1000);document.getElementsByClassName('msg-modal__button confirm-delete-btn')[0].click();await sleep(1000);}}deleteMessages();}());">
Delete all your LinkedIn messages
</a>
</span>
<ul>
<li>
Works on: https://linkedin.com/messaging/
</li>
</ul>
</div>
<div class="card">
<span class="bookmarklet-link">
<img src="https://adamdrake.github.io/pdmtools/static/img/bookmark-icon.png" width="25px">
<a href="javascript: (function () {function sleep(ms) {return new Promise(resolve => setTimeout(resolve, ms));}async function removeConnections() {while (document.getElementsByClassName('search-result__result-link').length > 0) {document.getElementsByClassName('search-result__result-link')[0].click();await sleep(4000);document.getElementsByClassName('pv-s-profile-actions__overflow-toggle')[0].click();await sleep(1500);document.getElementsByClassName('pv-s-profile-actions--disconnect')[0].click();await sleep(1000);document.getElementsByClassName('pv-s-profile-actions--unfollow')[0].click();await sleep(1000);window.history.back();await sleep(2000);}}removeConnections();}());">
Delete all your LinkedIn connections
</a>
</span>
<ul>
<li>
Works on: https://linkedin.com/search/results/people/?facetNetwork=["F"]
</li>
<li>
You can apply additional search filters as desired before using bookmarklet
</li>
</ul>
</div>
</div>
<footer class="footer">
<p>Check out the
<a href="https://github.com/adamdrake/pdmtools">open source project</a> and become a contributor. 🖤</p>
</footer>
</section>
</body>
</html>