Skip to content

Commit

Permalink
Merge pull request #9 from muze-nl/feature/archived-repos
Browse files Browse the repository at this point in the history
Add visual cue for archived repositories.
  • Loading branch information
Potherca authored Aug 27, 2024
2 parents 546fd64 + abc8bb3 commit ddf1d58
Show file tree
Hide file tree
Showing 4 changed files with 31 additions and 2 deletions.
8 changes: 8 additions & 0 deletions components/org-repos/componentCss/repo.css
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,14 @@ ol.repos .repo {
margin-bottom: 10px;
}

ol.repos .repo[data-archived] {
opacity: 0.5;
}

ol.repos .repo[data-archived] h3:after {
content: "(archived)";
}

ol.repos .repo .members:not(.simply-empty) {
background-color: white;
padding: 10px;
Expand Down
6 changes: 5 additions & 1 deletion components/org-repos/componentTemplates/org-repos.html
Original file line number Diff line number Diff line change
@@ -1,6 +1,10 @@
<ol class="repos" data-simply-list="orgRepos">
<template>
<li class="repo">
<li class="repo"
data-simply-field="archived"
data-simply-content="attributes"
data-simply-attributes="data-archived"
>
<h3 data-simply-field="name"></h3>
<div class="teams" data-simply-list="teams">
<template>
Expand Down
5 changes: 5 additions & 0 deletions components/org-repos/componentTemplates/org-repos.json
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,11 @@
{"login" : "user", "role_name": "admin"},
{"login" : "user", "role_name": "admin"}
]
},
{
"archived" : true,
"name" : "Archived Repo",
"teams" : [{"team" : "foo"}, {"team" : "bar"}]
}
]
}
14 changes: 13 additions & 1 deletion generated.html
Original file line number Diff line number Diff line change
Expand Up @@ -79,6 +79,14 @@
margin-bottom: 10px;
}

ol.repos .repo[data-archived] {
opacity: 0.5;
}

ol.repos .repo[data-archived] h3:after {
content: "(archived)";
}

ol.repos .repo .members:not(.simply-empty) {
background-color: white;
padding: 10px;
Expand Down Expand Up @@ -495,7 +503,11 @@
<template id="org-repos">
<ol class="repos" data-simply-list="orgRepos">
<template>
<li class="repo">
<li class="repo"
data-simply-field="archived"
data-simply-content="attributes"
data-simply-attributes="data-archived"
>
<h3 data-simply-field="name"></h3>
<div class="teams" data-simply-list="teams">
<template>
Expand Down

0 comments on commit ddf1d58

Please sign in to comment.