diff --git a/Makefile b/Makefile index cb801f2..1109956 100644 --- a/Makefile +++ b/Makefile @@ -1,6 +1,6 @@ LESS := $(shell npm bin)/lessc APP := app -CSS := $(APP)/app.css +CSS := $(APP)/cyp.css ICONS := $(APP)/js/lib/icons.js SYSD_USER := ~/.config/systemd/user SERVICE := cyp.service @@ -12,8 +12,8 @@ icons: $(ICONS) $(ICONS): $(APP)/icons/* $(APP)/svg2js.sh $(APP)/icons > $@ -$(CSS): $(APP)/css/* - $(LESS) $(APP)/css/app.less > $@ +$(CSS): $(APP)/css/* $(APP)/css/elements/* + $(LESS) $(APP)/css/cyp.less > $@ service: $(SERVICE) systemctl --user enable $(PWD)/$(SERVICE) diff --git a/app/css/commands.less b/app/css/commands.less deleted file mode 100644 index e69de29..0000000 diff --git a/app/css/app.less b/app/css/cyp.less similarity index 68% rename from app/css/app.less rename to app/css/cyp.less index 47b99db..2c2f3d4 100644 --- a/app/css/app.less +++ b/app/css/cyp.less @@ -13,21 +13,6 @@ main { overflow: auto; } -cyp-app { - .flex-column; - - box-sizing: border-box; - font-family: lato, sans-serif; - line-height: 1.25; - background-color: var(--bg); - color: var(--fg); - text-shadow: var(--text-shadow); - max-width: 800px; - margin: 0 auto; - overflow: hidden; - height: 100vh; -} - header, footer { flex-shrink: 0; z-index: 1; @@ -73,18 +58,20 @@ select { @import "font.less"; @import "icons.less"; @import "mixins.less"; -@import "range.less"; -@import "player.less"; @import "component.less"; -@import "queue.less"; @import "library.less"; @import "fs.less"; -@import "playlists.less"; -@import "yt.less"; -@import "settings.less"; @import "search.less"; @import "art.less"; @import "variables.less"; -@import "song.less"; -@import "menu.less"; +@import "elements/app.less"; +@import "elements/menu.less"; +@import "elements/song.less"; +@import "elements/player.less"; +@import "elements/playlists.less"; +@import "elements/queue.less"; +@import "elements/settings.less"; +@import "elements/yt.less"; +@import "elements/range.less"; +@import "elements/playlist.less"; diff --git a/app/css/elements/app.less b/app/css/elements/app.less new file mode 100644 index 0000000..321e864 --- /dev/null +++ b/app/css/elements/app.less @@ -0,0 +1,14 @@ +cyp-app { + .flex-column; + + box-sizing: border-box; + font-family: lato, sans-serif; + line-height: 1.25; + background-color: var(--bg); + color: var(--fg); + text-shadow: var(--text-shadow); + max-width: 800px; + margin: 0 auto; + overflow: hidden; + height: 100vh; +} diff --git a/app/css/menu.less b/app/css/elements/menu.less similarity index 100% rename from app/css/menu.less rename to app/css/elements/menu.less diff --git a/app/css/player.less b/app/css/elements/player.less similarity index 100% rename from app/css/player.less rename to app/css/elements/player.less diff --git a/app/css/elements/playlist.less b/app/css/elements/playlist.less new file mode 100644 index 0000000..6cc20df --- /dev/null +++ b/app/css/elements/playlist.less @@ -0,0 +1,9 @@ +cyp-playlist { + .flex-row; + + padding: 8px; + + &:nth-child(odd) { + background-color: var(--bg-alt); + } +} diff --git a/app/css/playlists.less b/app/css/elements/playlists.less similarity index 100% rename from app/css/playlists.less rename to app/css/elements/playlists.less diff --git a/app/css/queue.less b/app/css/elements/queue.less similarity index 78% rename from app/css/queue.less rename to app/css/elements/queue.less index b2299f8..50f01d2 100644 --- a/app/css/queue.less +++ b/app/css/elements/queue.less @@ -1,5 +1,3 @@ cyp-queue { - .component; - .current { color: var(--primary); } } diff --git a/app/css/elements/range.less b/app/css/elements/range.less new file mode 120000 index 0000000..6d34d2c --- /dev/null +++ b/app/css/elements/range.less @@ -0,0 +1 @@ +../../../node_modules/custom-range/range.less \ No newline at end of file diff --git a/app/css/settings.less b/app/css/elements/settings.less similarity index 100% rename from app/css/settings.less rename to app/css/elements/settings.less diff --git a/app/css/song.less b/app/css/elements/song.less similarity index 93% rename from app/css/song.less rename to app/css/elements/song.less index c653445..a187253 100644 --- a/app/css/song.less +++ b/app/css/elements/song.less @@ -2,7 +2,7 @@ cyp-song { .selectable; .flex-row; - .info { + .info { // FIXME zrevidovat flex-grow: 1; overflow: hidden; diff --git a/app/css/yt.less b/app/css/elements/yt.less similarity index 100% rename from app/css/yt.less rename to app/css/elements/yt.less diff --git a/app/css/main.less b/app/css/main.less deleted file mode 100644 index e69de29..0000000 diff --git a/app/css/range.less b/app/css/range.less deleted file mode 120000 index cf33e2d..0000000 --- a/app/css/range.less +++ /dev/null @@ -1 +0,0 @@ -../../node_modules/custom-range/range.less \ No newline at end of file diff --git a/app/app.css b/app/cyp.css similarity index 94% rename from app/app.css rename to app/cyp.css index 0c44f8b..7eea054 100644 --- a/app/app.css +++ b/app/cyp.css @@ -13,22 +13,6 @@ main { flex-grow: 1; overflow: auto; } -cyp-app { - flex-direction: column; - box-sizing: border-box; - font-family: lato, sans-serif; - line-height: 1.25; - background-color: var(--bg); - color: var(--fg); - text-shadow: var(--text-shadow); - max-width: 800px; - margin: 0 auto; - overflow: hidden; - height: 100vh; -} -cyp-app:not([hidden]) { - display: flex; -} header, footer { flex-shrink: 0; @@ -128,186 +112,6 @@ select { .selectable.selected { border-left-color: var(--primary); } -x-range { - --thumb-size: 8px; - --thumb-color: #fff; - --thumb-shadow: #000; - --thumb-hover-color: #ddd; - --track-size: 4px; - --track-color: #888; - --track-shadow: #000; - --elapsed-color: #ddd; - --remaining-color: transparent; - --radius: calc(var(--track-size)/2); - display: inline-block; - position: relative; - width: 192px; - height: 16px; -} -x-range .-track, -x-range .-elapsed, -x-range .-remaining { - position: absolute; - top: calc(50% - var(--track-size)/2); - height: var(--track-size); - border-radius: var(--radius); -} -x-range .-track { - width: 100%; - left: 0; - background-color: var(--track-color); - box-shadow: 0 0 1px var(--thumb-shadow); -} -x-range .-elapsed { - left: 0; - background-color: var(--elapsed-color); -} -x-range .-remaining { - right: 0; - background-color: var(--remaining-color); -} -x-range .-inner { - position: absolute; - left: var(--thumb-size); - right: var(--thumb-size); - top: 0; - bottom: 0; -} -x-range .-thumb { - all: unset; - position: absolute; - top: 50%; - transform: translate(-50%, -50%); - border-radius: 50%; - width: calc(2*var(--thumb-size)); - height: calc(2*var(--thumb-size)); - background-color: var(--thumb-color); - box-shadow: 0 0 2px var(--thumb-shadow); -} -x-range[disabled] { - opacity: 0.5; -} -x-range:not([disabled]) .-thumb:hover { - background-color: var(--thumb-hover-color); -} -cyp-player { - flex-direction: row; - align-items: center; - align-items: stretch; -} -cyp-player:not([hidden]) { - display: flex; -} -cyp-player:not([data-state=play]) .pause { - display: none; -} -cyp-player[data-state=play] .play { - display: none; -} -cyp-player:not([data-flags~=random]) .random, -cyp-player:not([data-flags~=repeat]) .repeat { - opacity: 0.5; -} -cyp-player x-range { - flex-grow: 1; - --elapsed-color: var(--primary); -} -cyp-player .art { - margin-right: 0; - height: 96px; -} -cyp-player .art img, -cyp-player .art .icon { - width: 96px; -} -cyp-player .info { - flex-grow: 2; - flex-basis: 0; - padding: 0 var(--icon-spacing); - overflow: hidden; - flex-direction: column; - justify-content: space-around; -} -cyp-player .info:not([hidden]) { - display: flex; -} -cyp-player .info h2 { - font-size: 125%; - margin: 0; -} -cyp-player .info .title, -cyp-player .info .subtitle { - white-space: nowrap; - overflow: hidden; - text-overflow: ellipsis; -} -cyp-player .timeline { - flex-direction: row; - align-items: center; -} -cyp-player .timeline:not([hidden]) { - display: flex; -} -cyp-player .timeline .duration, -cyp-player .timeline .elapsed { - flex-basis: 5ch; - text-align: center; -} -cyp-player .controls { - flex-grow: 1; - flex-basis: 0; - max-width: 220px; - flex-direction: column; - justify-content: space-around; -} -cyp-player .controls:not([hidden]) { - display: flex; -} -cyp-player .controls .playback { - flex-direction: row; - align-items: center; - justify-content: space-around; -} -cyp-player .controls .playback:not([hidden]) { - display: flex; -} -cyp-player .controls .playback .icon { - width: 40px; -} -cyp-player .controls .playback .icon-play, -cyp-player .controls .playback .icon-pause { - width: 64px; -} -cyp-player .controls .volume { - flex-direction: row; - align-items: center; -} -cyp-player .controls .volume:not([hidden]) { - display: flex; -} -cyp-player .controls .volume .mute { - margin-right: 4px; -} -cyp-player .misc { - display: flex; - flex-direction: column; - align-self: stretch; - justify-content: space-around; -} -cyp-player .misc .icon { - width: 32px; -} -@media (max-width: 519px) { - cyp-player { - flex-wrap: wrap; - justify-content: space-between; - } - cyp-player .info { - order: 1; - flex-basis: 100%; - height: 96px; - } -} .component header { flex-direction: row; align-items: center; @@ -366,67 +170,6 @@ cyp-player .misc .icon { .component li:nth-child(odd) { background-color: var(--bg-alt); } -cyp-queue header { - flex-direction: row; - align-items: center; - padding: var(--spacing); -} -cyp-queue header:not([hidden]) { - display: flex; -} -cyp-queue header button { - font-size: var(--font-size-large); - font-weight: bold; - overflow: hidden; -} -cyp-queue header button .icon { - margin-right: var(--icon-spacing); -} -cyp-queue ul { - flex-grow: 1; - overflow: auto; - list-style: none; - margin: 0; - padding: 0; -} -cyp-queue li { - flex-direction: row; - align-items: center; -} -cyp-queue li:not([hidden]) { - display: flex; -} -cyp-queue li .info { - flex-grow: 1; - overflow: hidden; -} -cyp-queue li .info .icon { - color: var(--primary); - margin-right: var(--icon-spacing); - filter: drop-shadow(var(--text-shadow)); -} -cyp-queue li .info h2 { - font-size: var(--font-size-large); - margin: 0; -} -cyp-queue li .info h2, -cyp-queue li .info div { - white-space: nowrap; - overflow: hidden; - text-overflow: ellipsis; -} -cyp-queue li:not(.has-art) { - padding: 8px; -} -cyp-queue li button .icon { - width: 32px; -} -cyp-queue li:nth-child(odd) { - background-color: var(--bg-alt); -} -cyp-queue .current { - color: var(--primary); -} #library header { flex-direction: row; align-items: center; @@ -602,6 +345,323 @@ cyp-queue .current { #fs .info h2 { font-weight: normal; } +.search { + flex-direction: row; + align-items: center; + margin-left: auto; + transition: all 300ms; + width: 32px; + max-width: 20ch; +} +.search:not([hidden]) { + display: flex; +} +.search .icon { + width: 32px; + cursor: pointer; +} +.search input { + border: none; + outline: none; + color: inherit; + background-color: inherit; + border-bottom: 1px solid var(--fg); + width: 0; + padding: 0; + flex-grow: 1; +} +.search.open { + flex: 1; +} +.art { + margin-right: var(--icon-spacing); +} +.art .icon, +.art img { + vertical-align: top; +} +cyp-app { + --font-size-large: 112.5%; + --icon-spacing: 4px; + --primary: rgb(var(--primary-raw)); + --spacing: 8px; + --box-shadow: 0 0 3px #000; +} +cyp-app[theme=light] { + --fg: #333; + --bg: #f0f0f0; + --bg-alt: #e0e0e0; + --text-shadow: none; +} +cyp-app[theme=dark] { + --fg: #f0f0f0; + --bg: #333; + --bg-alt: #555; + --text-shadow: 0 1px 1px rgba(0, 0, 0, 0.8); +} +@media (prefers-color-scheme: dark) { + cyp-app[theme=auto] { + --fg: #f0f0f0; + --bg: #333; + --bg-alt: #555; + --text-shadow: 0 1px 1px rgba(0, 0, 0, 0.8); + } +} +@media (prefers-color-scheme: light) { + cyp-app[theme=auto] { + --fg: #333; + --bg: #f0f0f0; + --bg-alt: #e0e0e0; + --text-shadow: none; + } +} +cyp-app[color=dodgerblue] { + --primary-raw: 30, 144, 255; +} +cyp-app[color=darkorange] { + --primary-raw: 255, 140, 0; +} +cyp-app[color=limegreen] { + --primary-raw: 50, 205, 50; +} +@media (max-width: 480px) { + :root { + --spacing: var(--icon-spacing); + } +} +cyp-app { + flex-direction: column; + box-sizing: border-box; + font-family: lato, sans-serif; + line-height: 1.25; + background-color: var(--bg); + color: var(--fg); + text-shadow: var(--text-shadow); + max-width: 800px; + margin: 0 auto; + overflow: hidden; + height: 100vh; +} +cyp-app:not([hidden]) { + display: flex; +} +cyp-menu, +cyp-commands { + flex-direction: row; + align-items: center; + height: 100%; +} +cyp-menu:not([hidden]), +cyp-commands:not([hidden]) { + display: flex; +} +cyp-menu button, +cyp-commands button { + height: 100%; + flex-direction: column; + align-items: center; + justify-content: center; +} +cyp-menu button:not([hidden]), +cyp-commands button:not([hidden]) { + display: flex; +} +@media (max-width: 480px) { + cyp-menu button, + cyp-commands button { + flex-direction: row; + } + cyp-menu button span:not([id]), + cyp-commands button span:not([id]) { + display: none; + } +} +cyp-menu button { + flex: 1 0 0; + border-top: 4px solid transparent; + border-bottom: 4px solid transparent; +} +cyp-menu button .icon { + margin-right: var(--icon-spacing); +} +cyp-menu button.active { + border-top-color: var(--primary); + color: var(--primary); + background-color: rgb(var(--primary-raw), 0.1); +} +cyp-commands { + position: absolute; + left: 0; + top: 0; + width: 100%; + transition: top 300ms; + background-color: var(--bg); +} +cyp-commands[hidden] { + display: flex; + top: 100%; +} +cyp-commands button { + flex: 0 0 80px; +} +cyp-commands button.last { + order: 1; + margin-left: auto; +} +cyp-song { + border-left: 4px solid transparent; + flex-direction: row; + align-items: center; +} +cyp-song.selected { + border-left-color: var(--primary); +} +cyp-song:not([hidden]) { + display: flex; +} +cyp-song .info { + flex-grow: 1; + overflow: hidden; +} +cyp-song .info .icon { + color: var(--primary); + margin-right: var(--icon-spacing); + filter: drop-shadow(var(--text-shadow)); +} +cyp-song .info h2 { + font-size: var(--font-size-large); + margin: 0; +} +cyp-song .info h2, +cyp-song .info div { + white-space: nowrap; + overflow: hidden; + text-overflow: ellipsis; +} +cyp-song:nth-child(odd) { + background-color: var(--bg-alt); +} +cyp-song:not(.has-art) { + padding: 8px; +} +cyp-player { + flex-direction: row; + align-items: center; + align-items: stretch; +} +cyp-player:not([hidden]) { + display: flex; +} +cyp-player:not([data-state=play]) .pause { + display: none; +} +cyp-player[data-state=play] .play { + display: none; +} +cyp-player:not([data-flags~=random]) .random, +cyp-player:not([data-flags~=repeat]) .repeat { + opacity: 0.5; +} +cyp-player x-range { + flex-grow: 1; + --elapsed-color: var(--primary); +} +cyp-player .art { + margin-right: 0; + height: 96px; +} +cyp-player .art img, +cyp-player .art .icon { + width: 96px; +} +cyp-player .info { + flex-grow: 2; + flex-basis: 0; + padding: 0 var(--icon-spacing); + overflow: hidden; + flex-direction: column; + justify-content: space-around; +} +cyp-player .info:not([hidden]) { + display: flex; +} +cyp-player .info h2 { + font-size: 125%; + margin: 0; +} +cyp-player .info .title, +cyp-player .info .subtitle { + white-space: nowrap; + overflow: hidden; + text-overflow: ellipsis; +} +cyp-player .timeline { + flex-direction: row; + align-items: center; +} +cyp-player .timeline:not([hidden]) { + display: flex; +} +cyp-player .timeline .duration, +cyp-player .timeline .elapsed { + flex-basis: 5ch; + text-align: center; +} +cyp-player .controls { + flex-grow: 1; + flex-basis: 0; + max-width: 220px; + flex-direction: column; + justify-content: space-around; +} +cyp-player .controls:not([hidden]) { + display: flex; +} +cyp-player .controls .playback { + flex-direction: row; + align-items: center; + justify-content: space-around; +} +cyp-player .controls .playback:not([hidden]) { + display: flex; +} +cyp-player .controls .playback .icon { + width: 40px; +} +cyp-player .controls .playback .icon-play, +cyp-player .controls .playback .icon-pause { + width: 64px; +} +cyp-player .controls .volume { + flex-direction: row; + align-items: center; +} +cyp-player .controls .volume:not([hidden]) { + display: flex; +} +cyp-player .controls .volume .mute { + margin-right: 4px; +} +cyp-player .misc { + display: flex; + flex-direction: column; + align-self: stretch; + justify-content: space-around; +} +cyp-player .misc .icon { + width: 32px; +} +@media (max-width: 519px) { + cyp-player { + flex-wrap: wrap; + justify-content: space-between; + } + cyp-player .info { + order: 1; + flex-basis: 100%; + height: 96px; + } +} cyp-playlists header { flex-direction: row; align-items: center; @@ -670,6 +730,41 @@ cyp-playlists .info:not([hidden]) { cyp-playlists .info h2 { font-weight: normal; } +cyp-queue .current { + color: var(--primary); +} +cyp-settings { + font-size: var(--font-size-large); +} +cyp-settings dl { + margin: var(--spacing); + display: grid; + grid-template-columns: max-content 1fr; + align-items: center; + grid-gap: var(--spacing); +} +cyp-settings dt { + font-weight: bold; +} +cyp-settings dd { + margin: 0; + flex-direction: column; + align-items: start; +} +cyp-settings dd:not([hidden]) { + display: flex; +} +cyp-settings label { + flex-direction: row; + align-items: center; +} +cyp-settings label:not([hidden]) { + display: flex; +} +cyp-settings label [type=radio], +cyp-settings label [type=checkbox] { + margin: 0 4px 0 0; +} cyp-yt header { flex-direction: row; align-items: center; @@ -757,218 +852,76 @@ cyp-yt.pending header { background-position: 100% 100%; } } -cyp-settings { - font-size: var(--font-size-large); +x-range { + --thumb-size: 8px; + --thumb-color: #fff; + --thumb-shadow: #000; + --thumb-hover-color: #ddd; + --track-size: 4px; + --track-color: #888; + --track-shadow: #000; + --elapsed-color: #ddd; + --remaining-color: transparent; + --radius: calc(var(--track-size)/2); + display: inline-block; + position: relative; + width: 192px; + height: 16px; } -cyp-settings dl { - margin: var(--spacing); - display: grid; - grid-template-columns: max-content 1fr; - align-items: center; - grid-gap: var(--spacing); +x-range .-track, +x-range .-elapsed, +x-range .-remaining { + position: absolute; + top: calc(50% - var(--track-size)/2); + height: var(--track-size); + border-radius: var(--radius); } -cyp-settings dt { - font-weight: bold; +x-range .-track { + width: 100%; + left: 0; + background-color: var(--track-color); + box-shadow: 0 0 1px var(--thumb-shadow); } -cyp-settings dd { - margin: 0; - flex-direction: column; - align-items: start; +x-range .-elapsed { + left: 0; + background-color: var(--elapsed-color); } -cyp-settings dd:not([hidden]) { - display: flex; +x-range .-remaining { + right: 0; + background-color: var(--remaining-color); } -cyp-settings label { +x-range .-inner { + position: absolute; + left: var(--thumb-size); + right: var(--thumb-size); + top: 0; + bottom: 0; +} +x-range .-thumb { + all: unset; + position: absolute; + top: 50%; + transform: translate(-50%, -50%); + border-radius: 50%; + width: calc(2*var(--thumb-size)); + height: calc(2*var(--thumb-size)); + background-color: var(--thumb-color); + box-shadow: 0 0 2px var(--thumb-shadow); +} +x-range[disabled] { + opacity: 0.5; +} +x-range:not([disabled]) .-thumb:hover { + background-color: var(--thumb-hover-color); +} +cyp-playlist { flex-direction: row; align-items: center; -} -cyp-settings label:not([hidden]) { - display: flex; -} -cyp-settings label [type=radio], -cyp-settings label [type=checkbox] { - margin: 0 4px 0 0; -} -.search { - flex-direction: row; - align-items: center; - margin-left: auto; - transition: all 300ms; - width: 32px; - max-width: 20ch; -} -.search:not([hidden]) { - display: flex; -} -.search .icon { - width: 32px; - cursor: pointer; -} -.search input { - border: none; - outline: none; - color: inherit; - background-color: inherit; - border-bottom: 1px solid var(--fg); - width: 0; - padding: 0; - flex-grow: 1; -} -.search.open { - flex: 1; -} -.art { - margin-right: var(--icon-spacing); -} -.art .icon, -.art img { - vertical-align: top; -} -cyp-app { - --font-size-large: 112.5%; - --icon-spacing: 4px; - --primary: rgb(var(--primary-raw)); - --spacing: 8px; - --box-shadow: 0 0 3px #000; -} -cyp-app[theme=light] { - --fg: #333; - --bg: #f0f0f0; - --bg-alt: #e0e0e0; - --text-shadow: none; -} -cyp-app[theme=dark] { - --fg: #f0f0f0; - --bg: #333; - --bg-alt: #555; - --text-shadow: 0 1px 1px rgba(0, 0, 0, 0.8); -} -@media (prefers-color-scheme: dark) { - cyp-app[theme=auto] { - --fg: #f0f0f0; - --bg: #333; - --bg-alt: #555; - --text-shadow: 0 1px 1px rgba(0, 0, 0, 0.8); - } -} -@media (prefers-color-scheme: light) { - cyp-app[theme=auto] { - --fg: #333; - --bg: #f0f0f0; - --bg-alt: #e0e0e0; - --text-shadow: none; - } -} -cyp-app[color=dodgerblue] { - --primary-raw: 30, 144, 255; -} -cyp-app[color=darkorange] { - --primary-raw: 255, 140, 0; -} -cyp-app[color=limegreen] { - --primary-raw: 50, 205, 50; -} -@media (max-width: 480px) { - :root { - --spacing: var(--icon-spacing); - } -} -cyp-song { - border-left: 4px solid transparent; - flex-direction: row; - align-items: center; -} -cyp-song.selected { - border-left-color: var(--primary); -} -cyp-song:not([hidden]) { - display: flex; -} -cyp-song .info { - flex-grow: 1; - overflow: hidden; -} -cyp-song .info .icon { - color: var(--primary); - margin-right: var(--icon-spacing); - filter: drop-shadow(var(--text-shadow)); -} -cyp-song .info h2 { - font-size: var(--font-size-large); - margin: 0; -} -cyp-song .info h2, -cyp-song .info div { - white-space: nowrap; - overflow: hidden; - text-overflow: ellipsis; -} -cyp-song:nth-child(odd) { - background-color: var(--bg-alt); -} -cyp-song:not(.has-art) { padding: 8px; } -cyp-menu, -cyp-commands { - flex-direction: row; - align-items: center; - height: 100%; -} -cyp-menu:not([hidden]), -cyp-commands:not([hidden]) { +cyp-playlist:not([hidden]) { display: flex; } -cyp-menu button, -cyp-commands button { - height: 100%; - flex-direction: column; - align-items: center; - justify-content: center; -} -cyp-menu button:not([hidden]), -cyp-commands button:not([hidden]) { - display: flex; -} -@media (max-width: 480px) { - cyp-menu button, - cyp-commands button { - flex-direction: row; - } - cyp-menu button span:not([id]), - cyp-commands button span:not([id]) { - display: none; - } -} -cyp-menu button { - flex: 1 0 0; - border-top: 4px solid transparent; - border-bottom: 4px solid transparent; -} -cyp-menu button .icon { - margin-right: var(--icon-spacing); -} -cyp-menu button.active { - border-top-color: var(--primary); - color: var(--primary); - background-color: rgb(var(--primary-raw), 0.1); -} -cyp-commands { - position: absolute; - left: 0; - top: 0; - width: 100%; - transition: top 300ms; - background-color: var(--bg); -} -cyp-commands[hidden] { - display: flex; - top: 100%; -} -cyp-commands button { - flex: 0 0 80px; -} -cyp-commands button.last { - order: 1; - margin-left: auto; +cyp-playlist:nth-child(odd) { + background-color: var(--bg-alt); } diff --git a/app/icons/delete.svg b/app/icons/delete.svg new file mode 100644 index 0000000..f9daefe --- /dev/null +++ b/app/icons/delete.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/app/index.html b/app/index.html index 8e67d55..cb3dd65 100644 --- a/app/index.html +++ b/app/index.html @@ -4,7 +4,7 @@