mirror of https://gitlab.com/bashrc2/epicyon
Change terminology
parent
24ce6e69c2
commit
4a64c60a75
|
@ -124,7 +124,7 @@ input[type=text] {
|
||||||
}
|
}
|
||||||
|
|
||||||
@media screen and (min-width: 400px) {
|
@media screen and (min-width: 400px) {
|
||||||
.hashtagcloud {
|
.hashtagswarm {
|
||||||
font-size: 30px;
|
font-size: 30px;
|
||||||
padding: 30px;
|
padding: 30px;
|
||||||
line-height: 60px;
|
line-height: 60px;
|
||||||
|
@ -157,7 +157,7 @@ input[type=text] {
|
||||||
}
|
}
|
||||||
|
|
||||||
@media screen and (max-width: 1000px) {
|
@media screen and (max-width: 1000px) {
|
||||||
.hashtagcloud {
|
.hashtagswarm {
|
||||||
font-size: 40px;
|
font-size: 40px;
|
||||||
padding: 40px;
|
padding: 40px;
|
||||||
line-height: 70px;
|
line-height: 70px;
|
||||||
|
|
|
@ -3755,13 +3755,13 @@ def htmlCalendar(translate: {}, \
|
||||||
calendarStr+=htmlFooter()
|
calendarStr+=htmlFooter()
|
||||||
return calendarStr
|
return calendarStr
|
||||||
|
|
||||||
def htmlHashTagCloud(baseDir: str,actor: str) -> str:
|
def htmlHashTagSwarm(baseDir: str,actor: str) -> str:
|
||||||
"""Returns a tag cloud of today's hashtags
|
"""Returns a tag swarm of today's hashtags
|
||||||
"""
|
"""
|
||||||
daysSinceEpoch=(datetime.utcnow() - datetime(1970,1,1)).days
|
daysSinceEpoch=(datetime.utcnow() - datetime(1970,1,1)).days
|
||||||
daysSinceEpochStr=str(daysSinceEpoch)+' '
|
daysSinceEpochStr=str(daysSinceEpoch)+' '
|
||||||
nickname=getNicknameFromActor(actor)
|
nickname=getNicknameFromActor(actor)
|
||||||
tagCloud=[]
|
tagSwarm=[]
|
||||||
for subdir, dirs, files in os.walk(baseDir+'/tags'):
|
for subdir, dirs, files in os.walk(baseDir+'/tags'):
|
||||||
for f in files:
|
for f in files:
|
||||||
tagsFilename=os.path.join(baseDir+'/tags',f)
|
tagsFilename=os.path.join(baseDir+'/tags',f)
|
||||||
|
@ -3784,16 +3784,16 @@ def htmlHashTagCloud(baseDir: str,actor: str) -> str:
|
||||||
if postDaysSinceEpoch<daysSinceEpoch:
|
if postDaysSinceEpoch<daysSinceEpoch:
|
||||||
break
|
break
|
||||||
if postDaysSinceEpoch==daysSinceEpoch:
|
if postDaysSinceEpoch==daysSinceEpoch:
|
||||||
tagCloud.append(hashTagName)
|
tagSwarm.append(hashTagName)
|
||||||
break
|
break
|
||||||
if not tagCloud:
|
if not tagSwarm:
|
||||||
return ''
|
return ''
|
||||||
tagCloud.sort()
|
tagSwarm.sort()
|
||||||
tagCloudStr=''
|
tagSwarmStr=''
|
||||||
for tagName in tagCloud:
|
for tagName in tagSwarm:
|
||||||
tagCloudStr+='<a href="'+actor+'/tags/'+tagName+'" class="hashtagcloud">'+tagName+'</a> '
|
tagSwarmStr+='<a href="'+actor+'/tags/'+tagName+'" class="hashtagswarm">'+tagName+'</a> '
|
||||||
tagCloudHtml=tagCloudStr.strip()+'\n'
|
tagSwarmHtml=tagSwarmStr.strip()+'\n'
|
||||||
return tagCloudHtml
|
return tagSwarmHtml
|
||||||
|
|
||||||
def htmlSearch(translate: {}, \
|
def htmlSearch(translate: {}, \
|
||||||
baseDir: str,path: str) -> str:
|
baseDir: str,path: str) -> str:
|
||||||
|
@ -3822,7 +3822,7 @@ def htmlSearch(translate: {}, \
|
||||||
followStr+=' <input type="text" name="searchtext" autofocus><br>'
|
followStr+=' <input type="text" name="searchtext" autofocus><br>'
|
||||||
followStr+=' <button type="submit" class="button" name="submitSearch">'+translate['Submit']+'</button>'
|
followStr+=' <button type="submit" class="button" name="submitSearch">'+translate['Submit']+'</button>'
|
||||||
followStr+=' </form>'
|
followStr+=' </form>'
|
||||||
followStr+=' <p class="hashtagcloud">'+htmlHashTagCloud(baseDir,actor)+'</p>'
|
followStr+=' <p class="hashtagswarm">'+htmlHashTagSwarm(baseDir,actor)+'</p>'
|
||||||
followStr+=' </center>'
|
followStr+=' </center>'
|
||||||
followStr+=' </div>'
|
followStr+=' </div>'
|
||||||
followStr+='</div>'
|
followStr+='</div>'
|
||||||
|
|
Loading…
Reference in New Issue