OpenProject is the leading open source project management software for product, project and portfolio management. A powerful Jira alternative with agile planning, issue tracking, roadmaps, Gantt charts, time tracking, collaboration features, and more. Available on premises or in the cloud. ⭐ Star us on GitHub
Ruby agile-developmentangularbcfboardsbug-trackerganttgantt-chartifcissue-trackerjira-alternativekanbanopenprojectproduct-managementproject-managementproject-planningroadmaprubyscrumtimelineworkflows
remove duplicated code and unnecessary files
bsatarnejadd4054f287f97
diff --git a/frontend/src/stimulus/controllers/dynamic/meetings-sidebar-details.controller.ts b/frontend/src/stimulus/controllers/dynamic/meetings-sidebar-details.controller.tsdeleted file mode 100644index 33c3408f387..00000000000--- a/frontend/src/stimulus/controllers/dynamic/meetings-sidebar-details.controller.ts+++ /dev/null@@ -1,51 +0,0 @@-/*- * -- copyright- * OpenProject is an open source project management software.- * Copyright (C) 2023 the OpenProject GmbH- *- * This program is free software; you can redistribute it and/or- * modify it under the terms of the GNU General Public License version 3.- *- * OpenProject is a fork of ChiliProject, which is a fork of Redmine. The copyright follows:- * Copyright (C) 2006-2013 Jean-Philippe Lang- * Copyright (C) 2010-2013 the ChiliProject Team- *- * This program is free software; you can redistribute it and/or- * modify it under the terms of the GNU General Public License- * as published by the Free Software Foundation; either version 2- * of the License, or (at your option) any later version.- *- * This program is distributed in the hope that it will be useful,- * but WITHOUT ANY WARRANTY; without even the implied warranty of- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the- * GNU General Public License for more details.- *- * You should have received a copy of the GNU General Public License- * along with this program; if not, write to the Free Software- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.- *- * See COPYRIGHT and LICENSE files for more details.- * ++- */--import { Controller } from '@hotwired/stimulus';--export default class MeetingsSidebarDetailsController extends Controller {- static targets = ['showHideButton', 'hiddenParticipants'];- declare readonly showHideButtonTarget:HTMLInputElement;- declare readonly hiddenParticipantsTarget:HTMLElement;-- connect():void {- this.showHiddenParticipants();- }-- showHiddenParticipants():void {- this.showHideButtonTarget.addEventListener('click', () => {- if (this.hiddenParticipantsTarget.classList.contains('d-none')) {- this.hiddenParticipantsTarget.classList.remove('d-none');- } else {- this.hiddenParticipantsTarget.classList.add('d-none');- }- });- }-}diff --git a/modules/meeting/app/components/_index.sass b/modules/meeting/app/components/_index.sassindex c3880088011..2f17a54aef6 100644--- a/modules/meeting/app/components/_index.sass+++ b/modules/meeting/app/components/_index.sass@@ -1,4 +1,3 @@@import "./meeting_agenda_items/item_component/show_component.sass"@import "./meeting_agenda_items/form_component.sass"@import "./meetings/sidebar/state_component.sass"-@import "./meetings/sidebar/details_component.sass"diff --git a/modules/meeting/app/components/meetings/sidebar/details_component.html.erb b/modules/meeting/app/components/meetings/sidebar/details_component.html.erbindex 74b62bd9736..a8a75b710db 100644--- a/modules/meeting/app/components/meetings/sidebar/details_component.html.erb+++ b/modules/meeting/app/components/meetings/sidebar/details_component.html.erb@@ -1,5 +1,5 @@<%=- component_wrapper(data: wrapper_data_attributes) do+ component_wrapper doflex_layout do |details_container|details_container.with_row doflex_layout(align_items: :center, justify_content: :space_between) do |heading|diff --git a/modules/meeting/app/components/meetings/sidebar/details_component.rb b/modules/meeting/app/components/meetings/sidebar/details_component.rbindex 436af43a8ec..3954f729b1f 100644--- a/modules/meeting/app/components/meetings/sidebar/details_component.rb+++ b/modules/meeting/app/components/meetings/sidebar/details_component.rb@@ -40,13 +40,6 @@ module Meetingsprivate- def wrapper_data_attributes- {- controller: 'meetings-sidebar-details',- 'application-target': 'dynamic'- }- end-def render_truncated_locationrender(Primer::Beta::Truncate.new) do |component|component.with_item(max_width: 250) do@@ -54,30 +47,6 @@ module Meetingsendendend-- def render_participant(participant)- flex_layout(align_items: :center) do |flex|- flex.with_column(classes: 'ellipsis') do- render(Users::AvatarComponent.new(user: participant.user,- size: :medium,- classes: 'op-principal_flex'))- end- render_participant_state(participant, flex)- end- end-- def render_participant_state(participant, flex)- if participant.attended?- flex.with_column(ml: 1) do- render(Primer::Beta::Text.new(font_size: :small, color: :subtle)) { t("description_attended").capitalize }- end- elsif participant.invited?- flex.with_column(ml: 1) do- render(Primer::Beta::Text.new(font_size: :small, color: :subtle)) { t("description_invite").capitalize }- end- end- end-def render_meeting_attribute_row(icon, &)flex_layout(align_items: :center, justify_content: :space_between) do |flex|flex.with_column dodiff --git a/modules/meeting/app/components/meetings/sidebar/details_component.sass b/modules/meeting/app/components/meetings/sidebar/details_component.sassdeleted file mode 100644index c980f3d981f..00000000000--- a/modules/meeting/app/components/meetings/sidebar/details_component.sass+++ /dev/null@@ -1,12 +0,0 @@-@import 'helpers'-.op-meeting-sidebar-details-participants- display: none- &-button- padding: 0 !important- color: var(--content-link-color)----@media screen and (max-width: $breakpoint-sm)- .op-meeting-sidebar-details-participants- display: block !important\ No newline at end of file