Skip to content
This repository has been archived by the owner on Apr 24, 2018. It is now read-only.

Commit

Permalink
Working and ready to go.
Browse files Browse the repository at this point in the history
  • Loading branch information
AstraLuma committed Mar 1, 2012
1 parent 0f3b6c3 commit 68e6ddd
Show file tree
Hide file tree
Showing 8 changed files with 20 additions and 17 deletions.
Binary file added bin.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added icon-blacklist.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added icon-delete.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added icon-potential.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added icon-secure.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
19 changes: 10 additions & 9 deletions options.css
Expand Up @@ -37,28 +37,29 @@ h1::before {
height:40px;
}

[data-status=potential] th {
[data-status=potential] {
border-color: #2A2;
background: #EFE;
background: #AFA;
}

[data-status=blacklist] th {
[data-status=blacklist] {
border-color: #F22;
background: #FEE;
background: #FAA;
}

/* TODO: Figure out how to style image buttons */
[data-site] td:not(.delete) {
opacity: 50%;
opacity: 0.5;
cursor: pointer;
}

td.delete {
cursor: pointer;
padding-left: 1em;
}

[data-status=secure] .secure,
[data-status=potential] .potential,
[data-status=blacklist] .blacklist {
opacity: 100%;
[data-status="secure"] .secure,
[data-status="potential"] .potential,
[data-status="blacklist"] .blacklist {
opacity: 1.0 !important;
}
4 changes: 3 additions & 1 deletion options.html
Expand Up @@ -32,8 +32,10 @@ <h2>Current sites</h2>
<th colspan="6">Add a site</th>
</tr>
<tr>
<td colspan="6">
<td colspan="2">
<input id="siteName" type="text" name="siteName" placeholder="Site Name">
</td>
<td colspan="4">
<button id="save-site">Save</button>
<button id="test-url-for-https">Test</button>
</td>
Expand Down
14 changes: 7 additions & 7 deletions options.js
Expand Up @@ -12,17 +12,17 @@ function mkSiteItem(site) {
var row = $("<tr></tr>").attr('data-site', site.site).attr('data-status', site.status)
.append($("<th><input type='checkbox'></th>"))
.append($("<th></th>").text(site.site))
.append($("<td class='secure'><img src='icon-secure.png'></td>"))
.append($("<td class='potential'><img src='icon-potential.png'></td>"))
.append($("<td class='blacklist'><img src='icon-blacklist.png'></td>"))
.append($("<td class='delete'><img src='icon-delete.png'></td>"))
.append($("<td class='secure' title='Secured'><img src='icon-secure.png'></td>"))
.append($("<td class='potential' title='Potential'><img src='icon-potential.png'></td>"))
.append($("<td class='blacklist' title='Blacklisted'><img src='icon-blacklist.png'></td>"))
.append($("<td class='delete' title='Delete Site'><img src='icon-delete.png'></td>"))
;
$('td', row).click(function(evt) {
var site = this.parentNode.attributes['data-site'];
var site = this.parentNode.attributes['data-site'].nodeValue;
if (this.className == 'delete') {
UseHTTPS.site.del(site);
UseHttps.site.del(site);
} else if (this.className) {
UseHTTPS.site.set(site, {status: this.className});
UseHttps.site.set(site, {status: this.className});
}
});
return row;
Expand Down

0 comments on commit 68e6ddd

Please sign in to comment.