j1-template 2022.0.12 → 2022.0.16

Sign up to get free protection for your applications and to get access to all the features.
Files changed (83) hide show
  1. checksums.yaml +4 -4
  2. data/assets/themes/j1/adapter/js/advertising.js +65 -44
  3. data/assets/themes/j1/adapter/js/algolia.js +9 -9
  4. data/assets/themes/j1/adapter/js/analytics.js +46 -24
  5. data/assets/themes/j1/adapter/js/asciidoctor.js +9 -9
  6. data/assets/themes/j1/adapter/js/attic.js +9 -1
  7. data/assets/themes/j1/adapter/js/bmd.js +9 -10
  8. data/assets/themes/j1/adapter/js/carousel.js +9 -9
  9. data/assets/themes/j1/adapter/js/clipboard.js +9 -9
  10. data/assets/themes/j1/adapter/js/comments.js +31 -10
  11. data/assets/themes/j1/adapter/js/cookieConsent.js +73 -80
  12. data/assets/themes/j1/adapter/js/fab.js +10 -10
  13. data/assets/themes/j1/adapter/js/framer.js +59 -58
  14. data/assets/themes/j1/adapter/js/j1.js +166 -103
  15. data/assets/themes/j1/adapter/js/justifiedGallery.js +11 -10
  16. data/assets/themes/j1/adapter/js/justifiedGalleryCustomizer.js +9 -9
  17. data/assets/themes/j1/adapter/js/lightbox.js +11 -4
  18. data/assets/themes/j1/adapter/js/logger.js +10 -3
  19. data/assets/themes/j1/adapter/js/mmenu.js +9 -9
  20. data/assets/themes/j1/adapter/js/navigator.js +9 -9
  21. data/assets/themes/j1/adapter/js/quicksearch.js +9 -9
  22. data/assets/themes/j1/adapter/js/rouge.js +9 -9
  23. data/assets/themes/j1/adapter/js/rtable.js +9 -9
  24. data/assets/themes/j1/adapter/js/rtextResizer.js +9 -9
  25. data/assets/themes/j1/adapter/js/scroller.js +12 -7
  26. data/assets/themes/j1/adapter/js/themer.js +11 -2
  27. data/assets/themes/j1/adapter/js/toccer.js +9 -9
  28. data/assets/themes/j1/adapter/js/translator.js +13 -16
  29. data/assets/themes/j1/core/css/vendor.css +6 -1
  30. data/assets/themes/j1/core/css/vendor.min.css +1 -1
  31. data/assets/themes/j1/core/js/template.js +4 -3
  32. data/assets/themes/j1/core/js/template.min.js +1 -1
  33. data/assets/themes/j1/core/js/template.min.js.map +1 -1
  34. data/assets/themes/j1/modules/advertising/js/google/adInitializer.js +14 -4
  35. data/exe/j1 +31 -11
  36. data/lib/j1/commands/generate.rb +37 -36
  37. data/lib/j1/commands/help.rb +35 -0
  38. data/lib/j1/commands/patch.rb +81 -0
  39. data/lib/j1/commands/reset.rb +36 -0
  40. data/lib/j1/commands/setup.rb +126 -0
  41. data/lib/j1/commands/site.rb +27 -0
  42. data/lib/j1/external.rb +1 -1
  43. data/lib/j1/utils/exec_until_trap.rb +28 -0
  44. data/lib/j1/utils.rb +31 -0
  45. data/lib/j1/version.rb +1 -1
  46. data/lib/starter_web/Gemfile +1 -1
  47. data/lib/starter_web/_config.yml +1 -1
  48. data/lib/starter_web/_data/layouts/home.ads.yml +262 -0
  49. data/lib/starter_web/_data/layouts/home.no-ads.yml +262 -0
  50. data/lib/starter_web/_data/layouts/home.yml +1 -1
  51. data/lib/starter_web/_data/modules/advertising.yml +1 -12
  52. data/lib/starter_web/_data/modules/analytics.yml +1 -1
  53. data/lib/starter_web/_data/modules/cookies.yml +5 -2
  54. data/lib/starter_web/_data/modules/defaults/advertising.yml +7 -8
  55. data/lib/starter_web/_data/modules/defaults/comments.yml +4 -4
  56. data/lib/starter_web/_data/modules/defaults/cookies.yml +106 -36
  57. data/lib/starter_web/_data/modules/defaults/themer.yml +3 -2
  58. data/lib/starter_web/_data/modules/themer.yml +2 -1
  59. data/lib/starter_web/_includes/attributes.asciidoc +1 -1
  60. data/lib/starter_web/_plugins/lunr_index.rb +1 -1
  61. data/lib/starter_web/collections/posts/public/featured/_posts/0000-00-00-welcome-to-j1.adoc.erb +1 -1
  62. data/lib/starter_web/collections/posts/public/featured/_posts/2021-01-01-about-cookies.adoc +1 -1
  63. data/lib/starter_web/collections/posts/public/featured/_posts/2021-01-01-about-cookies.ads.asciidoc +1 -1
  64. data/lib/starter_web/collections/posts/public/featured/_posts/2021-01-01-about-cookies.comments.asciidoc +1 -1
  65. data/lib/starter_web/collections/posts/public/featured/_posts/2021-02-01-site-generators.adoc +1 -1
  66. data/lib/starter_web/collections/posts/public/featured/_posts/2021-03-03-about-j1.adoc +1 -1
  67. data/lib/starter_web/collections/posts/public/series/_posts/2020-01-01-post-wiki-series.adoc +1 -1
  68. data/lib/starter_web/collections/posts/public/series/_posts/2020-01-02-post-wiki-series.adoc +1 -1
  69. data/lib/starter_web/collections/posts/public/series/_posts/2020-01-03-post-wiki-series.adoc +1 -1
  70. data/lib/starter_web/index.html +0 -3
  71. data/lib/starter_web/package.json +5 -1
  72. data/lib/starter_web/pages/public/asciidoc_skeletons/documentation/000_intro.adoc +1 -1
  73. data/lib/starter_web/pages/public/asciidoc_skeletons/documentation/100_converter.adoc +1 -1
  74. data/lib/starter_web/pages/public/asciidoc_skeletons/documentation/200_themes.adoc +1 -1
  75. data/lib/starter_web/pages/public/asciidoc_skeletons/documentation/documentation.adoc +1 -4
  76. data/lib/starter_web/pages/public/asciidoc_skeletons/multi-document/multi.adoc +1 -4
  77. data/lib/starter_web/pages/public/asciidoc_skeletons/simple-document/simple.adoc +1 -4
  78. data/lib/starter_web/pages/public/learn/roundtrip/400_asciidoc_extensions.adoc +7 -7
  79. data/lib/starter_web/pages/public/manuals/dropdown-help.adoc +23 -2
  80. data/lib/starter_web/pages/public/previewer/preview_bootstrap_theme.adoc +100 -166
  81. data/lib/starter_web/utilsrv/_defaults/package.json +1 -1
  82. data/lib/starter_web/utilsrv/package.json +1 -1
  83. metadata +11 -3
