Merge pull request #305 from kyw504100/Lab1

Irregular update 02/02
This commit is contained in:
cryptofyre 2022-02-02 15:18:48 -06:00 committed by GitHub
commit 7064e0ce84
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
8 changed files with 167 additions and 51 deletions

View file

@ -2784,43 +2784,43 @@ const app = new Vue({
// use switch statement to return friendly name for media types "songs,artists,albums,playlists,music-videos,stations,apple-curators,curators"
switch (type) {
case "song":
return "Songs"
return app.getLz('term.songs')
break;
case "artist":
return "Artists"
return app.getLz('term.artists')
break;
case "album":
return "Albums"
return app.getLz('term.albums')
break;
case "playlist":
return "Playlists"
return app.getLz('term.playlists')
break;
case "music_video":
return "Music Videos"
return app.getLz('term.musicVideos')
break;
case "station":
return "Stations"
return app.getLz('term.stations')
break;
case "apple-curator":
return "Apple Curators"
return app.getLz('term.appleCurators')
break;
case "radio_show":
return "Radio Shows"
return app.getLz('term.radioShows')
break;
case "record_label":
return "Record Labels"
return app.getLz('term.recordLabels')
break;
case "radio_episode":
return "Episodes"
return app.getLz('podcast.episodes')
break;
case "video_extra":
return "Video Extras"
return app.getLz('term.videoExtras')
break;
case "curator":
return "Curators"
return app.getLz('term.curators')
break;
case "top":
return "Top"
return app.getLz('term.top')
break;
default:
return type

View file

@ -2229,6 +2229,7 @@ input[type="range"].web-slider.display--small::-webkit-slider-thumb {
border: 1px solid rgba(100, 100, 100, 0.35);
border-top: 1px solid rgba(100, 100, 100, 0.5);
color: #eee;
white-space: nowrap;
transition: transform 0.2s var(--appleEase), box-shadow 0.2s var(--appleEase);
&.md-btn-block {

View file

@ -258,14 +258,14 @@
items: {
"new": {
"icon": "./assets/feather/plus.svg",
name: "New Preset...",
"name": app.getLz('action.newpreset'),
action: () => {
this.addPreset()
}
},
"delete": {
"icon": "./assets/feather/x-circle.svg",
name: "Delete Preset",
"name": app.getLz('action.deletepreset'),
action: () => {
this.deletePreset()
}
@ -316,13 +316,13 @@
},
deletePreset() {
let presets = this.$root.cfg.audio.equalizer.presets
bootbox.confirm("Are you sure you want to delete this preset?", (result) => {
bootbox.confirm(app.getLz('term.deletepreset.warn'), (result) => {
if (result) {
this.changePreset("default")
// find the preset by id (preset) and remove it
let index = presets.findIndex(p => p.preset == this.preset)
presets.splice(index, 1)
notyf.success("Removed preset")
notyf.success(app.getLz('term.deletedpreset'))
}
})
},
@ -367,7 +367,7 @@
},
addPreset() {
let self = this
bootbox.prompt("New EQ Preset Name", (res) => {
bootbox.prompt(app.getLz('term.newpreset.name'), (res) => {
if (res) {
let eqSettings = Clone(app.cfg.audio.equalizer)
let newPreset = new self.eqPreset()
@ -379,7 +379,7 @@
newPreset.mix = eqSettings.mix
newPreset.vibrantBass = eqSettings.vibrantBass
app.cfg.audio.equalizer.presets.push(newPreset)
notyf.success("Added Preset")
notyf.success(app.getLz('term.addedpreset'))
self.changePreset(newPreset.preset)
}
})