active_frontend 14.0.16 → 14.0.17
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.DS_Store +0 -0
- data/lib/active_frontend/version.rb +1 -1
- data/lib/generators/active_frontend/templates/install.js +2 -0
- data/vendor/assets/javascripts/active_frontend.js +2 -0
- data/vendor/assets/javascripts/base/_affirm.js +135 -0
- data/vendor/assets/javascripts/base/_colorpicker.js +3 -3
- data/vendor/assets/javascripts/base/_filepicker.js +2 -1
- data/vendor/assets/javascripts/base/_header.js +88 -0
- data/vendor/assets/javascripts/base/_layout.js +1 -1
- data/vendor/assets/javascripts/base/_timezone.js +0 -1
- data/vendor/assets/javascripts/extensions/_chart.js +3 -3
- data/vendor/assets/stylesheets/_variable.scss +13 -13
- data/vendor/assets/stylesheets/blocks/_common.scss +5 -5
- data/vendor/assets/stylesheets/components/_breadcrumb.scss +0 -1
- data/vendor/assets/stylesheets/components/_header.scss +8 -0
- data/vendor/assets/stylesheets/components/_layout.scss +4 -4
- data/vendor/assets/stylesheets/components/_modal.scss +10 -2
- data/vendor/assets/stylesheets/components/_nav_and_tab.scss +1 -1
- data/vendor/assets/stylesheets/components/_spinner.scss +3 -1
- metadata +4 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 172b12bf5f617882455d02532dc3026ef2e38d4a
|
4
|
+
data.tar.gz: 6d351cb2a3f005c22a585568a927b8cbe9ea9306
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 10b8945f842e161d1e4aeb03e206c17546111d5692894ea33e9aacfb7b28806bc5bae30ad69c2b50ca86429b4206ce5a490073cc5a4387ec62722c1812b28e8b
|
7
|
+
data.tar.gz: 6254c70bb0b8e61c45eb7237b8add53b004595d3c37b520f69ce67f86570cb45f686aa587902d6127a9577bab6a656a28a898f82465dd7af12ff6cb0639308dd
|
data/.DS_Store
CHANGED
Binary file
|
@@ -9,6 +9,7 @@
|
|
9
9
|
//= require base/_transition
|
10
10
|
//= require base/_layout
|
11
11
|
//= require base/_affix
|
12
|
+
//= require base/_header
|
12
13
|
//= require base/_modal
|
13
14
|
//= require base/_alert
|
14
15
|
//= require base/_tab
|
@@ -31,6 +32,7 @@
|
|
31
32
|
//= require base/_switch
|
32
33
|
//= require base/_timezone
|
33
34
|
//= require base/_tour
|
35
|
+
//= require base/_affirm
|
34
36
|
//
|
35
37
|
// Extensions Imports
|
36
38
|
// ==================================================
|
@@ -9,6 +9,7 @@
|
|
9
9
|
//= require base/_transition
|
10
10
|
//= require base/_layout
|
11
11
|
//= require base/_affix
|
12
|
+
//= require base/_header
|
12
13
|
//= require base/_modal
|
13
14
|
//= require base/_alert
|
14
15
|
//= require base/_tab
|
@@ -31,6 +32,7 @@
|
|
31
32
|
//= require base/_switch
|
32
33
|
//= require base/_timezone
|
33
34
|
//= require base/_tour
|
35
|
+
//= require base/_affirm
|
34
36
|
//
|
35
37
|
// Extensions Imports
|
36
38
|
// ==================================================
|
@@ -0,0 +1,135 @@
|
|
1
|
+
+function ($) {
|
2
|
+
'use strict';
|
3
|
+
|
4
|
+
// AFFIRM CLASS DEFINITION
|
5
|
+
// =======================
|
6
|
+
|
7
|
+
var Affirm = function (element, options) {
|
8
|
+
this.$element = $(element);
|
9
|
+
this.settings = {
|
10
|
+
title: this.$element.data('title'),
|
11
|
+
offset: this.$element.data('offset'),
|
12
|
+
removeClass: this.$element.data('remove-class')
|
13
|
+
};
|
14
|
+
this.options = $.extend({}, Affirm.DEFAULTS, options);
|
15
|
+
|
16
|
+
this.init();
|
17
|
+
};
|
18
|
+
|
19
|
+
if (!$.fn.modal) throw new Error('Affirm requires modal.js');
|
20
|
+
|
21
|
+
Affirm.VERSION = '1.0.0';
|
22
|
+
Affirm.DEFAULTS = {
|
23
|
+
btnClass: {
|
24
|
+
cancel: 'btn margin-size-right-xs',
|
25
|
+
confirm: 'btn btn-color-red'
|
26
|
+
},
|
27
|
+
modalClass: 'modal fade',
|
28
|
+
modalId: 'bsAffirmModal',
|
29
|
+
format: 'modal',
|
30
|
+
text: {
|
31
|
+
cancel: 'No, Cancel',
|
32
|
+
confirm: 'Yes, Confirm'
|
33
|
+
},
|
34
|
+
title: 'Are you 100% sure about this?'
|
35
|
+
};
|
36
|
+
|
37
|
+
Affirm.prototype.constructor = Affirm;
|
38
|
+
|
39
|
+
Affirm.prototype.init = function () {
|
40
|
+
var _self = this;
|
41
|
+
var body = $('body');
|
42
|
+
var modalId = '#' + this.options.modalId;
|
43
|
+
|
44
|
+
this.$element.click(function () {
|
45
|
+
$(modalId).remove();
|
46
|
+
body.append(_self.modalTemplate());
|
47
|
+
$(modalId).modal('show');
|
48
|
+
|
49
|
+
return false;
|
50
|
+
});
|
51
|
+
|
52
|
+
body.on('click', '[data-affirm-toggle="confirm"]', function () {
|
53
|
+
$(modalId).modal('hide');
|
54
|
+
});
|
55
|
+
};
|
56
|
+
|
57
|
+
Affirm.prototype.cancelBtn = function () {
|
58
|
+
var button = $('<a data-affirm-toggle="cancel" data-dismiss="modal">')
|
59
|
+
.addClass(this.options.btnClass.cancel)
|
60
|
+
.text(this.options.text.cancel);
|
61
|
+
|
62
|
+
return button;
|
63
|
+
};
|
64
|
+
|
65
|
+
Affirm.prototype.confirmBtn = function () {
|
66
|
+
var method = this.$element.attr('data-method');
|
67
|
+
var target = this.$element.attr('target');
|
68
|
+
var button = $('<a data-affirm-toggle="confirm">')
|
69
|
+
.addClass(this.options.btnClass.confirm)
|
70
|
+
.attr('href', this.$element.attr('href'))
|
71
|
+
.text(this.options.text.confirm);
|
72
|
+
|
73
|
+
if (method) button.attr('data-method', method);
|
74
|
+
if (target) button.attr('target', target);
|
75
|
+
|
76
|
+
return button;
|
77
|
+
};
|
78
|
+
|
79
|
+
Affirm.prototype.modalTemplate = function () {
|
80
|
+
var title = '<h5 class="row">' + this.options.title + '</h5>';
|
81
|
+
var header = $('<div class="modal-header text-align-left">')
|
82
|
+
.append(title);
|
83
|
+
var body = $('<div class="modal-body">')
|
84
|
+
.append(this.$element.attr('data-affirm'));
|
85
|
+
var footer = $('<div class="modal-footer text-align-right">')
|
86
|
+
.append(this.cancelBtn())
|
87
|
+
.append(this.confirmBtn());
|
88
|
+
var modal = $('<div role="modal">')
|
89
|
+
.addClass(this.options.modalClass)
|
90
|
+
.attr('id', this.options.modalId)
|
91
|
+
.append(header)
|
92
|
+
.append(body)
|
93
|
+
.append(footer);
|
94
|
+
|
95
|
+
return modal;
|
96
|
+
};
|
97
|
+
|
98
|
+
// AFFIRM PLUGIN DEFINITION
|
99
|
+
// ========================
|
100
|
+
|
101
|
+
function Plugin(option) {
|
102
|
+
return this.each(function () {
|
103
|
+
var $this = $(this);
|
104
|
+
var data = $this.data('bs.affirm');
|
105
|
+
var options = typeof option === 'object' && option;
|
106
|
+
|
107
|
+
if (!data) $this.data('bs.affirm', (data = new Affirm(this, options)));
|
108
|
+
if (typeof option === 'string') data[option]();
|
109
|
+
});
|
110
|
+
}
|
111
|
+
|
112
|
+
var old = $.fn.affirm;
|
113
|
+
|
114
|
+
$.fn.affirm = Plugin;
|
115
|
+
$.fn.affirm.Constructor = Affirm;
|
116
|
+
|
117
|
+
// AFFIRM NO CONFLICT
|
118
|
+
// ==================
|
119
|
+
|
120
|
+
$.fn.affirm.noConflict = function () {
|
121
|
+
$.fn.affirm = old;
|
122
|
+
return this;
|
123
|
+
};
|
124
|
+
|
125
|
+
// AFFIRM DATA-API
|
126
|
+
// ================
|
127
|
+
|
128
|
+
$(document).on('ready.bs.affirm.data-api', function () {
|
129
|
+
$('[data-affirm]').each(function () {
|
130
|
+
var $this = $(this);
|
131
|
+
Plugin.call($this, $this.data());
|
132
|
+
});
|
133
|
+
});
|
134
|
+
|
135
|
+
}(jQuery);
|
@@ -18,9 +18,9 @@
|
|
18
18
|
Colorpicker.DEFAULTS = {
|
19
19
|
callback: function (color) {},
|
20
20
|
colors: [
|
21
|
-
'#
|
22
|
-
'#
|
23
|
-
'#
|
21
|
+
'#94E254', '#13CE56', '#33C9EB', '#148DFF', '#7E5BEF',
|
22
|
+
'#9861C2', '#FF5DC4', '#FF3B3B', '#FF6935', '#FFD718',
|
23
|
+
'#273444', '#9BA7BA', '#F0F3F9', '#FFFFFF'
|
24
24
|
],
|
25
25
|
item: '<li><button type="button"></button></li>',
|
26
26
|
menu: '<ul class="colorpicker dropmenu caret"></ul>'
|
@@ -0,0 +1,88 @@
|
|
1
|
+
+function ($) {
|
2
|
+
'use strict';
|
3
|
+
|
4
|
+
// HEADER CLASS DEFINITION
|
5
|
+
// =======================
|
6
|
+
|
7
|
+
var Header = function (element, options) {
|
8
|
+
this.$element = $(element);
|
9
|
+
this.$window = $(window);
|
10
|
+
this.settings = {
|
11
|
+
addClass: this.$element.data('add-class'),
|
12
|
+
offset: this.$element.data('offset'),
|
13
|
+
removeClass: this.$element.data('remove-class')
|
14
|
+
};
|
15
|
+
this.options = $.extend({}, Header.DEFAULTS, this.settings, options);
|
16
|
+
|
17
|
+
this.init();
|
18
|
+
};
|
19
|
+
|
20
|
+
Header.VERSION = '1.0.0';
|
21
|
+
Header.DEFAULTS = {
|
22
|
+
addClass: 'border-color-bottom-transparent box-shadow-bottom',
|
23
|
+
offset: 10,
|
24
|
+
removeClass: 'background-color-transparent'
|
25
|
+
};
|
26
|
+
|
27
|
+
Header.prototype.constructor = Header;
|
28
|
+
|
29
|
+
Header.prototype.init = function () {
|
30
|
+
var _self = this;
|
31
|
+
|
32
|
+
this.$window.scroll(function () {
|
33
|
+
_self.toggleClasses();
|
34
|
+
});
|
35
|
+
};
|
36
|
+
|
37
|
+
Header.prototype.swapClass = function (removeClass, addClass) {
|
38
|
+
this.$element.removeClass(removeClass)
|
39
|
+
.addClass(addClass);
|
40
|
+
};
|
41
|
+
|
42
|
+
Header.prototype.toggleClasses = function () {
|
43
|
+
if (this.$window.scrollTop() >= this.options.offset) {
|
44
|
+
this.swapClass(this.options.removeClass, this.options.addClass);
|
45
|
+
} else {
|
46
|
+
this.swapClass(this.options.addClass, this.options.removeClass);
|
47
|
+
}
|
48
|
+
};
|
49
|
+
|
50
|
+
// HEADER PLUGIN DEFINITION
|
51
|
+
// ========================
|
52
|
+
|
53
|
+
function Plugin(option) {
|
54
|
+
return this.each(function () {
|
55
|
+
var $this = $(this);
|
56
|
+
var data = $this.data('bs.header');
|
57
|
+
var options = typeof option === 'object' && option;
|
58
|
+
|
59
|
+
if (!data) $this.data('bs.header', (data = new Header(this, options)));
|
60
|
+
if (typeof option === 'string') data[option]();
|
61
|
+
});
|
62
|
+
}
|
63
|
+
|
64
|
+
var old = $.fn.header;
|
65
|
+
|
66
|
+
$.fn.header = Plugin;
|
67
|
+
$.fn.header.Constructor = Header;
|
68
|
+
|
69
|
+
// HEADER NO CONFLICT
|
70
|
+
// ==================
|
71
|
+
|
72
|
+
$.fn.header.noConflict = function () {
|
73
|
+
$.fn.header = old;
|
74
|
+
return this;
|
75
|
+
};
|
76
|
+
|
77
|
+
// HEADER DATA-API
|
78
|
+
// ===============
|
79
|
+
|
80
|
+
$(document).on('ready.bs.header.data-api', function () {
|
81
|
+
$('[data-toggle="header"]').each(function () {
|
82
|
+
var $this = $(this);
|
83
|
+
if ($this.data('header')) return;
|
84
|
+
Plugin.call($this, $this.data());
|
85
|
+
});
|
86
|
+
});
|
87
|
+
|
88
|
+
}(jQuery);
|
@@ -5415,8 +5415,8 @@ module.exports = function () {
|
|
5415
5415
|
animationDuration: 400
|
5416
5416
|
},
|
5417
5417
|
onClick: null,
|
5418
|
-
defaultColor: 'rgba(52,
|
5419
|
-
defaultFontColor: 'rgba(52,
|
5418
|
+
defaultColor: 'rgba(39,52,68,0.1)',
|
5419
|
+
defaultFontColor: 'rgba(39,52,68,1)',
|
5420
5420
|
defaultFontFamily: "'Fakt Soft Pro', Verdana, Tahoma, sans-serif",
|
5421
5421
|
defaultFontSize: 16,
|
5422
5422
|
defaultFontStyle: 'normal',
|
@@ -7006,7 +7006,7 @@ module.exports = function (Chart) {
|
|
7006
7006
|
enabled: true,
|
7007
7007
|
custom: null,
|
7008
7008
|
mode: 'single',
|
7009
|
-
backgroundColor: 'rgba(52,
|
7009
|
+
backgroundColor: 'rgba(39,52,68,1)',
|
7010
7010
|
titleFontStyle: '500',
|
7011
7011
|
titleSpacing: 0,
|
7012
7012
|
titleMarginBottom: 3,
|
@@ -34,28 +34,28 @@ $animation-durations: (
|
|
34
34
|
// Color
|
35
35
|
// ==================================================
|
36
36
|
$colors-brand: (
|
37
|
-
'lime': rgba(
|
37
|
+
'lime': rgba(148,226,84,1),
|
38
38
|
'green': rgba(19,206,86,1),
|
39
|
-
'teal': rgba(
|
39
|
+
'teal': rgba(51,201,235,1),
|
40
40
|
'blue': rgba(20,141,255,1),
|
41
|
-
'indigo': rgba(
|
42
|
-
'purple': rgba(
|
43
|
-
'pink': rgba(255,
|
44
|
-
'red': rgba(
|
45
|
-
'orange': rgba(255,
|
46
|
-
'yellow': rgba(
|
41
|
+
'indigo': rgba(126,91,239,1),
|
42
|
+
'purple': rgba(152,97,194,1),
|
43
|
+
'pink': rgba(255,93,196,1),
|
44
|
+
'red': rgba(255,59,59,1),
|
45
|
+
'orange': rgba(255,105,53,1),
|
46
|
+
'yellow': rgba(255,215,24,1)
|
47
47
|
);
|
48
48
|
$colors-grayscale: (
|
49
49
|
'transparent': rgba(0,0,0,0),
|
50
|
-
'dark-black': rgba(
|
51
|
-
'black': rgba(52,
|
52
|
-
'light-black': rgba(
|
50
|
+
'dark-black': rgba(30,40,52,1),
|
51
|
+
'black': rgba(39,52,68,1),
|
52
|
+
'light-black': rgba(48,64,84,1),
|
53
53
|
'dark-gray': rgba(143,157,178,1),
|
54
54
|
'gray': rgba(155,167,186,1),
|
55
55
|
'light-gray': rgba(167,177,194,1),
|
56
56
|
'dark-haze': rgba(227,232,240,1),
|
57
|
-
'haze': rgba(
|
58
|
-
'light-haze': rgba(
|
57
|
+
'haze': rgba(240,243,249,1),
|
58
|
+
'light-haze': rgba(251,252,254,1),
|
59
59
|
'white': rgba(255,255,255,1)
|
60
60
|
);
|
61
61
|
$colors-global: (
|
@@ -98,11 +98,11 @@
|
|
98
98
|
|
99
99
|
// Box shadows
|
100
100
|
// ==================================================
|
101
|
-
.box-shadow-bottom { box-shadow: 0 2px
|
102
|
-
.box-shadow-left { box-shadow: -
|
103
|
-
.box-shadow-right { box-shadow:
|
104
|
-
.box-shadow-top { box-shadow: 0 -2px
|
105
|
-
.box-shadow { box-shadow: 0 0
|
101
|
+
.box-shadow-bottom { box-shadow: 0 1px 2px darker-color(dark-haze); }
|
102
|
+
.box-shadow-left { box-shadow: -1px 0 2px darker-color(dark-haze); }
|
103
|
+
.box-shadow-right { box-shadow: 1px 0 2px darker-color(dark-haze); }
|
104
|
+
.box-shadow-top { box-shadow: 0 -1px 2px darker-color(dark-haze); }
|
105
|
+
.box-shadow { box-shadow: 0 0 2px darker-color(dark-haze); }
|
106
106
|
|
107
107
|
// Border radiuses
|
108
108
|
// ==================================================
|
@@ -20,9 +20,9 @@
|
|
20
20
|
}
|
21
21
|
.layout-body { width: 100%; }
|
22
22
|
.layout-sidebar {
|
23
|
-
width:
|
23
|
+
width: 300px;
|
24
24
|
|
25
|
-
&:not(.hidden) + .layout-body { width: calc(100% -
|
25
|
+
&:not(.hidden) + .layout-body { width: calc(100% - 300px); }
|
26
26
|
|
27
27
|
&.fixed {
|
28
28
|
left: 0;
|
@@ -47,9 +47,9 @@
|
|
47
47
|
}
|
48
48
|
@media only screen and (min-width: 768px) and (max-width: 959px) {
|
49
49
|
.layout-sidebar {
|
50
|
-
width:
|
50
|
+
width: 220px;
|
51
51
|
|
52
|
-
&:not(.hidden) + .layout-body { width: calc(100% -
|
52
|
+
&:not(.hidden) + .layout-body { width: calc(100% - 220px); }
|
53
53
|
&.fixed + .layout-body { width: 100%; }
|
54
54
|
}
|
55
55
|
}
|
@@ -14,7 +14,7 @@
|
|
14
14
|
.modal {
|
15
15
|
background: color(white);
|
16
16
|
border-radius: border-radius(b);
|
17
|
-
box-shadow: 0 0
|
17
|
+
box-shadow: 0 0 3px dark-color(dark-haze);
|
18
18
|
display: none;
|
19
19
|
left: 0;
|
20
20
|
margin: 0 auto;
|
@@ -25,6 +25,12 @@
|
|
25
25
|
width: 560px;
|
26
26
|
z-index: 1060;
|
27
27
|
|
28
|
+
&.clean {
|
29
|
+
background: color(transparent);
|
30
|
+
border-color: color(transparent);
|
31
|
+
box-shadow: none;
|
32
|
+
}
|
33
|
+
|
28
34
|
&.fade {
|
29
35
|
@include transition((opacity 0.2s linear, top 0.4s ease-in-out));
|
30
36
|
top: -100%;
|
@@ -102,7 +108,7 @@
|
|
102
108
|
// Backdrop
|
103
109
|
// ==================================================
|
104
110
|
.modal-backdrop {
|
105
|
-
background: transparentize(color(white), 0.
|
111
|
+
background: transparentize(color(white), 0.05);
|
106
112
|
bottom: 0;
|
107
113
|
height: 100%;
|
108
114
|
left: 0;
|
@@ -116,6 +122,8 @@
|
|
116
122
|
|
117
123
|
&.in { opacity: 1; }
|
118
124
|
}
|
125
|
+
|
126
|
+
&.dark { background: transparentize(color(black), 0.05); }
|
119
127
|
}
|
120
128
|
|
121
129
|
// Media Queries
|
@@ -72,7 +72,7 @@
|
|
72
72
|
// Backdrop
|
73
73
|
// ==================================================
|
74
74
|
.spinner-backdrop {
|
75
|
-
background: transparentize(color(white), 0.
|
75
|
+
background: transparentize(color(white), 0.05);
|
76
76
|
bottom: 0;
|
77
77
|
height: 100%;
|
78
78
|
left: 0;
|
@@ -80,4 +80,6 @@
|
|
80
80
|
right: 0;
|
81
81
|
top: 0;
|
82
82
|
z-index: 2040;
|
83
|
+
|
84
|
+
&.dark { background: transparentize(color(black), 0.05); }
|
83
85
|
}
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: active_frontend
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 14.0.
|
4
|
+
version: 14.0.17
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Juan Gomez
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2016-11-
|
11
|
+
date: 2016-11-19 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: rails
|
@@ -206,6 +206,7 @@ files:
|
|
206
206
|
- vendor/assets/javascripts/.DS_Store
|
207
207
|
- vendor/assets/javascripts/.keep
|
208
208
|
- vendor/assets/javascripts/active_frontend.js
|
209
|
+
- vendor/assets/javascripts/base/_affirm.js
|
209
210
|
- vendor/assets/javascripts/base/_affix.js
|
210
211
|
- vendor/assets/javascripts/base/_alert.js
|
211
212
|
- vendor/assets/javascripts/base/_animation.js
|
@@ -216,6 +217,7 @@ files:
|
|
216
217
|
- vendor/assets/javascripts/base/_datepicker.js
|
217
218
|
- vendor/assets/javascripts/base/_dropdown.js
|
218
219
|
- vendor/assets/javascripts/base/_filepicker.js
|
220
|
+
- vendor/assets/javascripts/base/_header.js
|
219
221
|
- vendor/assets/javascripts/base/_hoverdown.js
|
220
222
|
- vendor/assets/javascripts/base/_layout.js
|
221
223
|
- vendor/assets/javascripts/base/_list.js
|