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

New plugin component slots (dock ,msg append/prepend), patches, chathistory fixes and History API, etc... #17

Draft
wants to merge 22 commits into
base: vue3-20240724
Choose a base branch
from
Draft
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 .browserslistrc
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
> 1%
last 2 versions
not ie <= 8
not dead
5 changes: 2 additions & 3 deletions .eslintignore
Original file line number Diff line number Diff line change
@@ -1,3 +1,2 @@
build/*.js
config/*.js
tests/unit/coverage/
/dist/
/tests/unit/coverage/
110 changes: 85 additions & 25 deletions .eslintrc.js
Original file line number Diff line number Diff line change
@@ -1,31 +1,50 @@
const rulesDirPlugin = require('eslint-plugin-rulesdir');

rulesDirPlugin.RULES_DIR = 'build/eslint/rules/';
const utils = require('./build/utils');

module.exports = {
root: true,

env: {
'browser': true,
'es6': true,
'node': true,
'vue/setup-compiler-macros': true,
},

parser: 'vue-eslint-parser',

parserOptions: {
parser: '@babel/eslint-parser',
ecmaVersion: 2020,
extraFileExtensions: ['.vue'],
sourceType: 'module',
},

plugins: ['@kiwiirc', 'jsdoc'],

extends: [
'plugin:vue/recommended',
'plugin:vue/vue3-recommended',
'eslint:recommended',
'@vue/airbnb',
'standard',
],
env: {
browser: true,

settings: {
'import/resolver': {
alias: {
map: [
['@', utils.pathResolve('src')],
],
extensions: ['.js', '.vue', '.json'],
},
},
},
// required to lint *.vue files
plugins: [
'rulesdir',
'vue',
],
// add your custom rules here

rules: {
'no-console': process.env.NODE_ENV === 'production' ? 'error' : 'off',
'no-debugger': process.env.NODE_ENV === 'production' ? 'error' : 'off',
'rulesdir/class-name-prefix': 'warn',
'no-console': process.env.NODE_ENV === 'production' ? 'error' : 'warn',
'no-debugger': process.env.NODE_ENV === 'production' ? 'error' : 'warn',

'@kiwiirc/class-name-prefix': 'warn',

'class-methods-use-this': 0,
'comma-dangle': ['error', {
arrays: 'always-multiline',
Expand All @@ -36,10 +55,16 @@ module.exports = {
}],
'import/extensions': 0,
'import/no-cycle': 0,
'import/no-extraneous-dependencies': 0,
'import/no-unresolved': 0,
'import/no-unresolved': [2, {
ignore: [
// These files will not exist if lint is run before the first build
'/res/locales/available\\.json$',
'/static/locales/\\S+\\.json$',
],
}],
'import/prefer-default-export': 0,
'indent': ['error', 4],
// 'max-len': ['error', { code: 120 }],
'max-classes-per-file': 0,
'no-continue': 0,
'no-else-return': 0,
Expand All @@ -57,9 +82,19 @@ module.exports = {
'prefer-template': 0,
'quote-props': ['error', 'consistent-as-needed'],
'semi': ['error', 'always'],
'strict': 0,
'space-before-function-paren': ['error', 'never'],
'vue/component-definition-name-casing': 0,
'vue/html-indent': ['error', 4],
// 'vue/max-len': [
// 'error',
// {
// code: 120,
// template: 120,
// tabWidth: 4,
// comments: 120,
// },
// ],
'vue/max-attributes-per-line': 0,
'vue/multi-word-component-names': 0,
'vue/multiline-html-element-content-newline': 0,
Expand All @@ -69,6 +104,7 @@ module.exports = {
'vue/one-component-per-file': 0,
'vue/require-default-prop': 0,
'vue/require-prop-types': 0,
'vue/script-setup-uses-vars': 'error',
'vue/singleline-html-element-content-newline': 0,
'vuejs-accessibility/anchor-has-content': 0,
'vuejs-accessibility/click-events-have-key-events': 0,
Expand All @@ -77,14 +113,38 @@ module.exports = {
'vuejs-accessibility/interactive-supports-focus': 0,
'vuejs-accessibility/label-has-for': 0,
'vuejs-accessibility/mouse-events-have-key-events': 0,

// TODO vue3
'multiline-ternary': 0,
'vue/operator-linebreak': 0,
'vue/comma-dangle': 0,
'vue/space-infix-ops': 0,
'vue/object-curly-newline': 0,
'vue/object-curly-spacing': 0,
'vue/key-spacing': 0,
'vue/no-template-target-blank': 0,
'vue/no-setup-props-destructure': 0,
'vue/no-v-for-template-key': 0,
'vue/quote-props': 0,
'vue/require-explicit-emits': 0,
'vue/v-on-event-hyphenation': 0,
},
overrides: [{
files: [
'**/__tests__/*.{j,t}s?(x)',
'**/tests/unit/**/*.spec.{j,t}s?(x)',
],
env: {
jest: true,
overrides: [
{
files: [
'**/__tests__/*.{j,t}s?(x)',
'**/tests/unit/**/*.spec.{j,t}s?(x)',
],
env: {
jest: true,
},
},
}],
{
files: ['webpack.config.js', 'build/**/*.js'],
rules: {
'import/no-extraneous-dependencies': 0,
'no-console': 0,
},
},
],
};
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ node_modules/
src/res/locales/available.json
static/config.local.json
tests/coverage
src/libs/external


