diff --git a/public/manifests/zhivan/manifest.json b/public/manifests/zhivan/manifest.json new file mode 100644 index 0000000..05a1d39 --- /dev/null +++ b/public/manifests/zhivan/manifest.json @@ -0,0 +1,45 @@ +{ + "name": "Zhivan - ژیوان", + "short_name": "Zhivan", + "start_url": "/zhivan", + "scope": "/", + "id": "/zhivan", + "display": "standalone", + "display_override": [ + "fullscreen", + "minimal-ui", + "browser" + ], + "background_color": "#F4F5F9", + "theme_color": "#F4F5F9", + "orientation": "portrait", + "description": "Zhivan Menu by Danak. DMenu is a modern, user-friendly menu management system designed to enhance the dining experience.", + "dir": "rtl", + "lang": "fa-IR", + "version": "1.0.0", + "author": { + "name": "Zhivan", + "url": "https://dmenu.com/zhivan" + }, + "icons": [ + { + "src": "/icons/web-app-manifest-192x192.png", + "type": "image/png", + "sizes": "192x192", + "purpose": "any" + }, + { + "src": "/icons/web-app-manifest-512x512.png", + "type": "image/png", + "sizes": "512x512", + "purpose": "any" + } + ], + "categories": [ + "food", + "restaurant", + "productivity" + ], + "related_applications": [], + "prefer_related_applications": false +} \ No newline at end of file diff --git a/src/app/[name]/layout.tsx b/src/app/[name]/layout.tsx index f0c9811..43f9660 100644 --- a/src/app/[name]/layout.tsx +++ b/src/app/[name]/layout.tsx @@ -1,16 +1,34 @@ -import PreferenceWrapper from '@/components/wrapper/PreferenceWrapper'; +import PreferenceWrapper from '@/components/wrapper/PreferenceWrapper' import React from 'react' +import type { Metadata, Viewport } from 'next' + +export async function generateMetadata ({ + params +}: { + params: { name: string } +}): Promise { + const { name } = await params + return { + title: `${name} Dashboard`, + description: `PWA dashboard for ${name}`, + manifest: `/manifests/${name}/manifest.json` + } +} + +export async function generateViewport ({}: { + params: { name: string } +}): Promise { + return { + themeColor: '#F4F5F9' + } +} type Props = { - children: React.ReactElement + children: React.ReactElement } -function layout({ children }: Props) { - return ( - - {children} - - ) +function layout ({ children }: Props) { + return {children} } -export default layout \ No newline at end of file +export default layout