spina 2.14.0 → 2.15.1

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
  SHA256:
3
- metadata.gz: 3b491e3dc04219159e135f4d0aae15b40efd0c47b0eb87a1ad930146f4cca059
4
- data.tar.gz: 3e44354ab0e44e3d791aae0385e8e4035a2acf19fb596192ad74a64ac0e7524f
3
+ metadata.gz: 8a4c285b310a44ed59a8188549402477161efe9e559dbbb6e5e52bac3a38ffc3
4
+ data.tar.gz: b7055f33ccf17811f980f0e79843245a3ce7d9a5b11910b6f5ef080ed25adbe1
5
5
  SHA512:
6
- metadata.gz: 972a89b23f86538258639af81adee7b5574f334e7884aa11fa614d33af0199c9ba99928c4bb46bd8fc459dd8edde796d857ba4f06cb49a500d637ae22d2a0ef6
7
- data.tar.gz: 30257c332b4516b81f86995007f8be53aa4389da6c0c67b0bf980f85a0319993f3c63ea40a0230dd3d6633849815c0a46a024c9e3639d46e7a5f4efa04708fb8
6
+ metadata.gz: 715e97080cea0a49d9329eb0c52960e21438f9401548f079d04afb9d1c0d1e601671de1153c3c4d6ae8ab305c5ee726d2881a08cf85fea77fc6b415b36dcdca7
7
+ data.tar.gz: 2623fea9312d74ea949df1588ff4b67bbd9c929af292c7097a1ec0cf09e738b75befb4e633092ca6fd19e248d7fd816e8f903f244fb75b0ea25a501955957f56
@@ -40,7 +40,7 @@
40
40
  <% end %>
41
41
 
42
42
  <% if @page.deletable? %>
43
- <%= button_to t('spina.pages.delete'), helpers.spina.admin_page_path(@page), method: :delete, class: "block w-full text-left px-4 py-2 text-sm leading-5 font-medium text-red-500 cursor-pointer bg-white hover:bg-red-100 hover:bg-opacity-50 hover:text-red-500 focus:outline-none focus:bg-gray-100 focus:text-gray-900", form: {data: {controller: "confirm", confirm_message: t('spina.pages.delete_confirmation', subject: @page.title)}} %>
43
+ <%= button_to t('spina.pages.delete'), helpers.spina.admin_page_path(@page), method: :delete, class: "block w-full text-left px-4 py-2 text-sm leading-5 font-medium text-red-500 cursor-pointer bg-white hover:bg-red-100 hover:bg-opacity-50 hover:text-red-500 focus:outline-none focus:bg-gray-100 focus:text-gray-900", form: {data: {controller: "confirm", confirm_message: t('spina.pages.delete_confirmation', subject: sanitize(@page.title))}} %>
44
44
  <% else %>
45
45
  <span class="block px-4 py-2 text-sm leading-5 text-gray-400"><%=t 'spina.pages.cannot_be_deleted' %></span>
46
46
  <% end %>
@@ -1,12 +1,12 @@
1
1
  <% if view_templates.many? %>
2
2
 
3
3
  <%= render Spina::UserInterface::DropdownComponent.new do |dropdown| %>
4
- <% dropdown.button(classes: "btn btn-primary w-full") do %>
4
+ <% dropdown.with_button(classes: "btn btn-primary w-full") do %>
5
5
  <%= helpers.heroicon("document-plus", style: :solid, class: "w-5 h-5 -ml-1 mr-1") %>
6
6
  <%=t 'spina.pages.new' %>
7
7
  <% end %>
8
8
 
9
- <% dropdown.menu do %>
9
+ <% dropdown.with_menu do %>
10
10
  <% view_templates.each do |template| %>
11
11
  <%= link_to helpers.spina.new_admin_page_path(view_template: template.name, resource_id: @resource&.id), class: "block px-4 py-2 text-sm leading-5 text-gray-700 hover:bg-gray-100 hover:text-gray-900 focus:outline-none focus:bg-gray-100 focus:text-gray-900", data: {turbo_frame: "modal", action: "reveal#hide"} do %>
12
12
  <div class="font-medium text-gray-700">
@@ -1,7 +1,7 @@
1
1
  <%= form_with model: current_spina_account, url: spina.admin_account_path do |f| %>
2
2
 
3
3
  <%= render Spina::UserInterface::HeaderComponent.new do |header| %>
4
- <% header.actions do %>
4
+ <% header.with_actions do %>
5
5
 
6
6
  <%= button_tag type: :submit, class: 'btn btn-primary', data: {controller: "button hotkeys", hotkeys: "command+s, ctrl+s", hotkeys_target: "button", action: "button#loading", loading_message: t("spina.ui.saving")} do %>
