-
Notifications
You must be signed in to change notification settings - Fork 396
Expand file tree
/
Copy pathcontent-tools.scss
More file actions
80 lines (69 loc) · 1.93 KB
/
content-tools.scss
File metadata and controls
80 lines (69 loc) · 1.93 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
@charset "UTF-8";
/* Vendor */
@import "../../external/styles/content-edit";
@import "../../external/styles/bourbon/bourbon";
/* Settings */
@import "settings";
/* UI */
@import "ui/ui";
/**
* The highlight class below is used to highlight editable regions within the
* page to users to help them see what they can edit. It's slightly unusual in
* that it's specified as a modifier of `ct`.
*/
@include keyframes(highlight) {
0% {
outline-color: rgba(white, 0);
@include transform(background-color);
}
25% {
outline-color: $highlight-color;
@include transform(background-color);
}
50% {
outline-color: $highlight-color;
@include transform(background-color);
}
100% {
outline-color: rgba(white, 0);
@include transform(background-color);
}
}
@mixin animation--highlight() {
@include animation(highlight 0.5s ease-in);
@include animation-iteration-count(infinite);
@include animation-fill-mode(forwards);
}
.ct-app {
@include box-sizing(border-box);
* {
&,
&:before,
&:after {
@include box-sizing(border-box);
}
}
}
.ct--highlight {
outline: 4px solid $highlight-color;
@include animation--highlight();
}
/**
* When applied to the `body` this class prevents the page from scrolling. This
* can be a useful trait when overlaying content such as a dialog where
* scrolling is either undesirable or relevant only to the overlayed content.
*/
.ct--no-scroll {
overflow: hidden;
}
/**
* Sometimes it necessary to take focus from an element such as when asking a
* user to provide a URL for a link. To provide an indication of the element's
* selection before focus was list this class can be applied to a `span`
* surrounding the element's selection.
*
* Once focus is returned to the element the class should be removed.
*/
.ct--pseudo-select {
background: rgba(black, 0.1);
}