This repository has been archived by the owner on Nov 14, 2019. It is now read-only.
forked from oliverschwendener/ueli
-
Notifications
You must be signed in to change notification settings - Fork 5
/
Copy pathmain.html
174 lines (165 loc) · 7.55 KB
/
main.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
<!DOCTYPE html>
<html lang="de">
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no">
<title>ueli</title>
</head>
<body>
<div id="vue-root">
<link rel="stylesheet" :href="stylesheetPath">
<link rel="stylesheet" :href="customStyleSheet">
<div class="container">
<div id="acrylic">
<img :src="screenshotFile"></img>
<div id="noise"></div>
</div>
<div
class="user-input-container"
:style="userInputContainerStyle()"
:class="{ 'active': commandLineOutput.length !== 0 || searchResults.length !== 0 || musicPlayer.playerConnectStatus }"
>
<div
id="scopes-container"
v-for="scope in scopes"
>
<span
class="scope"
>
{{ scope }}
</span>
</div>
<input
id="user-input"
class="user-input"
type="text" v-model="userInput"
:autofocus="{ 'autofocus' : autoFocus }"
v-on:keyDown="handleKeyPress"
>
<div
class="search-icon-container"
:class="{ 'hidden': notifying }"
style="-webkit-app-region: drag;"
:style="searchResultWidth()"
>
<svg viewBox="0 0 32 32" v-html="searchIcon"></svg>
</div>
<div
class="notify-icon-container"
:class="{ 'hidden': !notifying }"
:style="searchResultWidth()"
>
<svg viewBox="0 0 32 32" v-html="notifyIcon"></svg>
</div>
</div>
<div
class="output-container"
:style="outputContainerHeight()"
:class="{ 'musicActive' : commandLineOutput.length === 0 && searchResults.length === 0 && musicPlayer.playerConnectStatus }"
>
<div
id="music-info-container"
:class="{ 'hidden' : commandLineOutput.length !== 0 || searchResults.length !== 0 || !musicPlayer.playerConnectStatus }"
>
<div id="blur-background" :class="{ 'small': musicPlayer.smallSize }" :style="{ 'background-image' : musicPlayer.albumCover}"></div>
<div id="player" :class="{ 'small': musicPlayer.smallSize }">
<div id="cover-container">
<div id="album-cover" :style="{ 'background-image' : musicPlayer.albumCover}"></div>
<div id="like-track" :class="{ 'liked': musicPlayer.liked }" v-on:click="likeTrack"></div>
</div>
<div id="player-container">
<div id="player-control">
<div class="icon previous-track" v-on:click="previousTrack"></div>
<div class="icon next-track" v-on:click="nextTrack"></div>
<div
class="play-pause"
:class="{ 'play': !musicPlayer.state, 'pause' : musicPlayer.state }"
v-on:click="playPauseTrack"
></div>
</div>
<div class="spacer"></div>
<div id="player-info">
<div class="title">{{ musicPlayer.track }}</div>
<div class="artist">{{ musicPlayer.artist }}</div>
</div>
</div>
</div>
</div>
<div
class="command-line-output-container"
:class="{ 'hidden' : commandLineOutput.length === 0 }"
>
<pre v-for="line in commandLineOutput">{{ line }}</pre>
</div>
<div
class="search-results-container"
:class="{ 'hidden' : searchResults.length === 0}"
v-on:mousemove="handleMouseMove"
>
<div
:id="'search-result-item-' + searchResult.id"
class="search-result"
:class="{ 'active' : searchResult.active }"
:style="searchResultHeight()"
v-for="(searchResult, searchIndex) in searchResults"
v-on:mouseover="handleMouseOver(searchIndex)"
v-on:click="handleClick"
@contextmenu.prevent="handleRightClick(searchIndex)"
>
<div class="search-result-icon">
<div
class="search-result-icon-container"
:class="{ 'active' : searchResult.active }"
:style="searchResultIconStyle()"
>
<svg
xmlns="http://www.w3.org/2000/svg"
width="100%"
height="100%"
viewBox="0 0 32 32"
v-html="searchResult.icon"
></svg>
</div>
</div>
<div
class="search-result-index-num"
v-if="searchResult.id <= 9"
:class="{ 'active': showIndexNum}"
>
<span
v-html="(searchResult.id + 1) % 10"
>
</span>
</div>
<div class="search-result-information">
<div class="search-result-header-container">
<span
class="search-result-alternative-prefix"
:class="{ 'active' : (searchResult.active || showIndexNum) && searchResult.alternativePrefix && showAlternativePrefix }"
v-html="searchResult.alternativePrefix"
>
</span>
<span
class="search-result-name"
:class="{ 'active' : searchResult.active }"
v-html="searchResult.name"
>
</span>
</div>
<span
class="search-result-execution-argument"
:class="{ 'active' : searchResult.active } "
v-html="searchResult.description"
>
</span>
</div>
</div>
</div>
</div>
</div>
</div>
<script>
require('./bundle/renderer.js');
</script>
</body>
</html>