We were using the same texts twice. For the remove marker label text, however, we were using the text defined in proposals for both proposals and investments. Ideally the translation keys for these texts would go in another namespace, since they no longer refer to just proposals. However, renaming the translation keys would mean losing the existing translations in every language we manage through Crowdin. So we aren't doing so.
24 lines
410 B
Ruby
24 lines
410 B
Ruby
class MapLocations::FormFieldsComponent < ApplicationComponent
|
|
attr_reader :form, :map_location
|
|
use_helpers :render_map
|
|
|
|
def initialize(form, map_location:)
|
|
@form = form
|
|
@map_location = map_location
|
|
end
|
|
|
|
def render?
|
|
feature?(:map)
|
|
end
|
|
|
|
private
|
|
|
|
def label
|
|
t("proposals.form.map_location")
|
|
end
|
|
|
|
def help
|
|
t("proposals.form.map_location_instructions")
|
|
end
|
|
end
|