Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
  • Loading branch information
rycont committed Jun 20, 2020
2 parents 82239a4 + efd53be commit 85157d2
Show file tree
Hide file tree
Showing 6 changed files with 124 additions and 119 deletions.
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,2 +1,3 @@
# better-benedu
Benedu의 디자인을 크롬 익스텐션을 통해 바꿔줍니다.
Maintained by 강혁진, 민유, 정한
102 changes: 102 additions & 0 deletions css/global.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,102 @@
@import url("https://fonts.googleapis.com/css2?family=Noto+Sans+KR:wght@100;300;400;500;700;900&display=swap");

body {
font-family: "Noto Sans KR", "나눔스퀘어", "나눔바른고딕", Arial;
}

.skin-2 .navbar {
background: #393939;
}

.navbar-brand {
display: none;
}

img.pull-left {
content: url("https://raw.githubusercontent.com/HyeokjinKang/better-benedu/master/icon64.png");
margin-top: 6px;
height: 24px;
}
.menu-min {
width: 60px !important;
}

.sidebar.menu-min.compact {
width: 60px !important;
}

.sidebar-shortcuts-mini {
margin-left: 9px;
}

.nav-list > li > a > .menu-icon {
width: 60px !important;
}

#___sharetoclassroom_0 {
display: none !important;
}

.skin-2 .sidebar.menu-min .nav-list > li > a > .menu-text {
margin-left: 18px;
}

.user-info {
display: none;
}

.ace-nav > li {
border: none;
}

.fa-clock-o {
color: white !important;
}

.glyphicon {
color: white !important;
}

small > a {
color: white !important;
}

.ace-nav > li.light-blue > a {
background-color: #393939 !important;
}

#sidebar > div.nav-wrap-up.pos-rel > div.nav-wrap > div > ul > li {
border: none;
}

/* 배경 색 변경 */
.page-content {
height: 100%;
background-color: #393939;
}

.main-content-inner {
height: calc(100vh - 45px);
}

#main-container {
height: 100vh;
}

/* 버튼 색 변경 */
.skin-2 .navbar .navbar-toggle {
background-color: #393939;
}

.skin-2 .nav-list > li.hover-show > a {
background-color: #393939 !important;
}

.sidebar.menu-min .nav-list > li > .submenu {
left: 59px;
}

/* 푸터 삭제 */
.footer {
display: none;
}
119 changes: 4 additions & 115 deletions css/studentHome.css
Original file line number Diff line number Diff line change
@@ -1,24 +1,3 @@
@import url("https://fonts.googleapis.com/css2?family=Noto+Sans+KR:wght@100;300;400;500;700;900&display=swap");

/* 폰트 변경 */
body {
font-family: "Noto Sans KR", "나눔스퀘어", "나눔바른고딕", Arial;
}

.skin-2 .navbar {
background: #393939;
}

.navbar-brand {
display: none;
}

img.pull-left {
content: url("https://raw.githubusercontent.com/HyeokjinKang/better-benedu/master/icon64.png");
margin-top: 6px;
height: 24px;
}

.slide-0 {
background: linear-gradient(0, #1f1f1f, #393939) !important;
}
Expand All @@ -27,54 +6,6 @@ img.pull-left {
display: none;
}

.menu-min {
width: 60px !important;
}

.sidebar.menu-min.compact {
width: 60px !important;
}

.sidebar-shortcuts-mini {
margin-left: 9px;
}

.nav-list > li > a > .menu-icon {
width: 60px !important;
}

#___sharetoclassroom_0 {
display: none !important;
}

.skin-2 .sidebar.menu-min .nav-list > li > a > .menu-text {
margin-left: 18px;
}

.user-info {
display: none;
}

.ace-nav > li {
border: none;
}

.fa-clock-o {
color: white !important;
}

.glyphicon {
color: white !important;
}

small > a {
color: white !important;
}

.ace-nav > li.light-blue > a {
background-color: #393939 !important;
}

.carousel-caption {
font-size: 1.2em;
}
Expand All @@ -86,11 +17,6 @@ small > a {
.carousel-caption > p:nth-child(3) {
font-size: 1em;
}

/* 사이드바 보더 없애기 */
#sidebar > div.nav-wrap-up.pos-rel > div.nav-wrap > div > ul > li {
border: none;
}
/* 짜잔 */
/* 여기서부터는 민유의 코드 */

Expand All @@ -100,38 +26,11 @@ small > a {
color: white;
}

/* 버튼 색 변경 */
.skin-2 .navbar .navbar-toggle {
background-color: #393939;
}

.skin-2 .nav-list > li.hover-show > a {
background-color: #393939 !important;
}

.sidebar.menu-min .nav-list > li > .submenu {
left: 59px;
}

/* 폰트 색 변경 */
.row {
color: white;
}

/* 배경 색 변경 */
.page-content {
height: 100%;
background-color: #393939;
}

.main-content-inner {
height: calc(100vh - 45px);
}

#main-container {
height: 100vh;
}

/* 색칠되지 않은 별 색 변경 */
.light-grey {
color: #323232 !important;
Expand Down Expand Up @@ -164,11 +63,6 @@ small > a {
color: white;
}

/* 푸터 삭제 */
.footer {
display: none;
}

.fc-state-default,
.fc-state-default .fc-button-inner {
/* 학습계획 /일정에서의 버튼 색 변경 */
Expand Down Expand Up @@ -266,15 +160,6 @@ svg {
opacity: 0.9;
}

/* 일일단어 위젯 안쓰는 아이콘 제거 */
#mainVoca
> div
> div
> div.widget-header.widget-header-small.header-color-blue2
> div {
display: none;
}

/* 날씨위젯에 현재시간 표시 제거 */
#mainWeather
> div
Expand All @@ -290,6 +175,10 @@ svg {
border: none;
}

.fc-bg > table > tbody > tr {
background: linear-gradient(0, #393939, #4b4b4b);
}

/* 위젯-내용 공백 제거 */
.widget-body > div {
padding: 0px;
Expand Down
13 changes: 10 additions & 3 deletions js/content.js
Original file line number Diff line number Diff line change
@@ -1,16 +1,23 @@
const url = window.location.href;

const inject = path => {
const injectCss = path => {
let link = document.createElement("link");
link.setAttribute("rel", "stylesheet");
link.setAttribute("type", "text/css");
link.setAttribute("href", chrome.extension.getURL(path));
document.getElementsByTagName("head")[0].appendChild(link);
}

const injectJs = path => {
let script = document.createElement("script");
script.setAttribute("src", chrome.extension.getURL(path));
document.getElementsByTagName("body")[0].appendChild(script);
}

if(url.includes("benedu.co.kr")) {
inject("css/global.css");
injectCss("css/global.css");
if(url.includes("/StudentHome")) {
inject("css/studentHome.css");
injectCss("css/studentHome.css");
injectJs("js/studentHome.js");
}
}
6 changes: 6 additions & 0 deletions js/studentHome.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion manifest.json
Original file line number Diff line number Diff line change
Expand Up @@ -17,5 +17,5 @@
"name": "Better Benedu",
"permissions": ["*://*.benedu.co.kr/*", "tabs", "activeTab"],
"version": "1.0",
"web_accessible_resources": [ "svg/*.svg", "css/*.css" ]
"web_accessible_resources": [ "css/*.css", "js/*.js" ]
}

0 comments on commit 85157d2

Please sign in to comment.