diff --git a/options/locale/locale_en-US.ini b/options/locale/locale_en-US.ini index 89459b56e..d6de2bbd8 100644 --- a/options/locale/locale_en-US.ini +++ b/options/locale/locale_en-US.ini @@ -386,6 +386,7 @@ target_branch_not_exist = Target branch does not exist. change_avatar = Change your avatar… join_on = Joined on repositories = Repositories +datasets = Datasets activity = Public Activity followers = Followers starred = Starred Repositories diff --git a/options/locale/locale_zh-CN.ini b/options/locale/locale_zh-CN.ini index adf459af9..9b6fab0e0 100644 --- a/options/locale/locale_zh-CN.ini +++ b/options/locale/locale_zh-CN.ini @@ -385,6 +385,7 @@ target_branch_not_exist=目标分支不存在。 change_avatar=修改头像 join_on=加入于 repositories=仓库列表 +datasets=数据集 activity=公开活动 followers=关注者 starred=已点赞 diff --git a/templates/datasets/dataset_list.tmpl b/templates/datasets/dataset_list.tmpl new file mode 100644 index 000000000..05ec5eaef --- /dev/null +++ b/templates/datasets/dataset_list.tmpl @@ -0,0 +1,41 @@ +
+ {{range .Repos}} +
+
+ {{if .RelAvatarLink}} + + {{end}} + + {{if or $.PageIsExplore $.PageIsProfileStarList }}{{if .Owner}}{{.Owner.Name}} / {{end}}{{end}}{{.Name}} + {{if .IsArchived}}{{end}} + + {{if .IsPrivate}} + {{svg "octicon-lock" 16}} + {{else if .IsFork}} + {{svg "octicon-repo-forked" 16}} + {{end}} +
+ {{if .PrimaryLanguage }} + {{ .PrimaryLanguage.Language }} + {{end}} + {{svg "octicon-flame" 16}} {{.NumStars}} +
+
+
+ {{if .DescriptionHTML}}

{{.DescriptionHTML}}

{{end}} + {{if .Topics }} +
+ {{range .Topics}} + {{if ne . "" }}
{{.}}
{{end}} + {{end}} +
+ {{end}} +

{{$.i18n.Tr "org.repo_updated"}} {{TimeSinceUnix .UpdatedUnix $.i18n.Lang}}

+
+
+ {{else}} +
+ {{$.i18n.Tr "explore.repo_no_results"}} +
+ {{end}} +
diff --git a/templates/datasets/index.tmpl b/templates/datasets/index.tmpl index 5bad0c325..168f221d3 100644 --- a/templates/datasets/index.tmpl +++ b/templates/datasets/index.tmpl @@ -1,3 +1,3 @@ {{template "base/head" .}} -index.tmpl + {{template "datasets/dataset_list" .}} {{template "base/footer" .}} \ No newline at end of file diff --git a/templates/user/profile.tmpl b/templates/user/profile.tmpl index f3cac7bef..364bd63fe 100644 --- a/templates/user/profile.tmpl +++ b/templates/user/profile.tmpl @@ -83,9 +83,12 @@