# local env files
Expand Down
2 changes: 1 addition & 1 deletion .prettierrc.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
module.exports = {
printWidth: 120,
printWidth: 100,
quoteProps: 'consistent',
semi: true,
singleQuote: true,
Expand Down
51 changes: 46 additions & 5 deletions .stylelintrc.js
Original file line number Diff line number Diff line change
@@ -1,21 +1,62 @@
module.exports = {
extends: ['stylelint-config-standard', 'stylelint-config-recommended-vue'],
plugins: ['@stylistic/stylelint-plugin'],
extends: [
'stylelint-config-standard',
'stylelint-config-recommended',
'stylelint-config-recommended-vue',
'stylelint-config-standard-scss',
'stylelint-config-recommended-scss',
'stylelint-config-recess-order',
],
overrides: [
{
files: ['**/*.html'],
files: ['**/*.vue', '**/*.html'],
customSyntax: 'postcss-html',
},
],
rules: {
'alpha-value-notation': null,
'color-function-notation': null,
'declaration-block-no-redundant-longhand-properties': null,
'declaration-no-important': true,
'indentation': 4,
'media-feature-range-notation': null,
'no-descending-specificity': null,
'no-empty-first-line': null,
'number-max-precision': null,
'order/properties-order': null,
'property-no-vendor-prefix': null,
'scss/at-rule-no-unknown': [
true,
{
ignoreAtRules: [
'each',
'else',
'extends',
'for',
'function',
'if',
'ignores',
'include',
'media',
'mixin',
'return',
'use',

// Font Awesome 4
'fa-font-path',
],
},
],
'scss/double-slash-comment-empty-line-before': null,
'scss/double-slash-comment-whitespace-inside': null,
'selector-class-pattern': null,
'shorthand-property-no-redundant-values': null,
'string-quotes': 'single',

'@stylistic/color-hex-case': 'lower',
'@stylistic/indentation': 4,
// '@stylistic/no-empty-first-line': true,
'@stylistic/number-leading-zero': 'always',
'@stylistic/property-case': 'lower',
'@stylistic/string-quotes': 'single',
'@stylistic/unit-case': 'lower',
},
};
15 changes: 2 additions & 13 deletions babel.config.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
module.exports = {
presets: [
[
'@vue/cli-plugin-babel/preset',
'@babel/preset-env',
{
useBuiltIns: 'entry',
modules: 'commonjs',
Expand All @@ -10,16 +10,5 @@ module.exports = {
],
],
plugins: [['@babel/plugin-transform-runtime', { corejs: 3, useESModules: true }]],
env: {
test: {
plugins: [
[
'istanbul',
{
exclude: ['**/*.spec.js'],
},
],
],
},
},
exclude: [/core-js/],
};
Loading