feat(frontend): добавлены новые SCSS переменные и утилиты

Добавлены новые файлы _variables.scss, _utilities.scss, main.scss, default.vue, index.vue, app.vue
Изменения в package.json, nuxt.config.ts, eslint.config.mjs.
This commit is contained in:
Oscar
2026-03-12 17:42:12 +03:00
parent 10c49bd069
commit 1df836d826
16 changed files with 2802 additions and 39 deletions

View File

@@ -1,6 +1,5 @@
<template>
<div>
<NuxtRouteAnnouncer />
<NuxtWelcome />
</div>
<NuxtLayout>
<NuxtPage />
</NuxtLayout>
</template>

View File

@@ -0,0 +1,140 @@
$indents: 0 2 4 5 6 8 10 12 15 16 18 20 24 25 28 30 32 36 40 48 50 52 60 64;
@each $i in $indents {
.m#{$i} {
margin: #{$i}px;
}
.mx#{$i} {
margin-left: #{$i}px;
margin-right: #{$i}px;
}
.my#{$i} {
margin-top: #{$i}px;
margin-bottom: #{$i}px;
}
.mt#{$i} {
margin-top: #{$i}px;
}
.mb#{$i} {
margin-bottom: #{$i}px;
}
.ml#{$i} {
margin-left: #{$i}px;
}
.mr#{$i} {
margin-right: #{$i}px;
}
.p#{$i} {
padding: #{$i}px;
}
.px#{$i} {
padding-left: #{$i}px;
padding-right: #{$i}px;
}
.py#{$i} {
padding-top: #{$i}px;
padding-bottom: #{$i}px;
}
.pt#{$i} {
padding-top: #{$i}px;
}
.pb#{$i} {
padding-bottom: #{$i}px;
}
.pl#{$i} {
padding-left: #{$i}px;
}
.pr#{$i} {
padding-right: #{$i}px;
}
}
.mla {
margin-left: auto;
}
.mra {
margin-left: auto;
}
.mx-auto {
margin-left: auto;
margin-right: auto;
}
@each $align in ('left', 'right', 'center') {
.text-align-#{$align} {
text-align: #{$align};
}
}
.container {
width: 100%;
max-width: var(--container-max-width, 1248px);
margin: 0 auto;
padding: var(--container-padding, 0 24px);
position: relative;
}
.w-25 { width: 25% !important; }
.w-50 { width: 50% !important; }
.w-75 { width: 75% !important; }
.w-100 { width: 100% !important; }
.d-none { display: none !important; }
.d-inline { display: inline !important; }
.d-inline-block { display: inline-block !important; }
.d-block { display: block !important; }
.d-table { display: table !important; }
.d-table-row { display: table-row !important; }
.d-table-cell { display: table-cell !important; }
.d-flex { display: flex !important; }
.d-inline-flex { display: inline-flex !important; }
.flex-row { flex-direction: row !important; }
.flex-column { flex-direction: column !important; }
.flex-row-reverse { flex-direction: row-reverse !important; }
.flex-column-reverse { flex-direction: column-reverse !important; }
.flex-wrap { flex-wrap: wrap !important; }
.flex-nowrap { flex-wrap: nowrap !important; }
.flex-wrap-reverse { flex-wrap: wrap-reverse !important; }
.justify-content-start { justify-content: flex-start !important; }
.justify-content-end { justify-content: flex-end !important; }
.justify-content-center { justify-content: center !important; }
.justify-content-between { justify-content: space-between !important; }
.justify-content-around { justify-content: space-around !important; }
.align-items-start { align-items: flex-start !important; }
.align-items-end { align-items: flex-end !important; }
.align-items-center { align-items: center !important; }
.align-items-baseline { align-items: baseline !important; }
.align-items-stretch { align-items: stretch !important; }
.align-content-start { align-content: flex-start !important; }
.align-content-end { align-content: flex-end !important; }
.align-content-center { align-content: center !important; }
.align-content-between { align-content: space-between !important; }
.align-content-around { align-content: space-around !important; }
.align-content-stretch { align-content: stretch !important; }
.align-self-auto { align-self: auto !important; }
.align-self-start { align-self: flex-start !important; }
.align-self-end { align-self: flex-end !important; }
.align-self-center { align-self: center !important; }
.align-self-baseline { align-self: baseline !important; }
.align-self-stretch { align-self: stretch !important; }

