diff --git a/epicyon-follow.css b/epicyon-follow.css index 71e2a0ab..b73b9a8c 100644 --- a/epicyon-follow.css +++ b/epicyon-follow.css @@ -66,6 +66,10 @@ a:link { font-weight: bold; } +.searchBanner { + height: 10%; +} + .follow { background-image: url("follow-background.png"); height: 100%; diff --git a/img/search_banner_starlight.png b/img/search_banner_starlight.png new file mode 100644 index 00000000..9c62f11e Binary files /dev/null and b/img/search_banner_starlight.png differ diff --git a/webinterface.py b/webinterface.py index e6081603..c9736fca 100644 --- a/webinterface.py +++ b/webinterface.py @@ -5852,6 +5852,7 @@ def htmlSearch(translate: {}, """Search called from the timeline icon """ actor = path.replace('/search', '') + searchNickname = getNicknameFromActor(actor) domain, port = getDomainFromActor(actor) if os.path.isfile(baseDir + '/img/search-background.png'): @@ -5865,6 +5866,28 @@ def htmlSearch(translate: {}, with open(cssFilename, 'r') as cssFile: profileStyle = cssFile.read() followStr = htmlHeader(cssFilename, profileStyle) + + # show a banner above the search box + searchBannerFilename = \ + baseDir + '/accounts/' + searchNickname + '@' + domain + \ + '/search-banner.png' + if not os.path.isfile(searchBannerFilename): + theme = getConfigParam(baseDir, 'theme').lower() + if theme == 'default': + theme = '' + else: + theme = '_' + theme + themeSearchBannerFilename = \ + baseDir + '/img/search_banner' + theme + '.png' + if os.path.isfile(themeSearchBannerFilename): + copyfile(themeSearchBannerFilename, searchBannerFilename) + if os.path.isfile(searchBannerFilename): + followStr += \ + '
>
' \ + '
' + + # show the search box followStr += '
' followStr += '
' followStr += '
'