Skip to content

Commit 69381fb

Browse files
committed
Merge branch 'main' into next
2 parents 0e5e895 + f72be69 commit 69381fb

File tree

17 files changed

+2901
-758
lines changed

17 files changed

+2901
-758
lines changed

.github/workflows/release-docs.yml

Lines changed: 13 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@ on:
55
branches:
66
- main
77
- next
8+
- vue2
89

910
jobs:
1011
build-and-deploy:
@@ -28,11 +29,22 @@ jobs:
2829
with:
2930
branch: gh-pages
3031
folder: docs/src/.vuepress/dist
32+
clean-exclude: |
33+
next
34+
vue2
3135
3236
- name: Deploy next
3337
if: github.ref == 'refs/heads/next'
3438
uses: JamesIves/github-pages-deploy-action@4.1.7
3539
with:
3640
branch: gh-pages
3741
folder: docs/src/.vuepress/dist
38-
target-folder: ./next
42+
target-folder: ./next
43+
44+
- name: Deploy vue2
45+
if: github.ref == 'refs/heads/vue2'
46+
uses: JamesIves/github-pages-deploy-action@4.1.7
47+
with:
48+
branch: gh-pages
49+
folder: docs/src/.vuepress/dist
50+
target-folder: ./vue2

.gitignore

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,6 @@
11
.vscode
22
node_modules
3-
dist
3+
dist
4+
5+
vitepress-test
6+
vuepress-test

