Skip to content

Commit 1fc0a23

Browse files
committed
feat(windows): initial add for windows badges
also hide ion-button-effect and change alert buttons to full width references #5565
1 parent 6cd0c45 commit 1fc0a23

File tree

4 files changed

+34
-2
lines changed

4 files changed

+34
-2
lines changed

ionic/components.wp.scss

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,5 +8,6 @@
88
"components/app/app.wp",
99
"components/action-sheet/action-sheet.wp",
1010
"components/alert/alert.wp",
11+
"components/badge/badge.wp",
1112
"components/button/button.wp",
1213
"components/toolbar/toolbar.wp";

ionic/components/alert/alert.wp.scss

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -226,7 +226,7 @@ $alert-wp-buttons-justify-content: flex-end !default;
226226
flex-wrap: wrap-reverse;
227227

228228
&.vertical .alert-button {
229-
margin-left: 50.5%;
229+
width: 100%;
230230
margin-top: 5px;
231231

232232
&:first-child:not(:only-child) {

ionic/components/badge/badge.wp.scss

Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
@import "./badge";
2+
3+
// Windows Badge
4+
// --------------------------------------------------
5+
6+
$badge-wp-border-radius: 0 !default;
7+
$badge-wp-background-color: map-get($colors-wp, primary) !default;
8+
9+
10+
ion-badge {
11+
border-radius: $badge-wp-border-radius;
12+
background-color: $badge-wp-background-color;
13+
color: color-inverse($badge-wp-background-color);
14+
}
15+
16+
17+
// Generate Windows Badge Colors
18+
// --------------------------------------------------
19+
20+
@each $color-name, $color-value in $colors-wp {
21+
22+
.badge-#{$color-name} {
23+
background-color: $color-value;
24+
color: color-inverse($color-value);
25+
}
26+
27+
}

ionic/components/button/button.wp.scss

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -231,14 +231,18 @@ $button-wp-small-icon-font-size: 1.4em !default;
231231
border-color: transparent;
232232

233233
&:hover:not(.disable-hover) {
234-
border-color: transparent;
234+
border-color: transparent;
235235
}
236236
}
237237

238238
.button-icon-only {
239239
padding: 0;
240240
}
241241

242+
ion-button-effect {
243+
// wp does not use the button effect
244+
display: none;
245+
}
242246

243247
// Generate Windows Button Colors
244248
// --------------------------------------------------

0 commit comments

Comments
 (0)