@appartmint/mint 2.1.2 → 2.1.4

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.
@@ -5,6 +5,7 @@
5
5
  @charset 'utf-8';
6
6
 
7
7
  /// Imports
8
+ @use 'sass:map';
8
9
  @use '../util' as *;
9
10
 
10
11
  /// Video Styles
@@ -14,59 +15,22 @@
14
15
  flex-direction: column;
15
16
  align-items: flex-end;
16
17
  justify-content: center;
18
+ flex-direction: row;
19
+ min-height: calc(100vh - css-var(header-height) + 10rem);
17
20
  gap: 2rem;
18
21
  position: relative;
22
+ @include exit-padding;
23
+ @include fluid-padding;
19
24
 
20
- @include break(lg) {
21
- flex-direction: row;
22
- min-height: calc(100vh - css-var(header-height));
23
- margin-bottom: 15%;
24
- }
25
-
26
- & > section {
27
- @include break(lg) {
28
- margin-bottom: -15%;
29
- }
30
- }
31
-
32
- iframe, video {
25
+ iframe, video, #{class(image)}, #{class(embed)} {
26
+ position: absolute;
27
+ top: 0;
28
+ padding: 0;
33
29
  width: 100%;
34
- height: 100%;
30
+ height: calc(100vh - css-var(header-height));
31
+ border: none;
35
32
  object-fit: cover;
36
33
  pointer-events: none;
37
-
38
- @include break(lg) {
39
- position: absolute;
40
- width: 100vw;
41
- border: none;
42
- padding: 0;
43
- }
44
-
45
- & + * {
46
- #{class(grid)} {
47
- @include break(lg) {
48
- margin-bottom: -15%;
49
- }
50
- }
51
- }
52
- }
53
-
54
- &#{class(overflow)} {
55
- overflow: hidden;
56
- margin-bottom: 0;
57
-
58
- & > section {
59
- @include break(lg) {
60
- margin-bottom: 0;
61
- }
62
- }
63
-
64
- iframe, video {
65
- top: -10%;
66
- left: -10%;
67
- width: 120%;
68
- height: 120%;
69
- }
70
34
  }
71
35
  }
72
36
  }
@@ -87,7 +87,7 @@
87
87
  position: relative;
88
88
  overflow: hidden;
89
89
 
