feat(global): initialize project and framework structure, dockerize

This commit is contained in:
h
2025-09-02 00:03:50 +03:00
parent 3194237f5f
commit 2e9bfc888f
26 changed files with 422 additions and 113 deletions

View File

@@ -1,5 +1,7 @@
<template>
<div>
Welcome to The SYSTEM
<h1 class="sr-only">The SYSTEM</h1>
<NuxtLoadingIndicator />
<NuxtPage />
</div>
</template>

View File

@@ -0,0 +1,3 @@
@tailwind base;
@tailwind components;
@tailwind utilities;

View File

@@ -0,0 +1,11 @@
/* Base document styles */
html,
body {
height: 100%;
}
body {
color: var(--text-primary);
background-color: var(--bg-dark);
font-family: "Inter", sans-serif;
}

View File

@@ -0,0 +1,8 @@
/* Custom small utilities */
.no-scrollbar {
-ms-overflow-style: none;
scrollbar-width: none;
}
.no-scrollbar::-webkit-scrollbar {
display: none;
}

View File

@@ -0,0 +1,4 @@
$color-primary: #3b82f6;
$color-muted: #6b7280;
$text-primary: #ffffff;
$text-secondary: #e2e8f0;

View File

@@ -0,0 +1,3 @@
@use 'variables';
@use 'base';
@use 'utilities';

View File

@@ -0,0 +1,22 @@
import { mount } from '@vue/test-utils';
import { nextTick } from 'vue';
import PrimeVue from 'primevue/config';
import Button from 'primevue/button';
import Dialog from 'primevue/dialog';
import PrimeButtonDemo from './PrimeButtonDemo.vue';
import { it, expect } from 'vitest';
it('opens dialog on click', async () => {
const wrapper = mount(PrimeButtonDemo, {
attachTo: document.body,
global: {
plugins: [PrimeVue],
components: { Button, Dialog },
},
});
await wrapper.find('button').trigger('click');
await nextTick();
expect(document.body.innerHTML).toContain('PrimeVue is working');
});

View File

@@ -0,0 +1,15 @@
<script setup lang="ts">
import { ref } from 'vue';
const _open = ref(false);
</script>
<template>
<div class="space-y-2">
<Button type="button" label="Open Dialog" @click="_open = true" @keyup.enter="_open = true" />
<Dialog v-model:visible="_open" modal header="Hello" :draggable="false">
<p>PrimeVue is working.</p>
</Dialog>
</div>
</template>

13
app/pages/index.vue Normal file
View File

@@ -0,0 +1,13 @@
<script setup lang="ts">
import PrimeButtonDemo from '@/components/PrimeButtonDemo.vue';
</script>
<template>
<main class="p-6 space-y-4">
<section>
<h2 class="text-xl font-semibold">Welcome</h2>
<p class="text-slate-600">This is the foundation of The SYSTEM.</p>
</section>
<PrimeButtonDemo />
</main>
</template>