File tree 2 files changed +32
-0
lines changed
2 files changed +32
-0
lines changed Original file line number Diff line number Diff line change @@ -78,6 +78,17 @@ a { text-decoration: none; }
78
78
text-align : justify;
79
79
}
80
80
81
+ .recommended {
82
+ font-weight : 200 ;
83
+ font-size : small;
84
+ color : # fff ;
85
+ background : # 43C47A ;
86
+ border-radius : 3px ;
87
+ padding : 0 4px ;
88
+ margin-top : 15px ;
89
+ position : absolute;
90
+ }
91
+
81
92
.buttons {
82
93
padding : 14px 0 14px 0 ;
83
94
text-align : center;
Original file line number Diff line number Diff line change 1
1
var idpList = 'https://solid.github.io/solid-idp-list/services.json' ;
2
+ var recommended = [ 'https://databox.me/' ] ;
2
3
3
4
/* ---- DON'T EDIT BELOW ---- */
4
5
var accURL = { } ;
@@ -46,6 +47,26 @@ var list = function(data) {
46
47
var header_link = document . createElement ( 'a' ) ;
47
48
header_link . href = safeHTML ( idp . url ) ;
48
49
header . appendChild ( header_link ) ;
50
+
51
+ // recommended?
52
+ if ( idp . url && idp . url . length > 0 ) {
53
+ for ( var i in recommended ) {
54
+ if ( recommended [ i ] == idp . url ) {
55
+ var rec = document . createElement ( 'div' ) ;
56
+ rec . classList . add ( 'recommended' ) ;
57
+ rec . innerHTML = "Recommended" ;
58
+ if ( idp . btn_bg && idp . btn_bg . length > 0 ) {
59
+ rec . style . background = safeHTML ( idp . btn_bg ) ;
60
+ }
61
+ if ( idp . btn_color && idp . btn_color . length > 0 ) {
62
+ rec . style . color = safeHTML ( idp . btn_color ) ;
63
+ }
64
+ header_link . appendChild ( rec ) ;
65
+ break ;
66
+ }
67
+ }
68
+ }
69
+
49
70
// icon
50
71
if ( idp . icon && idp . icon . length > 0 ) {
51
72
var img = document . createElement ( 'img' ) ;
You can’t perform that action at this time.
0 commit comments