From 136d7c19d9fc8eccb4b4d5d7c660db639b3cfd9b Mon Sep 17 00:00:00 2001 From: Oleg Isonen Date: Tue, 10 Jun 2025 17:47:39 +0100 Subject: [PATCH] fix: Improve made with webstudio badge tooltip (#5266) Trying to explain that user can change the styles and position and everything about that badge. ## Steps for reproduction 1. click button 2. expect xyz ## Code Review - [ ] hi @kof, I need you to do - conceptual review (architecture, feature-correctness) - detailed review (read every line) - test it on preview ## Before requesting a review - [ ] made a self-review - [ ] added inline comments where things may be not obvious (the "why", not "what") ## Before merging - [ ] tested locally and on preview environment (preview dev login: 0000) - [ ] updated [test cases](https://github.com/webstudio-is/webstudio/blob/main/apps/builder/docs/test-cases.md) document - [ ] added tests - [ ] if any new env variables are added, added them to `.env` file --- apps/builder/app/builder/features/topbar/publish.tsx | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/apps/builder/app/builder/features/topbar/publish.tsx b/apps/builder/app/builder/features/topbar/publish.tsx index 5693bc64af..4348a6fc38 100644 --- a/apps/builder/app/builder/features/topbar/publish.tsx +++ b/apps/builder/app/builder/features/topbar/publish.tsx @@ -273,7 +273,7 @@ const $usedProFeatures = computed( const badgeFeature = 'No "Built with Webstudio" badge'; // Badge should be rendered on free sites on every page. features.set(badgeFeature, { - info: "Adding the badge to your homepage helps us offer a free version of the service. Please open the Components panel by clicking the “+” icon on the left, and add the “Built with Webstudio” component to your page. Feel free to adjust the badge’s styles to match your design.", + info: "Adding the badge to your homepage helps us offer a free version of the service. Please open the Components panel by clicking the “+” icon on the left, and add the “Built with Webstudio” component to your page. Feel free to adjust the badge's style to match your design - after all, it's just a link, and you can place it wherever you like.", }); // We want to check the badge only on the home page const homePageInstanceIds = findTreeInstanceIds( @@ -288,7 +288,8 @@ const $usedProFeatures = computed( for (const prop of props ?? []) { if ( prop.name === "href" && - prop.value === "https://webstudio.is/?via=badge" + typeof prop.value === "string" && + prop.value.includes("https://webstudio.is") ) { features.delete(badgeFeature); }