View File

@@ -0,0 +1,7 @@
$background: #1b1a1f;
$dark: #383838;
$darker: #2b2a2a;
$black: #0a0a0a;
$gray: #616065;
$light: #f4c08c;
$secondary: #0163aa;

View File

@@ -0,0 +1,62 @@
@use "utilities";
@use "variables";
ion-button {
--color: $light;
}
.input-wrapper {
color: white;
}
:root {
--ion-text-color: #ffffff;
--ion-background-color: #383838;
//--ion-backdrop-opacity: 0.95;
--ion-safe-area-right: 0;
--ion-safe-area-left: 0;
--ion-color-dark: #1b1a1f;
.toolbar-container {
--min-height: 100px !important;
min-height: 100px;
}
ion-toggle {
--track-background: #{$secondary};
}
ion-header {
--ion-background-color: red;
}
ion-toolbar {
--ion-toolbar-background: red;
height: 60px;
}
ion-toast {
--background: #2e6edf;
--box-shadow: 3px 3px 10px 0 rgba(0, 0, 0, 0.2);
--color: white;
}
}
body {
h1, h2, h3, h4, h5, h6, p, span, div, ul, li, dl, dt, dd {
margin: 0;
padding: 0;
}
}
.ion-no-pad {
height: 32px;
width: 32px;
margin: 0;
--padding-top: 0;
--padding-start: 0;
--padding-end: 0;
--padding-bottom: 0;
}

View File

@@ -0,0 +1,19 @@
<template>
<div class="default-layout">
<div class="default-layout__content">
<slot />
</div>
</div>
</template>
<script setup lang="ts">
</script>
<style lang="scss">
.default-layout {
&__content {
}
}
</style>

View File

@@ -0,0 +1,15 @@
<template>
<div>
asdasd
</div>
</template>
<script setup lang="ts">
// defineProps<{
//
// }>()
</script>
<style lang="scss">
</style>

View File

@@ -0,0 +1,17 @@
import antfu from '@antfu/eslint-config'
export default antfu({
overrides: [
{
files: ['*.vue'],
},
],
rules: {
'no-console': 0,
'vue/no-deprecated-slot-attribute': 0, // Отключаем это правило
'vue/block-order': ['error', {
order: ['template', 'script', 'style'],
}],
},
})

View File

@@ -1,5 +1,19 @@
// https://nuxt.com/docs/api/configuration/nuxt-config
export default defineNuxtConfig({
compatibilityDate: '2025-07-15',
devtools: { enabled: true }
ssr: false,
modules: ['@nuxt/eslint'],
css: ['~/assets/main.scss'],
devtools: { enabled: true },
vite: {
css: {
preprocessorOptions: {
scss: {
additionalData: `
@use "~/assets/_variables.scss" as *;
`,
},
},
},
},
})

View File

@@ -10,9 +10,20 @@
"postinstall": "nuxt prepare"
},
"dependencies": {
"@primeuix/themes": "^2.0.3",
"nuxt": "^4.3.1",
"primevue": "^4.5.4",
"vue": "^3.5.30",
"@nuxt/eslint": "latest",
"vue-router": "^4.6.4"
},
"packageManager": "yarn@1.22.22+sha512.a6b2f7906b721bba3d67d4aff083df04dad64c399707841b7acf00f6b133b7ac24255f2652fa22ae3534329dc6180534e98d17432037ff6fd140556e2bb3137e"
"packageManager": "yarn@1.22.22+sha512.a6b2f7906b721bba3d67d4aff083df04dad64c399707841b7acf00f6b133b7ac24255f2652fa22ae3534329dc6180534e98d17432037ff6fd140556e2bb3137e",
"devDependencies": {
"@primevue/nuxt-module": "^4.5.4",
"eslint": "latest",
"@antfu/eslint-config": "latest",
"sass": "latest",
"typescript": "latest",
"vue-tsc": "latest"
}
}

File diff suppressed because it is too large Load Diff