Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
G
gitlab-ce
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
1
Merge Requests
1
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
nexedi
gitlab-ce
Commits
245737fc
Commit
245737fc
authored
Mar 05, 2021
by
Samantha Ming
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Add reviewer comment
- Move help path to provide/inject - translate text
parent
9ee8db92
Changes
7
Hide whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
24 additions
and
38 deletions
+24
-38
app/assets/javascripts/pages/projects/forks/new/components/app.vue
...s/javascripts/pages/projects/forks/new/components/app.vue
+0
-10
app/assets/javascripts/pages/projects/forks/new/components/fork_form.vue
...scripts/pages/projects/forks/new/components/fork_form.vue
+8
-8
app/assets/javascripts/pages/projects/forks/new/index.js
app/assets/javascripts/pages/projects/forks/new/index.js
+4
-0
app/views/projects/forks/new.html.haml
app/views/projects/forks/new.html.haml
+5
-5
locale/gitlab.pot
locale/gitlab.pot
+3
-9
spec/frontend/pages/projects/forks/new/components/app_spec.js
.../frontend/pages/projects/forks/new/components/app_spec.js
+0
-4
spec/frontend/pages/projects/forks/new/components/fork_form_spec.js
...end/pages/projects/forks/new/components/fork_form_spec.js
+4
-2
No files found.
app/assets/javascripts/pages/projects/forks/new/components/app.vue
View file @
245737fc
...
...
@@ -14,18 +14,10 @@ export default {
type
:
String
,
required
:
true
,
},
newGroupPath
:
{
type
:
String
,
required
:
true
,
},
projectFullPath
:
{
type
:
String
,
required
:
true
,
},
visibilityHelpPath
:
{
type
:
String
,
required
:
true
,
},
projectId
:
{
type
:
String
,
required
:
true
,
...
...
@@ -68,9 +60,7 @@ export default {
<div
class=
"col-lg-9"
>
<fork-form
:endpoint=
"endpoint"
:new-group-path=
"newGroupPath"
:project-full-path=
"projectFullPath"
:visibility-help-path=
"visibilityHelpPath"
:project-id=
"projectId"
:project-name=
"projectName"
:project-path=
"projectPath"
...
...
app/assets/javascripts/pages/projects/forks/new/components/fork_form.vue
View file @
245737fc
...
...
@@ -45,23 +45,23 @@ export default {
GlFormRadioGroup
,
GlFormSelect
,
},
inject
:
{
newGroupPath
:
{
default
:
''
,
},
visibilityHelpPath
:
{
default
:
''
,
},
},
props
:
{
endpoint
:
{
type
:
String
,
required
:
true
,
},
newGroupPath
:
{
type
:
String
,
required
:
true
,
},
projectFullPath
:
{
type
:
String
,
required
:
true
,
},
visibilityHelpPath
:
{
type
:
String
,
required
:
true
,
},
projectId
:
{
type
:
String
,
required
:
true
,
...
...
app/assets/javascripts/pages/projects/forks/new/index.js
View file @
245737fc
...
...
@@ -21,6 +21,10 @@ if (gon.features.forkProjectForm) {
// eslint-disable-next-line no-new
new
Vue
({
el
:
mountElement
,
provide
:
{
newGroupPath
,
visibilityHelpPath
,
},
render
(
h
)
{
return
h
(
App
,
{
props
:
{
...
...
app/views/projects/forks/new.html.haml
View file @
245737fc
-
page_title
_
(
"ForkProject|Fork project"
)
-
page_title
s
_
(
"ForkProject|Fork project"
)
-
if
Feature
.
enabled?
(
:fork_project_form
)
#fork-groups-mount-element
{
data:
{
fork_illustration:
image_path
(
'illustrations/project-create-new-sm.svg'
),
...
...
@@ -15,15 +15,15 @@
.row.gl-mt-3
.col-lg-3
%h4
.gl-mt-0
=
_
(
"
Fork project"
)
=
s_
(
"ForkProject|
Fork project"
)
%p
=
_
(
"
A fork is a copy of a project."
)
=
s_
(
"ForkProject|
A fork is a copy of a project."
)
%br
=
_
(
'
Forking a repository allows you to make changes without affecting the original project.'
)
=
s_
(
'ForkProject|
Forking a repository allows you to make changes without affecting the original project.'
)
.col-lg-9
-
if
@own_namespace
.
present?
.fork-thumbnail-container.js-fork-content
%h5
.gl-mt-0.gl-mb-0.gl-ml-3.gl-mr-3
=
_
(
"
Select a namespace to fork the project"
)
=
s_
(
"ForkProject|
Select a namespace to fork the project"
)
=
render
'fork_button'
,
namespace:
@own_namespace
#fork-groups-mount-element
{
data:
{
endpoint:
new_project_fork_path
(
@project
,
format: :json
)
}
}
locale/gitlab.pot
View file @
245737fc
...
...
@@ -1315,9 +1315,6 @@ msgstr ""
msgid "A file with '%{file_name}' already exists in %{branch} branch"
msgstr ""
msgid "A fork is a copy of a project."
msgstr ""
msgid "A group is a collection of several projects"
msgstr ""
...
...
@@ -13306,6 +13303,9 @@ msgstr ""
msgid "ForkProject|Select a namespace"
msgstr ""
msgid "ForkProject|Select a namespace to fork the project"
msgstr ""
msgid "ForkProject|The project can be accessed by any logged in user."
msgstr ""
...
...
@@ -13324,9 +13324,6 @@ msgstr ""
msgid "ForkedFromProjectPath|Forked from an inaccessible project"
msgstr ""
msgid "Forking a repository allows you to make changes without affecting the original project."
msgstr ""
msgid "Forking in progress"
msgstr ""
...
...
@@ -26879,9 +26876,6 @@ msgstr ""
msgid "Select a label"
msgstr ""
msgid "Select a namespace to fork the project"
msgstr ""
msgid "Select a new namespace"
msgstr ""
...
...
spec/frontend/pages/projects/forks/new/components/app_spec.js
View file @
245737fc
import
{
shallowMount
}
from
'
@vue/test-utils
'
;
import
App
from
'
~/pages/projects/forks/new/components/app.vue
'
;
jest
.
mock
(
'
~/flash
'
);
describe
(
'
App component
'
,
()
=>
{
let
wrapper
;
const
DEFAULT_PROPS
=
{
forkIllustration
:
'
illustrations/project-create-new-sm.svg
'
,
endpoint
:
'
/some/project-full-path/-/forks/new.json
'
,
newGroupPath
:
'
some/groups/path
'
,
projectFullPath
:
'
/some/project-full-path
'
,
visibilityHelpPath
:
'
some/visibility/help/path
'
,
projectId
:
'
10
'
,
projectName
:
'
Project Name
'
,
projectPath
:
'
project-name
'
,
...
...
spec/frontend/pages/projects/forks/new/components/fork_form_spec.js
View file @
245737fc
...
...
@@ -30,9 +30,7 @@ describe('ForkForm component', () => {
const
DEFAULT_PROPS
=
{
endpoint
:
'
/some/project-full-path/-/forks/new.json
'
,
newGroupPath
:
'
some/groups/path
'
,
projectFullPath
:
'
/some/project-full-path
'
,
visibilityHelpPath
:
'
some/visibility/help/path
'
,
projectId
:
'
10
'
,
projectName
:
'
Project Name
'
,
projectPath
:
'
project-name
'
,
...
...
@@ -46,6 +44,10 @@ describe('ForkForm component', () => {
const
createComponent
=
(
props
=
{},
data
=
{})
=>
{
wrapper
=
shallowMount
(
ForkForm
,
{
provide
:
{
newGroupPath
:
'
some/groups/path
'
,
visibilityHelpPath
:
'
some/visibility/help/path
'
,
},
propsData
:
{
...
DEFAULT_PROPS
,
...
props
,
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment