Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Grunt 대신 WebPack 도입 #1042

Open
wants to merge 3 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
84 changes: 0 additions & 84 deletions Server/lib/Gruntfile.js

This file was deleted.

38 changes: 18 additions & 20 deletions Server/lib/Web/lib/global.js
Original file line number Diff line number Diff line change
Expand Up @@ -20,8 +20,6 @@
* 볕뉘 수정사항:
* getCookie 코드오류로 인한 코드 수정
*/
var global = {};
var L;

(function(){
var size;
Expand Down Expand Up @@ -85,9 +83,9 @@ var L;
var explSize;
var gn = $("#gn-content").html() || "";

global.profile = $("#profile").html();
if(global.profile) global.profile = JSON.parse(global.profile);
else global.profile = {};
globalThis.profile = $("#profile").html();
if(globalThis.profile) globalThis.profile = JSON.parse(globalThis.profile);
else globalThis.profile = {};

$.cookie('test', "good");
if($.cookie('test') != "good"){
Expand Down Expand Up @@ -120,8 +118,8 @@ var L;
// 계정
if($.cookie('lc') == "") $.cookie('lc', "ko_KR");

if(global.profile.token){
$("#account-info").html(global.profile.title || global.profile.name).on('click', function(e){
if(globalThis.profile.token){
$("#account-info").html(globalThis.profile.title || globalThis.profile.name).on('click', function(e){
if(confirm(L['ASK_LOGOUT'])) requestLogout(e);
});
}else{
Expand All @@ -137,8 +135,8 @@ var L;
/*if($.cookie('forlogout')){
requestLogout();
}*/
global.watchInput($("#quick-search-tf"));
(global.expl = function($mother){
globalThis.watchInput($("#quick-search-tf"));
(globalThis.expl = function($mother){
var $q = $mother ? $mother.find(".expl") : $(".expl");

$q.parent().addClass("expl-mother").on('mouseenter', function(e){
Expand Down Expand Up @@ -177,8 +175,8 @@ var L;
var i, c = 0;

$ac.empty();
global['wl-'+cid] = res.list.slice(0, 10);
global['wi-'+cid] = -1;
globalThis['wl-'+cid] = res.list.slice(0, 10);
globalThis['wi-'+cid] = -1;
for(i in res.list){
if(c++ >= 10) break;
$ac.append($("<div>")
Expand All @@ -205,7 +203,7 @@ var L;
}
_setTimeout(onWatchInput, 200, $o, prev);
}
global.watchInput = function($tf){
globalThis.watchInput = function($tf){
var cid = $tf.attr('id');

$tf.after($("<div>")
Expand All @@ -221,21 +219,21 @@ var L;
var list;

if(!dir) return;
if(!(list = global['wl-'+cid])) return;
if(global['wi-'+cid] == -1) if(dir == -1) dir = 0;
if(!(list = globalThis['wl-'+cid])) return;
if(globalThis['wi-'+cid] == -1) if(dir == -1) dir = 0;

$(".autocomp-select").removeClass("autocomp-select");
global['wi-'+cid] += dir;
if(global['wi-'+cid] < 0) global['wi-'+cid] += list.length;
if(global['wi-'+cid] >= list.length) global['wi-'+cid] = 0;
globalThis['wi-'+cid] += dir;
if(globalThis['wi-'+cid] < 0) globalThis['wi-'+cid] += list.length;
if(globalThis['wi-'+cid] >= list.length) globalThis['wi-'+cid] = 0;

$("#aci-" + list[global['wi-'+cid]]._id).addClass("autocomp-select");
$("#aci-" + list[globalThis['wi-'+cid]]._id).addClass("autocomp-select");
e.preventDefault();
});
return _setTimeout(onWatchInput, 200, $tf, $tf.val());
};
global.zeroPadding = function(num, len){ var s = num.toString(); return "000000000000000".slice(0, Math.max(0, len - s.length)) + s; };
global.onPopup = function(url){
globalThis.zeroPadding = function(num, len){ var s = num.toString(); return "000000000000000".slice(0, Math.max(0, len - s.length)) + s; };
globalThis.onPopup = function(url){
location.href = url;
};
})();
21 changes: 20 additions & 1 deletion Server/lib/Web/lib/in_game_kkutu.js
Original file line number Diff line number Diff line change
@@ -1,3 +1,21 @@
/**
Rule the words! KKuTu Online
Copyright (C) 2017 JJoriping(op@jjo.kr)

This program is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.

This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.

You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
(function(){
/**
* Rule the words! KKuTu Online
* Copyright (C) 2017 JJoriping(op@jjo.kr)
Expand Down Expand Up @@ -4788,4 +4806,5 @@ function yell(msg){
*/

delete window.WebSocket;
delete window.setInterval;
delete window.setInterval;
})();
37 changes: 17 additions & 20 deletions Server/lib/Web/public/js/global.min.js

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

Loading