7
7
  <%= heroicon('check', style: :mini, class: 'w-5 h-5 -ml-1 mr-1') %>
@@ -1,5 +1,5 @@
1
1
  <%= render Spina::UserInterface::HeaderComponent.new do |header| %>
2
- <% header.actions do %>
2
+ <% header.with_actions do %>
3
3
  <%= form_with model: [:admin, Spina::Attachment.new], url: spina.admin_attachments_path, data: {controller: "form loading-button", loading_message: t('spina.media_library.uploading'), action: "turbo:submit-end->loading-button#doneLoading"} do |f| %>
4
4
 
5
5
  <%= f.file_field :files, multiple: true, id: "new_attachment_file_field", class: 'hidden', data: {action: "loading-button#loading form#requestSubmit"} %>
@@ -10,7 +10,7 @@
10
10
  </button>
11
11
  <% end %>
12
12
  <% end %>
13
- <% header.navigation do %>
13
+ <% header.with_navigation do %>
14
14
  <nav class="-mb-3 mt-4">
15
15
  <ul class="inline-flex w-auto rounded-md bg-white">
16
16
  <%= render Spina::UserInterface::TabLinkComponent.new(spina.admin_images_path) do %>
@@ -42,7 +42,7 @@
42
42
 
43
43
  <% if @attachments.next_page %>
44
44
  <%= turbo_frame_tag "attachments-#{@attachments.next_page}", data: {action: "turbo:frame-load->infinite-scroll#load"} do %>
45
- <%= link_to t('spina.ui.load_more'), path_to_next_page(@attachments), class: 'hidden', data: {infinite_scroll_target: "button"} %>
45
+ <%= link_to t('spina.ui.load_more'), path_to_next_page(@attachments), class: "btn btn-default", data: {infinite_scroll_target: "button"} %>
46
46
  <% end %>
47
47
  <% end %>
48
48
  <% end %>
@@ -27,13 +27,13 @@
27
27
 
28
28
  <% if @media_folders.present? %>
29
29
  <%= render Spina::UserInterface::DropdownComponent.new do |dropdown| %>
30
- <% dropdown.button(classes: 'btn btn-default h-7 px-2 text-xs') do %>
30
+ <% dropdown.with_button(classes: 'btn btn-default h-7 px-2 text-xs') do %>
31
31
  <%= heroicon('folder', style: :mini, class: 'w-4 h-4 mr-1 text-gray-600') %>
32
32
  <%=t 'spina.ui.move_to' %>
33
33
  <%= heroicon('chevron-down', style: :solid, class: 'w-4 h-4') %>
34
34
  <% end %>
35
35
 
36
- <% dropdown.menu do %>
36
+ <% dropdown.with_menu do %>
37
37
  <% if image.media_folder_id.present? %>
38
38
  <%= form_with model: image, url: spina.admin_image_path(image) do |f| %>
39
39
  <%= f.hidden_field :media_folder_id, value: nil %>
@@ -1,5 +1,5 @@
1
1
  <%= render Spina::UserInterface::HeaderComponent.new do |header| %>
2
- <% header.actions do %>
2
+ <% header.with_actions do %>
3
3
  <% if @media_folder.blank? %>
4
4
  <%= link_to spina.new_admin_media_folder_path, class: "btn btn-default", data: {turbo_frame: "modal"} do %>
5
5
  <%= heroicon("folder", style: :solid, class: 'w-4 h-4 mr-1 -ml-1') %>
@@ -24,7 +24,7 @@
24
24
  <% end %>
25
25
  <% end %>
26
26
 
27
- <% header.navigation do %>
27
+ <% header.with_navigation do %>
28
28
  <nav class="-mb-3 mt-4">
29
29
  <ul class="inline-flex w-auto rounded-md bg-white">
30
30
  <%= render Spina::UserInterface::TabLinkComponent.new(spina.admin_images_path, active: true) do %>
@@ -1,5 +1,5 @@
1
1
  <%= render Spina::UserInterface::HeaderComponent.new do |header| %>
2
- <% header.actions do %>
2
+ <% header.with_actions do %>
3
3
  <%= render Spina::UserInterface::TranslationsComponent.new(@account, label: @locale.upcase) %>
4
4
 
5
5
  <% if Spina::Current.theme.layout_parts.any? %>
@@ -1,5 +1,5 @@
1
1
  <%= render Spina::UserInterface::HeaderComponent.new do |header| %>
2
- <% header.navigation do %>
2
+ <% header.with_navigation do %>
3
3
  <nav class="-mb-3 mt-4">
4
4
  <ul class="inline-flex flex-wrap w-auto rounded-md bg-white">
