Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore: Lots of updates #19

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion LICENSE
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
The MIT License (MIT)

Copyright (c) Jeff Galbraith <[email protected]>
Copyright (c) Allan Gaunt <[email protected]>

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
Expand Down
21 changes: 21 additions & 0 deletions app-extension/LICENSE
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
The MIT License (MIT)

Copyright (c) Allan Gaunt <[email protected]>

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in
all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
THE SOFTWARE.
9 changes: 2 additions & 7 deletions app-extension/README.md
Original file line number Diff line number Diff line change
@@ -1,9 +1,7 @@
# Quasar App Extension qribbon

> Add a short description of your App Extension. What does it do? How is it beneficial? Why would someone want to use it?

[![npm](https://img.shields.io/npm/v/quasar-app-extension-qribbon.svg?label=quasar-app-extension-qribbon)](https://www.npmjs.com/package/quasar-app-extension-qribbon)
[![npm](https://img.shields.io/npm/dt/quasar-app-extension-qribbon.svg)](https://www.npmjs.com/package/quasar-app-extension-qribbon)
[![npm](https://img.shields.io/npm/v/@quasar/quasar-app-extension-qribbon.svg?label=@quasar/quasar-app-extension-qribbon)](https://www.npmjs.com/package/@quasar/quasar-app-extension-qribbon)
[![npm](https://img.shields.io/npm/dt/@quasar/quasar-app-extension-qribbon.svg)](https://www.npmjs.com/package/@quasar/quasar-app-extension-qribbon)

# Examples and Documentation for QRibbon UI Component
Can be found [here](https://quasarframework.github.io/quasar-ui-qribbon)
Expand All @@ -14,9 +12,6 @@ quasar ext add @quasar/qribbon
```
Quasar CLI will retrieve it from NPM and install the extension.

## Prompts

> If your app extension uses prompts, explain them here, otherwise remove this section.

# Uninstall
```bash
Expand Down
2 changes: 1 addition & 1 deletion app-extension/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@
"corner"
],
"dependencies": {
"@quasar/quasar-ui-qribbon": "1.0.0-beta.11"
"@quasar/quasar-ui-qribbon": "^1.0.0-beta.11"
},
"engines": {
"node": ">= 8.9.0",
Expand Down
5 changes: 3 additions & 2 deletions app-extension/src/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ function extendConf (conf) {

// make sure app extension files & ui package gets transpiled
conf.build.transpileDependencies.push(/quasar-app-extension-qribbon[\\/]src/)
conf.build.transpileDependencies.push(/quasar-ui-qribbon[\\/]src/)

// make sure the stylesheet goes through webpack to avoid SSR issues
conf.css.push('~@quasar/quasar-ui-qribbon/src/index.sass')
Expand All @@ -21,8 +22,8 @@ module.exports = function (api) {
// Quasar compatibility check; you may need
// hard dependencies, as in a minimum version of the "quasar"
// package or a minimum version of "@quasar/app" CLI
api.compatibleWith('quasar', '^1.1.1')
api.compatibleWith('@quasar/app', '^1.1.0')
api.compatibleWith('quasar', '^1.5.0')
api.compatibleWith('@quasar/app', '^1.3.0')

// Uncomment the line below if you provide a JSON API for your component
api.registerDescribeApi('QRibbon', '~@quasar/quasar-ui-qribbon/dist/api/QRibbon.json')
Expand Down
3 changes: 2 additions & 1 deletion ui/.eslintignore
Original file line number Diff line number Diff line change
@@ -1 +1,2 @@
docs
/docs
/dist
1 change: 1 addition & 0 deletions ui/.eslintrc.js
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,7 @@ module.exports = {
'import/no-extraneous-dependencies': 'off',
'prefer-promise-reject-errors': 'off',

'no-void': 'off',
// allow console.log during development only
'no-console': process.env.NODE_ENV === 'production' ? 'error' : 'off',
// allow debugger during development only
Expand Down
21 changes: 21 additions & 0 deletions ui/LICENSE
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
The MIT License (MIT)

Copyright (c) Allan Gaunt <[email protected]>

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in
all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
THE SOFTWARE.
2 changes: 1 addition & 1 deletion ui/README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Component QRibbon

[![npm](https://img.shields.io/npm/v/@quasar/quasar-ui-qribbon.svg?label=quasar-ui-qribbon)](https://www.npmjs.com/package/@quasar/quasar-ui-qribbon)
[![npm](https://img.shields.io/npm/v/@quasar/quasar-ui-qribbon.svg?label=@quasar/quasar-ui-qribbon)](https://www.npmjs.com/package/@quasar/quasar-ui-qribbon)
[![npm](https://img.shields.io/npm/dt/@quasar/quasar-ui-qribbon.svg)](https://www.npmjs.com/package/@quasar/quasar-ui-qribbon)

# QRibbon
Expand Down
3 changes: 3 additions & 0 deletions ui/build/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -8,11 +8,14 @@ const { green, blue } = require('chalk')

console.log()

require('./script.app-ext.js').syncAppExt()
require('./script.clean.js')

console.log(` 📦 Building ${green('v' + require('../package.json').version)}...${parallel ? blue(' [multi-threaded]') : ''}\n`)

createFolder('dist')
createFolder('dist/api')
createFolder('dist/vetur')

runJob(join(__dirname, './script.javascript'))
runJob(join(__dirname, './script.css'))
60 changes: 60 additions & 0 deletions ui/build/script.app-ext.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,60 @@
const
fs = require('fs'),
path = require('path'),
root = path.resolve(__dirname, '../..'),
resolvePath = file => path.resolve(root, file),
{ blue } = require('chalk')

const writeJson = function (file, json) {
return fs.writeFileSync(file, JSON.stringify(json, null, 2) + '\n', 'utf-8')
}

module.exports.syncAppExt = function (both = true) {
// make sure this project has an app-extension project
const appExtDir = resolvePath('app-extension')
if (!fs.existsSync(appExtDir)) {
return
}

// make sure this project has an ui project
const uiDir = resolvePath('ui')
if (!fs.existsSync(uiDir)) {
return
}

// get version and name from ui package.json
const { name, version } = require(resolvePath(resolvePath('ui/package.json')))

// read app-ext package.json
const appExtFile = resolvePath('app-extension/package.json')
let appExtJson = require(appExtFile),
finished = false

// sync version numbers
if (both === true) {
appExtJson.version = version
}

// check dependencies
if (appExtJson.dependencies !== void 0) {
if (appExtJson.dependencies[name] !== void 0) {
appExtJson.dependencies[name] = '^' + version
finished = true
}
}
// check devDependencies, if not finished
if (finished === false && appExtJson.devDependencies !== void 0) {
if (appExtJson.devDependencies[name] !== void 0) {
appExtJson.devDependencies[name] = '^' + version
finished = true
}
}

if (finished === true) {
writeJson(appExtFile, appExtJson)
console.log(` ⭐️ App Extension version ${blue(appExtJson.name)} synced with UI version.\n`)
return
}

console.error(` App Extension version and dependency NOT synced.\n`)
}
10 changes: 9 additions & 1 deletion ui/build/script.javascript.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,8 @@ const rollup = require('rollup')
const uglify = require('uglify-es')
const buble = require('@rollup/plugin-buble')
const json = require('@rollup/plugin-json')
const nodeResolve = require('rollup-plugin-node-resolve')
const cjs = require('@rollup/plugin-commonjs')
const nodeResolve = require('@rollup/plugin-node-resolve')

const buildConf = require('./config')
const buildUtils = require('./utils')
Expand All @@ -12,12 +13,19 @@ const bubleConfig = {
objectAssign: 'Object.assign'
}

const cjsConfig = {
include: [
/node_modules/
]
}

const rollupPlugins = [
nodeResolve({
extensions: ['.js'],
preferBuiltins: false
}),
json(),
cjs(cjsConfig),
buble(bubleConfig)
]

Expand Down
4 changes: 2 additions & 2 deletions ui/dev/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -13,10 +13,10 @@
"dev:electron": "quasar dev -m electron"
},
"dependencies": {
"@quasar/extras": "^1.3.3"
"@quasar/extras": "^1.6.0"
},
"devDependencies": {
"@quasar/app": "^1.2.3"
"@quasar/app": "^1.6.0"
},
"engines": {
"node": ">= 8.9.0",
Expand Down
50 changes: 32 additions & 18 deletions ui/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,10 @@
"build:css": "node build/script.css.js",
"build:api": "node build/build.api.js"
},
"funding": {
"type": "github",
"url": "https://github.com/sponsors/webnoob"
},
"publishConfig": {
"access": "public"
},
Expand All @@ -38,29 +42,39 @@
"qribbon",
"corner"
],
"vetur": {
"tags": "dist/vetur/tags.json",
"attributes": "dist/vetur/attributes.json"
},
"dependencies": {
"q-colorize-mixin": "^1.0.0"
"q-colorize-mixin": "^1.0.6"
},
"devDependencies": {
"@vue/eslint-config-standard": "^4.0.0",
"autoprefixer": "^9.7.1",
"babel-eslint": "^10.0.3",
"@rollup/plugin-buble": "^0.21.1",
"@rollup/plugin-commonjs": "^11.0.2",
"@rollup/plugin-json": "^4.0.2",
"@rollup/plugin-node-resolve": "^7.1.1",
"@vue/eslint-config-standard": "^5.1.2",
"autoprefixer": "^9.7.4",
"babel-eslint": "^10.1.0",
"chalk": "^3.0.0",
"cssnano": "^4.1.10",
"eslint": "^6.6.0",
"eslint-loader": "^3.0.2",
"eslint-plugin-vue": "^6.0.0",
"node-sass": "^4.13.0",
"open": "^7.0.0",
"postcss": "^7.0.21",
"postcss-rtl": "^1.5.0",
"quasar": "^1.4.1",
"quasar-json-api": "^0.0.8",
"rimraf": "^3.0.0",
"rollup": "^1.26.5",
"@rollup/plugin-buble": "^0.20.0",
"@rollup/plugin-json": "^4.0.0",
"rollup-plugin-node-resolve": "^5.2.0",
"eslint": "^6.8.0",
"eslint-loader": "^3.0.3",
"eslint-plugin-import": "^2.20.1",
"eslint-plugin-node": "^11.0.0",
"eslint-plugin-promise": "^4.2.1",
"eslint-plugin-quasar": "^1.0.0-alpha.18",
"eslint-plugin-standard": "^4.0.1",
"eslint-plugin-vue": "^6.2.2",
"node-sass": "^4.13.1",
"open": "^7.0.3",
"postcss": "^7.0.27",
"postcss-rtl": "^1.7.3",
"quasar": "^1.9.10",
"quasar-json-api": "^0.0.21",
"rimraf": "^3.0.2",
"rollup": "^2.1.0",
"uglify-es": "^3.3.9",
"zlib": "^1.0.5"
},
Expand Down
2 changes: 1 addition & 1 deletion ui/src/components/QRibbon.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
// Utils
import slot from 'quasar/src/utils/slot.js'
import { slot } from 'quasar/src/utils/slot.js'

// Mixins
import QRibbonColorize from '../mixins/colorize'
Expand Down
Loading