Skip to content

Commit c8e83b0

Browse files
committed
docs: update docs
1 parent d455eac commit c8e83b0

9 files changed

+96
-13
lines changed

docs/src/.vuepress/components/cron-demo.vue

Lines changed: 15 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -2,11 +2,11 @@
22
<div class="cron-demo">
33
<p>Flavor</p>
44
<v-select
5-
:model-value="flavor"
6-
@update:model-value="selectFlavor"
5+
v-model="flavor"
76
:items="flavors"
8-
item-value="name"
9-
item-title="name">
7+
item-value="value"
8+
item-title="name"
9+
return-object>
1010
</v-select>
1111

1212
<p>Locale</p>
@@ -58,13 +58,21 @@ export default {
5858
{
5959
name: 'Naive UI',
6060
},
61+
{
62+
name: 'PrimeVue',
63+
value: 'prime'
64+
},
6165
{
6266
name: 'Quasar',
6367
},
6468
{
6569
name: 'Vuetify',
6670
},
67-
]
71+
].map(f => ({
72+
name: f.name,
73+
value: f.value ?? f.name.replace(' ', '-').toLowerCase()
74+
}))
75+
6876
const locales = [
6977
{
7078
name: 'English',
@@ -124,12 +132,6 @@ export default {
124132
const format = ref(formats[0])
125133
const disabled = ref(false)
126134
127-
const selectFlavor = (name) => {
128-
let i = flavors.map(f => f.name).indexOf(name)
129-
i = i >= 0 ? i : 0
130-
flavor.value = flavors[i]
131-
}
132-
133135
const src = computed(() => {
134136
const params = {
135137
locale: locale.value,
@@ -138,16 +140,16 @@ export default {
138140
...(disabled.value ? { disabled:true } : {})
139141
}
140142
const query = new URLSearchParams(params)
141-
const path = 'demo/' + flavor.value.name.replace(' ', '-').toLowerCase() + '/index.html?' + query.toString()
143+
const path = 'demo/' + flavor.value.value + '/index.html?' + query.toString()
142144
145+
console.log("src", path)
143146
return withBase(path)
144147
})
145148
146149
return {
147150
src,
148151
flavor: flavor,
149152
flavors,
150-
selectFlavor,
151153
toggle: ref(0),
152154
locales,
153155
locale: locale,

docs/src/guide/getting-started-ant.md

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,8 +7,11 @@ The fastest way to get started, is to use one of the prebuilt components.
77
- cron-ant - cron editor for [Ant Design Vue](https://antdv.com/)
88
- [cron-element-plus](./getting-started-element-plus) - cron editor for [Element Plus](https://element-plus.org/en-US/)
99
- [cron-naive](./getting-started-naive-ui) - cron editor for [Naive UI](https://www.naiveui.com)
10+
- [cron-prime](./getting-started-prime) - cron editor for [PrimeVue](https://primevue.org/)
1011
- [cron-quasar](./getting-started-quasar) - cron editor for [Quasar](https://quasar.dev/)
1112
- [cron-vuetify](./getting-started-vuetify) - cron editor for [Vuetify.js](https://next.vuetifyjs.com/en/)
13+
14+
1215
## Requirements
1316

1417
Make sure to install and setup all requirements.

docs/src/guide/getting-started-core.md

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,9 +7,12 @@ The fastest way to get started, is to use one of the prebuilt components.
77
- [cron-ant](./getting-started-ant) - cron editor for [Ant Design Vue](https://antdv.com/)
88
- [cron-element-plus](./getting-started-element-plus) - cron editor for [Element Plus](https://element-plus.org/en-US/)
99
- [cron-naive](./getting-started-naive-ui) - cron editor for [Naive UI](https://www.naiveui.com)
10+
- [cron-prime](./getting-started-prime) - cron editor for [PrimeVue](https://primevue.org/)
1011
- [cron-quasar](./getting-started-quasar) - cron editor for [Quasar](https://quasar.dev/)
1112
- [cron-vuetify](./getting-started-vuetify) - cron editor for [Vuetify.js](https://next.vuetifyjs.com/en/)
1213

14+
15+
1316
## Installation
1417

1518
Open up a terminal and run the following command:

docs/src/guide/getting-started-element-plus.md

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,8 +7,11 @@ The fastest way to get started, is to use one of the prebuilt components.
77
- [cron-ant](./getting-started-ant) - cron editor for [Ant Design Vue](https://antdv.com/)
88
- cron-element-plus - cron editor for [Element Plus](https://element-plus.org/en-US/)
99
- [cron-naive](./getting-started-naive-ui) - cron editor for [Naive UI](https://www.naiveui.com)
10+
- [cron-prime](./getting-started-prime) - cron editor for [PrimeVue](https://primevue.org/)
1011
- [cron-quasar](./getting-started-quasar) - cron editor for [Quasar](https://quasar.dev/)
1112
- [cron-vuetify](./getting-started-vuetify) - cron editor for [Vuetify.js](https://next.vuetifyjs.com/en/)
13+
14+
1215
## Requirements
1316

1417
Make sure to install and setup all requirements.

docs/src/guide/getting-started-light.md

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,9 +7,12 @@ The fastest way to get started, is to use one of the prebuilt components.
77
- [cron-ant](./getting-started-ant) - cron editor for [Ant Design Vue](https://antdv.com/)
88
- [cron-element-plus](./getting-started-element-plus) - cron editor for [Element Plus](https://element-plus.org/en-US/)
99
- [cron-naive](./getting-started-naive-ui) - cron editor for [Naive UI](https://www.naiveui.com)
10+
- [cron-prime](./getting-started-prime) - cron editor for [PrimeVue](https://primevue.org/)
1011
- [cron-quasar](./getting-started-quasar) - cron editor for [Quasar](https://quasar.dev/)
1112
- [cron-vuetify](./getting-started-vuetify) - cron editor for [Vuetify.js](https://next.vuetifyjs.com/en/)
1213

14+
15+
1316
## Installation
1417

1518
Open up a terminal and run the following command:

docs/src/guide/getting-started-naive-ui.md

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,8 +7,11 @@ The fastest way to get started, is to use one of the prebuilt components.
77
- [cron-ant](./getting-started-ant) - cron editor for [Ant Design Vue](https://antdv.com/)
88
- [cron-element-plus](./getting-started-element-plus) - cron editor for [Element Plus](https://element-plus.org/en-US/)
99
- cron-naive - cron editor for [Naive UI](https://www.naiveui.com)
10+
- [cron-prime](./getting-started-prime) - cron editor for [PrimeVue](https://primevue.org/)
1011
- [cron-quasar](./getting-started-quasar) - cron editor for [Quasar](https://quasar.dev/)
1112
- [cron-vuetify](./getting-started-vuetify) - cron editor for [Vuetify.js](https://next.vuetifyjs.com/en/)
13+
14+
1215
## Requirements
1316

1417
Make sure to install and setup all requirements.
Lines changed: 60 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,60 @@
1+
<!-- Generated file -->
2+
# Getting Started - PrimeVue
3+
4+
The fastest way to get started, is to use one of the prebuilt components.
5+
- [cron-core](./getting-started-core) - renderless cron editor
6+
- [cron-light](./getting-started-light) - lightweight cron editor without external dependencies
7+
- [cron-ant](./getting-started-ant) - cron editor for [Ant Design Vue](https://antdv.com/)
8+
- [cron-element-plus](./getting-started-element-plus) - cron editor for [Element Plus](https://element-plus.org/en-US/)
9+
- [cron-naive](./getting-started-naive-ui) - cron editor for [Naive UI](https://www.naiveui.com)
10+
- cron-prime - cron editor for [PrimeVue](https://primevue.org/)
11+
- [cron-quasar](./getting-started-quasar) - cron editor for [Quasar](https://quasar.dev/)
12+
- [cron-vuetify](./getting-started-vuetify) - cron editor for [Vuetify.js](https://next.vuetifyjs.com/en/)
13+
14+
15+
## Requirements
16+
17+
Make sure to install and setup all requirements.
18+
- [PrimeVue](https://primevue.org/setup/)
19+
20+
## Installation
21+
22+
Open up a terminal and run the following command:
23+
24+
```bash
25+
yarn add @vue-js-cron/prime
26+
```
27+
or
28+
29+
```bash
30+
npm install @vue-js-cron/prime
31+
```
32+
33+
Then you need to register the component
34+
35+
```js
36+
import '@vue-js-cron/prime/dist/prime.css'
37+
38+
// registers the component globally
39+
// registered name: CronPrime
40+
import CronPrimePlugin from '@vue-js-cron/prime'
41+
app.use(CronPrimePlugin)
42+
43+
// alternatively you can also register the component yourself
44+
// https://vuejs.org/guide/components/registration.html
45+
import { CronPrime } from '@vue-js-cron/prime'
46+
app.component('CronPrime', CronPrime)
47+
```
48+
49+
Done! 🚀
50+
51+
<br />
52+
53+
## API
54+
55+
56+
[CronPrime API](https://abichinger.github.io/vue-js-cron/typedoc/classes/_vue_js_cron_prime.CronPrime)
57+
58+
[CronPrimeProps API](https://abichinger.github.io/vue-js-cron/typedoc/interfaces/_vue_js_cron_prime.CronPrimeProps)
59+
60+

docs/src/guide/getting-started-quasar.md

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,8 +7,11 @@ The fastest way to get started, is to use one of the prebuilt components.
77
- [cron-ant](./getting-started-ant) - cron editor for [Ant Design Vue](https://antdv.com/)
88
- [cron-element-plus](./getting-started-element-plus) - cron editor for [Element Plus](https://element-plus.org/en-US/)
99
- [cron-naive](./getting-started-naive-ui) - cron editor for [Naive UI](https://www.naiveui.com)
10+
- [cron-prime](./getting-started-prime) - cron editor for [PrimeVue](https://primevue.org/)
1011
- cron-quasar - cron editor for [Quasar](https://quasar.dev/)
1112
- [cron-vuetify](./getting-started-vuetify) - cron editor for [Vuetify.js](https://next.vuetifyjs.com/en/)
13+
14+
1215
## Requirements
1316

1417
Make sure to install and setup all requirements.

docs/src/guide/getting-started-vuetify.md

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,8 +7,11 @@ The fastest way to get started, is to use one of the prebuilt components.
77
- [cron-ant](./getting-started-ant) - cron editor for [Ant Design Vue](https://antdv.com/)
88
- [cron-element-plus](./getting-started-element-plus) - cron editor for [Element Plus](https://element-plus.org/en-US/)
99
- [cron-naive](./getting-started-naive-ui) - cron editor for [Naive UI](https://www.naiveui.com)
10+
- [cron-prime](./getting-started-prime) - cron editor for [PrimeVue](https://primevue.org/)
1011
- [cron-quasar](./getting-started-quasar) - cron editor for [Quasar](https://quasar.dev/)
1112
- cron-vuetify - cron editor for [Vuetify.js](https://next.vuetifyjs.com/en/)
13+
14+
1215
## Requirements
1316

1417
Make sure to install and setup all requirements.

0 commit comments

Comments
 (0)