.releaserc.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
{
22
"branches": [
33
{ "name": "main" },
4+
{ "name": "vue2" },
45
{ "name": "next", "channel": "next" }
56
],
67
"plugins": [

README.md

Lines changed: 9 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,15 @@
1-
# Vue.js Cron
2-
3-
**generate cron expressions using Vue.js**
4-
5-
![Vue.js Cron Hero](https://raw.githubusercontent.com/abichinger/vue-js-cron/main/assets/cron-light-hero.png)
1+
<p align="center">
2+
<img src="./assets/vue-js-cron-hero.png" alt="vue-js-cron Hero">
3+
</p>
4+
<p align="center">
5+
<em>generate cron expressions using Vue.js</em>
6+
</p>
67

78
# Getting Started
89

9-
Vue v2: [documentation](https://abichinger.github.io/vue-js-cron)
10+
Vue v3: [documentation](https://abichinger.github.io/vue-js-cron)
1011

11-
Vue v3: [documentation](https://abichinger.github.io/vue-js-cron/next)
12+
Vue v2: [documentation](https://abichinger.github.io/vue-js-cron/vue2)
1213

1314
# Packages
1415

@@ -18,6 +19,7 @@ This monorepo includes the following packages:
1819
- light - a lightweight cron editor without external dependencies
1920
- vuetify - Vuetify component to edit cron expressions.
2021
- element-plus - Element Plus component
22+
- ant - Ant Design Vue component
2123
- docs - Vue.js Cron documentation powered by [VuePress](https://vuepress.vuejs.org/)
2224

2325
# Development

ant/src/components/CustomSelect.vue

Lines changed: 7 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -13,12 +13,12 @@
1313

1414
<template #overlay>
1515
<a-menu multiple :selectedKeys="Array.isArray(modelValue) ? modelValue : [modelValue]">
16-
<a-row class="vcron-a-row" type="flex" v-for="(itemRow, i) in itemRows" :key="i">
17-
<a-col class="vcron-a-col" :flex="1" v-for="(item, j) in itemRow" :key="j">
16+
<div class="vcron-a-row" type="flex" v-for="(itemRow, i) in itemRows" :key="i">
17+
<div class="vcron-a-col" :flex="1" v-for="(item, j) in itemRow" :key="j">
1818
<a-menu-item v-if="item" :key="item[itemValue]" @click="select(item); updateVisibility();">{{item.text}}</a-menu-item>
1919
<a-menu-item v-else></a-menu-item>
20-
</a-col>
21-
</a-row>
20+
</div>
21+
</div>
2222
</a-menu>
2323
</template>
2424

@@ -71,11 +71,12 @@ export default {
7171
<style scoped>
7272
7373
.vcron-a-row {
74-
flex-wrap: nowrap !important;
74+
display: flex;
75+
flex-wrap: nowrap;
7576
}
7677
7778
.vcron-a-col {
78-
flex-basis: 100% !important;
79+
flex-basis: 100%;
7980
min-width: 0;
8081
text-align: center;
8182
}

assets/hero.svg

Lines changed: 831 additions & 0 deletions
Loading

assets/vue-js-cron-hero.png

62.6 KB
Loading

docs/package.json

Lines changed: 9 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -12,20 +12,17 @@
1212
"scripts": {
1313
"dev": "vuepress dev src",
1414
"build": "vuepress build src",
15-
"clean": "git clean -xf src/.vuepress/dist"
15+
"clean": "git clean -xf src/.vuepress/dist src/.vuepress/.temp src/.vuepress/.cache"
1616
},
1717
"license": "MIT",
1818
"devDependencies": {
19-
"@vuepress/plugin-google-analytics": "^2.0.0-beta.49",
20-
"@vuepress/plugin-register-components": "^2.0.0-beta.49",
21-
"vuepress": "^2.0.0-beta.49"
22-
},
23-
"dependencies": {
24-
"@vue-js-cron/core": "^3.0.0",
25-
"@vue-js-cron/element-plus": "^1.0.0",
26-
"@vue-js-cron/light": "^2.0.0",
27-
"@vue-js-cron/vuetify": "^3.0.0",
28-
"@vue-js-cron/ant": "^1.0.0",
29-
"vuetify": "^3.0.0-beta.7"
19+
"@vue-js-cron/ant": "file:../ant",
20+
"@vue-js-cron/core": "file:../core",
21+
"@vue-js-cron/element-plus": "file:../element-plus",
22+
"@vue-js-cron/light": "file:../light",
23+
"@vue-js-cron/vuetify": "file:../vuetify",
24+
"@vuepress/plugin-register-components": "2.0.0-beta.51",
25+
"@vuepress/plugin-google-analytics": "2.0.0-beta.51",
26+
"vuepress": "2.0.0-beta.51"
3027
}
3128
}

docs/src/.vuepress/client.js

Lines changed: 8 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -10,24 +10,28 @@ import '@vue-js-cron/vuetify/dist/vuetify.css'
1010

1111
import { createVuetify } from 'vuetify'
1212
import * as components from 'vuetify/components'
13+
import * as directives from 'vuetify/directives'
1314
import 'vuetify/styles'
1415

1516
import ElementPlus from 'element-plus'
1617
import 'element-plus/dist/index.css'
1718

1819
import Ant from 'ant-design-vue'
20+
// import 'ant-design-vue/dist/antd.css'
1921
import '../styles/antd.css'
2022

2123
import { defineClientConfig } from '@vuepress/client'
2224

2325
import { variables } from './vars'
2426

25-
const vuetify = createVuetify({
26-
components
27-
})
28-
2927
export default defineClientConfig({
3028
enhance ({ app, router, siteData }) {
29+
const vuetify = createVuetify({
30+
components,
31+
directives,
32+
ssr: true
33+
})
34+
3135
app.use(vuetify)
3236
app.use(ElementPlus)
3337
app.use(Ant)
@@ -48,16 +52,3 @@ export default defineClientConfig({
4852
setup () {},
4953
rootComponents: []
5054
})
51-
52-
// export default ({
53-
// Vue, // the version of Vue being used in the VuePress app
54-
// options, // the options for the root Vue instance
55-
// router, // the router instance for the app
56-
// siteData // site metadata
57-
// }) => {
58-
// Vue.use(Vuetify)
59-
// options.vuetify = new Vuetify({})
60-
// Vue.use(CronCore)
61-
// Vue.use(CronVuetify)
62-
// Vue.use(CronLight)
63-
// }

docs/src/.vuepress/config.js

Lines changed: 14 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,17 +1,17 @@
1-
const { description } = require('../../package')
2-
const { defaultTheme } = require('@vuepress/theme-default')
3-
const { registerComponentsPlugin } = require('@vuepress/plugin-register-components')
4-
const { path } = require('@vuepress/utils')
5-
const { viteBundler } = require('@vuepress/bundler-vite')
6-
const { googleAnalyticsPlugin } = require('@vuepress/plugin-google-analytics')
1+
import { googleAnalyticsPlugin } from '@vuepress/plugin-google-analytics'
2+
import { registerComponentsPlugin } from '@vuepress/plugin-register-components'
3+
import { defaultTheme } from '@vuepress/theme-default'
4+
import { path } from '@vuepress/utils'
5+
import { defineUserConfig, viteBundler } from 'vuepress'
6+
import { description } from '../../package'
77

8-
module.exports = {
8+
export default defineUserConfig({
99

1010
/**
1111
* Ref: https://v2.vuepress.vuejs.org/guide/configuration.html#config-file
1212
*/
1313

14-
base: '/vue-js-cron/next/',
14+
base: '/vue-js-cron/',
1515

1616
title: 'Vue-js-cron Docs',
1717

@@ -32,6 +32,10 @@ module.exports = {
3232
editLinkText: '',
3333
lastUpdated: false,
3434
navbar: [
35+
{
36+
text: 'Vue v2',
37+
link: 'https://abichinger.github.io/vue-js-cron/vue2/'
38+
},
3539
{
3640
text: 'Demo',
3741
link: '/demo'
@@ -108,7 +112,7 @@ module.exports = {
108112
// https://github.com/vuepress/vuepress-next/issues/585#issuecomment-1046188074
109113
// https://v2.vuepress.vuejs.org/reference/bundler/vite.html#ssr-externals-issue
110114
ssr: {
111-
noExternal: ['vuetify', 'ant-design-vue']
115+
noExternal: ['vuetify', '@vue-js-cron/core']
112116
}
113117
},
114118
vuePluginOptions: {}
@@ -129,4 +133,4 @@ module.exports = {
129133
id: 'G-8E2WXHH0QS'
130134
})
131135
]
132-
}
136+
})

docs/src/guide/getting-started.md

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -15,12 +15,12 @@ If you would like to use a different UI framework, follow the quick start guide
1515
Open up a terminal and run the following command:
1616

1717
```bash
18-
yarn add @vue-js-cron/light@next
18+
yarn add @vue-js-cron/light@latest
1919
```
2020
or
2121

2222
```bash
23-
npm install @vue-js-cron/light@next
23+
npm install @vue-js-cron/light@latest
2424
```
2525

2626
Then you need to register `vue-js-cron/light` with `app.use()`
@@ -58,12 +58,12 @@ Now you can use the `cron-light` component.
5858
Open up a terminal and run the following command:
5959

6060
```bash
61-
yarn add @vue-js-cron/vuetify@next
61+
yarn add @vue-js-cron/vuetify@latest
6262
```
6363
or
6464

6565
```bash
66-
npm install @vue-js-cron/vuetify@next
66+
npm install @vue-js-cron/vuetify@latest
6767
```
6868

6969
Then you need to register `vue-js-cron/vuetify` with `app.use()`
@@ -102,12 +102,12 @@ Now you can use the `cron-vuetify` component.
102102
Open up a terminal and run the following command:
103103

104104
```bash
105-
yarn add @vue-js-cron/element-plus@next
105+
yarn add @vue-js-cron/element-plus@latest
106106
```
107107
or
108108

109109
```bash
110-
npm install @vue-js-cron/element-plus@next
110+
npm install @vue-js-cron/element-plus@latest
111111
```
112112

113113
Then you need to register `@vue-js-cron/element-plus` with `app.use()`
@@ -145,12 +145,12 @@ Now you can use the `cron-element-plus` component.
145145
Open up a terminal and run the following command:
146146

147147
```bash
148-
yarn add @vue-js-cron/ant@next
148+
yarn add @vue-js-cron/ant@latest
149149
```
150150
or
151151

152152
```bash
153-
npm install @vue-js-cron/ant@next
153+
npm install @vue-js-cron/ant@latest
154154
```
155155

156156
Then you need to register `@vue-js-cron/ant` with `app.use()`
@@ -187,12 +187,12 @@ In this example [Vuetify](https://vuetifyjs.com/en/) will be used to render the
187187
First open up a terminal and run the following command:
188188

189189
```bash
190-
yarn add @vue-js-cron/core@next
190+
yarn add @vue-js-cron/core@latest
191191
```
192192
or
193193

194194
```bash
195-
npm install @vue-js-cron/core@next
195+
npm install @vue-js-cron/core@latest
196196
```
197197

198198
Then you need to register `vue-js-cron/core` with `Vue.app()`

0 commit comments

Comments
 (0)