active_analytics 0.2.1 → 0.4.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/README.md +97 -15
- data/app/controllers/active_analytics/application_controller.rb +29 -6
- data/app/controllers/active_analytics/assets_controller.rb +36 -0
- data/app/controllers/active_analytics/browsers_controller.rb +27 -0
- data/app/controllers/active_analytics/pages_controller.rb +9 -10
- data/app/controllers/active_analytics/referrers_controller.rb +9 -5
- data/app/controllers/active_analytics/sites_controller.rb +5 -4
- data/app/helpers/active_analytics/browsers_helper.rb +12 -0
- data/app/lib/active_analytics/histogram.rb +47 -0
- data/app/models/active_analytics/browsers_per_day.rb +40 -0
- data/app/models/active_analytics/views_per_day.rb +16 -53
- data/app/views/active_analytics/assets/_charts.css +249 -0
- data/app/{assets/stylesheets/active_analytics/style.css → views/active_analytics/assets/_style.css} +36 -26
- data/app/views/active_analytics/assets/application.css.erb +2 -0
- data/app/{assets/javascripts/active_analytics → views/active_analytics/assets}/application.js +1 -3
- data/app/{assets/stylesheets/active_analytics → views/active_analytics/assets}/ariato.css +237 -234
- data/app/views/active_analytics/assets/browsers/arc.svg +1 -0
- data/app/views/active_analytics/assets/browsers/brave.svg +1 -0
- data/app/views/active_analytics/assets/browsers/chrome.svg +1 -0
- data/app/views/active_analytics/assets/browsers/default.svg +8 -0
- data/app/views/active_analytics/assets/browsers/firefox.svg +1 -0
- data/app/views/active_analytics/assets/browsers/internet_explorer.svg +1 -0
- data/app/views/active_analytics/assets/browsers/microsoft_edge.svg +1 -0
- data/app/views/active_analytics/assets/browsers/opera.svg +1 -0
- data/app/views/active_analytics/assets/browsers/safari.svg +1 -0
- data/app/views/active_analytics/assets/browsers/samsung_internet.svg +1 -0
- data/app/views/active_analytics/assets/browsers/vivaldi.svg +1 -0
- data/app/views/active_analytics/assets/browsers/yandex.svg +1 -0
- data/app/views/active_analytics/browsers/_table.html.erb +17 -0
- data/app/views/active_analytics/browsers/_version_table.html.erb +16 -0
- data/app/views/active_analytics/browsers/index.html.erb +9 -0
- data/app/views/active_analytics/browsers/show.html.erb +17 -0
- data/app/views/active_analytics/pages/_table.html.erb +6 -17
- data/app/views/active_analytics/pages/index.html.erb +2 -2
- data/app/views/active_analytics/pages/show.html.erb +7 -4
- data/app/views/active_analytics/referrers/_table.html.erb +9 -2
- data/app/views/active_analytics/referrers/index.html.erb +3 -3
- data/app/views/active_analytics/referrers/show.html.erb +6 -3
- data/app/views/active_analytics/sites/_histogram.html.erb +11 -4
- data/app/views/active_analytics/sites/_histogram_header.html.erb +10 -0
- data/app/views/active_analytics/sites/show.html.erb +9 -4
- data/app/views/layouts/active_analytics/_footer.html.erb +7 -7
- data/app/views/layouts/active_analytics/_header.html.erb +1 -3
- data/app/views/layouts/active_analytics/application.html.erb +5 -3
- data/config/routes.rb +7 -1
- data/db/migrate/20210303094108_create_active_analytics_views_per_days.rb +2 -3
- data/db/migrate/20240823150626_create_active_analytics_browsers_per_days.rb +13 -0
- data/lib/active_analytics/engine.rb +0 -4
- data/lib/active_analytics/version.rb +1 -1
- data/lib/active_analytics.rb +77 -3
- metadata +49 -12
- data/app/assets/stylesheets/active_analytics/application.css +0 -15
- data/app/assets/stylesheets/active_analytics/charts.css +0 -296
- /data/app/{assets/javascripts/active_analytics → views/active_analytics/assets}/ariato.js +0 -0
data/lib/active_analytics.rb
CHANGED
@@ -1,7 +1,26 @@
|
|
1
1
|
require "active_analytics/version"
|
2
2
|
require "active_analytics/engine"
|
3
|
+
require "browser"
|
3
4
|
|
4
5
|
module ActiveAnalytics
|
6
|
+
mattr_accessor :base_controller_class, default: "ActionController::Base"
|
7
|
+
|
8
|
+
def self.redis_url=(string)
|
9
|
+
@redis_url = string
|
10
|
+
end
|
11
|
+
|
12
|
+
def self.redis_url
|
13
|
+
@redis_url ||= ENV["ACTIVE_ANALYTICS_REDIS_URL"] || ENV["REDIS_URL"] || "redis://localhost"
|
14
|
+
end
|
15
|
+
|
16
|
+
def self.redis=(connection)
|
17
|
+
@redis = connection
|
18
|
+
end
|
19
|
+
|
20
|
+
def self.redis
|
21
|
+
@redis ||= Redis.new(url: redis_url)
|
22
|
+
end
|
23
|
+
|
5
24
|
def self.record_request(request)
|
6
25
|
params = {
|
7
26
|
site: request.host,
|
@@ -9,11 +28,12 @@ module ActiveAnalytics
|
|
9
28
|
date: Date.today,
|
10
29
|
}
|
11
30
|
if request.referrer.present?
|
12
|
-
|
13
|
-
params[:referrer_host] = referrer_uri.host
|
14
|
-
params[:referrer_path] = referrer_uri.path
|
31
|
+
params[:referrer_host], params[:referrer_path] = ViewsPerDay.split_referrer(request.referrer)
|
15
32
|
end
|
16
33
|
ViewsPerDay.append(params)
|
34
|
+
|
35
|
+
browser = Browser.new(request.headers["User-Agent"])
|
36
|
+
BrowsersPerDay.append(site: request.host, date: Date.today, name: browser.name, version: browser.version)
|
17
37
|
rescue => ex
|
18
38
|
if Rails.env.development? || Rails.env.test?
|
19
39
|
raise ex
|
@@ -22,4 +42,58 @@ module ActiveAnalytics
|
|
22
42
|
Rails.logger.error(ex.backtrace.join("\n"))
|
23
43
|
end
|
24
44
|
end
|
45
|
+
|
46
|
+
SEPARATOR = "|"
|
47
|
+
|
48
|
+
PAGE_QUEUE = "ActiveAnalytics::PageQueue"
|
49
|
+
BROWSER_QUEUE = "ActiveAnalytics::BrowserQueue"
|
50
|
+
|
51
|
+
OLD_PAGE_QUEUE = "ActiveAnalytics::OldPageQueue"
|
52
|
+
OLD_BROWSER_QUEUE = "ActiveAnalytics::BrowserQueue"
|
53
|
+
|
54
|
+
def self.queue_request(request)
|
55
|
+
queue_request_page(request)
|
56
|
+
queue_request_browser(request)
|
57
|
+
end
|
58
|
+
|
59
|
+
def self.queue_request_page(request)
|
60
|
+
keys = [request.host, request.path]
|
61
|
+
if request.referrer.present?
|
62
|
+
keys.concat(ViewsPerDay.split_referrer(request.referrer))
|
63
|
+
end
|
64
|
+
redis.hincrby(PAGE_QUEUE, keys.join(SEPARATOR).downcase, 1)
|
65
|
+
end
|
66
|
+
|
67
|
+
def self.queue_request_browser(request)
|
68
|
+
browser = Browser.new(request.headers["User-Agent"])
|
69
|
+
keys = [request.host.downcase, browser.name, browser.version]
|
70
|
+
redis.hincrby(BROWSER_QUEUE, keys.join(SEPARATOR), 1)
|
71
|
+
end
|
72
|
+
|
73
|
+
def self.flush_queue
|
74
|
+
flush_page_queue
|
75
|
+
flush_browser_queue
|
76
|
+
end
|
77
|
+
|
78
|
+
def self.flush_page_queue
|
79
|
+
return if !redis.exists?(PAGE_QUEUE)
|
80
|
+
date = Date.today
|
81
|
+
redis.rename(PAGE_QUEUE, OLD_PAGE_QUEUE)
|
82
|
+
redis.hscan_each(OLD_PAGE_QUEUE) do |key, count|
|
83
|
+
site, page, referrer_host, referrer_path = key.split(SEPARATOR)
|
84
|
+
ViewsPerDay.append(date: date, site: site, page: page, referrer_host: referrer_host, referrer_path: referrer_path, total: count.to_i)
|
85
|
+
end
|
86
|
+
redis.del(OLD_PAGE_QUEUE)
|
87
|
+
end
|
88
|
+
|
89
|
+
def self.flush_browser_queue
|
90
|
+
return if !redis.exists?(BROWSER_QUEUE)
|
91
|
+
date = Date.today
|
92
|
+
redis.rename(BROWSER_QUEUE, OLD_BROWSER_QUEUE)
|
93
|
+
redis.hscan_each(OLD_BROWSER_QUEUE) do |key, count|
|
94
|
+
site, name, version = key.split(SEPARATOR)
|
95
|
+
BrowsersPerDay.append(date: date, site: site, name: name, version: version, total: count.to_i)
|
96
|
+
end
|
97
|
+
redis.del(OLD_BROWSER_QUEUE)
|
98
|
+
end
|
25
99
|
end
|
metadata
CHANGED
@@ -1,15 +1,15 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: active_analytics
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.4.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Alexis Bernard
|
8
8
|
- Antoine Marguerie
|
9
|
-
autorequire:
|
9
|
+
autorequire:
|
10
10
|
bindir: bin
|
11
11
|
cert_chain: []
|
12
|
-
date:
|
12
|
+
date: 2025-03-06 00:00:00.000000000 Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: rails
|
@@ -25,6 +25,20 @@ dependencies:
|
|
25
25
|
- - ">="
|
26
26
|
- !ruby/object:Gem::Version
|
27
27
|
version: 5.2.0
|
28
|
+
- !ruby/object:Gem::Dependency
|
29
|
+
name: browser
|
30
|
+
requirement: !ruby/object:Gem::Requirement
|
31
|
+
requirements:
|
32
|
+
- - ">="
|
33
|
+
- !ruby/object:Gem::Version
|
34
|
+
version: 1.0.0
|
35
|
+
type: :runtime
|
36
|
+
prerelease: false
|
37
|
+
version_requirements: !ruby/object:Gem::Requirement
|
38
|
+
requirements:
|
39
|
+
- - ">="
|
40
|
+
- !ruby/object:Gem::Version
|
41
|
+
version: 1.0.0
|
28
42
|
description: NO cookies, NO JavaScript, NO third parties and NO bullshit.
|
29
43
|
email:
|
30
44
|
- alexis@basesecrete.com
|
@@ -39,24 +53,45 @@ files:
|
|
39
53
|
- app/assets/config/active_analytics_manifest.js
|
40
54
|
- app/assets/images/active_analytics.png
|
41
55
|
- app/assets/images/active_analytics_screenshot.png
|
42
|
-
- app/assets/javascripts/active_analytics/application.js
|
43
|
-
- app/assets/javascripts/active_analytics/ariato.js
|
44
|
-
- app/assets/stylesheets/active_analytics/application.css
|
45
|
-
- app/assets/stylesheets/active_analytics/ariato.css
|
46
|
-
- app/assets/stylesheets/active_analytics/charts.css
|
47
|
-
- app/assets/stylesheets/active_analytics/style.css
|
48
56
|
- app/controllers/active_analytics/application_controller.rb
|
57
|
+
- app/controllers/active_analytics/assets_controller.rb
|
58
|
+
- app/controllers/active_analytics/browsers_controller.rb
|
49
59
|
- app/controllers/active_analytics/pages_controller.rb
|
50
60
|
- app/controllers/active_analytics/referrers_controller.rb
|
51
61
|
- app/controllers/active_analytics/sites_controller.rb
|
52
62
|
- app/helpers/active_analytics/application_helper.rb
|
63
|
+
- app/helpers/active_analytics/browsers_helper.rb
|
53
64
|
- app/helpers/active_analytics/pages_helper.rb
|
54
65
|
- app/helpers/active_analytics/referrers_helper.rb
|
55
66
|
- app/helpers/active_analytics/sites_helper.rb
|
56
67
|
- app/jobs/active_analytics/application_job.rb
|
68
|
+
- app/lib/active_analytics/histogram.rb
|
57
69
|
- app/mailers/active_analytics/application_mailer.rb
|
58
70
|
- app/models/active_analytics/application_record.rb
|
71
|
+
- app/models/active_analytics/browsers_per_day.rb
|
59
72
|
- app/models/active_analytics/views_per_day.rb
|
73
|
+
- app/views/active_analytics/assets/_charts.css
|
74
|
+
- app/views/active_analytics/assets/_style.css
|
75
|
+
- app/views/active_analytics/assets/application.css.erb
|
76
|
+
- app/views/active_analytics/assets/application.js
|
77
|
+
- app/views/active_analytics/assets/ariato.css
|
78
|
+
- app/views/active_analytics/assets/ariato.js
|
79
|
+
- app/views/active_analytics/assets/browsers/arc.svg
|
80
|
+
- app/views/active_analytics/assets/browsers/brave.svg
|
81
|
+
- app/views/active_analytics/assets/browsers/chrome.svg
|
82
|
+
- app/views/active_analytics/assets/browsers/default.svg
|
83
|
+
- app/views/active_analytics/assets/browsers/firefox.svg
|
84
|
+
- app/views/active_analytics/assets/browsers/internet_explorer.svg
|
85
|
+
- app/views/active_analytics/assets/browsers/microsoft_edge.svg
|
86
|
+
- app/views/active_analytics/assets/browsers/opera.svg
|
87
|
+
- app/views/active_analytics/assets/browsers/safari.svg
|
88
|
+
- app/views/active_analytics/assets/browsers/samsung_internet.svg
|
89
|
+
- app/views/active_analytics/assets/browsers/vivaldi.svg
|
90
|
+
- app/views/active_analytics/assets/browsers/yandex.svg
|
91
|
+
- app/views/active_analytics/browsers/_table.html.erb
|
92
|
+
- app/views/active_analytics/browsers/_version_table.html.erb
|
93
|
+
- app/views/active_analytics/browsers/index.html.erb
|
94
|
+
- app/views/active_analytics/browsers/show.html.erb
|
60
95
|
- app/views/active_analytics/pages/_table.html.erb
|
61
96
|
- app/views/active_analytics/pages/index.html.erb
|
62
97
|
- app/views/active_analytics/pages/show.html.erb
|
@@ -64,6 +99,7 @@ files:
|
|
64
99
|
- app/views/active_analytics/referrers/index.html.erb
|
65
100
|
- app/views/active_analytics/referrers/show.html.erb
|
66
101
|
- app/views/active_analytics/sites/_histogram.html.erb
|
102
|
+
- app/views/active_analytics/sites/_histogram_header.html.erb
|
67
103
|
- app/views/active_analytics/sites/index.html.erb
|
68
104
|
- app/views/active_analytics/sites/show.html.erb
|
69
105
|
- app/views/layouts/active_analytics/_footer.html.erb
|
@@ -71,6 +107,7 @@ files:
|
|
71
107
|
- app/views/layouts/active_analytics/application.html.erb
|
72
108
|
- config/routes.rb
|
73
109
|
- db/migrate/20210303094108_create_active_analytics_views_per_days.rb
|
110
|
+
- db/migrate/20240823150626_create_active_analytics_browsers_per_days.rb
|
74
111
|
- lib/active_analytics.rb
|
75
112
|
- lib/active_analytics/engine.rb
|
76
113
|
- lib/active_analytics/version.rb
|
@@ -83,7 +120,7 @@ metadata:
|
|
83
120
|
homepage_uri: https://github.com/BaseSecrete/active_analytics
|
84
121
|
source_code_uri: https://github.com/BaseSecrete/active_analytics
|
85
122
|
changelog_uri: https://github.com/BaseSecrete/active_analytics
|
86
|
-
post_install_message:
|
123
|
+
post_install_message:
|
87
124
|
rdoc_options: []
|
88
125
|
require_paths:
|
89
126
|
- lib
|
@@ -98,8 +135,8 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
98
135
|
- !ruby/object:Gem::Version
|
99
136
|
version: '0'
|
100
137
|
requirements: []
|
101
|
-
rubygems_version: 3.
|
102
|
-
signing_key:
|
138
|
+
rubygems_version: 3.5.22
|
139
|
+
signing_key:
|
103
140
|
specification_version: 4
|
104
141
|
summary: First-party, privacy-focused traffic analytics for Ruby on Rails applications
|
105
142
|
test_files: []
|
@@ -1,15 +0,0 @@
|
|
1
|
-
/*
|
2
|
-
* This is a manifest file that'll be compiled into application.css, which will include all the files
|
3
|
-
* listed below.
|
4
|
-
*
|
5
|
-
* Any CSS and SCSS file within this directory, lib/assets/stylesheets, vendor/assets/stylesheets,
|
6
|
-
* or any plugin's vendor/assets/stylesheets directory can be referenced here using a relative path.
|
7
|
-
*
|
8
|
-
* You're free to add application-wide styles to this file and they'll appear at the bottom of the
|
9
|
-
* compiled file so the styles you add here take precedence over styles defined in any other CSS/SCSS
|
10
|
-
* files in this directory. Styles in this file should be added after the last require_* statement.
|
11
|
-
* It is generally better to create a new file per style scope.
|
12
|
-
*
|
13
|
-
*= require_tree .
|
14
|
-
*= require_self
|
15
|
-
*/
|
@@ -1,296 +0,0 @@
|
|
1
|
-
/*
|
2
|
-
* Charts.css v0.9.0 (https://ChartsCSS.org/)
|
3
|
-
* Copyright 2020 Rami Yushuvaev
|
4
|
-
* Licensed under MIT
|
5
|
-
*/
|
6
|
-
.charts-css {
|
7
|
-
--chart-bg-color: transparent;
|
8
|
-
--heading-size: 0px;
|
9
|
-
--primary-axis-color: rgba(var(--color-grey-100), 1);
|
10
|
-
--primary-axis-style: solid;
|
11
|
-
--primary-axis-width: 1px;
|
12
|
-
--secondary-axes-color: rgba(var(--color-grey-50), 1);
|
13
|
-
--secondary-axes-style: solid;
|
14
|
-
--secondary-axes-width: 1px;
|
15
|
-
--data-axes-color: rgba(var(--color-grey-200), 1);
|
16
|
-
--data-axes-style: solid;
|
17
|
-
--data-axes-width: 1px;
|
18
|
-
--legend-border-color: rgba(var(--color-grey-200), 1);
|
19
|
-
position: relative;
|
20
|
-
display: block;
|
21
|
-
margin: 0;
|
22
|
-
padding: 0;
|
23
|
-
border: 0;
|
24
|
-
}
|
25
|
-
|
26
|
-
/*
|
27
|
-
* Chart wrapper element
|
28
|
-
*/
|
29
|
-
|
30
|
-
.charts-css, .charts-css::after, .charts-css::before,
|
31
|
-
.charts-css *,
|
32
|
-
.charts-css *::after,
|
33
|
-
.charts-css *::before {
|
34
|
-
-webkit-box-sizing: border-box;
|
35
|
-
box-sizing: border-box;
|
36
|
-
}
|
37
|
-
|
38
|
-
/*
|
39
|
-
* Reset table element
|
40
|
-
*/
|
41
|
-
table.charts-css {
|
42
|
-
border-collapse: collapse;
|
43
|
-
border-spacing: 0;
|
44
|
-
empty-cells: show;
|
45
|
-
overflow: initial;
|
46
|
-
background-color: transparent;
|
47
|
-
}
|
48
|
-
|
49
|
-
table.charts-css caption,
|
50
|
-
table.charts-css colgroup,
|
51
|
-
table.charts-css thead,
|
52
|
-
table.charts-css tbody,
|
53
|
-
table.charts-css tr,
|
54
|
-
table.charts-css th,
|
55
|
-
table.charts-css td {
|
56
|
-
display: block;
|
57
|
-
margin: 0;
|
58
|
-
padding: 0;
|
59
|
-
border: 0;
|
60
|
-
background-color: transparent;
|
61
|
-
}
|
62
|
-
|
63
|
-
table.charts-css colgroup,
|
64
|
-
table.charts-css thead,
|
65
|
-
table.charts-css tfoot {
|
66
|
-
display: none;
|
67
|
-
}
|
68
|
-
|
69
|
-
|
70
|
-
/*
|
71
|
-
* Chart colors
|
72
|
-
*/
|
73
|
-
|
74
|
-
.charts-css.column tbody tr td {
|
75
|
-
background: rgba(var(--color-grey-100), 1);
|
76
|
-
padding: 0;
|
77
|
-
}
|
78
|
-
|
79
|
-
/*
|
80
|
-
* Chart data
|
81
|
-
*/
|
82
|
-
.charts-css.hide-data .data {
|
83
|
-
opacity: 0;
|
84
|
-
}
|
85
|
-
|
86
|
-
.charts-css.show-data-on-hover .data {
|
87
|
-
-webkit-transition-duration: .3s;
|
88
|
-
transition-duration: .3s;
|
89
|
-
opacity: 0;
|
90
|
-
}
|
91
|
-
|
92
|
-
.charts-css.show-data-on-hover tr:hover .data {
|
93
|
-
-webkit-transition-duration: .3s;
|
94
|
-
transition-duration: .3s;
|
95
|
-
opacity: 1;
|
96
|
-
}
|
97
|
-
|
98
|
-
/*
|
99
|
-
* Chart labels
|
100
|
-
*/
|
101
|
-
|
102
|
-
.charts-css.column:not(.show-labels) {
|
103
|
-
--labels-size: 0;
|
104
|
-
}
|
105
|
-
|
106
|
-
.charts-css.column:not(.show-labels) tbody tr th {
|
107
|
-
display: none;
|
108
|
-
}
|
109
|
-
|
110
|
-
.charts-css.column.show-labels {
|
111
|
-
--labels-size: 1.5rem;
|
112
|
-
}
|
113
|
-
|
114
|
-
.charts-css.column.show-labels tbody tr th {
|
115
|
-
display: -webkit-box;
|
116
|
-
display: -ms-flexbox;
|
117
|
-
display: flex;
|
118
|
-
-webkit-box-pack: var(--labels-align, center);
|
119
|
-
-ms-flex-pack: var(--labels-align, center);
|
120
|
-
justify-content: var(--labels-align, center);
|
121
|
-
-webkit-box-align: center;
|
122
|
-
-ms-flex-align: center;
|
123
|
-
align-items: center;
|
124
|
-
-webkit-box-orient: vertical;
|
125
|
-
-webkit-box-direction: normal;
|
126
|
-
-ms-flex-direction: column;
|
127
|
-
flex-direction: column;
|
128
|
-
}
|
129
|
-
|
130
|
-
@media (max-width: 600px) {
|
131
|
-
.charts-css.column.show-labels {
|
132
|
-
--labels-size: 0;
|
133
|
-
}
|
134
|
-
|
135
|
-
.charts-css.column.show-labels tbody tr th {
|
136
|
-
display: none;
|
137
|
-
}
|
138
|
-
}
|
139
|
-
|
140
|
-
/*
|
141
|
-
* Chart axes
|
142
|
-
*/
|
143
|
-
.charts-css.column.show-primary-axis:not(.reverse) tbody tr {
|
144
|
-
-webkit-border-after: var(--primary-axis-width) var(--primary-axis-style) var(--primary-axis-color);
|
145
|
-
border-block-end: var(--primary-axis-width) var(--primary-axis-style) var(--primary-axis-color);
|
146
|
-
}
|
147
|
-
|
148
|
-
.charts-css.column.show-primary-axis.reverse tbody tr {
|
149
|
-
-webkit-border-before: var(--primary-axis-width) var(--primary-axis-style) var(--primary-axis-color);
|
150
|
-
border-block-start: var(--primary-axis-width) var(--primary-axis-style) var(--primary-axis-color);
|
151
|
-
}
|
152
|
-
|
153
|
-
.charts-css.column.show-5-secondary-axes:not(.reverse) tbody tr {
|
154
|
-
background-size: 100% 20%;
|
155
|
-
background-image: -webkit-gradient(linear, left top, left bottom, from(var(--secondary-axes-color)), to(transparent));
|
156
|
-
background-image: linear-gradient(var(--secondary-axes-color) var(--secondary-axes-width), transparent var(--secondary-axes-width));
|
157
|
-
}
|
158
|
-
|
159
|
-
.charts-css.column.show-5-secondary-axes.reverse tbody tr {
|
160
|
-
background-size: 100% 20%;
|
161
|
-
background-image: -webkit-gradient(linear, left bottom, left top, from(var(--secondary-axes-color)), to(transparent));
|
162
|
-
background-image: linear-gradient(0deg, var(--secondary-axes-color) var(--secondary-axes-width), transparent var(--secondary-axes-width));
|
163
|
-
}
|
164
|
-
|
165
|
-
/*
|
166
|
-
* Chart tooltips
|
167
|
-
*/
|
168
|
-
.charts-css .tooltip {
|
169
|
-
position: absolute;
|
170
|
-
z-index: 1;
|
171
|
-
bottom: 50%;
|
172
|
-
left: 50%;
|
173
|
-
-webkit-transform: translateX(-50%);
|
174
|
-
transform: translateX(-50%);
|
175
|
-
width: -webkit-max-content;
|
176
|
-
width: -moz-max-content;
|
177
|
-
width: max-content;
|
178
|
-
padding: 5px 10px;
|
179
|
-
border-radius: 6px;
|
180
|
-
visibility: hidden;
|
181
|
-
opacity: 0;
|
182
|
-
-webkit-transition: opacity .3s;
|
183
|
-
transition: opacity .3s;
|
184
|
-
background-color: rgba(var(--color-grey-500), 1);
|
185
|
-
color: rgba(var(--color-grey-00), 1);
|
186
|
-
text-align: center;
|
187
|
-
font-size: .9rem;
|
188
|
-
}
|
189
|
-
|
190
|
-
.charts-css .tooltip::after {
|
191
|
-
content: "";
|
192
|
-
position: absolute;
|
193
|
-
top: 100%;
|
194
|
-
left: 50%;
|
195
|
-
margin-left: -5px;
|
196
|
-
border-width: 5px;
|
197
|
-
border-style: solid;
|
198
|
-
border-color: rgba(var(--color-grey-500), 1) transparent transparent;
|
199
|
-
}
|
200
|
-
|
201
|
-
.charts-css tr:hover .tooltip {
|
202
|
-
visibility: visible;
|
203
|
-
opacity: 1;
|
204
|
-
}
|
205
|
-
|
206
|
-
/*
|
207
|
-
* Column Chart
|
208
|
-
*/
|
209
|
-
.charts-css.column tbody {
|
210
|
-
display: -webkit-box;
|
211
|
-
display: -ms-flexbox;
|
212
|
-
display: flex;
|
213
|
-
-webkit-box-pack: justify;
|
214
|
-
-ms-flex-pack: justify;
|
215
|
-
justify-content: space-between;
|
216
|
-
-webkit-box-align: stretch;
|
217
|
-
-ms-flex-align: stretch;
|
218
|
-
align-items: stretch;
|
219
|
-
width: 100%;
|
220
|
-
height: calc(100% - var(--heading-size));
|
221
|
-
}
|
222
|
-
|
223
|
-
.charts-css.column tbody tr {
|
224
|
-
position: relative;
|
225
|
-
-webkit-box-flex: 1;
|
226
|
-
-ms-flex-positive: 1;
|
227
|
-
flex-grow: 1;
|
228
|
-
-ms-flex-negative: 1;
|
229
|
-
flex-shrink: 1;
|
230
|
-
-ms-flex-preferred-size: 0;
|
231
|
-
flex-basis: 0;
|
232
|
-
overflow-wrap: anywhere;
|
233
|
-
display: -webkit-box;
|
234
|
-
display: -ms-flexbox;
|
235
|
-
display: flex;
|
236
|
-
-webkit-box-pack: start;
|
237
|
-
-ms-flex-pack: start;
|
238
|
-
justify-content: flex-start;
|
239
|
-
min-width: 0;
|
240
|
-
}
|
241
|
-
|
242
|
-
.charts-css.column tbody tr th {
|
243
|
-
position: absolute;
|
244
|
-
right: 0;
|
245
|
-
left: 0;
|
246
|
-
}
|
247
|
-
|
248
|
-
.charts-css.column tbody tr td {
|
249
|
-
display: -webkit-box;
|
250
|
-
display: -ms-flexbox;
|
251
|
-
display: flex;
|
252
|
-
-webkit-box-pack: center;
|
253
|
-
-ms-flex-pack: center;
|
254
|
-
justify-content: center;
|
255
|
-
width: 100%;
|
256
|
-
height: calc(100% * var(--size, 1));
|
257
|
-
position: relative;
|
258
|
-
}
|
259
|
-
|
260
|
-
.charts-css.column:not(.reverse) tbody tr {
|
261
|
-
-webkit-box-align: end;
|
262
|
-
-ms-flex-align: end;
|
263
|
-
align-items: flex-end;
|
264
|
-
-webkit-margin-after: var(--labels-size);
|
265
|
-
margin-block-end: var(--labels-size);
|
266
|
-
}
|
267
|
-
|
268
|
-
.charts-css.column:not(.reverse) tbody tr th {
|
269
|
-
bottom: calc(-1 * var(--labels-size) - var(--primary-axis-width));
|
270
|
-
height: var(--labels-size);
|
271
|
-
color: rgba(var(--color-grey-400), 1);
|
272
|
-
font-weight: 400;
|
273
|
-
}
|
274
|
-
|
275
|
-
.charts-css.column:not(.reverse) tbody tr td {
|
276
|
-
-webkit-box-align: start;
|
277
|
-
-ms-flex-align: start;
|
278
|
-
align-items: flex-start;
|
279
|
-
}
|
280
|
-
|
281
|
-
.charts-css.column:not(.stacked) tbody tr td {
|
282
|
-
-webkit-box-flex: 1;
|
283
|
-
-ms-flex-positive: 1;
|
284
|
-
flex-grow: 1;
|
285
|
-
-ms-flex-negative: 1;
|
286
|
-
flex-shrink: 1;
|
287
|
-
-ms-flex-preferred-size: 0;
|
288
|
-
flex-basis: 0;
|
289
|
-
}
|
290
|
-
|
291
|
-
.charts-css.column:not(.reverse-data) tbody {
|
292
|
-
-webkit-box-orient: horizontal;
|
293
|
-
-webkit-box-direction: normal;
|
294
|
-
-ms-flex-direction: row;
|
295
|
-
flex-direction: row;
|
296
|
-
}
|
File without changes
|