Skip to content
This repository was archived by the owner on Dec 4, 2017. It is now read-only.

Commit 024b680

Browse files
Eric Jimeneznaomiblack
authored andcommitted
fix(copy btn): remove overflow from button. Refactor styles out of inlines within directive
1 parent 621bc31 commit 024b680

File tree

3 files changed

+13
-2
lines changed

3 files changed

+13
-2
lines changed

public/resources/css/main.scss

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -54,6 +54,7 @@
5454
@import 'module/press-kit';
5555
@import 'module/features';
5656
@import 'module/docs-landing';
57+
@import 'module/copy';
5758

5859
/*
5960
* PRINT STYLES
Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
.copy-container-template {
2+
position: relative;
3+
4+
& > .copy-button {
5+
margin-top: 8px;
6+
right: 0;
7+
z-index: 1;
8+
position: absolute;
9+
}
10+
}

public/resources/js/directives/copy.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -24,8 +24,8 @@ angularIO.directive('copyContainer', function() {
2424
restrict: 'E',
2525
transclude: true,
2626
template:
27-
'<div style="position: relative; overflow: auto;">' +
28-
'<copy-button style="position: absolute; top: 18px; right: 0px; z-index: 1" ></copy-button>' +
27+
'<div class="copy-container-template">' +
28+
'<copy-button class="copy-button"></copy-button>' +
2929
'<ng-transclude></ng-transclude>' +
3030
'</div>'
3131
};

0 commit comments

Comments
 (0)