i18n_feedback 0.8.1 → 0.8.2

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: 7961f050a8f18c3136f8bac4be58014c6d137b408539d9bbb589e3756c024674
4
- data.tar.gz: eb772bb6ca0dbd76d2638f6d5de2fb455a3c1ac737b640856fff79677f50f873
3
+ metadata.gz: 46eee60f6c5765728de028eb4cc020adf87c05fbfa1250a2b3bb9eccc5d66ad2
4
+ data.tar.gz: d7732101bdf49c68868f4f3580309ac0cb9e040024bdbd33e4c9598cb7a1dd0a
5
5
  SHA512:
6
- metadata.gz: a586da5d40cda89a58312e02bdeaaa27af64bc9c7013fca26cbd94bf7dd01da8109dfb2ce7417bf07fae3525837740d85441a6e47e3c65cebcb85dfe4125c53f
7
- data.tar.gz: 1978b54ebb78dadfbc90d09e97d4a8e656c2f77d34d134301e0844efbcf3848c13d95f8b2ea5311ef8f872f21439852c6c67564c981b3b42d08f2eee085376bc
6
+ metadata.gz: 93b6367c3e3b3479333152301dd6ab44e39d2fe734b10374fef7193d32652d18d1a13042820fa484d0e187061a6f0bda4a15ce3830f97ed409eeea25dfc02137
7
+ data.tar.gz: 9eb009039394424338293e77e1b5d684e75528508a5889856b710935ea34029300347218563a033025783fe46ffc100f5dd4e86cf5a62c3f788858474ad14a90
data/CHANGELOG.md CHANGED
@@ -2,6 +2,15 @@
2
2
 
3
3
  ## [Unreleased]
4
4
 
5
+ ## [0.8.2]
6
+
7
+ - Fix the dashboard's locale filter doing nothing under a strict (nonce-based)
8
+ Content-Security-Policy: it relied on an inline `onchange` handler, which such
9
+ a CSP blocks. The filter now has an always-visible **Filter** submit button, so
10
+ it works with JS off or inline handlers blocked (the `onchange` stays as a
11
+ nicety where allowed).
12
+ - Give the locale filter a visible **Locale** label.
13
+
5
14
  ## [0.8.1]
6
15
 
7
16
  - Make the dashboard **read-only**. Apply / Reject / Reopen / Delete only ever
@@ -16,14 +16,16 @@
16
16
  <% if @locales.many? %>
17
17
  <form class="filters" method="get">
18
18
  <input type="hidden" name="status" value="<%= @status %>">
19
- <select name="locale" onchange="this.form.requestSubmit()"
20
- aria-label="<%= t('i18n_feedback.dashboard.filter', default: 'Filter by locale') %>">
19
+ <label for="i18nf-locale"><%= t('i18n_feedback.dashboard.locale', default: 'Locale') %></label>
20
+ <select id="i18nf-locale" name="locale" onchange="this.form.submit()">
21
21
  <option value=""><%= t('i18n_feedback.dashboard.all_locales', default: 'All locales') %></option>
22
22
  <% @locales.each do |locale| %>
23
23
  <option value="<%= locale %>" <%= 'selected' if locale == @locale %>><%= locale %></option>
24
24
  <% end %>
25
25
  </select>
26
- <noscript><button><%= t('i18n_feedback.dashboard.filter', default: 'Filter') %></button></noscript>
26
+ <%# Inline onchange auto-submits where allowed; this button is the reliable
27
+ path where a strict CSP blocks inline handlers, or with JS off. %>
28
+ <button><%= t('i18n_feedback.dashboard.filter', default: 'Filter') %></button>
27
29
  </form>
28
30
  <% end %>
29
31
 
@@ -43,6 +43,7 @@
43
43
  }
44
44
 
45
45
  .filters { margin-bottom: 16px; display: flex; gap: 8px; align-items: center; }
46
+ .filters label { color: var(--muted); font-size: 13px; }
46
47
  .filters select {
47
48
  padding: 6px 8px; border: 1px solid var(--border); border-radius: 8px;
48
49
  background: var(--surface); color: var(--text); font: inherit;
@@ -24,7 +24,8 @@ en:
24
24
  dashboard:
25
25
  title: "Translation suggestions"
26
26
  subtitle: "Review what reviewers proposed, then apply it to your locale files."
27
- filter: "Filter by locale"
27
+ locale: "Locale"
28
+ filter: "Filter"
28
29
  all_locales: "All locales"
29
30
  current: "Current"
30
31
  suggested: "Suggested"
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module I18nFeedback
4
- VERSION = '0.8.1'
4
+ VERSION = '0.8.2'
5
5
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: i18n_feedback
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.8.1
4
+ version: 0.8.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Yaroslav Shmarov