Skip to content

Commit

Permalink
Merge pull request #5930 from solidusio/backport/v4.4/pr-5927
Browse files Browse the repository at this point in the history
[v4.4] Fix component translation scopes
  • Loading branch information
tvdeyen authored Nov 15, 2024
2 parents 287b995 + 6579041 commit 5ce0c99
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 15 deletions.
4 changes: 4 additions & 0 deletions admin/app/components/solidus_admin/base_component.rb
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,10 @@ def missing_translation(key, options)
end
end

def self.i18n_scope
@i18n_scope ||= name.underscore.tr("/", ".")
end

def self.stimulus_id
@stimulus_id ||= name.underscore
.sub(/^solidus_admin\/(.*)\/component$/, '\1')
Expand Down
Original file line number Diff line number Diff line change
@@ -1,20 +1,5 @@
en:
columns:
items:
one: 1 Item
other: '%{count} Items'
filters:
status: Status
shipment_state: Shipment State
payment_state: Payment State
promotions: Promotions
date:
formats:
short: '%d %b %y'
scopes:
all_orders: All
canceled: Canceled
complete: Complete
returned: Returned
in_progress: In Progress
promotions: Promotions
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
en:
filters:
promotions: Promotions
scopes:
promotions: Promotions

0 comments on commit 5ce0c99

Please sign in to comment.