ruby_cms 0.1.7 → 0.1.8

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 CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: cf4ff917e02707c3a9d4ed7cec086d357b3c7de708ebc58475a4b5c0276a64bd
4
- data.tar.gz: be5e98bda847b6b1129210ba575fb29951f7e2ac96d53e9fcdb7cf58af7e97b6
3
+ metadata.gz: 936e8ad32e5f5ad5cb16f5475450b5eba360947252549fe5f45f215b3a0e0437
4
+ data.tar.gz: 159a699e86f2a1f7bf1d42cb4f959ce7c888cfce5d3b6450906631db32bf6ea8
5
5
  SHA512:
6
- metadata.gz: 97f3797085020d26908c8189324fc3f157241be0aa1eecc4a7575d4a7839ea3920662ee7e9e2f6ad509c1fd7810cc291fc9c09f23630f98c4b2d208ef50dd1af
7
- data.tar.gz: 7ce9c3b67c447847f407b3fa96ee3dacee1780bd14352f3da9cc310d71868cccbed42e5de0c13cd1f9a6e8edc0bfbf6c96acc0a3cad37e5c2dcbaf7db448715b
6
+ metadata.gz: 4f63343f61e425f23af9387e3d156d3ca5d057c0eed9a8e61b9f554c665b70208a1f8fa40f2e0aaae415952b94915fb322273e138fbf3251c287536cf529da7b
7
+ data.tar.gz: d6bd95c19833248a79e4499f32cbe1cfc1adb345ab0869c6ee0264b1ebf1f6ccd1d13cad3cde6e81fa9223fd968991a6194278ac832e5d780063576f8cd77202
data/CHANGELOG.md CHANGED
@@ -1,5 +1,9 @@
1
1
  ## [Unreleased]
2
2
 
3
+ ## [0.1.0.8] - 2026-03-25
4
+
5
+ - Update admin page styling
6
+
3
7
  ## [0.1.0.7] - 2026-03-25
4
8
 
5
9
  - Improve some styling and fix rich text
@@ -31,15 +31,15 @@ module RubyCms
31
31
  CARD_CLASS = "bg-card shadow-sm rounded-xl border border-border/60 ring-1 ring-black/[0.03] overflow-hidden"
32
32
  GRID_CLASS = "grid grid-cols-1 lg:grid-cols-3"
33
33
  MAIN_CLASS = "lg:col-span-2 p-6 space-y-6"
34
- SIDEBAR_CLASS = "border-t lg:border-t-0 lg:border-l border-border/60 bg-muted/20 p-6 space-y-6"
35
- ACTIONS_CLASS = "flex items-center justify-end gap-3 border-t border-border/60 px-6 py-4 bg-muted/20"
34
+ SIDEBAR_CLASS = "border-t lg:border-t-0 lg:border-l border-border/60 bg-background p-6 space-y-6"
35
+ ACTIONS_CLASS = "flex items-center justify-end gap-3 border-t border-border/60 px-6 py-4 bg-background"
36
36
 
37
37
  INPUT_CLASS = "block w-full rounded-lg border border-border bg-background px-3 py-2 text-sm text-foreground shadow-sm placeholder:text-muted-foreground focus:outline-none focus:ring-2 focus:ring-primary/30 focus:border-primary transition-colors"
38
38
  LABEL_CLASS = "block text-sm font-medium text-foreground mb-1.5"
39
39
  HINT_CLASS = "mt-1 text-xs text-muted-foreground"
40
40
  FILE_INPUT_CLASS = "block w-full text-sm text-muted-foreground file:mr-3 file:py-1.5 file:px-3 file:rounded-lg file:border-0 file:text-sm file:font-medium file:bg-primary/10 file:text-primary hover:file:bg-primary/20 transition-colors"
41
41
 
42
- SECTION_CLASS = "rounded-xl border border-border/60 bg-muted/30 p-5"
42
+ SECTION_CLASS = "rounded-xl border border-border/60 bg-background p-5"
43
43
  SECTION_TITLE_CLASS = "text-sm font-semibold text-foreground tracking-tight mb-4"
44
44
  DETAIL_LABEL_CLASS = "text-xs font-medium text-muted-foreground uppercase tracking-wider"
45
45
  DETAIL_VALUE_CLASS = "mt-1 text-sm text-foreground"
