diff --git a/Source+Sans+Pro.css b/Source+Sans+Pro.css new file mode 100644 index 00000000..3a00466c --- /dev/null +++ b/Source+Sans+Pro.css @@ -0,0 +1,56 @@ +/* cyrillic-ext */ +@font-face { + font-family: 'Source Sans Pro'; + font-style: normal; + font-weight: 400; + src: local('Source Sans Pro Regular'), local('SourceSansPro-Regular'), url(https://fonts.gstatic.com/s/sourcesanspro/v12/6xK3dSBYKcSV-LCoeQqfX1RYOo3qNa7lqDY.woff2) format('woff2'); + unicode-range: U+0460-052F, U+1C80-1C88, U+20B4, U+2DE0-2DFF, U+A640-A69F, U+FE2E-FE2F; +} +/* cyrillic */ +@font-face { + font-family: 'Source Sans Pro'; + font-style: normal; + font-weight: 400; + src: local('Source Sans Pro Regular'), local('SourceSansPro-Regular'), url(https://fonts.gstatic.com/s/sourcesanspro/v12/6xK3dSBYKcSV-LCoeQqfX1RYOo3qPK7lqDY.woff2) format('woff2'); + unicode-range: U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116; +} +/* greek-ext */ +@font-face { + font-family: 'Source Sans Pro'; + font-style: normal; + font-weight: 400; + src: local('Source Sans Pro Regular'), local('SourceSansPro-Regular'), url(https://fonts.gstatic.com/s/sourcesanspro/v12/6xK3dSBYKcSV-LCoeQqfX1RYOo3qNK7lqDY.woff2) format('woff2'); + unicode-range: U+1F00-1FFF; +} +/* greek */ +@font-face { + font-family: 'Source Sans Pro'; + font-style: normal; + font-weight: 400; + src: local('Source Sans Pro Regular'), local('SourceSansPro-Regular'), url(https://fonts.gstatic.com/s/sourcesanspro/v12/6xK3dSBYKcSV-LCoeQqfX1RYOo3qO67lqDY.woff2) format('woff2'); + unicode-range: U+0370-03FF; +} +/* vietnamese */ +@font-face { + font-family: 'Source Sans Pro'; + font-style: normal; + font-weight: 400; + src: local('Source Sans Pro Regular'), local('SourceSansPro-Regular'), url(https://fonts.gstatic.com/s/sourcesanspro/v12/6xK3dSBYKcSV-LCoeQqfX1RYOo3qN67lqDY.woff2) format('woff2'); + unicode-range: U+0102-0103, U+0110-0111, U+1EA0-1EF9, U+20AB; +} +/* latin-ext */ +@font-face { + font-family: 'Source Sans Pro'; + font-style: normal; + font-weight: 400; + src: local('Source Sans Pro Regular'), local('SourceSansPro-Regular'), url(https://fonts.gstatic.com/s/sourcesanspro/v12/6xK3dSBYKcSV-LCoeQqfX1RYOo3qNq7lqDY.woff2) format('woff2'); + unicode-range: U+0100-024F, U+0259, U+1E00-1EFF, U+2020, U+20A0-20AB, U+20AD-20CF, U+2113, U+2C60-2C7F, U+A720-A7FF; +} +/* latin */ +@font-face { + font-family: 'Source Sans Pro'; + font-style: normal; + font-weight: 400; + src: local('Source Sans Pro Regular'), local('SourceSansPro-Regular'), url(https://fonts.gstatic.com/s/sourcesanspro/v12/6xK3dSBYKcSV-LCoeQqfX1RYOo3qOK7l.woff2) format('woff2'); + unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+2000-206F, U+2074, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; +} diff --git a/content.css b/content.css index 670bc4d0..13bb025b 100644 --- a/content.css +++ b/content.css @@ -1,7 +1,11 @@ +.sponsorSkipObject { + font-family: 'Source Sans Pro', sans-serif; +} + #sponsorSkipNotice { min-height: 120px; min-width: 400px; - background-color: rgba(153, 153, 153, 0.8); + background-color: rgba(217, 255, 220, 0.8); position: absolute; z-index: 1; } @@ -11,6 +15,7 @@ color: #000000; text-align: center; margin-top: 10px; + font-weight: bold; } .sponsorSkipButton { @@ -22,9 +27,8 @@ display:inline-block; cursor:pointer; color:#ffffff; - font-family:Arial; - font-size:16px; - padding:8px 15px; + font-size:14px; + padding:4px 15px; text-decoration:none; text-shadow:0px 0px 0px #2f6627; @@ -51,7 +55,6 @@ display:inline-block; cursor:pointer; color:#ffffff; - font-family:Arial; font-size:13px; padding:6px 24px; text-decoration:none; diff --git a/content.js b/content.js index b371cc49..df3b4572 100644 --- a/content.js +++ b/content.js @@ -108,7 +108,7 @@ function sponsorCheck(sponsorTimes) { // Video skipping //send out the message saying that a sponsor message was skipped openSkipNotice(); - setTimeout(closeSkipNotice, 2500); + // setTimeout(closeSkipNotice, 2500); } lastTime = v.currentTime; @@ -133,9 +133,11 @@ function openSkipNotice(){ var noticeElement = document.createElement("div"); noticeElement.id = "sponsorSkipNotice"; + noticeElement.className = "sponsorSkipObject"; var noticeMessage = document.createElement("p"); noticeMessage.id = "sponsorSkipMessage"; + noticeMessage.className = "sponsorSkipObject"; noticeMessage.innerText = "Hey, you just skipped a sponsor!"; var buttonContainer = document.createElement("div"); @@ -143,16 +145,19 @@ function openSkipNotice(){ var goBackButton = document.createElement("button"); goBackButton.innerText = "Go back"; + goBackButton.className = "sponsorSkipObject"; goBackButton.className = "sponsorSkipButton"; goBackButton.addEventListener("click", goBackToPreviousTime); var hideButton = document.createElement("button"); - hideButton.innerText = "Hide"; + hideButton.innerText = "Hide"; + hideButton.className = "sponsorSkipObject"; hideButton.className = "sponsorSkipButton"; hideButton.addEventListener("click", closeSkipNotice); var dontShowAgainButton = document.createElement("button"); - dontShowAgainButton.innerText = "Don't Show This Again"; + dontShowAgainButton.innerText = "Don't Show This Again"; + dontShowAgainButton.className = "sponsorSkipObject"; dontShowAgainButton.className = "sponsorSkipDontShowButton"; dontShowAgainButton.addEventListener("click", dontShowNoticeAgain); diff --git a/manifest.json b/manifest.json index e576dd08..b97d75aa 100644 --- a/manifest.json +++ b/manifest.json @@ -12,7 +12,8 @@ "content.js" ], "css": [ - "content.css" + "content.css", + "Source+Sans+Pro.css" ] } ],