@motor-cms/ui-admin 1.4.0 → 1.5.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -4,6 +4,7 @@ import type { FormSubmitEvent } from '@nuxt/ui'
4
4
 
5
5
  const { t } = useI18n()
6
6
  const { login } = useSanctumAuth()
7
+ const toast = useToast()
7
8
 
8
9
  definePageMeta({
9
10
  layout: 'auth',
@@ -53,6 +54,11 @@ async function onSubmit(event: FormSubmitEvent<Schema>) {
53
54
  email: event.data.email,
54
55
  password: event.data.password
55
56
  })
57
+ toast.add({
58
+ title: t('motor-core.login.login_success'),
59
+ color: 'success',
60
+ icon: 'i-lucide-check-circle'
61
+ })
56
62
  } catch {
57
63
  error.value = t('motor-core.login.login_failed')
58
64
  } finally {
@@ -37,31 +37,29 @@ const fetchEmailTemplates = useGridFetch<EmailTemplate>('/api/v2/email-templates
37
37
  </script>
38
38
 
39
39
  <template>
40
- <div>
41
- <GridPage
42
- :title="t('motor-admin.email_templates.title')"
43
- :subtitle="t('motor-admin.email_templates.subtitle')"
44
- add-route="/motor-admin/email-templates/create"
45
- :add-label="t('motor-admin.email_templates.add')"
40
+ <GridPage
41
+ :title="t('motor-admin.email_templates.title')"
42
+ :subtitle="t('motor-admin.email_templates.subtitle')"
43
+ add-route="/motor-admin/email-templates/create"
44
+ :add-label="t('motor-admin.email_templates.add')"
45
+ write-permission="email-templates.write"
46
+ >
47
+ <GridBase
48
+ id="email-templates-grid"
49
+ :fetch="fetchEmailTemplates"
50
+ :columns="columns"
51
+ :filters="filters"
52
+ :row-actions="rowActions"
53
+ base-path="/motor-admin/email-templates"
54
+ :row-click-to="(row: any) => `/motor-admin/email-templates/${row.id}/edit`"
46
55
  write-permission="email-templates.write"
47
- >
48
- <GridBase
49
- id="email-templates-grid"
50
- :fetch="fetchEmailTemplates"
51
- :columns="columns"
52
- :filters="filters"
53
- :row-actions="rowActions"
54
- base-path="/motor-admin/email-templates"
55
- :row-click-to="(row: any) => `/motor-admin/email-templates/${row.id}/edit`"
56
- write-permission="email-templates.write"
57
- delete-permission="email-templates.delete"
58
- />
59
- </GridPage>
60
-
61
- <EntityUsageModal
62
- v-model:open="usageModalOpen"
63
- :endpoint="usageEndpoint"
64
- :title="t('motor-admin.email_templates.usage_title')"
56
+ delete-permission="email-templates.delete"
65
57
  />
66
- </div>
58
+ </GridPage>
59
+
60
+ <EntityUsageModal
61
+ v-model:open="usageModalOpen"
62
+ :endpoint="usageEndpoint"
63
+ :title="t('motor-admin.email_templates.usage_title')"
64
+ />
67
65
  </template>
@@ -266,6 +266,7 @@ onMounted(() => {
266
266
  :thumbnail-url="row.thumbnail_url"
267
267
  :module="row.module"
268
268
  :index-label="row.index_label"
269
+ :suffix="row.suffix"
269
270
  :to="row.to"
270
271
  :actions="row.actions"
271
272
  :file-id="row.raw_index === 'files' ? row.id : undefined"
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@motor-cms/ui-admin",
3
- "version": "1.4.0",
3
+ "version": "1.5.0",
4
4
  "type": "module",
5
5
  "main": "./nuxt.config.ts",
6
6
  "files": [
@@ -17,7 +17,7 @@
17
17
  "@vueuse/core": "^14.0.0",
18
18
  "sortablejs": "^1.15.0",
19
19
  "zod": "^4.0.0",
20
- "@motor-cms/ui-core": "1.4.0"
20
+ "@motor-cms/ui-core": "1.5.0"
21
21
  },
22
22
  "peerDependencies": {
23
23
  "nuxt": "^4.0.0",