Merge pull request #78 from ItsVipra/77-profile-type-error

Fix type error in Mastodon v4.3+
This commit is contained in:
Vivien 2024-05-23 11:02:50 +02:00 committed by GitHub
commit a9e740014f
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
3 changed files with 9 additions and 3 deletions

View file

@ -89,7 +89,10 @@ function main() {
hasClasses(
n,
"detailed-status",
"status",
"status-public",
"status-unlisted",
"status-private",
"status-direct",
"conversation",
"account-authorize",
"notification",

View file

@ -51,7 +51,10 @@ export function addTypeAttribute(ActionElement) {
} else if (hasClasses(ActionElement, "notification", "notification__message")) {
ActionElement.setAttribute("protoots-type", "notification");
ActionElement.closest("article").setAttribute("protoots-type", "notification");
} else if (hasClasses(ActionElement, "account")) {
} else if (
hasClasses(ActionElement, "account") &&
!hasClasses(ActionElement, "account--minimal")
) {
ActionElement.setAttribute("protoots-type", "account");
ActionElement.closest("article").setAttribute("protoots-type", "account");
}

View file

@ -1,7 +1,7 @@
{
"manifest_version": 2,
"name": "ProToots",
"version": "1.2.2",
"version": "1.2.3",
"icons": {
"48": "icons/icon small_size/icon small_size.png",