Project

General

Profile

1
// Name:            Visibility
2
// Description:     Utilities to show or hide content on breakpoints, hover or touch
3
//
4
// Component:       `uk-hidden-*`
5
//                  `uk-visible-*`
6
//                  `uk-invisible`
7
//                  `uk-visible-toggle`
8
//                  `uk-hidden-hover`
9
//                  `uk-invisible-hover`
10
//
11
// ========================================================================
12

    
13

    
14
/* ========================================================================
15
   Component: Visibility
16
 ========================================================================== */
17

    
18
/*
19
 * Hidden
20
 * `hidden` attribute also set here to make it stronger
21
 */
22

    
23
[hidden],
24
.uk-hidden { display: none !important; }
25

    
26
/* Phone landscape and bigger */
27
@media (min-width: $breakpoint-small) {
28

    
29
    .uk-hidden\@s { display: none !important; }
30

    
31
}
32

    
33
/* Tablet landscape and bigger */
34
@media (min-width: $breakpoint-medium) {
35

    
36
    .uk-hidden\@m { display: none !important; }
37

    
38
}
39

    
40
/* Desktop and bigger */
41
@media (min-width: $breakpoint-large) {
42

    
43
    .uk-hidden\@l { display: none !important; }
44

    
45
}
46

    
47
/* Large screen and bigger */
48
@media (min-width: $breakpoint-xlarge) {
49

    
50
    .uk-hidden\@xl { display: none !important; }
51

    
52
}
53

    
54
/*
55
 * Visible
56
 */
57

    
58
/* Phone portrait and smaller */
59
@media (max-width: $breakpoint-xsmall-max) {
60

    
61
    .uk-visible\@s { display: none !important; }
62

    
63
}
64

    
65
/* Phone landscape and smaller */
66
@media (max-width: $breakpoint-small-max) {
67

    
68
    .uk-visible\@m { display: none !important; }
69

    
70
}
71

    
72
/* Tablet landscape and smaller */
73
@media (max-width: $breakpoint-medium-max) {
74

    
75
    .uk-visible\@l { display: none !important; }
76

    
77
}
78

    
79
/* Desktop and smaller */
80
@media (max-width: $breakpoint-large-max) {
81

    
82
    .uk-visible\@xl { display: none !important; }
83

    
84
}
85

    
86

    
87
/* Visibility
88
 ========================================================================== */
89

    
90
.uk-invisible { visibility: hidden !important; }
91

    
92

    
93
/* Hover
94
 ========================================================================== */
95

    
96
/* Hidden */
97
.uk-visible-toggle:not(:hover):not(.uk-hover) .uk-hidden-hover { display: none !important; }
98

    
99
/* Invisible */
100
.uk-visible-toggle:not(:hover):not(.uk-hover) .uk-invisible-hover { visibility: hidden !important; }
101

    
102

    
103

    
104
// Hooks
105
// ========================================================================
106

    
107
@if(mixin-exists(hook-visibility-misc)) {@include hook-visibility-misc();}
108

    
109
// @mixin hook-visibility-misc(){}
(65-65/66)