Skip to content
This repository has been archived by the owner on Oct 12, 2023. It is now read-only.

Commit

Permalink
Fix alignment of items inside button and action trigger button (#85)
Browse files Browse the repository at this point in the history
* Fix alignment of items inside button and action trigger button

* fix icon flex
  • Loading branch information
PatoBeltran authored Jul 22, 2019
1 parent c78768d commit 204fea4
Show file tree
Hide file tree
Showing 8 changed files with 21 additions and 13 deletions.
4 changes: 4 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,9 @@
# CHANGELOG

## v6.3.3
### Fixed
- Fix alignment of items inside action trigger button and buttons.

## v6.3.2
### Fixed
- Fix styling on action trigger button right icon.
Expand Down
8 changes: 8 additions & 0 deletions lib/common/_mixins.scss
Original file line number Diff line number Diff line change
Expand Up @@ -69,6 +69,14 @@
} @else if $option == 'flex-row' {
display: flex;
flex-direction: row;
} @else if $option == 'inline-flex' {
display: inline-flex;
} @else if $option == 'inline-flex-column' {
display: inline-flex;
flex-direction: column;
} @else if $option == 'inline-flex-row' {
display: inline-flex;
flex-direction: row;
} @else if $option == 'display-none' {
display: none;
}
Expand Down
1 change: 0 additions & 1 deletion lib/components/ActionTrigger/ActionTrigger.module.scss
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,6 @@ $line-height: 4.5*$grid-size;
vertical-align: top;
font-size: $font-size-default;
margin-left: 2*$grid-size;
line-height: 100%;

max-width: 50*$grid-size;
overflow: hidden;
Expand Down
9 changes: 3 additions & 6 deletions lib/components/Button/Button.module.scss
Original file line number Diff line number Diff line change
Expand Up @@ -7,10 +7,12 @@ $line-height: 8*$grid-size;
$outline-focus-border-width: 1px;

:global(.btn-primary), .method-btn-primary, :global(.btn-danger), .method-btn-danger, :global(.btn), .method-btn {
@include md-box(inline-block, relative);
@include md-box(inline-flex-row, relative);
font-family: $font-family-default;
font-size: $font-size-default;
line-height: $line-height;
justify-content: center;
align-items: center;

height: 8*$grid-size;
padding-left: 5*$grid-size;
Expand Down Expand Up @@ -133,9 +135,4 @@ $outline-focus-border-width: 1px;
background-color: themed('color-bg-btn-danger-disabled');
}
}
}

.label {
line-height: 100%;
vertical-align: text-top;
}
4 changes: 1 addition & 3 deletions lib/components/Button/Button.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -75,9 +75,7 @@ export const Button: React.StatelessComponent<ButtonProps> = (props: ButtonProps
attr={props.attr.container}
>
{icon}
<span className={css('label')}>
{props.children}
</span>
{props.children}
</ButtonProxy>
);
};
Expand Down
4 changes: 3 additions & 1 deletion lib/components/Icon/Icon.module.scss
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,9 @@
font-style: normal;
font-weight: normal;
font-family: $font-family-default;
display: flex;
display: inline-flex;
align-items: center;
justify-content: center;

&:before {
@include md-box(inline-block, relative);
Expand Down
2 changes: 1 addition & 1 deletion package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@microsoft/azure-iot-ux-fluent-controls",
"version": "6.3.2",
"version": "6.3.3",
"description": "Azure IoT UX Fluent Controls",
"main": "./lib/index.js",
"types": "./lib/index.d.ts",
Expand Down

0 comments on commit 204fea4

Please sign in to comment.