diff options
author | Larry Li <larryli@qq.com> | 2016-03-28 12:39:17 +0800 |
---|---|---|
committer | Larry Li <larryli@qq.com> | 2016-03-28 12:39:17 +0800 |
commit | 44d920605c4d857d4e494e818042a0251e9ee203 (patch) | |
tree | d672721562140801486f6a0641e1eee32088a918 | |
parent | b0a44cb0c867b2eec84ba8bb4ac303d829848195 (diff) | |
download | gitlab-ce-44d920605c4d857d4e494e818042a0251e9ee203.tar.gz |
完成 8.6 分支初步翻译v8.6.0.zh1
Signed-off-by: Larry Li <larryli@qq.com>
159 files changed, 1399 insertions, 1422 deletions
diff --git a/app/assets/javascripts/calendar.js.coffee b/app/assets/javascripts/calendar.js.coffee index d80e0e716ce..70e921be69a 100644 --- a/app/assets/javascripts/calendar.js.coffee +++ b/app/assets/javascripts/calendar.js.coffee @@ -2,10 +2,13 @@ class @Calendar constructor: (timestamps, starting_year, starting_month, calendar_activities_path) -> cal = new CalHeatMap() cal.init - itemName: ["contribution"] + itemName: ["次贡献", "次贡献"] data: timestamps start: new Date(starting_year, starting_month) - domainLabelFormat: "%b" + domainLabelFormat: "%-m 月" + subDomainDateFormat: "%Y-%m-%d" + subDomainTitleFormat: + filled: "{date}:{count} {name}" id: "cal-heatmap" domain: "month" subDomain: "day" diff --git a/app/assets/javascripts/star.js.coffee b/app/assets/javascripts/star.js.coffee index f27780dda93..7335d90d172 100644 --- a/app/assets/javascripts/star.js.coffee +++ b/app/assets/javascripts/star.js.coffee @@ -8,15 +8,15 @@ class @Star toggleStar = (isStarred) -> $this.parent().find('.star-count').text data.star_count if isStarred - $starSpan.removeClass('starred').text 'Star' + $starSpan.removeClass('starred').text '星标' $starIcon.removeClass('fa-star').addClass 'fa-star-o' else - $starSpan.addClass('starred').text 'Unstar' + $starSpan.addClass('starred').text '取消星标' $starIcon.removeClass('fa-star-o').addClass 'fa-star' return toggleStar $starSpan.hasClass('starred') return ).on 'ajax:error', (e, xhr, status, error) -> - new Flash('Star toggle failed. Try again later.', 'alert') + new Flash('星标切换失败,请稍后重试。', 'alert') return diff --git a/app/assets/stylesheets/pages/ui_dev_kit.scss b/app/assets/stylesheets/pages/ui_dev_kit.scss index 587bd6a1e8a..95cd923293f 100644 --- a/app/assets/stylesheets/pages/ui_dev_kit.scss +++ b/app/assets/stylesheets/pages/ui_dev_kit.scss @@ -6,7 +6,7 @@ .example { &:before { - content: "Example"; + content: "示例"; color: #bbb; } diff --git a/app/controllers/groups_controller.rb b/app/controllers/groups_controller.rb index 55a80d7643c..77a9f9b590c 100644 --- a/app/controllers/groups_controller.rb +++ b/app/controllers/groups_controller.rb @@ -30,7 +30,7 @@ class GroupsController < Groups::ApplicationController @group = Groups::CreateService.new(current_user, group_params).execute if @group.persisted? - redirect_to @group, notice: "Group '#{@group.name}' was successfully created." + redirect_to @group, notice: "群组 '#{@group.name}' 创建成功。" else render action: "new" end @@ -82,7 +82,7 @@ class GroupsController < Groups::ApplicationController def update if Groups::UpdateService.new(@group, current_user, group_params).execute - redirect_to edit_group_path(@group), notice: "Group '#{@group.name}' was successfully updated." + redirect_to edit_group_path(@group), notice: "群组 '#{@group.name}' 更新成功。" else render action: "edit" end diff --git a/app/controllers/projects/issues_controller.rb b/app/controllers/projects/issues_controller.rb index ce417ee637f..9a6e8871e40 100644 --- a/app/controllers/projects/issues_controller.rb +++ b/app/controllers/projects/issues_controller.rb @@ -117,7 +117,7 @@ class Projects::IssuesController < Projects::ApplicationController def bulk_update result = Issues::BulkUpdateService.new(project, current_user, bulk_update_params).execute - redirect_back_or_default(default: { action: 'index' }, options: { notice: "#{result[:count]} issues updated" }) + redirect_back_or_default(default: { action: 'index' }, options: { notice: "#{result[:count]} 问题已更新" }) end def closed_by_merge_requests diff --git a/app/helpers/application_helper.rb b/app/helpers/application_helper.rb index e32f94929e5..c8af42cbb1f 100644 --- a/app/helpers/application_helper.rb +++ b/app/helpers/application_helper.rb @@ -201,11 +201,11 @@ module ApplicationHelper return if object.updated_at == object.created_at content_tag :small, class: "edited-text" do - output = content_tag(:span, "Edited ") + output = content_tag(:span, "编辑时间 ") output << time_ago_with_tooltip(object.updated_at, placement: placement, html_class: html_class) if include_author && object.updated_by && object.updated_by != object.author - output << content_tag(:span, " by ") + output << content_tag(:span, " 由 ") output << link_to_member(object.project, object.updated_by, avatar: false, author_class: nil) end diff --git a/app/helpers/ci_status_helper.rb b/app/helpers/ci_status_helper.rb index 724146443b8..b423f4f11e0 100644 --- a/app/helpers/ci_status_helper.rb +++ b/app/helpers/ci_status_helper.rb @@ -46,11 +46,28 @@ module CiStatusHelper icon(icon_name + ' fw') end + def ci_status_zh(status) + case status + when 'pending' + '排队' + when 'running' + '运行' + when 'success' + '成功' + when 'failed' + '失败' + when 'canceled' + '取消' + else + '未知' + end + end + def render_ci_status(ci_commit, tooltip_placement: 'auto left') link_to ci_status_icon(ci_commit), ci_status_path(ci_commit), class: "ci-status-link ci-status-icon-#{ci_commit.status.dasherize}", - title: "Build #{ci_status_label(ci_commit)}", + title: "构建状态:#{ci_status_label(ci_commit)}", data: { toggle: 'tooltip', placement: tooltip_placement } end diff --git a/app/helpers/issues_helper.rb b/app/helpers/issues_helper.rb index cd630bb6973..4a52db4e8fb 100644 --- a/app/helpers/issues_helper.rb +++ b/app/helpers/issues_helper.rb @@ -64,7 +64,7 @@ module IssuesHelper current_user.can?(ability, project) end - no_project = OpenStruct.new(id: 0, name_with_namespace: 'No project') + no_project = OpenStruct.new(id: 0, name_with_namespace: '没有项目') projects.unshift(no_project) projects.delete(issuable.project) diff --git a/app/helpers/search_helper.rb b/app/helpers/search_helper.rb index bb61fc1d5c1..f28ac1e3278 100644 --- a/app/helpers/search_helper.rb +++ b/app/helpers/search_helper.rb @@ -24,25 +24,25 @@ module SearchHelper # Autocomplete results for various settings pages def default_autocomplete [ - { label: "Profile settings", url: profile_path }, - { label: "SSH Keys", url: profile_keys_path }, - { label: "Dashboard", url: root_path }, - { label: "Admin Section", url: admin_root_path }, + { label: "个人资料设置", url: profile_path }, + { label: "SSH 密钥", url: profile_keys_path }, + { label: "仪表盘", url: root_path }, + { label: "管理后台", url: admin_root_path }, ] end # Autocomplete results for internal help pages def help_autocomplete [ - { label: "help: API Help", url: help_page_path("api", "README") }, - { label: "help: Markdown Help", url: help_page_path("markdown", "markdown") }, - { label: "help: Permissions Help", url: help_page_path("permissions", "permissions") }, - { label: "help: Public Access Help", url: help_page_path("public_access", "public_access") }, - { label: "help: Rake Tasks Help", url: help_page_path("raketasks", "README") }, - { label: "help: SSH Keys Help", url: help_page_path("ssh", "README") }, - { label: "help: System Hooks Help", url: help_page_path("system_hooks", "system_hooks") }, - { label: "help: Webhooks Help", url: help_page_path("web_hooks", "web_hooks") }, - { label: "help: Workflow Help", url: help_page_path("workflow", "README") }, + { label: "帮助: API 帮助", url: help_page_path("api", "README") }, + { label: "帮助: Markdown 帮助", url: help_page_path("markdown", "markdown") }, + { label: "帮助: 权限帮助", url: help_page_path("permissions", "permissions") }, + { label: "帮助: 公开访问帮助", url: help_page_path("public_access", "public_access") }, + { label: "帮助: Rake 任务帮助", url: help_page_path("raketasks", "README") }, + { label: "帮助: SSH 密钥帮助", url: help_page_path("ssh", "README") }, + { label: "帮助: 系统钩子帮助", url: help_page_path("system_hooks", "system_hooks") }, + { label: "帮助: Web 钩子帮助", url: help_page_path("web_hooks", "web_hooks") }, + { label: "帮助: 工作流帮助", url: help_page_path("workflow", "README") }, ] end diff --git a/app/helpers/visibility_level_helper.rb b/app/helpers/visibility_level_helper.rb index 0bb3c1e1c0f..369210588c9 100644 --- a/app/helpers/visibility_level_helper.rb +++ b/app/helpers/visibility_level_helper.rb @@ -41,11 +41,11 @@ module VisibilityLevelHelper def group_visibility_level_description(level) case level when Gitlab::VisibilityLevel::PRIVATE - "The group and its projects can only be viewed by members." + "该群组和其项目只有其成员能以看到。" when Gitlab::VisibilityLevel::INTERNAL - "The group and any internal projects can be viewed by any logged in user." + "该群组和其内部项目只有已登录用户能看到。" when Gitlab::VisibilityLevel::PUBLIC - "The group and any public projects can be viewed without any authentication." + "该群组和其公开项目可以被任何授权的用户看到。" end end diff --git a/app/models/merge_request.rb b/app/models/merge_request.rb index c527bbcf6ea..3ad42c03b0b 100644 --- a/app/models/merge_request.rb +++ b/app/models/merge_request.rb @@ -503,14 +503,18 @@ class MergeRequest < ActiveRecord::Base def state_human_name if merged? - "Merged" + "已合并" elsif closed? - "Closed" + "已关闭" else - "Open" + "未关闭" end end + def zh_name + '合并请求' + end + def state_icon_name if merged? "check" diff --git a/app/models/milestone.rb b/app/models/milestone.rb index b8bb94d6366..d8a09f5f7a4 100644 --- a/app/models/milestone.rb +++ b/app/models/milestone.rb @@ -18,9 +18,9 @@ class Milestone < ActiveRecord::Base # Represents a "No Milestone" state used for filtering Issues and Merge # Requests that have no milestone assigned. MilestoneStruct = Struct.new(:title, :name, :id) - None = MilestoneStruct.new('No Milestone', 'No Milestone', 0) - Any = MilestoneStruct.new('Any Milestone', '', -1) - Upcoming = MilestoneStruct.new('Upcoming', '#upcoming', -2) + None = MilestoneStruct.new('无里程碑', 'No Milestone', 0) + Any = MilestoneStruct.new('任何里程碑', '', -1) + Upcoming = MilestoneStruct.new('即将到来', '#upcoming', -2) include InternalId include Sortable diff --git a/app/views/abuse_reports/new.html.haml b/app/views/abuse_reports/new.html.haml index 3bc1b24b5e2..26b17421773 100644 --- a/app/views/abuse_reports/new.html.haml +++ b/app/views/abuse_reports/new.html.haml @@ -1,6 +1,6 @@ -- page_title "Report abuse" -%h3.page-title Report abuse -%p Please use this form to report users who create spam issues, comments or behave inappropriately. +- page_title "滥用举报" +%h3.page-title 滥用举报 +%p 请使用此表单举报创建垃圾问题和评论或其他不当使用的用户。 %hr = form_for @abuse_report, html: { class: 'form-horizontal js-quick-submit js-requires-input'} do |f| = f.hidden_field :user_id @@ -9,16 +9,16 @@ - @abuse_report.errors.full_messages.each do |msg| %p= msg .form-group - = f.label :user_id, class: 'control-label' + = f.label :user_id, '用户 ID', class: 'control-label' .col-sm-10 - name = "#{@abuse_report.user.name} (@#{@abuse_report.user.username})" = text_field_tag :user_name, name, class: "form-control", readonly: true .form-group - = f.label :message, class: 'control-label' + = f.label :message, '信息', class: 'control-label' .col-sm-10 = f.text_area :message, class: "form-control", rows: 2, required: true, value: sanitize(@ref_url) .help-block - Explain the problem with this user. If appropriate, provide a link to the relevant issue or comment. + 详细描述该用户的问题。如果可以,请提供相关问题或评论的链接地址。 .form-actions - = f.submit "Send report", class: "btn btn-create" + = f.submit "发送举报", class: "btn btn-create" diff --git a/app/views/admin/application_settings/_form.html.haml b/app/views/admin/application_settings/_form.html.haml index 4d4d9723b78..cbd7490b202 100644 --- a/app/views/admin/application_settings/_form.html.haml +++ b/app/views/admin/application_settings/_form.html.haml @@ -6,232 +6,230 @@ %p= msg %fieldset - %legend Visibility and Access Controls + %legend 可见性与访问控制 .form-group - = f.label :default_branch_protection, class: 'control-label col-sm-2' + = f.label :default_branch_protection, '默认保护分支', class: 'control-label col-sm-2' .col-sm-10 = f.select :default_branch_protection, options_for_select(Gitlab::Access.protection_options, @application_setting.default_branch_protection), {}, class: 'form-control' .form-group.project-visibility-level-holder - = f.label :default_project_visibility, class: 'control-label col-sm-2' + = f.label :default_project_visibility, '默认项目可见度', class: 'control-label col-sm-2' .col-sm-10 = render('shared/visibility_radios', model_method: :default_project_visibility, form: f, selected_level: @application_setting.default_project_visibility, form_model: Project.new) .form-group.project-visibility-level-holder - = f.label :default_snippet_visibility, class: 'control-label col-sm-2' + = f.label :default_snippet_visibility, '默认代码片段可见度', class: 'control-label col-sm-2' .col-sm-10 = render('shared/visibility_radios', model_method: :default_snippet_visibility, form: f, selected_level: @application_setting.default_snippet_visibility, form_model: ProjectSnippet.new) .form-group.group-visibility-level-holder - = f.label :default_group_visibility, class: 'control-label col-sm-2' + = f.label :default_group_visibility, '默认群组可见度', class: 'control-label col-sm-2' .col-sm-10 = render('shared/visibility_radios', model_method: :default_group_visibility, form: f, selected_level: @application_setting.default_group_visibility, form_model: Group.new) .form-group - = f.label :restricted_visibility_levels, class: 'control-label col-sm-2' + = f.label :restricted_visibility_levels, '限制的可见等级', class: 'control-label col-sm-2' .col-sm-10 - data_attrs = { toggle: 'buttons' } .btn-group{ data: data_attrs } - restricted_level_checkboxes('restricted-visibility-help').each do |level| = level - %span.help-block#restricted-visibility-help Selected levels cannot be used by non-admin users for projects or snippets + %span.help-block#restricted-visibility-help 选择的等级将无法用于非管理用户的项目和代码片段 .form-group - = f.label :import_sources, class: 'control-label col-sm-2' + = f.label :import_sources, '导入来源', class: 'control-label col-sm-2' .col-sm-10 - data_attrs = { toggle: 'buttons' } .btn-group{ data: data_attrs } - import_sources_checkboxes('import-sources-help').each do |source| = source %span.help-block#import-sources-help - Enabled sources for code import during project creation. OmniAuth must be configured for GitHub + 项目创建时可用的代码导入来源。GitHub = link_to "(?)", help_page_path("integration", "github") - , Bitbucket + 、Bitbucket = link_to "(?)", help_page_path("integration", "bitbucket") - and GitLab.com + 和 GitLab.com = link_to "(?)", help_page_path("integration", "gitlab") + 必须先配置好 OmniAuth。 .form-group .col-sm-offset-2.col-sm-10 .checkbox = f.label :version_check_enabled do = f.check_box :version_check_enabled - Version check enabled + 开启版本检查 .form-group .col-sm-offset-2.col-sm-10 .checkbox = f.label :email_author_in_body do = f.check_box :email_author_in_body - Include author name in notification email body + 在通知邮件正文包含作者名称 .help-block - Some email servers do not support overriding the email sender name. - Enable this option to include the name of the author of the issue, - merge request or comment in the email body instead. + 有些电子邮件服务器不支持重写邮件发送人名称功能。 + 开启此选项将在邮件正文中提供问题、合并请求和评论作者的名称, + 否则只试图重写邮件发送人为作者。 .form-group - = f.label :admin_notification_email, class: 'control-label col-sm-2' + = f.label :admin_notification_email, '管理员通知邮箱', class: 'control-label col-sm-2' .col-sm-10 = f.text_field :admin_notification_email, class: 'form-control' .help-block - Abuse reports will be sent to this address if it is set. Abuse reports are always available in the admin area. + 滥用举报会使用此邮箱发送邮件。滥用举报总是在管理区域可用。 %fieldset - %legend Account and Limit Settings + %legend 账户与限制设置 .form-group .col-sm-offset-2.col-sm-10 .checkbox = f.label :gravatar_enabled do = f.check_box :gravatar_enabled - Gravatar enabled + 开启 Gravatar 头像 .form-group .col-sm-offset-2.col-sm-10 .checkbox = f.label :twitter_sharing_enabled do = f.check_box :twitter_sharing_enabled, :'aria-describedby' => 'twitter_help_block' - Twitter enabled - %span.help-block#twitter_help_block Show users a button to share their newly created public or internal projects on twitter + 开启推特 + %span.help-block#twitter_help_block 显示分享按钮,用于分享用户最新创建的公开或内部项目到推特 .form-group - = f.label :default_projects_limit, class: 'control-label col-sm-2' + = f.label :default_projects_limit, '默认项目限制', class: 'control-label col-sm-2' .col-sm-10 = f.number_field :default_projects_limit, class: 'form-control' .form-group - = f.label :max_attachment_size, 'Maximum attachment size (MB)', class: 'control-label col-sm-2' + = f.label :max_attachment_size, '最大附件大小 (MB)', class: 'control-label col-sm-2' .col-sm-10 = f.number_field :max_attachment_size, class: 'form-control' .form-group - = f.label :session_expire_delay, 'Session duration (minutes)', class: 'control-label col-sm-2' + = f.label :session_expire_delay, '会话保留时间 (分钟)', class: 'control-label col-sm-2' .col-sm-10 = f.number_field :session_expire_delay, class: 'form-control' - %span.help-block#session_expire_delay_help_block GitLab restart is required to apply changes + %span.help-block#session_expire_delay_help_block 要应用此变更需要重启 GitLab .form-group - = f.label :user_oauth_applications, 'User OAuth applications', class: 'control-label col-sm-2' + = f.label :user_oauth_applications, '用户 OAuth 应用', class: 'control-label col-sm-2' .col-sm-10 .checkbox = f.label :user_oauth_applications do = f.check_box :user_oauth_applications - Allow users to register any application to use GitLab as an OAuth provider + 允许用户注册使用 GitLab 为 OAuth 提供者的应用 %fieldset - %legend Sign-in Restrictions + %legend 登入限制 .form-group .col-sm-offset-2.col-sm-10 .checkbox = f.label :signup_enabled do = f.check_box :signup_enabled - Sign-up enabled + 开启注册 .form-group .col-sm-offset-2.col-sm-10 .checkbox = f.label :signin_enabled do = f.check_box :signin_enabled - Sign-in enabled + 开启登入 .form-group - = f.label :two_factor_authentication, 'Two-factor authentication', class: 'control-label col-sm-2' + = f.label :two_factor_authentication, '两步验证', class: 'control-label col-sm-2' .col-sm-10 .checkbox = f.label :require_two_factor_authentication do = f.check_box :require_two_factor_authentication - Require all users to setup Two-factor authentication + 强制全部用户设置两步验证 .form-group - = f.label :two_factor_authentication, 'Two-factor grace period (hours)', class: 'control-label col-sm-2' + = f.label :two_factor_authentication, '两步验证宽限期 (小时)', class: 'control-label col-sm-2' .col-sm-10 = f.number_field :two_factor_grace_period, min: 0, class: 'form-control', placeholder: '0' - .help-block Amount of time (in hours) that users are allowed to skip forced configuration of two-factor authentication + .help-block 允许用户跳过强制两步验证配置的时间范围(小时) .form-group - = f.label :restricted_signup_domains, 'Restricted domains for sign-ups', class: 'control-label col-sm-2' + = f.label :restricted_signup_domains, '注册限制域名', class: 'control-label col-sm-2' .col-sm-10 = f.text_area :restricted_signup_domains_raw, placeholder: 'domain.com', class: 'form-control' - .help-block Only users with e-mail addresses that match these domain(s) will be able to sign-up. Wildcards allowed. Use separate lines for multiple entries. Ex: domain.com, *.domain.com + .help-block 用户使用的电子邮箱地址后缀必须匹配这些域名才能注册。泛域名可用。使用英文逗号分隔多个域名。比如:domain.com, *.domain.com .form-group - = f.label :home_page_url, 'Home page URL', class: 'control-label col-sm-2' + = f.label :home_page_url, '主页链接', class: 'control-label col-sm-2' .col-sm-10 = f.text_field :home_page_url, class: 'form-control', placeholder: 'http://company.example.com', :'aria-describedby' => 'home_help_block' - %span.help-block#home_help_block We will redirect non-logged in users to this page + %span.help-block#home_help_block 未登录用户将会重定向到此页面 .form-group - = f.label :after_sign_out_path, class: 'control-label col-sm-2' + = f.label :after_sign_out_path, '退出后路径', class: 'control-label col-sm-2' .col-sm-10 = f.text_field :after_sign_out_path, class: 'form-control', placeholder: 'http://company.example.com', :'aria-describedby' => 'after_sign_out_path_help_block' - %span.help-block#after_sign_out_path_help_block We will redirect users to this page after they sign out + %span.help-block#after_sign_out_path_help_block 用户退出后将会重定向到此页面 .form-group - = f.label :sign_in_text, class: 'control-label col-sm-2' + = f.label :sign_in_text, '登入文字', class: 'control-label col-sm-2' .col-sm-10 = f.text_area :sign_in_text, class: 'form-control', rows: 4 - .help-block Markdown enabled + .help-block Markdown 可用 .form-group - = f.label :help_page_text, class: 'control-label col-sm-2' + = f.label :help_page_text, '帮助页面文字', class: 'control-label col-sm-2' .col-sm-10 = f.text_area :help_page_text, class: 'form-control', rows: 4 - .help-block Markdown enabled + .help-block Markdown 可用 %fieldset - %legend Continuous Integration + %legend 持续集成 .form-group .col-sm-offset-2.col-sm-10 .checkbox = f.label :shared_runners_enabled do = f.check_box :shared_runners_enabled - Enable shared runners for new projects + 为新项目默认开启共享 runner .form-group - = f.label :max_artifacts_size, 'Maximum artifacts size (MB)', class: 'control-label col-sm-2' + = f.label :max_artifacts_size, '最大附件大小 (MB)', class: 'control-label col-sm-2' .col-sm-10 = f.number_field :max_artifacts_size, class: 'form-control' %fieldset - %legend Metrics + %legend 度量 %p - These settings require a restart to take effect. + 这些设置需要重启才能生效。 .form-group .col-sm-offset-2.col-sm-10 .checkbox = f.label :metrics_enabled do = f.check_box :metrics_enabled - Enable InfluxDB Metrics + 开启 InfluxDB 度量 .form-group - = f.label :metrics_host, 'InfluxDB host', class: 'control-label col-sm-2' + = f.label :metrics_host, 'InfluxDB 主机', class: 'control-label col-sm-2' .col-sm-10 = f.text_field :metrics_host, class: 'form-control', placeholder: 'influxdb.example.com' .form-group - = f.label :metrics_port, 'InfluxDB port', class: 'control-label col-sm-2' + = f.label :metrics_port, 'InfluxDB 端口', class: 'control-label col-sm-2' .col-sm-10 = f.text_field :metrics_port, class: 'form-control', placeholder: '8089' .help-block - The UDP port to use for connecting to InfluxDB. InfluxDB requires that - your server configuration specifies a database to store data in when - sending messages to this port, without it metrics data will not be - saved. + 用于连接到 InfluxDB 的 UDP 端口。 + InfluxDB 需要您的服务器配置数据库用于存储发送到此端口的消息, + 如果没有配置,度量数据将不会保存。 .form-group - = f.label :metrics_pool_size, 'Connection pool size', class: 'control-label col-sm-2' + = f.label :metrics_pool_size, '连接池大小', class: 'control-label col-sm-2' .col-sm-10 = f.number_field :metrics_pool_size, class: 'form-control' .help-block - The amount of InfluxDB connections to open. Connections are opened - lazily. Users using multi-threaded application servers should ensure - enough connections are available (at minimum the amount of application - server threads). + 可用的 InfluxDB 连接数。 + 连接是延迟加载的,即只有需要的时候才会打开。 + 使用多线程应用服务器的用户应确保有足够的连接可用 + (可用数至少是应用服务器线程的数量)。 .form-group - = f.label :metrics_timeout, 'Connection timeout', class: 'control-label col-sm-2' + = f.label :metrics_timeout, '连接超时', class: 'control-label col-sm-2' .col-sm-10 = f.number_field :metrics_timeout, class: 'form-control' .help-block - The amount of seconds after which an InfluxDB connection will time - out. + InfluxDB 连接超时时间,单位秒。 .form-group - = f.label :metrics_method_call_threshold, 'Method Call Threshold (ms)', class: 'control-label col-sm-2' + = f.label :metrics_method_call_threshold, '方法调用阈值 (毫秒)', class: 'control-label col-sm-2' .col-sm-10 = f.number_field :metrics_method_call_threshold, class: 'form-control' .help-block - A method call is only tracked when it takes longer to complete than - the given amount of milliseconds. + 只有超过此给定的毫秒阀值后完成的方法调用才会被跟踪。 .form-group - = f.label :metrics_sample_interval, 'Sampler Interval (sec)', class: 'control-label col-sm-2' + = f.label :metrics_sample_interval, '采样间隔 (秒)', class: 'control-label col-sm-2' .col-sm-10 = f.number_field :metrics_sample_interval, class: 'form-control' .help-block - The sampling interval in seconds. Sampled data includes memory usage, - retained Ruby objects, file descriptors and so on. + 以秒为单位的采样间隔。 + 采样数据包括内存使用、保留的 Ruby 对象、文件描述符等。 %fieldset - %legend Spam and Anti-bot Protection + %legend Spam 与防机器人保护 .form-group .col-sm-offset-2.col-sm-10 .checkbox = f.label :recaptcha_enabled do = f.check_box :recaptcha_enabled - Enable reCAPTCHA + 开启 reCAPTCHA %span.help-block#recaptcha_help_block Helps prevent bots from creating accounts .form-group @@ -239,7 +237,7 @@ .col-sm-10 = f.text_field :recaptcha_site_key, class: 'form-control' .help-block - Generate site and private keys at + 在后面的网址生成网站密钥 (Site Key) 和私钥 (Private Key): %a{ href: 'http://www.google.com/recaptcha', target: 'blank'} http://www.google.com/recaptcha .form-group diff --git a/app/views/admin/broadcast_messages/_form.html.haml b/app/views/admin/broadcast_messages/_form.html.haml index b748460a9f7..2615d70ca6f 100644 --- a/app/views/admin/broadcast_messages/_form.html.haml +++ b/app/views/admin/broadcast_messages/_form.html.haml @@ -1,7 +1,7 @@ .broadcast-message-preview{ style: broadcast_message_style(@broadcast_message) } = icon('bullhorn') .js-broadcast-message-preview - = render_broadcast_message(@broadcast_message.message.presence || "Your message here") + = render_broadcast_message(@broadcast_message.message.presence || "信息预览") = form_for [:admin, @broadcast_message], html: { class: 'broadcast-message-form form-horizontal js-quick-submit js-requires-input'} do |f| -if @broadcast_message.errors.any? @@ -9,32 +9,32 @@ - @broadcast_message.errors.full_messages.each do |msg| %p= msg .form-group - = f.label :message, class: 'control-label' + = f.label :message, "信息", class: 'control-label' .col-sm-10 = f.text_area :message, class: "form-control js-autosize", required: true, data: { preview_path: preview_admin_broadcast_messages_path } .form-group.js-toggle-colors-container .col-sm-10.col-sm-offset-2 - = link_to 'Customize colors', '#', class: 'js-toggle-colors-link' + = link_to '自定义颜色', '#', class: 'js-toggle-colors-link' .form-group.js-toggle-colors-container.hide - = f.label :color, "Background Color", class: 'control-label' + = f.label :color, "背景颜色", class: 'control-label' .col-sm-10 = f.color_field :color, class: "form-control" .form-group.js-toggle-colors-container.hide - = f.label :font, "Font Color", class: 'control-label' + = f.label :font, "字体颜色", class: 'control-label' .col-sm-10 = f.color_field :font, class: "form-control" .form-group - = f.label :starts_at, class: 'control-label' + = f.label :starts_at, "开始时间", class: 'control-label' .col-sm-10.datetime-controls = f.datetime_select :starts_at, {}, class: 'form-control form-control-inline' .form-group - = f.label :ends_at, class: 'control-label' + = f.label :ends_at, "结束时间", class: 'control-label' .col-sm-10.datetime-controls = f.datetime_select :ends_at, {}, class: 'form-control form-control-inline' .form-actions - if @broadcast_message.persisted? - = f.submit "Update broadcast message", class: "btn btn-create" + = f.submit "更新广播信息", class: "btn btn-create" - else - = f.submit "Add broadcast message", class: "btn btn-create" + = f.submit "增加广播信息", class: "btn btn-create" diff --git a/app/views/admin/broadcast_messages/index.html.haml b/app/views/admin/broadcast_messages/index.html.haml index dd9fe805820..663b6a93522 100644 --- a/app/views/admin/broadcast_messages/index.html.haml +++ b/app/views/admin/broadcast_messages/index.html.haml @@ -3,7 +3,7 @@ %h3.page-title 广播信息 %p.light - 广播信息会显示给所有用户,可以用于通知用户系统定期维护、近期计划升级等信息。 + 广播信息会显示给全部用户,可以用于通知用户系统定期维护、近期计划升级等信息。 = render 'form' diff --git a/app/views/admin/builds/_build.html.haml b/app/views/admin/builds/_build.html.haml index 6e254a50c2b..ef1672a5e74 100644 --- a/app/views/admin/builds/_build.html.haml +++ b/app/views/admin/builds/_build.html.haml @@ -6,9 +6,9 @@ %td.build-link - if can?(current_user, :read_build, build.project) = link_to namespace_project_build_url(build.project.namespace, build.project, build) do - %strong Build ##{build.id} + %strong 构建 ##{build.id} - else - %strong Build ##{build.id} + %strong 构建 ##{build.id} - if build.stuck? %i.fa.fa-warning.text-warning @@ -24,13 +24,13 @@ - if build.ref = link_to build.ref, namespace_project_commits_path(build.project.namespace, build.project, build.ref) - else - .light none + .light 无 %td - if build.try(:runner) = runner_link(build.runner) - else - .light none + .light 无 %td #{build.stage} / #{build.name} @@ -61,12 +61,12 @@ %td .pull-right - if can?(current_user, :read_build, project) && build.artifacts? - = link_to download_namespace_project_build_artifacts_path(build.project.namespace, build.project, build), title: 'Download artifacts' do + = link_to download_namespace_project_build_artifacts_path(build.project.namespace, build.project, build), title: '下载附件' do %i.fa.fa-download - if can?(current_user, :update_build, build.project) - if build.active? - = link_to cancel_namespace_project_build_path(build.project.namespace, build.project, build, return_to: request.original_url), method: :post, title: 'Cancel' do + = link_to cancel_namespace_project_build_path(build.project.namespace, build.project, build, return_to: request.original_url), method: :post, title: '取消' do %i.fa.fa-remove.cred - elsif defined?(allow_retry) && allow_retry && build.retryable? - = link_to retry_namespace_project_build_path(build.project.namespace, build.project, build, return_to: request.original_url), method: :post, title: 'Retry' do + = link_to retry_namespace_project_build_path(build.project.namespace, build.project, build, return_to: request.original_url), method: :post, title: '重试' do %i.fa.fa-repeat diff --git a/app/views/admin/builds/index.html.haml b/app/views/admin/builds/index.html.haml index 5ee960d2348..f2e546d6193 100644 --- a/app/views/admin/builds/index.html.haml +++ b/app/views/admin/builds/index.html.haml @@ -2,7 +2,7 @@ %ul.nav-links %li{class: ('active' if @scope.nil?)} = link_to admin_builds_path do - 所有 + 全部 %span.badge.js-totalbuilds-count= @all_builds.count(:id) %li{class: ('active' if @scope == 'running')} diff --git a/app/views/admin/groups/index.html.haml b/app/views/admin/groups/index.html.haml index d47460cecb9..9837f8f162d 100644 --- a/app/views/admin/groups/index.html.haml +++ b/app/views/admin/groups/index.html.haml @@ -59,7 +59,7 @@ = truncate group.description, length: 150 .clearfix %p.light - #{pluralize(group.members.size, '个用户', '个用户')}, #{pluralize(group.projects.count, '个项目', '个项目')} + #{pluralize(group.members.size, '个用户', '个用户')},#{pluralize(group.projects.count, '个项目', '个项目')} = paginate @groups, theme: "gitlab" diff --git a/app/views/admin/groups/show.html.haml b/app/views/admin/groups/show.html.haml index 1693e3afa63..27bc6b1334f 100644 --- a/app/views/admin/groups/show.html.haml +++ b/app/views/admin/groups/show.html.haml @@ -1,46 +1,46 @@ -- page_title @group.name, "Groups" +- page_title @group.name, "群组" %h3.page-title - Group: #{@group.name} + 群组:#{@group.name} = link_to edit_admin_group_path(@group), class: "btn pull-right" do %i.fa.fa-pencil-square-o - Edit + 编辑 %hr .row .col-md-6 .panel.panel-default .panel-heading - Group info: + 群组信息: %ul.well-list %li = image_tag group_icon(@group), class: "avatar s60" %li - %span.light Name: + %span.light 名称: %strong= @group.name %li - %span.light Path: + %span.light 路径: %strong = @group.path %li - %span.light Description: + %span.light 描述: %strong = @group.description %li - %span.light Visibility level: + %span.light 可见等级: %strong = visibility_level_label(@group.visibility_level) %li - %span.light Created on: + %span.light 创建时间: %strong = @group.created_at.to_s(:medium) .panel.panel-default .panel-heading %h3.panel-title - Projects + 项目 %span.badge #{@group.projects.count} %ul.well-list @@ -58,7 +58,7 @@ - if @group.shared_projects.any? .panel.panel-default .panel-heading - Projects shared with #{@group.name} + #{@group.name} 共享项目 %span.badge #{@group.shared_projects.count} %ul.well-list diff --git a/app/views/admin/labels/_label.html.haml b/app/views/admin/labels/_label.html.haml index f417b2e44a4..f827e4539c7 100644 --- a/app/views/admin/labels/_label.html.haml +++ b/app/views/admin/labels/_label.html.haml @@ -3,5 +3,5 @@ = render_colored_label(label, tooltip: false) = markdown(label.description, pipeline: :single_line) .pull-right - = link_to 'Edit', edit_admin_label_path(label), class: 'btn btn-sm' - = link_to 'Delete', admin_label_path(label), class: 'btn btn-sm btn-remove remove-row', method: :delete, remote: true, data: {confirm: "Delete this label? Are you sure?"} + = link_to '编辑', edit_admin_label_path(label), class: 'btn btn-sm' + = link_to '删除', admin_label_path(label), class: 'btn btn-sm btn-remove remove-row', method: :delete, remote: true, data: {confirm: "确定要删除此标记么?"} diff --git a/app/views/admin/projects/show.html.haml b/app/views/admin/projects/show.html.haml index 2585f957bf7..5de2f2cb3d9 100644 --- a/app/views/admin/projects/show.html.haml +++ b/app/views/admin/projects/show.html.haml @@ -23,7 +23,7 @@ - else 全局 %li - %span.light 所有者: + %span.light 拥有者: %strong - if @project.owner = link_to @project.owner_name, [:admin, @project.owner] @@ -50,32 +50,32 @@ = link_to @project.ssh_url_to_repo, project_path(@project) - if @project.repository.exists? %li - %span.light fs: + %span.light 文件系统: %strong = @project.repository.path_to_repo %li - %span.light Size + %span.light 大小 %strong = repository_size(@project) %li - %span.light last commit: + %span.light 最后提交: %strong = last_commit(@project) - else %li - %span.light repository: + %span.light 版本库: %strong.cred - does not exist + 不存在 - if @project.archived? %li - %span.light archived: - %strong repository is read-only + %span.light 已归档: + %strong 版本库只读 %li - %span.light access: + %span.light 访问: %strong %span{ class: visibility_level_color(@project.visibility_level) } = visibility_level_icon(@project.visibility_level) @@ -133,7 +133,7 @@ (invited) .pull-right - if project_member.owner? - %span.light 所有者 + %span.light 拥有者 - else %span.light= project_member.human_access = link_to namespace_project_project_member_path(@project.namespace, @project, project_member), data: { confirm: remove_from_project_team_message(@project, project_member)}, method: :delete, remote: true, class: "btn btn-sm btn-remove" do diff --git a/app/views/admin/runners/index.html.haml b/app/views/admin/runners/index.html.haml index 61432db43c9..9a5cdf283f8 100644 --- a/app/views/admin/runners/index.html.haml +++ b/app/views/admin/runners/index.html.haml @@ -29,7 +29,7 @@ %ul %li %span.label.label-success 共享的 - \- 会运行所有未特殊指定项目的构建 + \- 会运行全部未特殊指定项目的构建 %li %span.label.label-info 特定的 \- 只运行被特殊指定到该 runner 的项目的构建 diff --git a/app/views/admin/runners/show.html.haml b/app/views/admin/runners/show.html.haml index 941d02f8631..6ff05064acb 100644 --- a/app/views/admin/runners/show.html.haml +++ b/app/views/admin/runners/show.html.haml @@ -13,7 +13,7 @@ - if @runner.shared? .bs-callout.bs-callout-success - %h4 此 runner 将会处理所有<b>未指派</b>项目的构建 + %h4 此 runner 将会处理全部<b>未指派</b>项目的构建 %p 如果你想让此 runner 只会处理指派项目的构建,请在下面的表格中启用相关项目的指派。 需要注意的是,此操作只能一次。一旦指定,此 runner 将不能再转为共享的。 diff --git a/app/views/admin/spam_logs/_spam_log.html.haml b/app/views/admin/spam_logs/_spam_log.html.haml index 8aea67f4497..23b444fb924 100644 --- a/app/views/admin/spam_logs/_spam_log.html.haml +++ b/app/views/admin/spam_logs/_spam_log.html.haml @@ -6,9 +6,9 @@ - if user = link_to user.name, [:admin, user] .light.small - Joined #{time_ago_with_tooltip(user.created_at)} + 加入时间 #{time_ago_with_tooltip(user.created_at)} - else - (removed) + (已删除) %td = spam_log.source_ip %td @@ -21,12 +21,12 @@ = truncate(spam_log.description, length: 100) %td - if user - = link_to 'Remove user', admin_spam_log_path(spam_log, remove_user: true), - data: { confirm: "USER #{user.name} WILL BE REMOVED! Are you sure?" }, method: :delete, class: "btn btn-xs btn-remove" + = link_to '删除用户', admin_spam_log_path(spam_log, remove_user: true), + data: { confirm: "确定要删除用户 #{user.name} 么?" }, method: :delete, class: "btn btn-xs btn-remove" %td - if user && !user.blocked? - = link_to 'Block user', block_admin_user_path(user), data: {confirm: 'USER WILL BE BLOCKED! Are you sure?'}, method: :put, class: "btn btn-xs" + = link_to '禁用用户', block_admin_user_path(user), data: {confirm: '确定要禁用用户么?'}, method: :put, class: "btn btn-xs" - else .btn.btn-xs.disabled - Already Blocked - = link_to 'Remove log', [:admin, spam_log], remote: true, method: :delete, class: "btn btn-xs btn-close js-remove-tr" + 已被禁用 + = link_to '删除日志', [:admin, spam_log], remote: true, method: :delete, class: "btn btn-xs btn-close js-remove-tr" diff --git a/app/views/admin/spam_logs/index.html.haml b/app/views/admin/spam_logs/index.html.haml index 0fdd5bd9960..cd78f3eec0c 100644 --- a/app/views/admin/spam_logs/index.html.haml +++ b/app/views/admin/spam_logs/index.html.haml @@ -1,21 +1,21 @@ -- page_title "Spam Logs" -%h3.page-title Spam Logs +- page_title "Spam 日志" +%h3.page-title Spam 日志 %hr - if @spam_logs.present? .table-holder %table.table %thead %tr - %th Date - %th User - %th Source IP + %th 日期 + %th 用户 + %th 来源 IP %th API? - %th Type - %th Title - %th Description - %th Primary Action + %th 类型 + %th 标题 + %th 描述 + %th 主要操作 %th = render @spam_logs = paginate @spam_logs - else - %h4 There are no Spam Logs + %h4 没有 Spam 日志 diff --git a/app/views/admin/users/_form.html.haml b/app/views/admin/users/_form.html.haml index f4fce7950ef..db0924bf930 100644 --- a/app/views/admin/users/_form.html.haml +++ b/app/views/admin/users/_form.html.haml @@ -7,70 +7,70 @@ %p= msg %fieldset - %legend Account + %legend 账号 .form-group - = f.label :name, class: 'control-label' + = f.label :name, "姓名", class: 'control-label' .col-sm-10 = f.text_field :name, required: true, autocomplete: "off", class: 'form-control' - %span.help-inline * required + %span.help-inline * 必须填写 .form-group - = f.label :username, class: 'control-label' + = f.label :username, "用户名", class: 'control-label' .col-sm-10 = f.text_field :username, required: true, autocomplete: "off", class: 'form-control' - %span.help-inline * required + %span.help-inline * 必须填写 .form-group - = f.label :email, class: 'control-label' + = f.label :email, "电子邮箱", class: 'control-label' .col-sm-10 = f.text_field :email, required: true, autocomplete: "off", class: 'form-control' - %span.help-inline * required + %span.help-inline * 必须填写 - if @user.new_record? %fieldset - %legend Password + %legend 密码 .form-group - = f.label :password, class: 'control-label' + = f.label :password, "密码", class: 'control-label' .col-sm-10 %strong - Reset link will be generated and sent to the user. + 重置链接将自动生成临时密码发送给用户。 %br - User will be forced to set the password on first sign in. + 用户在第一次登录后需要强制修改密码。 - else %fieldset - %legend Password + %legend 密码 .form-group - = f.label :password, class: 'control-label' + = f.label :password, "密码", class: 'control-label' .col-sm-10= f.password_field :password, disabled: f.object.force_random_password, class: 'form-control' .form-group - = f.label :password_confirmation, class: 'control-label' + = f.label :password_confirmation, "确认密码", class: 'control-label' .col-sm-10= f.password_field :password_confirmation, disabled: f.object.force_random_password, class: 'form-control' %fieldset - %legend Access + %legend 权限 .form-group - = f.label :projects_limit, class: 'control-label' + = f.label :projects_limit, "项目限制", class: 'control-label' .col-sm-10= f.number_field :projects_limit, class: 'form-control' .form-group - = f.label :can_create_group, class: 'control-label' + = f.label :can_create_group, "是否可以创建群组", class: 'control-label' .col-sm-10= f.check_box :can_create_group .form-group - = f.label :admin, class: 'control-label' + = f.label :admin, "管理", class: 'control-label' - if current_user == @user .col-sm-10= f.check_box :admin, disabled: true - .col-sm-10 You cannot remove your own admin rights. + .col-sm-10 不能删除自己的管理权限。 - else .col-sm-10= f.check_box :admin .form-group - = f.label :external, class: 'control-label' + = f.label :external, "外部", class: 'control-label' .col-sm-10= f.check_box :external - .col-sm-10 External users cannot see internal or private projects unless access is explicitly granted. Also, external users cannot create projects or groups. + .col-sm-10 除非明确授权,外部用户无法看到任何内部和私有项目。同样,外部用户无法创建项目和群组。 %fieldset - %legend Profile + %legend 个人资料 .form-group - = f.label :avatar, class: 'control-label' + = f.label :avatar, "头像", class: 'control-label' .col-sm-10 = f.file_field :avatar diff --git a/app/views/admin/users/_projects.html.haml b/app/views/admin/users/_projects.html.haml index a126a858ea8..122daad0ad7 100644 --- a/app/views/admin/users/_projects.html.haml +++ b/app/views/admin/users/_projects.html.haml @@ -1,13 +1,13 @@ - if local_assigns.has_key?(:contributed_projects) && contributed_projects.present? .panel.panel-default.contributed-projects - .panel-heading Projects contributed to + .panel-heading 贡献的项目 = render 'shared/projects/list', projects: contributed_projects.sort_by(&:star_count).reverse, projects_limit: 5, stars: true, avatar: false - if local_assigns.has_key?(:projects) && projects.present? .panel.panel-default - .panel-heading Personal projects + .panel-heading 个人项目 = render 'shared/projects/list', projects: projects.sort_by(&:star_count).reverse, projects_limit: 10, stars: true, avatar: false diff --git a/app/views/admin/users/index.html.haml b/app/views/admin/users/index.html.haml index a52aa324503..401d928325c 100644 --- a/app/views/admin/users/index.html.haml +++ b/app/views/admin/users/index.html.haml @@ -1,35 +1,35 @@ -- page_title "Users" +- page_title "用户" = render 'shared/show_aside' .admin-filter %ul.nav-links %li{class: "#{'active' unless params[:filter]}"} = link_to admin_users_path do - Active + 当前 %small.badge= number_with_delimiter(User.active.count) %li{class: "#{'active' if params[:filter] == "admins"}"} = link_to admin_users_path(filter: "admins") do - Admins + 管理 %small.badge= number_with_delimiter(User.admins.count) %li.filter-two-factor-enabled{class: "#{'active' if params[:filter] == 'two_factor_enabled'}"} = link_to admin_users_path(filter: 'two_factor_enabled') do - 2FA Enabled + 两步验证启用 %small.badge= number_with_delimiter(User.with_two_factor.count) %li.filter-two-factor-disabled{class: "#{'active' if params[:filter] == 'two_factor_disabled'}"} = link_to admin_users_path(filter: 'two_factor_disabled') do - 2FA Disabled + 两步验证禁用 %small.badge= number_with_delimiter(User.without_two_factor.count) %li.filter-external{class: "#{'active' if params[:filter] == 'external'}"} = link_to admin_users_path(filter: 'external') do - External + 外部的 %small.badge= number_with_delimiter(User.external.count) %li{class: "#{'active' if params[:filter] == "blocked"}"} = link_to admin_users_path(filter: "blocked") do - Blocked + 禁用的 %small.badge= number_with_delimiter(User.blocked.count) %li{class: "#{'active' if params[:filter] == "wop"}"} = link_to admin_users_path(filter: "wop") do - Without projects + 无项目 %small.badge= number_with_delimiter(User.without_projects.count) .gray-content-block.second-block @@ -79,29 +79,29 @@ = icon("user", class: "cgreen") = link_to user.name, [:admin, user] - if user.admin? - %strong.cred (Admin) + %strong.cred (管理) - if user.external? - %strong.cred (External) + %strong.cred (外部) - if user == current_user - %span.cred It's you! + %span.cred 自己 .pull-right %span.light %i.fa.fa-envelope = mail_to user.email, user.email, class: 'light' .pull-right - = link_to 'Edit', edit_admin_user_path(user), id: "edit_#{dom_id(user)}", class: 'btn-grouped btn btn-xs' + = link_to '编辑', edit_admin_user_path(user), id: "edit_#{dom_id(user)}", class: 'btn-grouped btn btn-xs' - unless user == current_user - if user.ldap_blocked? = link_to '#', title: 'Cannot unblock LDAP blocked users', data: {toggle: 'tooltip'}, class: 'btn-grouped btn btn-xs btn-success disabled' do %i.fa.fa-lock - Unblock + 启用 - elsif user.blocked? - = link_to 'Unblock', unblock_admin_user_path(user), method: :put, class: 'btn-grouped btn btn-xs btn-success' + = link_to '启用', unblock_admin_user_path(user), method: :put, class: 'btn-grouped btn btn-xs btn-success' - else - = link_to 'Block', block_admin_user_path(user), data: {confirm: 'USER WILL BE BLOCKED! Are you sure?'}, method: :put, class: 'btn-grouped btn btn-xs btn-warning' + = link_to '禁用', block_admin_user_path(user), data: {confirm: '用户将被禁用!确定要继续么?'}, method: :put, class: 'btn-grouped btn btn-xs btn-warning' - if user.access_locked? - = link_to 'Unlock', unlock_admin_user_path(user), method: :put, class: 'btn-grouped btn btn-xs btn-success', data: { confirm: 'Are you sure?' } + = link_to '解锁', unlock_admin_user_path(user), method: :put, class: 'btn-grouped btn btn-xs btn-success', data: { confirm: '确定要继续么?' } - if user.can_be_removed? - = link_to 'Destroy', [:admin, user], data: { confirm: "USER #{user.name} WILL BE REMOVED! All issues, merge requests and groups linked to this user will also be removed! Maybe block the user instead? Are you sure?" }, method: :delete, class: 'btn-grouped btn btn-xs btn-remove' + = link_to '销毁', [:admin, user], data: { confirm: "用户 #{user.name} 将被删除!所有该用户的相关内容也会被删除!要不要只禁用用户?确定要继续么?" }, method: :delete, class: 'btn-grouped btn btn-xs btn-remove' = paginate @users, theme: "gitlab" diff --git a/app/views/admin/users/keys.html.haml b/app/views/admin/users/keys.html.haml index 0f644121e62..582181d4b69 100644 --- a/app/views/admin/users/keys.html.haml +++ b/app/views/admin/users/keys.html.haml @@ -1,3 +1,3 @@ -- page_title "SSH Keys", @user.name, "Users" +- page_title "SSH 密钥", @user.name, "用户" = render 'admin/users/head' = render 'profiles/keys/key_table', admin: true diff --git a/app/views/admin/users/projects.html.haml b/app/views/admin/users/projects.html.haml index 624b9ff5a4e..5dcd06e1b0e 100644 --- a/app/views/admin/users/projects.html.haml +++ b/app/views/admin/users/projects.html.haml @@ -33,7 +33,7 @@ - if member .pull-right - if member.owner? - %span.light 所有者 + %span.light 拥有者 - else %span.light= member.human_access diff --git a/app/views/admin/users/show.html.haml b/app/views/admin/users/show.html.haml index c078453c1ef..fff4bd70cde 100644 --- a/app/views/admin/users/show.html.haml +++ b/app/views/admin/users/show.html.haml @@ -18,96 +18,96 @@ .panel.panel-default .panel-heading - Account: + 账号: %ul.well-list %li - %span.light Name: + %span.light 姓名: %strong= @user.name %li - %span.light Username: + %span.light 用户名: %strong = @user.username %li - %span.light Email: + %span.light 电子邮箱: %strong = mail_to @user.email - @user.emails.each do |email| %li - %span.light Secondary email: + %span.light 第二电子邮箱: %strong= email.email - = link_to remove_email_admin_user_path(@user, email), data: { confirm: "Are you sure you want to remove #{email.email}?" }, method: :delete, class: "btn-xs btn btn-remove pull-right", title: 'Remove secondary email', id: "remove_email_#{email.id}" do + = link_to remove_email_admin_user_path(@user, email), data: { confirm: "确定要删除 #{email.email}?" }, method: :delete, class: "btn-xs btn btn-remove pull-right", title: 'Remove secondary email', id: "remove_email_#{email.id}" do %i.fa.fa-times %li.two-factor-status - %span.light Two-factor Authentication: + %span.light 两步验证: %strong{class: @user.two_factor_enabled? ? 'cgreen' : 'cred'} - if @user.two_factor_enabled? - Enabled - = link_to 'Disable', disable_two_factor_admin_user_path(@user), data: {confirm: 'Are you sure?'}, method: :patch, class: 'btn btn-xs btn-remove pull-right', title: 'Disable Two-factor Authentication' + 已启用 + = link_to '禁用', disable_two_factor_admin_user_path(@user), data: {confirm: '确定要继续么?'}, method: :patch, class: 'btn btn-xs btn-remove pull-right', title: 'Disable Two-factor Authentication' - else - Disabled + 已禁用 %li - %span.light External User: + %span.light 外部用户: %strong - = @user.external? ? "Yes" : "No" + = @user.external? ? "是" : "否" %li - %span.light Can create groups: + %span.light 是否可以创建群组: %strong - = @user.can_create_group ? "Yes" : "No" + = @user.can_create_group ? "是" : "否" %li - %span.light Personal projects limit: + %span.light 个人项目限制: %strong = @user.projects_limit %li - %span.light Member since: + %span.light 注册时间: %strong = @user.created_at.to_s(:medium) - if @user.confirmed_at %li - %span.light Confirmed at: + %span.light 确认时间: %strong = @user.confirmed_at.to_s(:medium) - else %li - %span.light Confirmed: + %span.light 已确认: %strong.cred - No + 否 %li - %span.light Current sign-in IP: + %span.light 当前登入 IP: %strong - if @user.current_sign_in_ip = @user.current_sign_in_ip - else - never + 从未 %li - %span.light Current sign-in at: + %span.light 当前登入时间: %strong - if @user.current_sign_in_at = @user.current_sign_in_at.to_s(:medium) - else - never + 从未 %li - %span.light Last sign-in IP: + %span.light 上次登入 IP: %strong - if @user.last_sign_in_ip = @user.last_sign_in_ip - else - never + 从未 %li - %span.light Last sign-in at: + %span.light 上次登入时间: %strong - if @user.last_sign_in_at = @user.last_sign_in_at.to_s(:medium) - else - never + 从未 %li - %span.light Sign-in count: + %span.light 登入次数: %strong = @user.sign_in_count @@ -142,7 +142,7 @@ .panel-body %p 禁用用户有如下效果: %ul - %li 用户无法登录 + %li 用户无法登入 %li 用户无法访问 git 版本仓库 %li 个人项目将被移除 %li 拥有的群组将被移除 @@ -155,7 +155,7 @@ .panel-body %p 禁用用户有如下效果: %ul - %li 用户无法登录 + %li 用户无法登入 %li 用户无法访问 git 版本仓库 %li 用户将从加入的项目和群组中删除 %li 个人项目将被移除 @@ -178,7 +178,7 @@ - if @user.can_be_removed? %p 删除用户有如下效果: %ul - %li 所有用户内容,比如:问题、代码片段、注释都将被删除 + %li 全部用户内容,比如:问题、代码片段、注释都将被删除 - rp = @user.personal_projects.count - unless rp.zero? %li #{pluralize rp, '个个人项目', '个个人项目'}将被删除并无法恢复 diff --git a/app/views/dashboard/_projects_head.html.haml b/app/views/dashboard/_projects_head.html.haml index 9da3fcbd986..d5fc83d7e44 100644 --- a/app/views/dashboard/_projects_head.html.haml +++ b/app/views/dashboard/_projects_head.html.haml @@ -3,20 +3,20 @@ .top-area %ul.nav-links = nav_link(page: [dashboard_projects_path, root_path]) do - = link_to dashboard_projects_path, title: 'Home', class: 'shortcuts-activity', data: {placement: 'right'} do - Your Projects + = link_to dashboard_projects_path, title: '主页', class: 'shortcuts-activity', data: {placement: 'right'} do + 你的项目 = nav_link(page: starred_dashboard_projects_path) do - = link_to starred_dashboard_projects_path, title: 'Starred Projects', data: {placement: 'right'} do - Starred Projects + = link_to starred_dashboard_projects_path, title: '星标项目', data: {placement: 'right'} do + 星标项目 = nav_link(page: [explore_root_path, trending_explore_projects_path, starred_explore_projects_path, explore_projects_path]) do - = link_to explore_root_path, title: 'Explore', data: {placement: 'right'} do - Explore Projects + = link_to explore_root_path, title: '浏览', data: {placement: 'right'} do + 浏览项目 .nav-controls = form_tag request.original_url, method: :get, class: 'project-filter-form', id: 'project-filter-form' do |f| - = search_field_tag :filter_projects, params[:filter_projects], placeholder: 'Filter by name...', class: 'project-filter-form-field form-control input-short projects-list-filter', spellcheck: false, id: 'project-filter-form-field', tabindex: "2" + = search_field_tag :filter_projects, params[:filter_projects], placeholder: '按名称过滤...', class: 'project-filter-form-field form-control input-short projects-list-filter', spellcheck: false, id: 'project-filter-form-field', tabindex: "2" = render 'shared/projects/dropdown' - if current_user.can_create_project? = link_to new_project_path, class: 'btn btn-new' do = icon('plus') - New Project + 新项目 diff --git a/app/views/dashboard/milestones/show.html.haml b/app/views/dashboard/milestones/show.html.haml index 60c84a26420..f64aeedab37 100644 --- a/app/views/dashboard/milestones/show.html.haml +++ b/app/views/dashboard/milestones/show.html.haml @@ -1,4 +1,4 @@ -- header_title "Milestones", dashboard_milestones_path +- header_title "里程碑", dashboard_milestones_path = render 'shared/milestones/top', milestone: @milestone = render 'shared/milestones/summary', milestone: @milestone diff --git a/app/views/dashboard/projects/_zero_authorized_projects.html.haml b/app/views/dashboard/projects/_zero_authorized_projects.html.haml index 33b5b8066bb..ecb5ef6073a 100644 --- a/app/views/dashboard/projects/_zero_authorized_projects.html.haml +++ b/app/views/dashboard/projects/_zero_authorized_projects.html.haml @@ -1,25 +1,25 @@ - publicish_project_count = ProjectsFinder.new.execute(current_user).count -%h3.page-title Welcome to GitLab! -%p.light Self hosted Git management application. +%h3.page-title 欢迎来到 GitLab! +%p.light 自托管 Git 管理应用。 %hr %div .dashboard-intro-icon %i.fa.fa-bookmark-o .dashboard-intro-text %p.slead - You don't have access to any projects right now. + 你现在不能访问任何项目。 %br - if current_user.can_create_project? - You can create up to - %strong= pluralize(number_with_delimiter(current_user.projects_limit), "project") + "." + 你可以最多创建 + %strong= pluralize(number_with_delimiter(current_user.projects_limit), "个项目", "个项目") + "。" - else - If you are added to a project, it will be displayed here. + 如果你加入了项目,它将会显示在这里。 - if current_user.can_create_project? .link_holder = link_to new_project_path, class: "btn btn-new" do = icon('plus') - New Project + 新项目 - if current_user.can_create_group? %hr @@ -43,11 +43,11 @@ %i.fa.fa-globe .dashboard-intro-text %p.slead - There are + 此服务器上有 %strong= number_with_delimiter(publicish_project_count) - public projects on this server. + 个公开项目。 %br - Public projects are an easy way to allow everyone to have read-only access. + 公开项目允许全部人都可以只读访问。 .link_holder = link_to trending_explore_projects_path, class: "btn btn-new" do - Browse public projects + 浏览公开项目 diff --git a/app/views/dashboard/todos/_todo.html.haml b/app/views/dashboard/todos/_todo.html.haml index 4c848a50181..78c23039b58 100644 --- a/app/views/dashboard/todos/_todo.html.haml +++ b/app/views/dashboard/todos/_todo.html.haml @@ -17,7 +17,7 @@ - if todo.pending? .todo-actions.pull-right = link_to [:dashboard, todo], method: :delete, class: 'btn btn-loading done-todo' do - Done + 完成 = icon('spinner spin') .todo-body diff --git a/app/views/dashboard/todos/index.html.haml b/app/views/dashboard/todos/index.html.haml index f9804101a92..02adaddc582 100644 --- a/app/views/dashboard/todos/index.html.haml +++ b/app/views/dashboard/todos/index.html.haml @@ -1,5 +1,5 @@ -- page_title "Todos" -- header_title "Todos", dashboard_todos_path +- page_title "待办事项" +- header_title "待办事项", dashboard_todos_path .top-area %ul.nav-links @@ -7,21 +7,21 @@ %li{class: "todos-pending #{todo_pending_active}"} = link_to todos_filter_path(state: 'pending') do %span - To do + 待办事项 %span{class: 'badge'} = todos_pending_count - todo_done_active = ('active' if params[:state] == 'done') %li{class: "todos-done #{todo_done_active}"} = link_to todos_filter_path(state: 'done') do %span - Done + 已完成 %span{class: 'badge'} = todos_done_count .nav-controls - if @todos.any?(&:pending?) = link_to destroy_all_dashboard_todos_path(todos_filter_params), class: 'btn btn-loading js-todos-mark-all', method: :delete do - Mark all as done + 标记全部完成 = icon('spinner spin') .todos-filters diff --git a/app/views/doorkeeper/applications/_delete_form.html.haml b/app/views/doorkeeper/applications/_delete_form.html.haml index 001a711b1dd..56af9a55130 100644 --- a/app/views/doorkeeper/applications/_delete_form.html.haml +++ b/app/views/doorkeeper/applications/_delete_form.html.haml @@ -2,9 +2,9 @@ = form_tag oauth_application_path(application) do %input{:name => "_method", :type => "hidden", :value => "delete"}/ - if defined? small - = button_tag type: "submit", class: "btn btn-transparent", data: { confirm: "Are you sure?" } do + = button_tag type: "submit", class: "btn btn-transparent", data: { confirm: "确定要继续么?" } do %span.sr-only - Destroy + 销毁 = icon('trash') - else - = submit_tag 'Destroy', data: { confirm: "Are you sure?" }, class: submit_btn_css + = submit_tag '销毁', data: { confirm: "确定要继续么?" }, class: submit_btn_css diff --git a/app/views/doorkeeper/applications/_form.html.haml b/app/views/doorkeeper/applications/_form.html.haml index 906b0676150..e57271a5ce3 100644 --- a/app/views/doorkeeper/applications/_form.html.haml +++ b/app/views/doorkeeper/applications/_form.html.haml @@ -6,20 +6,20 @@ %li= msg .form-group - = f.label :name, class: 'label-light' + = f.label :name, "名称", class: 'label-light' = f.text_field :name, class: 'form-control', required: true .form-group - = f.label :redirect_uri, class: 'label-light' + = f.label :redirect_uri, "重定向 URI", class: 'label-light' = f.text_area :redirect_uri, class: 'form-control', required: true %span.help-block - Use one line per URI + 每个 URI 使用一行 - if Doorkeeper.configuration.native_redirect_uri %span.help-block - Use + 使用 %code= Doorkeeper.configuration.native_redirect_uri - for local tests + 作为本地测试 .prepend-top-default - = f.submit 'Save application', class: "btn btn-create" + = f.submit '保存应用', class: "btn btn-create" diff --git a/app/views/doorkeeper/applications/index.html.haml b/app/views/doorkeeper/applications/index.html.haml index ea0b66c932b..3fbe778f38d 100644 --- a/app/views/doorkeeper/applications/index.html.haml +++ b/app/views/doorkeeper/applications/index.html.haml @@ -1,4 +1,4 @@ -- page_title "Applications" +- page_title "应用" - header_title page_title, applications_profile_path .row.prepend-top-default @@ -7,28 +7,28 @@ = page_title %p - if user_oauth_applications? - Manage applications that can use GitLab as an OAuth provider, - and applications that you've authorized to use your account. + 管理将 GitLab 作为 OAuth 提供者的应用, + 和授权使用你的账号的应用。 - else - Manage applications that you've authorized to use your account. + 管理授权使用你的账号的应用。 .col-lg-9 - if user_oauth_applications? %h5.prepend-top-0 - Add new application + 增加新的应用 = render 'form', application: @application %hr - if user_oauth_applications? .oauth-applications %h5 - Your applications (#{@applications.size}) + 您的应用 (#{@applications.size}) - if @applications.any? .table-responsive %table.table %thead %tr - %th Name - %th Callback URL - %th Clients + %th 名称 + %th 回调链接 + %th 客户端 %th.last-heading %tbody - @applications.each do |application| @@ -41,25 +41,25 @@ %td = link_to edit_oauth_application_path(application), class: "btn btn-transparent append-right-5" do %span.sr-only - Edit + 编辑 = icon('pencil') = render 'delete_form', application: application, small: true - else .profile-settings-message.text-center - You don't have any applications + 没有任何应用 .oauth-authorized-applications.prepend-top-20.append-bottom-default - if user_oauth_applications? %h5 - Authorized applications (#{@authorized_tokens.size}) + 已认证的应用 (#{@authorized_tokens.size}) - if @authorized_tokens.any? .table-responsive %table.table.table-striped %thead %tr - %th Name - %th Authorized At - %th Scope + %th 名称 + %th 认证时间 + %th 范围 %th %tbody - @authorized_apps.each do |app| @@ -72,12 +72,12 @@ - @authorized_anonymous_tokens.each do |token| %tr %td - Anonymous + 匿名 %div.help-block - %em Authorization was granted by entering your username and password in the application. + %em 通过在应用中输入你的账号和密码认证授权。 %td= token.created_at %td= token.scopes %td= render 'delete_form', token: token - else .profile-settings-message.text-center - You don't have any authorized applications + 没有任何已认证的应用 diff --git a/app/views/errors/omniauth_error.html.haml b/app/views/errors/omniauth_error.html.haml index 082970d718a..6be15505e08 100644 --- a/app/views/errors/omniauth_error.html.haml +++ b/app/views/errors/omniauth_error.html.haml @@ -2,12 +2,12 @@ %h1 422 %h3 使用 #{@provider} 认证登入失败 %hr -%p Sign-in failed because #{@error}. -%p There are couple of steps you can take: +%p 因为 #{@error} 造成登入失败。 +%p 可能是因为下列原因造成: %ul - %li Try logging in using your email - %li Try logging in using your username - %li If you have forgotten your password, try recovering it using #{ link_to "Password recovery", new_password_path(resource_name) } + %li 使用您的电子邮箱尝试登录 + %li 使用您的用户名尝试登录 + %li 如果您忘记密码,请使用#{ link_to "密码找回", new_password_path(resource_name) }功能找回密码 -%p If none of the options work, try contacting the GitLab administrator. +%p 如果不是上诉原因,请联系 GitLab 管理员。 diff --git a/app/views/events/_event_last_push.html.haml b/app/views/events/_event_last_push.html.haml index 5753158c24d..6f3e503d8b7 100644 --- a/app/views/events/_event_last_push.html.haml +++ b/app/views/events/_event_last_push.html.haml @@ -2,13 +2,14 @@ .gray-content-block.clear-block.last-push-widget .event-last-push .event-last-push-text - %span You pushed to + %span 你在 + #{time_ago_with_tooltip(event.created_at)} + %span 推送 = link_to namespace_project_commits_path(event.project.namespace, event.project, event.ref_name), title: h(event.project.name) do %strong= event.ref_name - %span at + %span 到 %strong= link_to_project event.project - #{time_ago_with_tooltip(event.created_at)} .pull-right - = link_to new_mr_path_from_push_event(event), title: "New Merge Request", class: "btn btn-info btn-sm" do - Create Merge Request + = link_to new_mr_path_from_push_event(event), title: "新合并请求", class: "btn btn-info btn-sm" do + 创建合并请求 diff --git a/app/views/events/event/_push.html.haml b/app/views/events/event/_push.html.haml index ff61873bec8..6246ba508f3 100644 --- a/app/views/events/event/_push.html.haml +++ b/app/views/events/event/_push.html.haml @@ -6,7 +6,7 @@ - else %strong = link_to event.ref_name, namespace_project_commits_path(event.project.namespace, event.project, event.ref_name), title: h(event.target_title) - at + 在 = link_to_project event.project - if event.push_with_commits? diff --git a/app/views/explore/projects/_filter.html.haml b/app/views/explore/projects/_filter.html.haml index cd485da5104..dd1dc5960c6 100644 --- a/app/views/explore/projects/_filter.html.haml +++ b/app/views/explore/projects/_filter.html.haml @@ -2,16 +2,16 @@ .dropdown %a.dropdown-toggle.btn{href: '#', "data-toggle" => "dropdown"} = icon('globe') - %span.light Visibility: + %span.light 可见度: - if params[:visibility_level].present? = visibility_level_label(params[:visibility_level].to_i) - else - Any + 任何 %b.caret %ul.dropdown-menu %li = link_to filter_projects_path(visibility_level: nil) do - Any + 任何 - Gitlab::VisibilityLevel.values.each do |level| %li{ class: (level.to_s == params[:visibility_level]) ? 'active' : 'light' } = link_to filter_projects_path(visibility_level: level) do @@ -22,16 +22,16 @@ .dropdown %a.dropdown-toggle.btn{href: '#', "data-toggle" => "dropdown"} = icon('tags') - %span.light Tags: + %span.light 标签: - if params[:tag].present? = params[:tag] - else - Any + 任何 %b.caret %ul.dropdown-menu %li = link_to filter_projects_path(tag: nil) do - Any + 任何 - @tags.each do |tag| %li{ class: (tag.name == params[:tag]) ? 'active' : 'light' } diff --git a/app/views/groups/edit.html.haml b/app/views/groups/edit.html.haml index 0b7177240b3..9f7453e83c6 100644 --- a/app/views/groups/edit.html.haml +++ b/app/views/groups/edit.html.haml @@ -15,36 +15,36 @@ = image_tag group_icon(@group), alt: '', class: 'avatar group-avatar s160' %p.light - if @group.avatar? - You can change your group avatar here + 你可以在这里修改群组头像 - else - You can upload a group avatar here + 你可以在这里上传群组头像 = render 'shared/choose_group_avatar_button', f: f - if @group.avatar? %hr - = link_to 'Remove avatar', group_avatar_path(@group.to_param), data: { confirm: "Group avatar will be removed. Are you sure?"}, method: :delete, class: "btn btn-remove btn-sm remove-avatar" + = link_to '删除头像', group_avatar_path(@group.to_param), data: { confirm: "确定要删除群组头像么?"}, method: :delete, class: "btn btn-remove btn-sm remove-avatar" = render 'shared/visibility_level', f: f, visibility_level: @group.visibility_level, can_change_visibility_level: can_change_group_visibility_level?(@group), form_model: @group .form-group %hr = f.label :share_with_group_lock, class: 'control-label' do - Share with group lock + 群共享锁 .col-sm-10 .checkbox = f.check_box :share_with_group_lock - %span.descr Prevent sharing a project with another group within this group + %span.descr 禁止此群组与其他群组共享项目 .form-actions - = f.submit 'Save group', class: "btn btn-save" + = f.submit '保存群组', class: "btn btn-save" .panel.panel-danger - .panel-heading Remove group + .panel-heading 删除群组 .panel-body %p - Removing group will cause all child projects and resources to be removed. + 删除群组将删除全部子项目和相关资源。 %br - %strong Removed group can not be restored! + %strong 删除群组无法恢复! .form-actions - = link_to 'Remove Group', @group, data: {confirm: 'Removed group can not be restored! Are you sure?'}, method: :delete, class: "btn btn-remove" + = link_to '删除群组', @group, data: {confirm: '删除群组无法恢复!确定要继续么?'}, method: :delete, class: "btn btn-remove" diff --git a/app/views/groups/group_members/index.html.haml b/app/views/groups/group_members/index.html.haml index f8bd344d915..52dd278e8c2 100644 --- a/app/views/groups/group_members/index.html.haml +++ b/app/views/groups/group_members/index.html.haml @@ -9,7 +9,7 @@ .panel-body - if should_user_see_group_roles?(current_user, @group) %p.light - 群组成员可以访问所有群组项目。 + 群组成员可以访问全部群组项目。 .new-group-member-holder = render "new_group_member" diff --git a/app/views/groups/issues.html.haml b/app/views/groups/issues.html.haml index 7930fc3cfc5..dfa5fd100be 100644 --- a/app/views/groups/issues.html.haml +++ b/app/views/groups/issues.html.haml @@ -19,7 +19,7 @@ %strong #{@group.name} 群组的问题显示在此处。 - if current_user - 请到#{link_to '仪表盘', issues_dashboard_path}页面访问所有问题。 + 请到#{link_to '仪表盘', issues_dashboard_path}页面访问全部问题。 .prepend-top-default = render 'shared/issues' diff --git a/app/views/groups/merge_requests.html.haml b/app/views/groups/merge_requests.html.haml index d35f15925be..0d0084cc37f 100644 --- a/app/views/groups/merge_requests.html.haml +++ b/app/views/groups/merge_requests.html.haml @@ -13,7 +13,7 @@ %strong #{@group.name} 群组的合并请求显示在此处。 - if current_user - 请到#{link_to '仪表盘', merge_requests_dashboard_path}页面访问所有合并请求。 + 请到#{link_to '仪表盘', merge_requests_dashboard_path}页面访问全部合并请求。 .prepend-top-default = render 'shared/merge_requests' diff --git a/app/views/groups/milestones/new.html.haml b/app/views/groups/milestones/new.html.haml index a8e1ed77da9..c4720630549 100644 --- a/app/views/groups/milestones/new.html.haml +++ b/app/views/groups/milestones/new.html.haml @@ -1,46 +1,64 @@ -- page_title "Milestones" -- header_title group_title(@group, "Milestones", group_milestones_path(@group)) +- page_title "里程碑" +- header_title group_title(@group, "里程碑", group_milestones_path(@group)) %h3.page-title - New Milestone + 新里程碑 %p.light - This will create milestone in every selected project + 将会给每一个选择的项目创建里程碑 %hr = form_for @milestone, url: group_milestones_path(@group), html: { class: 'form-horizontal milestone-form gfm-form js-quick-submit js-requires-input' } do |f| .row .col-md-6 .form-group - = f.label :title, "Title", class: "control-label" + = f.label :title, "标题", class: "control-label" .col-sm-10 = f.text_field :title, maxlength: 255, class: "form-control", required: true, autofocus: true .form-group.milestone-description - = f.label :description, "Description", class: "control-label" + = f.label :description, "描述", class: "control-label" .col-sm-10 = render layout: 'projects/md_preview', locals: { preview_class: "md-preview" } do = render 'projects/zen', f: f, attr: :description, classes: 'description form-control' .clearfix .error-alert .form-group - = f.label :projects, "Projects", class: "control-label" + = f.label :projects, "项目", class: "control-label" .col-sm-10 = f.collection_select :project_ids, @group.projects, :id, :name, { selected: @group.projects.map(&:id) }, multiple: true, class: 'select2' .col-md-6 .form-group - = f.label :due_date, "Due Date", class: "control-label" + = f.label :due_date, "到期日", class: "control-label" .col-sm-10= f.hidden_field :due_date .col-sm-10 .datepicker .form-actions - = f.submit 'Create Milestone', class: "btn-create btn" - = link_to "Cancel", group_milestones_path(@group), class: "btn btn-cancel" + = f.submit '创建里程碑', class: "btn-create btn" + = link_to "取消", group_milestones_path(@group), class: "btn btn-cancel" :javascript + $.datepicker.regional['zh-CN'] = { + closeText: '关闭', + prevText: '<上月', + nextText: '下月>', + currentText: '今天', + monthNames: ['一月','二月','三月','四月','五月','六月', + '七月','八月','九月','十月','十一月','十二月'], + monthNamesShort: ['一月','二月','三月','四月','五月','六月', + '七月','八月','九月','十月','十一月','十二月'], + dayNames: ['星期日','星期一','星期二','星期三','星期四','星期五','星期六'], + dayNamesShort: ['周日','周一','周二','周三','周四','周五','周六'], + dayNamesMin: ['日','一','二','三','四','五','六'], + weekHeader: '周', + isRTL: false, + showMonthAfterYear: true, + yearSuffix: '年' + }; + $.datepicker.setDefaults($.datepicker.regional['zh-CN']); $(".datepicker").datepicker({ dateFormat: "yy-mm-dd", onSelect: function(dateText, inst) { $("#milestone_due_date").val(dateText) } diff --git a/app/views/groups/show.html.haml b/app/views/groups/show.html.haml index cd575e22e9f..ad0bc4d910e 100644 --- a/app/views/groups/show.html.haml +++ b/app/views/groups/show.html.haml @@ -32,19 +32,19 @@ %ul.nav-links %li.active = link_to "#projects", 'data-toggle' => 'tab' do - All Projects + 全部项目 - if @shared_projects.present? %li = link_to "#shared", 'data-toggle' => 'tab' do - Shared Projects + 共享的项目 .nav-controls = form_tag request.original_url, method: :get, class: 'project-filter-form', id: 'project-filter-form' do |f| - = search_field_tag :filter_projects, nil, placeholder: 'Filter by name', class: 'projects-list-filter form-control', spellcheck: false + = search_field_tag :filter_projects, nil, placeholder: '按名称过滤', class: 'projects-list-filter form-control', spellcheck: false = render 'shared/projects/dropdown' - if can? current_user, :create_projects, @group = link_to new_project_path(namespace_id: @group.id), class: 'btn btn-new pull-right' do = icon('plus') - New Project + 新项目 .tab-content .tab-pane.active#projects diff --git a/app/views/help/_shortcuts.html.haml b/app/views/help/_shortcuts.html.haml index 85401681522..f649239e341 100644 --- a/app/views/help/_shortcuts.html.haml +++ b/app/views/help/_shortcuts.html.haml @@ -4,24 +4,24 @@ .modal-header %a.close{href: "#", "data-dismiss" => "modal"} × %h4 - Keyboard Shortcuts + 键盘快捷键 %small - = link_to '(Show all)', '#', class: 'js-more-help-button' + = link_to '(显示全部)', '#', class: 'js-more-help-button' .modal-body.shortcuts-cheatsheet .col-lg-4 %table.shortcut-mappings %tbody %tr %th - %th Global Shortcuts + %th 全局快捷键 %tr %td.shortcut .key s - %td Focus Search + %td 直接搜索 %tr %td.shortcut .key ? - %td Show this dialog + %td 显示本对话框 %tr %td.shortcut - if browser.mac? @@ -29,180 +29,180 @@ - else .key ctrl shift p - %td Toggle Markdown preview + %td 切换 Markdown 预览 %tbody %tr %th - %th Project Files browsing + %th 项目文件浏览 %tr %td.shortcut .key %i.fa.fa-arrow-up - %td Move selection up + %td 选择向上 %tr %td.shortcut .key %i.fa.fa-arrow-down - %td Move selection down + %td 选择向下 %tr %td.shortcut - .key enter - %td Open Selection + .key 回车 + %td 打开选择 %tbody %tr %th - %th Finding Project File + %th 查找项目文件 %tr %td.shortcut .key %i.fa.fa-arrow-up - %td Move selection up + %td 选择向上 %tr %td.shortcut .key %i.fa.fa-arrow-down - %td Move selection down + %td 选择向下 %tr %td.shortcut - .key enter - %td Open Selection + .key 回车 + %td 打开选择 %tr %td.shortcut .key esc - %td Go back + %td 返回 .col-lg-4 %table.shortcut-mappings %tbody{ class: 'hidden-shortcut project', style: 'display:none' } %tr %th - %th Global Dashboard + %th 全局仪表盘 %tr %td.shortcut .key g .key a %td - Go to the activity feed + 转到动态 %tr %td.shortcut .key g .key p %td - Go to projects + 转到项目 %tr %td.shortcut .key g .key i %td - Go to issues + 转到问题 %tr %td.shortcut .key g .key m %td - Go to merge requests + 转到合并请求 %tbody %tr %th - %th Project + %th 项目 %tr %td.shortcut .key g .key p %td - Go to the project's home page + 转到项目首页 %tr %td.shortcut .key g .key e %td - Go to the project's activity feed + 转到项目动态 %tr %td.shortcut .key g .key f %td - Go to files + 转到文件 %tr %td.shortcut .key g .key c %td - Go to commits + 转到提交 %tr %td.shortcut .key g .key b %td - Go to builds + 转到构建 %tr %td.shortcut .key g .key n %td - Go to network graph + 转到网络图表 %tr %td.shortcut .key g .key g %td - Go to graphs + 转到图表 %tr %td.shortcut .key g .key i %td - Go to issues + 转到问题 %tr %td.shortcut .key g .key m %td - Go to merge requests + 转到合并请求 %tr %td.shortcut .key g .key s %td - Go to snippets + 转到代码片段 %tr %td.shortcut .key t - %td Go to finding file + %td 转到查找文件 .col-lg-4 %table.shortcut-mappings %tbody{ class: 'hidden-shortcut network', style: 'display:none' } %tr %th - %th Network Graph + %th 网络图表 %tr %td.shortcut .key %i.fa.fa-arrow-left \/ .key h - %td Scroll left + %td 左滚动 %tr %td.shortcut .key %i.fa.fa-arrow-right \/ .key l - %td Scroll right + %td 右滚动 %tr %td.shortcut .key %i.fa.fa-arrow-up \/ .key k - %td Scroll up + %td 上滚动 %tr %td.shortcut .key %i.fa.fa-arrow-down \/ .key j - %td Scroll down + %td 下滚动 %tr %td.shortcut .key @@ -220,44 +220,44 @@ \/ .key shift j - %td Scroll to bottom + %td 滚动到底部 %tbody{ class: 'hidden-shortcut issues', style: 'display:none' } %tr %th - %th Issues + %th 问题 %tr %td.shortcut .key a - %td Change assignee + %td 修改指派 %tr %td.shortcut .key m - %td Change milestone + %td 修改里程碑 %tr %td.shortcut .key r - %td Reply (quoting selected text) + %td 回复 (并引用选择的文本) %tr %td.shortcut .key e - %td Edit issue + %td 编辑问题 %tbody{ class: 'hidden-shortcut merge_requests', style: 'display:none' } %tr %th - %th Merge Requests + %th 合并请求 %tr %td.shortcut .key a - %td Change assignee + %td 修改指派 %tr %td.shortcut .key m - %td Change milestone + %td 修改里程碑 %tr %td.shortcut .key r - %td Reply (quoting selected text) + %td 回复 (并引用选择的文本) %tr %td.shortcut .key e - %td Edit merge request + %td 编辑合并请求 diff --git a/app/views/help/ui.html.haml b/app/views/help/ui.html.haml index c9244770bd0..2cd0f0e308a 100644 --- a/app/views/help/ui.html.haml +++ b/app/views/help/ui.html.haml @@ -1,67 +1,66 @@ -- page_title "UI Development Kit", "Help" -- lorem = "Lorem ipsum dolor sit amet, consectetur adipiscing elit. Sed fermentum nisi sapien, non consequat lectus aliquam ultrices. Suspendisse sodales est euismod nunc condimentum, a consectetur diam ornare." +- page_title "UI 开发包", "帮助" +- lorem = "《大教堂与市集》(The Cathedral and the Bazaar)是埃里克·斯蒂芬·雷蒙 Eric Steven Raymond 所撰写的软件工程方法论。以 Linux 的核心开发过程以及作者自己主持开发的开放源代码软件──Fetchmail 为讨论案例。文章在 1997 年 5 月 27 日发表,并在 1999 年出版成书。" .gitlab-ui-dev-kit - %h1 GitLab UI development kit + %h1 GitLab UI 开发包 %p.light - Use page inspector in your browser to check element classes and structure - of examples below. + 在浏览器中使用页面检查器查看下面例子中的元素样式和结构。 %hr %ul %li - = link_to 'Blocks', '#blocks' + = link_to '区块', '#blocks' %li - = link_to 'Lists', '#lists' + = link_to '列表', '#lists' %li - = link_to 'Tables', '#tables' + = link_to '表格', '#tables' %li - = link_to 'Nav', '#nav' + = link_to '导航', '#nav' %li - = link_to 'Buttons', '#buttons' + = link_to '按钮', '#buttons' %li - = link_to 'Dropdowns', '#dropdowns' + = link_to '下拉', '#dropdowns' %li - = link_to 'Panels', '#panels' + = link_to '面板', '#panels' %li - = link_to 'Alerts', '#alerts' + = link_to '警告', '#alerts' %li - = link_to 'Forms', '#forms' + = link_to '表单', '#forms' %li - = link_to 'Files', '#file' + = link_to '文件', '#file' %li = link_to 'Markdown', '#markdown' - %h2#blocks Blocks + %h2#blocks 区块 .lead - Content block separated with botton border + 使用底边框分隔的内容区块 %code .content-block .example .content-block - %h4 Normal block inside content + %h4 包含内容的普通区块 = lorem .content-block - %h4 Second block + %h4 第二个区块 = lorem .lead - Gray content block with side padding using + 使用边填充的灰底内容区块 %code .gray-content-block .example .gray-content-block - %h4 Normal block inside content + %h4 包含内容的普通区块 = lorem .gray-content-block.second-block - %h4 Second block + %h4 第二个区块 = lorem .lead - Cover block for profile page with avatar, name and description + 带有头像、名称和描述的资料页封面区块 %code .cover-block .example .cover-block @@ -80,75 +79,75 @@ = link_to '#', class: 'btn btn-gray' do = icon('rss') - %h2#lists Lists + %h2#lists 列表 .lead - Simple list using + 简单列表 %code .content-list .example %ul.content-list %li - One item + 一个项目 %li - One item + 一个项目 %li - One item + 一个项目 .lead - List with avatar, title and description using + 带有头像、标题和描述的列表 %code .content-list .example %ul.content-list %li = image_tag 'no_avatar.png', class: 'avatar s40' - .title Title - .description Description + .title 标题 + .description 描述 %li = image_tag 'no_avatar.png', class: 'avatar s40' - .title Title - .description Description + .title 标题 + .description 描述 %li = image_tag 'no_avatar.png', class: 'avatar s40' - .title Title - .description Description + .title 标题 + .description 描述 .lead - List with hover effect + 悬停效果列表 %code .well-list .example %ul.well-list %li - One item + 一个项目 %li - One item + 一个项目 %li - One item + 一个项目 .lead - List inside panel + 面板内列表 .example .panel.panel-default - .panel-heading Your list + .panel-heading 你的列表 %ul.well-list %li - One item + 一个项目 %li - One item + 一个项目 %li - One item + 一个项目 - %h2#tables Tables + %h2#tables 表格 .example %table.table %thead %tr %th # - %th First Name - %th Last Name - %th Username + %th 名字 + %th 姓氏 + %th 用户名 %tbody %tr %td 1 @@ -166,164 +165,164 @@ %td the Bird %td @twitter - %h2#navs Navigation + %h2#navs 导航条 .lead - Holder for top page navigation. Includes navigation, search field, sorting and button + 页面顶部导航。包括导航、搜索区域、排序和按钮 %code .top-area .example .top-area %ul.nav-links %li.active - %a Open + %a 打开的 %li - %a Closed + %a 关闭的 .nav-controls = text_field_tag 'sample', nil, class: 'form-control' .dropdown %button.dropdown-menu-toggle{type: 'button', 'data-toggle' => 'dropdown'} - %span Sort by name + %span 按名称排序 = icon('chevron-down') %ul.dropdown-menu %li - %a Sort by date + %a 按日期排序 - = link_to 'New issue', '#', class: 'btn btn-new' + = link_to '新问题', '#', class: 'btn btn-new' .lead - Only nav links without button and search + 不含按钮和搜索的导航 %code .nav-links .example %ul.nav-links %li.active - %a Open + %a 打开的 %li - %a Closed + %a 关闭的 - %h2#buttons Buttons + %h2#buttons 按钮 .example - %button.btn.btn-default{:type => "button"} Default - %button.btn.btn-gray{:type => "button"} Gray - %button.btn.btn-primary{:type => "button"} Primary - %button.btn.btn-success{:type => "button"} Success - %button.btn.btn-info{:type => "button"} Info - %button.btn.btn-warning{:type => "button"} Warning - %button.btn.btn-danger{:type => "button"} Danger - %button.btn.btn-link{:type => "button"} Link + %button.btn.btn-default{:type => "button"} 默认 + %button.btn.btn-gray{:type => "button"} 灰色 + %button.btn.btn-primary{:type => "button"} 主要 + %button.btn.btn-success{:type => "button"} 成功 + %button.btn.btn-info{:type => "button"} 信息 + %button.btn.btn-warning{:type => "button"} 警告 + %button.btn.btn-danger{:type => "button"} 危险 + %button.btn.btn-link{:type => "button"} 链接 - %h2#dropdowns Dropdowns + %h2#dropdowns 下拉 .example .clearfix .dropdown.inline.pull-left %button.dropdown-menu-toggle{type: 'button', data: {toggle: 'dropdown'}} - Dropdown + 下拉 = icon('chevron-down') %ul.dropdown-menu %li %a{href: "#"} - Dropdown Option + 下拉选项 .dropdown.inline.pull-right %button.dropdown-menu-toggle{type: 'button', data: {toggle: 'dropdown'}} - Dropdown + 下拉 = icon('chevron-down') %ul.dropdown-menu.dropdown-menu-align-right %li %a{href: "#"} - Dropdown Option + 下拉选项 .example %div .dropdown.inline %button.dropdown-menu-toggle{type: 'button', data: {toggle: 'dropdown'}} - Dropdown + 下拉 = icon('chevron-down') %ul.dropdown-menu.dropdown-menu-selectable %li %a.is-active{href: "#"} - Dropdown Option + 下拉选项 .example %div .dropdown.inline %button.dropdown-menu-toggle{type: 'button', data: {toggle: 'dropdown'}} - Dropdown + 下拉 = icon('chevron-down') .dropdown-menu.dropdown-select.dropdown-menu-selectable .dropdown-title - %span Dropdown Title - %button.dropdown-title-button.dropdown-menu-close{aria: {label: "Close"}} + %span 下拉标题 + %button.dropdown-title-button.dropdown-menu-close{aria: {label: "关闭"}} = icon('times') .dropdown-input - %input.dropdown-input-field{type: "search", placeholder: "Filter results"} + %input.dropdown-input-field{type: "search", placeholder: "过滤结果"} = icon('search') .dropdown-content %ul %li %a.is-active{href: "#"} - Dropdown Option + 下拉选项 %li %a{href: "#"} - Dropdown Option + 下拉选项 %li.divider %li %a{href: "#"} - Dropdown Option + 下拉选项 %li %a{href: "#"} - Dropdown Option + 下拉选项 %li %a{href: "#"} - Dropdown Option + 下拉选项 %li %a{href: "#"} - Dropdown Option + 下拉选项 %li %a{href: "#"} - Dropdown Option + 下拉选项 .dropdown-footer - %strong Tip: - If an author is not a member of this project, you can still filter by his name while using the search field. + %strong 提示: + 即使是非此项目的成员,你也能通过搜索框搜索到他的名字。 .dropdown.inline %button.dropdown-menu-toggle{type: 'button', data: {toggle: 'dropdown'}} - Dropdown loading + 正在载入下拉 = icon('chevron-down') .dropdown-menu.dropdown-select.dropdown-menu-selectable.is-loading .dropdown-title - %span Dropdown Title - %button.dropdown-title-button.dropdown-menu-close{aria: {label: "Close"}} + %span 下拉标题 + %button.dropdown-title-button.dropdown-menu-close{aria: {label: "关闭"}} = icon('times') .dropdown-input - %input.dropdown-input-field{type: "search", placeholder: "Filter results"} + %input.dropdown-input-field{type: "search", placeholder: "过滤结果"} = icon('search') .dropdown-content %ul %li %a.is-active{href: "#"} - Dropdown Option + 下拉选项 %li %a{href: "#"} - Dropdown Option + 下拉选项 %li.divider %li %a{href: "#"} - Dropdown Option + 下拉选项 %li %a{href: "#"} - Dropdown Option + 下拉选项 %li %a{href: "#"} - Dropdown Option + 下拉选项 %li %a{href: "#"} - Dropdown Option + 下拉选项 %li %a{href: "#"} - Dropdown Option + 下拉选项 .dropdown-footer - %strong Tip: - If an author is not a member of this project, you can still filter by his name while using the search field. + %strong 提示: + 即使是非此项目的成员,你也能通过搜索框搜索到他的名字。 .dropdown-loading = icon('spinner spin') @@ -331,15 +330,15 @@ %div .dropdown.inline %button.dropdown-menu-toggle{type: 'button', data: {toggle: 'dropdown'}} - Dropdown user + 下拉用户 = icon('chevron-down') .dropdown-menu.dropdown-select.dropdown-menu-selectable.dropdown-menu-user .dropdown-title - %span Dropdown Title - %button.dropdown-title-button.dropdown-menu-close{aria: {label: "Close"}} + %span 下拉标题 + %button.dropdown-title-button.dropdown-menu-close{aria: {label: "关闭"}} = icon('times') .dropdown-input - %input.dropdown-input-field{type: "search", placeholder: "Filter results"} + %input.dropdown-input-field{type: "search", placeholder: "过滤结果"} = icon('search') .dropdown-content %ul @@ -355,18 +354,18 @@ %div .dropdown.inline %button.dropdown-menu-toggle{type: 'button', data: {toggle: 'dropdown'}} - Dropdown page 2 + 下拉页 2 = icon('chevron-down') .dropdown-menu.dropdown-select.dropdown-menu-selectable.dropdown-menu-user.dropdown-menu-paging.is-page-two .dropdown-page-one .dropdown-title - %button.dropdown-title-button.dropdown-menu-back{aria: {label: "Go back"}} + %button.dropdown-title-button.dropdown-menu-back{aria: {label: "返回"}} = icon('arrow-left') - %span Dropdown Title - %button.dropdown-title-button.dropdown-menu-close{aria: {label: "Close"}} + %span 下拉标题 + %button.dropdown-title-button.dropdown-menu-close{aria: {label: "关闭"}} = icon('times') .dropdown-input - %input.dropdown-input-field{type: "search", placeholder: "Filter results"} + %input.dropdown-input-field{type: "search", placeholder: "过滤结果"} = icon('search') .dropdown-content %ul @@ -379,30 +378,30 @@ = current_user.to_reference .dropdown-page-two .dropdown-title - %button.dropdown-title-button.dropdown-menu-back{aria: {label: "Go back"}} + %button.dropdown-title-button.dropdown-menu-back{aria: {label: "返回"}} = icon('arrow-left') - %span Create label - %button.dropdown-title-button.dropdown-menu-close{aria: {label: "Close"}} + %span 创建标记 + %button.dropdown-title-button.dropdown-menu-close{aria: {label: "关闭"}} = icon('times') .dropdown-input - %input.dropdown-input-field{type: "search", placeholder: "Name new label"} + %input.dropdown-input-field{type: "search", placeholder: "新标记名称"} .dropdown-content %button.btn.btn-primary - Create + 创建 .example %div .dropdown.inline %button#js-project-dropdown.dropdown-menu-toggle{type: 'button', data: {toggle: 'dropdown'}} - Projects + 项目 = icon('chevron-down') .dropdown-menu.dropdown-select.dropdown-menu-selectable .dropdown-title - %span Go to project - %button.dropdown-title-button.dropdown-menu-close{aria: {label: "Close"}} + %span 转到项目 + %button.dropdown-title-button.dropdown-menu-close{aria: {label: "关闭"}} = icon('times') .dropdown-input - %input.dropdown-input-field{type: "search", placeholder: "Filter results"} + %input.dropdown-input-field{type: "search", placeholder: "过滤结果"} = icon('search') .dropdown-content .dropdown-loading @@ -433,35 +432,35 @@ .example %div - = dropdown_tag("Projects", options: { title: "Go to project", filter: true, placeholder: "Filter projects" }) + = dropdown_tag("项目", options: { title: "转到项目", filter: true, placeholder: "过滤项目" }) - %h2#panels Panels + %h2#panels 面板 .row .col-md-6 .panel.panel-success - .panel-heading Success + .panel-heading 成功 .panel-body = lorem .panel.panel-primary - .panel-heading Primary + .panel-heading 主要 .panel-body = lorem .panel.panel-info - .panel-heading Info + .panel-heading 信息 .panel-body = lorem .col-md-6 .panel.panel-warning - .panel-heading Warning + .panel-heading 警告 .panel-body = lorem .panel.panel-danger - .panel-heading Danger + .panel-heading 危险 .panel-body = lorem - %h2#alert Alerts + %h2#alert 警告 .row .col-md-6 @@ -477,51 +476,51 @@ .alert.alert-danger = lorem - %h2#forms Forms + %h2#forms 表单 .lead - Horizontal form when label rendered inline with input + 输入框前带标签的横向表单 %code form.horizontal-form .example %form.form-horizontal .form-group - %label.col-sm-2.control-label{:for => "inputEmail3"} Email + %label.col-sm-2.control-label{:for => "inputEmail3"} 电子邮箱 .col-sm-10 - %input#inputEmail3.form-control{:placeholder => "Email", :type => "email"}/ + %input#inputEmail3.form-control{:placeholder => "电子邮箱", :type => "email"}/ .form-group - %label.col-sm-2.control-label{:for => "inputPassword3"} Password + %label.col-sm-2.control-label{:for => "inputPassword3"} 密码 .col-sm-10 - %input#inputPassword3.form-control{:placeholder => "Password", :type => "password"}/ + %input#inputPassword3.form-control{:placeholder => "密码", :type => "password"}/ .form-group .col-sm-offset-2.col-sm-10 .checkbox %label %input{:type => "checkbox"}/ - Remember me + 记住我 .form-group .col-sm-offset-2.col-sm-10 - %button.btn.btn-default{:type => "submit"} Sign in + %button.btn.btn-default{:type => "submit"} 登入 .lead - Form when label rendered above input + 输入框上方带标签的表单 %code form .example %form .form-group - %label{:for => "exampleInputEmail1"} Email address - %input#exampleInputEmail1.form-control{:placeholder => "Enter email", :type => "email"}/ + %label{:for => "exampleInputEmail1"} 电子邮箱地址 + %input#exampleInputEmail1.form-control{:placeholder => "输入电子邮箱", :type => "email"}/ .form-group - %label{:for => "exampleInputPassword1"} Password - %input#exampleInputPassword1.form-control{:placeholder => "Password", :type => "password"}/ + %label{:for => "exampleInputPassword1"} 密码 + %input#exampleInputPassword1.form-control{:placeholder => "密码", :type => "password"}/ .checkbox %label %input{:type => "checkbox"}/ - Remember me - %button.btn.btn-default{:type => "submit"} Sign in + 记住我 + %button.btn.btn-default{:type => "submit"} 登入 - %h2#file File + %h2#file 文件 %h4 %code .file-holder @@ -539,14 +538,14 @@ %h2#markdown Markdown %h4 - %code .md or .wiki and others + %code .md 或 .wiki 和其他 - Markdown rendering has a bit different css and presented in next UI elements: + Markdown 会在下列 UI 元素中使用,并具有一些不同的 css 展示效果: %ul - %li comment - %li issue, merge request description - %li wiki page - %li help page + %li 评论 + %li 问题、合并请求描述 + %li 维基页面 + %li 帮助页面 - You can check how markdown rendered at #{link_to 'Markdown help page', help_page_path("markdown", "markdown")}. + 你可以在 #{link_to 'Markdown 帮助页', help_page_path("markdown", "markdown")}中查看 markdown 展示详情。 diff --git a/app/views/layouts/_search.html.haml b/app/views/layouts/_search.html.haml index 54af2c3063c..621f531517a 100644 --- a/app/views/layouts/_search.html.haml +++ b/app/views/layouts/_search.html.haml @@ -1,6 +1,6 @@ .search = form_tag search_path, method: :get, class: 'navbar-form pull-left' do |f| - = search_field_tag "search", nil, placeholder: 'Search', class: "search-input form-control", spellcheck: false, tabindex: "1" + = search_field_tag "search", nil, placeholder: '搜索', class: "search-input form-control", spellcheck: false, tabindex: "1" = hidden_field_tag :group_id, @group.try(:id) - if @project && @project.persisted? = hidden_field_tag :project_id, @project.id diff --git a/app/views/layouts/header/_default.html.haml b/app/views/layouts/header/_default.html.haml index 0b1f5e034e1..e3ff9f4c9f9 100644 --- a/app/views/layouts/header/_default.html.haml +++ b/app/views/layouts/header/_default.html.haml @@ -10,36 +10,36 @@ %li.hidden-sm.hidden-xs = render 'layouts/search' %li.visible-sm.visible-xs - = link_to search_path, title: 'Search', data: {toggle: 'tooltip', placement: 'bottom', container: 'body'} do + = link_to search_path, title: '搜索', data: {toggle: 'tooltip', placement: 'bottom', container: 'body'} do = icon('search') - if current_user - if session[:impersonator_id] %li.impersonation - = link_to stop_impersonation_admin_users_path, method: :delete, title: 'Stop Impersonation', data: { toggle: 'tooltip', placement: 'bottom', container: 'body' } do + = link_to stop_impersonation_admin_users_path, method: :delete, title: '中止假冒', data: { toggle: 'tooltip', placement: 'bottom', container: 'body' } do = icon('user-secret fw') - if current_user.is_admin? %li - = link_to admin_root_path, title: 'Admin Area', data: {toggle: 'tooltip', placement: 'bottom', container: 'body'} do + = link_to admin_root_path, title: '管理区域', data: {toggle: 'tooltip', placement: 'bottom', container: 'body'} do = icon('wrench fw') %li - = link_to dashboard_todos_path, title: 'Todos', data: {toggle: 'tooltip', placement: 'bottom', container: 'body'} do + = link_to dashboard_todos_path, title: '待办事项', data: {toggle: 'tooltip', placement: 'bottom', container: 'body'} do %span.badge.todos-pending-count = todos_pending_count - if current_user.can_create_project? %li - = link_to new_project_path, title: 'New project', data: {toggle: 'tooltip', placement: 'bottom', container: 'body'} do + = link_to new_project_path, title: '新项目', data: {toggle: 'tooltip', placement: 'bottom', container: 'body'} do = icon('plus fw') - if Gitlab::Sherlock.enabled? %li - = link_to sherlock_transactions_path, title: 'Sherlock Transactions', + = link_to sherlock_transactions_path, title: '夏洛克事务', data: {toggle: 'tooltip', placement: 'bottom', container: 'body'} do = icon('tachometer fw') %li - = link_to destroy_user_session_path, class: 'logout', method: :delete, title: 'Sign out', data: {toggle: 'tooltip', placement: 'bottom', container: 'body'} do + = link_to destroy_user_session_path, class: 'logout', method: :delete, title: '退出', data: {toggle: 'tooltip', placement: 'bottom', container: 'body'} do = icon('sign-out') - else .pull-right - = link_to "Sign in", new_session_path(:user, redirect_to_referer: 'yes'), class: 'btn btn-sign-in btn-success' + = link_to "登入", new_session_path(:user, redirect_to_referer: 'yes'), class: 'btn btn-sign-in btn-success' %h1.title= title diff --git a/app/views/layouts/nav/_dashboard.html.haml b/app/views/layouts/nav/_dashboard.html.haml index 4a0069f18f8..1e2c6b9e787 100644 --- a/app/views/layouts/nav/_dashboard.html.haml +++ b/app/views/layouts/nav/_dashboard.html.haml @@ -1,56 +1,56 @@ %ul.nav.nav-sidebar = nav_link(path: ['root#index', 'projects#trending', 'projects#starred', 'dashboard/projects#index'], html_options: {class: 'home'}) do - = link_to dashboard_projects_path, title: 'Projects' do + = link_to dashboard_projects_path, title: '项目' do = icon('bookmark fw') %span - Projects + 项目 = nav_link(controller: :todos) do - = link_to dashboard_todos_path, title: 'Todos' do + = link_to dashboard_todos_path, title: '待办事项' do = icon('bell fw') %span - Todos + 待办事项 %span.count= number_with_delimiter(todos_pending_count) = nav_link(path: 'dashboard#activity') do - = link_to activity_dashboard_path, class: 'shortcuts-activity', title: 'Activity' do + = link_to activity_dashboard_path, class: 'shortcuts-activity', title: '活动' do = icon('dashboard fw') %span - Activity + 活动 = nav_link(controller: :groups) do - = link_to dashboard_groups_path, title: 'Groups' do + = link_to dashboard_groups_path, title: '群组' do = icon('group fw') %span - Groups + 群组 = nav_link(controller: :milestones) do - = link_to dashboard_milestones_path, title: 'Milestones' do + = link_to dashboard_milestones_path, title: '里程碑' do = icon('clock-o fw') %span - Milestones + 里程碑 = nav_link(path: 'dashboard#issues') do - = link_to assigned_issues_dashboard_path, title: 'Issues', class: 'shortcuts-issues' do + = link_to assigned_issues_dashboard_path, title: '问题', class: 'shortcuts-issues' do = icon('exclamation-circle fw') %span - Issues + 问题 %span.count= number_with_delimiter(current_user.assigned_issues.opened.count) = nav_link(path: 'dashboard#merge_requests') do - = link_to assigned_mrs_dashboard_path, title: 'Merge Requests', class: 'shortcuts-merge_requests' do + = link_to assigned_mrs_dashboard_path, title: '合并请求', class: 'shortcuts-merge_requests' do = icon('tasks fw') %span - Merge Requests + 合并请求 %span.count= number_with_delimiter(current_user.assigned_merge_requests.opened.count) = nav_link(controller: :snippets) do - = link_to dashboard_snippets_path, title: 'Snippets' do + = link_to dashboard_snippets_path, title: '代码片段' do = icon('clipboard fw') %span - Snippets + 代码片段 = nav_link(controller: :help) do - = link_to help_path, title: 'Help' do + = link_to help_path, title: '帮助' do = icon('question-circle fw') %span - Help + 帮助 %li.separate-item = nav_link(controller: :profile) do - = link_to profile_path, title: 'Profile Settings', data: {placement: 'bottom'} do + = link_to profile_path, title: '个人资料设置', data: {placement: 'bottom'} do = icon('user fw') %span - Profile Settings + 个人资料设置 diff --git a/app/views/layouts/nav/_explore.html.haml b/app/views/layouts/nav/_explore.html.haml index f08c5edf99c..8b5e61238cd 100644 --- a/app/views/layouts/nav/_explore.html.haml +++ b/app/views/layouts/nav/_explore.html.haml @@ -1,21 +1,21 @@ %ul.nav.nav-sidebar = nav_link(path: ['dashboard#show', 'root#show', 'projects#trending', 'projects#starred', 'projects#index'], html_options: {class: 'home'}) do - = link_to explore_root_path, title: 'Projects' do + = link_to explore_root_path, title: '项目' do = icon('bookmark fw') %span - Projects + 项目 = nav_link(controller: :groups) do - = link_to explore_groups_path, title: 'Groups' do + = link_to explore_groups_path, title: '群组' do = icon('group fw') %span - Groups + 群组 = nav_link(controller: :snippets) do - = link_to explore_snippets_path, title: 'Snippets' do + = link_to explore_snippets_path, title: '代码片段' do = icon('clipboard fw') %span - Snippets + 代码片段 = nav_link(controller: :help) do - = link_to help_path, title: 'Help' do + = link_to help_path, title: '帮助' do = icon('question-circle fw') %span - Help + 帮助 diff --git a/app/views/layouts/nav/_group.html.haml b/app/views/layouts/nav/_group.html.haml index 55940741dc0..6fc97a98c7a 100644 --- a/app/views/layouts/nav/_group.html.haml +++ b/app/views/layouts/nav/_group.html.haml @@ -1,49 +1,49 @@ %ul.nav.nav-sidebar = nav_link do - = link_to root_path, title: 'Go to dashboard', class: 'back-link' do + = link_to root_path, title: '转到仪表盘', class: 'back-link' do = icon('caret-square-o-left fw') %span - Go to dashboard + 转到仪表盘 %li.separate-item = nav_link(path: 'groups#show', html_options: {class: 'home'}) do - = link_to group_path(@group), title: 'Home' do + = link_to group_path(@group), title: '主页' do = icon('group fw') %span - Group + 群组 = nav_link(path: 'groups#activity') do - = link_to activity_group_path(@group), title: 'Activity' do + = link_to activity_group_path(@group), title: '活动' do = icon('dashboard fw') %span - Activity + 活动 = nav_link(controller: [:group, :milestones]) do - = link_to group_milestones_path(@group), title: 'Milestones' do + = link_to group_milestones_path(@group), title: '里程碑' do = icon('clock-o fw') %span - Milestones + 里程碑 = nav_link(path: 'groups#issues') do - = link_to issues_group_path(@group), title: 'Issues' do + = link_to issues_group_path(@group), title: '问题' do = icon('exclamation-circle fw') %span - Issues + 问题 - issues = IssuesFinder.new(current_user, group_id: @group.id, state: 'opened').execute %span.count= number_with_delimiter(issues.count) = nav_link(path: 'groups#merge_requests') do - = link_to merge_requests_group_path(@group), title: 'Merge Requests' do + = link_to merge_requests_group_path(@group), title: '合并请求' do = icon('tasks fw') %span - Merge Requests + 合并请求 - merge_requests = MergeRequestsFinder.new(current_user, group_id: @group.id, state: 'opened').execute %span.count= number_with_delimiter(merge_requests.count) = nav_link(controller: [:group_members]) do - = link_to group_group_members_path(@group), title: 'Members' do + = link_to group_group_members_path(@group), title: '成员' do = icon('users fw') %span - Members + 成员 - if can?(current_user, :admin_group, @group) = nav_link(html_options: { class: "separate-item" }) do - = link_to edit_group_path(@group), title: 'Settings' do + = link_to edit_group_path(@group), title: '设置' do = icon ('cogs fw') %span - Settings + 设置 diff --git a/app/views/layouts/nav/_profile.html.haml b/app/views/layouts/nav/_profile.html.haml index 3b9d31a6fc5..d6b5d9c24e7 100644 --- a/app/views/layouts/nav/_profile.html.haml +++ b/app/views/layouts/nav/_profile.html.haml @@ -1,59 +1,59 @@ %ul.nav.nav-sidebar = nav_link do - = link_to root_path, title: 'Go to dashboard', class: 'back-link' do + = link_to root_path, title: '转到仪表盘', class: 'back-link' do = icon('caret-square-o-left fw') %span - Go to dashboard + 转到仪表盘 %li.separate-item = nav_link(path: 'profiles#show', html_options: {class: 'home'}) do - = link_to profile_path, title: 'Profile Settings' do + = link_to profile_path, title: '个人资料设置' do = icon('user fw') %span - Profile Settings + 个人资料设置 = nav_link(controller: [:accounts, :two_factor_auths]) do - = link_to profile_account_path, title: 'Account' do + = link_to profile_account_path, title: '账号' do = icon('gear fw') %span - Account + 账号 = nav_link(controller: 'oauth/applications') do - = link_to applications_profile_path, title: 'Applications' do + = link_to applications_profile_path, title: '应用' do = icon('cloud fw') %span - Applications + 应用 = nav_link(controller: :emails) do - = link_to profile_emails_path, title: 'Emails' do + = link_to profile_emails_path, title: '电子邮箱' do = icon('envelope-o fw') %span - Emails + 电子邮箱 %span.count= number_with_delimiter(current_user.emails.count + 1) - unless current_user.ldap_user? = nav_link(controller: :passwords) do - = link_to edit_profile_password_path, title: 'Password' do + = link_to edit_profile_password_path, title: '密码' do = icon('lock fw') %span - Password + 密码 = nav_link(controller: :notifications) do - = link_to profile_notifications_path, title: 'Notifications' do + = link_to profile_notifications_path, title: '通知' do = icon('inbox fw') %span - Notifications + 通知 = nav_link(controller: :keys) do - = link_to profile_keys_path, title: 'SSH Keys' do + = link_to profile_keys_path, title: 'SSH 密钥' do = icon('key fw') %span - SSH Keys + SSH 密钥 %span.count= number_with_delimiter(current_user.keys.count) = nav_link(controller: :preferences) do - = link_to profile_preferences_path, title: 'Preferences' do + = link_to profile_preferences_path, title: '偏好设置' do -# TODO (rspeicher): Better icon? = icon('image fw') %span - Preferences + 偏好设置 = nav_link(path: 'profiles#audit_log') do - = link_to audit_log_profile_path, title: 'Audit Log' do + = link_to audit_log_profile_path, title: '审核日志' do = icon('history fw') %span - Audit Log + 审核日志 diff --git a/app/views/layouts/nav/_project.html.haml b/app/views/layouts/nav/_project.html.haml index 86b46e8c75e..db12aab98fb 100644 --- a/app/views/layouts/nav/_project.html.haml +++ b/app/views/layouts/nav/_project.html.haml @@ -1,126 +1,126 @@ %ul.nav.nav-sidebar - if @project.group = nav_link do - = link_to group_path(@project.group), title: 'Go to group', class: 'back-link' do + = link_to group_path(@project.group), title: '转到群组', class: 'back-link' do = icon('caret-square-o-left fw') %span - Go to group + 转到群组 - else = nav_link do - = link_to root_path, title: 'Go to dashboard', class: 'back-link' do + = link_to root_path, title: '转到仪表盘', class: 'back-link' do = icon('caret-square-o-left fw') %span - Go to dashboard + 转到仪表盘 %li.separate-item = nav_link(path: 'projects#show', html_options: {class: 'home'}) do - = link_to project_path(@project), title: 'Project', class: 'shortcuts-project' do + = link_to project_path(@project), title: '项目', class: 'shortcuts-project' do = icon('bookmark fw') %span - Project + 项目 = nav_link(path: 'projects#activity') do - = link_to activity_project_path(@project), title: 'Activity', class: 'shortcuts-project-activity' do + = link_to activity_project_path(@project), title: '活动', class: 'shortcuts-project-activity' do = icon('dashboard fw') %span - Activity + 活动 - if project_nav_tab? :files = nav_link(controller: %w(tree blob blame edit_tree new_tree find_file)) do - = link_to project_files_path(@project), title: 'Files', class: 'shortcuts-tree' do + = link_to project_files_path(@project), title: '文件', class: 'shortcuts-tree' do = icon('files-o fw') %span - Files + 文件 - if project_nav_tab? :commits = nav_link(controller: %w(commit commits compare repositories tags branches releases network)) do - = link_to project_commits_path(@project), title: 'Commits', class: 'shortcuts-commits' do + = link_to project_commits_path(@project), title: '提交', class: 'shortcuts-commits' do = icon('history fw') %span - Commits + 提交 - if project_nav_tab? :builds = nav_link(controller: %w(builds)) do - = link_to project_builds_path(@project), title: 'Builds', class: 'shortcuts-builds' do + = link_to project_builds_path(@project), title: '构建', class: 'shortcuts-builds' do = icon('cubes fw') %span - Builds + 构建 %span.count.builds_counter= number_with_delimiter(@project.builds.running_or_pending.count(:all)) - if project_nav_tab? :graphs = nav_link(controller: %w(graphs)) do - = link_to namespace_project_graph_path(@project.namespace, @project, current_ref), title: 'Graphs', class: 'shortcuts-graphs' do + = link_to namespace_project_graph_path(@project.namespace, @project, current_ref), title: '图表', class: 'shortcuts-graphs' do = icon('area-chart fw') %span - Graphs + 图表 - if project_nav_tab? :milestones = nav_link(controller: :milestones) do - = link_to namespace_project_milestones_path(@project.namespace, @project), title: 'Milestones' do + = link_to namespace_project_milestones_path(@project.namespace, @project), title: '里程碑' do = icon('clock-o fw') %span - Milestones + 里程碑 - if project_nav_tab? :issues = nav_link(controller: :issues) do - = link_to url_for_project_issues(@project, only_path: true), title: 'Issues', class: 'shortcuts-issues' do + = link_to url_for_project_issues(@project, only_path: true), title: '问题', class: 'shortcuts-issues' do = icon('exclamation-circle fw') %span - Issues + 问题 - if @project.default_issues_tracker? %span.count.issue_counter= number_with_delimiter(@project.issues.visible_to_user(current_user).opened.count) - if project_nav_tab? :merge_requests = nav_link(controller: :merge_requests) do - = link_to namespace_project_merge_requests_path(@project.namespace, @project), title: 'Merge Requests', class: 'shortcuts-merge_requests' do + = link_to namespace_project_merge_requests_path(@project.namespace, @project), title: '合并请求', class: 'shortcuts-merge_requests' do = icon('tasks fw') %span - Merge Requests + 合并请求 %span.count.merge_counter= number_with_delimiter(@project.merge_requests.opened.count) - if project_nav_tab? :settings = nav_link(controller: [:project_members, :teams]) do - = link_to namespace_project_project_members_path(@project.namespace, @project), title: 'Members', class: 'team-tab tab' do + = link_to namespace_project_project_members_path(@project.namespace, @project), title: '成员', class: 'team-tab tab' do = icon('users fw') %span - Members + 成员 - if project_nav_tab? :labels = nav_link(controller: :labels) do - = link_to namespace_project_labels_path(@project.namespace, @project), title: 'Labels' do + = link_to namespace_project_labels_path(@project.namespace, @project), title: '标记' do = icon('tags fw') %span - Labels + 标记 - if project_nav_tab? :wiki = nav_link(controller: :wikis) do - = link_to get_project_wiki_path(@project), title: 'Wiki', class: 'shortcuts-wiki' do + = link_to get_project_wiki_path(@project), title: '维基', class: 'shortcuts-wiki' do = icon('book fw') %span - Wiki + 维基 - if project_nav_tab? :forks = nav_link(controller: :forks, action: :index) do - = link_to namespace_project_forks_path(@project.namespace, @project), title: 'Forks' do + = link_to namespace_project_forks_path(@project.namespace, @project), title: '派生' do = icon('code-fork fw') %span - Forks + 派生 - if project_nav_tab? :snippets = nav_link(controller: :snippets) do - = link_to namespace_project_snippets_path(@project.namespace, @project), title: 'Snippets', class: 'shortcuts-snippets' do + = link_to namespace_project_snippets_path(@project.namespace, @project), title: '代码片段', class: 'shortcuts-snippets' do = icon('clipboard fw') %span - Snippets + 代码片段 - if project_nav_tab? :settings = nav_link(html_options: {class: "#{project_tab_class} separate-item"}) do - = link_to edit_project_path(@project), title: 'Settings' do + = link_to edit_project_path(@project), title: '设置' do = icon('cogs fw') %span - Settings + 设置 -# Global shortcut to network page for compatibility - if project_nav_tab? :network %li.hidden - = link_to namespace_project_network_path(@project.namespace, @project, current_ref), title: 'Network', class: 'shortcuts-network' do - Network + = link_to namespace_project_network_path(@project.namespace, @project, current_ref), title: '网络', class: 'shortcuts-network' do + 网络 diff --git a/app/views/layouts/nav/_project_settings.html.haml b/app/views/layouts/nav/_project_settings.html.haml index 2ebea4ae51d..a237144a33d 100644 --- a/app/views/layouts/nav/_project_settings.html.haml +++ b/app/views/layouts/nav/_project_settings.html.haml @@ -1,44 +1,44 @@ %ul.nav.nav-sidebar = nav_link do - = link_to project_path(@project), title: 'Go to project', class: 'back-link' do + = link_to project_path(@project), title: '转到项目', class: 'back-link' do = icon('caret-square-o-left fw') %span - Go to project + 转到项目 %li.separate-item %ul.sidebar-subnav = nav_link(path: 'projects#edit') do - = link_to edit_project_path(@project), title: 'Project Settings' do + = link_to edit_project_path(@project), title: '项目设置' do = icon('pencil-square-o fw') %span - Project Settings + 项目设置 - if @project.allowed_to_share_with_group? = nav_link(controller: :group_links) do - = link_to namespace_project_group_links_path(@project.namespace, @project), title: "Groups" do + = link_to namespace_project_group_links_path(@project.namespace, @project), title: "群组" do = icon('share-square-o fw') %span - Groups + 群组 = nav_link(controller: :deploy_keys) do - = link_to namespace_project_deploy_keys_path(@project.namespace, @project), title: 'Deploy Keys' do + = link_to namespace_project_deploy_keys_path(@project.namespace, @project), title: '部署密钥' do = icon('key fw') %span - Deploy Keys + 部署密钥 = nav_link(controller: :hooks) do - = link_to namespace_project_hooks_path(@project.namespace, @project), title: 'Webhooks' do + = link_to namespace_project_hooks_path(@project.namespace, @project), title: 'Web 钩子' do = icon('link fw') %span - Webhooks + Web 钩子 = nav_link(controller: :services) do - = link_to namespace_project_services_path(@project.namespace, @project), title: 'Services' do + = link_to namespace_project_services_path(@project.namespace, @project), title: '服务' do = icon('cogs fw') %span - Services + 服务 = nav_link(controller: :protected_branches) do - = link_to namespace_project_protected_branches_path(@project.namespace, @project), title: 'Protected Branches' do + = link_to namespace_project_protected_branches_path(@project.namespace, @project), title: '保护分支' do = icon('lock fw') %span - Protected Branches + 保护分支 - if @project.builds_enabled? = nav_link(controller: :runners) do diff --git a/app/views/layouts/notify.html.haml b/app/views/layouts/notify.html.haml index 2997f59d946..57fce3d9ddc 100644 --- a/app/views/layouts/notify.html.haml +++ b/app/views/layouts/notify.html.haml @@ -13,20 +13,20 @@ %br - if @target_url - if @reply_by_email - Reply to this email directly or - #{link_to "view it on GitLab", @target_url}. + 直接回复此邮件或 + #{link_to "在 GitLab 上查看", @target_url}. - else - #{link_to "View it on GitLab", @target_url}. + #{link_to "在 GitLab 上查看", @target_url}. %br -# Don't link the host in the line below, one link in the email is easier to quickly click than two. - You're receiving this email because of your account on #{Gitlab.config.gitlab.host}. - If you'd like to receive fewer emails, you can + 因为你在 #{Gitlab.config.gitlab.host} 拥有账号,所以会收到此通知。 + 如果你不喜欢接受此类通知邮件,你可以在通知设置中调整设置 - if @labels_url adjust your #{link_to 'label subscriptions', @labels_url}. - else - if @sent_notification && @sent_notification.unsubscribable? - = link_to "unsubscribe", unsubscribe_sent_notification_url(@sent_notification) - from this thread or - adjust your notification settings. + 或在此主题中 + = link_to "取消订阅", unsubscribe_sent_notification_url(@sent_notification) + 。 = email_action @target_url diff --git a/app/views/notify/_reassigned_issuable_email.text.erb b/app/views/notify/_reassigned_issuable_email.text.erb index daf20a226dd..876dbc62643 100644 --- a/app/views/notify/_reassigned_issuable_email.text.erb +++ b/app/views/notify/_reassigned_issuable_email.text.erb @@ -1,6 +1,6 @@ -Reassigned <%= issuable.class.model_name.human.titleize %> <%= issuable.iid %> +重新指派 <%= issuable.class.model_name.human.titleize %> <%= issuable.iid %> <%= url_for([issuable.project.namespace.becomes(Namespace), issuable.project, issuable, { only_path: false }]) %> -Assignee changed <%= "from #{@previous_assignee.name}" if @previous_assignee -%> - to <%= "#{issuable.assignee_id ? issuable.assignee_name : 'Unassigned'}" %> +改变指派 <%= "from #{@previous_assignee.name}" if @previous_assignee -%> + 到 <%= "#{issuable.assignee_id ? issuable.assignee_name : '未指派'}" %> diff --git a/app/views/profiles/_event_table.html.haml b/app/views/profiles/_event_table.html.haml index 879fc170f92..e05f8ca214e 100644 --- a/app/views/profiles/_event_table.html.haml +++ b/app/views/profiles/_event_table.html.haml @@ -1,15 +1,15 @@ %h5.prepend-top-0 - History of authentications + 认证历史记录 %ul.well-list - events.each do |event| %li %span.description = audit_icon(event.details[:with], class: "append-right-5") - Signed in with + 使用 = event.details[:with] - authentication + 认证登入 %span.pull-right - #{time_ago_in_words event.created_at} ago + #{time_ago_in_words event.created_at}之前 = paginate events, theme: "gitlab" diff --git a/app/views/profiles/accounts/show.html.haml b/app/views/profiles/accounts/show.html.haml index 6efd119f260..c0b5e84f3cf 100644 --- a/app/views/profiles/accounts/show.html.haml +++ b/app/views/profiles/accounts/show.html.haml @@ -1,117 +1,117 @@ -- page_title "Account" +- page_title "账号" - header_title page_title, profile_account_path - if current_user.ldap_user? .alert.alert-info - Some options are unavailable for LDAP accounts + 部分设置对于 LDAP 账号无效 .row.prepend-top-default .col-lg-3.profile-settings-sidebar %h4.prepend-top-0 - Private Token + 私有授权 %p - Your private token is used to access application resources without authentication. + 私有授权可以免登录访问应用资源。 .col-lg-9 = form_for @user, url: reset_private_token_profile_path, method: :put, html: {class: "private-token"} do |f| %p.cgray - if current_user.private_token - = label_tag "token", "Private token", class: "label-light" + = label_tag "token", "私有授权", class: "label-light" = text_field_tag "token", current_user.private_token, class: "form-control" - else - %span You don`t have one yet. Click generate to fix it. + %span 没有私有授权,点生成按钮可修复。 %p.help-block - It can be used for atom feeds or the API. Keep it secret! + 通常在 RSS 和 API 中使用。注意保密! .prepend-top-default - if current_user.private_token - = f.submit 'Reset private token', data: { confirm: "Are you sure?" }, class: "btn btn-default" + = f.submit '重置私有授权', data: { confirm: "确定要继续么?" }, class: "btn btn-default" - else - = f.submit 'Generate', class: "btn btn-default" + = f.submit '生成', class: "btn btn-default" %hr .row.prepend-top-default .col-lg-3.profile-settings-sidebar %h4.prepend-top-0 - Two-factor Authentication + 两步验证 %p - Increase your account's security by enabling two-factor authentication (2FA). + 开启两步验证 (2FA) 增加账户安全性。 .col-lg-9 %p - Status: #{current_user.two_factor_enabled? ? 'enabled' : 'disabled'} + 状态:#{current_user.two_factor_enabled? ? '已启用' : '已禁用'} - if !current_user.two_factor_enabled? %p - Download the Google Authenticator application from App Store for iOS or Google Play for Android and scan this code. - More information is available in the #{link_to('documentation', help_page_path('profile', 'two_factor_authentication'))}. + 请从 iOS 的 App Store 或 Android 的 Google Play 下载谷歌身份验证器 (Google Authenticator) 应用,然后扫描下面的二维码。 + 更多可用的信息请参阅此#{link_to('文档', help_page_path('profile', 'two_factor_authentication'))}。 .append-bottom-10 - = link_to 'Enable two-factor authentication', new_profile_two_factor_auth_path, class: 'btn btn-success' + = link_to '开启两步验证', new_profile_two_factor_auth_path, class: 'btn btn-success' - else - = link_to 'Disable Two-factor Authentication', profile_two_factor_auth_path, method: :delete, class: 'btn btn-danger', - data: { confirm: 'Are you sure?' } + = link_to '禁用两步验证', profile_two_factor_auth_path, method: :delete, class: 'btn btn-danger', + data: { confirm: '确定要继续么?' } %hr - if button_based_providers.any? .row.prepend-top-default .col-lg-3.profile-settings-sidebar %h4.prepend-top-0 - Social sign-in + 社会化登入 %p - Activate signin with one of the following services + 激活下列登入服务 .col-lg-9 %label.label-light - Connected Accounts - %p Click on icon to activate signin with one of the following services + 连接到的账户 + %p 点击下列服务的图标激活第三方登入 - button_based_providers.each do |provider| .provider-btn-group .provider-btn-image = provider_image_tag(provider) - if auth_active?(provider) = link_to unlink_profile_account_path(provider: provider), method: :delete, class: 'provider-btn' do - Disconnect + 断开 - else = link_to user_omniauth_authorize_path(provider), method: :post, class: "provider-btn #{'not-active' if !auth_active?(provider)}", "data-no-turbolink" => "true" do - Connect + 连接 %hr - if current_user.can_change_username? .row.prepend-top-default .col-lg-3.profile-settings-sidebar %h4.prepend-top-0.change-username-title - Change username + 修改用户名 %p - Changing your username will change path to all personal projects! + 修改用户名会同时修改全部个人项目的路径! .col-lg-9 = form_for @user, url: update_username_profile_path, method: :put, remote: true, html: {class: "update-username"} do |f| .form-group - = f.label :username, "Path", class: "label-light" + = f.label :username, "路径", class: "label-light" .input-group .input-group-addon = "#{root_url}u/" = f.text_field :username, required: true, class: 'form-control' .help-block - Current path: + 当前路径: = "#{root_url}u/#{current_user.username}" .prepend-top-default = f.button class: "btn btn-warning", type: "submit" do = icon "spinner spin", class: "hidden loading-username" - Update username + 更新用户名 %hr - if signup_enabled? .row.prepend-top-default .col-lg-3.profile-settings-sidebar %h4.prepend-top-0.remove-account-title - Remove account + 删除账号 .col-lg-9 - if @user.can_be_removed? %p - Deleting an account has the following effects: + 删除账号会有以下影响: %ul - %li All user content like authored issues, snippets, comments will be removed + %li 全部用户内容,比如:问题、代码片段、注释将被删除 - rp = current_user.personal_projects.count - unless rp.zero? - %li #{pluralize rp, 'personal project'} will be removed and cannot be restored - = link_to 'Delete account', user_registration_path, data: { confirm: "REMOVE #{current_user.name}? Are you sure?" }, method: :delete, class: "btn btn-remove" + %li #{pluralize rp, '个个人项目', '个个人项目'}将被删除且无法恢复 + = link_to '删除账号', user_registration_path, data: { confirm: "确定要删除 #{current_user.name} 么?" }, method: :delete, class: "btn btn-remove" - else - if @user.solo_owned_groups.present? %p - Your account is currently an owner in these groups: + 你的账号当前是下列群组的拥有者: %strong #{@user.solo_owned_groups.map(&:name).join(', ')} %p - You must transfer ownership or delete these groups before you can delete your account. + 请在删除账号前转移群组所有权或删除之。 .append-bottom-default diff --git a/app/views/profiles/audit_log.html.haml b/app/views/profiles/audit_log.html.haml index f630c03e5f6..933fe4699a4 100644 --- a/app/views/profiles/audit_log.html.haml +++ b/app/views/profiles/audit_log.html.haml @@ -1,4 +1,4 @@ -- page_title "Audit Log" +- page_title "审核日志" - header_title page_title, audit_log_profile_path .row.prepend-top-default @@ -6,6 +6,6 @@ %h3.prepend-top-0 = page_title %p - This is a security log of important events involving your account. + 这是涉及您的帐户安全的重要事件日志。 .col-lg-9 = render 'event_table', events: @events diff --git a/app/views/profiles/emails/index.html.haml b/app/views/profiles/emails/index.html.haml index 3f328f96cea..2d31d88e81b 100644 --- a/app/views/profiles/emails/index.html.haml +++ b/app/views/profiles/emails/index.html.haml @@ -1,4 +1,4 @@ -- page_title "Emails" +- page_title "电子邮箱" - header_title page_title, profile_emails_path .row.prepend-top-default @@ -6,44 +6,44 @@ %h4.prepend-top-0 = page_title %p - Control emails linked to your account + 管理您的账号连接的电子邮箱 .col-lg-9 %h4.prepend-top-0 - Add email address + 增加电子邮箱地址 = form_for 'email', url: profile_emails_path do |f| .form-group - = f.label :email, class: 'label-light' + = f.label :email, '电子邮箱', class: 'label-light' = f.text_field :email, class: 'form-control' .prepend-top-default - = f.submit 'Add email address', class: 'btn btn-create' + = f.submit '增加电子邮箱地址', class: 'btn btn-create' %hr %h4.prepend-top-0 - Linked emails (#{@emails.count + 1}) + 连接的电子邮箱 (#{@emails.count + 1}) .account-well.append-bottom-default %ul %li - Your Primary Email will be used for avatar detection and web based operations, such as edits and merges. + 你的主要电子邮箱将用于头像显示和在网站操作,比如:编辑和合并操作。 %li - Your Notification Email will be used for account notifications. + 你的通知电子邮箱将用于账号通知。 %li - Your Public Email will be displayed on your public profile. + 你的公开电子邮箱将显示在公开的个人资料上。 %li - All email addresses will be used to identify your commits. + 所有电子邮箱地址都将用于识别提交作者。 %ul.well-list %li = @primary %span.pull-right - %span.label.label-success Primary Email + %span.label.label-success 主要电子邮箱 - if @primary === current_user.public_email - %span.label.label-info Public Email + %span.label.label-info 公开电子邮箱 - if @primary === current_user.notification_email - %span.label.label-info Notification Email + %span.label.label-info 通知电子邮箱 - @emails.each do |email| %li = email.email %span.pull-right - if email.email === current_user.public_email - %span.label.label-info Public Email + %span.label.label-info 公开电子邮箱 - if email.email === current_user.notification_email - %span.label.label-info Notification Email - = link_to 'Remove', profile_email_path(email), data: { confirm: 'Are you sure?'}, method: :delete, class: 'btn btn-sm btn-remove pull-right' + %span.label.label-info 通知电子邮箱 + = link_to '删除', profile_email_path(email), data: { confirm: '确定要继续么?'}, method: :delete, class: 'btn btn-sm btn-remove pull-right' diff --git a/app/views/profiles/keys/_form.html.haml b/app/views/profiles/keys/_form.html.haml index 4d78215ed3c..e2c1c7b13a5 100644 --- a/app/views/profiles/keys/_form.html.haml +++ b/app/views/profiles/keys/_form.html.haml @@ -7,11 +7,11 @@ %li= msg .form-group - = f.label :key, class: 'label-light' + = f.label :key, "公钥", class: 'label-light' = f.text_area :key, class: "form-control", rows: 8, required: true .form-group - = f.label :title, class: 'label-light' + = f.label :title, "标题", class: 'label-light' = f.text_field :title, class: "form-control", required: true .prepend-top-default - = f.submit 'Add key', class: "btn btn-create" + = f.submit '增加密钥', class: "btn btn-create" diff --git a/app/views/profiles/keys/_key.html.haml b/app/views/profiles/keys/_key.html.haml index 4dbaa662b66..7081eb1e252 100644 --- a/app/views/profiles/keys/_key.html.haml +++ b/app/views/profiles/keys/_key.html.haml @@ -8,7 +8,7 @@ = key.fingerprint .pull-right %span.key-created-at - created #{time_ago_with_tooltip(key.created_at)} - = link_to path_to_key(key, is_admin), data: { confirm: 'Are you sure?'}, method: :delete, class: "btn btn-transparent prepend-left-10" do - %span.sr-only Remove + 创建时间 #{time_ago_with_tooltip(key.created_at)} + = link_to path_to_key(key, is_admin), data: { confirm: '确定要继续么?'}, method: :delete, class: "btn btn-transparent prepend-left-10" do + %span.sr-only 删除 = icon('trash') diff --git a/app/views/profiles/keys/_key_table.html.haml b/app/views/profiles/keys/_key_table.html.haml index 296cafa6e31..6004d30e158 100644 --- a/app/views/profiles/keys/_key_table.html.haml +++ b/app/views/profiles/keys/_key_table.html.haml @@ -6,6 +6,6 @@ - else %p.profile-settings-message.text-center - if is_admin - There are no SSH keys associated with this account. + 该账号没有 ssh 密钥。 - else - There are no SSH keys with access to your account. + 您的账号没有 SSH 密钥。 diff --git a/app/views/profiles/keys/index.html.haml b/app/views/profiles/keys/index.html.haml index e0f8c9a5733..aa6e278bccd 100644 --- a/app/views/profiles/keys/index.html.haml +++ b/app/views/profiles/keys/index.html.haml @@ -1,4 +1,4 @@ -- page_title "SSH Keys" +- page_title "SSH 密钥" - header_title page_title, profile_keys_path .row.prepend-top-default @@ -6,16 +6,16 @@ %h4.prepend-top-0 = page_title %p - SSH keys allow you to establish a secure connection between your computer and GitLab. + SSH 密钥用于在您的电脑和 GitLab 建立安全连接。 .col-lg-9 %h5.prepend-top-0 - Add an SSH key + 增加 SSH 密钥 %p.profile-settings-content - Before you can add an SSH key you need to - = link_to "generate it.", help_page_path("ssh", "README") + 在增加 SSH 密钥之前需要先 + = link_to "生成密钥。", help_page_path("ssh", "README") = render 'form' %hr %h5 - Your SSH keys (#{@keys.count}) + 您的 SSH 密钥 (#{@keys.count}) %div.append-bottom-default = render 'key_table' diff --git a/app/views/profiles/notifications/show.html.haml b/app/views/profiles/notifications/show.html.haml index de80abd7f4d..2e694ead335 100644 --- a/app/views/profiles/notifications/show.html.haml +++ b/app/views/profiles/notifications/show.html.haml @@ -1,4 +1,4 @@ -- page_title "Notifications" +- page_title "通知" - header_title page_title, profile_notifications_path = form_for @user, url: profile_notifications_path, method: :put, html: { class: 'update-notifications prepend-top-default' } do |f| @@ -14,59 +14,59 @@ %h4 = page_title %p - You can specify notification level per group or per project. + 你也可以单独指定每个群组或项目的通知等级。 %p - By default, all projects and groups will use the global notifications setting. + 所有项目和群组默认使用全局通知设置。 .col-lg-9 %h5 - Global notification settings + 全局通知设置 .form-group - = f.label :notification_email, class: "label-light" + = f.label :notification_email, '通知电子邮箱', class: "label-light" = f.select :notification_email, @user.all_emails, { include_blank: false }, class: "select2" .form-group - = f.label :notification_level, class: 'label-light' + = f.label :notification_level, '通知等级', class: 'label-light' .radio = f.label :notification_level, value: Notification::N_DISABLED do = f.radio_button :notification_level, Notification::N_DISABLED .level-title - Disabled - %p You will not get any notifications via email + 关闭 + %p 将不会通过电子邮件收到任何通知 .radio = f.label :notification_level, value: Notification::N_MENTION do = f.radio_button :notification_level, Notification::N_MENTION .level-title - On Mention - %p You will receive notifications only for comments in which you were @mentioned + 被提及 + %p 只收到评论中 @自己 的通知 .radio = f.label :notification_level, value: Notification::N_PARTICIPATING do = f.radio_button :notification_level, Notification::N_PARTICIPATING .level-title - Participating - %p You will only receive notifications from related resources (e.g. from your commits or assigned issues) + 参与 + %p 只收到有关的通知 (比如:来自自己的提交或指派给自己的问题) .radio = f.label :notification_level, value: Notification::N_WATCH do = f.radio_button :notification_level, Notification::N_WATCH .level-title - Watch - %p You will receive notifications for any activity + 关注 + %p 将收到参与项目的所有通知 .prepend-top-default - = f.submit 'Update settings', class: "btn btn-create" + = f.submit '更新设置', class: "btn btn-create" %hr %h5 - Groups (#{@group_members.count}) + 群组 (#{@group_members.count}) %div %ul.bordered-list - @group_members.each do |group_member| - notification = Notification.new(group_member) = render 'settings', type: 'group', membership: group_member, notification: notification %h5 - Projects (#{@project_members.count}) + 项目 (#{@project_members.count}) %p.account-well - To specify the notification level per project of a group you belong to, you need to be a member of the project itself, not only its group. + 给所属群组的项目指定通知等级,需要自己属于项目成员,而不仅仅是群组成员。 .append-bottom-default %ul.bordered-list - @project_members.each do |project_member| diff --git a/app/views/profiles/passwords/edit.html.haml b/app/views/profiles/passwords/edit.html.haml index afd4f996b62..6144679553a 100644 --- a/app/views/profiles/passwords/edit.html.haml +++ b/app/views/profiles/passwords/edit.html.haml @@ -1,4 +1,4 @@ -- page_title "Password" +- page_title "密码" - header_title page_title, edit_profile_password_path .row.prepend-top-default @@ -6,12 +6,12 @@ %h4.prepend-top-0 = page_title %p - After a successful password update, you will be redirected to the login page where you can log in with your new password. + 密码被成功修改后将会重定向到登录页面使用新密码重新登录。 .col-lg-9 %h5.prepend-top-0 - Change your password + 修改密码 - unless @user.password_automatically_set? - or recover your current one + 或恢复当前密码 = form_for @user, url: profile_password_path, method: :put, html: {class: "update-password"} do |f| -if @user.errors.any? .alert.alert-danger @@ -20,16 +20,16 @@ %li= msg - unless @user.password_automatically_set? .form-group - = f.label :current_password, class: 'label-light' + = f.label :current_password, '当前密码', class: 'label-light' = f.password_field :current_password, required: true, class: 'form-control' %p.help-block - You must provide your current password in order to change it. + 必须提供当前密码才能修改密码。 .form-group - = f.label :password, 'New password', class: 'label-light' + = f.label :password, '新密码', class: 'label-light' = f.password_field :password, required: true, class: 'form-control' .form-group - = f.label :password_confirmation, class: 'label-light' + = f.label :password_confirmation, '确认密码', class: 'label-light' = f.password_field :password_confirmation, required: true, class: 'form-control' .prepend-top-default.append-bottom-default - = f.submit 'Save password', class: "btn btn-create append-right-10" - = link_to "I forgot my password", reset_profile_password_path, method: :put, class: "account-btn-link" + = f.submit '保存密码', class: "btn btn-create append-right-10" + = link_to "我忘记了自己的密码", reset_profile_password_path, method: :put, class: "account-btn-link" diff --git a/app/views/profiles/preferences/show.html.haml b/app/views/profiles/preferences/show.html.haml index f80211669fb..80694f196fd 100644 --- a/app/views/profiles/preferences/show.html.haml +++ b/app/views/profiles/preferences/show.html.haml @@ -1,12 +1,12 @@ -- page_title 'Preferences' +- page_title '偏好设置' - header_title page_title, profile_preferences_path = form_for @user, url: profile_preferences_path, remote: true, method: :put, html: {class: 'row prepend-top-default js-preferences-form'} do |f| .col-lg-3.profile-settings-sidebar %h4.prepend-top-0 - Application theme + 程序主题 %p - This setting allows you to customize the appearance of the site, ex. sidebar. + 此设置允许自定义本站点的外观和行为,比如边栏。 .col-lg-9.application-theme - Gitlab::Themes.each do |theme| = label_tag do @@ -17,9 +17,9 @@ %hr .col-lg-3.profile-settings-sidebar %h4.prepend-top-0 - Syntax highlighting theme + 语法高亮主题 %p - This setting allow you to customize the appearance of the syntax. + 此设置允许自定义语法显示。 .col-lg-9.syntax-theme - Gitlab::ColorSchemes.each do |scheme| = label_tag do @@ -30,27 +30,27 @@ %hr .col-lg-3.profile-settings-sidebar %h4.prepend-top-0 - Behavior + 行为 %p - This setting allows you to customize the behavior of the system layout and default views. + 此设置允许自定义系统布局和默认视图的行为。 .col-lg-9 .form-group = f.label :layout, class: 'label-light' do - Layout width + 页面宽度 = f.select :layout, layout_choices, {}, class: 'form-control' .help-block - Choose between fixed (max. 1200px) and fluid (100%) application layout. + 选择固定 (最大 1200px) 或自适应 (100%) 页面宽度。 .form-group = f.label :dashboard, class: 'label-light' do - Default Dashboard + 默认仪表盘 = link_to('(?)', help_page_path('profile', 'preferences') + '#default-dashboard', target: '_blank') = f.select :dashboard, dashboard_choices, {}, class: 'form-control' .form-group = f.label :project_view, class: 'label-light' do - Project view + 项目视图 = link_to('(?)', help_page_path('profile', 'preferences') + '#default-project-view', target: '_blank') = f.select :project_view, project_view_choices, {}, class: 'form-control' .help-block - Choose what content you want to see on a project's home page. + 选择访问项目页面时看到的内容。 .form-group - = f.submit 'Save changes', class: 'btn btn-save' + = f.submit '保存修改', class: 'btn btn-save' diff --git a/app/views/profiles/show.html.haml b/app/views/profiles/show.html.haml index cd582ba7060..355eb224377 100644 --- a/app/views/profiles/show.html.haml +++ b/app/views/profiles/show.html.haml @@ -7,52 +7,52 @@ .row .col-lg-3.profile-settings-sidebar %h4.prepend-top-0 - Public Avatar + 公开头像 %p - if @user.avatar? - You can change your avatar here + 在这里修改头像 - if Gitlab.config.gravatar.enabled - or remove the current avatar to revert to #{link_to Gitlab.config.gravatar.host, "http://" + Gitlab.config.gravatar.host} + 或者删除当前头像使用 #{link_to Gitlab.config.gravatar.host, "http://" + Gitlab.config.gravatar.host} 头像 - else - You can upload an avatar here + 在这里上传头像 - if Gitlab.config.gravatar.enabled - or change it at #{link_to Gitlab.config.gravatar.host, "http://" + Gitlab.config.gravatar.host} + 或者在 #{link_to Gitlab.config.gravatar.host, "http://" + Gitlab.config.gravatar.host} 修改头像 .col-lg-9 .clearfix.avatar-image.append-bottom-default = image_tag avatar_icon(@user, 160), alt: '', class: 'avatar s160' %h5.prepend-top-0 - Upload new avatar + 上传新的头像 .prepend-top-5.append-bottom-10 %a.btn.js-choose-user-avatar-button - Browse file... - %span.avatar-file-name.prepend-left-default.js-avatar-filename No file chosen + 浏览文件... + %span.avatar-file-name.prepend-left-default.js-avatar-filename 没有选择文件 = f.file_field :avatar, class: "js-user-avatar-input hidden" .help-block - The maximum file size allowed is 200KB. + 允许的最大文件大小 200KB。 - if @user.avatar? %hr - = link_to 'Remove avatar', profile_avatar_path, data: { confirm: "Avatar will be removed. Are you sure?"}, method: :delete, class: "btn btn-gray" + = link_to '删除头像', profile_avatar_path, data: { confirm: "确定要删除头像么?"}, method: :delete, class: "btn btn-gray" %hr .row .col-lg-3.profile-settings-sidebar %h4.prepend-top-0 - Main settings + 主要设置 %p - This information will appear on your profile. + 此信息会显示在个人资料页面上。 - if current_user.ldap_user? - Some options are unavailable for LDAP accounts + 部分设置对于 LDAP 账号无效 .col-lg-9 .form-group - = f.label :name, class: "label-light" + = f.label :name, "姓名", class: "label-light" = f.text_field :name, class: "form-control", required: true - %span.help-block Enter your name, so people you know can recognize you. + %span.help-block 输入其他人能知道的名字。 .form-group - = f.label :email, class: "label-light" + = f.label :email, "电子邮箱", class: "label-light" - if @user.ldap_user? && @user.ldap_email? = f.text_field :email, class: "form-control", required: true, readonly: true %span.help-block.light - Your email address was automatically set based on the LDAP server. + LDAP 用户的电子邮箱只读。 - else - if @user.temp_oauth_email? = f.text_field :email, class: "form-control", required: true, value: nil @@ -60,37 +60,37 @@ = f.text_field :email, class: "form-control", required: true - if @user.unconfirmed_email.present? %span.help-block - Please click the link in the confirmation email before continuing. It was sent to - = succeed "." do + 请点击确认邮件中的链接继续操作。其已经被发送到 + = succeed "。" do %strong #{@user.unconfirmed_email} %p - = link_to "Resend confirmation e-mail", user_confirmation_path(user: { email: @user.unconfirmed_email }), method: :post + = link_to "重发确认邮件", user_confirmation_path(user: { email: @user.unconfirmed_email }), method: :post - else - %span.help-block We also use email for avatar detection if no avatar is uploaded. + %span.help-block 如果没有上传头像将使用邮箱头像服务。 .form-group - = f.label :public_email, class: "label-light" + = f.label :public_email, '公开邮箱', class: "label-light" = f.select :public_email, options_for_select(@user.all_emails, selected: @user.public_email), {include_blank: 'Do not show on profile'}, class: "select2" - %span.help-block This email will be displayed on your public profile. + %span.help-block 此电子邮箱将显示在公开的个人资料上。 .form-group = f.label :skype, class: "label-light" = f.text_field :skype, class: "form-control" .form-group - = f.label :linkedin, class: "label-light" + = f.label :linkedin, '领英', class: "label-light" = f.text_field :linkedin, class: "form-control" .form-group - = f.label :twitter, class: "label-light" + = f.label :twitter, '推特', class: "label-light" = f.text_field :twitter, class: "form-control" .form-group - = f.label :website_url, 'Website', class: "label-light" + = f.label :website_url, '网址', class: "label-light" = f.text_field :website_url, class: "form-control" .form-group - = f.label :location, 'Location', class: "label-light" + = f.label :location, '位置', class: "label-light" = f.text_field :location, class: "form-control" .form-group - = f.label :bio, class: "label-light" + = f.label :bio, '简历', class: "label-light" = f.text_area :bio, rows: 4, class: "form-control", maxlength: 250 - %span.help-block Tell us about yourself in fewer than 250 characters. + %span.help-block 使用少于 250 字符的文字描述自己。 .prepend-top-default.append-bottom-default - = f.submit 'Update profile settings', class: "btn btn-success" - = link_to "Cancel", user_path(current_user), class: "btn btn-cancel" + = f.submit '更新个人资料设置', class: "btn btn-success" + = link_to "取消", user_path(current_user), class: "btn btn-cancel" diff --git a/app/views/profiles/two_factor_auths/new.html.haml b/app/views/profiles/two_factor_auths/new.html.haml index 5d342ef58e5..6d6360f5831 100644 --- a/app/views/profiles/two_factor_auths/new.html.haml +++ b/app/views/profiles/two_factor_auths/new.html.haml @@ -1,41 +1,41 @@ -- page_title 'Two-factor Authentication', 'Account' +- page_title '两步验证', '账号' .row.prepend-top-default .col-lg-3 %h4.prepend-top-0 - Two-factor Authentication (2FA) + 两步验证 (2FA) %p - Increase your account's security by enabling two-factor authentication (2FA). + 开启两步验证 (2FA) 增加账户安全性。 .col-lg-9 %p - Status: #{current_user.two_factor_enabled? ? 'enabled' : 'disabled'} + 状态:#{current_user.two_factor_enabled? ? '已启用' : '已禁用'} %p - Download the Google Authenticator application from App Store for iOS or Google Play for Android and scan this code. - More information is available in the #{link_to('documentation', help_page_path('profile', 'two_factor_authentication'))}. + 请从 iOS 的 App Store 或 Android 的 Google Play 下载谷歌身份验证器 (Google Authenticator) 应用,然后扫描下面的二维码。 + 更多可用的信息请参阅此#{link_to('文档', help_page_path('profile', 'two_factor_authentication'))}。 .row.append-bottom-10 .col-md-3 = raw @qr_code .col-md-9 .account-well %p.prepend-top-0.append-bottom-0 - Can't scan the code? + 无法扫描代码? %p.prepend-top-0.append-bottom-0 - To add the entry manually, provide the following details to the application on your phone. + 选择手动输入账户请在手机应用上输入下列明细内容。 %p.prepend-top-0.append-bottom-0 - Account: + 账户: = current_user.email %p.prepend-top-0.append-bottom-0 - Key: + 密钥: = current_user.otp_secret.scan(/.{4}/).join(' ') %p.two-factor-new-manual-content - Time based: Yes + 基于时间:是 = form_tag profile_two_factor_auth_path, method: :post do |f| - if @error .alert.alert-danger = @error .form-group - = label_tag :pin_code, nil, class: "label-light" + = label_tag :pin_code, 'Pin 码', class: "label-light" = text_field_tag :pin_code, nil, class: "form-control", required: true .prepend-top-default - = submit_tag 'Enable two-factor authentication', class: 'btn btn-success' - = link_to 'Configure it later', skip_profile_two_factor_auth_path, :method => :patch, class: 'btn btn-cancel' if two_factor_skippable? + = submit_tag '开启两步验证', class: 'btn btn-success' + = link_to '稍后配置', skip_profile_two_factor_auth_path, :method => :patch, class: 'btn btn-cancel' if two_factor_skippable? diff --git a/app/views/projects/_builds_settings.html.haml b/app/views/projects/_builds_settings.html.haml index 95ab9ecf3e8..61d3f1379b1 100644 --- a/app/views/projects/_builds_settings.html.haml +++ b/app/views/projects/_builds_settings.html.haml @@ -1,39 +1,38 @@ %fieldset.builds-feature %legend - Builds: + 构建: .form-group .col-sm-offset-2.col-sm-10 - %p Get recent application code using the following command: + %p 使用下面的命令来获取程序代码: .radio = f.label :build_allow_git_fetch_false do = f.radio_button :build_allow_git_fetch, 'false' %strong git clone %br - %span.descr Slower but makes sure you have a clean dir before every build + %span.descr 比较慢,但可以在每次构建前保证你有一个干净的文件目录 .radio = f.label :build_allow_git_fetch_true do = f.radio_button :build_allow_git_fetch, 'true' %strong git fetch %br - %span.descr Faster + %span.descr 比较快 .form-group - = f.label :build_timeout_in_minutes, 'Timeout', class: 'control-label' + = f.label :build_timeout_in_minutes, '超时', class: 'control-label' .col-sm-10 = f.number_field :build_timeout_in_minutes, class: 'form-control', min: '0' - %p.help-block per build in minutes + %p.help-block 每次构建时间的最大分钟数 .form-group - = f.label :build_coverage_regex, "Test coverage parsing", class: 'control-label' + = f.label :build_coverage_regex, "测试覆盖解析", class: 'control-label' .col-sm-10 .input-group %span.input-group-addon / = f.text_field :build_coverage_regex, class: 'form-control', placeholder: '\(\d+.\d+\%\) covered' %span.input-group-addon / %p.help-block - We will use this regular expression to find test coverage output in build trace. - Leave blank if you want to disable this feature + 我们将使用此正则表达式在构建信息中查找测试覆盖输出。如果不想使用此功能,请留空 .bs-callout.bs-callout-info - %p Below are examples of regex for existing tools: + %p 下面是现有工具的正则表达式例子: %ul %li Simplecov (Ruby) - @@ -50,11 +49,11 @@ .checkbox = f.label :public_builds do = f.check_box :public_builds - %strong Public builds - .help-block Allow everyone to access builds for Public and Internal projects + %strong 公开构建 + .help-block 允许所有人访问公开和内部项目的构建 .form-group - = f.label :runners_token, "Runners token", class: 'control-label' + = f.label :runners_token, "Runners 授权", class: 'control-label' .col-sm-10 = f.text_field :runners_token, class: "form-control", placeholder: 'xEeFCaDAB89' - %p.help-block The secure token used to checkout project. + %p.help-block 此安全授权码将用于检出项目。 diff --git a/app/views/projects/_find_file_link.html.haml b/app/views/projects/_find_file_link.html.haml index dbb33090670..e26c6e7744f 100644 --- a/app/views/projects/_find_file_link.html.haml +++ b/app/views/projects/_find_file_link.html.haml @@ -1,3 +1,3 @@ = link_to namespace_project_find_file_path(@project.namespace, @project, @ref), class: 'btn btn-grouped shortcuts-find-file', rel: 'nofollow' do = icon('search') - %span Find File + %span 查找文件 diff --git a/app/views/projects/_home_panel.html.haml b/app/views/projects/_home_panel.html.haml index d240508b64f..4126d5bdd58 100644 --- a/app/views/projects/_home_panel.html.haml +++ b/app/views/projects/_home_panel.html.haml @@ -14,7 +14,7 @@ - if forked_from_project = @project.forked_from_project .cover-desc - Forked from + 派生自 = link_to project_path(forked_from_project) do = forked_from_project.namespace.try(:name) diff --git a/app/views/projects/blame/show.html.haml b/app/views/projects/blame/show.html.haml index 5f9a92ff93f..08ab0f1f332 100644 --- a/app/views/projects/blame/show.html.haml +++ b/app/views/projects/blame/show.html.haml @@ -1,7 +1,7 @@ -- page_title "Blame", @blob.path, @ref -- header_title project_title(@project, "Files", project_files_path(@project)) +- page_title "审查", @blob.path, @ref +- header_title project_title(@project, "文件", project_files_path(@project)) -%h3.page-title Blame view +%h3.page-title 审查视图 #blob-content-holder.tree-holder .file-holder diff --git a/app/views/projects/blob/_editor.html.haml b/app/views/projects/blob/_editor.html.haml index f8b6fa253c4..33be80a1a7c 100644 --- a/app/views/projects/blob/_editor.html.haml +++ b/app/views/projects/blob/_editor.html.haml @@ -9,7 +9,7 @@ - if current_action?(:new) || current_action?(:create) %span.editor-file-name \/ - = text_field_tag 'file_name', params[:file_name], placeholder: "File name", + = text_field_tag 'file_name', params[:file_name], placeholder: "文件名", required: true, class: 'form-control new-file-name' .pull-right diff --git a/app/views/projects/blob/_new_dir.html.haml b/app/views/projects/blob/_new_dir.html.haml index 84694203d7d..e93db11adf7 100644 --- a/app/views/projects/blob/_new_dir.html.haml +++ b/app/views/projects/blob/_new_dir.html.haml @@ -3,19 +3,19 @@ .modal-content .modal-header %a.close{href: "#", "data-dismiss" => "modal"} × - %h3.page-title Create New Directory + %h3.page-title 创建新目录 .modal-body = form_tag namespace_project_create_dir_path(@project.namespace, @project, @id), method: :post, remote: false, class: 'form-horizontal js-create-dir-form js-quick-submit js-requires-input' do .form-group - = label_tag :dir_name, 'Directory name', class: 'control-label' + = label_tag :dir_name, '目录名称', class: 'control-label' .col-sm-10 = text_field_tag :dir_name, params[:dir_name], required: true, class: 'form-control' - = render 'shared/new_commit_form', placeholder: "Add new directory" + = render 'shared/new_commit_form', placeholder: "增加新目录" .form-actions - = submit_tag "Create directory", class: 'btn btn-create' - = link_to "Cancel", '#', class: "btn btn-cancel", "data-dismiss" => "modal" + = submit_tag "创建目录", class: 'btn btn-create' + = link_to "取消", '#', class: "btn btn-cancel", "data-dismiss" => "modal" - unless can?(current_user, :push_code, @project) .inline.prepend-left-10 diff --git a/app/views/projects/blob/_remove.html.haml b/app/views/projects/blob/_remove.html.haml index 2e1f32fd15e..bb9f8316468 100644 --- a/app/views/projects/blob/_remove.html.haml +++ b/app/views/projects/blob/_remove.html.haml @@ -3,16 +3,16 @@ .modal-content .modal-header %a.close{href: "#", "data-dismiss" => "modal"} × - %h3.page-title Delete #{@blob.name} + %h3.page-title 删除 #{@blob.name} .modal-body = form_tag namespace_project_blob_path(@project.namespace, @project, @id), method: :delete, class: 'form-horizontal js-replace-blob-form js-quick-submit js-requires-input' do - = render 'shared/new_commit_form', placeholder: "Delete #{@blob.name}" + = render 'shared/new_commit_form', placeholder: "删除 #{@blob.name}" .form-group .col-sm-offset-2.col-sm-10 - = button_tag 'Delete file', class: 'btn btn-remove btn-remove-file' - = link_to "Cancel", '#', class: "btn btn-cancel", "data-dismiss" => "modal" + = button_tag '删除文件', class: 'btn btn-remove btn-remove-file' + = link_to "取消", '#', class: "btn btn-cancel", "data-dismiss" => "modal" :javascript new NewCommitForm($('.js-replace-blob-form')) diff --git a/app/views/projects/blob/edit.html.haml b/app/views/projects/blob/edit.html.haml index 70d8009eb2b..48572b24a7f 100644 --- a/app/views/projects/blob/edit.html.haml +++ b/app/views/projects/blob/edit.html.haml @@ -15,7 +15,7 @@ = form_tag(namespace_project_update_blob_path(@project.namespace, @project, @id), method: :put, class: 'form-horizontal js-quick-submit js-requires-input js-edit-blob-form') do = render 'projects/blob/editor', ref: @ref, path: @path, blob_data: @blob.data - = render 'shared/new_commit_form', placeholder: "Update #{@blob.name}" + = render 'shared/new_commit_form', placeholder: "更新 #{@blob.name}" = hidden_field_tag 'last_commit', @last_commit = hidden_field_tag 'content', '', id: "file-content" diff --git a/app/views/projects/blob/new.html.haml b/app/views/projects/blob/new.html.haml index 1dd2b5c0af7..af04507f371 100644 --- a/app/views/projects/blob/new.html.haml +++ b/app/views/projects/blob/new.html.haml @@ -1,13 +1,13 @@ -- page_title "New File", @path.presence, @ref +- page_title "新文件", @path.presence, @ref = render "header_title" %h3.page-title - New File + 新文件 .file-editor = form_tag(namespace_project_create_blob_path(@project.namespace, @project, @id), method: :post, class: 'form-horizontal js-new-blob-form js-quick-submit js-requires-input') do = render 'projects/blob/editor', ref: @ref - = render 'shared/new_commit_form', placeholder: "Add new file" + = render 'shared/new_commit_form', placeholder: "增加新文件" = hidden_field_tag 'content', '', id: 'file-content' = render 'projects/commit_button', ref: @ref, diff --git a/app/views/projects/builds/index.html.haml b/app/views/projects/builds/index.html.haml index 811d304ea75..4f764db7bdd 100644 --- a/app/views/projects/builds/index.html.haml +++ b/app/views/projects/builds/index.html.haml @@ -1,58 +1,58 @@ -- page_title "Builds" +- page_title "构建" = render "header_title" .top-area %ul.nav-links %li{class: ('active' if @scope.nil?)} = link_to project_builds_path(@project) do - All + 全部 %span.badge.js-totalbuilds-count = number_with_delimiter(@all_builds.count(:id)) %li{class: ('active' if @scope == 'running')} = link_to project_builds_path(@project, scope: :running) do - Running + 正在运行 %span.badge.js-running-count = number_with_delimiter(@all_builds.running_or_pending.count(:id)) %li{class: ('active' if @scope == 'finished')} = link_to project_builds_path(@project, scope: :finished) do - Finished + 已结束 %span.badge.js-running-count = number_with_delimiter(@all_builds.finished.count(:id)) .nav-controls - if can?(current_user, :update_build, @project) - if @all_builds.running_or_pending.any? - = link_to 'Cancel running', cancel_all_namespace_project_builds_path(@project.namespace, @project), - data: { confirm: 'Are you sure?' }, class: 'btn btn-danger', method: :post + = link_to '取消运行', cancel_all_namespace_project_builds_path(@project.namespace, @project), + data: { confirm: '确定要继续么?' }, class: 'btn btn-danger', method: :post = link_to ci_lint_path, class: 'btn btn-default' do = icon('wrench') %span CI Lint .gray-content-block - #{(@scope || 'running').capitalize} builds from this project + 列出本项目 #{(@scope || 'running').capitalize} 的构建 %ul.content-list - if @builds.blank? %li - .nothing-here-block No builds to show + .nothing-here-block 没有构建 - else .table-holder %table.table.builds %thead %tr - %th Status - %th Build ID - %th Commit - %th Ref - %th Stage - %th Name - %th Duration - %th Finished at + %th 状态 + %th 构建 ID + %th 提交 + %th 参考 + %th 阶段 + %th 名称 + %th 运行时间 + %th 结束时间 - if @project.build_coverage_enabled? - %th Coverage + %th 覆盖率 %th = render @builds, commit_sha: true, stage: true, allow_retry: true, coverage: @project.build_coverage_enabled? diff --git a/app/views/projects/builds/show.html.haml b/app/views/projects/builds/show.html.haml index 2f85e363c9d..a8c5a726618 100644 --- a/app/views/projects/builds/show.html.haml +++ b/app/views/projects/builds/show.html.haml @@ -1,16 +1,16 @@ -- page_title "#{@build.name} (##{@build.id})", "Builds" +- page_title "#{@build.name} (##{@build.id})", "构建" = render "header_title" .build-page .gray-content-block.top-block - Build ##{@build.id} for commit - %strong.monospace= link_to @build.commit.short_sha, ci_status_path(@build.commit) - from + 从 = link_to @build.ref, namespace_project_commits_path(@project.namespace, @project, @build.ref) + %strong.monospace= link_to @build.commit.short_sha, ci_status_path(@build.commit) + 提交的构建 ##{@build.id} - merge_request = @build.merge_request - if merge_request - via - = link_to "merge request ##{merge_request.iid}", merge_request_path(merge_request) + 来自于 + = link_to "合并请求 ##{merge_request.iid}", merge_request_path(merge_request) #up-build-trace - builds = @build.commit.matrix_builds(@build) @@ -50,26 +50,26 @@ .bs-callout.bs-callout-warning %p - if no_runners_for_project?(@build.project) - This build is stuck, because the project doesn't have any runners online assigned to it. + 此构建被卡住,因为没有 runner 指定给该项目。 - elsif @build.tags.any? - This build is stuck, because you don't have any active runners online with any of these tags assigned to them: + 此构建被卡住,因为没有指定标签的 runner 指定给该项目。指定的标签如下: - @build.tags.each do |tag| %span.label.label-primary = tag - else - This build is stuck, because you don't have any active runners that can run this build. + 此构建被卡住,因为没有可用的 runner 来运行此构建。 %br - Go to + 转到 = link_to namespace_project_runners_path(@build.project.namespace, @build.project) do - Runners page + Runners 页面 .row.prepend-top-default .col-md-9 .clearfix - if @build.active? .autoscroll-container - %button.btn.btn-success.btn-sm#autoscroll-button{:type => "button", :data => {:state => 'disabled'}} enable autoscroll + %button.btn.btn-success.btn-sm#autoscroll-button{:type => "button", :data => {:state => 'disabled'}} 开启自动滚动 .clearfix #js-build-scroll.scroll-controls = link_to '#up-build-trace', class: 'btn' do @@ -93,59 +93,59 @@ - if @build.coverage .build-widget %h4.title - Test coverage + 测试覆盖 %h1 #{@build.coverage}% - if can?(current_user, :read_build, @project) && @build.artifacts? .build-widget.artifacts - %h4.title Build artifacts + %h4.title 构建附件 .center .btn-group{ role: :group } = link_to download_namespace_project_build_artifacts_path(@project.namespace, @project, @build), class: 'btn btn-sm btn-primary' do = icon('download') - Download + 下载 - if @build.artifacts_metadata? = link_to browse_namespace_project_build_artifacts_path(@project.namespace, @project, @build), class: 'btn btn-sm btn-primary' do = icon('folder-open') - Browse + 浏览 .build-widget %h4.title - Build ##{@build.id} + 构建 ##{@build.id} - if can?(current_user, :update_build, @project) .center .btn-group{ role: :group } - if @build.active? - = link_to "Cancel", cancel_namespace_project_build_path(@project.namespace, @project, @build), class: 'btn btn-sm btn-danger', method: :post + = link_to "取消", cancel_namespace_project_build_path(@project.namespace, @project, @build), class: 'btn btn-sm btn-danger', method: :post - elsif @build.retryable? - = link_to "Retry", retry_namespace_project_build_path(@project.namespace, @project, @build), class: 'btn btn-sm btn-primary', method: :post + = link_to "重试", retry_namespace_project_build_path(@project.namespace, @project, @build), class: 'btn btn-sm btn-primary', method: :post - if @build.erasable? = link_to erase_namespace_project_build_path(@project.namespace, @project, @build), class: 'btn btn-sm btn-warning', method: :post, - data: { confirm: 'Are you sure you want to erase this build?' } do + data: { confirm: '确定要删除此构建么?' } do = icon('eraser') - Erase + 删除 .clearfix - if @build.duration %p - %span.attr-name Duration: + %span.attr-name 运行时间: #{duration_in_words(@build.finished_at, @build.started_at)} %p - %span.attr-name Created: + %span.attr-name 创建时间: #{time_ago_with_tooltip(@build.created_at)} - if @build.finished_at %p - %span.attr-name Finished: + %span.attr-name 结束时间: #{time_ago_with_tooltip(@build.finished_at)} - if @build.erased_at %p - %span.attr-name Erased: + %span.attr-name 删除时间: #{time_ago_with_tooltip(@build.erased_at)} %p - %span.attr-name Runner: + %span.attr-name Runner: - if @build.runner && current_user && current_user.admin = link_to "##{@build.runner.id}", admin_runner_path(@build.runner.id) - elsif @build.runner diff --git a/app/views/projects/buttons/_download.html.haml b/app/views/projects/buttons/_download.html.haml index 6a60cfeff76..6c22a7bbca7 100644 --- a/app/views/projects/buttons/_download.html.haml +++ b/app/views/projects/buttons/_download.html.haml @@ -1,4 +1,4 @@ - unless @project.empty_repo? - if can? current_user, :download_code, @project - = link_to archive_namespace_project_repository_path(@project.namespace, @project, ref: @ref, format: 'zip'), class: 'btn has_tooltip', data: {container: "body"}, rel: 'nofollow', title: "Download ZIP" do + = link_to archive_namespace_project_repository_path(@project.namespace, @project, ref: @ref, format: 'zip'), class: 'btn has_tooltip', data: {container: "body"}, rel: 'nofollow', title: "下载 ZIP" do = icon('download') diff --git a/app/views/projects/commit/_builds.html.haml b/app/views/projects/commit/_builds.html.haml index 003b7c18d0e..ab57e167c6b 100644 --- a/app/views/projects/commit/_builds.html.haml +++ b/app/views/projects/commit/_builds.html.haml @@ -2,45 +2,45 @@ .pull-right - if can?(current_user, :update_build, @ci_commit.project) - if @ci_commit.builds.latest.failed.any?(&:retryable?) - = link_to "Retry failed", retry_builds_namespace_project_commit_path(@ci_commit.project.namespace, @ci_commit.project, @ci_commit.sha), class: 'btn btn-grouped btn-primary', method: :post + = link_to "重试失败", retry_builds_namespace_project_commit_path(@ci_commit.project.namespace, @ci_commit.project, @ci_commit.sha), class: 'btn btn-grouped btn-primary', method: :post - if @ci_commit.builds.running_or_pending.any? - = link_to "Cancel running", cancel_builds_namespace_project_commit_path(@ci_commit.project.namespace, @ci_commit.project, @ci_commit.sha), data: { confirm: 'Are you sure?' }, class: 'btn btn-grouped btn-danger', method: :post + = link_to "取消运行", cancel_builds_namespace_project_commit_path(@ci_commit.project.namespace, @ci_commit.project, @ci_commit.sha), data: { confirm: '确定要继续么?' }, class: 'btn btn-grouped btn-danger', method: :post .oneline - = pluralize @statuses.count(:id), "build" - if defined?(link_to_commit) && link_to_commit - for commit = link_to @ci_commit.short_sha, namespace_project_commit_path(@ci_commit.project.namespace, @ci_commit.project, @ci_commit.sha), class: "monospace" + 提交的 + = pluralize @statuses.count(:id), "次构建", "次构建" - if @ci_commit.duration > 0 - in + 耗费 = time_interval_in_words @ci_commit.duration - if @ci_commit.yaml_errors.present? .bs-callout.bs-callout-danger - %h4 Found errors in your .gitlab-ci.yml: + %h4 在 .gitlab-ci.yml 中发现错误: %ul - @ci_commit.yaml_errors.split(",").each do |error| %li= error - You can also test your .gitlab-ci.yml in the #{link_to "Lint", ci_lint_path} + 你也可以使用 #{link_to "Lint", ci_lint_path} 工具测试你的 .gitlab-ci.yml 文件 - if @ci_commit.project.builds_enabled? && !@ci_commit.ci_yaml_file .bs-callout.bs-callout-warning - \.gitlab-ci.yml not found in this commit + 此提交里面没有发现 .gitlab-ci.yml 文件 .table-holder %table.table.builds %thead %tr - %th Status - %th Build ID - %th Ref - %th Stage - %th Name - %th Duration - %th Finished at + %th 状态 + %th 构建 ID + %th 参考 + %th 阶段 + %th 名称 + %th 运行时间 + %th 结束时间 - if @ci_commit.project.build_coverage_enabled? - %th Coverage + %th 覆盖率 %th - @ci_commit.refs.each do |ref| - builds = @ci_commit.statuses.for_ref(ref).latest.ordered @@ -48,20 +48,20 @@ - if @ci_commit.retried.any? .gray-content-block.second-block - Retried builds + 重试的构建 .table-holder %table.table.builds %thead %tr - %th Status - %th Build ID - %th Ref - %th Stage - %th Name - %th Duration - %th Finished at + %th 状态 + %th 构建 ID + %th 参考 + %th 阶段 + %th 名称 + %th 运行时间 + %th 结束时间 - if @ci_commit.project.build_coverage_enabled? - %th Coverage + %th 覆盖率 %th = render @ci_commit.retried, coverage: @ci_commit.project.build_coverage_enabled?, stage: true diff --git a/app/views/projects/commits/_commit_list.html.haml b/app/views/projects/commits/_commit_list.html.haml index bac9e244d36..8755b1cf359 100644 --- a/app/views/projects/commits/_commit_list.html.haml +++ b/app/views/projects/commits/_commit_list.html.haml @@ -3,12 +3,12 @@ %div.panel.panel-default .panel-heading - Commits (#{@commits.count}) + 提交 (#{@commits.count}) - if hidden > 0 %ul.well-list - commits.each do |commit| = render "projects/commits/inline_commit", commit: commit, project: @project %li.warning-row.unstyled - #{number_with_delimiter(hidden)} additional commits have been omitted to prevent performance issues. + #{number_with_delimiter(hidden)} 次更多提交因为性能问题而隐藏。 - else %ul.well-list= render commits, project: @project diff --git a/app/views/projects/commits/_head.html.haml b/app/views/projects/commits/_head.html.haml index 7a5b0d993db..eced034283c 100644 --- a/app/views/projects/commits/_head.html.haml +++ b/app/views/projects/commits/_head.html.haml @@ -1,23 +1,23 @@ %ul.nav-links = nav_link(controller: [:commit, :commits]) do = link_to namespace_project_commits_path(@project.namespace, @project, current_ref) do - Commits + 提交 %span.badge= number_with_delimiter(@repository.commit_count) = nav_link(controller: %w(network)) do = link_to namespace_project_network_path(@project.namespace, @project, current_ref) do - Network + 网络 = nav_link(controller: :compare) do = link_to namespace_project_compare_index_path(@project.namespace, @project, from: @repository.root_ref, to: current_ref) do - Compare + 比较 = nav_link(html_options: {class: branches_tab_class}) do = link_to namespace_project_branches_path(@project.namespace, @project) do - Branches + 分支 %span.badge.js-totalbranch-count= @repository.branch_count = nav_link(controller: [:tags, :releases]) do = link_to namespace_project_tags_path(@project.namespace, @project) do - Tags + 标签 %span.badge.js-totaltags-count= @repository.tag_count diff --git a/app/views/projects/deploy_keys/index.html.haml b/app/views/projects/deploy_keys/index.html.haml index 44f7a37a459..830ec24c3a1 100644 --- a/app/views/projects/deploy_keys/index.html.haml +++ b/app/views/projects/deploy_keys/index.html.haml @@ -37,7 +37,7 @@ - if @available_public_keys.any? %h5 - 所有项目可用的 + 全部项目可用的 %strong 公开部署密钥 %ul.bordered-list = render @available_public_keys diff --git a/app/views/projects/diffs/_file.html.haml b/app/views/projects/diffs/_file.html.haml index fa53fc429f5..8e114e999bc 100644 --- a/app/views/projects/diffs/_file.html.haml +++ b/app/views/projects/diffs/_file.html.haml @@ -20,7 +20,7 @@ %strong = diff_file.new_path - if diff_file.deleted_file - deleted + 已删除 - if diff_file.mode_changed? %small @@ -44,7 +44,7 @@ - return unless blob.respond_to?('text?') - if diff_file.too_large? .nothing-here-block - This diff could not be displayed because it is too large. + 此 diff 太大无法显示。 - else - if blob_text_viewable?(blob) - if diff_view == 'parallel' @@ -55,4 +55,4 @@ - old_file = project.repository.prev_blob_for_diff(diff_commit, diff_file) = render "projects/diffs/image", diff_file: diff_file, old_file: old_file, file: blob, index: i, diff_refs: diff_refs - else - .nothing-here-block No preview for this file type + .nothing-here-block 不能预览此文件类型 diff --git a/app/views/projects/diffs/_warning.html.haml b/app/views/projects/diffs/_warning.html.haml index 15536c17f8e..658e7933613 100644 --- a/app/views/projects/diffs/_warning.html.haml +++ b/app/views/projects/diffs/_warning.html.haml @@ -1,18 +1,18 @@ .alert.alert-warning %h4 - Too many changes to show. + 要显示太多修改。 .pull-right - unless diff_hard_limit_enabled? - = link_to "Reload with full diff", url_for(params.merge(force_show_diff: true, format: nil)), class: "btn btn-sm" + = link_to "重新载入完整差异", url_for(params.merge(force_show_diff: true, format: nil)), class: "btn btn-sm" - if current_controller?(:commit) or current_controller?(:merge_requests) - if current_controller?(:commit) - = link_to "Plain diff", namespace_project_commit_path(@project.namespace, @project, @commit, format: :diff), class: "btn btn-sm" - = link_to "Email patch", namespace_project_commit_path(@project.namespace, @project, @commit, format: :patch), class: "btn btn-sm" + = link_to "原始差异文件", namespace_project_commit_path(@project.namespace, @project, @commit, format: :diff), class: "btn btn-sm" + = link_to "电子邮件补丁", namespace_project_commit_path(@project.namespace, @project, @commit, format: :patch), class: "btn btn-sm" - elsif @merge_request && @merge_request.persisted? - = link_to "Plain diff", merge_request_path(@merge_request, format: :diff), class: "btn btn-sm" - = link_to "Email patch", merge_request_path(@merge_request, format: :patch), class: "btn btn-sm" + = link_to "原始差异文件", merge_request_path(@merge_request, format: :diff), class: "btn btn-sm" + = link_to "电子邮件补丁", merge_request_path(@merge_request, format: :patch), class: "btn btn-sm" %p - To preserve performance only + 为保证性能只显示 %strong #{diff_files.count} of #{diff_files.real_size} - files are displayed. + 个文件。 diff --git a/app/views/projects/edit.html.haml b/app/views/projects/edit.html.haml index d237384cee6..8df3c9d5b86 100644 --- a/app/views/projects/edit.html.haml +++ b/app/views/projects/edit.html.haml @@ -3,185 +3,184 @@ .project-edit-content .panel.panel-default .panel-heading - Project settings + 项目设置 .panel-body = form_for [@project.namespace.becomes(Namespace), @project], remote: true, html: { multipart: true, class: "edit_project form-horizontal fieldset-form" }, authenticity_token: true do |f| %fieldset .form-group.project_name_holder = f.label :name, class: 'control-label' do - Project name + 项目名称 .col-sm-10 = f.text_field :name, class: "form-control", id: "project_name_edit" .form-group = f.label :description, class: 'control-label' do - Project description - %span.light (optional) + 项目描述 + %span.light (可选) .col-sm-10 = f.text_area :description, class: "form-control", rows: 3, maxlength: 250 - unless @project.empty_repo? .form-group - = f.label :default_branch, "Default Branch", class: 'control-label' + = f.label :default_branch, "默认分支", class: 'control-label' .col-sm-10= f.select(:default_branch, @project.repository.branch_names, {}, {class: 'select2 select-wide'}) = render 'shared/visibility_level', f: f, visibility_level: @project.visibility_level, can_change_visibility_level: can_change_visibility_level?(@project, current_user), form_model: @project .form-group - = f.label :tag_list, "Tags", class: 'control-label' + = f.label :tag_list, "标签", class: 'control-label' .col-sm-10 = f.text_field :tag_list, value: @project.tag_list.to_s, maxlength: 2000, class: "form-control" - %p.help-block Separate tags with commas. + %p.help-block 使用英文逗号分割。 %fieldset.features %legend - Features: + 功能: .form-group .col-sm-offset-2.col-sm-10 .checkbox = f.label :issues_enabled do = f.check_box :issues_enabled - %strong Issues + %strong 问题 %br - %span.descr Lightweight issue tracking system for this project + %span.descr 轻量级问题跟踪系统 .form-group .col-sm-offset-2.col-sm-10 .checkbox = f.label :merge_requests_enabled do = f.check_box :merge_requests_enabled - %strong Merge Requests + %strong 合并请求 %br - %span.descr Submit changes to be merged upstream + %span.descr 合并上游修改 .form-group .col-sm-offset-2.col-sm-10 .checkbox = f.label :builds_enabled do = f.check_box :builds_enabled - %strong Builds + %strong 构建 %br - %span.descr Test and deploy your changes before merge + %span.descr 合并前测试和部署变更 .form-group .col-sm-offset-2.col-sm-10 .checkbox = f.label :wiki_enabled do = f.check_box :wiki_enabled - %strong Wiki + %strong 维基 %br - %span.descr Pages for project documentation + %span.descr 项目文档页面 .form-group .col-sm-offset-2.col-sm-10 .checkbox = f.label :snippets_enabled do = f.check_box :snippets_enabled - %strong Snippets + %strong 代码片段 %br - %span.descr Share code pastes with others out of git repository + %span.descr 共享 git 版本仓库外的代码 = render 'builds_settings', f: f %fieldset.features %legend - Project avatar: + 项目头像: .form-group .col-sm-offset-2.col-sm-10 - if @project.avatar? = project_icon("#{@project.namespace.to_param}/#{@project.to_param}", alt: '', class: 'avatar project-avatar s160') %p.light - if @project.avatar_in_git - Project avatar in repository: #{ @project.avatar_in_git } + 项目头像保存在版本仓库:#{ @project.avatar_in_git } %p.light - if @project.avatar? - You can change your project avatar here + 在这里可以修改项目头像 - else - You can upload a project avatar here + 在这里可以上传项目头像 %a.choose-btn.btn.btn-sm.js-choose-project-avatar-button %i.icon-paper-clip - %span Choose File ... + %span 选择文件... %span.file_name.js-avatar-filename File name... = f.file_field :avatar, class: "js-project-avatar-input hidden" - .light The maximum file size allowed is 200KB. + .light 文件大小限制为 200KB。 - if @project.avatar? %hr - = link_to 'Remove avatar', namespace_project_avatar_path(@project.namespace, @project), data: { confirm: "Project avatar will be removed. Are you sure?"}, method: :delete, class: "btn btn-remove btn-sm remove-avatar" + = link_to '删除头像', namespace_project_avatar_path(@project.namespace, @project), data: { confirm: "确定要删除项目头像么?"}, method: :delete, class: "btn btn-remove btn-sm remove-avatar" .form-actions - = f.submit 'Save changes', class: "btn btn-save" + = f.submit '保存修改', class: "btn btn-save" .danger-settings .panel.panel-default - .panel-heading Housekeeping + .panel-heading 维护 .errors-holder .panel-body %p - Runs a number of housekeeping tasks within the current repository, - such as compressing file revisions and removing unreachable objects. + 执行当前仓库的一些维护任务,诸如压缩文件修订版本和删除无用对象等。 %br .form-actions - = link_to 'Housekeeping', housekeeping_namespace_project_path(@project.namespace, @project), + = link_to '维护', housekeeping_namespace_project_path(@project.namespace, @project), method: :post, class: "btn btn-default" - if can? current_user, :archive_project, @project - if @project.archived? .panel.panel-success .panel-heading - Unarchive project + 解档项目 .panel-body %p - Unarchiving the project will mark its repository as active. + 解档项目将恢复项目版本仓库可修改。 %br - The project can be committed to. + 项目可以被提交。 %br - %strong Once active this project shows up in the search and on the dashboard. + %strong 解档后该项目可以被搜索到并显示在仪表盘中。 .form-actions - = link_to 'Unarchive project', unarchive_namespace_project_path(@project.namespace, @project), - data: { confirm: "Are you sure that you want to unarchive this project?\nWhen this project is unarchived it is active and can be committed to again." }, + = link_to '解档项目', unarchive_namespace_project_path(@project.namespace, @project), + data: { confirm: "确定要解档本项目么?\n解档项目后可以重新提交版本仓库修改。" }, method: :post, class: "btn btn-success" - else .panel.panel-warning .panel-heading - Archive project + 归档项目 .panel-body %p - Archiving the project will mark its repository as read-only. + 归档项目将标识其版本仓库为只读。 %br - It is hidden from the dashboard and doesn't show up in searches. + 同时将在仪表盘隐藏并且不能搜索到。 %br - %strong Archived projects cannot be committed to! + %strong 已归档的项目不能被提交! .form-actions - = link_to 'Archive project', archive_namespace_project_path(@project.namespace, @project), - data: { confirm: "Are you sure that you want to archive this project?\nAn archived project cannot be committed to." }, + = link_to '归档项目', archive_namespace_project_path(@project.namespace, @project), + data: { confirm: "确定要归档本项目么?\n已归档的项目不能被提交。" }, method: :post, class: "btn btn-warning" - else - .nothing-here-block Only the project owner can archive a project + .nothing-here-block 只有项目所有者才能归档项目 .panel.panel-default.panel.panel-warning - .panel-heading Rename repository + .panel-heading 重命名仓库 .errors-holder .panel-body = form_for([@project.namespace.becomes(Namespace), @project], html: { class: 'form-horizontal' }) do |f| .form-group.project_name_holder = f.label :name, class: 'control-label' do - Project name + 项目名称 .col-sm-9 .form-group = f.text_field :name, class: "form-control" .form-group = f.label :path, class: 'control-label' do - %span Path + %span 路径 .col-sm-9 .form-group .input-group diff --git a/app/views/projects/empty.html.haml b/app/views/projects/empty.html.haml index 1ce0a9e3018..f7c7eda526a 100644 --- a/app/views/projects/empty.html.haml +++ b/app/views/projects/empty.html.haml @@ -9,31 +9,31 @@ .gray-content-block.second-block.center %h3.page-title - The repository for this project is empty + 此项目的版本仓库是空的 - if can?(current_user, :push_code, @project) %p - If you already have files you can push them using command line instructions below. + 如有已有文件请按照下面的命令行指令推送它们。 %p - Otherwise you can start with - = link_to "adding README", new_readme_path, class: 'underlined-link' - file to this project. + 或者可以从 + = link_to "增加 README", new_readme_path, class: 'underlined-link' + 文件开始本项目。 - if can?(current_user, :push_code, @project) %div{ class: container_class } .prepend-top-20 .empty_wrapper %h3.page-title-empty - Command line instructions + 命令行指令 %div.git-empty %fieldset - %h5 Git global setup + %h5 Git 全局设置 %pre.light-well :preserve git config --global user.name "#{h git_user_name}" git config --global user.email "#{h git_user_email}" %fieldset - %h5 Create a new repository + %h5 创建新版本库 %pre.light-well :preserve git clone #{ content_tag(:span, default_url_to_repo, class: 'clone')} diff --git a/app/views/projects/forks/index.html.haml b/app/views/projects/forks/index.html.haml index 4bcf2d9d533..074219cab7e 100644 --- a/app/views/projects/forks/index.html.haml +++ b/app/views/projects/forks/index.html.haml @@ -1,16 +1,16 @@ .top-area .nav-text - - full_count_title = "#{@public_forks_count} public and #{@private_forks_count} private" - == #{pluralize(@total_forks_count, 'fork')}: #{full_count_title} + - full_count_title = "#{@public_forks_count} 个公开和 #{@private_forks_count} 个私有" + == #{pluralize(@total_forks_count, '个派生', '个派生')}: #{full_count_title} .nav-controls = form_tag request.original_url, method: :get, class: 'project-filter-form', id: 'project-filter-form' do |f| - = search_field_tag :filter_projects, nil, placeholder: 'Search forks', class: 'projects-list-filter project-filter-form-field form-control input-short', + = search_field_tag :filter_projects, nil, placeholder: '搜索派生', class: 'projects-list-filter project-filter-form-field form-control input-short', spellcheck: false, data: { 'filter-selector' => 'span.namespace-name' } .dropdown %button.dropdown-toggle.btn.sort-forks{type: 'button', 'data-toggle' => 'dropdown'} - %span.light sort: + %span.light 排序: - if @sort.present? = sort_options_hash[@sort] - else @@ -30,13 +30,13 @@ - if current_user && can?(current_user, :fork_project, @project) - if current_user.already_forked?(@project) && current_user.manageable_namespaces.size < 2 - = link_to namespace_project_path(current_user, current_user.fork_of(@project)), title: 'Go to your fork', class: 'btn btn-new' do + = link_to namespace_project_path(current_user, current_user.fork_of(@project)), title: '转到您的派生', class: 'btn btn-new' do = icon('code-fork fw') - Fork + 派生 - else - = link_to new_namespace_project_fork_path(@project.namespace, @project), title: "Fork project", class: 'btn btn-new' do + = link_to new_namespace_project_fork_path(@project.namespace, @project), title: "派生项目", class: 'btn btn-new' do = icon('code-fork fw') - Fork + 派生 = render 'projects', projects: @forks @@ -44,5 +44,5 @@ - if @private_forks_count > 0 .private-forks-notice = icon('lock fw', base: 'circle', class: 'fa-lg private-fork-icon') - %strong= pluralize(@private_forks_count, 'private fork') - %span you have no access to. + %strong= pluralize(@private_forks_count, '个私有派生', '个私有派生') + %span 您没有权限访问。 diff --git a/app/views/projects/graphs/ci/_builds.haml b/app/views/projects/graphs/ci/_builds.haml index a8fd0b9ee8b..439d34f44d2 100644 --- a/app/views/projects/graphs/ci/_builds.haml +++ b/app/views/projects/graphs/ci/_builds.haml @@ -7,7 +7,7 @@ %span.cgray = icon("circle") - 所有 + 全部 .prepend-top-default %p.light diff --git a/app/views/projects/group_links/index.html.haml b/app/views/projects/group_links/index.html.haml index 13f5fc141fa..7a5c5d02928 100644 --- a/app/views/projects/group_links/index.html.haml +++ b/app/views/projects/group_links/index.html.haml @@ -1,12 +1,12 @@ -- page_title "Groups" -%h3.page_title Share project with other groups +- page_title "群组" +%h3.page_title 分享项目给其他群组 %p.light - Projects can be stored in only one group at once. However you can share a project with other groups here. + 项目只在一个群组内保存。但可以在这里分享项目到其他群组。 %hr - if @group_links.present? .enabled-groups.panel.panel-default .panel-heading - Already shared with + 已分享给 %ul.well-list - @group_links.each do |group_link| - group = group_link.group @@ -14,28 +14,28 @@ .pull-right = link_to namespace_project_group_link_path(@project.namespace, @project, group_link), method: :delete, class: 'btn btn-sm' do %i.icon-remove - disable sharing + 禁止分享 = link_to group do %strong %i.icon-folder-open = group.name %br - .light up to #{group_link.human_access} + .light 权限:#{group_link.human_access} .available-groups %h4 - Can be shared with + 可以分享给 %div = form_tag namespace_project_group_links_path(@project.namespace, @project), method: :post, class: 'form-horizontal' do .form-group - = label_tag :link_group_id, 'Group', class: 'control-label' + = label_tag :link_group_id, '群组', class: 'control-label' .col-sm-10 = groups_select_tag(:link_group_id, skip_group: @project.group.try(:path)) .form-group - = label_tag :link_group_access, 'Max access level', class: 'control-label' + = label_tag :link_group_access, '最大访问等级', class: 'control-label' .col-sm-10 = select_tag :link_group_access, options_for_select(ProjectGroupLink.access_options, ProjectGroupLink.default_access), class: "form-control" .form-actions - = submit_tag "Share", class: "btn btn-create" + = submit_tag "分享", class: "btn btn-create" diff --git a/app/views/projects/hooks/index.html.haml b/app/views/projects/hooks/index.html.haml index 67d016bd871..ac0db914b10 100644 --- a/app/views/projects/hooks/index.html.haml +++ b/app/views/projects/hooks/index.html.haml @@ -1,10 +1,9 @@ -- page_title "Webhooks" +- page_title "Web 钩子" %h3.page-title - Webhooks + Web 钩子 %p.light - #{link_to "Webhooks ", help_page_path("web_hooks", "web_hooks"), class: "vlink"} can be - used for binding events when something is happening within the project. + #{link_to "Web 钩子", help_page_path("web_hooks", "web_hooks"), class: "vlink"}用于在项目发生相关事件时通知外部服务器。 %hr.clearfix @@ -14,78 +13,78 @@ - @hook.errors.full_messages.each do |msg| %p= msg .form-group - = f.label :url, "URL", class: 'control-label' + = f.label :url, "链接", class: 'control-label' .col-sm-10 = f.text_field :url, class: "form-control", placeholder: 'http://example.com/trigger-ci.json' .form-group - = f.label :url, "Trigger", class: 'control-label' + = f.label :url, "触发", class: 'control-label' .col-sm-10.prepend-top-10 %div = f.check_box :push_events, class: 'pull-left' .prepend-left-20 = f.label :push_events, class: 'list-label' do - %strong Push events + %strong 推送事件 %p.light - This url will be triggered by a push to the repository + 推送仓库时将触发此链接 %div = f.check_box :tag_push_events, class: 'pull-left' .prepend-left-20 = f.label :tag_push_events, class: 'list-label' do - %strong Tag push events + %strong 标签推送事件 %p.light - This url will be triggered when a new tag is pushed to the repository + 新标签推送仓库时将触发此链接 %div = f.check_box :note_events, class: 'pull-left' .prepend-left-20 = f.label :note_events, class: 'list-label' do - %strong Comments + %strong 评论 %p.light - This url will be triggered when someone adds a comment + 增加新评论时将触发此链接 %div = f.check_box :issues_events, class: 'pull-left' .prepend-left-20 = f.label :issues_events, class: 'list-label' do - %strong Issues events + %strong 问题事件 %p.light - This url will be triggered when an issue is created/updated/merged + 问题创建、更新、合并时将触发此链接 %div = f.check_box :merge_requests_events, class: 'pull-left' .prepend-left-20 = f.label :merge_requests_events, class: 'list-label' do - %strong Merge Request events + %strong 合并请求事件 %p.light - This url will be triggered when a merge request is created/updated/merged + 合并请求创建、更新、合并时将触发此链接 %div = f.check_box :build_events, class: 'pull-left' .prepend-left-20 = f.label :build_events, class: 'list-label' do - %strong Build events + %strong 构建事件 %p.light - This url will be triggered when the build status changes + 构建状态改变时将触发此链接 .form-group - = f.label :enable_ssl_verification, "SSL verification", class: 'control-label checkbox' + = f.label :enable_ssl_verification, "SSL 证书验证", class: 'control-label checkbox' .col-sm-10 .checkbox = f.label :enable_ssl_verification do = f.check_box :enable_ssl_verification - %strong Enable SSL verification + %strong 开启 SSL 证书验证 .form-actions - = f.submit "Add Webhook", class: "btn btn-create" + = f.submit "增加 Web 钩子", class: "btn btn-create" -if @hooks.any? .panel.panel-default .panel-heading - Webhooks (#{@hooks.count}) + Web 钩子 (#{@hooks.count}) %ul.well-list - @hooks.each do |hook| %li .pull-right - = link_to 'Test Hook', test_namespace_project_hook_path(@project.namespace, @project, hook), class: "btn btn-sm btn-grouped" - = link_to 'Remove', namespace_project_hook_path(@project.namespace, @project, hook), data: { confirm: 'Are you sure?'}, method: :delete, class: "btn btn-remove btn-sm btn-grouped" + = link_to '测试钩子', test_namespace_project_hook_path(@project.namespace, @project, hook), class: "btn btn-sm btn-grouped" + = link_to '删除', namespace_project_hook_path(@project.namespace, @project, hook), data: { confirm: '确定要删除么?'}, method: :delete, class: "btn btn-remove btn-sm btn-grouped" .clearfix %span.monospace= hook.url %p - %w(push_events tag_push_events issues_events note_events merge_requests_events build_events).each do |trigger| - if hook.send(trigger) %span.label.label-gray= trigger.titleize - SSL Verification: #{hook.enable_ssl_verification ? "enabled" : "disabled"} + SSL 证书验证:#{hook.enable_ssl_verification ? "已启用" : "已禁用"} diff --git a/app/views/projects/issues/_discussion.html.haml b/app/views/projects/issues/_discussion.html.haml index b151393abab..360875974ac 100644 --- a/app/views/projects/issues/_discussion.html.haml +++ b/app/views/projects/issues/_discussion.html.haml @@ -1,7 +1,7 @@ - content_for :note_actions do - if can?(current_user, :update_issue, @issue) - = link_to 'Reopen issue', issue_path(@issue, issue: {state_event: :reopen}, status_only: true, format: 'json'), data: {no_turbolink: true, original_text: "Reopen issue", alternative_text: "Comment & reopen issue"}, class: "btn btn-nr btn-grouped btn-reopen btn-comment js-note-target-reopen #{issue_button_visibility(@issue, false)}", title: 'Reopen issue' - = link_to 'Close issue', issue_path(@issue, issue: {state_event: :close}, status_only: true, format: 'json'), data: {no_turbolink: true, original_text: "Close issue", alternative_text: "Comment & close issue"}, class: "btn btn-nr btn-grouped btn-close btn-comment js-note-target-close #{issue_button_visibility(@issue, true)}", title: 'Close issue' + = link_to '重新打开问题', issue_path(@issue, issue: {state_event: :reopen}, status_only: true, format: 'json'), data: {no_turbolink: true, original_text: "Reopen issue", alternative_text: "评论 & 重新打开问题"}, class: "btn btn-nr btn-grouped btn-reopen btn-comment js-note-target-reopen #{issue_button_visibility(@issue, false)}", title: '重新打开问题' + = link_to '关闭问题', issue_path(@issue, issue: {state_event: :close}, status_only: true, format: 'json'), data: {no_turbolink: true, original_text: "Close issue", alternative_text: "评论 & 关闭问题"}, class: "btn btn-nr btn-grouped btn-close btn-comment js-note-target-close #{issue_button_visibility(@issue, true)}", title: '关闭问题' #notes = render 'projects/notes/notes_with_form' diff --git a/app/views/projects/issues/_merge_requests.html.haml b/app/views/projects/issues/_merge_requests.html.haml index f767ce3f86a..f6e41f0cc50 100644 --- a/app/views/projects/issues/_merge_requests.html.haml +++ b/app/views/projects/issues/_merge_requests.html.haml @@ -1,6 +1,6 @@ - if @merge_requests.any? %h2.merge-requests-title - = pluralize(@merge_requests.count, 'Related Merge Request') + = pluralize(@merge_requests.count, '个相关合并请求', '个相关合并请求') %ul.unstyled-list - has_any_ci = @merge_requests.any?(&:ci_commit) - @merge_requests.each do |merge_request| diff --git a/app/views/projects/issues/_new_branch.html.haml b/app/views/projects/issues/_new_branch.html.haml index e66e4669d48..18dda5d944c 100644 --- a/app/views/projects/issues/_new_branch.html.haml +++ b/app/views/projects/issues/_new_branch.html.haml @@ -2,4 +2,4 @@ .pull-right = link_to namespace_project_branches_path(@project.namespace, @project, branch_name: @issue.to_branch_name, issue_iid: @issue.iid), method: :post, class: 'btn', title: @issue.to_branch_name do = icon('code-fork') - New Branch + 新分支 diff --git a/app/views/projects/issues/_related_branches.html.haml b/app/views/projects/issues/_related_branches.html.haml index b10cd03515f..20b960705d7 100644 --- a/app/views/projects/issues/_related_branches.html.haml +++ b/app/views/projects/issues/_related_branches.html.haml @@ -1,6 +1,6 @@ - if @related_branches.any? %h2.related-branches-title - = pluralize(@related_branches.count, 'Related Branch') + = pluralize(@related_branches.count, '个相关分支', '个相关分支') %ul.unstyled-list - @related_branches.each do |branch| %li diff --git a/app/views/projects/issues/show.html.haml b/app/views/projects/issues/show.html.haml index 2bcfdaaf4da..bb72955c608 100644 --- a/app/views/projects/issues/show.html.haml +++ b/app/views/projects/issues/show.html.haml @@ -9,12 +9,12 @@ .pull-left .status-box{ class: "status-box-closed #{issue_button_visibility(@issue, false)}"} %span.hidden-xs - Closed + 已关闭 %span.hidden-sm.hidden-md.hidden-lg = icon('check') .status-box{ class: "status-box-open #{issue_button_visibility(@issue, true)}"} %span.hidden-xs - Open + 未关闭 %span.hidden-sm.hidden-md.hidden-lg = icon('circle-o') @@ -24,30 +24,31 @@ .issue-meta = confidential_icon(@issue) %strong.identifier - Issue ##{@issue.iid} + 问题 ##{@issue.iid} %span.creator - opened + 在 .editor-details .editor-details = time_ago_with_tooltip(@issue.created_at) - by + 由 %strong = link_to_member(@project, @issue.author, size: 24, mobile_classes: "hidden-xs") %strong = link_to_member(@project, @issue.author, size: 24, mobile_classes: "hidden-sm hidden-md hidden-lg", by_username: true, avatar: false) + 打开 .pull-right.issue-btn-group - if can?(current_user, :create_issue, @project) - = link_to new_namespace_project_issue_path(@project.namespace, @project), class: 'btn btn-nr btn-grouped new-issue-link btn-success', title: 'New issue', id: 'new_issue_link' do + = link_to new_namespace_project_issue_path(@project.namespace, @project), class: 'btn btn-nr btn-grouped new-issue-link btn-success', title: '新问题', id: 'new_issue_link' do = icon('plus') - New issue + 新问题 - if can?(current_user, :update_issue, @issue) - = link_to 'Reopen issue', issue_path(@issue, issue: {state_event: :reopen}, status_only: true, format: 'json'), data: {no_turbolink: true}, class: "btn btn-nr btn-grouped btn-reopen #{issue_button_visibility(@issue, false)}", title: 'Reopen issue' - = link_to 'Close issue', issue_path(@issue, issue: {state_event: :close}, status_only: true, format: 'json'), data: {no_turbolink: true}, class: "btn btn-nr btn-grouped btn-close #{issue_button_visibility(@issue, true)}", title: 'Close issue' + = link_to '重新打开问题', issue_path(@issue, issue: {state_event: :reopen}, status_only: true, format: 'json'), data: {no_turbolink: true}, class: "btn btn-nr btn-grouped btn-reopen #{issue_button_visibility(@issue, false)}", title: '重新打开问题' + = link_to '关闭问题', issue_path(@issue, issue: {state_event: :close}, status_only: true, format: 'json'), data: {no_turbolink: true}, class: "btn btn-nr btn-grouped btn-close #{issue_button_visibility(@issue, true)}", title: '关闭问题' = link_to edit_namespace_project_issue_path(@project.namespace, @project, @issue), class: 'btn btn-nr btn-grouped issuable-edit' do = icon('pencil-square-o') - Edit + 编辑 .issue-details.issuable-details diff --git a/app/views/projects/labels/_form.html.haml b/app/views/projects/labels/_form.html.haml index dc6e8243ca4..9ed0690d782 100644 --- a/app/views/projects/labels/_form.html.haml +++ b/app/views/projects/labels/_form.html.haml @@ -8,23 +8,23 @@ %br .form-group - = f.label :title, class: 'control-label' + = f.label :title, "标题", class: 'control-label' .col-sm-10 = f.text_field :title, class: "form-control", required: true, autofocus: true .form-group - = f.label :description, class: 'control-label' + = f.label :description, "描述", class: 'control-label' .col-sm-10 = f.text_field :description, class: "form-control js-quick-submit" .form-group - = f.label :color, "Background color", class: 'control-label' + = f.label :color, "背景色", class: 'control-label' .col-sm-10 .input-group .input-group-addon.label-color-preview = f.color_field :color, class: "form-control" .help-block - Choose any color. + 选择任意颜色。 %br - Or you can choose one of suggested colors below + 或者在下面选择一个推荐的颜色 .suggest-colors - suggested_colors.each do |color| diff --git a/app/views/projects/labels/_label.html.haml b/app/views/projects/labels/_label.html.haml index 4927d239c1e..8e36302a0a7 100644 --- a/app/views/projects/labels/_label.html.haml +++ b/app/views/projects/labels/_label.html.haml @@ -4,11 +4,11 @@ .pull-right %strong.append-right-20 = link_to_label(label, type: :merge_request) do - = pluralize label.open_merge_requests_count, 'open merge request' + = pluralize label.open_merge_requests_count, '个未关闭合并请求', '个未关闭合并请求' %strong.append-right-20 = link_to_label(label) do - = pluralize label.open_issues_count, 'open issue' + = pluralize label.open_issues_count, '个未关闭问题', '个未关闭问题' - if current_user .label-subscription{data: {url: toggle_subscription_namespace_project_label_path(@project.namespace, @project, label)}} @@ -17,8 +17,8 @@ %span= label_subscription_toggle_button_text(label) - if can? current_user, :admin_label, @project - = link_to 'Edit', edit_namespace_project_label_path(@project.namespace, @project, label), class: 'btn btn-sm' - = link_to 'Delete', namespace_project_label_path(@project.namespace, @project, label), class: 'btn btn-sm btn-remove remove-row', method: :delete, remote: true, data: {confirm: "Remove this label? Are you sure?"} + = link_to '编辑', edit_namespace_project_label_path(@project.namespace, @project, label), class: 'btn btn-sm' + = link_to '删除', namespace_project_label_path(@project.namespace, @project, label), class: 'btn btn-sm btn-remove remove-row', method: :delete, remote: true, data: {confirm: "确定要删除这个标记么?"} - if current_user :javascript diff --git a/app/views/projects/merge_requests/_discussion.html.haml b/app/views/projects/merge_requests/_discussion.html.haml index 393998f15b9..fdabcf57733 100644 --- a/app/views/projects/merge_requests/_discussion.html.haml +++ b/app/views/projects/merge_requests/_discussion.html.haml @@ -1,8 +1,8 @@ - content_for :note_actions do - if can?(current_user, :update_merge_request, @merge_request) - if @merge_request.open? - = link_to 'Close merge request', merge_request_path(@merge_request, merge_request: {state_event: :close }), method: :put, class: "btn btn-nr btn-comment btn-grouped btn-close close-mr-link js-note-target-close", title: "Close merge request", data: {original_text: "Close merge request", alternative_text: "Comment & close merge request"} + = link_to '关闭合并请求', merge_request_path(@merge_request, merge_request: {state_event: :close }), method: :put, class: "btn btn-nr btn-comment btn-grouped btn-close close-mr-link js-note-target-close", title: "Close merge request", data: {original_text: "关闭合并请求", alternative_text: "评论 & 关闭合并请求"} - if @merge_request.closed? - = link_to 'Reopen merge request', merge_request_path(@merge_request, merge_request: {state_event: :reopen }), method: :put, class: "btn btn-nr btn-comment btn-grouped btn-reopen reopen-mr-link js-note-target-reopen", title: "Reopen merge request", data: {original_text: "Reopen merge request", alternative_text: "Comment & reopen merge request"} + = link_to '重新打开合并请求', merge_request_path(@merge_request, merge_request: {state_event: :reopen }), method: :put, class: "btn btn-nr btn-comment btn-grouped btn-reopen reopen-mr-link js-note-target-reopen", title: "Reopen merge request", data: {original_text: "重新打开合并请求", alternative_text: "评论 & 重新打开合并请求"} #notes= render "projects/notes/notes_with_form" diff --git a/app/views/projects/merge_requests/_merge_request.html.haml b/app/views/projects/merge_requests/_merge_request.html.haml index bcfec88c3a6..25b4bd9ede6 100644 --- a/app/views/projects/merge_requests/_merge_request.html.haml +++ b/app/views/projects/merge_requests/_merge_request.html.haml @@ -49,8 +49,8 @@ .merge-request-info #{merge_request.to_reference} · - opened #{time_ago_with_tooltip(merge_request.created_at, placement: 'bottom')} - by #{link_to_member(@project, merge_request.author, avatar: false)} + 在 #{time_ago_with_tooltip(merge_request.created_at, placement: 'bottom')} + 由 #{link_to_member(@project, merge_request.author, avatar: false)} 打开 - if merge_request.target_project.default_branch != merge_request.target_branch = link_to namespace_project_commits_path(merge_request.project.namespace, merge_request.project, merge_request.target_branch) do diff --git a/app/views/projects/merge_requests/_new_compare.html.haml b/app/views/projects/merge_requests/_new_compare.html.haml index 74572b9b370..2f6895ae411 100644 --- a/app/views/projects/merge_requests/_new_compare.html.haml +++ b/app/views/projects/merge_requests/_new_compare.html.haml @@ -36,19 +36,19 @@ .light-well.append-bottom-default .center %h4 - There isn't anything to merge. + 没有任何内容合并。 %p.slead - if @merge_request.source_branch == @merge_request.target_branch - You'll need to use different branch names to get a valid comparison. + 必须使用不同的分支名来比较。 - else %span.label-branch #{@merge_request.source_branch} - and + 和 %span.label-branch #{@merge_request.target_branch} - are the same. + 是一样的。 .form-actions - = f.submit 'Compare branches and continue', class: "btn btn-new mr-compare-btn" + = f.submit '比较分支后继续', class: "btn btn-new mr-compare-btn" :javascript var source_branch = $("#merge_request_source_branch") diff --git a/app/views/projects/merge_requests/_new_submit.html.haml b/app/views/projects/merge_requests/_new_submit.html.haml index 4fad7e9f6fd..0847215cf72 100644 --- a/app/views/projects/merge_requests/_new_submit.html.haml +++ b/app/views/projects/merge_requests/_new_submit.html.haml @@ -21,16 +21,16 @@ %ul.merge-request-tabs.nav-links.no-top.no-bottom %li.commits-tab = link_to url_for(params), data: {target: 'div#commits', action: 'commits', toggle: 'tab'} do - Commits + 提交 %span.badge= @commits.size - if @ci_commit %li.builds-tab.active = link_to url_for(params), data: {target: 'div#builds', action: 'builds', toggle: 'tab'} do - Builds + 构建 %span.badge= @statuses.size %li.diffs-tab.active = link_to url_for(params), data: {target: 'div#diffs', action: 'diffs', toggle: 'tab'} do - Changes + 变更 %span.badge= @diffs.real_size .tab-content @@ -39,8 +39,8 @@ #diffs.diffs.tab-pane.active - if @commits.size > MergeRequestDiff::COMMITS_SAFE_SIZE .alert.alert-danger - %h4 This comparison includes more than #{MergeRequestDiff::COMMITS_SAFE_SIZE} commits. - %p To preserve performance the line changes are not shown. + %h4 此比较包含超过 #{MergeRequestDiff::COMMITS_SAFE_SIZE} 次提交。 + %p 为保证性能,行变更内容没有显示。 - else = render "projects/diffs/diffs", diffs: @diffs, project: @project, diff_refs: @merge_request.diff_refs - if @ci_commit diff --git a/app/views/projects/merge_requests/_show.html.haml b/app/views/projects/merge_requests/_show.html.haml index ee5b9fd95a8..cafbacfe260 100644 --- a/app/views/projects/merge_requests/_show.html.haml +++ b/app/views/projects/merge_requests/_show.html.haml @@ -1,4 +1,4 @@ -- page_title "#{@merge_request.title} (#{@merge_request.to_reference})", "Merge Requests" +- page_title "#{@merge_request.title} (#{@merge_request.to_reference})", "合并请求" - page_description @merge_request.description - page_card_attributes @merge_request.card_attributes @@ -18,20 +18,20 @@ - if @merge_request.source_branch_exists? = link_to "#modal_merge_info", class: "btn btn-sm", "data-toggle" => "modal" do = icon('cloud-download fw') - Check out branch + 检出分支 %span.dropdown %a.btn.btn-sm.dropdown-toggle{ data: {toggle: :dropdown} } = icon('download') - Download as + 下载为 %span.caret %ul.dropdown-menu - %li= link_to "Email Patches", merge_request_path(@merge_request, format: :patch) - %li= link_to "Plain Diff", merge_request_path(@merge_request, format: :diff) + %li= link_to "电子邮件补丁", merge_request_path(@merge_request, format: :patch) + %li= link_to "原始差异文件", merge_request_path(@merge_request, format: :diff) .normal - %span Request to merge + %span 请求合并 %span.label-branch= source_branch_with_namespace(@merge_request) - %span into + %span 到 = link_to namespace_project_commits_path(@project.namespace, @project, @merge_request.target_branch), class: "label-branch" do = @merge_request.target_branch - if @merge_request.open? && @merge_request.diverged_from_target_branch? @@ -42,28 +42,28 @@ - if @merge_request.source_branch_exists? && @merge_request.mergeable? && @merge_request.can_be_merged_by?(current_user) .light.prepend-top-default - You can also accept this merge request manually using the - = succeed '.' do - = link_to "command line", "#modal_merge_info", class: "how_to_merge_link vlink", title: "How To Merge", "data-toggle" => "modal" + 也可以使用 + = succeed '手工接受此合并请求。' do + = link_to "命令行", "#modal_merge_info", class: "how_to_merge_link vlink", title: "如何合并", "data-toggle" => "modal" - if @commits.present? %ul.merge-request-tabs.nav-links.no-top.no-bottom %li.notes-tab = link_to namespace_project_merge_request_path(@project.namespace, @project, @merge_request), data: {target: 'div#notes', action: 'notes', toggle: 'tab'} do - Discussion + 讨论 %span.badge= @merge_request.mr_and_commit_notes.user.count %li.commits-tab = link_to commits_namespace_project_merge_request_path(@project.namespace, @project, @merge_request), data: {target: 'div#commits', action: 'commits', toggle: 'tab'} do - Commits + 提交 %span.badge= @commits.size - if @ci_commit %li.builds-tab = link_to builds_namespace_project_merge_request_path(@project.namespace, @project, @merge_request), data: {target: '#builds', action: 'builds', toggle: 'tab'} do - Builds + 构建 %span.badge= @statuses.size %li.diffs-tab = link_to diffs_namespace_project_merge_request_path(@project.namespace, @project, @merge_request), data: {target: 'div#diffs', action: 'diffs', toggle: 'tab'} do - Changes + 变更 %span.badge= @merge_request.diff_size .tab-content diff --git a/app/views/projects/merge_requests/show/_diffs.html.haml b/app/views/projects/merge_requests/show/_diffs.html.haml index 1b0bae86ad4..e9f388458a5 100644 --- a/app/views/projects/merge_requests/show/_diffs.html.haml +++ b/app/views/projects/merge_requests/show/_diffs.html.haml @@ -2,12 +2,12 @@ = render "projects/diffs/diffs", diffs: @merge_request.diffs(diff_options), project: @merge_request.project, diff_refs: @merge_request.diff_refs - elsif @merge_request_diff.empty? - .nothing-here-block Nothing to merge from #{@merge_request.source_branch} into #{@merge_request.target_branch} + .nothing-here-block 从 #{@merge_request.source_branch} 到 #{@merge_request.target_branch} 无需合并 - else .alert.alert-warning %h4 - Changes view for this comparison is extremely large. + 此比较的变更视图非常巨大。 %p - You can - = link_to "download it", merge_request_path(@merge_request, format: :diff), class: "vlink" - instead. + 可以 + = link_to "下载差异", merge_request_path(@merge_request, format: :diff), class: "vlink" + 到本地查看。 diff --git a/app/views/projects/merge_requests/show/_how_to_merge.html.haml b/app/views/projects/merge_requests/show/_how_to_merge.html.haml deleted file mode 100644 index ce5adf837b4..00000000000 --- a/app/views/projects/merge_requests/show/_how_to_merge.html.haml +++ /dev/null @@ -1,63 +0,0 @@ -%div#modal_merge_info.modal - .modal-dialog - .modal-content - .modal-header - %a.close{href: "#", "data-dismiss" => "modal"} × - %h3 检出,在本地审查和合并 - .modal-body - %p - %strong 第 1 步. - 获取并检出此合并请求的分支 - = clipboard_button(clipboard_target: 'pre#merge-info-1') - %pre.dark#merge-info-1 - - if @merge_request.for_fork? - :preserve - git fetch #{h @merge_request.source_project.http_url_to_repo} #{h @merge_request.source_branch} - git checkout -b #{h @merge_request.source_project_path}-#{h @merge_request.source_branch} FETCH_HEAD - - else - :preserve - git fetch origin - git checkout -b #{h @merge_request.source_branch} origin/#{h @merge_request.source_branch} - %p - %strong 第 2 步. - 本地审查变更 - - %p - %strong 第 3 步. - 合并分支并修复出现的任何冲突 - = clipboard_button(clipboard_target: 'pre#merge-info-3') - %pre.dark#merge-info-3 - - if @merge_request.for_fork? - :preserve - git checkout #{h @merge_request.target_branch} - git merge --no-ff #{h @merge_request.source_project_path}-#{h @merge_request.source_branch} - - else - :preserve - git checkout #{h @merge_request.target_branch} - git merge --no-ff #{h @merge_request.source_branch} - %p - %strong 第 4 步. - 推送合并的结果到 GitLab - = clipboard_button(clipboard_target: 'pre#merge-info-4') - %pre.dark#merge-info-4 - :preserve - git push origin #{h @merge_request.target_branch} - - unless @merge_request.can_be_merged_by?(current_user) - %p - 请注意推送到 GitLab 需要有此仓库的写权限。 - %p - %strong 提示: - 你可以使用 - %a{href: 'https://gitlab.com/gitlab-org/gitlab-ce/blob/master/doc/workflow/merge_requests.md#checkout-merge-requests-locally', target: '_blank'} 此指南 - 在本地检出合并请求 - -:javascript - $(function(){ - var modal = $('#modal_merge_info').modal({modal: true, show:false}); - $('.how_to_merge_link').bind("click", function(){ - modal.show(); - }); - $('.modal-header .close').bind("click", function(){ - modal.hide(); - }) - }) diff --git a/app/views/projects/merge_requests/show/_mr_title.html.haml b/app/views/projects/merge_requests/show/_mr_title.html.haml index ab4b1f14be5..f0008f5862d 100644 --- a/app/views/projects/merge_requests/show/_mr_title.html.haml +++ b/app/views/projects/merge_requests/show/_mr_title.html.haml @@ -11,25 +11,26 @@ %span.hidden-sm.hidden-md.hidden-lg MR %span.hidden-xs - Merge Request + 合并请求 !#{@merge_request.iid} %span.creator - opened + 在 .editor-details = time_ago_with_tooltip(@merge_request.created_at) - by + 由 %strong = link_to_member(@project, @merge_request.author, size: 24, mobile_classes: "hidden-xs") %strong = link_to_member(@project, @merge_request.author, size: 24, mobile_classes: "hidden-sm hidden-md hidden-lg", by_username: true, avatar: false) + 打开 .issue-btn-group.pull-right - if can?(current_user, :update_merge_request, @merge_request) - if @merge_request.open? - = link_to 'Close', merge_request_path(@merge_request, merge_request: { state_event: :close }), method: :put, class: 'btn btn-nr btn-grouped btn-close', title: 'Close merge request' + = link_to '关闭', merge_request_path(@merge_request, merge_request: { state_event: :close }), method: :put, class: 'btn btn-nr btn-grouped btn-close', title: '关闭合并请求' = link_to edit_namespace_project_merge_request_path(@project.namespace, @project, @merge_request), class: 'btn btn-nr btn-grouped issuable-edit', id: 'edit_merge_request' do = icon('pencil-square-o') - Edit + 编辑 - if @merge_request.closed? - = link_to 'Reopen', merge_request_path(@merge_request, merge_request: {state_event: :reopen }), method: :put, class: 'btn btn-nr btn-grouped btn-reopen reopen-mr-link', title: 'Reopen merge request' + = link_to '重新打开', merge_request_path(@merge_request, merge_request: {state_event: :reopen }), method: :put, class: 'btn btn-nr btn-grouped btn-reopen reopen-mr-link', title: '重新打开合并请求' diff --git a/app/views/projects/merge_requests/widget/open/_wip.html.haml b/app/views/projects/merge_requests/widget/open/_wip.html.haml index c296422a9cf..5b446dac738 100644 --- a/app/views/projects/merge_requests/widget/open/_wip.html.haml +++ b/app/views/projects/merge_requests/widget/open/_wip.html.haml @@ -1,11 +1,11 @@ %h4 - This merge request is currently a Work In Progress + 此合并请求当前正在处理中 - if can?(current_user, :update_merge_request, @merge_request) %p - When this merge request is ready, + 当合并请求准备好时, = link_to remove_wip_namespace_project_merge_request_path(@project.namespace, @project, @merge_request), method: :post do - remove the + 请从标题中删除 %code WIP: - prefix from the title - to allow it to be merged. + 前缀, + 以表示该合并请求可以被接受。 diff --git a/app/views/projects/milestones/_form.html.haml b/app/views/projects/milestones/_form.html.haml index 7d2545762b0..ff1cda373ae 100644 --- a/app/views/projects/milestones/_form.html.haml +++ b/app/views/projects/milestones/_form.html.haml @@ -7,11 +7,11 @@ .row .col-md-6 .form-group - = f.label :title, "Title", class: "control-label" + = f.label :title, "标题", class: "control-label" .col-sm-10 = f.text_field :title, maxlength: 255, class: "form-control", required: true, autofocus: true .form-group.milestone-description - = f.label :description, "Description", class: "control-label" + = f.label :description, "描述", class: "control-label" .col-sm-10 = render layout: 'projects/md_preview', locals: { preview_class: "md-preview" } do = render 'projects/zen', f: f, attr: :description, classes: 'description form-control' diff --git a/app/views/projects/milestones/show.html.haml b/app/views/projects/milestones/show.html.haml index 0b1bfc946c1..c3019cf3ce9 100644 --- a/app/views/projects/milestones/show.html.haml +++ b/app/views/projects/milestones/show.html.haml @@ -44,7 +44,7 @@ - if @milestone.complete?(current_user) && @milestone.active? .alert.alert-success.prepend-top-default - %span All issues for this milestone are closed. You may close milestone now. + %span 本里程碑的全部问题和合并请求都已关闭,可以选择关闭本里程碑。 = render 'shared/milestones/summary', milestone: @milestone, project: @project = render 'shared/milestones/tabs', milestone: @milestone diff --git a/app/views/projects/notes/_edit_form.html.haml b/app/views/projects/notes/_edit_form.html.haml index 2999befffc6..a1cdb6bc990 100644 --- a/app/views/projects/notes/_edit_form.html.haml +++ b/app/views/projects/notes/_edit_form.html.haml @@ -6,5 +6,5 @@ = render 'projects/notes/hints' .note-form-actions.clearfix - = f.submit 'Save Comment', class: 'btn btn-nr btn-save btn-grouped js-comment-button' - = link_to 'Cancel', '#', class: 'btn btn-nr btn-cancel note-edit-cancel' + = f.submit '保存评论', class: 'btn btn-nr btn-save btn-grouped js-comment-button' + = link_to '取消', '#', class: 'btn btn-nr btn-cancel note-edit-cancel' diff --git a/app/views/projects/notes/_form.html.haml b/app/views/projects/notes/_form.html.haml index f675f092da1..5c7b8da0f5a 100644 --- a/app/views/projects/notes/_form.html.haml +++ b/app/views/projects/notes/_form.html.haml @@ -13,7 +13,7 @@ .error-alert .note-form-actions.clearfix - = f.submit 'Comment', class: "btn btn-nr btn-create comment-btn btn-grouped js-comment-button" + = f.submit '评论', class: "btn btn-nr btn-create comment-btn btn-grouped js-comment-button" = yield(:note_actions) %a.btn.btn-cancel.js-note-discard{role: "button", data: {cancel_text: "Cancel"}} - Discard draft + 舍弃草稿 diff --git a/app/views/projects/notes/_note.html.haml b/app/views/projects/notes/_note.html.haml index f7eeaece3db..91c71bb3f5e 100644 --- a/app/views/projects/notes/_note.html.haml +++ b/app/views/projects/notes/_note.html.haml @@ -25,7 +25,7 @@ = '@' + note.author.username %span.note-last-update - %a{name: dom_id(note), href: "##{dom_id(note)}", title: 'Link here'} + %a{name: dom_id(note), href: "##{dom_id(note)}", title: '链接'} = time_ago_with_tooltip(note.created_at, placement: 'bottom', html_class: 'note_created_ago') .note-body{class: note_editable?(note) ? 'js-task-list-container' : ''} .note-text @@ -45,5 +45,5 @@ = icon('paperclip') = note.attachment_identifier = link_to delete_attachment_namespace_project_note_path(note.project.namespace, note.project, note), - title: 'Delete this attachment', method: :delete, remote: true, data: { confirm: 'Are you sure you want to remove the attachment?' }, class: 'danger js-note-attachment-delete' do + title: '删除此附件', method: :delete, remote: true, data: { confirm: '确定要删除此附件么?' }, class: 'danger js-note-attachment-delete' do = icon('trash-o', class: 'cred') diff --git a/app/views/projects/protected_branches/index.html.haml b/app/views/projects/protected_branches/index.html.haml index c7e60d615ec..c0df9848e34 100644 --- a/app/views/projects/protected_branches/index.html.haml +++ b/app/views/projects/protected_branches/index.html.haml @@ -6,9 +6,9 @@ .well %p 保护分支设计为: %ul - %li prevent pushes from everybody except #{link_to "masters", help_page_path("permissions", "permissions"), class: "vlink"} - %li prevent anyone from force pushing to the branch - %li prevent anyone from deleting the branch + %li 禁止除了#{link_to "主开发人员", help_page_path("permissions", "permissions"), class: "vlink"}外所有人推送 + %li 禁止任何强制推送此分支 + %li 禁止任何人删除此分支 %p 点击#{link_to "项目权限", help_page_path("permissions", "permissions"), class: "underlined-link"}了解更多 - if can? current_user, :admin_project, @project diff --git a/app/views/projects/releases/edit.html.haml b/app/views/projects/releases/edit.html.haml index fc86a1ace4f..27252abc2b3 100644 --- a/app/views/projects/releases/edit.html.haml +++ b/app/views/projects/releases/edit.html.haml @@ -1,12 +1,13 @@ -- page_title "Edit", @tag.name, "Tags" +- page_title "编辑", @tag.name, "标签" = render "projects/commits/header_title" = render "projects/commits/head" .gray-content-block .oneline .title - Release notes for tag + 标签 %strong #{@tag.name} + 的发布备注 .prepend-top-default = form_for(@release, method: :put, url: namespace_project_tag_release_path(@project.namespace, @project, @tag.name), html: { class: 'form-horizontal gfm-form release-form js-quick-submit' }) do |f| diff --git a/app/views/projects/repositories/_download_archive.html.haml b/app/views/projects/repositories/_download_archive.html.haml index 24658319060..d42aee7e058 100644 --- a/app/views/projects/repositories/_download_archive.html.haml +++ b/app/views/projects/repositories/_download_archive.html.haml @@ -5,28 +5,28 @@ %span.btn-group{class: btn_class} = link_to archive_namespace_project_repository_path(@project.namespace, @project, ref: ref, format: 'zip'), class: 'btn col-xs-10', rel: 'nofollow' do %i.fa.fa-download - %span Download zip + %span 下载 zip %a.col-xs-2.btn.dropdown-toggle{ 'data-toggle' => 'dropdown' } %span.caret %span.sr-only - Select Archive Format + 选择打包格式 %ul.col-xs-10.dropdown-menu.dropdown-menu-align-right{ role: 'menu' } %li = link_to archive_namespace_project_repository_path(@project.namespace, @project, ref: ref, format: 'zip'), rel: 'nofollow' do %i.fa.fa-download - %span Download zip + %span 下载 zip %li = link_to archive_namespace_project_repository_path(@project.namespace, @project, ref: ref, format: 'tar.gz'), rel: 'nofollow' do %i.fa.fa-download - %span Download tar.gz + %span 下载 tar.gz %li = link_to archive_namespace_project_repository_path(@project.namespace, @project, ref: ref, format: 'tar.bz2'), rel: 'nofollow' do %i.fa.fa-download - %span Download tar.bz2 + %span 下载 tar.bz2 %li = link_to archive_namespace_project_repository_path(@project.namespace, @project, ref: ref, format: 'tar'), rel: 'nofollow' do %i.fa.fa-download - %span Download tar + %span 下载 tar - else %span.btn-group{class: btn_class} = link_to archive_namespace_project_repository_path(@project.namespace, @project, ref: ref, format: 'zip'), class: 'btn', rel: 'nofollow' do diff --git a/app/views/projects/tags/new.html.haml b/app/views/projects/tags/new.html.haml index 367dc20dce7..8bfa1e0a146 100644 --- a/app/views/projects/tags/new.html.haml +++ b/app/views/projects/tags/new.html.haml @@ -7,35 +7,35 @@ = @error %h3.page-title - New Tag + 新标签 %hr = form_tag namespace_project_tags_path, method: :post, id: "new-tag-form", class: "form-horizontal gfm-form tag-form js-quick-submit js-requires-input" do .form-group - = label_tag :tag_name, nil, class: 'control-label' + = label_tag :tag_name, '标签名称', class: 'control-label' .col-sm-10 = text_field_tag :tag_name, params[:tag_name], required: true, tabindex: 1, autofocus: true, class: 'form-control' .form-group - = label_tag :ref, 'Create from', class: 'control-label' + = label_tag :ref, '创建自', class: 'control-label' .col-sm-10 = text_field_tag :ref, params[:ref] || @project.default_branch, required: true, tabindex: 2, class: 'form-control' - .help-block Branch name or commit SHA + .help-block 分支名称或提交 SHA .form-group - = label_tag :message, nil, class: 'control-label' + = label_tag :message, '信息', class: 'control-label' .col-sm-10 = text_field_tag :message, nil, required: false, tabindex: 3, class: 'form-control' - .help-block Optionally, enter a message to create an annotated tag. + .help-block 可选,输入创建标签的信息。 %hr .form-group - = label_tag :release_description, 'Release notes', class: 'control-label' + = label_tag :release_description, '发布备注', class: 'control-label' .col-sm-10 = render layout: 'projects/md_preview', locals: { preview_class: "md-preview", referenced_users: true } do = render 'projects/zen', attr: :release_description, classes: 'description form-control' = render 'projects/notes/hints' - .help-block Optionally, add release notes to the tag. They will be stored in the GitLab database and displayed on the tags page. + .help-block 可选,可以给标签增加发布备注。备注会储存在 GitLab 数据库并显示在标签页。 .form-actions - = button_tag 'Create tag', class: 'btn btn-create', tabindex: 3 - = link_to 'Cancel', namespace_project_tags_path(@project.namespace, @project), class: 'btn btn-cancel' + = button_tag '创建标签', class: 'btn btn-create', tabindex: 3 + = link_to '取消', namespace_project_tags_path(@project.namespace, @project), class: 'btn btn-cancel' :javascript var availableRefs = #{@project.repository.ref_names.to_json}; diff --git a/app/views/projects/wikis/_form.html.haml b/app/views/projects/wikis/_form.html.haml index fde8753f01f..b75cc0f1267 100644 --- a/app/views/projects/wikis/_form.html.haml +++ b/app/views/projects/wikis/_form.html.haml @@ -7,12 +7,12 @@ = f.hidden_field :title, value: @page.title .form-group - = f.label :format, class: 'control-label' + = f.label :format, '格式', class: 'control-label' .col-sm-10 = f.select :format, options_for_select(ProjectWiki::MARKUPS, {selected: @page.format}), {}, class: "form-control" .form-group - = f.label :content, class: 'control-label' + = f.label :content, '内容', class: 'control-label' .col-sm-10 = render layout: 'projects/md_preview', locals: { preview_class: "md-preview" } do = render 'projects/zen', f: f, attr: :content, classes: 'description form-control' diff --git a/app/views/search/_filter.html.haml b/app/views/search/_filter.html.haml index 4ef544136a8..2b3dac885f6 100644 --- a/app/views/search/_filter.html.haml +++ b/app/views/search/_filter.html.haml @@ -1,21 +1,21 @@ .dropdown.inline %button.dropdown-toggle.btn.btn-sm{type: 'button', 'data-toggle' => 'dropdown'} - %span.light Group: + %span.light 群组: - if @group.present? %strong= @group.name - else - Any + 任何 %b.caret .dropdown-menu.dropdown-select.dropdown-menu-selectable .dropdown-title - %span Filter results by group + %span 按群组过滤的结果 %button.dropdown-title-button.dropdown-menu-close{aria: {label: "Close"}} = icon('times') .dropdown-content %ul %li = link_to search_filter_path(group_id: nil), class: ("is-active" if !params[:group_id].present?) do - Any + 任何 %li.divider - current_user.authorized_groups.sort_by(&:name).each do |group| %li @@ -24,22 +24,22 @@ .dropdown.inline.prepend-left-10.project-filter %button.dropdown-toggle.btn.btn-sm{type: 'button', 'data-toggle' => 'dropdown'} - %span.light Project: + %span.light 项目: - if @project.present? %strong= @project.name_with_namespace - else - Any + 任何 %b.caret .dropdown-menu.dropdown-select.dropdown-menu-selectable .dropdown-title - %span Filter results by project + %span 按项目过滤的结果 %button.dropdown-title-button.dropdown-menu-close{aria: {label: "Close"}} = icon('times') .dropdown-content %ul %li = link_to search_filter_path(project_id: nil), class: ("is-active" if !params[:project_id].present?) do - Any + 任何 %li.divider - current_user.authorized_projects.sort_by(&:name_with_namespace).each do |project| %li diff --git a/app/views/search/_form.html.haml b/app/views/search/_form.html.haml index a9dbc84da29..b5693c763f8 100644 --- a/app/views/search/_form.html.haml +++ b/app/views/search/_form.html.haml @@ -6,9 +6,9 @@ .search-holder.clearfix .input-group - = search_field_tag :search, params[:search], placeholder: "Search for projects, issues etc", class: "form-control search-text-input", id: "dashboard_search", autofocus: true, spellcheck: false + = search_field_tag :search, params[:search], placeholder: "搜索项目、问题等", class: "form-control search-text-input", id: "dashboard_search", autofocus: true, spellcheck: false %span.input-group-btn - = button_tag 'Search', class: "btn btn-primary" + = button_tag '搜索', class: "btn btn-primary" - unless params[:snippets].eql? 'true' %br = render 'filter' if current_user diff --git a/app/views/shared/_group_form.html.haml b/app/views/shared/_group_form.html.haml index a94359501ab..7dacd0d7da5 100644 --- a/app/views/shared/_group_form.html.haml +++ b/app/views/shared/_group_form.html.haml @@ -18,7 +18,7 @@ .alert.alert-warning.prepend-top-10 %ul %li 修改群组路径会存在意想不到的副作用。 - %li 重命名群组路径会重命名所有相关项目的路径 + %li 重命名群组路径会重命名全部相关项目的路径 %li 包括改变群组和群组项目的网页访问链接。 %li 包括改变群组下版本库的 git 路径。 diff --git a/app/views/shared/_group_tips.html.haml b/app/views/shared/_group_tips.html.haml index 46e4340511a..28c1dcf96c7 100644 --- a/app/views/shared/_group_tips.html.haml +++ b/app/views/shared/_group_tips.html.haml @@ -1,5 +1,5 @@ %ul - %li A group is a collection of several projects - %li Members of a group may only view projects they have permission to access - %li Group project URLs are prefixed with the group namespace - %li Existing projects may be moved into a group + %li 群组是多个项目的集合 + %li 只有群组的成员才有权查看项目 + %li 群组项目的 URL 都会带上群组的命名空间 + %li 现有项目可以转移到群组 diff --git a/app/views/shared/_issues.html.haml b/app/views/shared/_issues.html.haml index 8ff9d4c1c7f..5aa81c2f6fc 100644 --- a/app/views/shared/_issues.html.haml +++ b/app/views/shared/_issues.html.haml @@ -6,11 +6,11 @@ = link_to project.name_with_namespace, namespace_project_issues_path(project.namespace, project) - if can?(current_user, :create_issue, project) .pull-right - = link_to 'New issue', new_namespace_project_issue_path(project.namespace, project) + = link_to '新问题', new_namespace_project_issue_path(project.namespace, project) %ul.content-list.issues-list - group[1].each do |issue| = render 'projects/issues/issue', issue: issue = paginate @issues, theme: "gitlab" - else - .nothing-here-block No issues to show + .nothing-here-block 没有问题 diff --git a/app/views/shared/_merge_requests.html.haml b/app/views/shared/_merge_requests.html.haml index 43ab4c75ebd..076300f9be0 100644 --- a/app/views/shared/_merge_requests.html.haml +++ b/app/views/shared/_merge_requests.html.haml @@ -6,7 +6,7 @@ = link_to project.name_with_namespace, namespace_project_merge_requests_path(project.namespace, project) - if can?(current_user, :create_merge_request, project) .pull-right - = link_to 'New merge request', new_namespace_project_merge_request_path(project.namespace, project) + = link_to '新合并请求', new_namespace_project_merge_request_path(project.namespace, project) %ul.content-list.mr-list - group[1].each do |merge_request| diff --git a/app/views/shared/_no_ssh.html.haml b/app/views/shared/_no_ssh.html.haml index bb5fff2d3bb..685a0671fc2 100644 --- a/app/views/shared/_no_ssh.html.haml +++ b/app/views/shared/_no_ssh.html.haml @@ -1,8 +1,8 @@ - if cookies[:hide_no_ssh_message].blank? && !current_user.hide_no_ssh_key && current_user.require_ssh_key? .no-ssh-key-message.alert.alert-warning.hidden-xs - You won't be able to pull or push project code via SSH until you #{link_to 'add an SSH key', profile_keys_path, class: 'alert-link'} to your profile + 你的账号没有配置用于拉取/推送 SSH 版本库的密钥,请立即在个人资料中#{link_to '增加 SSH 密钥', profile_keys_path, class: 'alert-link'} .pull-right - = link_to "Don't show again", profile_path(user: {hide_no_ssh_key: true}), method: :put, class: 'alert-link' + = link_to "不再显示", profile_path(user: {hide_no_ssh_key: true}), method: :put, class: 'alert-link' | - = link_to 'Remind later', '#', class: 'hide-no-ssh-message alert-link' + = link_to '稍后提示', '#', class: 'hide-no-ssh-message alert-link' diff --git a/app/views/shared/groups/_group.html.haml b/app/views/shared/groups/_group.html.haml index ddd74b5353c..d2cd10f3ffe 100644 --- a/app/views/shared/groups/_group.html.haml +++ b/app/views/shared/groups/_group.html.haml @@ -29,7 +29,7 @@ = group.name - if group_member - as + 身份: %span #{group_member.human_access} - if group.description.present? diff --git a/app/views/shared/groups/_list.html.haml b/app/views/shared/groups/_list.html.haml index 1aa7ed1f2eb..de6ca8f0338 100644 --- a/app/views/shared/groups/_list.html.haml +++ b/app/views/shared/groups/_list.html.haml @@ -3,4 +3,4 @@ - groups.each_with_index do |group, i| = render "shared/groups/group", group: group - else - %h3 No groups found + %h3 没有群组 diff --git a/app/views/shared/issuable/_filter.html.haml b/app/views/shared/issuable/_filter.html.haml index ac20f7d1f7e..dff30d69838 100644 --- a/app/views/shared/issuable/_filter.html.haml +++ b/app/views/shared/issuable/_filter.html.haml @@ -9,14 +9,14 @@ .filter-item.inline - if params[:author_id] = hidden_field_tag(:author_id, params[:author_id]) - = dropdown_tag(user_dropdown_label(params[:author_id], "Author"), options: { toggle_class: "js-user-search js-filter-submit js-author-search", title: "Filter by author", filter: true, dropdown_class: "dropdown-menu-user dropdown-menu-selectable dropdown-menu-author", - placeholder: "Search authors", data: { any_user: "Any Author", first_user: (current_user.username if current_user), current_user: true, project_id: (@project.id if @project), selected: params[:author_id], field_name: "author_id", default_label: "Author" } }) + = dropdown_tag(user_dropdown_label(params[:author_id], "作者"), options: { toggle_class: "js-user-search js-filter-submit js-author-search", title: "按作者过滤", filter: true, dropdown_class: "dropdown-menu-user dropdown-menu-selectable dropdown-menu-author", + placeholder: "搜索作者", data: { any_user: "任何作者", first_user: (current_user.username if current_user), current_user: true, project_id: (@project.id if @project), selected: params[:author_id], field_name: "author_id", default_label: "作者" } }) .filter-item.inline - if params[:assignee_id] = hidden_field_tag(:assignee_id, params[:assignee_id]) - = dropdown_tag(user_dropdown_label(params[:assignee_id], "Assignee"), options: { toggle_class: "js-user-search js-filter-submit js-assignee-search", title: "Filter by assignee", filter: true, dropdown_class: "dropdown-menu-user dropdown-menu-selectable dropdown-menu-assignee", - placeholder: "Search assignee", data: { any_user: "Any Assignee", first_user: (current_user.username if current_user), null_user: true, current_user: true, project_id: (@project.id if @project), selected: params[:assignee_id], field_name: "assignee_id", default_label: "Assignee" } }) + = dropdown_tag(user_dropdown_label(params[:assignee_id], "指派"), options: { toggle_class: "js-user-search js-filter-submit js-assignee-search", title: "按指派过滤", filter: true, dropdown_class: "dropdown-menu-user dropdown-menu-selectable dropdown-menu-assignee", + placeholder: "搜索指派", data: { any_user: "任何指派", first_user: (current_user.username if current_user), null_user: true, current_user: true, project_id: (@project.id if @project), selected: params[:assignee_id], field_name: "assignee_id", default_label: "指派" } }) .filter-item.inline.milestone-filter = render "shared/issuable/milestone_dropdown" @@ -31,22 +31,22 @@ .issues_bulk_update.hide = form_tag bulk_update_namespace_project_issues_path(@project.namespace, @project), method: :post do .filter-item.inline - = dropdown_tag("Status", options: { toggle_class: "js-issue-status", title: "Change status", dropdown_class: "dropdown-menu-selectable", data: { field_name: "update[state_event]" } } ) do + = dropdown_tag("Status", options: { toggle_class: "js-issue-status", title: "更改状态", dropdown_class: "dropdown-menu-selectable", data: { field_name: "update[state_event]" } } ) do %ul %li - %a{href: "#", data: {id: "reopen"}} Open + %a{href: "#", data: {id: "reopen"}} 未关闭 %li - %a{href: "#", data: {id: "close"}} Closed + %a{href: "#", data: {id: "close"}} 已关闭 .filter-item.inline - = dropdown_tag("Assignee", options: { toggle_class: "js-user-search", title: "Assign to", filter: true, dropdown_class: "dropdown-menu-user dropdown-menu-selectable", - placeholder: "Search authors", data: { first_user: (current_user.username if current_user), null_user: true, current_user: true, project_id: @project.id, field_name: "update[assignee_id]" } }) + = dropdown_tag("指派", options: { toggle_class: "js-user-search", title: "指派给", filter: true, dropdown_class: "dropdown-menu-user dropdown-menu-selectable", + placeholder: "搜索作者", data: { first_user: (current_user.username if current_user), null_user: true, current_user: true, project_id: @project.id, field_name: "update[assignee_id]" } }) .filter-item.inline - = dropdown_tag("Milestone", options: { title: "Assign milestone", toggle_class: 'js-milestone-select', filter: true, dropdown_class: "dropdown-menu-selectable", - placeholder: "Search milestones", data: { show_no: true, field_name: "update[milestone_id]", project_id: @project.id, milestones: namespace_project_milestones_path(@project.namespace, @project, :js), use_id: true } }) + = dropdown_tag("里程碑", options: { title: "指派到里程碑", toggle_class: 'js-milestone-select', filter: true, dropdown_class: "dropdown-menu-selectable", + placeholder: "搜索里程碑", data: { show_no: true, field_name: "update[milestone_id]", project_id: @project.id, milestones: namespace_project_milestones_path(@project.namespace, @project, :js), use_id: true } }) = hidden_field_tag 'update[issues_ids]', [] = hidden_field_tag :state_event, params[:state_event] .filter-item.inline - = button_tag "Update issues", class: "btn update_selected_issues btn-save" + = button_tag "更新问题", class: "btn update_selected_issues btn-save" - if @label .gray-content-block.second-block diff --git a/app/views/shared/issuable/_form.html.haml b/app/views/shared/issuable/_form.html.haml index 551f0cc0b51..39cc1ac70a2 100644 --- a/app/views/shared/issuable/_form.html.haml +++ b/app/views/shared/issuable/_form.html.haml @@ -6,7 +6,7 @@ %span= msg %br .form-group - = f.label :title, class: 'control-label' + = f.label :title, '标题', class: 'control-label' .col-sm-10 = f.text_field :title, maxlength: 255, autofocus: true, autocomplete: 'off', class: 'form-control pad js-gfm-input', required: true @@ -15,21 +15,21 @@ %p.help-block .js-wip-explanation %a.js-toggle-wip{href: ""} - Remove the + 从标题中删除 %code WIP: - prefix from the title - to allow this - %strong Work In Progress - merge request to be merged when it's ready. + 前缀 + 表示允许此标识为 + %strong 正在处理中 + 的合并请求已准备好可以被接受。 .js-no-wip-explanation %a.js-toggle-wip{href: ""} - Start the title with + 标题以 %code WIP: - to prevent a - %strong Work In Progress - merge request from being merged before it's ready. + 开头将合并请求标识为 + %strong 正在处理中 + 表示其还未准备好可以接受合并。 .form-group.detail-page-description - = f.label :description, 'Description', class: 'control-label' + = f.label :description, '描述', class: 'control-label' .col-sm-10 = render layout: 'projects/md_preview', locals: { preview_class: "md-preview", referenced_users: true } do @@ -45,93 +45,93 @@ .checkbox = f.label :confidential do = f.check_box :confidential - This issue is confidential and should only be visible to team members + 此问题是保密的,只对团队成员可见 - if can?(current_user, :"admin_#{issuable.to_ability_name}", issuable.project) %hr .form-group .issue-assignee - = f.label :assignee_id, "Assignee", class: 'control-label' + = f.label :assignee_id, "指派给", class: 'control-label' .col-sm-10 = users_select_tag("#{issuable.class.model_name.param_key}[assignee_id]", - placeholder: 'Select assignee', class: 'custom-form-control', null_user: true, + placeholder: '选择指派', class: 'custom-form-control', null_user: true, selected: issuable.assignee_id, project: @target_project || @project, first_user: true, current_user: true, include_blank: true) - = link_to 'Assign to me', '#', class: 'btn assign-to-me-link' + = link_to '指派给自己', '#', class: 'btn assign-to-me-link' .form-group .issue-milestone - = f.label :milestone_id, "Milestone", class: 'control-label' + = f.label :milestone_id, "里程碑", class: 'control-label' .col-sm-10 - if milestone_options(issuable).present? = f.select(:milestone_id, milestone_options(issuable), - { include_blank: true }, { class: 'select2', data: { placeholder: 'Select milestone' } }) + { include_blank: true }, { class: 'select2', data: { placeholder: '选择里程碑' } }) - else .prepend-top-10 - %span.light No open milestones available. + %span.light 没有可用的未关闭里程碑。 - if can? current_user, :admin_milestone, issuable.project - = link_to 'Create new milestone', new_namespace_project_milestone_path(issuable.project.namespace, issuable.project), target: :blank + = link_to '创建新的里程碑', new_namespace_project_milestone_path(issuable.project.namespace, issuable.project), target: :blank .form-group - = f.label :label_ids, "Labels", class: 'control-label' + = f.label :label_ids, "标记", class: 'control-label' .col-sm-10 - if issuable.project.labels.any? = f.collection_select :label_ids, issuable.project.labels.all, :id, :name, - { selected: issuable.label_ids }, multiple: true, class: 'select2', data: { placeholder: "Select labels" } + { selected: issuable.label_ids }, multiple: true, class: 'select2', data: { placeholder: "选择标记" } - else .prepend-top-10 - %span.light No labels yet. + %span.light 没有标记。 - if can? current_user, :admin_label, issuable.project - = link_to 'Create new label', new_namespace_project_label_path(issuable.project.namespace, issuable.project), target: :blank + = link_to '创建新的标记', new_namespace_project_label_path(issuable.project.namespace, issuable.project), target: :blank - if issuable.can_move?(current_user) %hr .form-group - = label_tag :move_to_project_id, 'Move', class: 'control-label' + = label_tag :move_to_project_id, '移动', class: 'control-label' .col-sm-10 - projects = project_options(issuable, current_user, ability: :admin_issue) = select_tag(:move_to_project_id, projects, include_blank: true, - class: 'select2', data: { placeholder: 'Select project' }) + class: 'select2', data: { placeholder: '选择项目' }) %span{ data: { toggle: 'tooltip', placement: 'auto top' }, style: 'cursor: default', - title: 'Moving an issue will copy the discussion to a different project and close it here. All participants will be notified of the new location.' } + title: '移动问题将复制讨论到不同的项目并关闭此问题。所有参与者都会收到新位置的通知。' } = icon('question-circle') - if issuable.is_a?(MergeRequest) %hr - if @merge_request.new_record? .form-group - = f.label :source_branch, class: 'control-label' + = f.label :source_branch, '来源分支', class: 'control-label' .col-sm-10 = f.select(:source_branch, [@merge_request.source_branch], { }, { class: 'source_branch select2 span2', disabled: true }) .form-group - = f.label :target_branch, class: 'control-label' + = f.label :target_branch, '目标分支', class: 'control-label' .col-sm-10 - = f.select(:target_branch, @merge_request.target_branches, { include_blank: true }, { class: 'target_branch select2 span2', disabled: @merge_request.new_record?, data: {placeholder: "Select branch"} }) + = f.select(:target_branch, @merge_request.target_branches, { include_blank: true }, { class: 'target_branch select2 span2', disabled: @merge_request.new_record?, data: {placeholder: "选择分支"} }) - if @merge_request.new_record? %p.help-block - = link_to 'Change branches', mr_change_branches_path(@merge_request) + = link_to '修改分支', mr_change_branches_path(@merge_request) - is_footer = !(issuable.is_a?(MergeRequest) && issuable.new_record?) .gray-content-block{class: (is_footer ? "footer-block" : "middle-block")} - if issuable.new_record? - = f.submit "Submit #{issuable.class.model_name.human.downcase}", class: 'btn btn-create' + = f.submit "提交新的#{issuable.zh_name}", class: 'btn btn-create' - else - = f.submit 'Save changes', class: 'btn btn-save' + = f.submit '保存修改', class: 'btn btn-save' - if !issuable.persisted? && !issuable.project.empty_repo? && (guide_url = contribution_guide_path(issuable.project)) .inline.prepend-left-10 - Please review the - %strong #{link_to 'contribution guidelines', guide_url} - for this project. + 请先阅读此项目的 + %strong #{link_to '贡献指导原则', guide_url} + 。 - if issuable.new_record? - = link_to 'Cancel', namespace_project_issues_path(@project.namespace, @project), class: 'btn btn-cancel' + = link_to '取消', namespace_project_issues_path(@project.namespace, @project), class: 'btn btn-cancel' - else .pull-right - if current_user.can?(:"destroy_#{issuable.to_ability_name}", @project) = link_to polymorphic_path([@project.namespace.becomes(Namespace), @project, issuable]), method: :delete, class: 'btn btn-grouped' do = icon('trash-o') - Delete - = link_to 'Cancel', namespace_project_issue_path(@project.namespace, @project, issuable), class: 'btn btn-grouped btn-cancel' + 删除 + = link_to '取消', namespace_project_issue_path(@project.namespace, @project, issuable), class: 'btn btn-grouped btn-cancel' diff --git a/app/views/shared/issuable/_label_dropdown.html.haml b/app/views/shared/issuable/_label_dropdown.html.haml index 87617315181..ddd870ffbd4 100644 --- a/app/views/shared/issuable/_label_dropdown.html.haml +++ b/app/views/shared/issuable/_label_dropdown.html.haml @@ -1,14 +1,14 @@ - if params[:label_name] = hidden_field_tag(:label_name, params[:label_name]) .dropdown - %button.dropdown-menu-toggle.js-label-select.js-filter-submit{type: "button", data: {toggle: "dropdown", field_name: "label_name", show_no: "true", show_any: "true", selected: params[:label_name], project_id: @project.try(:id), labels: labels_filter_path, default_label: "Label"}} + %button.dropdown-menu-toggle.js-label-select.js-filter-submit{type: "button", data: {toggle: "dropdown", field_name: "label_name", show_no: "true", show_any: "true", selected: params[:label_name], project_id: @project.try(:id), labels: labels_filter_path, default_label: "标记"}} %span.dropdown-toggle-text - = h(params[:label_name].presence || "Label") + = h(params[:label_name].presence || "标记") = icon('chevron-down') .dropdown-menu.dropdown-select.dropdown-menu-paging.dropdown-menu-labels.dropdown-menu-selectable .dropdown-page-one - = dropdown_title("Filter by label") - = dropdown_filter("Search labels") + = dropdown_title("按标记过滤") + = dropdown_filter("搜索标记") = dropdown_content - if @project = dropdown_footer do @@ -16,24 +16,24 @@ - if can? current_user, :admin_label, @project %li %a.dropdown-toggle-page{href: "#"} - Create new + 创建新的 %li = link_to namespace_project_labels_path(@project.namespace, @project) do - if can? current_user, :admin_label, @project - Manage labels + 管理标记 - else - View labels + 查看标记 - if can? current_user, :admin_label, @project and @project .dropdown-page-two - = dropdown_title("Create new label", back: true) + = dropdown_title("创建新的标记", back: true) = dropdown_content do %input#new_label_color{type: "hidden"} - %input#new_label_name.dropdown-input-field{type: "text", placeholder: "Name new label"} + %input#new_label_name.dropdown-input-field{type: "text", placeholder: "新标记名称"} .dropdown-label-color-preview.js-dropdown-label-color-preview .suggest-colors.suggest-colors-dropdown - suggested_colors.each do |color| = link_to '#', style: "background-color: #{color}", data: { color: color } do   %button.btn.btn-primary.js-new-label-btn{type: "button"} - Create + 创建 = dropdown_loading diff --git a/app/views/shared/issuable/_milestone_dropdown.html.haml b/app/views/shared/issuable/_milestone_dropdown.html.haml index 0434506c8d7..37b25ea5b9e 100644 --- a/app/views/shared/issuable/_milestone_dropdown.html.haml +++ b/app/views/shared/issuable/_milestone_dropdown.html.haml @@ -1,16 +1,16 @@ - if params[:milestone_title] = hidden_field_tag(:milestone_title, params[:milestone_title]) -= dropdown_tag(h(params[:milestone_title].presence || "Milestone"), options: { title: "Filter by milestone", toggle_class: 'js-milestone-select js-filter-submit', filter: true, dropdown_class: "dropdown-menu-selectable", - placeholder: "Search milestones", footer_content: @project.present?, data: { show_no: true, show_any: true, field_name: "milestone_title", selected: params[:milestone_title], project_id: @project.try(:id), milestones: milestones_filter_dropdown_path, default_label: "Milestone" } }) do += dropdown_tag(h(params[:milestone_title].presence || "里程碑"), options: { title: "按里程碑过滤", toggle_class: 'js-milestone-select js-filter-submit', filter: true, dropdown_class: "dropdown-menu-selectable", + placeholder: "搜索里程碑", footer_content: @project.present?, data: { show_no: true, show_any: true, field_name: "milestone_title", selected: params[:milestone_title], project_id: @project.try(:id), milestones: milestones_filter_dropdown_path, default_label: "里程碑" } }) do - if @project %ul.dropdown-footer-list - if can? current_user, :admin_milestone, @project %li - = link_to new_namespace_project_milestone_path(@project.namespace, @project), title: "New Milestone" do - Create new + = link_to new_namespace_project_milestone_path(@project.namespace, @project), title: "新里程碑" do + 创建新的 %li = link_to namespace_project_milestones_path(@project.namespace, @project) do - if can? current_user, :admin_milestone, @project - Manage milestones + 管理里程碑 - else - View milestones + 查看里程碑 diff --git a/app/views/shared/issuable/_participants.html.haml b/app/views/shared/issuable/_participants.html.haml index 3fb409ff727..d29b7487ada 100644 --- a/app/views/shared/issuable/_participants.html.haml +++ b/app/views/shared/issuable/_participants.html.haml @@ -7,14 +7,14 @@ %span = participants.count .title.hide-collapsed - = pluralize participants.count, "participant" + = pluralize participants.count, "个参与者", "个参与者" .hide-collapsed.participants-list - participants.each do |participant| .participants-author.js-participants-author = link_to_member(@project, participant, name: false, size: 24) - if participants_extra > 0 %div.participants-more - %a.js-participants-more{href: "#", data: {original_text: "+ #{participants_size - 7} more", less_text: "- show less"}} - + #{participants_extra} more + %a.js-participants-more{href: "#", data: {original_text: "+ #{participants_size - 7} 更多", less_text: "- 显示更少"}} + + #{participants_extra} 更多 :javascript Issue.prototype.PARTICIPANTS_ROW_COUNT = #{participants_row}; diff --git a/app/views/shared/issuable/_sidebar.html.haml b/app/views/shared/issuable/_sidebar.html.haml index fd8952ae4f4..0d472548686 100644 --- a/app/views/shared/issuable/_sidebar.html.haml +++ b/app/views/shared/issuable/_sidebar.html.haml @@ -3,21 +3,21 @@ .block.issuable-sidebar-header %span.issuable-count.hide-collapsed.pull-left = issuable.iid - of + \/ = issuables_count(issuable) %a.gutter-toggle.pull-right.js-sidebar-toggle{href: '#'} = sidebar_gutter_toggle_icon .issuable-nav.hide-collapsed.pull-right.btn-group{role: 'group', "aria-label" => '...'} - if prev_issuable = prev_issuable_for(issuable) - = link_to 'Prev', [@project.namespace.becomes(Namespace), @project, prev_issuable], class: 'btn btn-default prev-btn' + = link_to '上一个', [@project.namespace.becomes(Namespace), @project, prev_issuable], class: 'btn btn-default prev-btn' - else %a.btn.btn-default.disabled{href: '#'} - Prev + 上一个 - if next_issuable = next_issuable_for(issuable) - = link_to 'Next', [@project.namespace.becomes(Namespace), @project, next_issuable], class: 'btn btn-default next-btn' + = link_to '下一个', [@project.namespace.becomes(Namespace), @project, next_issuable], class: 'btn btn-default next-btn' - else %a.btn.btn-default.disabled{href: '#'} - Next + 下一个 = form_for [@project.namespace.becomes(Namespace), @project, issuable], remote: true, html: {class: 'issuable-context-form inline-update js-issuable-update'} do |f| .block.assignee @@ -27,22 +27,22 @@ - else = icon('user') .title.hide-collapsed - Assignee + 指派 - if can?(current_user, :"admin_#{issuable.to_ability_name}", @project) - = link_to 'Edit', '#', class: 'edit-link pull-right' + = link_to '编辑', '#', class: 'edit-link pull-right' .value.bold.hide-collapsed - if issuable.assignee = link_to_member(@project, issuable.assignee, size: 32) do %span.username = issuable.assignee.to_reference - if issuable.instance_of?(MergeRequest) && !issuable.can_be_merged_by?(issuable.assignee) - %a.pull-right.cannot-be-merged{href: '#', data: {toggle: 'tooltip'}, title: 'Not allowed to merge'} + %a.pull-right.cannot-be-merged{href: '#', data: {toggle: 'tooltip'}, title: '不允许合并'} = icon('exclamation-triangle') - else - .light None + .light 无 .selectbox.hide-collapsed - = users_select_tag("#{issuable.class.table_name.singularize}[assignee_id]", placeholder: 'Select assignee', class: 'custom-form-control js-select2 js-assignee', selected: issuable.assignee_id, project: @target_project, null_user: true, current_user: true, first_user: true) + = users_select_tag("#{issuable.class.table_name.singularize}[assignee_id]", placeholder: '选择指派', class: 'custom-form-control js-select2 js-assignee', selected: issuable.assignee_id, project: @target_project, null_user: true, current_user: true, first_user: true) .block.milestone .sidebar-collapsed-icon @@ -51,19 +51,19 @@ - if issuable.milestone = issuable.milestone.title - else - No + 否 .title.hide-collapsed - Milestone + 里程碑 - if can?(current_user, :"admin_#{issuable.to_ability_name}", @project) - = link_to 'Edit', '#', class: 'edit-link pull-right' + = link_to '编辑', '#', class: 'edit-link pull-right' .value.bold.hide-collapsed - if issuable.milestone = link_to namespace_project_milestone_path(@project.namespace, @project, issuable.milestone) do = issuable.milestone.title - else - .light None + .light 无 .selectbox.hide-collapsed - = f.select(:milestone_id, milestone_options(issuable), { include_blank: true }, { class: 'select2 select2-compact js-select2 js-milestone', data: { placeholder: 'Select milestone' }}) + = f.select(:milestone_id, milestone_options(issuable), { include_blank: true }, { class: 'select2 select2-compact js-select2 js-milestone', data: { placeholder: '选择里程碑' }}) = hidden_field_tag :issuable_context = f.submit class: 'btn hide' @@ -74,18 +74,18 @@ %span = issuable.labels.count .title.hide-collapsed - Labels + 标记 - if can?(current_user, :"admin_#{issuable.to_ability_name}", @project) - = link_to 'Edit', '#', class: 'edit-link pull-right' + = link_to '编辑', '#', class: 'edit-link pull-right' .value.issuable-show-labels.hide-collapsed{class: ("has-labels" if issuable.labels.any?)} - if issuable.labels.any? - issuable.labels.each do |label| = link_to_label(label, type: issuable.to_ability_name) - else - .light None + .light 无 .selectbox.hide-collapsed = f.collection_select :label_ids, issuable.project.labels.all, :id, :name, - { selected: issuable.label_ids }, multiple: true, class: 'select2 js-select2', data: { placeholder: "Select labels" } + { selected: issuable.label_ids }, multiple: true, class: 'select2 js-select2', data: { placeholder: "选择标记" } = render "shared/issuable/participants", participants: issuable.participants(current_user) - if current_user @@ -94,15 +94,15 @@ .sidebar-collapsed-icon = icon('rss') .title.hide-collapsed - Notifications + 通知 - subscribtion_status = subscribed ? 'subscribed' : 'unsubscribed' %button.btn.btn-block.btn-gray.subscribe-button.hide-collapsed{:type => 'button'} - %span= subscribed ? 'Unsubscribe' : 'Subscribe' + %span= subscribed ? '取消订阅' : '订阅' .subscription-status.hide-collapsed{data: {status: subscribtion_status}} .unsubscribed{class: ( 'hidden' if subscribed )} - You're not receiving notifications from this thread. + 你将不会再收到此主题的通知。 .subscribed{class: ( 'hidden' unless subscribed )} - You're receiving notifications because you're subscribed to this thread. + 因为你订阅了本主题,将会收到相关通知。 - project_ref = cross_project_reference(@project, issuable) .block.project-reference diff --git a/app/views/shared/milestones/_issuable.html.haml b/app/views/shared/milestones/_issuable.html.haml index 85888096722..b896a461851 100644 --- a/app/views/shared/milestones/_issuable.html.haml +++ b/app/views/shared/milestones/_issuable.html.haml @@ -23,5 +23,5 @@ - if assignee = link_to polymorphic_path(base_url_args, { milestone_title: @milestone.title, assignee_id: issuable.assignee_id, state: 'all' }), - class: 'has_tooltip', data: { 'original-title' => "Assigned to #{sanitize(assignee.name)}", container: 'body' } do + class: 'has_tooltip', data: { 'original-title' => "指派给 #{sanitize(assignee.name)}", container: 'body' } do - image_tag(avatar_icon(issuable.assignee, 16), class: "avatar s16", alt: '') diff --git a/app/views/shared/milestones/_issues_tab.html.haml b/app/views/shared/milestones/_issues_tab.html.haml index a8db7f8a556..5af0ca160d3 100644 --- a/app/views/shared/milestones/_issues_tab.html.haml +++ b/app/views/shared/milestones/_issues_tab.html.haml @@ -3,8 +3,8 @@ .row.prepend-top-default .col-md-4 - = render 'shared/milestones/issuables', args.merge(title: 'Unstarted Issues (open and unassigned)', issuables: issues.opened.unassigned, id: 'unassigned', show_counter: true) + = render 'shared/milestones/issuables', args.merge(title: '未开始的问题 (未关闭 & 未指派)', issuables: issues.opened.unassigned, id: 'unassigned', show_counter: true) .col-md-4 - = render 'shared/milestones/issuables', args.merge(title: 'Ongoing Issues (open and assigned)', issuables: issues.opened.assigned, id: 'ongoing', show_counter: true) + = render 'shared/milestones/issuables', args.merge(title: '正在进行的问题 (未关闭 & 已指派)', issuables: issues.opened.assigned, id: 'ongoing', show_counter: true) .col-md-4 - = render 'shared/milestones/issuables', args.merge(title: 'Completed Issues (closed)', issuables: issues.closed, id: 'closed', show_counter: true) + = render 'shared/milestones/issuables', args.merge(title: '完成的问题 (已关闭)', issuables: issues.closed, id: 'closed', show_counter: true) diff --git a/app/views/shared/milestones/_labels_tab.html.haml b/app/views/shared/milestones/_labels_tab.html.haml index 868b2357003..1e3d60872a6 100644 --- a/app/views/shared/milestones/_labels_tab.html.haml +++ b/app/views/shared/milestones/_labels_tab.html.haml @@ -12,7 +12,7 @@ .pull-right %strong.issues-count = link_to milestones_label_path(options.merge(state: 'opened')) do - - pluralize milestone_issues_by_label_count(@milestone, label, state: :opened), 'open issue' + - pluralize milestone_issues_by_label_count(@milestone, label, state: :opened), '个未关闭问题', '个未关闭问题' %strong.issues-count = link_to milestones_label_path(options.merge(state: 'closed')) do - - pluralize milestone_issues_by_label_count(@milestone, label, state: :closed), 'closed issue' + - pluralize milestone_issues_by_label_count(@milestone, label, state: :closed), '个已关闭问题', '个已关闭问题' diff --git a/app/views/shared/milestones/_merge_requests_tab.haml b/app/views/shared/milestones/_merge_requests_tab.haml index c29d8ee6737..e6c4c79ab1e 100644 --- a/app/views/shared/milestones/_merge_requests_tab.haml +++ b/app/views/shared/milestones/_merge_requests_tab.haml @@ -3,10 +3,10 @@ .row.prepend-top-default .col-md-3 - = render 'shared/milestones/issuables', args.merge(title: 'Work in progress (open and unassigned)', issuables: merge_requests.opened.unassigned, id: 'unassigned') + = render 'shared/milestones/issuables', args.merge(title: '正在处理的 (未关闭 & 未指派)', issuables: merge_requests.opened.unassigned, id: 'unassigned') .col-md-3 - = render 'shared/milestones/issuables', args.merge(title: 'Waiting for merge (open and assigned)', issuables: merge_requests.opened.assigned, id: 'ongoing') + = render 'shared/milestones/issuables', args.merge(title: '等待合并 (未关闭 & 已指派)', issuables: merge_requests.opened.assigned, id: 'ongoing') .col-md-3 - = render 'shared/milestones/issuables', args.merge(title: 'Rejected (closed)', issuables: merge_requests.closed, id: 'closed') + = render 'shared/milestones/issuables', args.merge(title: '拒绝 (已关闭)', issuables: merge_requests.closed, id: 'closed') .col-md-3 - = render 'shared/milestones/issuables', args.merge(title: 'Merged', issuables: merge_requests.merged, id: 'merged', primary: true) + = render 'shared/milestones/issuables', args.merge(title: '已合并', issuables: merge_requests.merged, id: 'merged', primary: true) diff --git a/app/views/shared/milestones/_milestone.html.haml b/app/views/shared/milestones/_milestone.html.haml index 6b25745c554..2ad80a905b0 100644 --- a/app/views/shared/milestones/_milestone.html.haml +++ b/app/views/shared/milestones/_milestone.html.haml @@ -6,12 +6,12 @@ .col-sm-6 %strong= link_to_gfm truncate(milestone.title, length: 100), milestone_path .col-sm-6 - .pull-right.light #{milestone.percent_complete(current_user)}% complete + .pull-right.light #{milestone.percent_complete(current_user)}% 完成 .row .col-sm-6 - = link_to pluralize(milestone.issues_visible_to_user(current_user).size, 'Issue'), issues_path + = link_to pluralize(milestone.issues_visible_to_user(current_user).size, '个问题', '个问题'), issues_path · - = link_to pluralize(milestone.merge_requests.size, 'Merge Request'), merge_requests_path + = link_to pluralize(milestone.merge_requests.size, '个合并请求', '个合并请求'), merge_requests_path .col-sm-6= milestone_progress_bar(milestone) - if milestone.is_a?(GlobalMilestone) .row @@ -26,9 +26,9 @@ .col-sm-6 - if can?(current_user, :admin_milestones, @group) - if milestone.closed? - = link_to 'Reopen Milestone', group_milestone_path(@group, milestone.safe_title, title: milestone.title, milestone: {state_event: :activate }), method: :put, class: "btn btn-xs btn-grouped btn-reopen" + = link_to '重新打开里程碑', group_milestone_path(@group, milestone.safe_title, title: milestone.title, milestone: {state_event: :activate }), method: :put, class: "btn btn-xs btn-grouped btn-reopen" - else - = link_to 'Close Milestone', group_milestone_path(@group, milestone.safe_title, title: milestone.title, milestone: {state_event: :close }), method: :put, class: "btn btn-xs btn-close" + = link_to '关闭里程碑', group_milestone_path(@group, milestone.safe_title, title: milestone.title, milestone: {state_event: :close }), method: :put, class: "btn btn-xs btn-close" - if @project .row @@ -37,9 +37,9 @@ - if can?(current_user, :admin_milestone, milestone.project) and milestone.active? = link_to edit_namespace_project_milestone_path(milestone.project.namespace, milestone.project, milestone), class: "btn btn-xs" do = icon('pencil-square-o') - Edit + 编辑 \ = link_to 'Close Milestone', namespace_project_milestone_path(@project.namespace, @project, milestone, milestone: {state_event: :close }), method: :put, remote: true, class: "btn btn-xs btn-close" - = link_to namespace_project_milestone_path(milestone.project.namespace, milestone.project, milestone), data: { confirm: 'Are you sure?' }, method: :delete, class: "btn btn-xs btn-remove" do + = link_to namespace_project_milestone_path(milestone.project.namespace, milestone.project, milestone), data: { confirm: '确定要继续么?' }, method: :delete, class: "btn btn-xs btn-remove" do = icon('trash-o') - Delete + 删除 diff --git a/app/views/shared/milestones/_summary.html.haml b/app/views/shared/milestones/_summary.html.haml index 385c6596606..e89e247a2a4 100644 --- a/app/views/shared/milestones/_summary.html.haml +++ b/app/views/shared/milestones/_summary.html.haml @@ -2,27 +2,27 @@ .context.prepend-top-default .milestone-summary - %h4 Progress + %h4 进度 %strong= milestone.issues_visible_to_user(current_user).size - issues: + 问题: %span.milestone-stat %strong= milestone.issues_visible_to_user(current_user).opened.size - open and + 个未关闭和 %strong= milestone.issues_visible_to_user(current_user).closed.size - closed + 个已关闭 %span.milestone-stat %strong== #{milestone.percent_complete(current_user)}% - complete + 完成 %span.milestone-stat %span.remaining-days= milestone_remaining_days(milestone) %span.pull-right.tab-issues-buttons - if project && can?(current_user, :create_issue, project) - = link_to new_namespace_project_issue_path(project.namespace, project, issue: { milestone_id: milestone.id }), class: "btn btn-grouped", title: "New Issue" do + = link_to new_namespace_project_issue_path(project.namespace, project, issue: { milestone_id: milestone.id }), class: "btn btn-grouped", title: "新问题" do %i.fa.fa-plus - New Issue - = link_to 'Browse Issues', milestones_browse_issuables_path(milestone, type: :issues), class: "btn btn-grouped" + 新问题 + = link_to '浏览问题', milestones_browse_issuables_path(milestone, type: :issues), class: "btn btn-grouped" %span.pull-right.tab-merge-requests-buttons.hidden - = link_to 'Browse Merge Requests', milestones_browse_issuables_path(milestone, type: :merge_requests), class: "btn btn-grouped" + = link_to '浏览合并请求', milestones_browse_issuables_path(milestone, type: :merge_requests), class: "btn btn-grouped" = milestone_progress_bar(milestone) diff --git a/app/views/shared/milestones/_tabs.html.haml b/app/views/shared/milestones/_tabs.html.haml index 2b6ce2d7e7a..3a0ac8846b3 100644 --- a/app/views/shared/milestones/_tabs.html.haml +++ b/app/views/shared/milestones/_tabs.html.haml @@ -1,19 +1,19 @@ %ul.nav-links.no-top.no-bottom %li.active = link_to '#tab-issues', 'data-toggle' => 'tab', 'data-show' => '.tab-issues-buttons' do - Issues + 问题 %span.badge= milestone.issues_visible_to_user(current_user).size %li = link_to '#tab-merge-requests', 'data-toggle' => 'tab', 'data-show' => '.tab-merge-requests-buttons' do - Merge Requests + 合并请求 %span.badge= milestone.merge_requests.size %li = link_to '#tab-participants', 'data-toggle' => 'tab' do - Participants + 参与者 %span.badge= milestone.participants.count %li = link_to '#tab-labels', 'data-toggle' => 'tab' do - Labels + 标记 %span.badge= milestone.labels.count - show_project_name = local_assigns.fetch(:show_project_name, false) diff --git a/app/views/shared/milestones/_top.html.haml b/app/views/shared/milestones/_top.html.haml index cab8743a077..fe3e8719806 100644 --- a/app/views/shared/milestones/_top.html.haml +++ b/app/views/shared/milestones/_top.html.haml @@ -1,17 +1,17 @@ -- page_title milestone.title, "Milestones" +- page_title milestone.title, "里程碑" - group = local_assigns[:group] .detail-page-header .status-box{ class: "status-box-#{milestone.closed? ? 'closed' : 'open'}" } - if milestone.closed? - Closed + 已关闭 - elsif milestone.expired? - Expired + 已过期 - else - Open + 未关闭 %span.identifier - Milestone #{milestone.title} + 里程碑 #{milestone.title} - if milestone.expires_at %span.creator · @@ -20,9 +20,9 @@ .pull-right - if can?(current_user, :admin_milestones, group) - if milestone.active? - = link_to 'Close Milestone', group_milestone_path(group, milestone.safe_title, title: milestone.title, milestone: {state_event: :close }), method: :put, class: "btn btn-grouped btn-close" + = link_to '关闭里程碑', group_milestone_path(group, milestone.safe_title, title: milestone.title, milestone: {state_event: :close }), method: :put, class: "btn btn-grouped btn-close" - else - = link_to 'Reopen Milestone', group_milestone_path(group, milestone.safe_title, title: milestone.title, milestone: {state_event: :activate }), method: :put, class: "btn btn-grouped btn-reopen" + = link_to '重新打开里程碑', group_milestone_path(group, milestone.safe_title, title: milestone.title, milestone: {state_event: :activate }), method: :put, class: "btn btn-grouped btn-reopen" .detail-page-description.gray-content-block.second-block %h2.title @@ -30,17 +30,17 @@ - if milestone.complete?(current_user) && milestone.active? .alert.alert-success.prepend-top-default - - close_msg = group ? 'You may close the milestone now.' : 'Navigate to the project to close the milestone.' - %span All issues for this milestone are closed. #{close_msg} + - close_msg = group ? '可以关闭此里程碑。' : '导航到此项目去关闭此里程碑。' + %span 该里程碑的全部问题都已关闭。#{close_msg} .table-holder %table.table %thead %tr - %th Project - %th Open issues - %th State - %th Due date + %th 项目 + %th 未关闭问题 + %th 状态 + %th 到期日 - milestone.milestones.each do |ms| %tr %td @@ -50,9 +50,9 @@ = ms.issues_visible_to_user(current_user).opened.count %td - if ms.closed? - Closed + 已关闭 - else - Open + 未关闭 %td = ms.expires_at diff --git a/app/views/shared/projects/_dropdown.html.haml b/app/views/shared/projects/_dropdown.html.haml index e7e04621ff4..bed3988c533 100644 --- a/app/views/shared/projects/_dropdown.html.haml +++ b/app/views/shared/projects/_dropdown.html.haml @@ -7,7 +7,7 @@ %b.caret %ul.dropdown-menu.dropdown-menu-align-right.dropdown-menu-selectable %li.dropdown-header - Sort by + 排序: - projects_sort_options_hash.each do |value, title| %li = link_to filter_projects_path(sort: value, archived: archived), class: ("is-active" if @sort == value) do @@ -16,7 +16,7 @@ %li.divider %li = link_to filter_projects_path(sort: @sort, archived: nil), class: ("is-active" unless params[:archived].present?) do - Hide archived projects + 隐藏归档的项目 %li = link_to filter_projects_path(sort: @sort, archived: true), class: ("is-active" if params[:archived].present?) do - Show archived projects + 显示归档的项目 diff --git a/app/views/shared/projects/_list.html.haml b/app/views/shared/projects/_list.html.haml index 2e08bb2ac08..7024db45f80 100644 --- a/app/views/shared/projects/_list.html.haml +++ b/app/views/shared/projects/_list.html.haml @@ -18,7 +18,7 @@ forks: forks, show_last_commit_as_description: show_last_commit_as_description = paginate(projects, remote: remote, theme: "gitlab") if projects.respond_to? :total_pages - else - .nothing-here-block No projects found + .nothing-here-block 没有项目 :javascript ProjectsList.init(); diff --git a/app/views/shared/snippets/_header.html.haml b/app/views/shared/snippets/_header.html.haml index b17e6dbf3fc..5a45599a5b1 100644 --- a/app/views/shared/snippets/_header.html.haml +++ b/app/views/shared/snippets/_header.html.haml @@ -11,7 +11,7 @@ - if @snippet.updated_at != @snippet.created_at %span · - = icon('edit', title: 'edited') + = icon('edit', title: '编辑时间') = time_ago_with_tooltip(@snippet.updated_at, placement: 'bottom', html_class: 'snippet_edited_ago') .pull-right diff --git a/app/views/shared/snippets/_snippet.html.haml b/app/views/shared/snippets/_snippet.html.haml index a316a085107..c38c964d97a 100644 --- a/app/views/shared/snippets/_snippet.html.haml +++ b/app/views/shared/snippets/_snippet.html.haml @@ -7,7 +7,7 @@ - if snippet.private? %span.label.label-gray = icon('lock') - private + 私有 %span.monospace.pull-right = snippet.file_name @@ -18,4 +18,4 @@ .snippet-info = link_to user_snippets_path(snippet.author) do = snippet.author_name - authored #{time_ago_with_tooltip(snippet.created_at)} + 编辑于 #{time_ago_with_tooltip(snippet.created_at)} diff --git a/app/views/users/show.html.haml b/app/views/users/show.html.haml index df6486a1371..185303cd6f2 100644 --- a/app/views/users/show.html.haml +++ b/app/views/users/show.html.haml @@ -17,12 +17,12 @@ - elsif current_user %span.report-abuse - if @user.abuse_report - %button.btn.btn-danger{ title: 'Already reported for abuse', + %button.btn.btn-danger{ title: '已被举报', data: { toggle: 'tooltip', placement: 'left', container: 'body' }} = icon('exclamation-circle') - else = link_to new_abuse_report_path(user_id: @user.id, ref_url: request.referrer), class: 'btn btn-gray', - title: 'Report abuse', data: {toggle: 'tooltip', placement: 'left', container: 'body'} do + title: '举报滥用', data: {toggle: 'tooltip', placement: 'left', container: 'body'} do = icon('exclamation-circle') - if current_user @@ -39,7 +39,7 @@ %span.middle-dot-divider @#{@user.username} %span.middle-dot-divider - Member since #{@user.created_at.to_s(:medium)} + 注册时间:#{@user.created_at.to_s(:medium)} - if @user.bio.present? .cover-desc @@ -56,11 +56,11 @@ = icon('skype') - unless @user.linkedin.blank? .profile-link-holder.middle-dot-divider - = link_to "https://www.linkedin.com/in/#{@user.linkedin}", title: "LinkedIn" do + = link_to "https://www.linkedin.com/in/#{@user.linkedin}", title: "领英" do = icon('linkedin-square') - unless @user.twitter.blank? .profile-link-holder.middle-dot-divider - = link_to "https://twitter.com/#{@user.twitter}", title: "Twitter" do + = link_to "https://twitter.com/#{@user.twitter}", title: "推特" do = icon('twitter-square') - unless @user.website_url.blank? .profile-link-holder.middle-dot-divider @@ -73,16 +73,16 @@ %ul.nav-links.center.user-profile-nav %li.activity-tab = link_to user_calendar_activities_path, data: {target: 'div#activity', action: 'activity', toggle: 'tab'} do - Activity + 活动 %li.groups-tab = link_to user_groups_path, data: {target: 'div#groups', action: 'groups', toggle: 'tab'} do - Groups + 群组 %li.contributed-tab = link_to user_contributed_projects_path, data: {target: 'div#contributed', action: 'contributed', toggle: 'tab'} do - Contributed projects + 贡献项目 %li.projects-tab = link_to user_projects_path, data: {target: 'div#projects', action: 'projects', toggle: 'tab'} do - Personal projects + 个人项目 %div{ class: container_class } .tab-content diff --git a/app/views/votes/_votes_block.html.haml b/app/views/votes/_votes_block.html.haml index 20d2d5f317b..109306f022b 100644 --- a/app/views/votes/_votes_block.html.haml +++ b/app/views/votes/_votes_block.html.haml @@ -11,7 +11,7 @@ = icon('smile-o', {class: "award-control-icon"}) = icon('spinner spin', {class: "award-control-icon award-control-icon-loading"}) %span.award-control-text - Add + 增加 - if current_user :javascript diff --git a/public/404.html b/public/404.html index 4862770cc2a..203d18d751e 100644 --- a/public/404.html +++ b/public/404.html @@ -1,7 +1,7 @@ <!DOCTYPE html> <html> <head> - <title>The page you're looking for could not be found (404)</title> + <title>页面不存在 (404)</title> <style> body { color: #666; @@ -47,9 +47,9 @@ <img src="data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iMjEwIiBoZWlnaHQ9IjIxMCIgdmlld0JveD0iMCAwIDIxMCAyMTAiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyI+CiAgPHBhdGggZD0iTTEwNS4wNjE0IDIwMy42NTVsMzguNjQtMTE4LjkyMWgtNzcuMjhsMzguNjQgMTE4LjkyMXoiIGZpbGw9IiNlMjQzMjkiLz4KICA8cGF0aCBkPSJNMTA1LjA2MTQgMjAzLjY1NDhsLTM4LjY0LTExOC45MjFoLTU0LjE1M2w5Mi43OTMgMTE4LjkyMXoiIGZpbGw9IiNmYzZkMjYiLz4KICA8cGF0aCBkPSJNMTIuMjY4NSA4NC43MzQxbC0xMS43NDIgMzYuMTM5Yy0xLjA3MSAzLjI5Ni4xMDIgNi45MDcgMi45MDYgOC45NDRsMTAxLjYyOSA3My44MzgtOTIuNzkzLTExOC45MjF6IiBmaWxsPSIjZmNhMzI2Ii8+CiAgPHBhdGggZD0iTTEyLjI2ODUgODQuNzM0Mmg1NC4xNTNsLTIzLjI3My03MS42MjVjLTEuMTk3LTMuNjg2LTYuNDExLTMuNjg1LTcuNjA4IDBsLTIzLjI3MiA3MS42MjV6IiBmaWxsPSIjZTI0MzI5Ii8+CiAgPHBhdGggZD0iTTEwNS4wNjE0IDIwMy42NTQ4bDM4LjY0LTExOC45MjFoNTQuMTUzbC05Mi43OTMgMTE4LjkyMXoiIGZpbGw9IiNmYzZkMjYiLz4KICA8cGF0aCBkPSJNMTk3Ljg1NDQgODQuNzM0MWwxMS43NDIgMzYuMTM5YzEuMDcxIDMuMjk2LS4xMDIgNi45MDctMi45MDYgOC45NDRsLTEwMS42MjkgNzMuODM4IDkyLjc5My0xMTguOTIxeiIgZmlsbD0iI2ZjYTMyNiIvPgogIDxwYXRoIGQ9Ik0xOTcuODU0NCA4NC43MzQyaC01NC4xNTNsMjMuMjczLTcxLjYyNWMxLjE5Ny0zLjY4NiA2LjQxMS0zLjY4NSA3LjYwOCAwbDIzLjI3MiA3MS42MjV6IiBmaWxsPSIjZTI0MzI5Ii8+Cjwvc3ZnPgo=" /><br /> 404 </h1> - <h3>The page you're looking for could not be found.</h3> + <h3>页面不存在。</h3> <hr/> - <p>Make sure the address is correct and that the page hasn't moved.</p> - <p>Please contact your GitLab administrator if you think this is a mistake.</p> + <p>请确认地址是否正确和页面是否被移动。</p> + <p>如果觉得有问题请联系 GitLab 管理员。</p> </body> </html> diff --git a/public/422.html b/public/422.html index 055b0bde165..e149b60681d 100644 --- a/public/422.html +++ b/public/422.html @@ -1,7 +1,7 @@ <!DOCTYPE html> <html> <head> - <title>The change you requested was rejected (422)</title> + <title>请求被拒绝 (422)</title> <style> body { color: #666; @@ -47,9 +47,9 @@ <img src="data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iMjEwIiBoZWlnaHQ9IjIxMCIgdmlld0JveD0iMCAwIDIxMCAyMTAiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyI+CiAgPHBhdGggZD0iTTEwNS4wNjE0IDIwMy42NTVsMzguNjQtMTE4LjkyMWgtNzcuMjhsMzguNjQgMTE4LjkyMXoiIGZpbGw9IiNlMjQzMjkiLz4KICA8cGF0aCBkPSJNMTA1LjA2MTQgMjAzLjY1NDhsLTM4LjY0LTExOC45MjFoLTU0LjE1M2w5Mi43OTMgMTE4LjkyMXoiIGZpbGw9IiNmYzZkMjYiLz4KICA8cGF0aCBkPSJNMTIuMjY4NSA4NC43MzQxbC0xMS43NDIgMzYuMTM5Yy0xLjA3MSAzLjI5Ni4xMDIgNi45MDcgMi45MDYgOC45NDRsMTAxLjYyOSA3My44MzgtOTIuNzkzLTExOC45MjF6IiBmaWxsPSIjZmNhMzI2Ii8+CiAgPHBhdGggZD0iTTEyLjI2ODUgODQuNzM0Mmg1NC4xNTNsLTIzLjI3My03MS42MjVjLTEuMTk3LTMuNjg2LTYuNDExLTMuNjg1LTcuNjA4IDBsLTIzLjI3MiA3MS42MjV6IiBmaWxsPSIjZTI0MzI5Ii8+CiAgPHBhdGggZD0iTTEwNS4wNjE0IDIwMy42NTQ4bDM4LjY0LTExOC45MjFoNTQuMTUzbC05Mi43OTMgMTE4LjkyMXoiIGZpbGw9IiNmYzZkMjYiLz4KICA8cGF0aCBkPSJNMTk3Ljg1NDQgODQuNzM0MWwxMS43NDIgMzYuMTM5YzEuMDcxIDMuMjk2LS4xMDIgNi45MDctMi45MDYgOC45NDRsLTEwMS42MjkgNzMuODM4IDkyLjc5My0xMTguOTIxeiIgZmlsbD0iI2ZjYTMyNiIvPgogIDxwYXRoIGQ9Ik0xOTcuODU0NCA4NC43MzQyaC01NC4xNTNsMjMuMjczLTcxLjYyNWMxLjE5Ny0zLjY4NiA2LjQxMS0zLjY4NSA3LjYwOCAwbDIzLjI3MiA3MS42MjV6IiBmaWxsPSIjZTI0MzI5Ii8+Cjwvc3ZnPgo=" /><br /> 422 </h1> - <h3>The change you requested was rejected.</h3> + <h3>请求被拒绝。</h3> <hr /> - <p>Make sure you have access to the thing you tried to change.</p> - <p>Please contact your GitLab administrator if you think this is a mistake.</p> + <p>请确认是否权限访问此页面。</p> + <p>如果觉得有问题请联系 GitLab 管理员。</p> </body> </html> diff --git a/public/500.html b/public/500.html index 3d59d1392f5..72416ca0c5e 100644 --- a/public/500.html +++ b/public/500.html @@ -1,7 +1,7 @@ <!DOCTYPE html> <html> <head> - <title>Something went wrong (500)</title> + <title>发生错误 (500)</title> <style> body { color: #666; @@ -46,9 +46,9 @@ <img src="data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iMjEwIiBoZWlnaHQ9IjIxMCIgdmlld0JveD0iMCAwIDIxMCAyMTAiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyI+CiAgPHBhdGggZD0iTTEwNS4wNjE0IDIwMy42NTVsMzguNjQtMTE4LjkyMWgtNzcuMjhsMzguNjQgMTE4LjkyMXoiIGZpbGw9IiNlMjQzMjkiLz4KICA8cGF0aCBkPSJNMTA1LjA2MTQgMjAzLjY1NDhsLTM4LjY0LTExOC45MjFoLTU0LjE1M2w5Mi43OTMgMTE4LjkyMXoiIGZpbGw9IiNmYzZkMjYiLz4KICA8cGF0aCBkPSJNMTIuMjY4NSA4NC43MzQxbC0xMS43NDIgMzYuMTM5Yy0xLjA3MSAzLjI5Ni4xMDIgNi45MDcgMi45MDYgOC45NDRsMTAxLjYyOSA3My44MzgtOTIuNzkzLTExOC45MjF6IiBmaWxsPSIjZmNhMzI2Ii8+CiAgPHBhdGggZD0iTTEyLjI2ODUgODQuNzM0Mmg1NC4xNTNsLTIzLjI3My03MS42MjVjLTEuMTk3LTMuNjg2LTYuNDExLTMuNjg1LTcuNjA4IDBsLTIzLjI3MiA3MS42MjV6IiBmaWxsPSIjZTI0MzI5Ii8+CiAgPHBhdGggZD0iTTEwNS4wNjE0IDIwMy42NTQ4bDM4LjY0LTExOC45MjFoNTQuMTUzbC05Mi43OTMgMTE4LjkyMXoiIGZpbGw9IiNmYzZkMjYiLz4KICA8cGF0aCBkPSJNMTk3Ljg1NDQgODQuNzM0MWwxMS43NDIgMzYuMTM5YzEuMDcxIDMuMjk2LS4xMDIgNi45MDctMi45MDYgOC45NDRsLTEwMS42MjkgNzMuODM4IDkyLjc5My0xMTguOTIxeiIgZmlsbD0iI2ZjYTMyNiIvPgogIDxwYXRoIGQ9Ik0xOTcuODU0NCA4NC43MzQyaC01NC4xNTNsMjMuMjczLTcxLjYyNWMxLjE5Ny0zLjY4NiA2LjQxMS0zLjY4NSA3LjYwOCAwbDIzLjI3MiA3MS42MjV6IiBmaWxsPSIjZTI0MzI5Ii8+Cjwvc3ZnPgo=" /><br /> 500 </h1> - <h3>Whoops, something went wrong on our end.</h3> + <h3>哇,因为我们的原因发生错误。</h3> <hr/> - <p>Try refreshing the page, or going back and attempting the action again.</p> - <p>Please contact your GitLab administrator if this problem persists.</p> + <p>请尝试刷新页面,或者回退到上一页面再操作。</p> + <p>如果此问题继续存在请联系 GitLab 管理员。</p> </body> </html> diff --git a/public/502.html b/public/502.html index 67dfd8a2743..1eb92873831 100644 --- a/public/502.html +++ b/public/502.html @@ -1,7 +1,7 @@ <!DOCTYPE html> <html> <head> - <title>GitLab is not responding (502)</title> + <title>GitLab 无响应 (502)</title> <style> body { color: #666; @@ -46,9 +46,9 @@ <img src="data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iMjEwIiBoZWlnaHQ9IjIxMCIgdmlld0JveD0iMCAwIDIxMCAyMTAiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyI+CiAgPHBhdGggZD0iTTEwNS4wNjE0IDIwMy42NTVsMzguNjQtMTE4LjkyMWgtNzcuMjhsMzguNjQgMTE4LjkyMXoiIGZpbGw9IiNlMjQzMjkiLz4KICA8cGF0aCBkPSJNMTA1LjA2MTQgMjAzLjY1NDhsLTM4LjY0LTExOC45MjFoLTU0LjE1M2w5Mi43OTMgMTE4LjkyMXoiIGZpbGw9IiNmYzZkMjYiLz4KICA8cGF0aCBkPSJNMTIuMjY4NSA4NC43MzQxbC0xMS43NDIgMzYuMTM5Yy0xLjA3MSAzLjI5Ni4xMDIgNi45MDcgMi45MDYgOC45NDRsMTAxLjYyOSA3My44MzgtOTIuNzkzLTExOC45MjF6IiBmaWxsPSIjZmNhMzI2Ii8+CiAgPHBhdGggZD0iTTEyLjI2ODUgODQuNzM0Mmg1NC4xNTNsLTIzLjI3My03MS42MjVjLTEuMTk3LTMuNjg2LTYuNDExLTMuNjg1LTcuNjA4IDBsLTIzLjI3MiA3MS42MjV6IiBmaWxsPSIjZTI0MzI5Ii8+CiAgPHBhdGggZD0iTTEwNS4wNjE0IDIwMy42NTQ4bDM4LjY0LTExOC45MjFoNTQuMTUzbC05Mi43OTMgMTE4LjkyMXoiIGZpbGw9IiNmYzZkMjYiLz4KICA8cGF0aCBkPSJNMTk3Ljg1NDQgODQuNzM0MWwxMS43NDIgMzYuMTM5YzEuMDcxIDMuMjk2LS4xMDIgNi45MDctMi45MDYgOC45NDRsLTEwMS42MjkgNzMuODM4IDkyLjc5My0xMTguOTIxeiIgZmlsbD0iI2ZjYTMyNiIvPgogIDxwYXRoIGQ9Ik0xOTcuODU0NCA4NC43MzQyaC01NC4xNTNsMjMuMjczLTcxLjYyNWMxLjE5Ny0zLjY4NiA2LjQxMS0zLjY4NSA3LjYwOCAwbDIzLjI3MiA3MS42MjV6IiBmaWxsPSIjZTI0MzI5Ii8+Cjwvc3ZnPgo=" /><br /> 502 </h1> - <h3>Whoops, GitLab is taking too much time to respond.</h3> + <h3>哇,GitLab 响应花费了太多时间。</h3> <hr/> - <p>Try refreshing the page, or going back and attempting the action again.</p> - <p>Please contact your GitLab administrator if this problem persists.</p> + <p>请尝试刷新页面,或者回退到上一页面再操作。</p> + <p>如果此问题继续存在请联系 GitLab 管理员。</p> </body> </html> diff --git a/public/deploy.html b/public/deploy.html index 48976dacf41..9485269f72b 100644 --- a/public/deploy.html +++ b/public/deploy.html @@ -1,7 +1,7 @@ <!DOCTYPE html> <html> <head> - <title>Deploy in progress</title> + <title>正在部署</title> <style> body { color: #666; @@ -45,10 +45,10 @@ <body> <h1> <img src="data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iMjEwIiBoZWlnaHQ9IjIxMCIgdmlld0JveD0iMCAwIDIxMCAyMTAiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyI+CiAgPHBhdGggZD0iTTEwNS4wNjE0IDIwMy42NTVsMzguNjQtMTE4LjkyMWgtNzcuMjhsMzguNjQgMTE4LjkyMXoiIGZpbGw9IiNlMjQzMjkiLz4KICA8cGF0aCBkPSJNMTA1LjA2MTQgMjAzLjY1NDhsLTM4LjY0LTExOC45MjFoLTU0LjE1M2w5Mi43OTMgMTE4LjkyMXoiIGZpbGw9IiNmYzZkMjYiLz4KICA8cGF0aCBkPSJNMTIuMjY4NSA4NC43MzQxbC0xMS43NDIgMzYuMTM5Yy0xLjA3MSAzLjI5Ni4xMDIgNi45MDcgMi45MDYgOC45NDRsMTAxLjYyOSA3My44MzgtOTIuNzkzLTExOC45MjF6IiBmaWxsPSIjZmNhMzI2Ii8+CiAgPHBhdGggZD0iTTEyLjI2ODUgODQuNzM0Mmg1NC4xNTNsLTIzLjI3My03MS42MjVjLTEuMTk3LTMuNjg2LTYuNDExLTMuNjg1LTcuNjA4IDBsLTIzLjI3MiA3MS42MjV6IiBmaWxsPSIjZTI0MzI5Ii8+CiAgPHBhdGggZD0iTTEwNS4wNjE0IDIwMy42NTQ4bDM4LjY0LTExOC45MjFoNTQuMTUzbC05Mi43OTMgMTE4LjkyMXoiIGZpbGw9IiNmYzZkMjYiLz4KICA8cGF0aCBkPSJNMTk3Ljg1NDQgODQuNzM0MWwxMS43NDIgMzYuMTM5YzEuMDcxIDMuMjk2LS4xMDIgNi45MDctMi45MDYgOC45NDRsLTEwMS42MjkgNzMuODM4IDkyLjc5My0xMTguOTIxeiIgZmlsbD0iI2ZjYTMyNiIvPgogIDxwYXRoIGQ9Ik0xOTcuODU0NCA4NC43MzQyaC01NC4xNTNsMjMuMjczLTcxLjYyNWMxLjE5Ny0zLjY4NiA2LjQxMS0zLjY4NSA3LjYwOCAwbDIzLjI3MiA3MS42MjV6IiBmaWxsPSIjZTI0MzI5Ii8+Cjwvc3ZnPgo=" /><br /> - Deploy in progress + 正在部署 </h1> - <h3>Please try again in a few minutes.</h3> + <h3>请等待片刻后重试。</h3> <hr/> - <p>Please contact your GitLab administrator if this problem persists.</p> + <p>如果此问题继续存在请联系 GitLab 管理员。</p> </body> </html> |