Skip to content

Commit

Permalink
chore: small cleanup
Browse files Browse the repository at this point in the history
  • Loading branch information
Virenbar committed Dec 4, 2024
1 parent c42c33e commit 6bcd73c
Show file tree
Hide file tree
Showing 7 changed files with 378 additions and 938 deletions.
5 changes: 0 additions & 5 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,11 +24,6 @@ jobs:
node-version: 20.x
cache: "yarn"

- name: Set variables
run: |
echo "NUXT_PUBLIC_BRANCH=${GITHUB_HEAD_REF:-${GITHUB_REF#refs/heads/}}" >> "$GITHUB_ENV"
echo "NUXT_PUBLIC_HASH=${GITHUB_SHA}" >> "$GITHUB_ENV"
- name: Build website
run: |
yarn install --immutable --immutable-cache --check-cache
Expand Down
36 changes: 19 additions & 17 deletions app.vue
Original file line number Diff line number Diff line change
@@ -1,27 +1,26 @@
<script setup lang="ts">
const title = "Каналы радио Record";
const description = "Автоматически обновляемый список ссылок на каналы радио Record";
const logo = "https://www.radiorecord.ru/logo300-300.jpg"
useHead({
title,
link: [
{ rel: "icon", type: "image/png", href: "https://www.radiorecord.ru/favicon.ico" }
],
meta: [
{ name: "description", content: description }
],
htmlAttrs: {
"data-bs-theme": "dark"
}
titleTemplate: (chunk) => (chunk ? `${chunk} - ` : "") + title,
link: [{ rel: "icon", type: "image/png", href: "https://www.radiorecord.ru/favicon.ico" }],
meta: [{ name: "description", content: description }],
htmlAttrs: { lang: "ru", "data-bs-theme": "dark" }
});
useServerSeoMeta({
ogType: "website",
ogTitle: title,
useSeoMeta({
description,
ogDescription: description,
ogImage: logo,
ogImageSecureUrl: logo,
ogSiteName: title,
ogTitle: title,
ogType: "website",
ogUrl: "https://virenbar.ru/RadioRecord/",
ogDescription: description,
description,
ogImage: "https://www.radiorecord.ru/logo300-300.jpg",
ogImageSecureUrl: "https://www.radiorecord.ru/logo300-300.jpg"
twitterCard: "summary",
twitterDescription: description,
twitterImage: logo,
twitterTitle: title
});
</script>
<template>
Expand All @@ -33,3 +32,6 @@ useServerSeoMeta({
<PageFooter />
</div>
</template>
<style lang="scss">
@use "~/assets/css/styles.scss";
</style>
2 changes: 2 additions & 0 deletions components/Page/Header.vue
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,8 @@
</header>
</template>
<style scoped lang="scss">
@import "@/assets/css/variables.scss";
.nav-link {
color: $text-night-primary;
transition: all .3s;
Expand Down
2 changes: 2 additions & 0 deletions components/Station/Card.vue
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,8 @@ const S = computed(() => props.station);
<div v-else class="card fake" />
</template>
<style scoped lang="scss">
@import "@/assets/css/variables.scss";

.card {
flex: 1 1 0;
margin: 3px;
Expand Down
16 changes: 2 additions & 14 deletions nuxt.config.ts
Original file line number Diff line number Diff line change
@@ -1,14 +1,11 @@
import { execSync } from "child_process";

const exec = (command: string) => execSync(command).toString().trim();
const branch = exec("git branch --show-current");
const hash = exec("git rev-parse HEAD");
const branch = exec("git branch --show-current") || process.env.HEAD;
const hash = exec("git rev-parse HEAD") || process.env.COMMIT_REF;
const date = new Date().toISOString();

export default defineNuxtConfig({
css: [
"@/assets/css/styles.scss"
],
modules: [
"@nuxt/eslint",
"nuxt-gtag",
Expand All @@ -23,14 +20,5 @@ export default defineNuxtConfig({
hash: hash,
date: date
}
},
vite: {
css: {
preprocessorOptions: {
scss: {
additionalData: "@import \"@/assets/css/variables.scss\";"
}
}
}
}
});
9 changes: 5 additions & 4 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -28,14 +28,15 @@
"@types/lodash-es": "^4.17.12",
"@types/node": "^20.17.6",
"eslint": "^9.14.0",
"nuxt-gtag": "^3.0.1",
"nuxt": "^3.14.1592",
"sass-loader": "^16.0.3",
"nuxt-gtag": "^3.0.1",
"sass": "^1.80.6",
"sass-loader": "^16.0.3",
"tsx": "^4.19.2",
"typescript": "^5.6.3",
"webpack": "^5.96.1"
"vue": "latest",
"vue-router": "latest"
},
"type": "module",
"private": true
}
}
Loading

0 comments on commit 6bcd73c

Please sign in to comment.