Skip to content

Commit

Permalink
Merge branch 'release/14.5' into task/57594-145-documentation-update-…
Browse files Browse the repository at this point in the history
…pageheaders-and-subheaders-in-the-my-account-pages
  • Loading branch information
as-op authored Sep 9, 2024
2 parents fb93d51 + 12843b2 commit 99feb9b
Show file tree
Hide file tree
Showing 176 changed files with 1,484 additions and 1,059 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,9 @@
selected: selected_columns,
protected: helpers.protected_projects_columns_options,
name: COLUMN_HTML_NAME,
id: 'columns-select',
id: COLUMN_HTML_ID,
dragAreaName: "#{COLUMN_HTML_ID}_dragarea",
formControlId: "#{COLUMN_HTML_ID}_autocompleter",
inputLabel: I18n.t(:'queries.configure_view.columns.input_label'),
inputPlaceholder: I18n.t(:'queries.configure_view.columns.input_placeholder'),
dragAreaLabel: I18n.t(:'queries.configure_view.columns.drag_area_label'),
Expand Down
1 change: 1 addition & 0 deletions app/components/projects/configure_view_modal_component.rb
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,7 @@ class Projects::ConfigureViewModalComponent < ApplicationComponent
MODAL_ID = "op-project-list-configure-dialog"
QUERY_FORM_ID = "op-project-list-configure-query-form"
COLUMN_HTML_NAME = "columns"
COLUMN_HTML_ID = "columns-select"

options :query

Expand Down
4 changes: 2 additions & 2 deletions app/components/work_packages/details/tab_component.html.erb
Original file line number Diff line number Diff line change
Expand Up @@ -62,8 +62,8 @@
flex.with_column(classes: "op-work-package-details-tab-component--action") do
render(Primer::Beta::IconButton.new(icon: :x,
tag: :a,
href: helpers.url_for_with_params(action: :close_split_view),
data: { turbo: true, 'turbo-stream': true },
href: base_route,
data: { turbo: true, target: "_top", turbo_action: "advance" },
scheme: :invisible,
test_selector: "wp-details-tab-component--close",
aria: { label: I18n.t(:button_close) }))
Expand Down
2 changes: 1 addition & 1 deletion app/components/work_packages/split_view_component.html.erb
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
flex.with_row(flex: 1) do
helpers.angular_component_tag "opce-wp-split-view",
inputs: {
work_package_id: params[:work_package_id] || @work_package.id,
work_package_id: @id,
resizerClass: "op-work-package-split-view",
activeTab: @tab
}
Expand Down
4 changes: 4 additions & 0 deletions app/components/work_packages/split_view_component.sass
Original file line number Diff line number Diff line change
Expand Up @@ -7,3 +7,7 @@
@media screen and (max-width: $breakpoint-lg)
// Unfortunately, we have to enforce this style via !important as the resizer writes the width directly on the element as inline style
min-width: unset !important

@media screen and (max-width: $breakpoint-sm)
.work-packages--details-toolbar-container
@include hide-button-texts
28 changes: 0 additions & 28 deletions app/controllers/concerns/work_packages/with_split_view.rb
Original file line number Diff line number Diff line change
Expand Up @@ -37,33 +37,5 @@ module WithSplitView
def split_view_work_package_id
params[:work_package_id].to_i
end

def close_split_view
respond_to do |format|
format.turbo_stream do
render turbo_stream: [
turbo_stream.remove("work-package-details-#{split_view_work_package_id}"),
turbo_stream.push_state(url: split_view_base_route),
turbo_stream.set_title(title: helpers.page_title(I18n.t("js.notifications.title")))
]
end
format.html do
redirect_to split_view_base_route
end
end
end

def respond_to_with_split_view(&format_block)
respond_to do |format|
format.turbo_stream do
render turbo_stream: [
turbo_stream.update("content-bodyRight", helpers.split_view_instance.render_in(view_context)),
turbo_stream.push_state(url: request.fullpath)
]
end

yield(format) if format_block
end
end
end
end
10 changes: 7 additions & 3 deletions app/controllers/notifications_controller.rb
Original file line number Diff line number Diff line change
Expand Up @@ -31,16 +31,20 @@ class NotificationsController < ApplicationController

before_action :require_login
before_action :filtered_query, only: :mark_all_read
no_authorization_required! :index, :split_view, :update_counter, :close_split_view, :mark_all_read, :date_alerts, :share_upsale
no_authorization_required! :index, :split_view, :update_counter, :mark_all_read, :date_alerts, :share_upsale

def index
render_notifications_layout
end