@@ -98,7 +98,15 @@ j1.adapter.quicksearch = (function (j1, window) {
98
98
  init: function (options) {
99
99
 
100
100
  // -----------------------------------------------------------------------
101
- // globals
101
+ // Default module settings
102
+ // -----------------------------------------------------------------------
103
+ var settings = $.extend({
104
+ module_name: 'j1.adapter.quicksearch',
105
+ generated: '{{site.time}}'
106
+ }, options);
107
+
108
+ // -----------------------------------------------------------------------
109
+ // Global variable settings
102
110
  // -----------------------------------------------------------------------
103
111
  _this = j1.adapter.quicksearch;
104
112
  logger = log4javascript.getLogger('j1.adapter.quicksearch');
@@ -108,14 +116,6 @@ j1.adapter.quicksearch = (function (j1, window) {
108
116
  logger.info('\n' + 'state: ' + _this.getState());
109
117
  logger.info('\n' + 'module is being initialized');
110
118
 
111
- // -----------------------------------------------------------------------
112
- // defaults
113
- // -----------------------------------------------------------------------
114
- var settings = $.extend({
115
- module_name: 'j1.adapter.quicksearch',
116
- generated: '{{site.time}}'
117
- }, options);
118
-
119
119
  // -----------------------------------------------------------------------
120
120
  // options loader
121
121
  // -----------------------------------------------------------------------
@@ -101,7 +101,15 @@ j1.adapter.rouge = (function (j1, window) {
101
101
  init: function (options) {
102
102
 
103
103
  // -----------------------------------------------------------------------
104
- // globals
104
+ // Default module settings
105
+ // -----------------------------------------------------------------------
106
+ var settings = $.extend({
107
+ module_name: 'j1.adapter.rouge',
108
+ generated: '{{site.time}}'
109
+ }, options);
110
+
111
+ // -----------------------------------------------------------------------
112
+ // Global variable settings
105
113
  // -----------------------------------------------------------------------
106
114
  _this = j1.adapter.rouge;
107
115
  logger = log4javascript.getLogger('j1.adapter.rouge');
@@ -111,14 +119,6 @@ j1.adapter.rouge = (function (j1, window) {
111
119
  logger.info('\n' + 'state: ' + _this.getState());
112
120
  logger.info('\n' + 'module is being initialized');
113
121
 
114
- // -----------------------------------------------------------------------
115
- // Default module settings
116
- // -----------------------------------------------------------------------
117
- var settings = $.extend({
118
- module_name: 'j1.adapter.rouge',
119
- generated: '{{site.time}}'
120
- }, options);
121
-
122
122
  // -----------------------------------------------------------------------
123
123
  // rouge initializer
124
124
  // -----------------------------------------------------------------------
@@ -101,7 +101,15 @@ j1.adapter.rtable = (function (j1, window) {
101
101
  init: function (options) {
102
102
 
103
103
  // -----------------------------------------------------------------------
104
- // globals
104
+ // Default module settings
105
+ // -----------------------------------------------------------------------
106
+ var settings = $.extend({
107
+ module_name: 'j1.adapter.rtable',
108
+ generated: '{{site.time}}'
109
+ }, options);
110
+
111
+ // -----------------------------------------------------------------------
112
+ // Global variable settings
105
113
  // -----------------------------------------------------------------------
106
114
  _this = j1.adapter.rtable;
107
115
  logger = log4javascript.getLogger('j1.adapter.rtable');
@@ -111,14 +119,6 @@ j1.adapter.rtable = (function (j1, window) {
111
119
  logger.info('\n' + 'state: ' + _this.getState());
112
120
  logger.info('\n' + 'module is being initialized');
113
121
 
114
- // -----------------------------------------------------------------------
115
- // Default module settings
116
- // -----------------------------------------------------------------------
117
- var settings = $.extend({
118
- module_name: 'j1.adapter.rtable',
119
- generated: '{{site.time}}'
120
- }, options);
121
-
122
122
  // create settings object from frontmatterOptions
123
123
  frontmatterOptions = options != null ? $.extend({}, options) : {};
124
124
  moduleOptions = $.extend({}, {{rtable_options | replace: 'nil', 'null' | replace: '=>', ':' }});
@@ -111,7 +111,15 @@ j1.adapter.rtextResizer = (function (j1, window) {
111
111
  init: function (options) {
112
112
 
113
113
  // -----------------------------------------------------------------------
114
- // globals
114
+ // Default module settings
115
+ // -----------------------------------------------------------------------
116
+ var settings = $.extend({
117
+ module_name: 'j1.adapter.rtextResizer',
118
+ generated: '{{site.time}}'
119
+ }, options);
120
+
121
+ // -----------------------------------------------------------------------
122
+ // Global variable settings
115
123
  // -----------------------------------------------------------------------
116
124
  _this = j1.adapter.rtextResizer;
117
125
  logger = log4javascript.getLogger('j1.adapter.rtextResizer');
@@ -121,14 +129,6 @@ j1.adapter.rtextResizer = (function (j1, window) {
121
129
  logger.info('\n' + 'state: ' + _this.getState());
122
130
  logger.info('\n' + 'module is being initialized');
123
131
 
124
- // -----------------------------------------------------------------------
125
- // Default module settings
126
- // -----------------------------------------------------------------------
127
- var settings = $.extend({
128
- module_name: 'j1.adapter.rtextResizer',
129
- generated: '{{site.time}}'
130
- }, options);
131
-
132
132
  {% comment %} Load gallery config from yml data
133
133
  -------------------------------------------------------------------------- {% endcomment %}
134
134
  /* eslint-disable */
@@ -97,8 +97,18 @@ var lastPageInfo;
97
97
  // adapter initializer
98
98
  // -------------------------------------------------------------------------
99
99
  init: function (options) {
100
- {% comment %} Set global variables
101
- -------------------------------------------------------------------------- {% endcomment %}
100
+
101
+ // -----------------------------------------------------------------------
102
+ // Default module settings
103
+ // -----------------------------------------------------------------------
104
+ var settings = $.extend({
105
+ module_name: 'j1.adapter.scroller',
106
+ generated: '{{site.time}}'
107
+ }, options);
108
+
109
+ // -----------------------------------------------------------------------
110
+ // Global variable settings
111
+ // -----------------------------------------------------------------------
102
112
  _this = j1.adapter.scroller;
103
113
  logger = log4javascript.getLogger('j1.adapter.scroller');
104
114
 
@@ -108,11 +118,6 @@ var lastPageInfo;
108
118
  logger.info('\n' + 'module is being initialized');
109
119
 
110
120
 
111
- // default module settings
112
- var settings = $.extend({
113
- module_name: 'j1.adapter.scroller',
114
- generated: '{{site.time}}'
115
- }, options);
116
121
 
117
122
  _this.generate_scrollers();
118
123
 
@@ -159,9 +159,18 @@ j1.adapter.themer = (function (j1, window) {
159
159
  // -------------------------------------------------------------------------
160
160
  // initializer
161
161
  // -------------------------------------------------------------------------
162
- init: function () {
162
+ init: function (options) {
163
+
164
+ // -----------------------------------------------------------------------
165
+ // Default module settings
166
+ // -----------------------------------------------------------------------
167
+ var settings = $.extend({
168
+ module_name: 'j1.adapter.themer',
169
+ generated: '{{site.time}}'
170
+ }, options);
171
+
163
172
  // -----------------------------------------------------------------------
164
- // globals
173
+ // Global variable settings
165
174
  // -----------------------------------------------------------------------
166
175
  _this = j1.adapter.themer;
167
176
  url = new liteURL(window.location.href);
@@ -117,7 +117,15 @@ j1.adapter.toccer = (function () {
117
117
  init: function (options) {
118
118
 
119
119
  // -----------------------------------------------------------------------
120
- // globals
120
+ // Default module settings
121
+ // -----------------------------------------------------------------------
122
+ var settings = $.extend({
123
+ module_name: 'j1.adapter.toccer',
124
+ generated: '{{site.time}}'
125
+ }, options);
126
+
127
+ // -----------------------------------------------------------------------
128
+ // Global variable settings
121
129
  // -----------------------------------------------------------------------
122
130
  _this = j1.adapter.toccer;
123
131
  logger = log4javascript.getLogger('j1.adapter.toccer');
@@ -130,14 +138,6 @@ j1.adapter.toccer = (function () {
130
138
  // create settings object from frontmatterOptions
131
139
  var frontmatterOptions = options != null ? $.extend({}, options) : {};
132
140
 
133
- // -----------------------------------------------------------------------
134
- // defaults
135
- // -----------------------------------------------------------------------
136
- var settings = $.extend({
137
- module_name: 'j1.adapter.toccer',
138
- generated: '{{site.time}}'
139
- }, options);
140
-
141
141
  // -----------------------------------------------------------------------
142
142
  // options loader
143
143
  // -----------------------------------------------------------------------
@@ -37,17 +37,16 @@ regenerate: true
37
37
  -------------------------------------------------------------------------------- {% endcomment %}
38
38
  {% assign cookie_defaults = modules.defaults.cookies.defaults %}
39
39
  {% assign cookie_settings = modules.cookies.settings %}
40
-
41
- {% assign tracking_enabled = modules.analytics.settings.enabled %}
42
-
43
40
  {% assign translator_defaults = modules.defaults.translator.defaults %}
44
41
  {% assign translator_settings = modules.translator.settings %}
45
42
 
46
-
47
43
  {% comment %} Set config options
48
44
  -------------------------------------------------------------------------------- {% endcomment %}
49
- {% assign translator_options = translator_defaults | merge: translator_settings %}
50
45
  {% assign cookie_options = cookie_defaults | merge: cookie_settings %}
46
+ {% assign translator_options = translator_defaults | merge: translator_settings %}
47
+
48
+ {% comment %} Set variables
49
+ -------------------------------------------------------------------------------- {% endcomment %}
51
50
 
52
51
  {% assign production = false %}
53
52
  {% if environment == 'prod' or environment == 'production' %}
@@ -84,9 +83,7 @@ regenerate: true
84
83
  'use strict';
85
84
 
86
85
  j1.adapter.translator = (function (j1, window) {
87
-
88
86
  var environment = '{{environment}}';
89
- var tracking_enabled = ('{{tracking_enabled}}' === 'true') ? true: false; // Analytics/GA enabled?
90
87
  var moduleOptions = {};
91
88
  var user_translate = {};
92
89
  var _this;
@@ -122,7 +119,15 @@ j1.adapter.translator = (function (j1, window) {
122
119
  init: function (options) {
123
120
 
124
121
  // -----------------------------------------------------------------------
125
- // globals
122
+ // Default module settings
123
+ // -----------------------------------------------------------------------
124
+ var settings = $.extend({
125
+ module_name: 'j1.adapter.translator',
126
+ generated: '{{site.time}}'
127
+ }, options);
128
+
129
+ // -----------------------------------------------------------------------
130
+ // Global variable settings
126
131
  // -----------------------------------------------------------------------
127
132
  _this = j1.adapter.translator;
128
133
  logger = log4javascript.getLogger('j1.adapter.translator');
@@ -154,14 +159,6 @@ j1.adapter.translator = (function (j1, window) {
154
159
  // initialize state flag
155
160
  _this.state = 'pending';
156
161
 
157
- // -----------------------------------------------------------------------
158
- // Default module settings
159
- // -----------------------------------------------------------------------
160
- var settings = $.extend({
161
- module_name: 'j1.adapter.translator',
162
- generated: '{{site.time}}'
163
- }, options);
164
-
165
162
  {% comment %} Load module config from yml data
166
163
  -------------------------------------------------------------------------- {% endcomment %}
167
164
  // Load module DEFAULTS|CONFIG
@@ -924,11 +924,16 @@ ul.disc {
924
924
 
925
925
  .btn-viewer:hover {
926
926
  color: #fff;
927
- background-color: #607d8b; }
927
+ background-color: #2196f3; }
928
928
 
929
929
  .btn-viewer + .tooltip > .tooltip-inner {
930
930
  background-color: #f00; }
931
931
 
932
+ .j1-viewer {
933
+ position: relative;
934
+ display: block;
935
+ float: right; }
936
+
932
937
  /*
933
938
  # ----------------------------------------------------------------------------
934
939
  # ~/vendor/flag-icons/flag-icons.scss