fixed conflict

master
Castro0o 5 years ago
commit 52ca77ce4d

@ -98,7 +98,11 @@
margin-top: 70px;
line-height: 1.5;
float: right;
cursor: pointer;
}
.eachwords {
cursor: pointer;
}
.top_words {
@ -114,6 +118,7 @@
position: fixed;
float: left;
}
.top_words_title {
@ -186,5 +191,3 @@
background-color: lightgreen;
}

File diff suppressed because it is too large Load Diff

@ -37,11 +37,16 @@ print('''<!DOCTYPE>
<head>
<script src="https://code.jquery.com/jquery-3.5.0.min.js"></script>
<link rel="stylesheet" href="faceapp.css">
<<<<<<< HEAD
=======
<link rel="stylesheet" href="legend.css">
>>>>>>> 6ee205254e8d1a95ada02cc7d5f0ac0fc0d3d046
<script src="highlight.js"></script>
<meta charset="utf-8">
<title></title>
</head>
<body>''')
@ -86,7 +91,7 @@ for paragraph in faceapp_text_list:
tagged = pos_tag(tokenized)
print('<p>')
for word, pos in tagged:
print('<span class="{0} {1}">{2}</span>'.format(pos.replace('.', 'dot').replace(',', 'comma').replace('(', 'marks').replace(')', 'marks').replace(':', 'marks').replace(';', 'marks'), word.replace('.', 'dot').replace(',', 'comma').replace('(', 'marks').replace(')', 'marks').replace(':', 'marks').replace(';', 'marks').lower(), word))
print('<span class="{0} {1} eachwords">{2}</span>'.format(pos.replace('.', 'dot').replace(',', 'comma').replace('(', 'marks').replace(')', 'marks').replace(':', 'marks').replace(';', 'marks'), word.replace('.', 'dot').replace(',', 'comma').replace('(', 'marks').replace(')', 'marks').replace(':', 'marks').replace(';', 'marks').lower(), word))
print('</p>')
print('</div>')

@ -11,6 +11,19 @@ $(document).ready(function() {
});
/* legend */
$('.legendverb').click(
function() {
$('.VB, .VBZ, .VBN, .VVD').toggleClass('verb');
$('.legendverb').css('background-color','white');
$(this).css('background-color','yellow');
});
/* pos highlight*/
$('.TO, .DT, .IN, .WDT, .WP, .MD, .PRP, .CC, .marks, .comma, .dot').click(
function() {
$('.TO, .DT, .IN, .WDT, .WP, .MD, .PRP, .CC, .marks, .comma, .dot').toggleClass('hide');

@ -0,0 +1,28 @@
.legend {
font-family: Belgika;
font-size: 10pt;
margin-top: 50px;
list-style: none;
margin-left: 12vw;
float: left;
}
.legend li { float: left; margin-right: 10px; }
.legend span { border: 1px solid #ccc; float: left; width: 12px; height: 12px; margin: 2px; }
/*.legend .legendverb { background-color: #ff00ff; }
*/.legend .legendnoun { background-color: #00ffff; }
.legend .legendadjective { background-color: #0000ff; }
.legend .legendadverb { background-color: green; }
.legend .legendhide { background-color: #000000; }
.legendverb:hover {
background-color: yellow;
}
Loading…
Cancel
Save