def split_view
respond_to_with_split_view do |format|
respond_to do |format|
format.html do
render :index, layout: "notifications"
if turbo_frame_request?
render "work_packages/split_view", layout: false
else
render :index, layout: "notifications"
end
end
end
end
Expand Down
2 changes: 1 addition & 1 deletion app/helpers/work_packages/split_view_helper.rb
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,6 @@ def optional_work_package_split_view
def split_view_instance
WorkPackages::SplitViewComponent.new(id: params[:work_package_id],
tab: params[:tab],
base_route: params[:base_route] || work_packages_path)
base_route: split_view_base_route)
end
end
2 changes: 1 addition & 1 deletion app/mailers/sharing_mailer.rb
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ def shared_work_package(sharer, membership, group = nil)
@role_rights = derive_role_rights(role)
@allowed_work_package_actions = derive_allowed_work_package_actions(role)
@url = optionally_activated_url(work_package_url(@work_package.id), @invitation_token)
@notification_url = optionally_activated_url(details_notifications_url(@work_package.id), @invitation_token)
@notification_url = optionally_activated_url(details_notifications_url(@work_package.id, tab: :activity), @invitation_token)

set_open_project_headers(@work_package)
message_id(membership, sharer)
Expand Down
4 changes: 2 additions & 2 deletions app/views/layouts/base.html.erb
Original file line number Diff line number Diff line change
Expand Up @@ -155,9 +155,9 @@ See COPYRIGHT and LICENSE files for more details.
<%= yield %>
<% end %>
</div>
<div id="content-bodyRight">
<%= turbo_frame_tag "content-bodyRight" do %>
<%= content_for :content_body_right %>
</div>
<% end %>
<% end %>
</main>
</div>
Expand Down
4 changes: 2 additions & 2 deletions app/views/mailer/_notification_row.html.erb
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<a style="text-decoration: none;display: block;"
href="<%= local_assigns[:notification_url] || details_notifications_url(work_package.id) %>"
href="<%= local_assigns[:notification_url] || details_notifications_url(work_package.id, tab: :activity) %>"
target="_blank">
<%= render layout: 'mailer/border_table' do %>
<tr>
Expand Down Expand Up @@ -104,7 +104,7 @@
</table>

