You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: hub/apps/publish/microsoft-store-app-badge.md
+18-5Lines changed: 18 additions & 5 deletions
Original file line number
Diff line number
Diff line change
@@ -9,7 +9,7 @@ ms.localizationpriority: medium
9
9
10
10
# The new Microsoft Store badges are here
11
11
12
-
We've refreshed the Microsoft Store badge to feature the new logo, with a more refined call-to-action to give users more confidence to acquire your app. These will go live on our[badge creator page](https://apps.microsoft.com/badge) on **August 7, 2024** in all supported languages.
12
+
We've refreshed the Microsoft Store badge to feature the new logo, with a more refined call-to-action to give users more confidence to acquire your app. Generate the badge for your app on the[badge creator page](https://apps.microsoft.com/badge).
13
13
14
14
## How do I get the new badge?
15
15
@@ -25,12 +25,25 @@ If you're a developer with an app published on the Microsoft Store, and if you'v
25
25
| <imgsrc="../images/new-badge-dark.png"width="256"alt="New Store badge for dark mode"> | <imgsrc="../images/new-badge-light.png"width="256"alt="New Store badge for light mode"> |
26
26
| ------------- | ------------- |
27
27
28
-
29
28
If you don't have a badge yet, visit the [Microsoft Store badge creator page](https://apps.microsoft.com/badge) to choose the options that work best for your badge and hit Generate to create one for your app.
30
29
30
+
## Customizing the badge appearance on your site
31
+
The badge is a [web component](https://developer.mozilla.org/en-US/docs/Web/API/Web_components) that automatically detects the user's language and theme and displays the appropriate badge image. As a web component, the badge won't inherit styles from your page.
32
+
33
+
But you may need to customize the appearance of the badge. For example, you may wish to adjust the size of the badge on your page to match other button sizes. To do this, you can use a [CSS part selector](https://developer.mozilla.org/en-US/docs/Web/CSS/::part) to style the badge:
34
+
35
+
```css
36
+
/* The badge should have a max width of 200px to match other buttons on my page.
37
+
The badge image preserves aspect ratio, so changing the max-width will also affect the badge height.
38
+
*/
39
+
ms-store-badge::part(img) {
40
+
max-width: 200px;
41
+
}
42
+
```
43
+
31
44
### Some tips to make the most of your badge
32
-
*We'll have a different badge color for dark and light modes, and you should pick what works best for your website or allow it to be automatically detected.
33
-
* We recommend using the standard JavaScript-based badge, but if your website doesn't use JavaScript, you'll be able to create a non-JS version too.
45
+
*The badge will detect light or dark mode automatically based on the user's preference. However, you can optionally override the badge theme on the [badge creator page](https://apps.microsoft.com/badge).
46
+
* We recommend using badge web component because it detects the user's theme and language. But if you need to display your app badge on a page that doesn't support JavaScript, such as GitHub markdown pages, you can optionally create a non-JS version of the badge on the [badge creator page](https://apps.microsoft.com/badge).
34
47
* Remember to add a campaign ID with a unique string so you can better track your traffic sources on the Microsoft Store Partner Center dashboard.
35
48
36
-
Please avoid altering the badge – including changing the color, the text, or the elements within.
49
+
Please avoid altering the badge color, text, or elements within.
0 commit comments