-
-
Notifications
You must be signed in to change notification settings - Fork 9
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
9 changed files
with
5,607 additions
and
6,107 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,9 +1,9 @@ | ||
module.exports = { | ||
stories: [ | ||
'../stories/**/*.stories.js' | ||
], | ||
stories: ['../stories/**/*.stories.js'], | ||
logLevel: 'debug', | ||
addons: [ | ||
'@storybook/addon-essentials', | ||
'@storybook/addon-controls', | ||
'@storybook/addon-docs', | ||
'@storybook/addon-a11y' | ||
] | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
import { addons } from '@storybook/addons' | ||
import theme from './theme' | ||
|
||
addons.setConfig({ theme }) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,37 @@ | ||
import { create } from '@storybook/theming/create' | ||
|
||
export default create({ | ||
base: 'light', | ||
|
||
colorPrimary: '#0052c0', | ||
colorSecondary: '#0052c0', | ||
|
||
// UI | ||
appBg: '#F7FAFC', | ||
appContentBg: '#EDF2F7', | ||
appBorderColor: '#CBD5E0', | ||
appBorderRadius: 4, | ||
|
||
// Typography | ||
fontBase: '-apple-system, BlinkMacSystemFont, "Segoe UI", "Roboto", "Oxygen", "Ubuntu", "Cantarell", "Fira Sans", "Droid Sans", "Helvetica Neue", "Open Sans", sans-serif', | ||
fontCode: 'monospace', | ||
|
||
// Text colors | ||
textColor: '#1A202C', | ||
textInverseColor: 'rgba(255,255,255,0.9)', | ||
|
||
// Toolbar default and active colors | ||
barTextColor: 'silver', | ||
barSelectedColor: '#FFFFFF', | ||
barBg: '#35495e', | ||
|
||
// Form colors | ||
inputBg: 'white', | ||
inputBorder: 'silver', | ||
inputTextColor: '#1A202C', | ||
inputBorderRadius: 4, | ||
|
||
brandTitle: 'Vue List Picker', | ||
brandUrl: 'https://github.com/guastallaigor/vue-list-picker', | ||
brandImage: 'https://github.com/guastallaigor/vue-list-picker/blob/master/.github/logo.png?raw=true' | ||
}) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,5 @@ | ||
module.exports = { | ||
presets: [ | ||
'@vue/app' | ||
'@vue/cli-plugin-babel/preset' | ||
] | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,9 @@ | ||
{ | ||
"name": "vue-list-picker", | ||
"version": "0.2.0", | ||
"version": "0.3.0", | ||
"description": "Just a simple list picker component made with Vue.js", | ||
"homepage": "https://github.com/guastallaigor/vue-list-picker#readme", | ||
"author": "Igor Guastalla de Lima <[email protected]>", | ||
"private": false, | ||
"scripts": { | ||
"lint": "vue-cli-service lint", | ||
|
@@ -14,41 +17,41 @@ | |
"build-storybook": "build-storybook" | ||
}, | ||
"dependencies": { | ||
"vue": "^2.6.12" | ||
"vue": "^2.6.14" | ||
}, | ||
"devDependencies": { | ||
"@commitlint/cli": "^11.0.0", | ||
"@commitlint/config-conventional": "^11.0.0", | ||
"@storybook/addon-actions": "^6.0.21", | ||
"@storybook/addon-backgrounds": "^6.0.21", | ||
"@storybook/addon-controls": "^6.0.21", | ||
"@storybook/addon-essentials": "^6.0.21", | ||
"@storybook/addon-knobs": "^6.0.21", | ||
"@storybook/addon-links": "^6.0.21", | ||
"@storybook/vue": "^6.0.21", | ||
"@vue/cli-plugin-babel": "^4.5.6", | ||
"@vue/cli-plugin-eslint": "^4.5.6", | ||
"@vue/cli-plugin-unit-jest": "^4.5.6", | ||
"@vue/cli-service": "^4.5.6", | ||
"@vue/eslint-config-standard": "^5.1.2", | ||
"@vue/test-utils": "^1.1.0", | ||
"babel-core": "7.0.0-bridge.0", | ||
"@babel/core": "^7.16.0", | ||
"@commitlint/cli": "^15.0.0", | ||
"@commitlint/config-conventional": "^15.0.0", | ||
"@storybook/addon-a11y": "^6.4.8", | ||
"@storybook/addon-actions": "^6.4.8", | ||
"@storybook/addon-backgrounds": "^6.4.8", | ||
"@storybook/addon-controls": "^6.4.8", | ||
"@storybook/addon-essentials": "^6.4.8", | ||
"@storybook/addon-links": "^6.4.8", | ||
"@storybook/theming": "^6.4.8", | ||
"@storybook/vue": "^6.4.8", | ||
"@vue/cli-plugin-babel": "^4.5.15", | ||
"@vue/cli-plugin-eslint": "^4.5.15", | ||
"@vue/cli-plugin-unit-jest": "^4.5.15", | ||
"@vue/cli-service": "^4.5.15", | ||
"@vue/eslint-config-standard": "^6.1.0", | ||
"@vue/test-utils": "^1.3.0", | ||
"babel-eslint": "^10.1.0", | ||
"babel-jest": "^23.6.0", | ||
"babel-loader": "^8.1.0", | ||
"babel-jest": "^27.4.2", | ||
"babel-loader": "^8.2.3", | ||
"babel-preset-vue": "^2.0.2", | ||
"commitizen": "^4.2.1", | ||
"core-js": "^3.6.5", | ||
"eslint": "^7.9.0", | ||
"eslint-plugin-import": "^2.22.0", | ||
"commitizen": "^4.2.4", | ||
"core-js": "^3.19.3", | ||
"eslint": "^7.32.0", | ||
"eslint-plugin-import": "^2.25.3", | ||
"eslint-plugin-node": "^11.1.0", | ||
"eslint-plugin-promise": "^4.2.1", | ||
"eslint-plugin-standard": "^4.0.1", | ||
"eslint-plugin-vue": "^6.2.2", | ||
"husky": "^4.3.0", | ||
"react-is": "^16.13.1", | ||
"vue-cli-plugin-storybook": "^1.3.0", | ||
"vue-template-compiler": "^2.6.12" | ||
"eslint-plugin-promise": "^5.2.0", | ||
"eslint-plugin-standard": "^4.1.0", | ||
"eslint-plugin-vue": "^8.2.0", | ||
"husky": "^7.0.4", | ||
"vue-cli-plugin-storybook": "^2.1.0", | ||
"vue-template-compiler": "^2.6.14" | ||
}, | ||
"bugs": { | ||
"url": "https://github.com/guastallaigor/vue-list-picker/issues" | ||
|
@@ -113,7 +116,7 @@ | |
"plugins": { | ||
"autoprefixer": {} | ||
} | ||
}, | ||
}, | ||
"browserslist": [ | ||
"> 1%", | ||
"last 2 versions" | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,22 +1,37 @@ | ||
// Import vue component | ||
import VueListPicker from './src/components/VueListPicker.vue' | ||
|
||
// Export components | ||
const Components = { | ||
VueListPicker | ||
// install function executed by Vue.use() | ||
const install = function (Vue) { | ||
if (install.installed) return | ||
install.installed = true | ||
Vue.component('VueListPicker', VueListPicker) | ||
} | ||
|
||
const VueListPickerPlugin = { | ||
install (Vue) { | ||
Object.keys(Components).forEach((name) => { | ||
Vue.component(name, Components[name]) | ||
}) | ||
} | ||
} | ||
// Create module definition for Vue.use() | ||
const plugin = { install } | ||
|
||
// To auto-install when vue is found | ||
// eslint-disable-next-line no-redeclare | ||
/* global window, global */ | ||
let GlobalVue = null | ||
|
||
// Export as a plugin | ||
export default VueListPickerPlugin | ||
if (typeof window !== 'undefined') { | ||
GlobalVue = window.Vue | ||
} else if (typeof global !== 'undefined') { | ||
GlobalVue = global.Vue | ||
} | ||
|
||
// Export as individual components | ||
export { | ||
VueListPicker | ||
if (GlobalVue) { | ||
GlobalVue.use(plugin) | ||
} | ||
|
||
// Inject install function into component - allows component | ||
// to be registered via Vue.use() as well as Vue.component() | ||
VueListPicker.install = install | ||
|
||
// Export component by default | ||
export default VueListPicker | ||
|
||
// Export single (backwards compatibility) | ||
export { VueListPicker } |
Oops, something went wrong.