Explorar o código

blur 처리 방식 변경

ect (or 2du) %!s(int64=8) %!d(string=hai) anos
pai
achega
96525d9304
Modificáronse 1 ficheiros con 4 adicións e 2 borrados
  1. 4 2
      set_mark/link.py

+ 4 - 2
set_mark/link.py

@@ -29,11 +29,13 @@ def link(conn, title, data, num, category, backlink):
                 category += ' / '                
 
             style = ''
+            title_name = re.sub("분류:", "", g[0])
             if g[1]:
                 if re.search('#blur', g[1]):
-                    style = ' style="filter: blur(3px);" onmouseover="this.style.filter=\'none\';" onmouseout="this.style.filter=\'blur(3px)\';"'
+                    style = ' onmouseover="this.innerHTML=\'' + title_name + '\';"'
+                    title_name = '<span id="inside">스포일러</span>'
                 
-            category += '<a ' + red + ' ' + style + ' href="/w/' + url_pas(g[0]) + '">' + re.sub("분류:", "", g[0]) + '</a>'
+            category += '<a ' + red + ' ' + style + ' href="/w/' + url_pas(g[0]) + '">' + title_name + '</a>'
         
         data = re.sub("\[\[(분류:(?:(?:(?!\]\]|#).)+))((?:#(?:(?:(?!#|\]\]).)+))+)?\]\]", '', data, 1)