diff --git a/source/css/popup.css b/source/css/popup.css index ed56c81..488c95d 100644 --- a/source/css/popup.css +++ b/source/css/popup.css @@ -1,21 +1,22 @@ body { - font-size: 100%; + font-size: 100%; } #app { - min-width: 45em; - margin: 15px; + min-width: 45em; + /* min-height: 175px; */ + margin: 15px; } #icon { - max-height: 26px; - vertical-align: middle; + max-height: 26px; + vertical-align: middle; } table.archive-results .row { - /* table-layout: fixed; */ - width: 90%; - max-width: 100px; + /* table-layout: fixed; */ + width: 90%; + max-width: 100px; } /* .archive-results td { @@ -27,7 +28,38 @@ table.archive-results .row { } */ table td { - word-wrap: break-word; - overflow-wrap: break-word; - padding: 5px; + word-wrap: break-word; + overflow-wrap: break-word; + padding: 5px; +} + +/* MODAL */ + +.modal div.modal-content { + padding: 5px; + padding-left: 10px; + padding-right: 10px; +} + +#archiveModal { + max-height: 90%; + font-size: 0.83em; +} + +#archiveModal select { + font-size: initial; + width: auto; + display: inline; + margin-left: 10px; +} + +.form-guide { + font-size: 1rem; + color: #9e9e9e; + margin-right: 10px; +} + +.switch label { + color: black; + font-size: 1.1rem; } diff --git a/source/js/background.js b/source/js/background.js index fc974a2..cb87685 100644 --- a/source/js/background.js +++ b/source/js/background.js @@ -11,7 +11,8 @@ const LOGIN_FAILED = `Please login before using this feature.`; chrome.runtime.onMessage.addListener(((r, s, sendResponse) => { processMessages(r, s) .then(response => { - console.log(`SUCCESS (${r.action}): ${JSON.stringify(response).slice(0,50)}`) + // console.log(`SUCCESS (${r.action}): ${JSON.stringify(response).slice(0,50)}`) + console.log(`SUCCESS (${r.action}): ${JSON.stringify(response)}`) sendResponse({ status: "success", result: response }) } ).catch(error => { @@ -151,7 +152,11 @@ function submitUrlArchive(url, accessToken) { 'Content-Type': 'application/json', 'Authorization': `Bearer ${accessToken}` }, - body: JSON.stringify({ url }), + body: JSON.stringify({ + url, + group_id: null, + tags: [] + }), }) .then(getJsonOrError) .then(response => resolve(response)) diff --git a/source/manifest.json b/source/manifest.json index 5217588..5699a1d 100644 --- a/source/manifest.json +++ b/source/manifest.json @@ -1,6 +1,6 @@ { "name": "Auto-archiver extension", - "version": "0.1.1", + "version": "0.3.0", "description": "A gateway to effective archiving of online content, including behind private platforms. ", "homepage_url": "https://github.com/bellingcat/auto-archiver-extension", "manifest_version": 3, diff --git a/source/vue/Popup.vue b/source/vue/Popup.vue index 9ecdba1..0db2b76 100644 --- a/source/vue/Popup.vue +++ b/source/vue/Popup.vue @@ -1,60 +1,103 @@ \ No newline at end of file + diff --git a/source/vue/TaskItem.vue b/source/vue/TaskItem.vue index ddd4493..d8b4742 100644 --- a/source/vue/TaskItem.vue +++ b/source/vue/TaskItem.vue @@ -94,8 +94,8 @@ export default { return this.task?.result?.media?.filter(m => m?.properties?.id == "_final_media")?.at(0)?.urls?.at(0) || ''; }, readbleDate() { - if (this.task?.result?._processed_at) { - return new Date(this.task.result._processed_at * 1e3).toISOString().slice(0, 19); + if (this.task?.result?.metadata?._processed_at) { + return new Date(this.task.result.metadata._processed_at * 1e3).toISOString().slice(0, 19); } }, taskPending() {