@nice-digital/nds-maintain-ratio 1.2.20-alpha.0 → 2.0.0-alpha.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +3 -3
- package/scss/maintain-ratio.scss +4 -4
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@nice-digital/nds-maintain-ratio",
|
|
3
|
-
"version": "
|
|
3
|
+
"version": "2.0.0-alpha.0",
|
|
4
4
|
"description": "Maintain ratio component for the NICE Design System",
|
|
5
5
|
"author": "Ian Routledge <ian.routledge@nice.org.uk>",
|
|
6
6
|
"homepage": "https://design-system.nice.org.uk/",
|
|
@@ -34,7 +34,7 @@
|
|
|
34
34
|
"url": "https://github.com/nice-digital/nice-design-system/issues"
|
|
35
35
|
},
|
|
36
36
|
"dependencies": {
|
|
37
|
-
"@nice-digital/nds-core": "^
|
|
37
|
+
"@nice-digital/nds-core": "^2.0.0-alpha.0",
|
|
38
38
|
"classnames": "^2.3.1",
|
|
39
39
|
"prop-types": "^15.7.2"
|
|
40
40
|
},
|
|
@@ -45,5 +45,5 @@
|
|
|
45
45
|
"devDependencies": {
|
|
46
46
|
"@babel/cli": "^7.5.0"
|
|
47
47
|
},
|
|
48
|
-
"gitHead": "
|
|
48
|
+
"gitHead": "66fbcb1c0c01b0afc6b51b0f3fe4719be92996b0"
|
|
49
49
|
}
|
package/scss/maintain-ratio.scss
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
/// @group components
|
|
3
3
|
////
|
|
4
4
|
|
|
5
|
-
@use
|
|
5
|
+
@use 'sass:math';
|
|
6
6
|
|
|
7
7
|
/// Maintains the aspect ratio of an embedded item, useful for responsive embedding, e.g.
|
|
8
8
|
/// YouTube videos in iframes or video tags. Also useful when you know the ratio of an image
|
|
@@ -57,17 +57,17 @@
|
|
|
57
57
|
|
|
58
58
|
// Modifier class for 21:9 aspect ratio
|
|
59
59
|
&--21-9 {
|
|
60
|
-
padding-bottom: percentage(math.div(9, 21));
|
|
60
|
+
padding-bottom: math.percentage(math.div(9, 21));
|
|
61
61
|
}
|
|
62
62
|
|
|
63
63
|
// Modifier class for 16:9 aspect ratio
|
|
64
64
|
&--16-9 {
|
|
65
|
-
padding-bottom: percentage(math.div(9, 16));
|
|
65
|
+
padding-bottom: math.percentage(math.div(9, 16));
|
|
66
66
|
}
|
|
67
67
|
|
|
68
68
|
// Modifier class for 4:3 aspect ratio
|
|
69
69
|
&--4-3 {
|
|
70
|
-
padding-bottom: percentage(3 * 0.25);
|
|
70
|
+
padding-bottom: math.percentage(3 * 0.25);
|
|
71
71
|
}
|
|
72
72
|
|
|
73
73
|
// Modifier class for square aspect ratio
|