<a style="margin-left: 12px;"
href="<%= defined?(open_in_browser_path) ? open_in_browser_path : details_notifications_url(work_package.id) %>"
href="<%= defined?(open_in_browser_path) ? open_in_browser_path : details_notifications_url(work_package.id, tab: :activity) %>"
target="_blank"
rel="noopener noreferrer">
<%= I18n.t('mail.work_packages.open_in_browser') %>
Expand Down
2 changes: 1 addition & 1 deletion app/views/work_package_mailer/mentioned.html.erb
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
<%= render partial: 'mailer/mailer_header',
locals: {
summary: I18n.t(:'mail.work_packages.mentioned_by', user: @journal.user),
button_href: details_notifications_url(@work_package.id),
button_href: details_notifications_url(@work_package.id, tab: :activity),
button_text: I18n.t(:'mail.notification.see_in_center'),
user: @user,
} %>
Expand Down
3 changes: 3 additions & 0 deletions app/views/work_packages/split_view.html.erb
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
<%= turbo_frame_tag "content-bodyRight" do %>
<%= render(split_view_instance) %>
<% end %>
32 changes: 16 additions & 16 deletions config/locales/crowdin/de.yml
Original file line number Diff line number Diff line change
Expand Up @@ -297,7 +297,7 @@ de:
actions:
label_enable_single: "In diesem Projekt aktiv, zum Deaktivieren anklicken"
label_disable_single: "In diesem Projekt inaktiv, zum Aktivieren anklicken"
remove_from_project: "Remove from project"
remove_from_project: "Aus dem Projekt entfernen"
label_enable_all: "Alles aktivieren"
label_disable_all: "Alles deaktivieren"
is_required_blank_slate:
Expand Down Expand Up @@ -1679,23 +1679,23 @@ de:
label: "Zoom levels"
caption: "Select what is the zoom level for dates displayed in the chart."
options:
days: "Days"
weeks: "Weeks"
months: "Months"
quarters: "Quarters"
days: "Tage"
weeks: "Wochen"
months: "Monate"
quarters: "Quartale"
column_width:
label: "Table column width"
label: "Breite der Tabellenspalten"
options:
narrow: "Narrow"
medium: "Medium"
wide: "Wide"
very_wide: "Very wide"
narrow: "Schmal"
medium: "Mittel"
wide: "Breit"
very_wide: "Sehr breit"
paper_size:
label: "Paper size"
caption: "Depending on the chart size more than one page might be exported."
label: "Papierformat"
caption: "Je nach Größe des Diagramms besteht der Export aus einer oder auch aus mehreren Seiten."
long_text_fields:
input_caption: "By default all long text fields are selected."
input_label: "Add long text fields"
input_caption: "Standardmäßig sind alle Langtextfelder ausgewählt."
input_label: "Langtextfelder hinzufügen"
input_placeholder: "Search for long text fields"
drag_area_label: "Manage long text fields"
xls:
Expand Down Expand Up @@ -3517,9 +3517,9 @@ de:
remaining_hours:
cleared_because_work_is_empty: "Cleared because Work is empty."
cleared_because_percent_complete_is_empty: "Cleared because % Complete is empty."
decreased_like_work: "Decreased by the same amount as Work."
decreased_like_work: "Verringert um den gleichen Betrag wie Aufwand."
derived: "Derived from Work and % Complete."
increased_like_work: "Increased by the same amount as Work."
increased_like_work: "Erhöht um den gleichen Betrag wie Aufwand."
same_as_work: "Set to same value as Work."
permissions:
comment: "Kommentar"
Expand Down
96 changes: 48 additions & 48 deletions config/locales/crowdin/fr.yml
Original file line number Diff line number Diff line change
Expand Up @@ -300,7 +300,7 @@ fr:
actions:
label_enable_single: "Actif dans ce projet, cliquez pour le désactiver"
label_disable_single: "Inactif dans ce projet, cliquez pour l'activer"
remove_from_project: "Remove from project"
remove_from_project: "Supprimer du projet"
label_enable_all: "Activer tout"
label_disable_all: "Désactiver tout"
is_required_blank_slate:
Expand Down Expand Up @@ -1673,46 +1673,46 @@ fr:
caption: "Exporter la liste des lots de travaux dans une table avec les colonnes souhaitées."
report:
label: "Rapport"
caption: "Export the work package on a detailed report of all work packages in the list."
caption: "Exportez le lot de travaux dans un rapport détaillé de tous les lots de travaux de la liste."
gantt:
label: "Gantt chart"
caption: "Export the work packages list in a Gantt diagram view."
label: "Diagramme de Gantt"
caption: "Exportez la liste des lots de travaux dans un diagramme de Gantt."
include_images:
label: "Include images"
caption: "Exclude images to reduce the size of the PDF export."
label: "Inclure des images"
caption: "Excluez les images pour réduire la taille de l'exportation PDF."
gantt_zoom_levels:
label: "Zoom levels"
caption: "Select what is the zoom level for dates displayed in the chart."
label: "Niveaux de zoom"
caption: "Sélectionnez le niveau de zoom pour les dates affichées dans le graphique."
options:
days: "Days"
weeks: "Weeks"
months: "Months"
quarters: "Quarters"
days: "Jours"
weeks: "Semaines"
months: "Mois"
quarters: "Trimestres"
column_width:
label: "Table column width"
label: "Largeur des colonnes du tableau"
options:
narrow: "Narrow"
medium: "Medium"
wide: "Wide"
very_wide: "Very wide"
narrow: "Étroite"
medium: "Moyenne"
wide: "Large"
very_wide: "Très large"
paper_size:
label: "Paper size"
caption: "Depending on the chart size more than one page might be exported."
label: "Format du papier"
caption: "Plusieurs pages peuvent être exportées en fonction de la taille de la carte."
long_text_fields:
input_caption: "By default all long text fields are selected."
input_label: "Add long text fields"
input_placeholder: "Search for long text fields"
drag_area_label: "Manage long text fields"
input_caption: "Par défaut, tous les champs de texte long sont sélectionnés."
input_label: "Ajouter des champs de texte longs"
input_placeholder: "Recherche de champs de texte longs"
drag_area_label: "Gérer les champs de texte longs"
xls:
include_relations:
label: "Include relations"
caption: "This option will create a duplicate of each work package for every relation this has with another work package."
label: "Inclure les relations"
caption: "Cette option crée un double de chaque lot de travaux pour chaque relation qu'il a avec un autre lot de travaux."
include_descriptions:
label: "Include descriptions"
caption: "This option will add a description column in raw format."
your_work_packages_export: "Work packages are being exported"
succeeded: "Export completed"
failed: "An error has occurred while trying to export the work packages: %{message}"
label: "Inclure des descriptions"
caption: "Cette option permet d'ajouter une colonne de description au format brut."
your_work_packages_export: "Les lots de travaux sont exportés"
succeeded: "Exportation terminée"
failed: "Une erreur s'est produite lors de l'exportation des lots de travaux : %{message}"
format:
atom: "Atom"
csv: "CSV"
Expand Down Expand Up @@ -2363,8 +2363,8 @@ fr:
label_role_plural: "Rôles"
label_role_search: "Assigner un rôle aux nouveaux membres"
label_scm: "SCM"
label_scroll_left: "Scroll left"
label_scroll_right: "Scroll right"
label_scroll_left: "Défilement vers la gauche"
label_scroll_right: "Défilement vers la droite"
label_search: "Recherche"
label_search_by_name: "Rechercher par nom"
label_send_information: "Envoyer de nouveaux identifiants à l'utilisateur"
Expand Down Expand Up @@ -3122,9 +3122,9 @@ fr:
setting_work_package_done_ratio_field: "Basé sur le travail"
setting_work_package_done_ratio_status: "Basé sur le statut"
setting_work_package_done_ratio_explanation_pre_14_4_without_percent_complete_edition_html: >
In <b>work-based</b> mode, % Complete is calculated from how much work is done in relation to total work. In <b>status-based</b> mode, each status has a % Complete value associated with it. Changing status will change % Complete.
En mode <b>Basé sur le travail</b>, le % d'achèvement est calculé à partir de la quantité de travail effectuée par rapport au total du travail. En mode <b>Basé sur le statut</b>, chaque état a une valeur de % d'achèvement associée. Le changement de statut changera la valeur de % d'achèvement.
setting_work_package_done_ratio_explanation_html: >
In <b>work-based</b> mode, % Complete can be freely set to any value. If you optionally enter a value for Work, Remaining work will automatically be derived. In <b>status-based</b> mode, each status has a % Complete value associated with it. Changing status will change % Complete.
En mode <b>Basé sur le travail</b>, le % d'achèvement peut être librement défini sur n'importe quelle valeur. Si vous saisissez une valeur pour le travail, le travail restant sera automatiquement dérivé. En mode <b>Basé sur le statut</b>, chaque état a une valeur de % d'achèvement associée. Le changement de statut changera la valeur de % d'achèvement.
setting_work_package_properties: "Propriétés du Lot de Travaux"
setting_work_package_startdate_is_adddate: "Utiliser la date actuelle comme date de début des nouveaux lots de travaux"
setting_work_packages_projects_export_limit: "Limite d'exportation des lots de travaux/projets"
Expand Down Expand Up @@ -3506,26 +3506,26 @@ fr:
progress:
label_note: "Note :"
modal:
work_based_help_text: "Each field is automatically calculated from the two others when possible."
work_based_help_text_pre_14_4_without_percent_complete_edition: "% Complete is automatically derived from Work and Remaining work."
work_based_help_text: "Chaque champ est calculé automatiquement à partir des deux autres lorsque cela est possible."
work_based_help_text_pre_14_4_without_percent_complete_edition: "Le % d'achèvement est automatiquement dérivé du travail et du travail restant."
status_based_help_text: "Le % réalisé est défini par le statut du lot de travaux."
migration_warning_text: "Dans le mode de calcul de la progression basé sur le travail, le % réalisé ne peut pas être défini manuellement et est lié au travail. La valeur existante a été conservée mais ne peut pas être modifiée. Veuillez d'abord renseigner Travail."
derivation_hints:
done_ratio:
cleared_because_remaining_work_is_empty: "Cleared because Remaining work is empty."
cleared_because_work_is_0h: "Cleared because Work is 0h."
derived: "Derived from Work and Remaining work."
cleared_because_remaining_work_is_empty: "Effacé parce que le travail restant est vide."
cleared_because_work_is_0h: "Effacé parce que le travail est de 0 h."
derived: "Dérivé du travail et du travail restant."
estimated_hours:
cleared_because_remaining_work_is_empty: "Cleared because Remaining work is empty."
derived: "Derived from Remaining work and % Complete."
same_as_remaining_work: "Set to same value as Remaining work."
cleared_because_remaining_work_is_empty: "Effacé parce que le travail restant est vide."
derived: "Dérivé du travail restant et du % d'achèvement."
same_as_remaining_work: "Régler à la même valeur que le travail restant."
remaining_hours:
cleared_because_work_is_empty: "Cleared because Work is empty."
cleared_because_percent_complete_is_empty: "Cleared because % Complete is empty."
decreased_like_work: "Decreased by the same amount as Work."
derived: "Derived from Work and % Complete."
increased_like_work: "Increased by the same amount as Work."
same_as_work: "Set to same value as Work."
cleared_because_work_is_empty: "Effacé parce que le travail est vide."
cleared_because_percent_complete_is_empty: "Effacé parce que le % d'achèvement est vide."
decreased_like_work: "Diminué du même montant que le travail."
derived: "Dérivé du travail et du % d'achèvement."
increased_like_work: "Augmenté du même montant que le travail."
same_as_work: "Régler à la même valeur que le travail."
permissions:
comment: "Commentaire"
comment_description: "Peut consulter et commenter ce lot de travaux."
Expand Down
Loading

0 comments on commit 99feb9b

Please sign in to comment.