style: improve platform/version card in sidebar

This commit is contained in:
Sam Chau
2026-01-20 00:56:51 +10:30
parent ec0db073d2
commit facf391f16
9 changed files with 111 additions and 78 deletions

View File

@@ -45,6 +45,19 @@ jobs:
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}
- name: Determine channel
id: channel
run: |
if [[ "${{ github.ref }}" == "refs/heads/v2" ]]; then
echo "value=develop" >> $GITHUB_OUTPUT
elif [[ "${{ github.ref }}" == refs/tags/v*-beta* ]]; then
echo "value=beta" >> $GITHUB_OUTPUT
elif [[ "${{ github.ref }}" == refs/tags/v* ]]; then
echo "value=stable" >> $GITHUB_OUTPUT
else
echo "value=develop" >> $GITHUB_OUTPUT
fi
- name: Extract metadata
id: meta
uses: docker/metadata-action@v5
@@ -70,6 +83,8 @@ jobs:
push: true
tags: ${{ steps.meta.outputs.tags }}
labels: ${{ steps.meta.outputs.labels }}
build-args: |
VITE_CHANNEL=${{ steps.channel.outputs.value }}
cache-from: type=registry,ref=${{ env.IMAGE_BASE }}/${{ matrix.image }}:buildcache
cache-to: type=registry,ref=${{ env.IMAGE_BASE }}/${{ matrix.image }}:buildcache,mode=max