keppler 2.1.11 → 2.1.12
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/Gemfile.lock +1 -1
- data/LICENSE +674 -0
- data/installer/core/Gemfile.lock +0 -0
- data/installer/core/LICENSE +674 -0
- data/installer/core/app/assets/javascripts/admin/main.coffee +1 -1
- data/installer/core/app/controllers/admin/settings_controller.rb +4 -0
- data/installer/core/app/controllers/application_controller.rb +1 -0
- data/installer/core/app/views/admin/layouts/_navigation.html.haml +1 -1
- data/installer/core/app/views/admin/layouts/_sidebar.html.haml +1 -1
- data/installer/core/app/views/admin/scripts/index.html.haml +1 -1
- data/installer/core/app/views/app/layouts/_google_analytics.html.haml +5 -6
- data/installer/core/config/circleci/db_config.yml +2 -2
- data/installer/core/config/locales/en.yml +3 -0
- data/installer/core/config/routes.rb +0 -8
- data/installer/core/config/settings.yml +2 -2
- data/installer/core/db/seeds.rb +6 -9
- data/installer/core/rockets/keppler_frontend/app/assets/html/keppler_frontend/app/bootstrap/conf +0 -0
- data/installer/core/rockets/keppler_frontend/app/assets/html/keppler_frontend/app/conf +0 -0
- data/installer/core/rockets/keppler_frontend/app/assets/html/keppler_frontend/app/keppler/conf +0 -0
- data/installer/core/rockets/keppler_frontend/app/assets/html/keppler_frontend/app/slick/conf +0 -0
- data/installer/core/rockets/keppler_frontend/app/assets/javascripts/keppler_frontend/app/grapes/grapes-editor.js +1174 -0
- data/installer/core/rockets/keppler_frontend/app/controllers/keppler_frontend/app/app_controller.rb +1 -1
- data/installer/core/rockets/keppler_frontend/app/controllers/keppler_frontend/concerns/services.rb +0 -0
- data/installer/core/rockets/keppler_frontend/app/helpers/keppler_frontend/app/frontend_helper.rb +1 -1
- data/installer/core/rockets/keppler_frontend/app/models/keppler_frontend/concerns/partials/helper_file.rb +4 -4
- data/installer/core/rockets/keppler_frontend/app/models/keppler_frontend/concerns/partials/html_file.rb +14 -20
- data/installer/core/rockets/keppler_frontend/app/models/keppler_frontend/concerns/partials/scss_file.rb +1 -1
- data/installer/core/rockets/keppler_frontend/app/services/keppler_frontend/editor/file_format.rb +0 -0
- data/installer/core/rockets/keppler_frontend/app/services/keppler_frontend/editor/resources.rb +0 -0
- data/installer/core/rockets/keppler_frontend/app/services/keppler_frontend/editor/resources_format.rb +0 -0
- data/installer/core/rockets/keppler_frontend/app/services/keppler_frontend/urls/assets.rb +0 -0
- data/installer/core/rockets/keppler_frontend/app/services/keppler_frontend/urls/config.rb +0 -0
- data/installer/core/rockets/keppler_frontend/app/services/keppler_frontend/urls/front.rb +0 -0
- data/installer/core/rockets/keppler_frontend/app/services/keppler_frontend/urls/roots.rb +0 -0
- data/installer/core/rockets/keppler_frontend/app/services/keppler_frontend/utils/code_search.rb +0 -0
- data/installer/core/rockets/keppler_frontend/app/services/keppler_frontend/utils/file_format.rb +0 -0
- data/installer/core/rockets/keppler_frontend/app/services/keppler_frontend/utils/yml_handler.rb +0 -0
- data/installer/core/rockets/keppler_frontend/app/services/keppler_frontend/views/actions_handler.rb +0 -0
- data/installer/core/rockets/keppler_frontend/app/services/keppler_frontend/views/css_handler.rb +0 -0
- data/installer/core/rockets/keppler_frontend/app/services/keppler_frontend/views/html_handler.rb +0 -0
- data/installer/core/rockets/keppler_frontend/app/services/keppler_frontend/views/install.rb +0 -0
- data/installer/core/rockets/keppler_frontend/app/services/keppler_frontend/views/js_handler.rb +0 -0
- data/installer/core/rockets/keppler_frontend/app/services/keppler_frontend/views/remote_js_handler.rb +0 -0
- data/installer/core/rockets/keppler_frontend/app/services/keppler_frontend/views/routes_handler.rb +0 -0
- data/installer/core/rockets/keppler_frontend/app/services/keppler_frontend/views/uninstall.rb +0 -0
- data/installer/core/rockets/keppler_frontend/app/views/keppler_frontend/admin/views/_editor_assets.html.haml +25 -23
- data/installer/core/rockets/keppler_frontend/app/views/keppler_frontend/admin/views/_editor_themes.html.haml +25 -23
- data/installer/core/rockets/keppler_frontend/app/views/keppler_frontend/admin/views/_editor_views.html.haml +23 -21
- data/installer/core/rockets/keppler_frontend/app/views/keppler_frontend/admin/views/index.html.haml +11 -10
- data/installer/core/rockets/keppler_frontend/app/views/keppler_frontend/app/partials/_devise_login.html.erb +34 -34
- data/installer/core/rockets/keppler_frontend/app/views/layouts/keppler_frontend/app/layouts/application.html.erb +0 -1
- data/installer/core/rockets/keppler_frontend/app/views/layouts/themes/keppler_default/application.html.erb +0 -1
- data/installer/core/rockets/keppler_ga_dashboard/app/controllers/keppler_ga_dashboard/admin/dashboard_controller.rb +64 -0
- data/installer/core/rockets/keppler_ga_dashboard/app/helpers/keppler_ga_dashboard/admin/dashboard_helper.rb +16 -0
- data/installer/core/rockets/keppler_ga_dashboard/app/helpers/keppler_ga_dashboard/application_helper.rb +4 -1
- data/installer/core/rockets/keppler_ga_dashboard/app/views/keppler_ga_dashboard/{dashboard → admin/dashboard}/analytics.html.haml +0 -0
- data/installer/core/rockets/keppler_ga_dashboard/config/routes.rb +1 -1
- data/installer/core/spec/controllers/keppler_frontend/admin/views_controller/create_view_spec.rb +0 -0
- data/installer/core/spec/controllers/keppler_frontend/admin/views_controller/editor_spec.rb +0 -0
- data/installer/core/spec/controllers/keppler_frontend/admin/views_controller/live_editor_save_spec.rb +0 -0
- data/installer/core/spec/fixtures/keppler_frontend/editor/test.html +0 -0
- data/installer/core/spec/fixtures/keppler_frontend/editor/test.png +0 -0
- data/installer/core/spec/fixtures/keppler_frontend/live_editor/test_index_1.html +0 -0
- data/installer/core/spec/fixtures/keppler_frontend/live_editor/test_index_2.html +0 -0
- data/installer/core/spec/models/keppler_frontend/view/live_editor_spec.rb +1 -0
- data/installer/core/spec/models/keppler_frontend/view/model_spec.rb +0 -0
- data/installer/core/spec/models/keppler_frontend/view/view_files_handler_spec.rb +0 -0
- data/installer/core/spec/models/user_spec.rb +0 -2
- data/installer/core/spec/routing/keppler_frontend/views_spec.rb +1 -0
- data/installer/core/spec/services/keppler_frontend/editor/file_format_spec.rb +0 -0
- data/installer/core/spec/services/keppler_frontend/editor/resources_format_spec.rb +0 -0
- data/installer/core/spec/services/keppler_frontend/editor/resources_spec.rb +0 -0
- data/installer/core/spec/services/keppler_frontend/urls/assets_spec.rb +0 -0
- data/installer/core/spec/services/keppler_frontend/urls/config_spec.rb +0 -0
- data/installer/core/spec/services/keppler_frontend/urls/front_spec.rb +0 -0
- data/installer/core/spec/services/keppler_frontend/urls/roots_spec.rb +0 -0
- data/installer/core/spec/services/keppler_frontend/utils/code_search_spec.rb +0 -0
- data/installer/core/spec/services/keppler_frontend/utils/file_format_spec.rb +0 -0
- data/installer/core/spec/services/keppler_frontend/utils/yml_handle_spec.rb +2 -0
- data/installer/core/spec/services/keppler_frontend/views/actions_handler_spec.rb +0 -0
- data/installer/core/spec/services/keppler_frontend/views/css_handler_spec.rb +0 -0
- data/installer/core/spec/services/keppler_frontend/views/format_html_spec.rb +0 -0
- data/installer/core/spec/services/keppler_frontend/views/format_remote_js_spec.rb +0 -0
- data/installer/core/spec/services/keppler_frontend/views/fromat_only_action_spec.rb +0 -0
- data/installer/core/spec/services/keppler_frontend/views/html_handler_spec.rb +0 -0
- data/installer/core/spec/services/keppler_frontend/views/js_handler_spec.rb +0 -0
- data/installer/core/spec/services/keppler_frontend/views/remote_js_handler_spec.rb +0 -0
- data/installer/core/spec/services/keppler_frontend/views/routes_handler_spec.rb +0 -0
- data/installer/core/vendor/cache/autoprefixer-rails-9.3.1.gem +0 -0
- data/installer/core/vendor/cache/bootsnap-1.3.2.gem +0 -0
- data/installer/core/vendor/cache/factory_bot-4.11.1.gem +0 -0
- data/installer/core/vendor/cache/factory_bot_rails-4.11.1.gem +0 -0
- data/installer/core/vendor/cache/faraday-0.15.3.gem +0 -0
- data/installer/core/vendor/cache/ffi-1.9.25.gem +0 -0
- data/installer/core/vendor/cache/i18n-1.1.1.gem +0 -0
- data/installer/core/vendor/cache/image_optimizer-1.8.0.gem +0 -0
- data/installer/core/vendor/cache/loofah-2.2.3.gem +0 -0
- data/installer/core/vendor/cache/mail-2.7.1.gem +0 -0
- data/installer/core/vendor/cache/marcel-0.3.3.gem +0 -0
- data/installer/core/vendor/cache/mime-types-3.2.2.gem +0 -0
- data/installer/core/vendor/cache/mime-types-data-3.2018.0812.gem +0 -0
- data/installer/core/vendor/cache/mini_mime-1.0.1.gem +0 -0
- data/installer/core/vendor/cache/money-6.13.1.gem +0 -0
- data/installer/core/vendor/cache/nokogiri-1.8.5.gem +0 -0
- data/installer/core/vendor/cache/parser-2.5.3.0.gem +0 -0
- data/installer/core/vendor/cache/powerpack-0.1.2.gem +0 -0
- data/installer/core/vendor/cache/public_suffix-3.0.3.gem +0 -0
- data/installer/core/vendor/cache/puma-3.12.0.gem +0 -0
- data/installer/core/vendor/cache/rack-test-1.1.0.gem +0 -0
- data/installer/core/vendor/cache/rails-assets-animate-css-3.7.0.gem +0 -0
- data/installer/core/vendor/cache/retriable-3.1.2.gem +0 -0
- data/installer/core/vendor/cache/rspec-expectations-3.8.2.gem +0 -0
- data/installer/core/vendor/cache/rspec-rails-3.8.1.gem +0 -0
- data/installer/core/vendor/cache/ruby-progressbar-1.10.0.gem +0 -0
- data/installer/core/vendor/cache/sass-3.6.0.gem +0 -0
- data/installer/core/vendor/cache/scss_lint-0.57.1.gem +0 -0
- data/installer/core/vendor/cache/signet-0.11.0.gem +0 -0
- data/installer/core/vendor/cache/spreadsheet-1.1.8.gem +0 -0
- data/installer/core/vendor/cache/sprockets-3.7.2.gem +0 -0
- data/installer/core/vendor/cache/turbolinks-source-5.2.0.gem +0 -0
- data/installer/core/vendor/cache/unicode-display_width-1.4.0.gem +0 -0
- data/installer/core/vendor/cache/web-console-3.7.0.gem +0 -0
- data/lib/keppler/cli.rb +1 -1
- data/lib/keppler/version.rb +1 -1
- metadata +11 -2993
- data/LICENSE.txt +0 -21
- data/installer/core/app/controllers/admin/customizes_controller.rb +0 -110
- data/installer/core/app/helpers/customizes_helper.rb +0 -5
- data/installer/core/app/models/customize.rb +0 -30
- data/installer/core/app/policies/customize_policy.rb +0 -11
- data/installer/core/app/services/admin/template_service.rb +0 -129
- data/installer/core/app/views/admin/customizes/_description.html.haml +0 -13
- data/installer/core/app/views/admin/customizes/_form.html.haml +0 -33
- data/installer/core/app/views/admin/customizes/_listing.html.haml +0 -15
- data/installer/core/app/views/admin/customizes/_switch_default_template.html.haml +0 -11
- data/installer/core/app/views/admin/customizes/_switch_template.html.haml +0 -19
- data/installer/core/app/views/admin/customizes/index.html.haml +0 -38
- data/installer/core/app/views/admin/customizes/new.html.haml +0 -4
- data/installer/core/db/migrate/20170603145521_create_customizes.rb +0 -10
- data/installer/core/rockets/keppler_frontend/app/assets/html/keppler_frontend/app/bootstrap/bstp-accordion.html +0 -56
- data/installer/core/rockets/keppler_frontend/app/assets/html/keppler_frontend/app/bootstrap/bstp-alert.html +0 -18
- data/installer/core/rockets/keppler_frontend/app/assets/html/keppler_frontend/app/bootstrap/bstp-button-group.html +0 -15
- data/installer/core/rockets/keppler_frontend/app/assets/html/keppler_frontend/app/bootstrap/bstp-button.html +0 -15
- data/installer/core/rockets/keppler_frontend/app/assets/html/keppler_frontend/app/bootstrap/bstp-checks.html +0 -23
- data/installer/core/rockets/keppler_frontend/app/assets/html/keppler_frontend/app/bootstrap/bstp-collapse.html +0 -23
- data/installer/core/rockets/keppler_frontend/app/assets/html/keppler_frontend/app/bootstrap/bstp-columns-12.html +0 -59
- data/installer/core/rockets/keppler_frontend/app/assets/html/keppler_frontend/app/bootstrap/bstp-columns-2.html +0 -29
- data/installer/core/rockets/keppler_frontend/app/assets/html/keppler_frontend/app/bootstrap/bstp-columns-3.html +0 -32
- data/installer/core/rockets/keppler_frontend/app/assets/html/keppler_frontend/app/bootstrap/bstp-columns-4.html +0 -35
- data/installer/core/rockets/keppler_frontend/app/assets/html/keppler_frontend/app/bootstrap/bstp-columns-6.html +0 -41
- data/installer/core/rockets/keppler_frontend/app/assets/html/keppler_frontend/app/bootstrap/bstp-container.html +0 -15
- data/installer/core/rockets/keppler_frontend/app/assets/html/keppler_frontend/app/bootstrap/bstp-dropdown-btn.html +0 -22
- data/installer/core/rockets/keppler_frontend/app/assets/html/keppler_frontend/app/bootstrap/bstp-form.html +0 -33
- data/installer/core/rockets/keppler_frontend/app/assets/html/keppler_frontend/app/bootstrap/bstp-jumbotron.html +0 -25
- data/installer/core/rockets/keppler_frontend/app/assets/html/keppler_frontend/app/bootstrap/bstp-label.html +0 -13
- data/installer/core/rockets/keppler_frontend/app/assets/html/keppler_frontend/app/bootstrap/bstp-list-group.html +0 -22
- data/installer/core/rockets/keppler_frontend/app/assets/html/keppler_frontend/app/bootstrap/bstp-modal.html +0 -32
- data/installer/core/rockets/keppler_frontend/app/assets/html/keppler_frontend/app/bootstrap/bstp-navbar.html +0 -71
- data/installer/core/rockets/keppler_frontend/app/assets/html/keppler_frontend/app/bootstrap/bstp-pagination.html +0 -31
- data/installer/core/rockets/keppler_frontend/app/assets/html/keppler_frontend/app/bootstrap/bstp-panel-table.html +0 -48
- data/installer/core/rockets/keppler_frontend/app/assets/html/keppler_frontend/app/bootstrap/bstp-panel.html +0 -19
- data/installer/core/rockets/keppler_frontend/app/assets/html/keppler_frontend/app/bootstrap/bstp-progress-bar.html +0 -17
- data/installer/core/rockets/keppler_frontend/app/assets/html/keppler_frontend/app/bootstrap/bstp-radio.html +0 -23
- data/installer/core/rockets/keppler_frontend/app/assets/html/keppler_frontend/app/bootstrap/bstp-table.html +0 -42
- data/installer/core/rockets/keppler_frontend/app/assets/html/keppler_frontend/app/bootstrap/bstp-tabs.html +0 -34
- data/installer/core/rockets/keppler_frontend/app/assets/html/keppler_frontend/app/bootstrap/bstp-textarea.html +0 -13
- data/installer/core/rockets/keppler_frontend/app/assets/html/keppler_frontend/app/bootstrap/bstp-thumbnail.html +0 -23
- data/installer/core/rockets/keppler_frontend/app/assets/html/keppler_frontend/app/bootstrap/bstp-well.html +0 -13
- data/installer/core/rockets/keppler_frontend/app/assets/html/keppler_frontend/app/bootstrap/btsp-input.html +0 -13
- data/installer/core/rockets/keppler_frontend/app/assets/html/keppler_frontend/app/keppler/kppl-banner-blur-parallax.html +0 -59
- data/installer/core/rockets/keppler_frontend/app/assets/html/keppler_frontend/app/keppler/kppl-banner-blur.html +0 -58
- data/installer/core/rockets/keppler_frontend/app/assets/html/keppler_frontend/app/keppler/kppl-banner-parallax.html +0 -49
- data/installer/core/rockets/keppler_frontend/app/assets/html/keppler_frontend/app/keppler/kppl-banner-static.html +0 -48
- data/installer/core/rockets/keppler_frontend/app/assets/html/keppler_frontend/app/keppler/kppl-banner-video.html +0 -54
- data/installer/core/rockets/keppler_frontend/app/assets/html/keppler_frontend/app/keppler/kppl-block.html +0 -15
- data/installer/core/rockets/keppler_frontend/app/assets/html/keppler_frontend/app/keppler/kppl-h1.html +0 -13
- data/installer/core/rockets/keppler_frontend/app/assets/html/keppler_frontend/app/keppler/kppl-h2.html +0 -13
- data/installer/core/rockets/keppler_frontend/app/assets/html/keppler_frontend/app/keppler/kppl-h3.html +0 -13
- data/installer/core/rockets/keppler_frontend/app/assets/html/keppler_frontend/app/keppler/kppl-h4.html +0 -13
- data/installer/core/rockets/keppler_frontend/app/assets/html/keppler_frontend/app/keppler/kppl-small.html +0 -13
- data/installer/core/rockets/keppler_frontend/app/assets/html/keppler_frontend/app/slick/slick-basic.html +0 -43
- data/installer/core/rockets/keppler_ga_dashboard/app/controllers/keppler_ga_dashboard/dashboard_controller.rb +0 -64
- data/installer/core/rockets/keppler_ga_dashboard/app/helpers/keppler_ga_dashboard/dashboard_helper.rb +0 -14
- data/installer/core/spec/factories/customize.rb +0 -6
- data/installer/core/spec/models/customize_spec.rb +0 -23
data/installer/core/rockets/keppler_frontend/app/controllers/keppler_frontend/concerns/services.rb
CHANGED
File without changes
|
data/installer/core/rockets/keppler_frontend/app/helpers/keppler_frontend/app/frontend_helper.rb
CHANGED
@@ -2,7 +2,7 @@ module KepplerFrontend
|
|
2
2
|
module App::FrontendHelper
|
3
3
|
# begin devise_login
|
4
4
|
def devise_login(hash = {})
|
5
|
-
render 'keppler_frontend/app/partials/devise_login',
|
5
|
+
render 'keppler_frontend/app/partials/devise_login', params: params
|
6
6
|
end
|
7
7
|
# end devise_login
|
8
8
|
end
|
@@ -15,8 +15,8 @@ module KepplerFrontend
|
|
15
15
|
head_idx = index_html.find_index(i) if i.include?(" module App::FrontendHelper")
|
16
16
|
end
|
17
17
|
index_html.insert(head_idx.to_i + 1, " # begin #{name}\n")
|
18
|
-
index_html.insert(head_idx.to_i + 2, " def #{name}(
|
19
|
-
index_html.insert(head_idx.to_i + 3, " render 'keppler_frontend/app/partials/#{name}',
|
18
|
+
index_html.insert(head_idx.to_i + 2, " def #{name}(params = {})\n")
|
19
|
+
index_html.insert(head_idx.to_i + 3, " render 'keppler_frontend/app/partials/#{name}', params: params\n")
|
20
20
|
index_html.insert(head_idx.to_i + 4, " end\n")
|
21
21
|
index_html.insert(head_idx.to_i + 5, " # end #{name}\n")
|
22
22
|
index_html = index_html.join('')
|
@@ -51,8 +51,8 @@ module KepplerFrontend
|
|
51
51
|
end
|
52
52
|
return if begin_idx==0
|
53
53
|
index_html[begin_idx] = " # begin #{helper[:name]}\n"
|
54
|
-
index_html[begin_idx+1] = " def #{helper[:name]}(
|
55
|
-
index_html[begin_idx+2] = " render 'keppler_frontend/app/partials/#{helper[:name]}',
|
54
|
+
index_html[begin_idx+1] = " def #{helper[:name]}(params = {})\n"
|
55
|
+
index_html[begin_idx+2] = " render 'keppler_frontend/app/partials/#{helper[:name]}', params: params\n"
|
56
56
|
index_html[begin_idx+4] = " # end #{helper[:name]}\n"
|
57
57
|
index_html = index_html.join('')
|
58
58
|
File.write(file, index_html)
|
@@ -7,19 +7,16 @@ module KepplerFrontend
|
|
7
7
|
module HtmlFile
|
8
8
|
extend ActiveSupport::Concern
|
9
9
|
def html_code
|
10
|
-
# html = File.readlines("#{url_front}/app/views/keppler_frontend/app/partials/#{underscore_name}.html.erb")
|
11
|
-
# html.join
|
12
|
-
|
13
10
|
file = "#{url_front}/app/views/keppler_frontend/app/partials/#{underscore_name}.html.erb"
|
14
11
|
index_html = File.readlines(file)
|
15
12
|
begin_idx = 0
|
16
13
|
end_idx = 0
|
17
14
|
index_html.each do |idx|
|
18
|
-
begin_idx = index_html.find_index(idx) if idx.include?("
|
19
|
-
end_idx = index_html.find_index(idx) if idx.include?("
|
15
|
+
begin_idx = index_html.find_index(idx) if idx.include?("<keppler-partial id='#{name}'>\n")
|
16
|
+
end_idx = index_html.find_index(idx) if idx.include?("</keppler-partial>\n")
|
20
17
|
end
|
21
18
|
# return if begin_idx==0
|
22
|
-
index_html = index_html[begin_idx+
|
19
|
+
index_html = index_html[begin_idx+1..end_idx-1]
|
23
20
|
index_html = index_html.map { |line| line[0, line.length] }
|
24
21
|
index_html.join('')
|
25
22
|
end
|
@@ -28,11 +25,9 @@ module KepplerFrontend
|
|
28
25
|
file = File.open("#{url_front}/app/views/keppler_frontend/app/partials/#{underscore_name}.html.erb", "w")
|
29
26
|
index_html = File.readlines(file)
|
30
27
|
head_idx = 0
|
31
|
-
index_html.insert(head_idx.to_i + 1, "
|
32
|
-
index_html.insert(head_idx.to_i + 2, "<
|
33
|
-
index_html.insert(head_idx.to_i + 3, "
|
34
|
-
index_html.insert(head_idx.to_i + 4, "\n</div>\n")
|
35
|
-
index_html.insert(head_idx.to_i + 5, "<!-- end #{name} -->\n")
|
28
|
+
index_html.insert(head_idx.to_i + 1, "<keppler-partial id='#{name}'>\n")
|
29
|
+
index_html.insert(head_idx.to_i + 2, " <h1> #{name} partial </h1>")
|
30
|
+
index_html.insert(head_idx.to_i + 3, "\n</keppler-partial>\n")
|
36
31
|
index_html = index_html.join('')
|
37
32
|
File.write(file, index_html)
|
38
33
|
file.close
|
@@ -52,13 +47,12 @@ module KepplerFrontend
|
|
52
47
|
end_idx = 0
|
53
48
|
default_idx = 0
|
54
49
|
index_html.each do |idx|
|
55
|
-
begin_idx = index_html.find_index(idx) if idx.include?("
|
56
|
-
end_idx = index_html.find_index(idx) if idx.include?("
|
50
|
+
begin_idx = index_html.find_index(idx) if idx.include?("<keppler-partial id='#{name}'>\n")
|
51
|
+
end_idx = index_html.find_index(idx) if idx.include?("</keppler-partial>\n")
|
57
52
|
default_idx = index_html.find_index(idx) if idx.include?(" <h1> #{name} partial </h1>")
|
58
53
|
end
|
59
|
-
index_html[begin_idx] = "
|
60
|
-
index_html[
|
61
|
-
index_html[end_idx] = "<!-- end #{html[:name]} -->\n"
|
54
|
+
index_html[begin_idx] = "<keppler-partial id='#{html[:name]}'>\n"
|
55
|
+
index_html[end_idx] = "</keppler-partial>"
|
62
56
|
index_html[default_idx] = " <h1> #{html[:name]} partial </h1>\n" unless default_idx.eql?(0)
|
63
57
|
index_html = index_html.join('')
|
64
58
|
File.write(file, index_html)
|
@@ -77,13 +71,13 @@ module KepplerFrontend
|
|
77
71
|
begin_idx = 0
|
78
72
|
end_idx = 0
|
79
73
|
code_html.each do |i|
|
80
|
-
begin_idx = code_html.find_index(i) if i.include?("
|
81
|
-
end_idx = code_html.find_index(i) if i.include?("
|
74
|
+
begin_idx = code_html.find_index(i) if i.include?("<keppler-partial id='#{name}'>\n")
|
75
|
+
end_idx = code_html.find_index(i) if i.include?("</keppler-partial>\n")
|
82
76
|
end
|
83
77
|
# return if begin_idx==0
|
84
|
-
code_html.slice!(begin_idx+
|
78
|
+
code_html.slice!(begin_idx+1..end_idx-1)
|
85
79
|
code.split("\n").each_with_index do |line, i|
|
86
|
-
code_html.insert(begin_idx+(i+
|
80
|
+
code_html.insert(begin_idx+(i+1), "#{line}\n")
|
87
81
|
end
|
88
82
|
code_html = code_html.join('')
|
89
83
|
File.write(file, code_html)
|
@@ -78,7 +78,7 @@ module KepplerFrontend
|
|
78
78
|
# return if begin_idx==0
|
79
79
|
code_css.slice!(begin_idx+2..end_idx-2)
|
80
80
|
code.split("\n").each_with_index do |line, i|
|
81
|
-
code_css.insert(begin_idx+(i+2), "
|
81
|
+
code_css.insert(begin_idx+(i+2), "#{line}\n")
|
82
82
|
end
|
83
83
|
code_css = code_css.join('')
|
84
84
|
File.write(file, code_css)
|
data/installer/core/rockets/keppler_frontend/app/services/keppler_frontend/editor/file_format.rb
CHANGED
File without changes
|
data/installer/core/rockets/keppler_frontend/app/services/keppler_frontend/editor/resources.rb
CHANGED
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
data/installer/core/rockets/keppler_frontend/app/services/keppler_frontend/utils/code_search.rb
CHANGED
File without changes
|
data/installer/core/rockets/keppler_frontend/app/services/keppler_frontend/utils/file_format.rb
CHANGED
File without changes
|
data/installer/core/rockets/keppler_frontend/app/services/keppler_frontend/utils/yml_handler.rb
CHANGED
File without changes
|
data/installer/core/rockets/keppler_frontend/app/services/keppler_frontend/views/actions_handler.rb
CHANGED
File without changes
|
data/installer/core/rockets/keppler_frontend/app/services/keppler_frontend/views/css_handler.rb
CHANGED
File without changes
|
data/installer/core/rockets/keppler_frontend/app/services/keppler_frontend/views/html_handler.rb
CHANGED
File without changes
|
File without changes
|
data/installer/core/rockets/keppler_frontend/app/services/keppler_frontend/views/js_handler.rb
CHANGED
File without changes
|
File without changes
|
data/installer/core/rockets/keppler_frontend/app/services/keppler_frontend/views/routes_handler.rb
CHANGED
File without changes
|
data/installer/core/rockets/keppler_frontend/app/services/keppler_frontend/views/uninstall.rb
CHANGED
File without changes
|
@@ -101,30 +101,32 @@
|
|
101
101
|
%i.fa.fa-save
|
102
102
|
.control-sidebar-bg
|
103
103
|
:javascript
|
104
|
-
$(
|
105
|
-
|
106
|
-
|
104
|
+
$(document).on('turbolinks:load', function() {
|
105
|
+
$('a[data-toggle="tab"]').on('shown.bs.tab', function (ev) {
|
106
|
+
var tab = ev.target.innerText;
|
107
|
+
var id = `#{@view.id}`;
|
107
108
|
|
108
|
-
|
109
|
-
|
110
|
-
}
|
111
|
-
|
112
|
-
$(document).bind('keydown', function(e) {
|
113
|
-
if(e.ctrlKey && (e.which == 83)) {
|
114
|
-
e.preventDefault();
|
115
|
-
save()
|
109
|
+
if (tab === '') {
|
110
|
+
tab = `#{@view.name}.html.erb`
|
116
111
|
}
|
117
|
-
});
|
118
112
|
|
119
|
-
|
120
|
-
|
121
|
-
|
122
|
-
|
123
|
-
|
124
|
-
}
|
125
|
-
|
126
|
-
|
127
|
-
|
113
|
+
$(document).bind('keydown', function(e) {
|
114
|
+
if(e.ctrlKey && (e.which == 83)) {
|
115
|
+
e.preventDefault();
|
116
|
+
save()
|
117
|
+
}
|
118
|
+
});
|
119
|
+
|
120
|
+
function save() {
|
121
|
+
if ( tab === `#{@view.name}.html.erb` ) {
|
122
|
+
codeHTML.save(id);
|
123
|
+
} else if (tab === `#{@view.name}.scss` ) {
|
124
|
+
codeCSS.save(id);
|
125
|
+
} else if (tab === `#{@view.name}.js` ) {
|
126
|
+
codeJs.save(id);
|
127
|
+
} else if (tab === 'Action') {
|
128
|
+
codeAction.save(id);
|
129
|
+
}
|
128
130
|
}
|
129
|
-
}
|
130
|
-
})
|
131
|
+
})
|
132
|
+
});
|
@@ -31,30 +31,32 @@
|
|
31
31
|
.control-sidebar-bg
|
32
32
|
|
33
33
|
:javascript
|
34
|
-
$(
|
35
|
-
|
36
|
-
|
34
|
+
$(document).on('turbolinks:load', function() {
|
35
|
+
$('a[data-toggle="tab"]').on('shown.bs.tab', function (ev) {
|
36
|
+
var tab = ev.target.innerText;
|
37
|
+
var id = `#{@view.id}`;
|
37
38
|
|
38
|
-
|
39
|
-
|
40
|
-
}
|
41
|
-
|
42
|
-
$(document).bind('keydown', function(e) {
|
43
|
-
if(e.ctrlKey && (e.which == 83)) {
|
44
|
-
e.preventDefault();
|
45
|
-
save()
|
39
|
+
if (tab === '') {
|
40
|
+
tab = `#{@view.name}.html.erb`
|
46
41
|
}
|
47
|
-
});
|
48
42
|
|
49
|
-
|
50
|
-
|
51
|
-
|
52
|
-
|
53
|
-
|
54
|
-
}
|
55
|
-
|
56
|
-
|
57
|
-
|
43
|
+
$(document).bind('keydown', function(e) {
|
44
|
+
if(e.ctrlKey && (e.which == 83)) {
|
45
|
+
e.preventDefault();
|
46
|
+
save()
|
47
|
+
}
|
48
|
+
});
|
49
|
+
|
50
|
+
function save() {
|
51
|
+
if ( tab === `#{@view.name}.html.erb` ) {
|
52
|
+
codeHTML.save(id);
|
53
|
+
} else if (tab === `#{@view.name}.scss` ) {
|
54
|
+
codeCSS.save(id);
|
55
|
+
} else if (tab === `#{@view.name}.js` ) {
|
56
|
+
codeJs.save(id);
|
57
|
+
} else if (tab === 'Action') {
|
58
|
+
codeAction.save(id);
|
59
|
+
}
|
58
60
|
}
|
59
|
-
}
|
60
|
-
}
|
61
|
+
})
|
62
|
+
}
|
@@ -65,7 +65,7 @@
|
|
65
65
|
.row
|
66
66
|
.col-lg-6
|
67
67
|
%h4.box-title
|
68
|
-
= truncate(partial.name, length:
|
68
|
+
= truncate(partial.name, length: 15, omission: '...')
|
69
69
|
.col-lg-3
|
70
70
|
%span.box-title
|
71
71
|
%a.btn.btn-default.pull-right{onclick: "copyPartial('#{partial.id}')"}
|
@@ -78,24 +78,26 @@
|
|
78
78
|
.control-sidebar-bg
|
79
79
|
|
80
80
|
:javascript
|
81
|
-
$(
|
82
|
-
$(
|
83
|
-
|
84
|
-
e.
|
85
|
-
|
86
|
-
|
87
|
-
|
81
|
+
$(document).on('turbolinks:load', function() {
|
82
|
+
$('a[data-toggle="tab"]').on('shown.bs.tab', function (ev) {
|
83
|
+
$(document).bind('keydown',function(e) {
|
84
|
+
if(e.ctrlKey && (e.which == 83)) {
|
85
|
+
e.preventDefault();
|
86
|
+
var tab = e.target.innerText;
|
87
|
+
if (tab==='') {
|
88
|
+
var tab = `#{@view.name}.html.erb`;
|
89
|
+
}
|
90
|
+
var id = `#{@view.id}`
|
91
|
+
if ( tab === `#{@view.name}.html.erb`) {
|
92
|
+
codeHTML.save(id);
|
93
|
+
} else if (tab === `#{@view.name}.scss`) {
|
94
|
+
codeCSS.save(id);
|
95
|
+
} else if (tab === `#{@view.name}.js`) {
|
96
|
+
codeJs.save(id);
|
97
|
+
} else if (tab === 'Action') {
|
98
|
+
codeAction.save(id);
|
99
|
+
}
|
88
100
|
}
|
89
|
-
|
90
|
-
|
91
|
-
|
92
|
-
} else if (tab === `#{@view.name}.scss`) {
|
93
|
-
codeCSS.save(id);
|
94
|
-
} else if (tab === `#{@view.name}.js`) {
|
95
|
-
codeJs.save(id);
|
96
|
-
} else if (tab === 'Action') {
|
97
|
-
codeAction.save(id);
|
98
|
-
}
|
99
|
-
}
|
100
|
-
});
|
101
|
-
})
|
101
|
+
});
|
102
|
+
})
|
103
|
+
}
|
data/installer/core/rockets/keppler_frontend/app/views/keppler_frontend/admin/views/index.html.haml
CHANGED
@@ -68,14 +68,15 @@
|
|
68
68
|
= render "description"
|
69
69
|
|
70
70
|
:javascript
|
71
|
-
|
72
|
-
$(
|
73
|
-
$('#
|
74
|
-
|
75
|
-
$('
|
76
|
-
|
77
|
-
|
78
|
-
|
71
|
+
(function() {
|
72
|
+
$(document).on('turbolinks:load', function() {});
|
73
|
+
$('#view').click(function() {
|
74
|
+
$('#upload_file_view').click()
|
75
|
+
$('#upload_file_view').change(function() {
|
76
|
+
$('.waiting').css('display', 'block')
|
77
|
+
$('#upload_form_view').submit()
|
78
|
+
})
|
79
|
+
});
|
79
80
|
|
80
|
-
|
81
|
-
|
81
|
+
renderImg();
|
82
|
+
}).call(this);
|
@@ -1,42 +1,42 @@
|
|
1
1
|
<!-- begin devise_login -->
|
2
|
-
<
|
3
|
-
|
4
|
-
|
5
|
-
|
6
|
-
|
7
|
-
|
8
|
-
|
9
|
-
|
10
|
-
</div>
|
2
|
+
<keppler-partial id='devise_login'>
|
3
|
+
<%- unless current_user %>
|
4
|
+
<%= form_for(User.new, :as => User.new, :url => session_path(User.new), :html => { :role => 'form'}) do |f| %>
|
5
|
+
<%= f.text_field :path, type: :hidden, class: "form-control validate", :value => "#{controller_path}##{action_name}" %>
|
6
|
+
<div class="form-group">
|
7
|
+
<label for="inputEmail3" class="col-sm-2 control-label">Email</label>
|
8
|
+
<div class="col-sm-10">
|
9
|
+
<%= f.email_field :email, :autofocus => true, class: "form-control validate", :placeholder => "Email" %>
|
11
10
|
</div>
|
12
|
-
|
13
|
-
|
14
|
-
|
15
|
-
|
16
|
-
|
11
|
+
</div>
|
12
|
+
<div class="form-group">
|
13
|
+
<label for="inputPassword3" class="col-sm-2 control-label">Password</label>
|
14
|
+
<div class="col-sm-10">
|
15
|
+
<%= f.password_field :password, :autofocus => true, class: "form-control validate #{'invalid' if flash[:alert]}", :placeholder => "Password" %>
|
17
16
|
</div>
|
18
|
-
|
19
|
-
|
20
|
-
|
21
|
-
|
22
|
-
|
23
|
-
|
17
|
+
</div>
|
18
|
+
<div class="form-group has-feedback">
|
19
|
+
<div class="devise-errors center-align">
|
20
|
+
<%- flash.each do |name, msg| %>
|
21
|
+
<%= content_tag :div, msg, :id => "flash_#{name}" if msg.is_a?(String) %>
|
22
|
+
<% end %>
|
24
23
|
</div>
|
25
|
-
|
26
|
-
|
27
|
-
|
28
|
-
|
29
|
-
|
30
|
-
|
31
|
-
</
|
24
|
+
</div>
|
25
|
+
<div class="form-group">
|
26
|
+
<div class="col-sm-offset-2 col-sm-10">
|
27
|
+
<div class="checkbox">
|
28
|
+
<label>
|
29
|
+
<input type="checkbox"> Remember me
|
30
|
+
</label>
|
32
31
|
</div>
|
33
32
|
</div>
|
34
|
-
|
35
|
-
|
36
|
-
|
37
|
-
|
33
|
+
</div>
|
34
|
+
<div class="form-group">
|
35
|
+
<div class="col-sm-offset-2 col-sm-10">
|
36
|
+
<%= f.submit t("devise.sessions.log_in"), class: 'btn btn-primary' %>
|
38
37
|
</div>
|
39
|
-
|
40
|
-
|
41
|
-
|
38
|
+
</div>
|
39
|
+
<% end %>
|
40
|
+
<%- end %>
|
41
|
+
</keppler-partial>
|
42
42
|
<!-- end devise_login -->
|