Skip to content

Commit

Permalink
Fix(NcActionButton): Add RTL support to NcActionButton component
Browse files Browse the repository at this point in the history
Signed-off-by: Faisal Alghamdi <[email protected]>
  • Loading branch information
falghamdi125 authored and susnux committed Nov 19, 2024
1 parent 52e3bbd commit 0e449a2
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 8 deletions.
8 changes: 2 additions & 6 deletions src/assets/action.scss
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@
height: auto;
margin: 0;
padding: 0;
padding-right: $icon-margin;
padding-inline-end: $icon-margin;
box-sizing: border-box; // otherwise router-link overflows in Firefox

cursor: pointer;
Expand Down Expand Up @@ -109,11 +109,7 @@
}

&__menu-icon {
// Push to the right
margin-left: auto;
// Align with right end of the button
// This is the padding-right
margin-right: calc($icon-margin * -1);
margin-inline: auto calc($icon-margin * -1);
}
}
}
4 changes: 2 additions & 2 deletions src/components/NcActionButton/NcActionButton.vue
Original file line number Diff line number Diff line change
Expand Up @@ -547,7 +547,7 @@ export default {
@include action-item('button');

.action-button__pressed-icon {
margin-left: auto;
margin-right: calc($icon-margin * -1);
margin-inline-start: auto;
margin-inline-end: calc($icon-margin * -1);
}
</style>

0 comments on commit 0e449a2

Please sign in to comment.