# HG changeset patch # User Mads Kiilerich # Date 1670720708 -3600 # Node ID d00371a768c91915cab2afd6b49f620e97f53e87 # Parent 1d1fe8c2ef57a95f23883f7327e648382cfd0e99 templates: align forms for repo creation and repo settings 99% whitespace changes and reordering. diff -r 1d1fe8c2ef57 -r d00371a768c9 kallithea/templates/admin/repos/repo_add_base.html --- a/kallithea/templates/admin/repos/repo_add_base.html Mon Dec 12 00:38:59 2022 +0100 +++ b/kallithea/templates/admin/repos/repo_add_base.html Sun Dec 11 02:05:08 2022 +0100 @@ -1,17 +1,22 @@ -## -*- coding: utf-8 -*- - ${h.form(url('repos'))} -
+
${h.text('repo_name',class_='form-control')}
-
+
+ +
+ ${h.select('repo_type','hg',c.backends,class_='form-control')} + ${_('Type of repository to create.')} +
+
+
- ${h.text('clone_uri',class_='form-control')} + ${h.text('clone_uri',class_='form-control', placeholder=_('Repository URL'))} ${_('Optional: URL of a remote repository. If set, the repository will be created as a clone from this URL.')} @@ -39,16 +44,9 @@
- -
- ${h.select('repo_type','hg',c.backends,class_='form-control')} - ${_('Type of repository to create.')} -
-
-
- ${h.select('repo_landing_rev','',c.landing_revs,class_='form-control')} + ${h.select('repo_landing_rev',None,c.landing_revs,class_='form-control')} ${_('Default revision for files page, downloads, full text search index and readme generation')}
@@ -64,10 +62,19 @@ ${h.submit('add',_('Add'),class_="btn btn-default")}
-
+ +${h.end_form()} + -${h.end_form()} diff -r 1d1fe8c2ef57 -r d00371a768c9 kallithea/templates/admin/repos/repo_edit_settings.html --- a/kallithea/templates/admin/repos/repo_edit_settings.html Mon Dec 12 00:38:59 2022 +0100 +++ b/kallithea/templates/admin/repos/repo_edit_settings.html Sun Dec 11 02:05:08 2022 +0100 @@ -1,115 +1,112 @@ ${h.form(url('update_repo', repo_name=c.repo_info.repo_name))}
-
- -
- ${h.text('repo_name',class_='form-control')} -
+
+ +
+ ${h.text('repo_name',class_='form-control')} +
+
+
+ +
+ ${h.text('permanent_url',class_='form-control', readonly='1')} + + ${_('''In case this repository is renamed or moved into another group the repository URL changes. + Using the above permanent URL guarantees that this repository always will be accessible on that URL. + This is useful for CI systems, or any other cases that you need to hardcode the URL into a 3rd party service.''')} + +
+
+
+ +
+ ${h.text('clone_uri',class_='form-control', placeholder=_('Repository URL'))} + ${h.hidden('clone_uri_hidden', c.repo_info.clone_uri_hidden)} + + ${_('Optional: URL of a remote repository. If set, the repository can be pulled from this URL.')} + +
+
+
+ +
+ ${h.textarea('repo_description',class_='form-control')} + ${_('Keep it short and to the point. Use a README file for longer descriptions.')} +
+
+
+ +
+ ${h.select('repo_group',None,c.repo_groups,class_='form-control')} + ${_('Optionally select a group to put this repository into.')}
+
+
+ +
+ ${h.select('repo_landing_rev',None,c.landing_revs,class_='form-control')} + ${_('Default revision for files page, downloads, full text search index and readme generation')} +
+
+
+ +
+ ${h.text('owner',class_='form-control', placeholder=_('Type name of user'))} + ${_('Change owner of this repository.')} +
+
+
+ +
+ ${h.checkbox('repo_private',value="True")} + ${_('Private repositories are only visible to people explicitly added as collaborators.')} +
+
+
+ +
+ ${h.checkbox('repo_enable_statistics',value="True")} + ${_('Enable statistics window on summary page.')} +
+
+
+ +
+ ${h.checkbox('repo_enable_downloads',value="True")} + ${_('Enable download menu on summary page.')} +
+
+ + %if c.visual.repository_fields: + ## EXTRA FIELDS + %for field in c.repo_fields:
- -
- ${h.text('permanent_url',class_='form-control', readonly='1')} - - ${_('''In case this repository is renamed or moved into another group the repository URL changes. - Using the above permanent URL guarantees that this repository always will be accessible on that URL. - This is useful for CI systems, or any other cases that you need to hardcode the URL into a 3rd party service.''')} - -
-
-
- +
-
- ${h.text('clone_uri',class_='form-control', placeholder=_('Repository URL'))} - ${h.hidden('clone_uri_hidden', c.repo_info.clone_uri_hidden)} -
- - ${_('Optional: URL of a remote repository. If set, the repository can be pulled from this URL.')} - -
-
-
- -
- ${h.select('repo_group','',c.repo_groups,class_='form-control')} - ${_('Optionally select a group to put this repository into.')} -
-
-
- -
- ${h.select('repo_landing_rev','',c.landing_revs,class_='form-control')} - ${_('Default revision for files page, downloads, whoosh and readme')} -
-
-
- -
- ${h.text('owner',class_='form-control', placeholder=_('Type name of user'))} - ${_('Change owner of this repository.')} + ${h.text(field.field_key_prefixed, field.field_value, class_='form-control')} + %if field.field_desc: + ${field.field_desc} + %endif
-
- -
- ${h.textarea('repo_description',class_='form-control')} - ${_('Keep it short and to the point. Use a README file for longer descriptions.')} -
-
- -
- -
- ${h.checkbox('repo_private',value="True")} - ${_('Private repositories are only visible to people explicitly added as collaborators.')} -
-
-
- -
- ${h.checkbox('repo_enable_statistics',value="True")} - ${_('Enable statistics window on summary page.')} -
+ %endfor + %endif +
+
+ ${h.submit('save',_('Save'),class_="btn btn-default")} + ${h.reset('reset',_('Reset'),class_="btn btn-default")}
-
- -
- ${h.checkbox('repo_enable_downloads',value="True")} - ${_('Enable download menu on summary page.')} -
-
- - %if c.visual.repository_fields: - ## EXTRA FIELDS - %for field in c.repo_fields: -
- -
- ${h.text(field.field_key_prefixed, field.field_value, class_='form-control')} - %if field.field_desc: - ${field.field_desc} - %endif -
-
- %endfor - %endif -
-
- ${h.submit('save',_('Save'),class_="btn btn-default")} - ${h.reset('reset',_('Reset'),class_="btn btn-default")} -
-
+
- ${h.end_form()} +${h.end_form()}