@@ -78,33 +78,28 @@
78
78
 
79
79
  <%# ── Locale Tabs ── %>
80
80
  <% if @blocks_by_locale.present? %>
81
- <% active_locale = @blocks_by_locale.key?(@content_block.locale.to_s) ? @content_block.locale.to_s : @blocks_by_locale.keys.first %>
82
81
  <div class="rounded-xl border border-border/60 overflow-hidden" data-controller="ruby-cms--locale-tabs">
83
- <div class="flex gap-1 p-2 bg-muted/30 border-b border-border/60" role="tablist">
84
- <% @blocks_by_locale.each do |locale_s, _| %>
85
- <% selected = locale_s == active_locale %>
82
+ <div class="flex gap-1 p-2 bg-background border-b border-border/60" role="tablist">
83
+ <% @blocks_by_locale.each_with_index do |(locale_s, _), idx| %>
86
84
  <button type="button"
87
85
  role="tab"
88
- aria-selected="<%= selected %>"
86
+ aria-selected="<%= idx == 0 %>"
89
87
  aria-controls="locale-panel-<%= locale_s %>"
90
88
  id="locale-tab-<%= locale_s %>"
91
89
  data-ruby-cms--locale-tabs-target="tab"
92
90
  data-panel-id="locale-panel-<%= locale_s %>"
93
- data-active-classes="bg-background text-primary shadow-sm ring-1 ring-border/60"
94
- data-inactive-classes="bg-transparent text-muted-foreground hover:bg-muted hover:text-foreground"
95
91
  data-action="click->ruby-cms--locale-tabs#switchTab"
96
- class="px-3 py-1.5 rounded-md text-xs font-medium border-none cursor-pointer transition-colors <%= selected ? 'bg-background text-primary shadow-sm ring-1 ring-border/60' : 'bg-transparent text-muted-foreground hover:bg-muted hover:text-foreground' %>">
92
+ class="px-3 py-1.5 rounded-md text-xs font-medium border-none cursor-pointer transition-colors <%= idx == 0 ? 'bg-background text-primary shadow-sm ring-1 ring-border/60' : 'bg-transparent text-muted-foreground hover:bg-muted hover:text-foreground' %>">
97
93
  <%= ruby_cms_locale_display_name(locale_s) %>
98
94
  </button>
99
95
  <% end %>
100
96
  </div>
101
97
 
102
- <% @blocks_by_locale.each do |locale_s, block| %>
103
- <% selected = locale_s == active_locale %>
98
+ <% @blocks_by_locale.each_with_index do |(locale_s, block), idx| %>
104
99
  <div id="locale-panel-<%= locale_s %>"
105
100
  role="tabpanel"
106
101
  aria-labelledby="locale-tab-<%= locale_s %>"
107
- class="p-5 <%= selected ? '' : 'hidden' %>"
102
+ class="p-5 <%= idx > 0 ? 'hidden' : '' %>"
108
103
  data-locale-panel>
109
104
 
110
105
  <%= hidden_field_tag "content_block[locales][#{locale_s}][locale]", locale_s %>
@@ -209,8 +204,8 @@
209
204
  <div class="space-y-3">
210
205
  <% @blocks_by_locale.each do |locale_s, block| %>
211
206
  <% next if block.title.blank? && block.content_body.blank? %>
212
- <div class="py-1">
213
- <span class="text-[10px] font-semibold uppercase tracking-wide text-muted-foreground"><%= ruby_cms_locale_display_name(locale_s) %></span>
207
+ <div class="rounded-lg border border-border/60 bg-background p-3">
208
+ <span class="inline-flex items-center rounded-md bg-background px-1.5 py-0.5 text-[10px] font-medium text-muted-foreground ring-1 ring-border/60 mb-2"><%= ruby_cms_locale_display_name(locale_s) %></span>
214
209
  <% if block.title.present? %>
215
210
  <p class="text-xs font-medium text-foreground"><%= block.title %></p>
216
211
  <% end %>
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module RubyCms
4
- VERSION = "0.1.7"
4
+ VERSION = "0.1.8"
5
5
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: ruby_cms
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.7
4
+ version: 0.1.8
5
5
  platform: ruby
6
6
  authors:
7
7
  - Codebyjob