File tree Expand file tree Collapse file tree 4 files changed +19
-0
lines changed Expand file tree Collapse file tree 4 files changed +19
-0
lines changed Original file line number Diff line number Diff line change @@ -6,6 +6,7 @@ export default DS.Model.extend({
6
6
created_at : DS . attr ( 'date' ) ,
7
7
updated_at : DS . attr ( 'date' ) ,
8
8
downloads : DS . attr ( 'number' ) ,
9
+ yanked : DS . attr ( 'boolean' ) ,
9
10
10
11
crate : DS . belongsTo ( 'crate' ) ,
11
12
authors : DS . hasMany ( 'users' , { async : true } ) ,
Original file line number Diff line number Diff line change @@ -110,6 +110,11 @@ span.small {
110
110
}
111
111
}
112
112
113
+ .yanked {
114
+ font-size : 80% ;
115
+ color : rgb (166 , 0 , 0 )
116
+ }
117
+
113
118
span .loading {
114
119
display : inline-block ;
115
120
width : 16px ;
Original file line number Diff line number Diff line change 29
29
{{! This is used to set the url of to actually download a file }}
30
30
<iframe id =' download-frame' style =' display:none' ></iframe >
31
31
32
+ {{ #if currentVersion.yanked }}
33
+ <div class =' crate-info' >
34
+ This crate has been yanked, but it is still available for download for
35
+ other crates that may be depending on it.
36
+ </div >
37
+ {{ else }}
32
38
<div class =' crate-info' >
33
39
<div class =' docs' >
34
40
{{ #if description }}
116
122
<div id =' graph-data' ></div >
117
123
</div >
118
124
</div >
125
+ {{ /if }}
119
126
120
127
<div id =' crate-links' >
121
128
<div class =' section' >
173
180
<li >
174
181
{{ #link-to ' crate' this }} {{ num }} {{ /link-to }}
175
182
<span class =' date' >{{ date-small created_at }} </span >
183
+ {{ #if yanked }}
184
+ <span class =' yanked' >yanked</span >
185
+ {{ /if }}
176
186
</li >
177
187
{{ /each }}
178
188
</ul >
Original file line number Diff line number Diff line change 16
16
<div >
17
17
{{ #link-to ' crate' this }} {{ num }} {{ /link-to }}
18
18
<span class =' small' >{{ date-long created_at }} </span >
19
+ {{ #if yanked }}
20
+ <span class =' yanked' >yanked</span >
21
+ {{ /if }}
19
22
</div >
20
23
{{ #link-to ' crate' this class =' arrow' }}
21
24
<img src =" /assets/right-arrow-all-versions.png" />
You can’t perform that action at this time.
0 commit comments