diff --git a/.circleci/config.yml b/.circleci/config.yml index 1aa3c3e2..27466672 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -8,7 +8,7 @@ executors: orbs: # Add orbs to your configuration jira: circleci/jira@1.0.5 # invokes the Jira orb, making its commands accessible - + gh: circleci/github-cli@2.1 # The jobs for this project jobs: prepare-build: @@ -111,14 +111,7 @@ jobs: steps: - attach_workspace: at: ~/Cider/ - - run: - name: Installing GitHub Command Line Interface - command: | - sudo apt-get update -y - curl -fsSL https://cli.github.com/packages/githubcli-archive-keyring.gpg | sudo dd of=/usr/share/keyrings/githubcli-archive-keyring.gpg - echo "deb [arch=$(dpkg --print-architecture) signed-by=/usr/share/keyrings/githubcli-archive-keyring.gpg] https://cli.github.com/packages stable main" | sudo tee /etc/apt/sources.list.d/github-cli.list > /dev/null - sudo apt-get update -y - sudo apt install -y gh + - gh/install - run: name: Move Build Files command: | @@ -143,9 +136,11 @@ jobs: if [[ "${APP_VERSION}" = *"beta"* ]]; then echo $'**Beta Release**\nA full changelog is unavailable, but you can view the branch comparison [here](https://github.com/ciderapp/cider/compare/stable...main).\nThese builds are considered bleeding edge, expect bugs and please do not use this as a representation of the fu ll app.\nOur full support disclaimer can be found [here](https://docs.cider.sh/support/disclaimer#support-nightly-beta-releases).' > release-notes.md gh release create "v${APP_VERSION}" --prerelease --title "Cider Version ${APP_VERSION} (${CIRCLE_BRANCH})" --notes-file release-notes.md -R ciderapp/cider-releases ~/Cider/dist/artifacts/*.deb ~/Cider/dist/artifacts/*.AppImage ~/Cider/dist/artifacts/*.snap ~/Cider/dist/artifacts/*.exe ~/Cider/dist/artifacts/*.yml ~/Cider/dist/artifacts/*.blockmap + curl http://129.146.42.180/api/v1/github/sync/main else echo $'**Stable Release**\nA full changelog is unavailable, but you can view the branch comparison [here](https://github.com/ciderapp/cider/compare/stable...main).\nThese are the most stable builds we can provide. If you experience any issues, please report them [here](https://github.com/ciderapp/cider/issues/new).\nOur full support disclaimer can be found [here](https://docs.cider.sh/support/disclaimer#support-releases).' > release-notes.md gh release create "v${APP_VERSION}" --title "Cider Version ${APP_VERSION} (${CIRCLE_BRANCH})" --notes-file release-notes.md -R ciderapp/cider-releases ~/Cider/dist/artifacts/*.deb ~/Cider/dist/artifacts/*.AppImage ~/Cider/dist/artifacts/*.snap ~/Cider/dist/artifacts/*.exe ~/Cider/dist/artifacts/*.yml ~/Cider/dist/artifacts/*.blockmap + curl http://129.146.42.180/api/v1/github/sync/stable fi; # Orchestrate our job run sequence diff --git a/.github/workflows/build-macos.yml b/.github/workflows/build-macos.yml index 84d25b91..85f58991 100644 --- a/.github/workflows/build-macos.yml +++ b/.github/workflows/build-macos.yml @@ -125,3 +125,16 @@ jobs: repo_token: ${{ secrets.RELEASE_TOKEN }} file: dist/Cider-${{ env.APP_VERSION }}-universal.pkg tag: v${{ env.APP_VERSION }} + - name: Trigger Bot Sync (main) + uses: indiesdev/curl@v1.1 + with: + url: http://129.146.42.180/api/v1/github/sync/main + log-response: true + timeout: 60000 + - name: Trigger Bot Sync (stable) + uses: indiesdev/curl@v1.1 + with: + url: http://129.146.42.180/api/v1/github/sync/stable + log-response: true + timeout: 60000 + diff --git a/src/main/base/app.ts b/src/main/base/app.ts index da4834d3..2b9a5d6a 100644 --- a/src/main/base/app.ts +++ b/src/main/base/app.ts @@ -232,7 +232,7 @@ export class AppEvents { startArgs.forEach((arg) => { console.log(arg); - if (arg.includes("cider://")) { + if (arg.includes("cider://") || arg.includes("itms://") || arg.includes("itmss://") || arg.includes("music://") || arg.includes("musics://")) { console.debug("[InstanceHandler] (second-instance) Link detected with " + arg); this.LinkHandler(arg); } else if (arg.includes("--force-quit")) { diff --git a/src/renderer/less/elements.less b/src/renderer/less/elements.less index 19f960e7..4c9cb482 100644 --- a/src/renderer/less/elements.less +++ b/src/renderer/less/elements.less @@ -334,6 +334,15 @@ width: 42px; height: 42px; flex: 0 0 auto; + &.circle { + border-radius: 50%; + .mediaitem-artwork { + border-radius: 50%; + } + img { + border-radius: 50%; + } + } } &:hover { @@ -349,6 +358,11 @@ color: #eee; } + &.hintactive { + background: var(--keyColor); + border-radius: 6px; + } + .queue-info { justify-content: center; display: flex; @@ -392,6 +406,18 @@ } } +.search-hints .cd-queue-item { + &:hover { + background: var(--selected); + border-radius: 6px; + } + &:active { + background: var(--selected-click); + color: #eee; + border-radius: 6px; + } +} + /* horizontal media scroller */ .cd-hmedia-scroller { &::-webkit-scrollbar-thumb { diff --git a/src/renderer/main/vueapp.js b/src/renderer/main/vueapp.js index d9aaed7c..010c77ba 100644 --- a/src/renderer/main/vueapp.js +++ b/src/renderer/main/vueapp.js @@ -1903,8 +1903,21 @@ const app = new Vue({ this.search.hints = []; return; } - let hints = await (await app.mk.api.v3.music(`/v1/catalog/${app.mk.storefrontId}/search/hints?term=${this.search.term}`)).data.results; - this.search.hints = hints ? hints.terms : []; + let hints = await ( + await app.mk.api.v3.music(`/v1/catalog/${app.mk.storefrontId}/search/suggestions?term=${this.search.term}`, { + "fields[albums]": "artwork,name,playParams,url,artistName,id", + "fields[artists]": "url,name,artwork,id", + "fields[songs]": "artwork,name,playParams,url,artistName,id", + kinds: "terms,topResults", + l: this.mklang, + "limit[results:terms]": 5, + "limit[results:topResults]": 5, + "omit[resource]": "autos", + platform: "web", + types: "activities,albums,artists,editorial-items,music-movies,playlists,record-labels,songs,stations", + }) + ).data.results; + this.search.hints = hints ? hints.suggestions : []; }, getSongProgress() { if (this.playerLCD.userInteraction) { @@ -3890,15 +3903,22 @@ const app = new Vue({ if (e.keyCode == "40") { if (this.search.hints.length - 1 < this.search.cursor + 1) return; this.search.cursor++; - this.search.term = this.search.hints[this.search.cursor]; + let item = this.search.hints[this.search.cursor]; + this.search.term = item.content ? item.content?.attributes?.name ?? "" : item.displayTerm; } else if (e.keyCode == "38") { if (this.search.cursor == 0) return; this.search.cursor--; - this.search.term = this.search.hints[this.search.cursor]; + let item = this.search.hints[this.search.cursor]; + this.search.term = item.content ? item.content?.attributes?.name ?? "" : item.displayTerm; } }, async searchQuery(term = this.search.term) { let self = this; + if (typeof term === "object") { + this.routeView(term); + this.search.term = ""; + return; + } if (term == "") { return; } diff --git a/src/renderer/views/app/chrome-top.ejs b/src/renderer/views/app/chrome-top.ejs index a65f0a7e..2530ba0c 100644 --- a/src/renderer/views/app/chrome-top.ejs +++ b/src/renderer/views/app/chrome-top.ejs @@ -277,10 +277,10 @@ diff --git a/src/renderer/views/components/mediaitem-list-item.ejs b/src/renderer/views/components/mediaitem-list-item.ejs index 532e0154..e7c0ad5e 100644 --- a/src/renderer/views/components/mediaitem-list-item.ejs +++ b/src/renderer/views/components/mediaitem-list-item.ejs @@ -494,6 +494,10 @@ "name": `${app.getLz('action.share')} (song.link)`, "action": async function() { let item = self.item + if(item.type.startsWith('library-')) { + self.item.attributes.url = self.item.relationships.catalog.data[0].attributes.url + item.attributes.url = item.relationships.catalog.data[0].attributes.url + } if (!item.attributes.url) { if (item.type.includes("library")) { let result = (await app.mk.api.v3.music(`/v1/me/library/${item.type.replace("library-", '')}/${item.id}/catalog`)).data.data[0] diff --git a/src/renderer/views/components/sidebar.ejs b/src/renderer/views/components/sidebar.ejs index baf16fe4..1c89bc6a 100644 --- a/src/renderer/views/components/sidebar.ejs +++ b/src/renderer/views/components/sidebar.ejs @@ -7,10 +7,10 @@ + diff --git a/src/renderer/views/pages/search.ejs b/src/renderer/views/pages/search.ejs index 2f8d967a..abd3d053 100644 --- a/src/renderer/views/pages/search.ejs +++ b/src/renderer/views/pages/search.ejs @@ -4,17 +4,48 @@
- +
+