Skip to content

Commit

Permalink
Update docs
Browse files Browse the repository at this point in the history
  • Loading branch information
kieuminhcanh committed Dec 3, 2024
1 parent e4f562c commit 8292c78
Show file tree
Hide file tree
Showing 17 changed files with 338 additions and 955 deletions.
2 changes: 1 addition & 1 deletion docs/app.config.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
// https://github.com/nuxt-themes/docus/blob/main/nuxt.schema.ts
export default defineAppConfig({
docus: {
title: 'Docus',
title: 'Notifier',
description: 'The best place to start your documentation.',
image: 'https://user-images.githubusercontent.com/904724/185365452-87b7ca7b-6030-4813-a2db-5e65c785bf88.png',
socials: {
Expand Down
67 changes: 33 additions & 34 deletions docs/content/0.index.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,85 +15,84 @@ cta:
- /introduction/getting-started
secondary:
- Open on GitHub →
- https://github.com/nuxt-themes/docus
- https://github.com/kieuminhcanh/vuetify-notifier
---

#title
The best place to start your documentation.
Vuetify Notifier

#description
Write pages in [Markdown](https://content.nuxtjs.org), use [Vue](https://vuejs.org) components and enjoy the power of [Nuxt](https://nuxt.com).
Simple yet fully customizable notifications, dialogs, and directives for your Vuetify applications.

#extra
::list
- **+50 Components** ready to build rich pages
- **Docs** and **Page** layouts
- Start from a `README`, scale to a framework documentation
- Navigation and Table of Contents generation
- Fully configurable design system
- Leverages [**Typography**](https://typography.nuxt.space/) and [**Elements**](https://elements.nuxt.dev)
- Used on [Content Documentation](https://content.nuxtjs.org)
- Display beautiful and informative notifications with various types (success, error, warning, info) and customizable options.
- Built-in dialog types for alerts, confirmations, and prompts.
- Seamless integration with Vuetify's styling and components.
- Support for custom content and actions.
- Transform any Vue component into a modal dialog with a single line of code.
::

#support
::terminal
---
content:
- npx nuxi@latest init -t themes/docus
- cd docs
- npm install
- npm run dev
- NUXT INSTALL
- npx nuxi@latest module add vuetify-notifier
-
- VUE PROJECT INSTALL
- npm install -D vuetify-notifier
---
::
::
::

::card-grid
#title
What's included
Key Features

#root
:ellipsis{left=0px width=40rem top=10rem blur=140px}

#default
::card{icon=logos:nuxt-icon}
::card{icon=mdi:bell-outline}
#title
Nuxt Architecture
Notifications
#description
Harness the full power of [Nuxt 3](https://v3.nuxtjs.org) and its [modules](https://modules.nuxtjs.org) ecosystem.
Display beautiful and informative notifications with various types (success, error, warning, info) and customizable options.
::

::card{icon=IconNuxtStudio}
::card{icon=mdi:alert-circle-outline}
#title
Nuxt Studio ready
Dialogs
#description
Edit your theme content and appearance with live-preview within [Nuxt Studio](https://nuxt.studio).
Create engaging and interactive dialogs with minimal effort, including alerts, confirmations, and prompts.
::

::card{icon=logos:vue}
::card{icon=mdi:cursor-pointer}
#title
Vue Components
Directives
#description
Use built-in components (or your own!) inside your content.
Add powerful functionalities to your elements with custom directives like `v-confirm` and `v-input`.
::

::card{icon=simple-icons:markdown}
::card{icon=mdi:view-grid-plus-outline}
#title
Write Markdown
Component as Dialog
#description
Enjoy the ease and simplicity of Markdown and discover [MDC syntax](https://content.nuxtjs.org/guide/writing/mdc).
Transform any Vue component into a modal dialog with a single line of code.
::

::card{icon=noto:rocket}
::card{icon=mdi:vuetify}
#title
Deploy anywhere
Seamless Vuetify Integration
#description
Zero config on [Vercel](https://vercel.com) or [Netlify](https://netlify.com). Choose between static generation, on-demand rendering (Node) or edge-side rendering on [CloudFlare workers](https://workers.cloudflare.com).
Enjoy perfect compatibility and styling consistency with your Vuetify projects.
::

::card{icon=noto:puzzle-piece}
::card{icon=mdi:feather}
#title
Extensible.
Lightweight and Performant
#description
Customize the whole design, or add components using slots - you can make Docus your own.
Minimize overhead and ensure smooth performance in your applications.
::
::
45 changes: 12 additions & 33 deletions docs/content/1.introduction/1.getting-started.md
Original file line number Diff line number Diff line change
@@ -1,57 +1,36 @@
# Getting Started

From your Markdown files to a deployed website in few minutes.
Add notifications, dialogs, and directives to your Vuetify application in minutes.

## Play online
## Install in your project

You can start playing with Docus in your browser using Stackblitz:

:button-link[Play on StackBlitz]{size="small" icon="IconStackBlitz" href="https://stackblitz.com/github/nuxt-themes/docus-starter" blank}

## Create a new project

1. Start a fresh Docus project with:
### Nuxt Project

```bash [npx]
npx nuxi@latest init docs -t themes/docus
npx nuxi@latest module add vuetify-notifier
```

2. Install the dependencies in the `docs` folder:
### Vue Project

::code-group

```bash [npm]
npm install
npm install vuetify-notifier
```

```bash [yarn]
yarn install
yarn install vuetify-notifier
```

```bash [pnpm]
pnpm install --shamefully-hoist
pnpm install vuetify-notifier
```

::

3. Run the `dev` command to start Docus in development mode:

## Try it out
::code-group

```bash [npm]
npm run dev
```

```bash [yarn]
yarn dev
```

```bash [pnpm]
pnpm run dev
```

::

::alert{type="success"}
✨ Well done! A browser window should automatically open for <http://localhost:3000>
::code-block{label="Preview" preview}
:sandbox{src="https://stackblitz.com/edit/vuetify-notifier?embed=1&file=src%2FApp.vue&view=preview"}
::
::
21 changes: 0 additions & 21 deletions docs/content/1.introduction/2.project-structure.md

This file was deleted.

86 changes: 86 additions & 0 deletions docs/content/1.introduction/2.usage.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,86 @@
# Usage

## Nuxt Project

Add `vuetify-notifier` module to `nuxt.config.ts` and configure it:
::code-group

```ts [nuxt.config.ts]
export default defineNuxtConfig({
modules: [
'vuetify-nuxt-module', // Required
'vuetify-notifier/nuxt'
],
notifier:{
/* module specific options */
}
})
```
::

Add `VNotifierContainer` to `VMain` component of `app.vue` or `default.
vue` layout

::code-group

```vue [app.vue]
<template>
<VApp>
<VMain>
<!-- This is required component for dialog work -->
<VNotifierContainer />
</VMain>
</VApp>
</template>
```

```vue [layouts/default.vue]
<template>
<!-- ... -->
<VMain>
<!-- This is required component for dialog work -->
<VNotifierContainer />
</VMain>
<!-- ... -->
</template>
```
::

## Vue Project

`Vuetify Notifier` only work when vuetify installed. See more [Vuetify Install guide](https://vuetifyjs.com/en/getting-started/installation/#using-laravel-mix)

Add `vuetify-notifier` plugin to `main.ts` and configure it:

::code-group

```ts [main.ts]
...
import VuetifyNotifier from "vuetify-notifier";

const vuetify = createVuetify({
...
})

createApp(App)
.use(vuetify) // Required
.use(VuetifyNotifier)
.mount('#app')
```
::

Add `VNotifierContainer` to `VMain` component of `App.vue`

::code-group

```vue [App.vue]
<template>
<!-- ... -->
<VMain>
<!-- This is required component for dialog work -->
<VNotifierContainer />
</VMain>
<!-- ... -->
</template>
```
::
41 changes: 0 additions & 41 deletions docs/content/1.introduction/3.writing-pages.md

This file was deleted.

Loading

0 comments on commit 8292c78

Please sign in to comment.