uikit3-rails 0.1.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +7 -0
- data/.gitignore +9 -0
- data/.travis.yml +5 -0
- data/Gemfile +4 -0
- data/LICENSE.txt +21 -0
- data/README.md +41 -0
- data/Rakefile +10 -0
- data/assets/images/backgrounds/accordion-close.svg +4 -0
- data/assets/images/backgrounds/accordion-open.svg +3 -0
- data/assets/images/backgrounds/divider-icon.svg +3 -0
- data/assets/images/backgrounds/form-checkbox-indeterminate.svg +3 -0
- data/assets/images/backgrounds/form-checkbox.svg +3 -0
- data/assets/images/backgrounds/form-radio.svg +3 -0
- data/assets/images/backgrounds/form-select.svg +4 -0
- data/assets/images/backgrounds/list-bullet.svg +3 -0
- data/assets/images/backgrounds/nav-parent-close.svg +3 -0
- data/assets/images/backgrounds/nav-parent-open.svg +3 -0
- data/assets/images/components/close-large.svg +4 -0
- data/assets/images/components/close.svg +4 -0
- data/assets/images/components/navbar-toggle.svg +5 -0
- data/assets/images/components/overlay.svg +4 -0
- data/assets/images/components/pagination-next.svg +3 -0
- data/assets/images/components/pagination-previous.svg +3 -0
- data/assets/images/components/search-default.svg +4 -0
- data/assets/images/components/search-large.svg +4 -0
- data/assets/images/components/search-navbar.svg +4 -0
- data/assets/images/components/slidenav-large-next.svg +3 -0
- data/assets/images/components/slidenav-large-previous.svg +3 -0
- data/assets/images/components/slidenav-next.svg +3 -0
- data/assets/images/components/slidenav-previous.svg +3 -0
- data/assets/images/components/spinner.svg +3 -0
- data/assets/images/components/totop.svg +3 -0
- data/assets/images/symbols/album.svg +5 -0
- data/assets/images/symbols/arrow-down.svg +4 -0
- data/assets/images/symbols/arrow-left.svg +4 -0
- data/assets/images/symbols/arrow-right.svg +4 -0
- data/assets/images/symbols/arrow-up.svg +4 -0
- data/assets/images/symbols/ban.svg +4 -0
- data/assets/images/symbols/behance.svg +5 -0
- data/assets/images/symbols/bell.svg +4 -0
- data/assets/images/symbols/bold.svg +3 -0
- data/assets/images/symbols/bolt.svg +3 -0
- data/assets/images/symbols/bookmark.svg +3 -0
- data/assets/images/symbols/calendar.svg +5 -0
- data/assets/images/symbols/camera.svg +4 -0
- data/assets/images/symbols/cart.svg +5 -0
- data/assets/images/symbols/check.svg +3 -0
- data/assets/images/symbols/chevron-down.svg +3 -0
- data/assets/images/symbols/chevron-left.svg +3 -0
- data/assets/images/symbols/chevron-right.svg +3 -0
- data/assets/images/symbols/chevron-up.svg +3 -0
- data/assets/images/symbols/clock.svg +5 -0
- data/assets/images/symbols/close.svg +4 -0
- data/assets/images/symbols/cloud-download.svg +5 -0
- data/assets/images/symbols/cloud-upload.svg +5 -0
- data/assets/images/symbols/code.svg +4 -0
- data/assets/images/symbols/cog.svg +4 -0
- data/assets/images/symbols/comment.svg +3 -0
- data/assets/images/symbols/commenting.svg +6 -0
- data/assets/images/symbols/comments.svg +4 -0
- data/assets/images/symbols/copy.svg +4 -0
- data/assets/images/symbols/credit-card.svg +4 -0
- data/assets/images/symbols/database.svg +6 -0
- data/assets/images/symbols/desktop.svg +6 -0
- data/assets/images/symbols/download.svg +5 -0
- data/assets/images/symbols/dribbble.svg +6 -0
- data/assets/images/symbols/expand.svg +6 -0
- data/assets/images/symbols/facebook.svg +3 -0
- data/assets/images/symbols/file-edit.svg +4 -0
- data/assets/images/symbols/file.svg +3 -0
- data/assets/images/symbols/flickr.svg +4 -0
- data/assets/images/symbols/folder.svg +3 -0
- data/assets/images/symbols/forward.svg +3 -0
- data/assets/images/symbols/foursquare.svg +3 -0
- data/assets/images/symbols/future.svg +6 -0
- data/assets/images/symbols/git-branch.svg +6 -0
- data/assets/images/symbols/git-fork.svg +6 -0
- data/assets/images/symbols/github-alt.svg +3 -0
- data/assets/images/symbols/github.svg +3 -0
- data/assets/images/symbols/google-plus.svg +4 -0
- data/assets/images/symbols/google.svg +3 -0
- data/assets/images/symbols/grid.svg +11 -0
- data/assets/images/symbols/happy.svg +6 -0
- data/assets/images/symbols/hashtag.svg +3 -0
- data/assets/images/symbols/heart.svg +3 -0
- data/assets/images/symbols/history.svg +6 -0
- data/assets/images/symbols/home.svg +5 -0
- data/assets/images/symbols/image.svg +6 -0
- data/assets/images/symbols/info.svg +4 -0
- data/assets/images/symbols/instagram.svg +5 -0
- data/assets/images/symbols/italic.svg +3 -0
- data/assets/images/symbols/joomla.svg +6 -0
- data/assets/images/symbols/laptop.svg +4 -0
- data/assets/images/symbols/lifesaver.svg +3 -0
- data/assets/images/symbols/link.svg +5 -0
- data/assets/images/symbols/linkedin.svg +4 -0
- data/assets/images/symbols/list.svg +8 -0
- data/assets/images/symbols/location.svg +4 -0
- data/assets/images/symbols/lock.svg +4 -0
- data/assets/images/symbols/mail.svg +4 -0
- data/assets/images/symbols/menu.svg +5 -0
- data/assets/images/symbols/minus-circle.svg +4 -0
- data/assets/images/symbols/minus.svg +3 -0
- data/assets/images/symbols/more-vertical.svg +5 -0
- data/assets/images/symbols/more.svg +5 -0
- data/assets/images/symbols/move.svg +8 -0
- data/assets/images/symbols/nut.svg +4 -0
- data/assets/images/symbols/pagekit.svg +3 -0
- data/assets/images/symbols/paint-bucket.svg +5 -0
- data/assets/images/symbols/pencil.svg +4 -0
- data/assets/images/symbols/phone-landscape.svg +4 -0
- data/assets/images/symbols/phone-receiver.svg +3 -0
- data/assets/images/symbols/phone.svg +4 -0
- data/assets/images/symbols/pinterest.svg +3 -0
- data/assets/images/symbols/play-circle.svg +4 -0
- data/assets/images/symbols/play.svg +3 -0
- data/assets/images/symbols/plus-circle.svg +5 -0
- data/assets/images/symbols/plus.svg +4 -0
- data/assets/images/symbols/pull.svg +5 -0
- data/assets/images/symbols/push.svg +5 -0
- data/assets/images/symbols/question.svg +5 -0
- data/assets/images/symbols/quote-right.svg +4 -0
- data/assets/images/symbols/refresh.svg +4 -0
- data/assets/images/symbols/reply.svg +3 -0
- data/assets/images/symbols/rss.svg +5 -0
- data/assets/images/symbols/search.svg +4 -0
- data/assets/images/symbols/server.svg +15 -0
- data/assets/images/symbols/settings.svg +11 -0
- data/assets/images/symbols/shrink.svg +6 -0
- data/assets/images/symbols/sign-in.svg +4 -0
- data/assets/images/symbols/sign-out.svg +4 -0
- data/assets/images/symbols/social.svg +7 -0
- data/assets/images/symbols/soundcloud.svg +6 -0
- data/assets/images/symbols/star.svg +3 -0
- data/assets/images/symbols/strikethrough.svg +4 -0
- data/assets/images/symbols/table.svg +6 -0
- data/assets/images/symbols/tablet-landscape.svg +4 -0
- data/assets/images/symbols/tablet.svg +4 -0
- data/assets/images/symbols/tag.svg +4 -0
- data/assets/images/symbols/thumbnails.svg +6 -0
- data/assets/images/symbols/trash.svg +7 -0
- data/assets/images/symbols/triangle-down.svg +3 -0
- data/assets/images/symbols/triangle-left.svg +3 -0
- data/assets/images/symbols/triangle-right.svg +3 -0
- data/assets/images/symbols/triangle-up.svg +3 -0
- data/assets/images/symbols/tumblr.svg +3 -0
- data/assets/images/symbols/tv.svg +4 -0
- data/assets/images/symbols/twitter.svg +3 -0
- data/assets/images/symbols/uikit.svg +4 -0
- data/assets/images/symbols/unlock.svg +4 -0
- data/assets/images/symbols/upload.svg +5 -0
- data/assets/images/symbols/user.svg +4 -0
- data/assets/images/symbols/users.svg +5 -0
- data/assets/images/symbols/video-camera.svg +4 -0
- data/assets/images/symbols/vimeo.svg +3 -0
- data/assets/images/symbols/warning.svg +5 -0
- data/assets/images/symbols/whatsapp.svg +3 -0
- data/assets/images/symbols/wordpress.svg +3 -0
- data/assets/images/symbols/world.svg +7 -0
- data/assets/images/symbols/xing.svg +4 -0
- data/assets/images/symbols/youtube.svg +3 -0
- data/assets/javascripts/uikit.js +6398 -0
- data/assets/stylesheets/components/_import.components.less +55 -0
- data/assets/stylesheets/components/_import.utilities.less +19 -0
- data/assets/stylesheets/components/accordion.less +110 -0
- data/assets/stylesheets/components/alert.less +147 -0
- data/assets/stylesheets/components/align.less +142 -0
- data/assets/stylesheets/components/animation.less +638 -0
- data/assets/stylesheets/components/article.less +113 -0
- data/assets/stylesheets/components/background.less +136 -0
- data/assets/stylesheets/components/badge.less +104 -0
- data/assets/stylesheets/components/base.less +737 -0
- data/assets/stylesheets/components/breadcrumb.less +150 -0
- data/assets/stylesheets/components/button.less +541 -0
- data/assets/stylesheets/components/card.less +363 -0
- data/assets/stylesheets/components/close.less +119 -0
- data/assets/stylesheets/components/column.less +285 -0
- data/assets/stylesheets/components/comment.less +171 -0
- data/assets/stylesheets/components/container.less +106 -0
- data/assets/stylesheets/components/cover.less +56 -0
- data/assets/stylesheets/components/description-list.less +71 -0
- data/assets/stylesheets/components/divider.less +147 -0
- data/assets/stylesheets/components/dotnav.less +190 -0
- data/assets/stylesheets/components/drop.less +74 -0
- data/assets/stylesheets/components/dropdown.less +150 -0
- data/assets/stylesheets/components/flex.less +335 -0
- data/assets/stylesheets/components/form.less +836 -0
- data/assets/stylesheets/components/grid.less +363 -0
- data/assets/stylesheets/components/heading.less +238 -0
- data/assets/stylesheets/components/icon.less +242 -0
- data/assets/stylesheets/components/iconnav.less +166 -0
- data/assets/stylesheets/components/inverse.less +52 -0
- data/assets/stylesheets/components/label.less +110 -0
- data/assets/stylesheets/components/link.less +91 -0
- data/assets/stylesheets/components/list.less +205 -0
- data/assets/stylesheets/components/margin.less +161 -0
- data/assets/stylesheets/components/mixin.less +20 -0
- data/assets/stylesheets/components/modal.less +403 -0
- data/assets/stylesheets/components/nav.less +438 -0
- data/assets/stylesheets/components/navbar.less +596 -0
- data/assets/stylesheets/components/notification.less +190 -0
- data/assets/stylesheets/components/offcanvas.less +250 -0
- data/assets/stylesheets/components/overlay.less +89 -0
- data/assets/stylesheets/components/padding.less +79 -0
- data/assets/stylesheets/components/pagination.less +169 -0
- data/assets/stylesheets/components/placeholder.less +45 -0
- data/assets/stylesheets/components/position.less +221 -0
- data/assets/stylesheets/components/print.less +61 -0
- data/assets/stylesheets/components/progress.less +102 -0
- data/assets/stylesheets/components/search.less +442 -0
- data/assets/stylesheets/components/section.less +230 -0
- data/assets/stylesheets/components/slidenav.less +145 -0
- data/assets/stylesheets/components/sortable.less +101 -0
- data/assets/stylesheets/components/spinner.less +103 -0
- data/assets/stylesheets/components/sticky.less +57 -0
- data/assets/stylesheets/components/subnav.less +305 -0
- data/assets/stylesheets/components/switcher.less +47 -0
- data/assets/stylesheets/components/tab.less +226 -0
- data/assets/stylesheets/components/table.less +207 -0
- data/assets/stylesheets/components/text.less +254 -0
- data/assets/stylesheets/components/tooltip.less +84 -0
- data/assets/stylesheets/components/totop.less +97 -0
- data/assets/stylesheets/components/transition.less +187 -0
- data/assets/stylesheets/components/utility.less +516 -0
- data/assets/stylesheets/components/variables.less +117 -0
- data/assets/stylesheets/components/visibility.less +109 -0
- data/assets/stylesheets/components/width.less +418 -0
- data/assets/stylesheets/theme/_import.less +72 -0
- data/assets/stylesheets/theme/accordion.less +76 -0
- data/assets/stylesheets/theme/alert.less +76 -0
- data/assets/stylesheets/theme/align.less +14 -0
- data/assets/stylesheets/theme/animation.less +14 -0
- data/assets/stylesheets/theme/article.less +60 -0
- data/assets/stylesheets/theme/background.less +14 -0
- data/assets/stylesheets/theme/badge.less +29 -0
- data/assets/stylesheets/theme/base.less +134 -0
- data/assets/stylesheets/theme/breadcrumb.less +42 -0
- data/assets/stylesheets/theme/button.less +221 -0
- data/assets/stylesheets/theme/card.less +193 -0
- data/assets/stylesheets/theme/close.less +34 -0
- data/assets/stylesheets/theme/column.less +14 -0
- data/assets/stylesheets/theme/comment.less +72 -0
- data/assets/stylesheets/theme/container.less +14 -0
- data/assets/stylesheets/theme/description-list.less +36 -0
- data/assets/stylesheets/theme/divider.less +41 -0
- data/assets/stylesheets/theme/dotnav.less +41 -0
- data/assets/stylesheets/theme/drop.less +14 -0
- data/assets/stylesheets/theme/dropdown.less +45 -0
- data/assets/stylesheets/theme/form.less +150 -0
- data/assets/stylesheets/theme/grid.less +14 -0
- data/assets/stylesheets/theme/heading.less +59 -0
- data/assets/stylesheets/theme/icon.less +55 -0
- data/assets/stylesheets/theme/iconnav.less +34 -0
- data/assets/stylesheets/theme/inverse.less +14 -0
- data/assets/stylesheets/theme/label.less +46 -0
- data/assets/stylesheets/theme/link.less +35 -0
- data/assets/stylesheets/theme/list.less +49 -0
- data/assets/stylesheets/theme/margin.less +14 -0
- data/assets/stylesheets/theme/modal.less +95 -0
- data/assets/stylesheets/theme/nav.less +94 -0
- data/assets/stylesheets/theme/navbar.less +175 -0
- data/assets/stylesheets/theme/notification.less +44 -0
- data/assets/stylesheets/theme/offcanvas.less +26 -0
- data/assets/stylesheets/theme/overlay.less +33 -0
- data/assets/stylesheets/theme/padding.less +14 -0
- data/assets/stylesheets/theme/pagination.less +44 -0
- data/assets/stylesheets/theme/placeholder.less +29 -0
- data/assets/stylesheets/theme/position.less +14 -0
- data/assets/stylesheets/theme/progress.less +27 -0
- data/assets/stylesheets/theme/search.less +67 -0
- data/assets/stylesheets/theme/section.less +34 -0
- data/assets/stylesheets/theme/slidenav.less +49 -0
- data/assets/stylesheets/theme/sortable.less +38 -0
- data/assets/stylesheets/theme/spinner.less +14 -0
- data/assets/stylesheets/theme/sticky.less +14 -0
- data/assets/stylesheets/theme/subnav.less +81 -0
- data/assets/stylesheets/theme/tab.less +139 -0
- data/assets/stylesheets/theme/table.less +65 -0
- data/assets/stylesheets/theme/text.less +60 -0
- data/assets/stylesheets/theme/tooltip.less +20 -0
- data/assets/stylesheets/theme/totop.less +35 -0
- data/assets/stylesheets/theme/transition.less +14 -0
- data/assets/stylesheets/theme/utility.less +46 -0
- data/assets/stylesheets/theme/variables.less +36 -0
- data/assets/stylesheets/theme/width.less +14 -0
- data/assets/stylesheets/uikit.less +17 -0
- data/assets/stylesheets/uikit.theme.less +23 -0
- data/bin/console +14 -0
- data/bin/setup +8 -0
- data/lib/uikit3/rails.rb +8 -0
- data/lib/uikit3/rails/version.rb +5 -0
- data/uikit3-rails.gemspec +29 -0
- metadata +391 -0
@@ -0,0 +1,242 @@
|
|
1
|
+
// Name: Icon
|
2
|
+
// Description: Component to create icons
|
3
|
+
//
|
4
|
+
// Component: `uk-icon`
|
5
|
+
//
|
6
|
+
// Modifiers: `uk-icon-image`
|
7
|
+
// `uk-icon-link`
|
8
|
+
// `uk-icon-button`
|
9
|
+
//
|
10
|
+
// States: `uk-preserve`
|
11
|
+
//
|
12
|
+
// ========================================================================
|
13
|
+
|
14
|
+
|
15
|
+
// Variables
|
16
|
+
// ========================================================================
|
17
|
+
|
18
|
+
@icon-image-size: 20px;
|
19
|
+
|
20
|
+
@icon-link-color: @global-muted-color;
|
21
|
+
@icon-link-hover-color: @global-color;
|
22
|
+
@icon-link-active-color: darken(@global-color, 5%);
|
23
|
+
|
24
|
+
@icon-button-size: 36px;
|
25
|
+
@icon-button-border-radius: 500px;
|
26
|
+
@icon-button-background: @global-muted-background;
|
27
|
+
@icon-button-color: @global-muted-color;
|
28
|
+
|
29
|
+
@icon-button-hover-background: darken(@icon-button-background, 5%);
|
30
|
+
@icon-button-hover-color: @global-color;
|
31
|
+
|
32
|
+
@icon-button-active-background: darken(@icon-button-background, 10%);
|
33
|
+
@icon-button-active-color: @global-color;
|
34
|
+
|
35
|
+
@internal-icon-image: "../../../dist/images/icons.svg";
|
36
|
+
|
37
|
+
|
38
|
+
/* ========================================================================
|
39
|
+
Component: Icon
|
40
|
+
========================================================================== */
|
41
|
+
|
42
|
+
/*
|
43
|
+
* Pass image path to JS
|
44
|
+
*/
|
45
|
+
|
46
|
+
.uk-icon::before { background-image: url("@{internal-icon-image}"); }
|
47
|
+
|
48
|
+
/*
|
49
|
+
* 1. Fill all SVG elements with the current text color if no `fill` attribute is set
|
50
|
+
* 2. Let the container fit the height of the icon
|
51
|
+
*/
|
52
|
+
|
53
|
+
.uk-icon {
|
54
|
+
display: inline-block;
|
55
|
+
/* 1 */
|
56
|
+
fill: currentcolor;
|
57
|
+
/* 2 */
|
58
|
+
line-height: 0;
|
59
|
+
}
|
60
|
+
|
61
|
+
/*
|
62
|
+
* Set the fill and stroke color of all SVG elements to the current text color
|
63
|
+
*/
|
64
|
+
|
65
|
+
.uk-icon [fill*='#']:not(.uk-preserve) { fill: currentcolor; }
|
66
|
+
.uk-icon [stroke*='#']:not(.uk-preserve) { stroke: currentcolor; }
|
67
|
+
|
68
|
+
/*
|
69
|
+
* Fix Firefox blurry SVG rendering: https://bugzilla.mozilla.org/show_bug.cgi?id=1046835
|
70
|
+
*/
|
71
|
+
|
72
|
+
.uk-icon > * { transform: translate(0,0); }
|
73
|
+
|
74
|
+
|
75
|
+
/* Image modifier
|
76
|
+
========================================================================== */
|
77
|
+
|
78
|
+
/*
|
79
|
+
* Display images in icon dimensions
|
80
|
+
*/
|
81
|
+
|
82
|
+
.uk-icon-image {
|
83
|
+
width: @icon-image-size;
|
84
|
+
height: @icon-image-size;
|
85
|
+
background-position: 50% 50%;
|
86
|
+
background-repeat: no-repeat;
|
87
|
+
background-size: contain;
|
88
|
+
vertical-align: middle;
|
89
|
+
}
|
90
|
+
|
91
|
+
|
92
|
+
/* Style modifiers
|
93
|
+
========================================================================== */
|
94
|
+
|
95
|
+
/*
|
96
|
+
* Link
|
97
|
+
*/
|
98
|
+
|
99
|
+
.uk-icon-link {
|
100
|
+
color: @icon-link-color;
|
101
|
+
.hook-icon-link;
|
102
|
+
}
|
103
|
+
|
104
|
+
.uk-icon-link:hover,
|
105
|
+
.uk-icon-link:focus {
|
106
|
+
color: @icon-link-hover-color;
|
107
|
+
outline: none;
|
108
|
+
.hook-icon-link-hover;
|
109
|
+
}
|
110
|
+
|
111
|
+
/* OnClick + Active */
|
112
|
+
.uk-icon-link:active,
|
113
|
+
.uk-active > .uk-icon-link {
|
114
|
+
color: @icon-link-active-color;
|
115
|
+
.hook-icon-link-active;
|
116
|
+
}
|
117
|
+
|
118
|
+
/*
|
119
|
+
* Button
|
120
|
+
* 1. Center icon vertically and horizontally
|
121
|
+
*/
|
122
|
+
|
123
|
+
.uk-icon-button {
|
124
|
+
box-sizing: border-box;
|
125
|
+
width: @icon-button-size;
|
126
|
+
height: @icon-button-size;
|
127
|
+
border-radius: @icon-button-border-radius;
|
128
|
+
background: @icon-button-background;
|
129
|
+
color: @icon-button-color;
|
130
|
+
vertical-align: middle;
|
131
|
+
/* 1 */
|
132
|
+
display: -ms-inline-flexbox;
|
133
|
+
display: -webkit-inline-flex;
|
134
|
+
display: inline-flex;
|
135
|
+
-ms-flex-pack: center;
|
136
|
+
-webkit-justify-content: center;
|
137
|
+
justify-content: center;
|
138
|
+
-ms-flex-align: center;
|
139
|
+
-webkit-align-items: center;
|
140
|
+
align-items: center;
|
141
|
+
.hook-icon-button;
|
142
|
+
}
|
143
|
+
|
144
|
+
/* Hover + Focus */
|
145
|
+
.uk-icon-button:hover,
|
146
|
+
.uk-icon-button:focus {
|
147
|
+
background-color: @icon-button-hover-background;
|
148
|
+
color: @icon-button-hover-color;
|
149
|
+
outline: none;
|
150
|
+
.hook-icon-button-hover;
|
151
|
+
}
|
152
|
+
|
153
|
+
/* OnClick + Active */
|
154
|
+
.uk-icon-button:active,
|
155
|
+
.uk-active > .uk-icon-button {
|
156
|
+
background-color: @icon-button-active-background;
|
157
|
+
color: @icon-button-active-color;
|
158
|
+
.hook-icon-button-active;
|
159
|
+
}
|
160
|
+
|
161
|
+
|
162
|
+
// Hooks
|
163
|
+
// ========================================================================
|
164
|
+
|
165
|
+
.hook-icon-misc;
|
166
|
+
|
167
|
+
.hook-icon-link() {}
|
168
|
+
.hook-icon-link-hover() {}
|
169
|
+
.hook-icon-link-active() {}
|
170
|
+
.hook-icon-button() {}
|
171
|
+
.hook-icon-button-hover() {}
|
172
|
+
.hook-icon-button-active() {}
|
173
|
+
.hook-icon-misc() {}
|
174
|
+
|
175
|
+
|
176
|
+
// Inverse
|
177
|
+
// ========================================================================
|
178
|
+
|
179
|
+
@inverse-icon-link-color: @inverse-global-muted-color;
|
180
|
+
@inverse-icon-link-hover-color: @inverse-global-color;
|
181
|
+
@inverse-icon-link-active-color: @inverse-global-color;
|
182
|
+
@inverse-icon-button-background: @inverse-global-muted-background;
|
183
|
+
@inverse-icon-button-color: @inverse-global-muted-color;
|
184
|
+
@inverse-icon-button-hover-background: darken(@inverse-icon-button-background, 5%);
|
185
|
+
@inverse-icon-button-hover-color: @inverse-global-color;
|
186
|
+
@inverse-icon-button-active-background: darken(@inverse-icon-button-background, 10%);
|
187
|
+
@inverse-icon-button-active-color: @inverse-global-color;
|
188
|
+
|
189
|
+
.hook-inverse() {
|
190
|
+
|
191
|
+
//
|
192
|
+
// Link
|
193
|
+
//
|
194
|
+
|
195
|
+
.uk-icon-link {
|
196
|
+
color: @inverse-icon-link-color;
|
197
|
+
.hook-inverse-icon-link;
|
198
|
+
}
|
199
|
+
|
200
|
+
.uk-icon-link:hover,
|
201
|
+
.uk-icon-link:focus {
|
202
|
+
color: @inverse-icon-link-hover-color;
|
203
|
+
.hook-inverse-icon-link-hover;
|
204
|
+
}
|
205
|
+
|
206
|
+
.uk-icon-link:active,
|
207
|
+
.uk-active > .uk-icon-link {
|
208
|
+
color: @inverse-icon-link-active-color;
|
209
|
+
.hook-inverse-icon-link-active;
|
210
|
+
}
|
211
|
+
|
212
|
+
//
|
213
|
+
// Button
|
214
|
+
//
|
215
|
+
|
216
|
+
.uk-icon-button {
|
217
|
+
background-color: @inverse-icon-button-background;
|
218
|
+
color: @inverse-icon-button-color;
|
219
|
+
.hook-inverse-icon-button;
|
220
|
+
}
|
221
|
+
|
222
|
+
.uk-icon-button:hover,
|
223
|
+
.uk-icon-button:focus {
|
224
|
+
background-color: @inverse-icon-button-hover-background;
|
225
|
+
color: @inverse-icon-button-hover-color;
|
226
|
+
.hook-inverse-icon-button-hover;
|
227
|
+
}
|
228
|
+
|
229
|
+
.uk-icon-button:active {
|
230
|
+
background-color: @inverse-icon-button-active-background;
|
231
|
+
color: @inverse-icon-button-active-color;
|
232
|
+
.hook-inverse-icon-button-active;
|
233
|
+
}
|
234
|
+
|
235
|
+
}
|
236
|
+
|
237
|
+
.hook-inverse-icon-link() {}
|
238
|
+
.hook-inverse-icon-link-hover() {}
|
239
|
+
.hook-inverse-icon-link-active() {}
|
240
|
+
.hook-inverse-icon-button() {}
|
241
|
+
.hook-inverse-icon-button-hover() {}
|
242
|
+
.hook-inverse-icon-button-active() {}
|
@@ -0,0 +1,166 @@
|
|
1
|
+
// Name: Iconnav
|
2
|
+
// Description: Component to create icon navigations
|
3
|
+
//
|
4
|
+
// Component: `uk-iconnav`
|
5
|
+
//
|
6
|
+
// Modifier: `uk-iconnav-vertical`
|
7
|
+
//
|
8
|
+
// States: `uk-active`
|
9
|
+
//
|
10
|
+
// ========================================================================
|
11
|
+
|
12
|
+
|
13
|
+
// Variables
|
14
|
+
// ========================================================================
|
15
|
+
|
16
|
+
@iconnav-margin-horizontal: @global-small-margin;
|
17
|
+
@iconnav-margin-vertical: @iconnav-margin-horizontal;
|
18
|
+
|
19
|
+
@iconnav-item-color: @global-muted-color;
|
20
|
+
|
21
|
+
@iconnav-item-hover-color: @global-color;
|
22
|
+
|
23
|
+
@iconnav-item-active-color: @global-color;
|
24
|
+
|
25
|
+
|
26
|
+
/* ========================================================================
|
27
|
+
Component: Iconnav
|
28
|
+
========================================================================== */
|
29
|
+
|
30
|
+
/*
|
31
|
+
* 1. Allow items to wrap into the next line
|
32
|
+
* 2. Reset lists
|
33
|
+
* 3. Gutter
|
34
|
+
*/
|
35
|
+
|
36
|
+
.uk-iconnav {
|
37
|
+
display: -ms-flexbox;
|
38
|
+
display: -webkit-flex;
|
39
|
+
display: flex;
|
40
|
+
/* 1 */
|
41
|
+
-ms-flex-wrap: wrap;
|
42
|
+
-webkit-flex-wrap: wrap;
|
43
|
+
flex-wrap: wrap;
|
44
|
+
/* 2 */
|
45
|
+
margin: 0;
|
46
|
+
padding: 0;
|
47
|
+
list-style: none;
|
48
|
+
/* 3 */
|
49
|
+
margin-left: -@iconnav-margin-horizontal;
|
50
|
+
.hook-iconnav;
|
51
|
+
}
|
52
|
+
|
53
|
+
/*
|
54
|
+
* 1. Space is allocated solely based on content dimensions: 0 0 auto
|
55
|
+
* 2. Gutter
|
56
|
+
*/
|
57
|
+
|
58
|
+
.uk-iconnav > * {
|
59
|
+
/* 1 */
|
60
|
+
-ms-flex: none;
|
61
|
+
-webkit-flex: none;
|
62
|
+
flex: none;
|
63
|
+
/* 2 */
|
64
|
+
padding-left: @iconnav-margin-horizontal;
|
65
|
+
}
|
66
|
+
|
67
|
+
|
68
|
+
/* Items
|
69
|
+
========================================================================== */
|
70
|
+
|
71
|
+
/*
|
72
|
+
* Items
|
73
|
+
* 1. Prevent gap if child element is `inline-block`, e.g. an icon
|
74
|
+
* 2. Style
|
75
|
+
*/
|
76
|
+
|
77
|
+
.uk-iconnav > * > * {
|
78
|
+
/* 1 */
|
79
|
+
display: block;
|
80
|
+
/* 2 */
|
81
|
+
color: @iconnav-item-color;
|
82
|
+
.hook-iconnav-item;
|
83
|
+
}
|
84
|
+
|
85
|
+
/* Hover + Focus */
|
86
|
+
.uk-iconnav > * > :hover,
|
87
|
+
.uk-iconnav > * > :focus {
|
88
|
+
color: @iconnav-item-hover-color;
|
89
|
+
outline: none;
|
90
|
+
.hook-iconnav-item-hover;
|
91
|
+
}
|
92
|
+
|
93
|
+
/* Active */
|
94
|
+
.uk-iconnav > .uk-active > * {
|
95
|
+
color: @iconnav-item-active-color;
|
96
|
+
.hook-iconnav-item-active;
|
97
|
+
}
|
98
|
+
|
99
|
+
|
100
|
+
/* Modifier: 'uk-iconnav-vertical'
|
101
|
+
========================================================================== */
|
102
|
+
|
103
|
+
/*
|
104
|
+
* 1. Change direction
|
105
|
+
* 2. Gutter
|
106
|
+
*/
|
107
|
+
|
108
|
+
.uk-iconnav-vertical {
|
109
|
+
/* 1 */
|
110
|
+
-ms-flex-direction: column;
|
111
|
+
-webkit-flex-direction: column;
|
112
|
+
flex-direction: column;
|
113
|
+
/* 2 */
|
114
|
+
margin-left: 0;
|
115
|
+
margin-top: -@iconnav-margin-vertical;
|
116
|
+
}
|
117
|
+
|
118
|
+
/* 2 */
|
119
|
+
.uk-iconnav-vertical > * {
|
120
|
+
padding-left: 0;
|
121
|
+
padding-top: @iconnav-margin-vertical;
|
122
|
+
}
|
123
|
+
|
124
|
+
|
125
|
+
// Hooks
|
126
|
+
// ========================================================================
|
127
|
+
|
128
|
+
.hook-iconnav-misc;
|
129
|
+
|
130
|
+
.hook-iconnav() {}
|
131
|
+
.hook-iconnav-item() {}
|
132
|
+
.hook-iconnav-item-hover() {}
|
133
|
+
.hook-iconnav-item-active() {}
|
134
|
+
.hook-iconnav-misc() {}
|
135
|
+
|
136
|
+
|
137
|
+
// Inverse
|
138
|
+
// ========================================================================
|
139
|
+
|
140
|
+
@inverse-iconnav-item-color: @inverse-global-muted-color;
|
141
|
+
@inverse-iconnav-item-hover-color: @inverse-global-color;
|
142
|
+
@inverse-iconnav-item-active-color: @inverse-global-color;
|
143
|
+
|
144
|
+
.hook-inverse() {
|
145
|
+
|
146
|
+
.uk-iconnav > * > * {
|
147
|
+
color: @inverse-iconnav-item-color;
|
148
|
+
.hook-inverse-iconnav-item;
|
149
|
+
}
|
150
|
+
|
151
|
+
.uk-iconnav > * > :hover,
|
152
|
+
.uk-iconnav > * > :focus {
|
153
|
+
color: @inverse-iconnav-item-hover-color;
|
154
|
+
.hook-inverse-iconnav-item-hover;
|
155
|
+
}
|
156
|
+
|
157
|
+
.uk-iconnav > .uk-active > * {
|
158
|
+
color: @inverse-iconnav-item-active-color;
|
159
|
+
.hook-inverse-iconnav-item-active;
|
160
|
+
}
|
161
|
+
|
162
|
+
}
|
163
|
+
|
164
|
+
.hook-inverse-iconnav-item() {}
|
165
|
+
.hook-inverse-iconnav-item-hover() {}
|
166
|
+
.hook-inverse-iconnav-item-active() {}
|
@@ -0,0 +1,52 @@
|
|
1
|
+
// Name: Inverse
|
2
|
+
// Description: Inverse component style for light or dark backgrounds
|
3
|
+
//
|
4
|
+
// Component: `uk-light`
|
5
|
+
// `uk-dark`
|
6
|
+
//
|
7
|
+
// ========================================================================
|
8
|
+
|
9
|
+
|
10
|
+
// Variables
|
11
|
+
// ========================================================================
|
12
|
+
|
13
|
+
@inverse-global-color-mode: light;
|
14
|
+
|
15
|
+
@inverse-global-color: fade(@global-inverse-color, 70%);
|
16
|
+
@inverse-global-emphasis-color: @global-inverse-color;
|
17
|
+
@inverse-global-muted-color: fade(@global-inverse-color, 50%);
|
18
|
+
@inverse-global-inverse-color: @global-color;
|
19
|
+
|
20
|
+
@inverse-global-primary-background: @global-inverse-color;
|
21
|
+
@inverse-global-muted-background: fade(@global-inverse-color, 10%);
|
22
|
+
|
23
|
+
@inverse-global-border: fade(@global-inverse-color, 20%);
|
24
|
+
|
25
|
+
|
26
|
+
/* ========================================================================
|
27
|
+
Component: Inverse
|
28
|
+
========================================================================== */
|
29
|
+
|
30
|
+
/*
|
31
|
+
* Implemented class depends on the general theme color
|
32
|
+
* `uk-light` is for light colors on dark backgrounds
|
33
|
+
* `uk-dark` is or dark colors on light backgrounds
|
34
|
+
*/
|
35
|
+
|
36
|
+
.uk-light when (@inverse-global-color-mode = light) {
|
37
|
+
|
38
|
+
.hook-inverse;
|
39
|
+
|
40
|
+
}
|
41
|
+
|
42
|
+
.uk-dark when (@inverse-global-color-mode = dark) {
|
43
|
+
|
44
|
+
.hook-inverse;
|
45
|
+
|
46
|
+
}
|
47
|
+
|
48
|
+
|
49
|
+
// Hooks
|
50
|
+
// ========================================================================
|
51
|
+
|
52
|
+
.hook-inverse() {}
|