5
5
  <% @navigations.each do |navigation| %>
@@ -1,6 +1,6 @@
1
1
  <div data-controller="tabs" data-tabs-active="cursor-default text-gray-900 bg-spina-dark bg-opacity-10" data-tabs-inactive="cursor-pointer bg-transparent text-gray-400 border-transparent">
2
2
  <%= render Spina::UserInterface::HeaderComponent.new do |header| %>
3
- <% header.after_breadcrumbs do %>
3
+ <% header.with_after_breadcrumbs do %>
4
4
  <% if @page.draft? %>
5
5
  <span class="text-gray-400 ml-2 text-sm">(<%= Spina::Page.human_attribute_name(:draft) %>)</span>
6
6
  <% end %>
@@ -8,10 +8,10 @@
8
8
  <%= heroicon("external-link", style: :mini, class: "w-4 h-4") %>
9
9
  <% end %>
10
10
  <% end %>
11
- <% header.actions do %>
11
+ <% header.with_actions do %>
12
12
  <%= render Spina::Pages::ActionsComponent.new(page: @page, locale: @locale) %>
13
13
  <% end %>
14
- <% header.navigation do %>
14
+ <% header.with_navigation do %>
15
15
  <nav class="-mb-3 mt-4">
16
16
  <ul class="inline-flex w-auto rounded-md bg-white">
17
17
  <% @tabs.each do |tab_name| %>
@@ -1,5 +1,5 @@
1
1
  <%= render Spina::UserInterface::HeaderComponent.new do |header| %>
2
- <% header.actions do %>
2
+ <% header.with_actions do %>
3
3
  <% if @resource %>
4
4
  <%= link_to spina.edit_admin_resource_path(@resource), class: 'btn btn-default' do %>
5
5
  <%= heroicon('cog-8-tooth', style: :solid, class: 'text-gray-300 w-5 h-5 -ml-1 mr-1') %>
@@ -12,7 +12,7 @@
12
12
  </div>
13
13
  <% end %>
14
14
 
15
- <% header.navigation do %>
15
+ <% header.with_navigation do %>
16
16
  <nav class="-mb-1 md:-mb-3 mt-4">
17
17
  <ul class="inline-flex flex-wrap w-auto rounded-md bg-white">
18
18
  <%= render Spina::UserInterface::TabLinkComponent.new(spina.admin_pages_path, active: @resource.nil?) do %>
@@ -1,5 +1,5 @@
1
1
  <%= render Spina::UserInterface::HeaderComponent.new do |header| %>
2
- <% header.actions do %>
2
+ <% header.with_actions do %>
3
3
  <%= render Spina::UserInterface::TranslationsComponent.new(@resource, label: @locale.upcase) %>
4
4
 
5
5
  <%= button_tag type: :submit, form: dom_id(@resource), class: 'btn btn-primary', data: {controller: "button", action: "button#loading", loading_message: t('spina.ui.saving')} do %>
@@ -1,7 +1,7 @@
1
1
  <%= form_with model: @setting, scope: :setting, url: admin_settings_path do |f| %>
2
2
 
3
3
  <%= render Spina::UserInterface::HeaderComponent.new do |header| %>
4
- <% header.actions do %>
4
+ <% header.with_actions do %>
5
5
 
6
6
  <%= button_tag type: :submit, class: 'btn btn-primary', data: {controller: "button", action: "button#loading", loading_message: t('spina.ui.saving')} do %>
7
7
  <%= heroicon('check', style: :solid, class: 'w-5 h-5 mr-1 -ml-2') %>
@@ -3,7 +3,7 @@
3
3
 
4
4
  <ul class="flex md:flex-col">
5
5
  <%= render Spina::MainNavigation::SubNavComponent.new(:content) do |nav| %>
6
- <% nav.icon do %>
6
+ <% nav.with_icon do %>
7
7
  <%= heroicon('document-text', style: :solid, class: 'hidden md:block w-8 h-8 text-white md:mr-3') %>
8
8
  <%= heroicon('menu', style: :solid, class: 'md:hidden w-8 h-8 text-white md:mr-3') %>
9
9
 
@@ -12,7 +12,7 @@
12
12
  </div>
13
13
  <% end %>
14
14
 
15
- <% nav.links do %>
15
+ <% nav.with_links do %>
16
16
 
17
17
  <%= render Spina::MainNavigation::LinkComponent.new t('spina.website.pages'), spina.admin_pages_path, active: controller_name.in?(%w(pages resources)) %>
18
18
 
@@ -29,7 +29,7 @@
29
29
  <%= render Spina::Hooks::HookComponent.new(partial: "primary_navigation") %>
