From 5b56b6b9fdd9ad82a8f1c24d03024be0e7902c80 Mon Sep 17 00:00:00 2001 From: tusooa Date: Tue, 17 Jan 2023 19:55:16 -0500 Subject: [PATCH 01/12] Populate user card on receiving chats --- src/modules/chats.js | 1 + 1 file changed, 1 insertion(+) diff --git a/src/modules/chats.js b/src/modules/chats.js index f28c260391..0f1540db2f 100644 --- a/src/modules/chats.js +++ b/src/modules/chats.js @@ -65,6 +65,7 @@ const chats = { const newChatMessageSideEffects = (chat) => { maybeShowChatNotification(store, chat) } + commit('addNewUsers', chats.map(k => k.account).filter(k => k)) commit('addNewChats', { dispatch, chats, rootGetters, newChatMessageSideEffects }) }, updateChat ({ commit }, { chat }) { From d1876503bc560b9c62d03e219021593cb954fcf4 Mon Sep 17 00:00:00 2001 From: tusooa Date: Fri, 20 Jan 2023 12:33:19 -0500 Subject: [PATCH 02/12] Display delete status errors --- src/i18n/en.json | 1 + src/modules/statuses.js | 14 ++++++++++++-- src/services/api/api.service.js | 5 +++-- 3 files changed, 16 insertions(+), 4 deletions(-) diff --git a/src/i18n/en.json b/src/i18n/en.json index 1ee1147ad3..5e653ad8c1 100644 --- a/src/i18n/en.json +++ b/src/i18n/en.json @@ -844,6 +844,7 @@ "favorites": "Favorites", "repeats": "Repeats", "delete": "Delete status", + "delete_error": "Error deleting status: {0}", "edit": "Edit status", "edited_at": "(last edited {time})", "pin": "Pin on profile", diff --git a/src/modules/statuses.js b/src/modules/statuses.js index 77dd7e1c2d..93a4a957c5 100644 --- a/src/modules/statuses.js +++ b/src/modules/statuses.js @@ -615,9 +615,19 @@ const statuses = { fetchStatusHistory ({ rootState, dispatch }, status) { return apiService.fetchStatusHistory({ status }) }, - deleteStatus ({ rootState, commit }, status) { - commit('setDeleted', { status }) + deleteStatus ({ rootState, commit, dispatch }, status) { apiService.deleteStatus({ id: status.id, credentials: rootState.users.currentUser.credentials }) + .then((_) => { + commit('setDeleted', { status }) + }) + .catch((e) => { + dispatch('pushGlobalNotice', { + level: 'error', + messageKey: 'status.delete_error', + messageArgs: [e.message], + timeout: 5000 + }) + }) }, deleteStatusById ({ rootState, commit }, id) { const status = rootState.statuses.allStatusesObject[id] diff --git a/src/services/api/api.service.js b/src/services/api/api.service.js index af12265e89..609f6790ae 100644 --- a/src/services/api/api.service.js +++ b/src/services/api/api.service.js @@ -923,8 +923,9 @@ const editStatus = ({ } const deleteStatus = ({ id, credentials }) => { - return fetch(MASTODON_DELETE_URL(id), { - headers: authHeaders(credentials), + return promisedRequest({ + url: MASTODON_DELETE_URL(id), + credentials, method: 'DELETE' }) } From ebf3a2de30e071abd1e76e9992e8d94d6cdfa32a Mon Sep 17 00:00:00 2001 From: Pleroma Renovate Bot Date: Fri, 27 Jan 2023 09:08:52 +0000 Subject: [PATCH 03/12] Update dependency cropperjs to v1.5.13 --- package.json | 2 +- yarn.lock | 8 ++++---- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/package.json b/package.json index 557672ea6e..8d2833ae6a 100644 --- a/package.json +++ b/package.json @@ -30,7 +30,7 @@ "body-scroll-lock": "3.1.5", "chromatism": "3.0.0", "click-outside-vue3": "4.0.1", - "cropperjs": "1.5.12", + "cropperjs": "1.5.13", "escape-html": "1.0.3", "js-cookie": "3.0.1", "localforage": "1.10.0", diff --git a/yarn.lock b/yarn.lock index 85a8155f3f..a2393ba1b6 100644 --- a/yarn.lock +++ b/yarn.lock @@ -3268,10 +3268,10 @@ cosmiconfig@^7.1.0: path-type "^4.0.0" yaml "^1.10.0" -cropperjs@1.5.12: - version "1.5.12" - resolved "https://registry.yarnpkg.com/cropperjs/-/cropperjs-1.5.12.tgz#d9c0db2bfb8c0d769d51739e8f916bbc44e10f50" - integrity sha512-re7UdjE5UnwdrovyhNzZ6gathI4Rs3KGCBSc8HCIjUo5hO42CtzyblmWLj6QWVw7huHyDMfpKxhiO2II77nhDw== +cropperjs@1.5.13: + version "1.5.13" + resolved "https://registry.yarnpkg.com/cropperjs/-/cropperjs-1.5.13.tgz#eb1682f01d17c70ed5244317091d745c9a249ef8" + integrity sha512-by7jKAo73y5/Do0K6sxdTKHgndY0NMjG2bEdgeJxycbcmHuCiMXqw8sxy5C5Y5WTOTcDGmbT7Sr5CgKOXR06OA== cross-spawn@7.0.3, cross-spawn@^7.0.2: version "7.0.3" From 796a006a99cd2ee7dcf7ea4e8e54e8c0ea68bb25 Mon Sep 17 00:00:00 2001 From: Pleroma Renovate Bot Date: Sun, 29 Jan 2023 09:08:07 +0000 Subject: [PATCH 04/12] Update dependency qrcode to v1.5.1 --- package.json | 2 +- yarn.lock | 8 ++++---- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/package.json b/package.json index df15f5775f..a9c07814cd 100644 --- a/package.json +++ b/package.json @@ -37,7 +37,7 @@ "parse-link-header": "2.0.0", "phoenix": "1.6.2", "punycode.js": "2.3.0", - "qrcode": "1.5.0", + "qrcode": "1.5.1", "querystring-es3": "0.2.1", "url": "0.11.0", "utf8": "3.0.0", diff --git a/yarn.lock b/yarn.lock index 5693c2aea3..fe85b5ea44 100644 --- a/yarn.lock +++ b/yarn.lock @@ -7341,10 +7341,10 @@ qjobs@^1.2.0: resolved "https://registry.yarnpkg.com/qjobs/-/qjobs-1.2.0.tgz#c45e9c61800bd087ef88d7e256423bdd49e5d071" integrity sha512-8YOJEHtxpySA3fFDyCRxA+UUV+fA+rTWnuWvylOK/NCjhY+b4ocCtmu8TtsWb+mYeU+GCHf/S66KZF/AsteKHg== -qrcode@1.5.0: - version "1.5.0" - resolved "https://registry.yarnpkg.com/qrcode/-/qrcode-1.5.0.tgz#95abb8a91fdafd86f8190f2836abbfc500c72d1b" - integrity sha512-9MgRpgVc+/+47dFvQeD6U2s0Z92EsKzcHogtum4QB+UNd025WOJSHvn/hjk9xmzj7Stj95CyUAs31mrjxliEsQ== +qrcode@1.5.1: + version "1.5.1" + resolved "https://registry.yarnpkg.com/qrcode/-/qrcode-1.5.1.tgz#0103f97317409f7bc91772ef30793a54cd59f0cb" + integrity sha512-nS8NJ1Z3md8uTjKtP+SGGhfqmTCs5flU/xR623oI0JX+Wepz9R8UrRVCTBTJm3qGw3rH6jJ6MUHjkDx15cxSSg== dependencies: dijkstrajs "^1.0.1" encode-utf8 "^1.0.3" From e516eee479cf6e943b6fc43d0a9d18793c141ba0 Mon Sep 17 00:00:00 2001 From: tusooa Date: Tue, 21 Feb 2023 00:39:16 -0500 Subject: [PATCH 05/12] Make block & mute lists able to load more --- src/components/list/list.vue | 6 ++- .../tabs/mutes_and_blocks_tab.js | 7 +++- src/hocs/with_load_more/with_load_more.jsx | 2 +- src/modules/users.js | 38 ++++++++++++++++--- src/services/api/api.service.js | 16 ++++++-- 5 files changed, 55 insertions(+), 14 deletions(-) diff --git a/src/components/list/list.vue b/src/components/list/list.vue index f17766b47b..a3562c5d75 100644 --- a/src/components/list/list.vue +++ b/src/components/list/list.vue @@ -1,9 +1,13 @@