From 39288b4cb5f9167ba30932e36bd70197a5f1268f Mon Sep 17 00:00:00 2001 From: Moriz Wahl Date: Wed, 31 May 2023 18:05:29 +0200 Subject: [PATCH 1/7] fix(webapp): warnings in unit tests --- webapp/components/InviteButton/InviteButton.spec.js | 4 +++- webapp/pages/post/create.spec.js | 8 ++++++-- 2 files changed, 9 insertions(+), 3 deletions(-) diff --git a/webapp/components/InviteButton/InviteButton.spec.js b/webapp/components/InviteButton/InviteButton.spec.js index cb73ecfd1..1282c2bad 100644 --- a/webapp/components/InviteButton/InviteButton.spec.js +++ b/webapp/components/InviteButton/InviteButton.spec.js @@ -1,6 +1,8 @@ import { mount } from '@vue/test-utils' import InviteButton from './InviteButton.vue' +const localVue = global.localVue + const stubs = { 'v-popover': { template: '', @@ -26,7 +28,7 @@ describe('InviteButton.vue', () => { describe('mount', () => { const Wrapper = () => { - return mount(InviteButton, { mocks, propsData, stubs }) + return mount(InviteButton, { mocks, localVue, propsData, stubs }) } beforeEach(() => { diff --git a/webapp/pages/post/create.spec.js b/webapp/pages/post/create.spec.js index 4f786aaa9..45ac5f3f3 100644 --- a/webapp/pages/post/create.spec.js +++ b/webapp/pages/post/create.spec.js @@ -18,9 +18,13 @@ describe('create.vue', () => { }, } + const stubs = { + ContributionForm: true, + } + describe('mount', () => { const Wrapper = () => { - return mount(create, { mocks, localVue }) + return mount(create, { mocks, localVue, stubs }) } beforeEach(() => { @@ -28,7 +32,7 @@ describe('create.vue', () => { }) it('renders', () => { - expect(wrapper.findAll('.contribution-form')).toHaveLength(1) + expect(wrapper.findComponent({ name: 'ContributionForm' }).exists()).toBe(true) }) }) }) From a08d4f48aeb4d54d381022a2b1e26f369373782e Mon Sep 17 00:00:00 2001 From: entermex Date: Thu, 1 Jun 2023 23:42:09 +0200 Subject: [PATCH 2/7] refactor(webapp): changed color for event-ribbon. Co-authored-by: Elweyn --- webapp/assets/_new/styles/tokens.scss | 1 + webapp/components/Ribbon/index.vue | 4 ++-- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/webapp/assets/_new/styles/tokens.scss b/webapp/assets/_new/styles/tokens.scss index 863e0e0b7..f3e308573 100644 --- a/webapp/assets/_new/styles/tokens.scss +++ b/webapp/assets/_new/styles/tokens.scss @@ -11,6 +11,7 @@ $color-primary-inverse: rgb(241, 253, 244); $color-secondary: rgb(0, 142, 230); $color-secondary-active: rgb(10, 161, 255); $color-secondary-inverse: rgb(240, 249, 255); +$color-third: rgb(149,74,255); $color-success: rgb(23, 181, 63); $color-success-active: rgb(26, 203, 71); $color-success-inverse: rgb(241, 253, 244); diff --git a/webapp/components/Ribbon/index.vue b/webapp/components/Ribbon/index.vue index ea7fd273a..89b84e817 100644 --- a/webapp/components/Ribbon/index.vue +++ b/webapp/components/Ribbon/index.vue @@ -48,10 +48,10 @@ export default { } } .eventBg { - background-color: $color-success-active; + background-color: $color-third; &::before { - border-color: $color-success-active transparent transparent $color-success-active; + border-color: $color-third transparent transparent $color-third; } } From 75f18e60d3d358b1586cac1ed021344d7c490ba5 Mon Sep 17 00:00:00 2001 From: entermex Date: Fri, 2 Jun 2023 00:17:29 +0200 Subject: [PATCH 3/7] refactor(webapp): changed locaalized text for article ribbon. --- webapp/locales/en.json | 80 +++++++++++++++++++++--------------------- 1 file changed, 40 insertions(+), 40 deletions(-) diff --git a/webapp/locales/en.json b/webapp/locales/en.json index 45a241957..ea2947c70 100644 --- a/webapp/locales/en.json +++ b/webapp/locales/en.json @@ -12,7 +12,7 @@ "categories": { "categoryName": "Name", "name": "Topics", - "postCount": "Posts" + "postCount": "Articles" }, "dashboard": { "comments": "Comments", @@ -21,7 +21,7 @@ "name": "Dashboard", "notifications": "Notifications", "organizations": "Organizations", - "posts": "Posts", + "posts": "Articles", "projects": "Projects", "shouts": "Shouts", "users": "Users" @@ -37,7 +37,7 @@ "name": "Hashtags", "nameOfHashtag": "Name", "number": "No.", - "tagCount": "Posts", + "tagCount": "Articles", "tagCountUnique": "Users" }, "invites": { @@ -105,7 +105,7 @@ "loadMore": "load more", "name": "Name", "organization": "Organization ::: Organizations", - "post": "Post ::: Posts", + "post": "Contribution ::: Contributions", "project": "Project ::: Projects", "reportContent": "Report", "shout": "Shout ::: Shouts", @@ -272,14 +272,14 @@ "myFriends": "Users I follow", "myGroups": "By my groups", "myTopics": "My topics", - "noFilter": "Filter posts" + "noFilter": "Filter articles" }, "filterMyGroups": "Contributions in my groups", "inappropriatePicture": "This image may be inappropriate for some people.", "languageSelectLabel": "Language of your contribution", "languageSelectText": "Select Language", "newEvent": "Create a new Event", - "newPost": "Create a new Post", + "newPost": "Create a new Article", "success": "Saved!", "teaserImage": { "cropImage": "Crop image", @@ -291,7 +291,7 @@ "supportedFormats": "Insert a picture of file format JPG, PNG or GIF" }, "title": "Title", - "visibleOnlyForMembersOfGroup": "This post will only be visible to members of the “{name}” group." + "visibleOnlyForMembersOfGroup": "This contribution will only be visible to members of the “{name}” group." }, "delete": { "cancel": "Cancel", @@ -370,10 +370,10 @@ "500-default": "Internal Server Error!", "503-default": "Service Unavailable!", "back-to-index": "Back to index page!", - "cannot-edit-post": "This post cannot be edited!", + "cannot-edit-post": "This contribution cannot be edited!", "default": "An error occurred!", "group-not-found": "This group profile could not be found!", - "post-not-found": "This post could not be found!", + "post-not-found": "This contribution could not be found!", "profile-not-found": "This profile could not be found!" }, "filter-menu": { @@ -398,7 +398,7 @@ } }, "order-by": "Order by ...", - "post-type": "Post type", + "post-type": "Article type", "save": { "error": "Failed saving topic settings!", "success": "Topics saved!" @@ -500,9 +500,9 @@ "public": "Public" }, "typesOptions": { - "closed": "Closed — All posts only visible to the group's members", + "closed": "Closed — All contributions only visible to the group's members", "hidden": "Secret — Group (including the name) is completely invisible", - "public": "Public — Group and all posts are visible for all registered users" + "public": "Public — Group and all contributions are visible for all registered users" }, "update": "Save change", "updatedGroup": "The group data has been changed." @@ -601,12 +601,12 @@ }, "Post": { "disable": { - "message": "Do you really want to let the post \"{name}\" stay disabled?", - "title": "Finally Disable Post" + "message": "Do you really want to let the article \"{name}\" stay disabled?", + "title": "Finally Disable Article" }, "enable": { - "message": "Do you really want to let the post \"{name}\" stay enabled?", - "title": "Finally Enable Post" + "message": "Do you really want to let the article \"{name}\" stay enabled?", + "title": "Finally Enable Article" } }, "submit": "Confirm decision", @@ -663,12 +663,12 @@ }, "markAllAsRead": "Mark all as read", "pageLink": "All notifications", - "post": "Post or Group", + "post": "Contribution or Group", "reason": { "changed_group_member_role": "Changed your role in group …", - "commented_on_post": "Commented on your post …", + "commented_on_post": "Commented on your contribution …", "mentioned_in_comment": "Mentioned you in a comment …", - "mentioned_in_post": "Mentioned you in a post …", + "mentioned_in_post": "Mentioned you in a contribution …", "removed_user_from_group": "Removed you from group …", "user_joined_group": "Joined your group …", "user_left_group": "Left your group …" @@ -698,25 +698,25 @@ "forGroup": { "title": "For The Group “{name}”" }, - "title": "Create A New Post" + "title": "Create A New Article" }, "edited": "edited", "editPost": { "forGroup": { "title": "For The Group “{name}”" }, - "title": "Edit Your Post" + "title": "Edit Your Contribution" }, "event": "Event", "menu": { - "delete": "Delete post", - "edit": "Edit post", - "pin": "Pin post", - "pinnedSuccessfully": "Post pinned successfully!", - "unpin": "Unpin post", - "unpinnedSuccessfully": "Post unpinned successfully!" + "delete": "Delete contribution", + "edit": "Edit contribution", + "pin": "Pin contribution", + "pinnedSuccessfully": "Contribution pinned successfully!", + "unpin": "Unpin contribution", + "unpinnedSuccessfully": "Contribution unpinned successfully!" }, - "name": "Post", + "name": "Article", "pinned": "Announcement", "takeAction": { "name": "Take action" @@ -733,7 +733,7 @@ "forGroup": { "title": "In The Group “{name}”" }, - "title": "Post" + "title": "Article" } }, "profile": { @@ -802,7 +802,7 @@ "contribution": { "error": "You have already reported the contribution!", "message": "Do you really want to report the contribution \"{name}\"?", - "title": "Report Post", + "title": "Report Contribution", "type": "Contribution" }, "reason": { @@ -812,7 +812,7 @@ "options": { "advert_products_services_commercial": "Advertising products and services with commercial intent.", "criminal_behavior_violation_german_law": "Criminal behavior or violation of German law.", - "discrimination_etc": "Discriminatory posts, comments, utterances or insults.", + "discrimination_etc": "Discriminatory contributions, comments, utterances or insults.", "doxing": "The disclosure of others' personal information without their consent or threat there of (\"doxing\").", "glorific_trivia_of_cruel_inhuman_acts": "Glorification or trivialization of cruel or inhuman acts of violence.", "intentional_intimidation_stalking_persecution": "Intentional intimidation, stalking or persecution.", @@ -840,11 +840,11 @@ "for": "Searching for ", "heading": { "Group": "Group ::: Groups", - "Post": "Post ::: Posts", + "Post": "Contribution ::: Contributions", "Tag": "Hashtag ::: Hashtags", "User": "User ::: Users" }, - "hint": "What are you searching for? Use !… for posts, @… for users, &… for groups, #… for hashtags.", + "hint": "What are you searching for? Use !… for contributions, @… for users, &… for groups, #… for hashtags.", "no-results": "No results found for \"{search}\". Try a different search term!", "page": "Page", "placeholder": "Search", @@ -862,7 +862,7 @@ "empty": "So far, you have not blocked anybody.", "explanation": { "closing": "This should be sufficient for now so that blocked users can no longer bother you.", - "commenting-disabled": "Commenting is not possible at this time on this post.", + "commenting-disabled": "Commenting is not possible at this time on this contribution.", "commenting-explanation": "This can happen for several reasons, please see our ", "intro": "If another user has been blocked by you, this is what happens:", "notifications": "Blocked users will no longer receive notifications if they mention each other.", @@ -885,20 +885,20 @@ "success": "Your data was successfully updated!" }, "deleteUserAccount": { - "accountDescription": "Be aware that your Posts and Comments are important to our community. If you still choose to delete them, you have to mark them below.", - "accountWarning": "You CAN'T MANAGE and CAN'T RECOVER your Account, Posts, or Comments after deleting your account!", + "accountDescription": "Be aware that your Contributions and Comments are important to our community. If you still choose to delete them, you have to mark them below.", + "accountWarning": "You CAN'T MANAGE and CAN'T RECOVER your Account, Contributions, or Comments after deleting your account!", "accountWarningAdmin": "The account, contributions or comments can NOT BE ADMINISTERED OR RESTORED after deletion!", "accountWarningIsAdmin": "Attention! You are about to delete a user account!", "commentedCount": "Delete my {count} comment ::: Delete my {count} comments", "confirmDeleting": "Delete user account now", - "contributionsCount": "Delete my {count} post ::: Delete my {count} posts", + "contributionsCount": "Delete my {count} contribution ::: Delete my {count} contributions", "infoAdmin": "All contributions and comments of the user will be deleted additionally!", "name": "Delete user account", "pleaseConfirm": "Destructive action! Type “{confirm}” to confirm.", "success": "Account successfully deleted!" }, "download": { - "description": "Click on the button above to download the content of your posts and comments. To download the images of your posts, you have to click on the corresponding link below.", + "description": "Click on the button above to download the content of your contributions and comments. To download the images of your contributions, you have to click on the corresponding link below.", "json": "as JSON", "name": "Download Data" }, @@ -954,8 +954,8 @@ "empty": "So far, you have not muted anybody.", "explanation": { "intro": "If another user has been muted by you, this is what happens:", - "search": "Posts of muted people disappear from your search results.", - "your-perspective": "The muted person's posts will no longer appear in your news feed." + "search": "Contributions of muted people disappear from your search results.", + "your-perspective": "The muted person's contributions will no longer appear in your news feed." }, "how-to": "You can mute other users on their profile page via the content menu.", "mute": "Mute user", From 9c98f87e69a3bfafd994d5a973b3abb040b53af4 Mon Sep 17 00:00:00 2001 From: entermex Date: Fri, 2 Jun 2023 09:49:45 +0200 Subject: [PATCH 4/7] refactor(webapp): changed color a bit litter for event-ribbons --- webapp/assets/_new/styles/tokens.scss | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/webapp/assets/_new/styles/tokens.scss b/webapp/assets/_new/styles/tokens.scss index f3e308573..c01b7d2cc 100644 --- a/webapp/assets/_new/styles/tokens.scss +++ b/webapp/assets/_new/styles/tokens.scss @@ -11,7 +11,7 @@ $color-primary-inverse: rgb(241, 253, 244); $color-secondary: rgb(0, 142, 230); $color-secondary-active: rgb(10, 161, 255); $color-secondary-inverse: rgb(240, 249, 255); -$color-third: rgb(149,74,255); +$color-third: rgb(160,103,255); $color-success: rgb(23, 181, 63); $color-success-active: rgb(26, 203, 71); $color-success-inverse: rgb(241, 253, 244); From 1626b06948168bc991e7606aff4b23f7ac315311 Mon Sep 17 00:00:00 2001 From: elweyn Date: Mon, 5 Jun 2023 12:33:48 +0200 Subject: [PATCH 5/7] Revert "refactor(webapp): changed locaalized text for article ribbon." This reverts commit 75f18e60d3d358b1586cac1ed021344d7c490ba5. --- webapp/locales/en.json | 80 +++++++++++++++++++++--------------------- 1 file changed, 40 insertions(+), 40 deletions(-) diff --git a/webapp/locales/en.json b/webapp/locales/en.json index ea2947c70..45a241957 100644 --- a/webapp/locales/en.json +++ b/webapp/locales/en.json @@ -12,7 +12,7 @@ "categories": { "categoryName": "Name", "name": "Topics", - "postCount": "Articles" + "postCount": "Posts" }, "dashboard": { "comments": "Comments", @@ -21,7 +21,7 @@ "name": "Dashboard", "notifications": "Notifications", "organizations": "Organizations", - "posts": "Articles", + "posts": "Posts", "projects": "Projects", "shouts": "Shouts", "users": "Users" @@ -37,7 +37,7 @@ "name": "Hashtags", "nameOfHashtag": "Name", "number": "No.", - "tagCount": "Articles", + "tagCount": "Posts", "tagCountUnique": "Users" }, "invites": { @@ -105,7 +105,7 @@ "loadMore": "load more", "name": "Name", "organization": "Organization ::: Organizations", - "post": "Contribution ::: Contributions", + "post": "Post ::: Posts", "project": "Project ::: Projects", "reportContent": "Report", "shout": "Shout ::: Shouts", @@ -272,14 +272,14 @@ "myFriends": "Users I follow", "myGroups": "By my groups", "myTopics": "My topics", - "noFilter": "Filter articles" + "noFilter": "Filter posts" }, "filterMyGroups": "Contributions in my groups", "inappropriatePicture": "This image may be inappropriate for some people.", "languageSelectLabel": "Language of your contribution", "languageSelectText": "Select Language", "newEvent": "Create a new Event", - "newPost": "Create a new Article", + "newPost": "Create a new Post", "success": "Saved!", "teaserImage": { "cropImage": "Crop image", @@ -291,7 +291,7 @@ "supportedFormats": "Insert a picture of file format JPG, PNG or GIF" }, "title": "Title", - "visibleOnlyForMembersOfGroup": "This contribution will only be visible to members of the “{name}” group." + "visibleOnlyForMembersOfGroup": "This post will only be visible to members of the “{name}” group." }, "delete": { "cancel": "Cancel", @@ -370,10 +370,10 @@ "500-default": "Internal Server Error!", "503-default": "Service Unavailable!", "back-to-index": "Back to index page!", - "cannot-edit-post": "This contribution cannot be edited!", + "cannot-edit-post": "This post cannot be edited!", "default": "An error occurred!", "group-not-found": "This group profile could not be found!", - "post-not-found": "This contribution could not be found!", + "post-not-found": "This post could not be found!", "profile-not-found": "This profile could not be found!" }, "filter-menu": { @@ -398,7 +398,7 @@ } }, "order-by": "Order by ...", - "post-type": "Article type", + "post-type": "Post type", "save": { "error": "Failed saving topic settings!", "success": "Topics saved!" @@ -500,9 +500,9 @@ "public": "Public" }, "typesOptions": { - "closed": "Closed — All contributions only visible to the group's members", + "closed": "Closed — All posts only visible to the group's members", "hidden": "Secret — Group (including the name) is completely invisible", - "public": "Public — Group and all contributions are visible for all registered users" + "public": "Public — Group and all posts are visible for all registered users" }, "update": "Save change", "updatedGroup": "The group data has been changed." @@ -601,12 +601,12 @@ }, "Post": { "disable": { - "message": "Do you really want to let the article \"{name}\" stay disabled?", - "title": "Finally Disable Article" + "message": "Do you really want to let the post \"{name}\" stay disabled?", + "title": "Finally Disable Post" }, "enable": { - "message": "Do you really want to let the article \"{name}\" stay enabled?", - "title": "Finally Enable Article" + "message": "Do you really want to let the post \"{name}\" stay enabled?", + "title": "Finally Enable Post" } }, "submit": "Confirm decision", @@ -663,12 +663,12 @@ }, "markAllAsRead": "Mark all as read", "pageLink": "All notifications", - "post": "Contribution or Group", + "post": "Post or Group", "reason": { "changed_group_member_role": "Changed your role in group …", - "commented_on_post": "Commented on your contribution …", + "commented_on_post": "Commented on your post …", "mentioned_in_comment": "Mentioned you in a comment …", - "mentioned_in_post": "Mentioned you in a contribution …", + "mentioned_in_post": "Mentioned you in a post …", "removed_user_from_group": "Removed you from group …", "user_joined_group": "Joined your group …", "user_left_group": "Left your group …" @@ -698,25 +698,25 @@ "forGroup": { "title": "For The Group “{name}”" }, - "title": "Create A New Article" + "title": "Create A New Post" }, "edited": "edited", "editPost": { "forGroup": { "title": "For The Group “{name}”" }, - "title": "Edit Your Contribution" + "title": "Edit Your Post" }, "event": "Event", "menu": { - "delete": "Delete contribution", - "edit": "Edit contribution", - "pin": "Pin contribution", - "pinnedSuccessfully": "Contribution pinned successfully!", - "unpin": "Unpin contribution", - "unpinnedSuccessfully": "Contribution unpinned successfully!" + "delete": "Delete post", + "edit": "Edit post", + "pin": "Pin post", + "pinnedSuccessfully": "Post pinned successfully!", + "unpin": "Unpin post", + "unpinnedSuccessfully": "Post unpinned successfully!" }, - "name": "Article", + "name": "Post", "pinned": "Announcement", "takeAction": { "name": "Take action" @@ -733,7 +733,7 @@ "forGroup": { "title": "In The Group “{name}”" }, - "title": "Article" + "title": "Post" } }, "profile": { @@ -802,7 +802,7 @@ "contribution": { "error": "You have already reported the contribution!", "message": "Do you really want to report the contribution \"{name}\"?", - "title": "Report Contribution", + "title": "Report Post", "type": "Contribution" }, "reason": { @@ -812,7 +812,7 @@ "options": { "advert_products_services_commercial": "Advertising products and services with commercial intent.", "criminal_behavior_violation_german_law": "Criminal behavior or violation of German law.", - "discrimination_etc": "Discriminatory contributions, comments, utterances or insults.", + "discrimination_etc": "Discriminatory posts, comments, utterances or insults.", "doxing": "The disclosure of others' personal information without their consent or threat there of (\"doxing\").", "glorific_trivia_of_cruel_inhuman_acts": "Glorification or trivialization of cruel or inhuman acts of violence.", "intentional_intimidation_stalking_persecution": "Intentional intimidation, stalking or persecution.", @@ -840,11 +840,11 @@ "for": "Searching for ", "heading": { "Group": "Group ::: Groups", - "Post": "Contribution ::: Contributions", + "Post": "Post ::: Posts", "Tag": "Hashtag ::: Hashtags", "User": "User ::: Users" }, - "hint": "What are you searching for? Use !… for contributions, @… for users, &… for groups, #… for hashtags.", + "hint": "What are you searching for? Use !… for posts, @… for users, &… for groups, #… for hashtags.", "no-results": "No results found for \"{search}\". Try a different search term!", "page": "Page", "placeholder": "Search", @@ -862,7 +862,7 @@ "empty": "So far, you have not blocked anybody.", "explanation": { "closing": "This should be sufficient for now so that blocked users can no longer bother you.", - "commenting-disabled": "Commenting is not possible at this time on this contribution.", + "commenting-disabled": "Commenting is not possible at this time on this post.", "commenting-explanation": "This can happen for several reasons, please see our ", "intro": "If another user has been blocked by you, this is what happens:", "notifications": "Blocked users will no longer receive notifications if they mention each other.", @@ -885,20 +885,20 @@ "success": "Your data was successfully updated!" }, "deleteUserAccount": { - "accountDescription": "Be aware that your Contributions and Comments are important to our community. If you still choose to delete them, you have to mark them below.", - "accountWarning": "You CAN'T MANAGE and CAN'T RECOVER your Account, Contributions, or Comments after deleting your account!", + "accountDescription": "Be aware that your Posts and Comments are important to our community. If you still choose to delete them, you have to mark them below.", + "accountWarning": "You CAN'T MANAGE and CAN'T RECOVER your Account, Posts, or Comments after deleting your account!", "accountWarningAdmin": "The account, contributions or comments can NOT BE ADMINISTERED OR RESTORED after deletion!", "accountWarningIsAdmin": "Attention! You are about to delete a user account!", "commentedCount": "Delete my {count} comment ::: Delete my {count} comments", "confirmDeleting": "Delete user account now", - "contributionsCount": "Delete my {count} contribution ::: Delete my {count} contributions", + "contributionsCount": "Delete my {count} post ::: Delete my {count} posts", "infoAdmin": "All contributions and comments of the user will be deleted additionally!", "name": "Delete user account", "pleaseConfirm": "Destructive action! Type “{confirm}” to confirm.", "success": "Account successfully deleted!" }, "download": { - "description": "Click on the button above to download the content of your contributions and comments. To download the images of your contributions, you have to click on the corresponding link below.", + "description": "Click on the button above to download the content of your posts and comments. To download the images of your posts, you have to click on the corresponding link below.", "json": "as JSON", "name": "Download Data" }, @@ -954,8 +954,8 @@ "empty": "So far, you have not muted anybody.", "explanation": { "intro": "If another user has been muted by you, this is what happens:", - "search": "Contributions of muted people disappear from your search results.", - "your-perspective": "The muted person's contributions will no longer appear in your news feed." + "search": "Posts of muted people disappear from your search results.", + "your-perspective": "The muted person's posts will no longer appear in your news feed." }, "how-to": "You can mute other users on their profile page via the content menu.", "mute": "Mute user", From 93a679c17a92e38ee2a00b2723d131b2b2a29c7b Mon Sep 17 00:00:00 2001 From: elweyn Date: Mon, 5 Jun 2023 12:57:15 +0200 Subject: [PATCH 6/7] Add background color definitions Add background ribbon colors Co-authored-by: Tirokk Co-authored-by: entermex --- webapp/assets/_new/styles/tokens.scss | 13 ++++++++++++- webapp/components/Ribbon/index.vue | 8 ++++---- 2 files changed, 16 insertions(+), 5 deletions(-) diff --git a/webapp/assets/_new/styles/tokens.scss b/webapp/assets/_new/styles/tokens.scss index c01b7d2cc..22e0214ff 100644 --- a/webapp/assets/_new/styles/tokens.scss +++ b/webapp/assets/_new/styles/tokens.scss @@ -11,7 +11,6 @@ $color-primary-inverse: rgb(241, 253, 244); $color-secondary: rgb(0, 142, 230); $color-secondary-active: rgb(10, 161, 255); $color-secondary-inverse: rgb(240, 249, 255); -$color-third: rgb(160,103,255); $color-success: rgb(23, 181, 63); $color-success-active: rgb(26, 203, 71); $color-success-inverse: rgb(241, 253, 244); @@ -91,6 +90,9 @@ $background-color-primary-inverse: rgb(241, 253, 244); $background-color-secondary: rgb(0, 142, 230); $background-color-secondary-active: rgb(10, 161, 255); $background-color-secondary-inverse: rgb(240, 249, 255); +$background-color-third: rgb(126, 82, 204); +$background-color-third-active: rgb(160, 103, 255); +$background-color-third-inverse: rgb(239, 230, 255); $background-color-success: rgb(23, 181, 63); $background-color-success-active: rgb(26, 203, 71); $background-color-success-inverse: rgb(241, 253, 244); @@ -396,3 +398,12 @@ $color-toast-orange: $color-warning; $color-toast-yellow: $color-yellow; $color-toast-blue: $color-secondary; $color-toast-green: $color-success; + +/** + * @tokens Ribbon Color + */ + +$color-ribbon-event: $background-color-third; +$color-ribbon-event-active: $background-color-third-active; +$color-ribbon-article: $background-color-secondary; +$color-ribbon-article-active: $background-color-secondary-active; \ No newline at end of file diff --git a/webapp/components/Ribbon/index.vue b/webapp/components/Ribbon/index.vue index 89b84e817..8595c0f5d 100644 --- a/webapp/components/Ribbon/index.vue +++ b/webapp/components/Ribbon/index.vue @@ -25,7 +25,7 @@ export default { padding: $size-ribbon $size-ribbon; border-radius: $border-radius-small 0 0 $border-radius-small; color: $color-neutral-100; - background-color: $background-color-secondary-active; + background-color: $color-ribbon-article-active; font-size: $font-size-x-small; font-weight: $font-weight-bold; @@ -36,7 +36,7 @@ export default { bottom: -$size-ribbon; border-width: $border-size-large 4px $border-size-large $border-size-large; border-style: solid; - border-color: $background-color-secondary transparent transparent $background-color-secondary; + border-color: $color-ribbon-article transparent transparent $color-ribbon-article; } &.--pinned { @@ -48,10 +48,10 @@ export default { } } .eventBg { - background-color: $color-third; + background-color: $color-ribbon-event-active; &::before { - border-color: $color-third transparent transparent $color-third; + border-color: $color-ribbon-event transparent transparent $color-ribbon-event; } } From 277e53ded58f3851721bcabceb05fa8c6f21b1b8 Mon Sep 17 00:00:00 2001 From: elweyn Date: Mon, 5 Jun 2023 13:03:46 +0200 Subject: [PATCH 7/7] Change ribbon text from 'post' to 'article' Co-authored-by: Tirokk Co-authored-by: entermex --- webapp/locales/en.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/webapp/locales/en.json b/webapp/locales/en.json index 45a241957..70969ac8c 100644 --- a/webapp/locales/en.json +++ b/webapp/locales/en.json @@ -716,7 +716,7 @@ "unpin": "Unpin post", "unpinnedSuccessfully": "Post unpinned successfully!" }, - "name": "Post", + "name": "Article", "pinned": "Announcement", "takeAction": { "name": "Take action"