mirror of
https://github.com/heyarne/berliner-winter.git
synced 2026-05-06 19:23:39 +02:00
Merge branch 'master' of github.com:aesthaddicts/OpenData
This commit is contained in:
commit
8bcb3c62f9
2 changed files with 21 additions and 7 deletions
17
analyze.py
17
analyze.py
|
|
@ -87,12 +87,21 @@ def get_categories(article_body):
|
||||||
"""
|
"""
|
||||||
bad_words = {
|
bad_words = {
|
||||||
'antisemit': 'antisemitism',
|
'antisemit': 'antisemitism',
|
||||||
'homophob': 'homophobia',
|
'jud': 'antisemitism',
|
||||||
|
'jüd': 'antisemitism',
|
||||||
|
'homo': 'homophobia',
|
||||||
|
'schwul': 'homophobia',
|
||||||
|
'lesb': 'homophobia',
|
||||||
|
'trans': 'homophobia',
|
||||||
'sexis': 'sexism',
|
'sexis': 'sexism',
|
||||||
'rassis': 'racism'
|
'frauenfeind': 'sexism',
|
||||||
|
'rassis': 'racism',
|
||||||
|
'fremdenfeind': 'racism',
|
||||||
|
'flüchtling': 'racism',
|
||||||
|
'migrant': 'racism'
|
||||||
}
|
}
|
||||||
found_categories = [bad_words[key] for key in bad_words
|
found_categories = set([bad_words[key] for key in bad_words
|
||||||
if key in article_body.lower()]
|
if key in article_body.lower()])
|
||||||
return found_categories
|
return found_categories
|
||||||
|
|
||||||
def get_geoloc(query):
|
def get_geoloc(query):
|
||||||
|
|
|
||||||
|
|
@ -90,6 +90,7 @@ a {
|
||||||
text-decoration: none;
|
text-decoration: none;
|
||||||
color: #ddd;
|
color: #ddd;
|
||||||
text-align: center;
|
text-align: center;
|
||||||
|
-webkit-transition: background .3s ease;
|
||||||
transition: background .3s ease;
|
transition: background .3s ease;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -108,6 +109,7 @@ a {
|
||||||
.category-filter li {
|
.category-filter li {
|
||||||
margin: 12px 0;
|
margin: 12px 0;
|
||||||
opacity: .5;
|
opacity: .5;
|
||||||
|
-webkit-transition: opacity .3s ease;
|
||||||
transition: opacity .3s ease;
|
transition: opacity .3s ease;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -166,6 +168,7 @@ a {
|
||||||
width: 100%;
|
width: 100%;
|
||||||
top: 0;
|
top: 0;
|
||||||
left: 0;
|
left: 0;
|
||||||
|
background: -webkit-linear-gradient(top right, rgba(255,255,255,.2), white 50%);
|
||||||
background: linear-gradient(to bottom left, rgba(255,255,255,.2), white 50%);
|
background: linear-gradient(to bottom left, rgba(255,255,255,.2), white 50%);
|
||||||
display: table-cell;
|
display: table-cell;
|
||||||
vertical-align: center;
|
vertical-align: center;
|
||||||
|
|
@ -177,6 +180,8 @@ a {
|
||||||
left: 50%;
|
left: 50%;
|
||||||
width: 90%;
|
width: 90%;
|
||||||
max-width: 1024px;
|
max-width: 1024px;
|
||||||
|
-webkit-transform: translate(-50%,-50%);
|
||||||
|
-ms-transform: translate(-50%,-50%);
|
||||||
transform: translate(-50%,-50%);
|
transform: translate(-50%,-50%);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue