Skip to content
This repository was archived by the owner on Sep 5, 2024. It is now read-only.
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.

Commit 93e2081

Browse files
committedJul 27, 2020
refactor(dialog): remove styles for deprecated md-actions class
- remove code and tests for warning about deprecated `md-actions` class - remove unused injections in tests - fix `md-fab-speed-dial` demo that used `md-actions` class BREAKING CHANGE: Removed support for the deprecated `class="md-actions"` inside of an `md-dialog` template. This was deprecated in favor of using the `<md-dialog-actions>` element.
1 parent bafbd96 commit 93e2081

File tree

6 files changed

+60
-109
lines changed

6 files changed

+60
-109
lines changed
 
+10-14
Original file line numberDiff line numberDiff line change
@@ -1,25 +1,21 @@
11
#popupContainer {
2-
position:relative;
2+
position: relative;
33
}
4-
54
.footer {
6-
width:100%;
7-
text-align: center;
8-
margin-left:20px;
5+
width: 100%;
6+
text-align: center;
7+
margin-left: 20px;
98
}
10-
.footer, .footer > code {
11-
font-size: 0.8em;
12-
margin-top:50px;
9+
.footer, .footer > code {
10+
font-size: 0.8em;
11+
margin-top: 50px;
1312
}
14-
1513
button {
16-
width: 200px;
14+
width: 200px;
1715
}
18-
1916
div#status {
20-
color: #c60008;
17+
color: #c60008;
2118
}
22-
2319
.dialog-demo-prerendered md-checkbox {
2420
margin-bottom: 0;
25-
}
21+
}

‎src/components/dialog/dialog-theme.scss

+1-1
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ md-dialog.md-THEME_NAME-theme {
88

99

1010
&.md-content-overflow {
11-
.md-actions, md-dialog-actions {
11+
md-dialog-actions {
1212
border-top-color: '{{foreground-4}}';
1313
}
1414
}

‎src/components/dialog/dialog.js

+1-11
Original file line numberDiff line numberDiff line change
@@ -737,19 +737,9 @@ function MdDialogProvider($$interimElementProvider) {
737737
return dialogPopIn(element, options)
738738
.then(function() {
739739
lockScreenReader(element, options);
740-
warnDeprecatedActions();
741740
focusOnOpen();
742741
});
743742

744-
/**
745-
* Check to see if they used the deprecated .md-actions class and log a warning
746-
*/
747-
function warnDeprecatedActions() {
748-
if (element[0].querySelector('.md-actions')) {
749-
$log.warn('Using a class of md-actions is deprecated, please use <md-dialog-actions>.');
750-
}
751-
}
752-
753743
/**
754744
* For alerts, focus on content... otherwise focus on
755745
* the close button (or equivalent)
@@ -762,7 +752,7 @@ function MdDialogProvider($$interimElementProvider) {
762752

763753
/**
764754
* If no element with class dialog-close, try to find the last
765-
* button child in md-actions and assume it is a close button.
755+
* button child in md-dialog-actions and assume it is a close button.
766756
*
767757
* If we find no actions at all, log a warning to the console.
768758
*/

‎src/components/dialog/dialog.scss

+2-3
Original file line numberDiff line numberDiff line change
@@ -80,7 +80,7 @@ md-dialog {
8080
}
8181
}
8282

83-
.md-actions, md-dialog-actions {
83+
md-dialog-actions {
8484
display: flex;
8585
order: 2;
8686
box-sizing: border-box;
@@ -100,12 +100,11 @@ md-dialog {
100100
}
101101
}
102102
&.md-content-overflow {
103-
.md-actions, md-dialog-actions {
103+
md-dialog-actions {
104104
border-top-width: 1px;
105105
border-top-style: solid;
106106
}
107107
}
108-
109108
}
110109

111110
@media screen and (-ms-high-contrast: active) {
There was a problem loading the remainder of the diff.

0 commit comments

Comments
 (0)
Failed to load comments.