@enigmatry/scss-foundation 17.0.0-preview.5 → 17.0.0-preview.5.1
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/README.md +18 -18
- package/coverage/clover.xml +2 -2
- package/coverage/lcov-report/index.html +1 -1
- package/docs/modules/README.md +19 -19
- package/docs/modules/absolute-positioning.md +28 -28
- package/docs/modules/alignment.md +45 -45
- package/docs/modules/background-hover.md +18 -18
- package/docs/modules/border-radius.md +19 -19
- package/docs/modules/breakpoints.md +27 -27
- package/docs/modules/fixed-positioning.md +28 -28
- package/docs/modules/grid.md +46 -46
- package/docs/modules/row-coloring.md +23 -23
- package/docs/modules/text-hover.md +18 -18
- package/docs/modules/text-modification.md +27 -27
- package/docs/modules/visibility.md +27 -27
- package/docs/partials/README.md +14 -14
- package/docs/partials/alignment.md +15 -15
- package/docs/partials/cursor.md +13 -13
- package/docs/partials/resize.md +9 -9
- package/docs/partials/text-control.md +11 -11
- package/docs/partials/visibility.md +9 -9
- package/jest.config.js +21 -21
- package/package.json +24 -24
- package/src/modules/_index.scss +7 -7
- package/src/modules/_map.scss +53 -53
- package/src/modules/_variables.scss +11 -11
- package/src/modules/borders/_border-radius.scss +10 -10
- package/src/modules/display/_items.scss +21 -21
- package/src/modules/layout/_grid-core.scss +53 -53
- package/src/modules/layout/_grid.scss +98 -98
- package/src/modules/layout/_index.scss +1 -1
- package/src/modules/lists/_row-coloring.scss +12 -12
- package/src/modules/position/_absolute.scss +8 -8
- package/src/modules/position/_fixed.scss +8 -8
- package/src/modules/position/_index.scss +2 -2
- package/src/modules/position/_set-position.scss +24 -24
- package/src/modules/responsiveness/_breakpoints.scss +55 -55
- package/src/modules/states/_hover.scss +6 -6
- package/src/modules/states/_index.scss +1 -1
- package/src/modules/states/_visibility.scss +15 -15
- package/src/modules/text/_hover.scss +6 -6
- package/src/modules/text/_index.scss +1 -1
- package/src/modules/text/_modification.scss +29 -29
- package/src/partials/core/_index.scss +2 -2
- package/src/partials/core/fonts/_text-control.scss +10 -10
- package/src/partials/core/layouts/_alignment.scss +21 -21
- package/src/partials/core/states/_cursors.scss +10 -10
- package/src/partials/core/states/_index.scss +2 -2
- package/src/partials/core/states/_resize.scss +2 -2
- package/src/partials/core/states/_visibility.scss +2 -2
- package/tests/display/items.tests.scss +99 -99
- package/tests/layout/grid-core.tests.scss +115 -115
- package/tests/layout/grid.tests.scss +1154 -1154
- package/tests/lists/row-coloring.tests.scss +51 -51
- package/tests/position/absolute.tests.scss +67 -67
- package/tests/position/fixed.tests.scss +67 -67
- package/tests/position/set-position.tests.scss +64 -64
- package/tests/shim.test.js +13 -13
- package/tests/text/modification.tests.scss +20 -20
|
@@ -1,52 +1,52 @@
|
|
|
1
|
-
@use 'sass:color';
|
|
2
|
-
@use 'sass-true/sass/true';
|
|
3
|
-
@use '../../src/modules/lists/row-coloring' as lists;
|
|
4
|
-
|
|
5
|
-
@include true.describe('row-coloring($color, $rows)') {
|
|
6
|
-
@include true.it('should set background #EBEBEB color to third element') {
|
|
7
|
-
@include true.assert() {
|
|
8
|
-
@include true.output() {
|
|
9
|
-
@include lists.row-coloring(#EBEBEB, 3);
|
|
10
|
-
}
|
|
11
|
-
|
|
12
|
-
@include true.expect() {
|
|
13
|
-
&:nth-child(3) {
|
|
14
|
-
background-color: #EBEBEB;
|
|
15
|
-
}
|
|
16
|
-
}
|
|
17
|
-
}
|
|
18
|
-
}
|
|
19
|
-
}
|
|
20
|
-
|
|
21
|
-
@include true.describe('even-row-coloring($color)') {
|
|
22
|
-
@include true.it('should set background #000, $alpha: -1 color to all even element') {
|
|
23
|
-
@include true.assert() {
|
|
24
|
-
@include true.output() {
|
|
25
|
-
@include lists.even-row-coloring(color.adjust(#000, $alpha: -1));
|
|
26
|
-
}
|
|
27
|
-
|
|
28
|
-
@include true.expect() {
|
|
29
|
-
&:nth-child(even) {
|
|
30
|
-
background-color: color.adjust(#000, $alpha: -1);
|
|
31
|
-
}
|
|
32
|
-
}
|
|
33
|
-
}
|
|
34
|
-
}
|
|
35
|
-
}
|
|
36
|
-
|
|
37
|
-
@include true.describe('odd-row-coloring($color)') {
|
|
38
|
-
@include true.it('should set background color of variable $background-color to all odd element') {
|
|
39
|
-
$background-color: #EBEBEB;
|
|
40
|
-
@include true.assert() {
|
|
41
|
-
@include true.output() {
|
|
42
|
-
@include lists.odd-row-coloring($background-color);
|
|
43
|
-
}
|
|
44
|
-
|
|
45
|
-
@include true.expect() {
|
|
46
|
-
&:nth-child(odd) {
|
|
47
|
-
background-color: $background-color;
|
|
48
|
-
}
|
|
49
|
-
}
|
|
50
|
-
}
|
|
51
|
-
}
|
|
1
|
+
@use 'sass:color';
|
|
2
|
+
@use 'sass-true/sass/true';
|
|
3
|
+
@use '../../src/modules/lists/row-coloring' as lists;
|
|
4
|
+
|
|
5
|
+
@include true.describe('row-coloring($color, $rows)') {
|
|
6
|
+
@include true.it('should set background #EBEBEB color to third element') {
|
|
7
|
+
@include true.assert() {
|
|
8
|
+
@include true.output() {
|
|
9
|
+
@include lists.row-coloring(#EBEBEB, 3);
|
|
10
|
+
}
|
|
11
|
+
|
|
12
|
+
@include true.expect() {
|
|
13
|
+
&:nth-child(3) {
|
|
14
|
+
background-color: #EBEBEB;
|
|
15
|
+
}
|
|
16
|
+
}
|
|
17
|
+
}
|
|
18
|
+
}
|
|
19
|
+
}
|
|
20
|
+
|
|
21
|
+
@include true.describe('even-row-coloring($color)') {
|
|
22
|
+
@include true.it('should set background #000, $alpha: -1 color to all even element') {
|
|
23
|
+
@include true.assert() {
|
|
24
|
+
@include true.output() {
|
|
25
|
+
@include lists.even-row-coloring(color.adjust(#000, $alpha: -1));
|
|
26
|
+
}
|
|
27
|
+
|
|
28
|
+
@include true.expect() {
|
|
29
|
+
&:nth-child(even) {
|
|
30
|
+
background-color: color.adjust(#000, $alpha: -1);
|
|
31
|
+
}
|
|
32
|
+
}
|
|
33
|
+
}
|
|
34
|
+
}
|
|
35
|
+
}
|
|
36
|
+
|
|
37
|
+
@include true.describe('odd-row-coloring($color)') {
|
|
38
|
+
@include true.it('should set background color of variable $background-color to all odd element') {
|
|
39
|
+
$background-color: #EBEBEB;
|
|
40
|
+
@include true.assert() {
|
|
41
|
+
@include true.output() {
|
|
42
|
+
@include lists.odd-row-coloring($background-color);
|
|
43
|
+
}
|
|
44
|
+
|
|
45
|
+
@include true.expect() {
|
|
46
|
+
&:nth-child(odd) {
|
|
47
|
+
background-color: $background-color;
|
|
48
|
+
}
|
|
49
|
+
}
|
|
50
|
+
}
|
|
51
|
+
}
|
|
52
52
|
}
|
|
@@ -1,68 +1,68 @@
|
|
|
1
|
-
/* stylelint-disable declaration-block-no-redundant-longhand-properties */
|
|
2
|
-
/* stylelint-disable shorthand-property-no-redundant-values */
|
|
3
|
-
@use 'sass-true/sass/true';
|
|
4
|
-
@use '../../src/modules/position/absolute';
|
|
5
|
-
|
|
6
|
-
@include true.describe('position($top, $right, $bottom, $left)') {
|
|
7
|
-
@include true.it('should default to zero-based if position not provided') {
|
|
8
|
-
@include true.assert() {
|
|
9
|
-
@include true.output() {
|
|
10
|
-
@include absolute.position();
|
|
11
|
-
}
|
|
12
|
-
@include true.expect() {
|
|
13
|
-
position: absolute;
|
|
14
|
-
top: 0;
|
|
15
|
-
right: 0;
|
|
16
|
-
bottom: 0;
|
|
17
|
-
left: 0;
|
|
18
|
-
}
|
|
19
|
-
}
|
|
20
|
-
}
|
|
21
|
-
|
|
22
|
-
@include true.it('should set position to given in right order') {
|
|
23
|
-
@include true.assert() {
|
|
24
|
-
@include true.output() {
|
|
25
|
-
@include absolute.position(5px, 3em, 14rem, -8px);
|
|
26
|
-
}
|
|
27
|
-
@include true.expect() {
|
|
28
|
-
position: absolute;
|
|
29
|
-
top: 5px;
|
|
30
|
-
right: 3em;
|
|
31
|
-
bottom: 14rem;
|
|
32
|
-
left: -8px;
|
|
33
|
-
}
|
|
34
|
-
}
|
|
35
|
-
}
|
|
36
|
-
}
|
|
37
|
-
|
|
38
|
-
@include true.describe('position-unset($top, $right, $bottom, $left)') {
|
|
39
|
-
@include true.it('should default to unset-based if position not provided') {
|
|
40
|
-
@include true.assert() {
|
|
41
|
-
@include true.output() {
|
|
42
|
-
@include absolute.position-unset();
|
|
43
|
-
}
|
|
44
|
-
@include true.expect() {
|
|
45
|
-
position: absolute;
|
|
46
|
-
top: unset;
|
|
47
|
-
right: unset;
|
|
48
|
-
bottom: unset;
|
|
49
|
-
left: unset;
|
|
50
|
-
}
|
|
51
|
-
}
|
|
52
|
-
}
|
|
53
|
-
|
|
54
|
-
@include true.it('should set position to given in right order') {
|
|
55
|
-
@include true.assert() {
|
|
56
|
-
@include true.output() {
|
|
57
|
-
@include absolute.position-unset(5px, 3em, 14rem);
|
|
58
|
-
}
|
|
59
|
-
@include true.expect() {
|
|
60
|
-
position: absolute;
|
|
61
|
-
top: 5px;
|
|
62
|
-
right: 3em;
|
|
63
|
-
bottom: 14rem;
|
|
64
|
-
left: unset;
|
|
65
|
-
}
|
|
66
|
-
}
|
|
67
|
-
}
|
|
1
|
+
/* stylelint-disable declaration-block-no-redundant-longhand-properties */
|
|
2
|
+
/* stylelint-disable shorthand-property-no-redundant-values */
|
|
3
|
+
@use 'sass-true/sass/true';
|
|
4
|
+
@use '../../src/modules/position/absolute';
|
|
5
|
+
|
|
6
|
+
@include true.describe('position($top, $right, $bottom, $left)') {
|
|
7
|
+
@include true.it('should default to zero-based if position not provided') {
|
|
8
|
+
@include true.assert() {
|
|
9
|
+
@include true.output() {
|
|
10
|
+
@include absolute.position();
|
|
11
|
+
}
|
|
12
|
+
@include true.expect() {
|
|
13
|
+
position: absolute;
|
|
14
|
+
top: 0;
|
|
15
|
+
right: 0;
|
|
16
|
+
bottom: 0;
|
|
17
|
+
left: 0;
|
|
18
|
+
}
|
|
19
|
+
}
|
|
20
|
+
}
|
|
21
|
+
|
|
22
|
+
@include true.it('should set position to given in right order') {
|
|
23
|
+
@include true.assert() {
|
|
24
|
+
@include true.output() {
|
|
25
|
+
@include absolute.position(5px, 3em, 14rem, -8px);
|
|
26
|
+
}
|
|
27
|
+
@include true.expect() {
|
|
28
|
+
position: absolute;
|
|
29
|
+
top: 5px;
|
|
30
|
+
right: 3em;
|
|
31
|
+
bottom: 14rem;
|
|
32
|
+
left: -8px;
|
|
33
|
+
}
|
|
34
|
+
}
|
|
35
|
+
}
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
@include true.describe('position-unset($top, $right, $bottom, $left)') {
|
|
39
|
+
@include true.it('should default to unset-based if position not provided') {
|
|
40
|
+
@include true.assert() {
|
|
41
|
+
@include true.output() {
|
|
42
|
+
@include absolute.position-unset();
|
|
43
|
+
}
|
|
44
|
+
@include true.expect() {
|
|
45
|
+
position: absolute;
|
|
46
|
+
top: unset;
|
|
47
|
+
right: unset;
|
|
48
|
+
bottom: unset;
|
|
49
|
+
left: unset;
|
|
50
|
+
}
|
|
51
|
+
}
|
|
52
|
+
}
|
|
53
|
+
|
|
54
|
+
@include true.it('should set position to given in right order') {
|
|
55
|
+
@include true.assert() {
|
|
56
|
+
@include true.output() {
|
|
57
|
+
@include absolute.position-unset(5px, 3em, 14rem);
|
|
58
|
+
}
|
|
59
|
+
@include true.expect() {
|
|
60
|
+
position: absolute;
|
|
61
|
+
top: 5px;
|
|
62
|
+
right: 3em;
|
|
63
|
+
bottom: 14rem;
|
|
64
|
+
left: unset;
|
|
65
|
+
}
|
|
66
|
+
}
|
|
67
|
+
}
|
|
68
68
|
}
|
|
@@ -1,68 +1,68 @@
|
|
|
1
|
-
/* stylelint-disable declaration-block-no-redundant-longhand-properties */
|
|
2
|
-
/* stylelint-disable shorthand-property-no-redundant-values */
|
|
3
|
-
@use 'sass-true/sass/true';
|
|
4
|
-
@use '../../src/modules/position/fixed';
|
|
5
|
-
|
|
6
|
-
@include true.describe('position($top, $right, $bottom, $left)') {
|
|
7
|
-
@include true.it('should default to zero-based if position not provided') {
|
|
8
|
-
@include true.assert() {
|
|
9
|
-
@include true.output() {
|
|
10
|
-
@include fixed.position();
|
|
11
|
-
}
|
|
12
|
-
@include true.expect() {
|
|
13
|
-
position: fixed;
|
|
14
|
-
top: 0;
|
|
15
|
-
right: 0;
|
|
16
|
-
bottom: 0;
|
|
17
|
-
left: 0;
|
|
18
|
-
}
|
|
19
|
-
}
|
|
20
|
-
}
|
|
21
|
-
|
|
22
|
-
@include true.it('should set position to given in right order') {
|
|
23
|
-
@include true.assert() {
|
|
24
|
-
@include true.output() {
|
|
25
|
-
@include fixed.position(5px, 15px, 20px, 1px);
|
|
26
|
-
}
|
|
27
|
-
@include true.expect() {
|
|
28
|
-
position: fixed;
|
|
29
|
-
top: 5px;
|
|
30
|
-
right: 15px;
|
|
31
|
-
bottom: 20px;
|
|
32
|
-
left: 1px;
|
|
33
|
-
}
|
|
34
|
-
}
|
|
35
|
-
}
|
|
36
|
-
}
|
|
37
|
-
|
|
38
|
-
@include true.describe('position-unset($top, $right, $bottom, $left)') {
|
|
39
|
-
@include true.it('should default to unset-based if position not provided') {
|
|
40
|
-
@include true.assert() {
|
|
41
|
-
@include true.output() {
|
|
42
|
-
@include fixed.position-unset();
|
|
43
|
-
}
|
|
44
|
-
@include true.expect() {
|
|
45
|
-
position: fixed;
|
|
46
|
-
top: unset;
|
|
47
|
-
right: unset;
|
|
48
|
-
bottom: unset;
|
|
49
|
-
left: unset;
|
|
50
|
-
}
|
|
51
|
-
}
|
|
52
|
-
}
|
|
53
|
-
|
|
54
|
-
@include true.it('should set position to given in right order') {
|
|
55
|
-
@include true.assert() {
|
|
56
|
-
@include true.output() {
|
|
57
|
-
@include fixed.position-unset(5px, 15px, 20px);
|
|
58
|
-
}
|
|
59
|
-
@include true.expect() {
|
|
60
|
-
position: fixed;
|
|
61
|
-
top: 5px;
|
|
62
|
-
right: 15px;
|
|
63
|
-
bottom: 20px;
|
|
64
|
-
left: unset;
|
|
65
|
-
}
|
|
66
|
-
}
|
|
67
|
-
}
|
|
1
|
+
/* stylelint-disable declaration-block-no-redundant-longhand-properties */
|
|
2
|
+
/* stylelint-disable shorthand-property-no-redundant-values */
|
|
3
|
+
@use 'sass-true/sass/true';
|
|
4
|
+
@use '../../src/modules/position/fixed';
|
|
5
|
+
|
|
6
|
+
@include true.describe('position($top, $right, $bottom, $left)') {
|
|
7
|
+
@include true.it('should default to zero-based if position not provided') {
|
|
8
|
+
@include true.assert() {
|
|
9
|
+
@include true.output() {
|
|
10
|
+
@include fixed.position();
|
|
11
|
+
}
|
|
12
|
+
@include true.expect() {
|
|
13
|
+
position: fixed;
|
|
14
|
+
top: 0;
|
|
15
|
+
right: 0;
|
|
16
|
+
bottom: 0;
|
|
17
|
+
left: 0;
|
|
18
|
+
}
|
|
19
|
+
}
|
|
20
|
+
}
|
|
21
|
+
|
|
22
|
+
@include true.it('should set position to given in right order') {
|
|
23
|
+
@include true.assert() {
|
|
24
|
+
@include true.output() {
|
|
25
|
+
@include fixed.position(5px, 15px, 20px, 1px);
|
|
26
|
+
}
|
|
27
|
+
@include true.expect() {
|
|
28
|
+
position: fixed;
|
|
29
|
+
top: 5px;
|
|
30
|
+
right: 15px;
|
|
31
|
+
bottom: 20px;
|
|
32
|
+
left: 1px;
|
|
33
|
+
}
|
|
34
|
+
}
|
|
35
|
+
}
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
@include true.describe('position-unset($top, $right, $bottom, $left)') {
|
|
39
|
+
@include true.it('should default to unset-based if position not provided') {
|
|
40
|
+
@include true.assert() {
|
|
41
|
+
@include true.output() {
|
|
42
|
+
@include fixed.position-unset();
|
|
43
|
+
}
|
|
44
|
+
@include true.expect() {
|
|
45
|
+
position: fixed;
|
|
46
|
+
top: unset;
|
|
47
|
+
right: unset;
|
|
48
|
+
bottom: unset;
|
|
49
|
+
left: unset;
|
|
50
|
+
}
|
|
51
|
+
}
|
|
52
|
+
}
|
|
53
|
+
|
|
54
|
+
@include true.it('should set position to given in right order') {
|
|
55
|
+
@include true.assert() {
|
|
56
|
+
@include true.output() {
|
|
57
|
+
@include fixed.position-unset(5px, 15px, 20px);
|
|
58
|
+
}
|
|
59
|
+
@include true.expect() {
|
|
60
|
+
position: fixed;
|
|
61
|
+
top: 5px;
|
|
62
|
+
right: 15px;
|
|
63
|
+
bottom: 20px;
|
|
64
|
+
left: unset;
|
|
65
|
+
}
|
|
66
|
+
}
|
|
67
|
+
}
|
|
68
68
|
}
|
|
@@ -1,65 +1,65 @@
|
|
|
1
|
-
/* stylelint-disable declaration-block-no-redundant-longhand-properties */
|
|
2
|
-
@use 'sass-true/sass/true';
|
|
3
|
-
@use '../../src/modules/position/set-position' as position;
|
|
4
|
-
|
|
5
|
-
@include true.describe('set-position($top, $right, $bottom, $left, $position)') {
|
|
6
|
-
@include true.it('should set the type of positioning and the four positions.') {
|
|
7
|
-
@include true.assert() {
|
|
8
|
-
@include true.output() {
|
|
9
|
-
@include position.set-position(absolute, 5px, 3em, 14rem, -8px);
|
|
10
|
-
}
|
|
11
|
-
@include true.expect() {
|
|
12
|
-
position: absolute;
|
|
13
|
-
top: 5px;
|
|
14
|
-
right: 3em;
|
|
15
|
-
bottom: 14rem;
|
|
16
|
-
left: -8px;
|
|
17
|
-
}
|
|
18
|
-
}
|
|
19
|
-
}
|
|
20
|
-
|
|
21
|
-
@include true.it('should set the type of positioning and the four positions.') {
|
|
22
|
-
@include true.assert() {
|
|
23
|
-
@include true.output() {
|
|
24
|
-
@include position.set-position(fixed, 5px, 1px, 1em, 100px);
|
|
25
|
-
}
|
|
26
|
-
@include true.expect() {
|
|
27
|
-
position: fixed;
|
|
28
|
-
top: 5px;
|
|
29
|
-
right: 1px;
|
|
30
|
-
bottom: 1em;
|
|
31
|
-
left: 100px;
|
|
32
|
-
}
|
|
33
|
-
}
|
|
34
|
-
}
|
|
35
|
-
|
|
36
|
-
@include true.it('should set the type of positioning and the four positions.') {
|
|
37
|
-
@include true.assert() {
|
|
38
|
-
@include true.output() {
|
|
39
|
-
@include position.set-position(static, 5px, 1px, 1em, 100px);
|
|
40
|
-
}
|
|
41
|
-
@include true.expect() {
|
|
42
|
-
position: static;
|
|
43
|
-
top: 5px;
|
|
44
|
-
right: 1px;
|
|
45
|
-
bottom: 1em;
|
|
46
|
-
left: 100px;
|
|
47
|
-
}
|
|
48
|
-
}
|
|
49
|
-
}
|
|
50
|
-
|
|
51
|
-
@include true.it('should set the type of positioning and the four positions.') {
|
|
52
|
-
@include true.assert() {
|
|
53
|
-
@include true.output() {
|
|
54
|
-
@include position.set-position(relative, 5px, 1px, 1em, 100px);
|
|
55
|
-
}
|
|
56
|
-
@include true.expect() {
|
|
57
|
-
position: relative;
|
|
58
|
-
top: 5px;
|
|
59
|
-
right: 1px;
|
|
60
|
-
bottom: 1em;
|
|
61
|
-
left: 100px;
|
|
62
|
-
}
|
|
63
|
-
}
|
|
64
|
-
}
|
|
1
|
+
/* stylelint-disable declaration-block-no-redundant-longhand-properties */
|
|
2
|
+
@use 'sass-true/sass/true';
|
|
3
|
+
@use '../../src/modules/position/set-position' as position;
|
|
4
|
+
|
|
5
|
+
@include true.describe('set-position($top, $right, $bottom, $left, $position)') {
|
|
6
|
+
@include true.it('should set the type of positioning and the four positions.') {
|
|
7
|
+
@include true.assert() {
|
|
8
|
+
@include true.output() {
|
|
9
|
+
@include position.set-position(absolute, 5px, 3em, 14rem, -8px);
|
|
10
|
+
}
|
|
11
|
+
@include true.expect() {
|
|
12
|
+
position: absolute;
|
|
13
|
+
top: 5px;
|
|
14
|
+
right: 3em;
|
|
15
|
+
bottom: 14rem;
|
|
16
|
+
left: -8px;
|
|
17
|
+
}
|
|
18
|
+
}
|
|
19
|
+
}
|
|
20
|
+
|
|
21
|
+
@include true.it('should set the type of positioning and the four positions.') {
|
|
22
|
+
@include true.assert() {
|
|
23
|
+
@include true.output() {
|
|
24
|
+
@include position.set-position(fixed, 5px, 1px, 1em, 100px);
|
|
25
|
+
}
|
|
26
|
+
@include true.expect() {
|
|
27
|
+
position: fixed;
|
|
28
|
+
top: 5px;
|
|
29
|
+
right: 1px;
|
|
30
|
+
bottom: 1em;
|
|
31
|
+
left: 100px;
|
|
32
|
+
}
|
|
33
|
+
}
|
|
34
|
+
}
|
|
35
|
+
|
|
36
|
+
@include true.it('should set the type of positioning and the four positions.') {
|
|
37
|
+
@include true.assert() {
|
|
38
|
+
@include true.output() {
|
|
39
|
+
@include position.set-position(static, 5px, 1px, 1em, 100px);
|
|
40
|
+
}
|
|
41
|
+
@include true.expect() {
|
|
42
|
+
position: static;
|
|
43
|
+
top: 5px;
|
|
44
|
+
right: 1px;
|
|
45
|
+
bottom: 1em;
|
|
46
|
+
left: 100px;
|
|
47
|
+
}
|
|
48
|
+
}
|
|
49
|
+
}
|
|
50
|
+
|
|
51
|
+
@include true.it('should set the type of positioning and the four positions.') {
|
|
52
|
+
@include true.assert() {
|
|
53
|
+
@include true.output() {
|
|
54
|
+
@include position.set-position(relative, 5px, 1px, 1em, 100px);
|
|
55
|
+
}
|
|
56
|
+
@include true.expect() {
|
|
57
|
+
position: relative;
|
|
58
|
+
top: 5px;
|
|
59
|
+
right: 1px;
|
|
60
|
+
bottom: 1em;
|
|
61
|
+
left: 100px;
|
|
62
|
+
}
|
|
63
|
+
}
|
|
64
|
+
}
|
|
65
65
|
}
|
package/tests/shim.test.js
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* @jest-environment jest-environment-node-single-context
|
|
3
|
-
*/
|
|
4
|
-
|
|
5
|
-
const path = require('path');
|
|
6
|
-
const sassTrue = require('sass-true');
|
|
7
|
-
const glob = require('glob');
|
|
8
|
-
|
|
9
|
-
describe('Scss unit tests', () => {
|
|
10
|
-
const paths = path.resolve(process.cwd(), 'tests/**/*.tests.scss').replace(/\\/g,'/');
|
|
11
|
-
const sassTestFiles = glob.sync(paths);
|
|
12
|
-
|
|
13
|
-
sassTestFiles.forEach(file => sassTrue.runSass({ describe, it }, file, {loadPaths: ['../../node_modules'] }));
|
|
1
|
+
/**
|
|
2
|
+
* @jest-environment jest-environment-node-single-context
|
|
3
|
+
*/
|
|
4
|
+
|
|
5
|
+
const path = require('path');
|
|
6
|
+
const sassTrue = require('sass-true');
|
|
7
|
+
const glob = require('glob');
|
|
8
|
+
|
|
9
|
+
describe('Scss unit tests', () => {
|
|
10
|
+
const paths = path.resolve(process.cwd(), 'tests/**/*.tests.scss').replace(/\\/g,'/');
|
|
11
|
+
const sassTestFiles = glob.sync(paths);
|
|
12
|
+
|
|
13
|
+
sassTestFiles.forEach(file => sassTrue.runSass({ describe, it }, file, {loadPaths: ['../../node_modules'] }));
|
|
14
14
|
});
|
|
@@ -1,21 +1,21 @@
|
|
|
1
|
-
@use '../../src/modules/variables' as vars;
|
|
2
|
-
@use '../../src/modules/text/modification';
|
|
3
|
-
@use 'sass-true';
|
|
4
|
-
|
|
5
|
-
vars.$testing: true;
|
|
6
|
-
|
|
7
|
-
@include sass-true.describe('capitalize(word)') {
|
|
8
|
-
@include sass-true.it('should throw if word is not a string') {
|
|
9
|
-
$expected-message: 'ERROR [capitalize()]: Please provide string parameter! Given value: ';
|
|
10
|
-
@include sass-true.assert-equal(modification.capitalize(5), $expected-message + '5');
|
|
11
|
-
@include sass-true.assert-equal(modification.capitalize(null), $expected-message);
|
|
12
|
-
@include sass-true.assert-equal(modification.capitalize(#FFEEAA), $expected-message + '#FFEEAA');
|
|
13
|
-
}
|
|
14
|
-
|
|
15
|
-
@include sass-true.it('should return string with first letter capitalized') {
|
|
16
|
-
@include sass-true.assert-equal(modification.capitalize('house'), 'House');
|
|
17
|
-
@include sass-true.assert-equal(modification.capitalize('dOg'),'DOg');
|
|
18
|
-
@include sass-true.assert-equal(modification.capitalize('Dang'), 'Dang');
|
|
19
|
-
@include sass-true.assert-equal(modification.capitalize('4pple'), '4pple');
|
|
20
|
-
}
|
|
1
|
+
@use '../../src/modules/variables' as vars;
|
|
2
|
+
@use '../../src/modules/text/modification';
|
|
3
|
+
@use 'sass-true';
|
|
4
|
+
|
|
5
|
+
vars.$testing: true;
|
|
6
|
+
|
|
7
|
+
@include sass-true.describe('capitalize(word)') {
|
|
8
|
+
@include sass-true.it('should throw if word is not a string') {
|
|
9
|
+
$expected-message: 'ERROR [capitalize()]: Please provide string parameter! Given value: ';
|
|
10
|
+
@include sass-true.assert-equal(modification.capitalize(5), $expected-message + '5');
|
|
11
|
+
@include sass-true.assert-equal(modification.capitalize(null), $expected-message);
|
|
12
|
+
@include sass-true.assert-equal(modification.capitalize(#FFEEAA), $expected-message + '#FFEEAA');
|
|
13
|
+
}
|
|
14
|
+
|
|
15
|
+
@include sass-true.it('should return string with first letter capitalized') {
|
|
16
|
+
@include sass-true.assert-equal(modification.capitalize('house'), 'House');
|
|
17
|
+
@include sass-true.assert-equal(modification.capitalize('dOg'),'DOg');
|
|
18
|
+
@include sass-true.assert-equal(modification.capitalize('Dang'), 'Dang');
|
|
19
|
+
@include sass-true.assert-equal(modification.capitalize('4pple'), '4pple');
|
|
20
|
+
}
|
|
21
21
|
}
|