-
Notifications
You must be signed in to change notification settings - Fork 3.4k
Expand file tree
/
Copy pathindex_component.html.erb
More file actions
119 lines (108 loc) · 4.31 KB
/
Copy pathindex_component.html.erb
File metadata and controls
119 lines (108 loc) · 4.31 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
<%#-- copyright
OpenProject is an open source project management software.
Copyright (C) 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.
++#%>
<%=
component_wrapper do
flex_layout(data: wrapper_data_attributes) do |flex|
flex.with_row do
render EnterpriseEdition::BannerComponent.new(
:customize_life_cycle,
variant: :medium,
image: "enterprise/project-lifecycle.png",
mb: 3
)
end
if allowed_to_customize_life_cycle?
flex.with_row do
render(Primer::OpenProject::SubHeader.new(collapsed_search: false)) do |subheader|
subheader.with_filter_input(
name: "border-box-filter",
label: t("settings.project_phase_definitions.filter.label"),
visually_hide_label: true,
placeholder: t("settings.project_phase_definitions.filter.label"),
leading_visual: {
icon: :search,
size: :small
},
show_clear_button: true,
data: {
action: "input->projects--settings--border-box-filter#filterLists",
"projects--settings--border-box-filter-target": "filter"
}
)
subheader.with_action_button(
scheme: :primary,
leading_icon: :plus,
label: I18n.t("settings.project_phase_definitions.label_add_description"),
tag: :a,
href: new_admin_settings_project_phase_definition_path
) do
I18n.t("settings.project_phase_definitions.label_add")
end
end
end
end
flex.with_row do
render(border_box_container(mb: 3, data: drop_target_config)) do |component|
component.with_header(font_weight: :bold) do
flex_layout(justify_content: :space_between, align_items: :center) do |header_container|
header_container.with_column do
render(Primer::Beta::Text.new(font_weight: :bold)) do
I18n.t("settings.project_phase_definitions.section_header")
end
end
end
end
if definitions.empty?
component.with_row do
render(Primer::Beta::Text.new(color: :subtle)) do
t("settings.project_phase_definitions.non_defined")
end
end
else
definitions.each do |definition|
component.with_row(
data: {
"projects--settings--border-box-filter-target": "searchItem",
test_selector: "project-phase-definition",
**draggable_item_config(definition)
}
) do
render(
Settings::ProjectPhaseDefinitions::RowComponent.new(
definition,
first?: definition == definitions.first,
last?: definition == definitions.last
)
)
end
end
end
end
end
flex.with_row(display: :none, data: { "projects--settings--border-box-filter-target": "noResultsText" }) do
render Primer::Beta::Text.new do
I18n.t("js.autocompleter.notFoundText")
end
end
end
end
%>