30
30
 
31
31
  <%= render Spina::MainNavigation::SubNavComponent.new(:settings) do |nav| %>
32
- <% nav.icon do %>
32
+ <% nav.with_icon do %>
33
33
  <%= heroicon('cog-8-tooth', style: :solid, class: 'w-8 h-8 text-white md:mr-3') %>
34
34
 
35
35
  <div class="text-white font-semibold hidden md:block transform -translate-x-2 ease-in-out duration-300 absolute md:relative opacity-0 transition-all" data-navigation-target="label">
@@ -37,7 +37,7 @@
37
37
  </div>
38
38
  <% end %>
39
39
 
40
- <% nav.links do %>
40
+ <% nav.with_links do %>
41
41
  <%= render Spina::MainNavigation::LinkComponent.new(t('spina.settings.general'), spina.edit_admin_account_path, active: controller_name == "accounts") %>
42
42
  <%= render Spina::MainNavigation::LinkComponent.new(t('spina.website.theme'), spina.edit_admin_theme_path, active: controller_name == "theme") %>
43
43
 
@@ -1,7 +1,7 @@
1
1
  <%= form_with model: Spina::Current.account, url: spina.admin_theme_path do |f| %>
2
2
 
3
3
  <%= render Spina::UserInterface::HeaderComponent.new do |header| %>
4
- <% header.actions do %>
4
+ <% header.with_actions do %>
5
5
 
6
6
  <%= button_tag type: :submit, class: 'btn btn-primary', data: {controller: "button hotkeys", hotkeys: "command+s, ctrl+s", hotkeys_target: "button", action: "button#loading", loading_message: t("spina.ui.saving")} do %>
7
7
  <%= heroicon('check', style: :mini, class: 'w-5 h-5 -ml-1 mr-1') %>
@@ -1,5 +1,5 @@
1
1
  <%= render Spina::UserInterface::HeaderComponent.new do |header| %>
2
- <% header.actions do %>
2
+ <% header.with_actions do %>
3
3
  <%= button_tag type: :submit, form: dom_id(@user), class: 'btn btn-primary', data: {controller: "button hotkeys", hotkeys: "command+s, ctrl+s", hotkeys_target: "button", action: "button#loading", loading_message: t('spina.ui.saving')} do %>
4
4
  <%= heroicon('check', style: :mini, class: 'w-5 h-5 -ml-1 mr-1') %>
5
5
  <%=t 'spina.users.save' %>
@@ -1,5 +1,5 @@
1
1
  <%= render Spina::UserInterface::HeaderComponent.new do |header| %>
2
- <% header.after_breadcrumbs do %>
2
+ <% header.with_after_breadcrumbs do %>
3
3
  <% if current_spina_user.admin? %>
4
4
  <%= link_to spina.new_admin_user_path, class: 'btn btn-default h-8 px-2 ml-3' do %>
5
5
  <%= heroicon('plus', style: :mini, class: 'w-4 h-4') %>
@@ -283,6 +283,7 @@ de:
283
283
  save_draft: Entwurf speichern
284
284
  saved: Seite gespeichert
285
285
  saving: wird gespeichert...
286
+ select_page: Seite wählen
286
287
  couldnt_be_saved: Seite konnte nicht gespeichert werden
287
288
  search_engines: Suchmaschinen
288
289
  show_in_menu: unsichtbar
data/lib/spina/version.rb CHANGED
@@ -1,3 +1,3 @@
1
1
  module Spina
2
- VERSION = "2.14.0"
2
+ VERSION = "2.15.1"
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: spina
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.14.0
4
+ version: 2.15.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Bram Jetten
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2023-02-22 00:00:00.000000000 Z
11
+ date: 2023-06-28 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rails
@@ -168,16 +168,22 @@ dependencies:
168
168
  name: view_component
169
169
  requirement: !ruby/object:Gem::Requirement
170
170
  requirements:
171
- - - "~>"
171
+ - - ">="
172
172
  - !ruby/object:Gem::Version
173
173
  version: '2.32'
174
+ - - "<"
175
+ - !ruby/object:Gem::Version
176
+ version: '4.0'
174
177
  type: :runtime
175
178
  prerelease: false
176
179
  version_requirements: !ruby/object:Gem::Requirement
177
180
  requirements:
178
- - - "~>"
181
+ - - ">="
179
182
  - !ruby/object:Gem::Version
180
183
  version: '2.32'
184
+ - - "<"
185
+ - !ruby/object:Gem::Version
186
+ version: '4.0'
181
187
  - !ruby/object:Gem::Dependency
182
188
  name: importmap-rails
183
189
  requirement: !ruby/object:Gem::Requirement