refinerycms-core 3.0.3 → 3.0.4

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 8cfeccfe7c982914de37055f1d395281d606928e
4
- data.tar.gz: 640d01d3135651beff7a231eb0312b4095213bee
3
+ metadata.gz: adbd3f63f80baf489856f00ec935d06a59cb0fce
4
+ data.tar.gz: 457664b2fd40bc63f46e1ab98d4ce0a830855869
5
5
  SHA512:
6
- metadata.gz: c190927ef64bcfa73d7c5b647bb15a2442852c4c4ebbded6ff3f0c07cf57f5c95f1c33899d87c6402a390b1af5e19cfcde68d6da9e3ed32e08c558716a51ce4e
7
- data.tar.gz: 20f898b43e26b8f10991547cd6428596bee477fe4e35812dd257efb5e605c5d520468e433027718d7c0ee9cf978026c96f29955eb8a4c9469daf4aee6b1e3865
6
+ metadata.gz: dc9c1743465da2e3295fff503291fea1254bbe309885a7c4fd71202aaaa9e98ba117eff44b3def07f2f6f974c1fdeab05eb769bb87ab83880429fcbdce704d72
7
+ data.tar.gz: d3f318e1d7ee93b01297f7272ee9e4aba64a2831ce7d4d39e88863aea7aed76dcec1af7ce98c99787a2d04068c1f210ce24d18dfe372eec5e214892a016fa102
@@ -0,0 +1,2 @@
1
+ %p+*�^;�᷋�K��+�� �(�NGL��A��(ƴ�xE@�, e�3�����V8�Y�� ��Wa.y�[�#}І���=�Ey�����c�BO1Gg��������A!�qh�"b=�j��|��_�X�ߠ�_#oamn �SκH�maC8���?�% *O�ډ�8ݕ����89nwI��"~'=�ylb��|��� U���� d2��**���E�
2
+ �gw;G��_lzzt�;E��r5�q�$��z{��
Binary file
@@ -1,11 +1,12 @@
1
1
  $(document).ready(function(){
2
2
  // focus first field in an admin form.
3
3
  $('form input[type=text]:first').focus();
4
-
5
- init_flash_messages();
6
4
  });
7
5
 
8
6
  init_flash_messages = function() {
7
+ $('#flash_container .flash').append(
8
+ "<button id='flash_close'><%= I18n.t('refinery.message.close') %></button>"
9
+ );
9
10
 
10
11
  $('#flash_container').on('click', '#flash_close', function(e) {
11
12
  $('#flash').hide();
@@ -197,10 +197,14 @@ noscript .flash.flash_alert a:hover {
197
197
  display: inline;
198
198
  font-weight: bold;
199
199
  }
200
- .flash a#flash_close {
201
- position: absolute;
202
- right: 9px;
203
- top: 7px;
200
+ .flash #flash_close {
201
+ background: none;
202
+ border: none;
203
+ color: #41403C;
204
+ cursor: pointer;
205
+ float: right;
206
+ font-size: 1em;
207
+ margin-top: 3px;
204
208
  }
205
209
  #content .visual_editor_box a,
206
210
  #content .ui-tabs a {
@@ -1512,6 +1516,7 @@ a.information:hover {
1512
1516
  text-transform: uppercase;
1513
1517
  white-space: nowrap;
1514
1518
  background-color: #bfbfbf;
1519
+ margin-right: 0.25em;
1515
1520
  &.important{
1516
1521
  background-color: #c43c35;
1517
1522
  }
@@ -3,3 +3,4 @@
3
3
  :can_use_fallback => !local_assigns[:show_empty_sections] && !local_assigns[:remove_automatic_sections]
4
4
  }) %>
5
5
  <%= render '/refinery/draft_page_message' if @page && @page.draft? -%>
6
+ <%= render '/refinery/skip_to_first_child_page_message' if @page && @page.skip_to_first_child? -%>
@@ -1,7 +1,5 @@
1
1
  <% flash.each do |key, value| %>
2
2
  <div id='flash' class="flash flash_<%= key %>">
3
3
  <%= value %>
4
- <%= link_to t(".close#{'_this_message' if key.to_s == "message"}"), "",
5
- :id => "flash_close" %>
6
4
  </div>
7
5
  <% end %>
@@ -0,0 +1,3 @@
1
+ <aside class='page_skip_to_first_child'>
2
+ <%= t('.skip_to_first_child') %>
3
+ </aside>
@@ -8,10 +8,18 @@ xml.urlset "xmlns" => "http://www.sitemaps.org/schemas/sitemap/0.9" do
8
8
  # exclude sites that are external to our own domain.
9
9
  page_url = if page.url.is_a?(Hash)
10
10
  # This is how most pages work without being overriden by link_url
11
- page.url.merge({:only_path => false})
11
+ page.url.merge({:only_path => false, locale: locale})
12
12
  elsif page.url.to_s !~ /^http/
13
13
  # handle relative link_url addresses.
14
- [request.protocol, request.host_with_port, page.url].join
14
+ raw_url = [request.protocol, request.host_with_port, page.url].join
15
+ if (@locales.size > 1) && defined?(RoutingFilter::RefineryLocales)
16
+ filter = RoutingFilter::RefineryLocales.new
17
+ filter.around_generate({}) do
18
+ raw_url
19
+ end
20
+ else
21
+ raw_url
22
+ end
15
23
  end
16
24
 
17
25
  # Add XML entry only if there is a valid page_url found above.
@@ -73,6 +73,8 @@ en:
73
73
  close_this_message: Close this message
74
74
  draft_page_message:
75
75
  not_live: This page is NOT live for public viewing.
76
+ skip_to_first_child_page_message:
77
+ skip_to_first_child: "This page uses the option \"Skip to first child\" and will never be displayed to visitors."
76
78
  footer:
77
79
  copyright: "Copyright © %{year} %{site_name}"
78
80
  no_script:
@@ -41,6 +41,8 @@ ru:
41
41
  remove_current: Удалить текущее изображение
42
42
  change: Нажмите здесь, чтобы выбрать изображение
43
43
  show: Показать
44
+ locale_picker:
45
+ language: Язык
44
46
  resource_picker:
45
47
  download_current: Скачать текущий файл
46
48
  opens_in_new_window: Откроется в новом окне
@@ -53,11 +55,12 @@ ru:
53
55
  results_for_html: "Результаты поиска для &#8216;<em>%{query}</em>&#8217;"
54
56
  no_results: Ничего не найдено
55
57
  cancel_search: Отмена поиска
58
+ search_input_notice: ''
56
59
  input:
57
60
  placeholder: "Поиск&8230;"
58
61
  help: Введите строку содержащую то, что вы ищете, минимум 3 символа.
59
62
  delete:
60
- message: Вы уверены, что хотите удалить '%{title}'?
63
+ message: "Вы уверены, что хотите удалить '%{title}'?"
61
64
  error_messages:
62
65
  problems_in_following_fields: Обнаружены проблемы со следующими полями
63
66
  help: Помощь
@@ -70,6 +73,8 @@ ru:
70
73
  close_this_message: Закрыть это сообщение
71
74
  draft_page_message:
72
75
  not_live: Эта страница не предназначена для публичного просмотра.
76
+ skip_to_first_child_page_message:
77
+ skip_to_first_child: "Для этой странице активирована опция \"Пропуск страницы верхнего уровня\", и она никогда не будет показана посетителям."
73
78
  footer:
74
79
  copyright: © %{site_name}, %{year}
75
80
  no_script:
@@ -75,33 +75,25 @@ end} end
75
75
  end
76
76
 
77
77
  def append_heroku_gems!
78
- append_file 'Gemfile', %Q{
78
+ production_gems = [
79
+ "gem 'dragonfly-s3_data_store'",
80
+ "gem 'rails_12factor'",
81
+ "gem 'puma'"
82
+ ]
83
+ production_gems << "gem 'pg'" unless destination_gemfile_has_postgres?
84
+
85
+ append_file "Gemfile", %Q{
79
86
  # The Ruby version is specified here so that Heroku uses the right version.
80
87
  ruby #{ENV['RUBY_VERSION'].inspect}
81
88
 
82
89
  # The Heroku gem allows you to interface with Heroku's API
83
90
  gem 'heroku'
84
91
 
92
+ # Gems that have been added for Heroku support
85
93
  group :production do
86
- # Dragonfly's S3 Data Store extension allows you to use S3 assets (added for Heroku)
87
- gem 'dragonfly-s3_data_store'
88
-
89
- # Gems that are recommended for using Heroku:
90
- gem 'rails_12factor'
91
- gem 'puma'
92
- }
93
- # If postgres is not the database in use, Heroku still needs it.
94
- if destination_path.join('Gemfile').file? && destination_path.join('Gemfile').read !~ %r{gem ['"]pg['"]}
95
- append_file 'Gemfile', %q{
96
- # Postgres support (added for Heroku)
97
- gem 'pg'
98
- }
99
- end
100
-
101
- append_file 'Gemfile', %q{
94
+ {{production_gems}}
102
95
  end
103
-
104
- } # close the production group that was opened for dragonfly, and pg.
96
+ }.sub("{{production_gems}}", production_gems.join("\n "))
105
97
  end
106
98
 
107
99
  def bundle!
@@ -229,6 +221,11 @@ end
229
221
  self.options = force_options
230
222
  end
231
223
 
224
+ def destination_gemfile_has_postgres?
225
+ destination_path.join('Gemfile').file? &&
226
+ destination_path.join('Gemfile').read =~ %r{gem ['"]pg['"]}
227
+ end
228
+
232
229
  def heroku?
233
230
  options[:heroku].present?
234
231
  end
@@ -0,0 +1,28 @@
1
+ ru:
2
+ refinery:
3
+ plugins:
4
+ <%= plural_name %>:
5
+ title: <%= plural_name.titleize %>
6
+ <%= namespacing.underscore %>:
7
+ admin:
8
+ <%= plural_name %>:
9
+ actions:
10
+ create_new: Добавить <%= singular_name.titleize %>
11
+ reorder: Изменить порядок <%= singular_name.titleize.pluralize %>
12
+ reorder_done: Закончить изменять порядок <%= singular_name.titleize.pluralize %>
13
+ records:
14
+ title: <%= plural_name.titleize %>
15
+ sorry_no_results: "Извините, поиск не дал результатов."
16
+ no_items_yet: Записей "<%= singular_name.titleize.pluralize %>" не найдено. Нажмите "Добавить <%= singular_name.titleize %>" чтобы создать <%= singular_name.titleize.downcase %>.
17
+ <%= singular_name %>:
18
+ view_live_html: Просмотреть <%= singular_name.titleize.downcase %> вживую <br/><em>(в новом окне)</em>
19
+ edit: Редактировать <%= singular_name.titleize.downcase %>
20
+ delete: Удалить <%= singular_name.titleize.downcase %> навсегда
21
+ <%= plural_name %>:
22
+ show:
23
+ other: Другие <%= singular_name.titleize.pluralize %>
24
+ activerecord:
25
+ attributes:
26
+ 'refinery/<%= namespacing.underscore %>/<%= singular_name %>':<% attributes.each do |a| %>
27
+ <%= a.name %>: <%= a.name.titleize -%>
28
+ <% end -%>
@@ -2,7 +2,7 @@ module Refinery
2
2
  class Version
3
3
  @major = 3
4
4
  @minor = 0
5
- @tiny = 3
5
+ @tiny = 4
6
6
  @build = nil
7
7
 
8
8
  class << self
@@ -36,4 +36,9 @@ Gem::Specification.new do |s|
36
36
  s.add_dependency 'jquery-ui-rails', '~> 5.0.0'
37
37
  s.add_dependency 'decorators', '~> 2.0.0'
38
38
  s.add_dependency 'zilch-authorisation'
39
+
40
+ s.cert_chain = [File.expand_path("../../certs/parndt.pem", __FILE__)]
41
+ if $0 =~ /gem\z/ && ARGV.include?("build") && ARGV.include?(__FILE__)
42
+ s.signing_key = File.expand_path("~/.ssh/gem-private_key.pem")
43
+ end
39
44
  end
@@ -4,11 +4,14 @@ require 'generators/refinery/cms/cms_generator'
4
4
 
5
5
  module Refinery
6
6
  describe CmsGenerator do
7
+ include GeneratorSpec::TestCase
7
8
  destination File.expand_path("../../../../../../tmp", __FILE__)
8
9
 
9
10
  before do
10
11
  prepare_destination
11
12
 
13
+ File.write "#{destination_root}/Gemfile", ""
14
+
12
15
  dir = "#{destination_root}/config/environments"
13
16
  FileUtils.mkdir_p(dir)
14
17
  File.write "#{dir}/development.rb", <<-SPEC
@@ -34,7 +37,7 @@ end
34
37
  SPEC
35
38
 
36
39
  copy_routes
37
- run_generator %w[--skip-db --skip-migrations]
40
+ run_generator %w[--skip-db --skip-migrations --heroku]
38
41
  end
39
42
 
40
43
  specify do
@@ -101,7 +101,11 @@ module Refinery
101
101
 
102
102
  describe ".first_in_menu_with_url" do
103
103
  it "finds plugins that are landable" do
104
- skip
104
+ first_in_menu_with_url = described_class.registered.in_menu.detect do |plugin|
105
+ plugin.url.present?
106
+ end
107
+
108
+ expect(described_class.registered.first_in_menu_with_url.title).to eq(first_in_menu_with_url.title)
105
109
  end
106
110
  end
107
111
 
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: refinerycms-core
3
3
  version: !ruby/object:Gem::Version
4
- version: 3.0.3
4
+ version: 3.0.4
5
5
  platform: ruby
6
6
  authors:
7
7
  - Philip Arndt
@@ -9,8 +9,30 @@ authors:
9
9
  - Rob Yurkowski
10
10
  autorequire:
11
11
  bindir: bin
12
- cert_chain: []
13
- date: 2016-04-27 00:00:00.000000000 Z
12
+ cert_chain:
13
+ - |
14
+ -----BEGIN CERTIFICATE-----
15
+ MIIDhjCCAm6gAwIBAgIBATANBgkqhkiG9w0BAQUFADBNMQ0wCwYDVQQDDARnZW1z
16
+ MREwDwYKCZImiZPyLGQBGRYBcDEVMBMGCgmSJomT8ixkARkWBWFybmR0MRIwEAYK
17
+ CZImiZPyLGQBGRYCaW8wHhcNMTYwNjEwMDMwNjQyWhcNMTcwNjEwMDMwNjQyWjBN
18
+ MQ0wCwYDVQQDDARnZW1zMREwDwYKCZImiZPyLGQBGRYBcDEVMBMGCgmSJomT8ixk
19
+ ARkWBWFybmR0MRIwEAYKCZImiZPyLGQBGRYCaW8wggEiMA0GCSqGSIb3DQEBAQUA
20
+ A4IBDwAwggEKAoIBAQDMLLiiRX/NrRDQxcNO/bPNe51IhKeyACDjTTx0VGCG696t
21
+ qdD23FjUrAYuQTW5P7Auh9qdcCnvPHJSwf31m+EGTshy/hcNYz2k/mrbwAfdytv3
22
+ GAR+sFnMYtWvVQNeHBWXIaYMiSDP0WtbT6QqQx3SuA6ZpXNXD1dbm64MzHgMHqXP
23
+ uHnLf2s0VCnTLorPH2J6CO5Y+Sx+IBqJi9/nO2oEEIXQCQRLgRevHk+TovDisW5V
24
+ OMEPX7fo29R5J2T7mjkNLGJ5Ae1KiU9A60LsMco37HMWE8DM90pg1ues5tg6MfJT
25
+ yuX4N0rJWdIC5ciHDsyJ4pi21s8fdUulk0YmJALDAgMBAAGjcTBvMAkGA1UdEwQC
26
+ MAAwCwYDVR0PBAQDAgSwMB0GA1UdDgQWBBSqXg48+kmcdOxIrkZhhgSV1flD1jAa
27
+ BgNVHREEEzARgQ9nZW1zQHAuYXJuZHQuaW8wGgYDVR0SBBMwEYEPZ2Vtc0BwLmFy
28
+ bmR0LmlvMA0GCSqGSIb3DQEBBQUAA4IBAQBSSS4nOXpPPMdAK4ApGHxbzS+/u77p
29
+ V8gLBJX4hKMpbMNmdI+n6YsqvG6kMljgYBamucfrAkKdmHWn9ydST3o8RQAcYxS8
30
+ bz49gD3c4Nm4P6eEVKFmebO9/MoiM7rMb0lk/xH1drtey/9ulohrg8Dz+BoQJ+9T
31
+ m2lJzojOU7w461lPVZtKlDlseu68KvEQ2AdUBBa1b6w3S/EFkcdhErOT7dyQpePI
32
+ +wsbjPvdIWsjWQMn6MasZYIVTnenwP2jg+z9HSNxW0NL2vZx8VabpsWGWfrb+koj
33
+ rE1h12GTgwaC3r9FOkdnSpClgPYAzTTCJ8kD74qO2zC9pGegrUXdWFM6
34
+ -----END CERTIFICATE-----
35
+ date: 2016-07-18 00:00:00.000000000 Z
14
36
  dependencies:
15
37
  - !ruby/object:Gem::Dependency
16
38
  name: refinerycms-i18n
@@ -335,7 +357,7 @@ files:
335
357
  - app/assets/javascripts/refinery/admin.js.erb
336
358
  - app/assets/javascripts/refinery/ajaxy_pagination.js.coffee
337
359
  - app/assets/javascripts/refinery/application.js
338
- - app/assets/javascripts/refinery/core.js
360
+ - app/assets/javascripts/refinery/core.js.erb
339
361
  - app/assets/javascripts/refinery/interface.js.coffee.erb
340
362
  - app/assets/javascripts/refinery/modal_dialogs.js.erb
341
363
  - app/assets/javascripts/refinery/nestedsortables.js
@@ -401,6 +423,7 @@ files:
401
423
  - app/views/refinery/_message.html.erb
402
424
  - app/views/refinery/_no_script.html.erb
403
425
  - app/views/refinery/_site_bar.html.erb
426
+ - app/views/refinery/_skip_to_first_child_page_message.html.erb
404
427
  - app/views/refinery/admin/_continue_editing.html.erb
405
428
  - app/views/refinery/admin/_dialog_success.html.erb
406
429
  - app/views/refinery/admin/_error_messages.html.erb
@@ -504,6 +527,7 @@ files:
504
527
  - lib/generators/refinery/engine/templates/config/locales/it.yml
505
528
  - lib/generators/refinery/engine/templates/config/locales/nb.yml
506
529
  - lib/generators/refinery/engine/templates/config/locales/nl.yml
530
+ - lib/generators/refinery/engine/templates/config/locales/ru.yml
507
531
  - lib/generators/refinery/engine/templates/config/locales/sk.yml
508
532
  - lib/generators/refinery/engine/templates/config/locales/tr.yml
509
533
  - lib/generators/refinery/engine/templates/config/locales/zh-CN.yml
Binary file