Skip to content

Commit

Permalink
Updated to latest nuxt and primevue modules.
Browse files Browse the repository at this point in the history
  • Loading branch information
rizen committed Jan 21, 2025
1 parent 0c3dcc8 commit 58f6fda
Show file tree
Hide file tree
Showing 15 changed files with 7,190 additions and 6,946 deletions.
File renamed without changes.
4 changes: 2 additions & 2 deletions app/pages/cronjobs/index.vue
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@
<Pager :kind="cronjobs" />
</PanelZone>
<PanelZone title="Create Cron Job">
<Form :send="() => cronjobs.create()">
<VForm :send="() => cronjobs.create()">

<FormInput name="schedule" type="text" v-model="cronjobs.new.schedule" required label="Schedule" class="mb-4" />
<FormInput name="handler" type="select" v-model="cronjobs.new.handler" :options="cronjobs.propsOptions?.handler" required label="Handler" class="mb-4" />
Expand All @@ -37,7 +37,7 @@
<Icon name="ph:plus" class="mr-1"/> Create Cron Job
</Button>
</div>
</Form>
</VForm>
</PanelZone>
</template>
</PanelFrame>
Expand Down
4 changes: 2 additions & 2 deletions app/pages/users/[id]/reset-password.vue
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
</NuxtLink>
</div>
<PanelZone>
<Form :send="resetPassword">
<VForm :send="resetPassword">
<div class="flex gap-5 flex-col-reverse md:flex-row">
<div class="flex-auto">
<FormInput name="code" type="text" v-model="newPassword.code" required readonly
Expand All @@ -28,7 +28,7 @@
</div>

</div>
</Form>
</VForm>
</PanelZone>
</div>
</template>
Expand Down
4 changes: 2 additions & 2 deletions app/pages/users/admin/index.vue
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@
</PanelZone>
<PanelZone title="Create User">

<Form :send="() => users.create()">
<VForm :send="() => users.create()">

<FormInput name="nausernameme" type="text" v-model="users.new.username" required
label="Username" class="mb-4" />
Expand All @@ -67,7 +67,7 @@
<Icon name="ph:plus" class="mr-1"/> Create User
</Button>

</Form>
</VForm>
</PanelZone>
</template>
</PanelFrame>
Expand Down
4 changes: 2 additions & 2 deletions app/pages/users/create.vue
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
</NuxtLink>
</div>
<PanelZone>
<Form :send="createAccount">
<VForm :send="createAccount">
<FormInput name="username" v-model="newUser.username" required label="Username" autocomplete="username"
type="text" class="mb-3" />

Expand All @@ -27,7 +27,7 @@
class="mb-3" />

<Button type="submit" class="w-full"><span class="text-center w-full"><Icon name="ph:user" class="mr-1"/><span class="align-middle">Create Account</span></span></Button>
</Form>
</VForm>

<Divider align="center" class="my-4">
<span >OR</span>
Expand Down
4 changes: 2 additions & 2 deletions app/pages/users/login.vue
Original file line number Diff line number Diff line change
Expand Up @@ -10,15 +10,15 @@
</div>
<PanelZone>

<Form :send="tryLogin">
<VForm :send="tryLogin">
<FormInput name="login" v-model="login" id="login1" required label="Email or Username" autocomplete="email"
class="mb-3" />

<FormInput name="password" v-model="password" required label="Password" autocomplete="current-password"
type="password" class="mb-3" />

<Button type="submit" class="w-full"><span class="text-center w-full"><Icon name="ph:user" class="mr-1"/><span class="align-middle">Sign in with Password</span></span></Button>
</Form>
</VForm>

<div class="mt-3">
<span class="text-600 font-medium line-height-3">Forgot your password?</span>
Expand Down
4 changes: 2 additions & 2 deletions app/pages/users/reset-password.vue
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
</NuxtLink>
</div>
<PanelZone info="Where should we send the password reset email?">
<Form :send="sendPasswordReset">
<VForm :send="sendPasswordReset">
<div class="flex gap-5 flex-col-reverse md:flex-row">
<div class="flex-auto">
<FormInput name="email" type="email" v-model="email" required label="Email Address" class="mb-4" />
Expand All @@ -20,7 +20,7 @@
</div>

</div>
</Form>
</VForm>
</PanelZone>
</div>
</template>
Expand Down
4 changes: 2 additions & 2 deletions app/pages/users/settings/account.vue
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
autocomplete="name" @change="currentUser.save('realName')" class="mb-4" />
</PanelZone>
<PanelZone title="Change Password" info="Alter your credentials.">
<Form :send="changePassword">
<VForm :send="changePassword">
<FormInput name="password" type="password" v-model="newPassword.password" required
label="New Password" autocomplete="new-password" class="mb-4" />

Expand All @@ -28,7 +28,7 @@
Change Password
</Button>

</Form>
</VForm>
</PanelZone>

</template>
Expand Down
4 changes: 2 additions & 2 deletions app/pages/users/settings/apikeys.vue
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@
</PanelZone>

<PanelZone title="Create API Key" info="Make a new API Key.">
<Form :send="() => apikeys.create()">
<VForm :send="() => apikeys.create()">

<FormInput name="name" type="text" v-model="apikeys.new.name" required
label="Name" class="mb-4" />
Expand All @@ -76,7 +76,7 @@
<Icon name="ph:plus" class="mr-1"/> Create API Key
</Button>

</Form>
</VForm>
</PanelZone>

</template>
Expand Down
13 changes: 12 additions & 1 deletion nuxt.config.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -7,31 +7,37 @@ ving.site.url = process.env.VING_SITE_URL;

export default defineNuxtConfig({
devtools: false,

future: {
compatibilityVersion: 4,
},

modules: [
'@pinia/nuxt',
'nuxt-icon',
'@nuxtjs/tailwindcss',
'@primevue/nuxt-module',
'@vueuse/nuxt',
],

primevue: {
importTheme: { from: "@/themes/ving-theme.mjs" },
},

imports: {
dirs: [
'composables/**',
'utils/**',
],
},

components: [
{
path: '~/components',
pathPrefix: false,
},
],

app: {
head: {
link: [
Expand Down Expand Up @@ -69,16 +75,21 @@ export default defineNuxtConfig({
]
},
},

css: [
'primeicons/primeicons.css',
],

runtimeConfig: {
public: ving,
},

hooks: {
'nitro:build:public-assets': (nitro) => {
const targetPath = path.join(nitro.options.output.dir, 'ving.json');
cpSync('./ving.json', targetPath, { recursive: true });
}
}
},

compatibilityDate: '2025-01-21'
})
Loading

0 comments on commit 58f6fda

Please sign in to comment.