rails_admin_featured_content_rails_6 1.0.4
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +7 -0
- data/.gitignore +8 -0
- data/CODE_OF_CONDUCT.md +74 -0
- data/Gemfile +4 -0
- data/LICENSE.txt +21 -0
- data/README.md +92 -0
- data/Rakefile +2 -0
- data/app/assets/images/fc-image-default.jpg +0 -0
- data/app/assets/images/fc-loading.svg +1 -0
- data/app/assets/images/fc-snippet-float-one.jpg +0 -0
- data/app/assets/images/fc-snippet-float-one.psd +0 -0
- data/app/assets/images/fc-snippet-float-three.jpg +0 -0
- data/app/assets/images/fc-snippet-float-three.psd +0 -0
- data/app/assets/images/fc-snippet-float-two.jpg +0 -0
- data/app/assets/images/fc-snippet-float-two.psd +0 -0
- data/app/assets/images/fc-snippet-four.jpg +0 -0
- data/app/assets/images/fc-snippet-four.psd +0 -0
- data/app/assets/images/fc-snippet-highlight.jpg +0 -0
- data/app/assets/images/fc-snippet-highlight.psd +0 -0
- data/app/assets/images/fc-snippet-one.jpg +0 -0
- data/app/assets/images/fc-snippet-one.psd +0 -0
- data/app/assets/images/fc-snippet-slide.jpg +0 -0
- data/app/assets/images/fc-snippet-slide.psd +0 -0
- data/app/assets/images/fc-snippet-text-one.jpg +0 -0
- data/app/assets/images/fc-snippet-text-one.psd +0 -0
- data/app/assets/images/fc-snippet-text-three.jpg +0 -0
- data/app/assets/images/fc-snippet-text-three.psd +0 -0
- data/app/assets/images/fc-snippet-text-two.jpg +0 -0
- data/app/assets/images/fc-snippet-text-two.psd +0 -0
- data/app/assets/images/fc-snippet-text.jpg +0 -0
- data/app/assets/images/fc-snippet-text.psd +0 -0
- data/app/assets/images/fc-snippet-three.jpg +0 -0
- data/app/assets/images/fc-snippet-three.psd +0 -0
- data/app/assets/images/fc-snippet-two.jpg +0 -0
- data/app/assets/images/fc-snippet-two.psd +0 -0
- data/app/assets/javascripts/rails_admin/featured_content.js.erb +574 -0
- data/app/assets/javascripts/rails_admin/helpers/autocomplete.js +21 -0
- data/app/assets/javascripts/rails_admin/helpers/events.js +4 -0
- data/app/assets/javascripts/rails_admin/helpers/generate_radom_id.js +4 -0
- data/app/assets/javascripts/rails_admin/helpers/slide.js.erb +77 -0
- data/app/assets/javascripts/rails_admin/helpers/upload_file.js +32 -0
- data/app/assets/stylesheets/rails_admin/featured_content.scss +661 -0
- data/app/controllers/rails_admin_featured_content/featured_content_controller.rb +37 -0
- data/app/models/.keep +0 -0
- data/app/models/rails_admin_featured_content/featured_content.rb +16 -0
- data/app/models/rails_admin_featured_content/featured_content_image.rb +11 -0
- data/app/views/.gitkeep +0 -0
- data/app/views/rails_admin/main/featured_content.html.erb +113 -0
- data/bin/console +14 -0
- data/bin/setup +8 -0
- data/config/initializers/assets.rb +15 -0
- data/config/locales/featured_content.en.yml +32 -0
- data/config/locales/featured_content.pt-BR.yml +32 -0
- data/config/routes.rb +9 -0
- data/lib/generators/rails_admin_featured_content_generator.rb +36 -0
- data/lib/generators/templates/create_featured_content_images_migration.rb +10 -0
- data/lib/generators/templates/create_featured_content_migration.rb +11 -0
- data/lib/generators/templates/featured_content_image_uploader.rb +64 -0
- data/lib/generators/templates/rails_admin_featured_content.rb +22 -0
- data/lib/rails_admin_featured_content_rails_6.rb +55 -0
- data/lib/rails_admin_featured_content_rails_6/engine.rb +22 -0
- data/lib/rails_admin_featured_content_rails_6/version.rb +3 -0
- data/rails_admin_featured_content_rails_6.gemspec +45 -0
- data/screenshots/image-1.png +0 -0
- data/vendor/assets/stylesheets/rails_admin_featured_content.scss +459 -0
- metadata +426 -0
@@ -0,0 +1,21 @@
|
|
1
|
+
function autocomplete(id) {
|
2
|
+
$('#' + id + ' input:text').autocomplete({
|
3
|
+
source: "search_content",
|
4
|
+
minLength: 5,
|
5
|
+
select: function(event, ui) {
|
6
|
+
console.log(ui.item);
|
7
|
+
$("#" + id + ' .fc-title').text(ui.item.title);
|
8
|
+
$("#" + id + ' .fc-text').text(ui.item.summary);
|
9
|
+
$("#" + id + ' .fc-caption').text(ui.item.content_builder_category.name);
|
10
|
+
$("#" + id + ' .fc-link').attr('href', '/noticias/'+ ui.item.content_builder_category.slug +'/' + ui.item.slug);
|
11
|
+
return false;
|
12
|
+
},
|
13
|
+
create: function () {
|
14
|
+
$(this).data('ui-autocomplete')._renderItem = function (ul, item) {
|
15
|
+
return $( "<li>" )
|
16
|
+
.append( "<a>" + item.title + "</a>" )
|
17
|
+
.appendTo( ul );
|
18
|
+
}
|
19
|
+
}
|
20
|
+
})
|
21
|
+
};
|
@@ -0,0 +1,77 @@
|
|
1
|
+
// slide active
|
2
|
+
function slideActive(container) {
|
3
|
+
if(container) {
|
4
|
+
container.owlCarousel({
|
5
|
+
singleItem: true,
|
6
|
+
slideSpeed: 500,
|
7
|
+
autoPlay: false,
|
8
|
+
stopOnHover: true,
|
9
|
+
paginationSpeed: 500,
|
10
|
+
rewindSpeed: 1000,
|
11
|
+
navigation: true,
|
12
|
+
touchDrag: false,
|
13
|
+
mouseDrag: false,
|
14
|
+
navigationText: ['‹','›']
|
15
|
+
});
|
16
|
+
}
|
17
|
+
};
|
18
|
+
|
19
|
+
// slide add
|
20
|
+
function slideAdd(row_id, reference) {
|
21
|
+
section_id = generateID();
|
22
|
+
|
23
|
+
var element = '<div class="fc-item fc-slide__owl" id="'+ section_id +'">';
|
24
|
+
element += '<input class="fc-search" type="text" name="search" placeholder="<%= I18n.t('admin.actions.featured_content.snippet.search_news') %>">';
|
25
|
+
element += '<div class="fc-slide__item">';
|
26
|
+
element += '<div class="fc-tools fc-tools--center">';
|
27
|
+
element += '<a class="fc-tools__btn fc-tools__btn--upload fa fa-camera" href="#'+ section_id + '"></a>';
|
28
|
+
element += '<a class="fc-tools__btn fc-tools__btn--slide-add fa fa-plus" data-row="'+ row_id +'" href="#'+ section_id +'"></a>';
|
29
|
+
element += '<a class="fc-tools__btn fc-tools__btn--slide-remove fa fa-trash" data-row="'+ row_id +'" href="#'+ section_id +'"></a>';
|
30
|
+
element += '</div>';
|
31
|
+
element += '<a href="#" class="fc-link fc-slide__link"></a>';
|
32
|
+
element += '<h2 class="fc-caption fc-slide__caption"></h2>';
|
33
|
+
element += '<figure class="fc-slide__figure">';
|
34
|
+
element += '<img class="fc-slide__image" src="<%= image_url'cb-image-default.jpg' %>">';
|
35
|
+
element += '<input class="fc-tools__input fc-tools__input--upload" type="file" name="image" id="'+ section_id +'">';
|
36
|
+
element += '</figure>';
|
37
|
+
element += '<div class="fc-slide__content">';
|
38
|
+
element += '<h1 class="fc-title fc-slide__title"></h1>';
|
39
|
+
element += '<p class="fc-text fc-slide__text"></p>';
|
40
|
+
element += '</div>';
|
41
|
+
element += '</section>';
|
42
|
+
element += '</div>';
|
43
|
+
element += '</div>';
|
44
|
+
|
45
|
+
var container = $('#'+ row_id +' .fc-slide');
|
46
|
+
|
47
|
+
container.data('owlCarousel').addItem(element, [0]);
|
48
|
+
container.data('owlCarousel').jumpTo(0);
|
49
|
+
|
50
|
+
autocomplete(section_id);
|
51
|
+
addEventToInputFile(section_id);
|
52
|
+
editable();
|
53
|
+
}
|
54
|
+
|
55
|
+
// slide destroy
|
56
|
+
function slideDestroy(container) {
|
57
|
+
if(container.length) {
|
58
|
+
for(var i = 0; i < container.length; i++) {
|
59
|
+
$(container[i]).data('owlCarousel').destroy();
|
60
|
+
}
|
61
|
+
}
|
62
|
+
}
|
63
|
+
|
64
|
+
// slide remove
|
65
|
+
function slideRemove(row_id, reference) {
|
66
|
+
var container = $('#'+ row_id +' .fc-slide');
|
67
|
+
var items = $('#'+ row_id +' .fc-slide__owl');
|
68
|
+
|
69
|
+
for(i = 0; i < items.length; i++) {
|
70
|
+
if('#' + items[i].id == reference.attr('href')) {
|
71
|
+
container.data('owlCarousel').removeItem(i);
|
72
|
+
container.data('owlCarousel').jumpTo(i);
|
73
|
+
|
74
|
+
break;
|
75
|
+
}
|
76
|
+
}
|
77
|
+
}
|
@@ -0,0 +1,32 @@
|
|
1
|
+
// upload file via ajax
|
2
|
+
function fileSelectAndUpload(evt) {
|
3
|
+
var file = evt.target.files[0];
|
4
|
+
var container = $('#' + evt.target.id);
|
5
|
+
|
6
|
+
if(file) {
|
7
|
+
var formData = new FormData();
|
8
|
+
formData.append('featured_content_image', file);
|
9
|
+
|
10
|
+
$.ajax({
|
11
|
+
url: 'create_images',
|
12
|
+
data: formData,
|
13
|
+
cache: false,
|
14
|
+
contentType: false,
|
15
|
+
processData: false,
|
16
|
+
type: 'PUT',
|
17
|
+
beforeSend: function() {
|
18
|
+
container.find('figure').append('<div class="fc-loading"></div>');
|
19
|
+
container.find($('.fc-tools--center')).addClass('fc-tools--disabled');
|
20
|
+
},
|
21
|
+
complete: function(){
|
22
|
+
$('.fc-loading').remove();
|
23
|
+
$('.fc-tools--center').removeClass('fc-tools--disabled');
|
24
|
+
}
|
25
|
+
}).done(function(e) {
|
26
|
+
console.log(e)
|
27
|
+
container.find('img').attr('src', e.thumb.url);
|
28
|
+
}).fail(function(e) {
|
29
|
+
alert('error: ' + e);
|
30
|
+
});
|
31
|
+
}
|
32
|
+
};
|
@@ -0,0 +1,661 @@
|
|
1
|
+
/*
|
2
|
+
*= require owl.carousel
|
3
|
+
*= require owl.theme
|
4
|
+
*/
|
5
|
+
|
6
|
+
@import 'medium-editor/medium-editor';
|
7
|
+
@import 'medium-editor/themes/bootstrap';
|
8
|
+
|
9
|
+
.fc-snippet {
|
10
|
+
position: fixed;
|
11
|
+
z-index: 400;
|
12
|
+
bottom: 54px;
|
13
|
+
left: 0;
|
14
|
+
right: 0;
|
15
|
+
|
16
|
+
width: 100%;
|
17
|
+
height: 100px;
|
18
|
+
padding: 10px 0;
|
19
|
+
background: #f8f8f8;
|
20
|
+
border-top: solid 1px rgba(0,0,0,.1);
|
21
|
+
overflow-y: scroll;
|
22
|
+
}
|
23
|
+
|
24
|
+
.fc-snippet__btn {
|
25
|
+
box-sizing: border-box;
|
26
|
+
float: left;
|
27
|
+
width: 25%;
|
28
|
+
padding: 10px;
|
29
|
+
|
30
|
+
text-align: center;
|
31
|
+
text-decoration: none;
|
32
|
+
|
33
|
+
transition: box-shadow .1s ease;
|
34
|
+
|
35
|
+
&:hover {
|
36
|
+
text-decoration: none;
|
37
|
+
box-shadow: 0 0 0 2px rgba(0,0,0,.1);
|
38
|
+
}
|
39
|
+
}
|
40
|
+
|
41
|
+
.fc-snippet__caption {
|
42
|
+
display: none;
|
43
|
+
padding: 5px;
|
44
|
+
|
45
|
+
color: rgba(0,0,0,.6);
|
46
|
+
font-size: 10px;
|
47
|
+
}
|
48
|
+
|
49
|
+
.fc-snippet__image {
|
50
|
+
width: 100%;
|
51
|
+
}
|
52
|
+
|
53
|
+
.fc-controls {
|
54
|
+
position: fixed;
|
55
|
+
z-index: 400;
|
56
|
+
bottom: 0;
|
57
|
+
right: 0;
|
58
|
+
|
59
|
+
width: 100%;
|
60
|
+
|
61
|
+
padding: 10px;
|
62
|
+
|
63
|
+
background: #f8f8f8;
|
64
|
+
border-top: solid 1px rgba(0,0,0,.1);
|
65
|
+
border-left: solid 1px rgba(0,0,0,.1);
|
66
|
+
|
67
|
+
.btn-block {
|
68
|
+
margin-top: 0;
|
69
|
+
width: auto !important;
|
70
|
+
}
|
71
|
+
|
72
|
+
.btn-right {
|
73
|
+
float: right;
|
74
|
+
}
|
75
|
+
|
76
|
+
.btn-left {
|
77
|
+
float: left;
|
78
|
+
}
|
79
|
+
}
|
80
|
+
|
81
|
+
.fc-tools {
|
82
|
+
margin-bottom: 10px;
|
83
|
+
|
84
|
+
border-radius: .4rem;
|
85
|
+
background: darken(#fff, 7%);
|
86
|
+
overflow: hidden;
|
87
|
+
|
88
|
+
text-align: right;
|
89
|
+
}
|
90
|
+
|
91
|
+
.fc-tools--center {
|
92
|
+
position: absolute;
|
93
|
+
z-index: 300;
|
94
|
+
top: 50%;
|
95
|
+
left: 50%;
|
96
|
+
transform: translateX(-50%) translateY(-50%);
|
97
|
+
}
|
98
|
+
|
99
|
+
.fc-tools--disabled {
|
100
|
+
z-index: 100;
|
101
|
+
}
|
102
|
+
|
103
|
+
.fc-tools__btn {
|
104
|
+
display: inline-block;
|
105
|
+
|
106
|
+
font-size: 12px;
|
107
|
+
text-align: center;
|
108
|
+
text-transform: uppercase;
|
109
|
+
|
110
|
+
padding: 10px;
|
111
|
+
|
112
|
+
&:hover,
|
113
|
+
&:focus {
|
114
|
+
background: rgba(0,0,0,.05);
|
115
|
+
text-decoration: none;
|
116
|
+
}
|
117
|
+
}
|
118
|
+
|
119
|
+
.fc-tools__btn--delete {
|
120
|
+
float: left;
|
121
|
+
}
|
122
|
+
|
123
|
+
.fc-tools__input {
|
124
|
+
|
125
|
+
}
|
126
|
+
|
127
|
+
.fc-tools__input--upload {
|
128
|
+
display: none !important;
|
129
|
+
}
|
130
|
+
|
131
|
+
.fc-container {
|
132
|
+
box-sizing: border-box;
|
133
|
+
padding: 0 0 300px 0;
|
134
|
+
|
135
|
+
font-family: 'Open Sans', sans-serif;
|
136
|
+
}
|
137
|
+
|
138
|
+
.fc-content {
|
139
|
+
position: relative;
|
140
|
+
max-width: 100%;
|
141
|
+
height: auto !important;
|
142
|
+
|
143
|
+
&:after {
|
144
|
+
visibility: hidden;
|
145
|
+
display: block;
|
146
|
+
font-size: 0;
|
147
|
+
content: " ";
|
148
|
+
clear: both;
|
149
|
+
height: 0;
|
150
|
+
}
|
151
|
+
}
|
152
|
+
|
153
|
+
.fc-row {
|
154
|
+
position: relative;
|
155
|
+
}
|
156
|
+
|
157
|
+
.fc-loading {
|
158
|
+
position: absolute;
|
159
|
+
z-index: 400;
|
160
|
+
top: 0;
|
161
|
+
left: 0;
|
162
|
+
|
163
|
+
width: 100%;
|
164
|
+
height: 100%;
|
165
|
+
background: image_url('fc-loading.svg') no-repeat center rgba(#fff, .95);
|
166
|
+
}
|
167
|
+
|
168
|
+
.fc-search {
|
169
|
+
margin-bottom: 10px;
|
170
|
+
|
171
|
+
width: 100%;
|
172
|
+
padding: 8px;
|
173
|
+
border-radius: 4px;
|
174
|
+
border: solid 1px #ccc;
|
175
|
+
|
176
|
+
outline: none;
|
177
|
+
|
178
|
+
&:focus {
|
179
|
+
border-color: #999;
|
180
|
+
}
|
181
|
+
}
|
182
|
+
|
183
|
+
|
184
|
+
[contenteditable="true"] {
|
185
|
+
outline: none;
|
186
|
+
min-height: 15px;
|
187
|
+
|
188
|
+
&:focus {
|
189
|
+
box-shadow: 0 0 0 1px rgba(0,0,0,.2);
|
190
|
+
}
|
191
|
+
|
192
|
+
&:empty {
|
193
|
+
background: rgba(#000, .1);
|
194
|
+
}
|
195
|
+
}
|
196
|
+
|
197
|
+
.ui-sortable-placeholder {
|
198
|
+
margin: 20px 0;
|
199
|
+
height: 80px;
|
200
|
+
|
201
|
+
background: rgba(0,0,0,.05);
|
202
|
+
border: dashed 2px rgba(0,0,0,.05);
|
203
|
+
}
|
204
|
+
|
205
|
+
|
206
|
+
.fc-content {
|
207
|
+
line-height: 1.6;
|
208
|
+
|
209
|
+
color: rgba(0,0,0,.7);
|
210
|
+
font-family: arial, sans-serif;
|
211
|
+
font-size: 16px;
|
212
|
+
|
213
|
+
margin-bottom: 30px;
|
214
|
+
}
|
215
|
+
|
216
|
+
|
217
|
+
.fc-row {
|
218
|
+
position: relative;
|
219
|
+
|
220
|
+
&:after {
|
221
|
+
visibility: hidden;
|
222
|
+
display: block;
|
223
|
+
font-size: 0;
|
224
|
+
content: " ";
|
225
|
+
clear: both;
|
226
|
+
height: 0;
|
227
|
+
}
|
228
|
+
}
|
229
|
+
|
230
|
+
.fc-date {
|
231
|
+
color: lighten(#111, 50%);
|
232
|
+
font-size: 12px;
|
233
|
+
|
234
|
+
margin-bottom: 16px;
|
235
|
+
padding-bottom: 16px;
|
236
|
+
|
237
|
+
border-bottom: solid 1px rgba(#111, .06);
|
238
|
+
}
|
239
|
+
|
240
|
+
.fc-item {
|
241
|
+
position: relative;
|
242
|
+
|
243
|
+
&:after {
|
244
|
+
visibility: hidden;
|
245
|
+
display: block;
|
246
|
+
font-size: 0;
|
247
|
+
content: " ";
|
248
|
+
clear: both;
|
249
|
+
height: 0;
|
250
|
+
}
|
251
|
+
}
|
252
|
+
|
253
|
+
.fc-item--border {
|
254
|
+
margin-bottom: 24px;
|
255
|
+
padding-bottom: 24px;
|
256
|
+
|
257
|
+
border-bottom: solid 1px rgba(#111, .06);
|
258
|
+
}
|
259
|
+
|
260
|
+
.fc-link {
|
261
|
+
display: none;
|
262
|
+
}
|
263
|
+
|
264
|
+
.fc-figure {
|
265
|
+
position: relative;
|
266
|
+
|
267
|
+
float: left;
|
268
|
+
margin: 0 1rem 0 0;
|
269
|
+
|
270
|
+
width: 150px;
|
271
|
+
height: 100px;
|
272
|
+
border-radius: 4px;
|
273
|
+
|
274
|
+
overflow: hidden;
|
275
|
+
}
|
276
|
+
|
277
|
+
.fc-figure--small {
|
278
|
+
width: 90px;
|
279
|
+
height: 60px;
|
280
|
+
}
|
281
|
+
|
282
|
+
.fc-figure--large {
|
283
|
+
width: 150px;
|
284
|
+
height: 100px;
|
285
|
+
}
|
286
|
+
|
287
|
+
.fc-image {
|
288
|
+
margin-bottom: -7px;
|
289
|
+
|
290
|
+
height: 100%;
|
291
|
+
border-radius: 4px;
|
292
|
+
}
|
293
|
+
|
294
|
+
.fc-content {
|
295
|
+
height: 144px;
|
296
|
+
overflow: hidden;
|
297
|
+
}
|
298
|
+
|
299
|
+
.fc-time {
|
300
|
+
line-height: 1.6;
|
301
|
+
|
302
|
+
float: right;
|
303
|
+
color: darken(#fff, 40%);
|
304
|
+
font-size: 14px;
|
305
|
+
}
|
306
|
+
|
307
|
+
.fc-caption {
|
308
|
+
margin: 0 0 8px;
|
309
|
+
|
310
|
+
color: lighten(#111, 40%);
|
311
|
+
font-size: 10px;
|
312
|
+
font-weight: 600;
|
313
|
+
text-transform: uppercase;
|
314
|
+
}
|
315
|
+
|
316
|
+
.fc-title {
|
317
|
+
margin: 0;
|
318
|
+
|
319
|
+
display: block;
|
320
|
+
width: 100%;
|
321
|
+
line-height: 1.4;
|
322
|
+
|
323
|
+
color: lighten(#111, 23%) !important;
|
324
|
+
font-size: 15px;
|
325
|
+
font-weight: 600;
|
326
|
+
letter-spacing: -.04em;
|
327
|
+
|
328
|
+
+ .fc-figure {
|
329
|
+
margin-top: 8px;
|
330
|
+
}
|
331
|
+
}
|
332
|
+
|
333
|
+
.fc-title--highlight {
|
334
|
+
margin: 0;
|
335
|
+
|
336
|
+
padding: 8px;
|
337
|
+
background: #333;
|
338
|
+
border-radius: 4px;
|
339
|
+
|
340
|
+
color: #fff !important;
|
341
|
+
font-size: 17px !important;
|
342
|
+
}
|
343
|
+
|
344
|
+
.fc-text {
|
345
|
+
margin: 8px 0 0;
|
346
|
+
|
347
|
+
line-height: 1.4;
|
348
|
+
overflow: hidden;
|
349
|
+
|
350
|
+
color: lighten(#111, 50%);
|
351
|
+
font-family: Arial, sans-serif;
|
352
|
+
font-size: 14px;
|
353
|
+
}
|
354
|
+
|
355
|
+
@media screen and (min-width: 460px) {
|
356
|
+
.fc-snippet__caption {
|
357
|
+
display: block;
|
358
|
+
}
|
359
|
+
|
360
|
+
.fc-caption {
|
361
|
+
font-size: 13px;
|
362
|
+
}
|
363
|
+
|
364
|
+
.fc-title {
|
365
|
+
line-height: 1.4;
|
366
|
+
font-size: 19px;
|
367
|
+
}
|
368
|
+
|
369
|
+
.fc-title--small {
|
370
|
+
font-size: 16px;
|
371
|
+
}
|
372
|
+
|
373
|
+
.fc-title--large {
|
374
|
+
line-height: 1.3;
|
375
|
+
font-size: 22px;
|
376
|
+
}
|
377
|
+
}
|
378
|
+
|
379
|
+
@media screen and (min-width: 768px) {
|
380
|
+
.fc-snippet {
|
381
|
+
top: 50px;
|
382
|
+
right: 0;
|
383
|
+
bottom: 112px;
|
384
|
+
left: auto;
|
385
|
+
|
386
|
+
width: 150px;
|
387
|
+
height: auto;
|
388
|
+
padding: 20px;
|
389
|
+
border: 0;
|
390
|
+
border-left: solid 1px rgba(0,0,0,.1);
|
391
|
+
|
392
|
+
-webkit-transform: translateX(0%);
|
393
|
+
-moz-transform: translateX(0%);
|
394
|
+
transform: translateX(0%);
|
395
|
+
}
|
396
|
+
|
397
|
+
.fc-snippet__btn {
|
398
|
+
margin-bottom: 20px;
|
399
|
+
|
400
|
+
display: block;
|
401
|
+
width: 100%;
|
402
|
+
padding: 0;
|
403
|
+
}
|
404
|
+
|
405
|
+
.fc-tools {
|
406
|
+
position: absolute;
|
407
|
+
z-index: 300;
|
408
|
+
top: 0;
|
409
|
+
left: -40px;
|
410
|
+
}
|
411
|
+
|
412
|
+
.fc-tools__btn {
|
413
|
+
display: block;
|
414
|
+
}
|
415
|
+
|
416
|
+
.fc-tools--center {
|
417
|
+
position: absolute;
|
418
|
+
z-index: 300;
|
419
|
+
top: 50%;
|
420
|
+
left: 50%;
|
421
|
+
|
422
|
+
.fc-tools__btn {
|
423
|
+
display: inline-block;
|
424
|
+
}
|
425
|
+
}
|
426
|
+
|
427
|
+
.fc-controls {
|
428
|
+
position: fixed;
|
429
|
+
z-index: 100;
|
430
|
+
bottom: 0;
|
431
|
+
right: 0;
|
432
|
+
|
433
|
+
width: 150px;
|
434
|
+
|
435
|
+
padding: 20px;
|
436
|
+
|
437
|
+
background: #f8f8f8;
|
438
|
+
border-top: solid 1px rgba(0,0,0,.1);
|
439
|
+
border-left: solid 1px rgba(0,0,0,.1);
|
440
|
+
|
441
|
+
.btn-block {
|
442
|
+
width: 100% !important;
|
443
|
+
}
|
444
|
+
|
445
|
+
.btn-block + .btn-block {
|
446
|
+
margin-top: 5px;
|
447
|
+
}
|
448
|
+
|
449
|
+
.btn-left,
|
450
|
+
.btn-right {
|
451
|
+
float: none;
|
452
|
+
}
|
453
|
+
}
|
454
|
+
|
455
|
+
.fc-container {
|
456
|
+
box-sizing: border-box;
|
457
|
+
padding: 30px 160px 100px 40px;
|
458
|
+
width: 75%;
|
459
|
+
margin: 0 auto;
|
460
|
+
}
|
461
|
+
|
462
|
+
.fc-row--flex {
|
463
|
+
display: flex;
|
464
|
+
}
|
465
|
+
|
466
|
+
.fc-item--two {
|
467
|
+
float: left;
|
468
|
+
display: block;
|
469
|
+
margin-right: 3.57866%;
|
470
|
+
width: 48.21067%;
|
471
|
+
|
472
|
+
&:nth-child(2n+1) {
|
473
|
+
clear: left;
|
474
|
+
}
|
475
|
+
|
476
|
+
&:nth-child(2n) {
|
477
|
+
margin-right: 0;
|
478
|
+
}
|
479
|
+
}
|
480
|
+
|
481
|
+
.fc-item--three {
|
482
|
+
float: left;
|
483
|
+
display: block;
|
484
|
+
margin-right: 3.16844%;
|
485
|
+
width: 31.22104%;
|
486
|
+
|
487
|
+
&:nth-child(3n+1) {
|
488
|
+
clear: left;
|
489
|
+
}
|
490
|
+
|
491
|
+
&:nth-child(3n) {
|
492
|
+
margin-right: 0;
|
493
|
+
}
|
494
|
+
}
|
495
|
+
|
496
|
+
.fc-item--four {
|
497
|
+
float: left;
|
498
|
+
display: block;
|
499
|
+
margin-right: 3.57866%;
|
500
|
+
width: 22.316%;
|
501
|
+
|
502
|
+
&:nth-child(4n+1) {
|
503
|
+
clear: left;
|
504
|
+
}
|
505
|
+
|
506
|
+
&:nth-child(4n) {
|
507
|
+
margin-right: 0;
|
508
|
+
}
|
509
|
+
}
|
510
|
+
|
511
|
+
.fc-date {
|
512
|
+
font-size: 14px;
|
513
|
+
}
|
514
|
+
|
515
|
+
.fc-title--highlight {
|
516
|
+
padding: 8px 14px;
|
517
|
+
}
|
518
|
+
|
519
|
+
.fc-figure--block {
|
520
|
+
position: relative;
|
521
|
+
float: none;
|
522
|
+
margin: 0 1rem .5rem 0;
|
523
|
+
|
524
|
+
width: 100%;
|
525
|
+
height: 0;
|
526
|
+
padding-bottom: 50%;
|
527
|
+
|
528
|
+
.fc-image {
|
529
|
+
position: absolute;
|
530
|
+
top: 50%;
|
531
|
+
left: 0;
|
532
|
+
|
533
|
+
width: 100%;
|
534
|
+
height: auto;
|
535
|
+
|
536
|
+
-webkit-transform: translateY(-50%);
|
537
|
+
-moz-transform: translateY(-50%);
|
538
|
+
transform: translateY(-50%);
|
539
|
+
}
|
540
|
+
}
|
541
|
+
}
|
542
|
+
|
543
|
+
// slide
|
544
|
+
|
545
|
+
.fc-slide {
|
546
|
+
position: relative;
|
547
|
+
|
548
|
+
overflow: hidden;
|
549
|
+
|
550
|
+
-webkit-transform: translate3d(0, 0, 0);
|
551
|
+
-moz-transform: translate3d(0, 0, 0);
|
552
|
+
transform: translate3d(0, 0, 0);
|
553
|
+
|
554
|
+
.owl-controls {
|
555
|
+
margin: 0;
|
556
|
+
|
557
|
+
.owl-buttons {
|
558
|
+
display: none;
|
559
|
+
}
|
560
|
+
|
561
|
+
.owl-pagination {
|
562
|
+
margin-top: .5em;
|
563
|
+
text-align: center;
|
564
|
+
}
|
565
|
+
|
566
|
+
.owl-page {
|
567
|
+
display: inline-block;
|
568
|
+
opacity: .6;
|
569
|
+
|
570
|
+
span {
|
571
|
+
display: block;
|
572
|
+
|
573
|
+
width: 10px;
|
574
|
+
height: 10px;
|
575
|
+
margin: 0 4px;
|
576
|
+
background: #999;
|
577
|
+
border-radius: 100%;
|
578
|
+
}
|
579
|
+
|
580
|
+
&:hover,
|
581
|
+
&:focus {
|
582
|
+
opacity: 1;
|
583
|
+
}
|
584
|
+
}
|
585
|
+
|
586
|
+
.owl-page.active {
|
587
|
+
opacity: 1;
|
588
|
+
}
|
589
|
+
}
|
590
|
+
}
|
591
|
+
|
592
|
+
.fc-slide__item {
|
593
|
+
position: relative;
|
594
|
+
overflow: hidden;
|
595
|
+
}
|
596
|
+
|
597
|
+
.fc-slide__link {
|
598
|
+
|
599
|
+
}
|
600
|
+
|
601
|
+
.fc-slide__figure {
|
602
|
+
position: relative;
|
603
|
+
z-index: -1;
|
604
|
+
margin: 0 0 .5rem;
|
605
|
+
|
606
|
+
width: 100%;
|
607
|
+
height: 0;
|
608
|
+
padding-bottom: 60%;
|
609
|
+
border-radius: 4px;
|
610
|
+
overflow: hidden;
|
611
|
+
}
|
612
|
+
|
613
|
+
.fc-slide__image {
|
614
|
+
position: absolute;
|
615
|
+
|
616
|
+
display: block;
|
617
|
+
width: 100%;
|
618
|
+
min-height: 100%;
|
619
|
+
}
|
620
|
+
|
621
|
+
@media screen and (min-width: 768px) {
|
622
|
+
.fc-slide__text {
|
623
|
+
max-height: none;
|
624
|
+
}
|
625
|
+
}
|
626
|
+
|
627
|
+
@media screen and (min-width: 990px) {
|
628
|
+
.fc-slide {
|
629
|
+
.owl-controls {
|
630
|
+
.owl-buttons {
|
631
|
+
position: absolute;
|
632
|
+
top: 70px;
|
633
|
+
right: 0;
|
634
|
+
|
635
|
+
display: block;
|
636
|
+
|
637
|
+
div {
|
638
|
+
margin: 0;
|
639
|
+
|
640
|
+
display: inline-block;
|
641
|
+
opacity: 1;
|
642
|
+
width: 48px;
|
643
|
+
height: 48px;
|
644
|
+
line-height: 48px;
|
645
|
+
padding: 0;
|
646
|
+
background: none;
|
647
|
+
border-radius: 0;
|
648
|
+
|
649
|
+
color: #fff;
|
650
|
+
font-size: 32px;
|
651
|
+
text-align: center;
|
652
|
+
|
653
|
+
&:hover,
|
654
|
+
&:focus {
|
655
|
+
opacity: .7 !important;
|
656
|
+
}
|
657
|
+
}
|
658
|
+
}
|
659
|
+
}
|
660
|
+
}
|
661
|
+
}
|