90
- @include states(hover, focus, active) {
90
+ @include states(hover, focus, active, mint-active) {
91
91
  &::after {
92
92
  transition-duration: delay(default);
93
93
  transform: translate(100%, -100%);
@@ -105,7 +105,7 @@ main {
105
105
  width: 100%;
106
106
  padding: 0.25rem;
107
107
 
108
- @include fluid(padding, map.get($break, xs) * 1px, map.get($break, sm) * 1px, 4px, 16px);
108
+ @include fluid-padding;
109
109
 
110
110
  &+:not(#{prefix(partial-footer)}) {
111
111
  height: 0;
@@ -117,7 +117,7 @@ a {
117
117
  }
118
118
  }
119
119
 
120
- @include states(hover, focus, active) {
120
+ @include states(hover, focus, active, mint-active) {
121
121
  color: css-var($link-color-hover);
122
122
 
123
123
  .fa-facebook,
@@ -5,5 +5,5 @@
5
5
  @charset 'utf-8';
6
6
 
7
7
  /// Imports
8
- @forward './util';
9
8
  @forward './vars';
9
+ @forward './util';
@@ -10,6 +10,7 @@
10
10
  @use 'sass:math';
11
11
  @use 'sass:meta';
12
12
  @use 'sass:string';
13
+ @use 'vars' as *;
13
14
 
14
15
  /// Library name
15
16
  /// @group Variables
@@ -746,8 +747,9 @@ $bootstrap5: false !default;
746
747
  /// @param {String} $max-vw - the maximum screen width of the fluid property
747
748
  /// @param {String} $min-size - the minimum value of the fluid property
748
749
  /// @param {String} $max-size - the maximum value of the fluid property
750
+ /// @param {String} $base - the base value of the fluid property
749
751
  /// @output the definitions for the property at different screen sizes
750
- @mixin fluid ($prop, $min-vw, $max-vw, $min-size, $max-size) {
752
+ @mixin fluid ($prop, $min-vw, $max-vw, $min-size, $max-size, $base: null) {
751
753
  $u1: math.unit($min-vw);
752
754
  $u2: math.unit($max-vw);
753
755
  $u3: math.unit($min-size);
@@ -765,20 +767,53 @@ $bootstrap5: false !default;
765
767
  @error 'The fluid mixin requires width and size arguments with the same units.';
766
768
  }
767
769
 
768
- // See if you can get rid of this wrapping & selector
769
770
  & {
770
- #{$prop}: $min-size;
771
-
772
- @media (min-width: $min-vw) {
773
- #{$prop}: calc(#{$min-size} + #{strip-unit($max-size - $min-size)} * ((100vw - #{$min-vw}) / #{strip-unit($max-vw - $min-vw)}));
774
- }
775
-
776
- @media (min-width: $max-vw) {
777
- #{$prop}: $max-size;
771
+ @if ($base) {
772
+ #{$prop}: calc($base + $min-size);
773
+
774
+ @media (min-width: $min-vw) {
775
+ #{$prop}: calc($base + #{$min-size} + #{strip-unit($max-size - $min-size)} * ((100vw - #{$min-vw}) / #{strip-unit($max-vw - $min-vw)}));
776
+ }
777
+
778
+ @media (min-width: $max-vw) {
779
+ #{$prop}: calc($base + $max-size);
780
+ }
781
+ } @else {
782
+ #{$prop}: $min-size;
783
+
784
+ @media (min-width: $min-vw) {
785
+ #{$prop}: calc(#{$min-size} + #{strip-unit($max-size - $min-size)} * ((100vw - #{$min-vw}) / #{strip-unit($max-vw - $min-vw)}));
786
+ }
787
+
788
+ @media (min-width: $max-vw) {
789
+ #{$prop}: $max-size;
790
+ }
778
791
  }
779
792
  }
780
793
  }
781
794
 
795
+ /// Gives a container fluid padding
796
+ /// @group Mixins
797
+ ///
798
+ ///
799
+ @mixin fluid-padding {
800
+ $padding-min-vw: map.get($break, $pad-min-vw) * 1px;
801
+ $padding-max-vw: map.get($break, $pad-max-vw) * 1px;
802
+ @include fluid(padding, $padding-min-vw, $padding-max-vw, $pad-min-size, $pad-max-size);
803
+ }
804
+
805
+ /// Negates a page's padding
806
+ /// @group Mixins
807
+ ///
808
+ ///
809
+ @mixin exit-padding {
810
+ $padding-min-vw: map.get($break, $pad-min-vw) * 1px;
811
+ $padding-max-vw: map.get($break, $pad-max-vw) * 1px;
812
+ @include fluid(top, $padding-min-vw, $padding-max-vw, $pad-min-size * -1, $pad-max-size * -1);
813
+ @include fluid(left, $padding-min-vw, $padding-max-vw, $pad-min-size * -1, $pad-max-size * -1);
814
+ @include fluid(width, $padding-min-vw, $padding-max-vw, $pad-min-size * 2, $pad-max-size * 2, 100%);
815
+ }
816
+
782
817
  /// Generates css varibles for lighter, darker, or both variations
783
818
  /// @group Mixins
784
819
  ///
@@ -899,7 +934,12 @@ $bootstrap5: false !default;
899
934
 
900
935
  @if (list.index($states, 'active') != null) {
901
936
 
902
- &:active,
937
+ &:active {
938
+ @content;
939
+ }
940
+ }
941
+
942
+ @if (list.index($states, 'mint-active') != null) {
903
943
  &#{class(active)} {
904
944
  @content;
905
945
  }
@@ -964,14 +1004,11 @@ $bootstrap5: false !default;
964
1004
  @mixin headers () {
965
1005
  @for $i from 1 through 6 {
966
1006
  h#{$i},
967
- #{class(h#{$i})
968
- }
969
-
970
- {
971
- @content;
1007
+ #{class(h#{$i})} {
1008
+ @content;
1009
+ }
972
1010
  }
973
1011
  }
974
- }
975
1012
 
976
1013
 
977
1014
  /// Background clip text
@@ -89,6 +89,10 @@ $font-size-desktop: (
89
89
 
90
90
  /// Structure
91
91
  $grid-gap: 2rem !default;
92
+ $pad-min-vw: xs !default;
93
+ $pad-max-vw: sm !default;
94
+ $pad-min-size: 4px !default;
95
+ $pad-max-size: 16px !default;
92
96
 
93
97
  /// Outline width
94
98
  $border-width: 0.125rem !default;