diff --git a/.env.example b/.env.example new file mode 100644 index 0000000..ece51f9 --- /dev/null +++ b/.env.example @@ -0,0 +1,24 @@ +# Copy to .env and change values as needed. +# If .env is missing or a key is empty, built-in irandom defaults are used. + +# Branding +# Display name in sidebar / mobile header +VUE_APP_NAME=irandom +# Browser tab title (can differ from NAME) +VUE_APP_TITLE=irandom +# Link on logo + name +VUE_APP_BRAND_URL=https://git.imiheev.online/admin/irandom +# Logo path or absolute URL (file should be in public/ if relative) +VUE_APP_LOGO_URL=/logo.png + +# Theme colors (CSS hex) +VUE_APP_COLOR_PRIMARY=#c9a66b +VUE_APP_COLOR_ACCENT=#e6c566 +VUE_APP_COLOR_BG=#1a1815 +VUE_APP_COLOR_SURFACE=#2e2820 +VUE_APP_COLOR_SURFACE_RAISED=#3a3228 +VUE_APP_COLOR_TEXT=#ffffff +VUE_APP_COLOR_TEXT_MUTED=#c8c0b4 +VUE_APP_COLOR_DANGER=#ee5c5c +VUE_APP_COLOR_LINK=#4a6a8a +VUE_APP_COLOR_BORDER=#4a4034 diff --git a/.gitignore b/.gitignore index 1ea4b0b..e548c97 100644 --- a/.gitignore +++ b/.gitignore @@ -4,6 +4,7 @@ # local env files +.env .env.local .env.*.local diff --git a/package.json b/package.json index 9eb2c39..3ccabe1 100644 --- a/package.json +++ b/package.json @@ -3,6 +3,9 @@ "version": "0.1.0", "private": true, "scripts": { + "generate-config": "node scripts/generate-config.js", + "preserve": "node scripts/generate-config.js", + "prebuild": "node scripts/generate-config.js", "serve": "vue-cli-service serve", "build": "vue-cli-service build", "lint": "vue-cli-service lint" diff --git a/public/config.js b/public/config.js new file mode 100644 index 0000000..87054a4 --- /dev/null +++ b/public/config.js @@ -0,0 +1,19 @@ +/* Generated by scripts/generate-config.js — do not edit by hand */ +window.__APP_CONFIG__ = { + "name": "irandom", + "title": "irandom", + "brandUrl": "https://git.imiheev.online/admin/irandom", + "logoUrl": "/logo.png", + "colors": { + "primary": "#c9a66b", + "accent": "#e6c566", + "bg": "#1a1815", + "surface": "#2e2820", + "surfaceRaised": "#3a3228", + "text": "#ffffff", + "textMuted": "#c8c0b4", + "danger": "#ee5c5c", + "link": "#4a6a8a", + "border": "#4a4034" + } +}; diff --git a/public/index.html b/public/index.html index 61b126b..267a5d4 100644 --- a/public/index.html +++ b/public/index.html @@ -5,7 +5,8 @@ - irandom — простой генератор случайностей + irandom +