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

Improve & update plugin #91

Open
wants to merge 5 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
4 changes: 2 additions & 2 deletions .eslintignore
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
webpack.config.js
/dist/
/node_modules/
/dist/
95 changes: 80 additions & 15 deletions .eslintrc.js
Original file line number Diff line number Diff line change
@@ -1,22 +1,49 @@
const utils = require('./build/utils');

module.exports = {
root: true,

env: {
browser: true,
es6: true,
node: true,
},

parser: 'vue-eslint-parser',

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

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

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

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

rules: {
'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 @@ -26,32 +53,51 @@ module.exports = {
functions: 'ignore',
}],
'import/extensions': 0,
'import/no-extraneous-dependencies': 0,
'import/no-unresolved': 0,
'import/no-cycle': 0,
'import/prefer-default-export': 0,
'indent': ['error', 4],
// 'max-len': ['error', { code: 120 }],
'max-classes-per-file': 0,
'no-continue': 0,
'no-control-regex': 0,
'no-else-return': 0,
'no-multi-assign': 0,
'no-param-reassign': ['error', { props: false }],
'no-plusplus': 0,
'no-prototype-builtins': 0,
'prefer-promise-reject-errors': 0,
'quote-props': ['error', 'consistent-as-needed'],
'no-control-regex': 0,
'object-shorthand': 0,
'operator-linebreak': 0,
'prefer-const': 0,
'prefer-destructuring': 0,
'prefer-object-spread': 0,
'prefer-promise-reject-errors': 0,
'prefer-template': 0,
'quote-props': ['error', 'consistent-as-needed'],
'semi': ['error', 'always'],
'space-before-function-paren': ['error', 'never'],
'vue/html-closing-bracket-spacing': 0,
'space-before-function-paren': ['error', {
anonymous: 'always',
named: 'never',
asyncArrow: 'always',
}],
'vue/html-indent': ['error', 4],
'vue/max-len': [
'error',
{
code: 120,
template: 120,
tabWidth: 4,
comments: 120,
ignoreComments: true,
},
],
'vue/max-attributes-per-line': 0,
'vue/multi-word-component-names': 0,
'vue/multiline-html-element-content-newline': 0,
'vue/no-mutating-props': 0,
'vue/no-mutating-props': ['error', {
shallowOnly: true,
}],
'vue/no-v-html': 0,
'vue/prefer-template': 0,
'vue/require-default-prop': 0,
'vue/require-prop-types': 0,
'vue/singleline-html-element-content-newline': 0,
'vuejs-accessibility/anchor-has-content': 0,
Expand All @@ -61,5 +107,24 @@ module.exports = {
'vuejs-accessibility/interactive-supports-focus': 0,
'vuejs-accessibility/label-has-for': 0,
'vuejs-accessibility/mouse-events-have-key-events': 0,
'vuejs-accessibility/media-has-caption': 0,
},
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,
},
},
],
};
2 changes: 1 addition & 1 deletion .gitignore
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
.DS_Store
.yarn/
dist/
node_modules/

Expand All @@ -13,7 +14,6 @@ yarn-error.log*

# Editor directories and files
.idea
.vscode
*.suo
*.ntvs*
*.njsproj
Expand Down
9 changes: 9 additions & 0 deletions .prettierrc.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
module.exports = {
printWidth: 120,
quoteProps: 'consistent',
semi: true,
singleQuote: true,
trailingComma: 'es5',
tabWidth: 4,
jsdocVerticalAlignment: true,
};
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',
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: ['*.vue', '**/*.vue'],
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',
},
};
8 changes: 8 additions & 0 deletions .vscode/extensions.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
{
"recommendations": [
"vue.volar",
"dbaeumer.vscode-eslint",
"stylelint.vscode-stylelint",
"rvest.vs-code-prettier-eslint"
]
}
23 changes: 23 additions & 0 deletions .vscode/settings.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
{
"files.eol": "\n",
"files.insertFinalNewline": true,
"files.trimFinalNewlines": true,
"files.trimTrailingWhitespace": true,
"stylelint.validate": [
"vue",
"css",
"less",
"sass",
"scss",
"postcss"
],
"[javascript]": {
"editor.defaultFormatter": "rvest.vs-code-prettier-eslint"
},
"[vue]": {
"editor.defaultFormatter": "rvest.vs-code-prettier-eslint"
},
"[css]": {
"editor.defaultFormatter": "rvest.vs-code-prettier-eslint"
},
}
1 change: 1 addition & 0 deletions .yarnrc.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
nodeLinker: node-modules
23 changes: 13 additions & 10 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -42,21 +42,23 @@ Note that the "secure" option enables JWT authentication, but will not work on J
Jitsi Meet supports extra configuration to customise its interface and functions. You can configure these via the optional `interfaceConfigOverwrite` and `configOverwrite` config options.

The defaults are:
~~~json
"conference": {
~~~json5
"plugin-conference": {
"secure": false,
"server": "meet.jit.si",
"queries": true,
"channels": true,
"closeOnLeave": true,
"buttonIcon": "fa-phone",
"viewHeight": "40%",
"enabledInChannels": ["*"],
"enabledInChannels": [],
"disabledInChannels": [],
"groupInvitesTTL": 30000,
"maxParticipantsLength": 60,
"participantsMore": "more...",
// These messages are sent to irc for users not using the plugin
// Users with the plugin will see the translations
"inviteText": "{{ nick }} is inviting you to a private call.",
"joinText": "{{ nick }} has joined the conference.",
"joinButtonText": "Join now!",
"showLink": false,
"useLinkShortener": false,
"linkShortenerURL": "https://x0.no/api/?{{ link }}",
Expand All @@ -65,9 +67,10 @@ The defaults are:
"SHOW_JITSI_WATERMARK": false,
"SHOW_WATERMARK_FOR_GUESTS": false,
"TOOLBAR_BUTTONS": [
"microphone", "camera", "fullscreen", "hangup",
"settings", "videoquality", "filmstrip", "fodeviceselection",
"stats", "shortcuts",
"camera", "closedcaptions", "desktop", "etherpad", "filmstrip",
"fullscreen", "hangup", "help", "highlight", "livestreaming",
"microphone", "noisesuppression", "raisehand", "select-background",
"settings", "shortcuts", "stats", "tileview", "toggle-camera",
],
},
"configOverwrite": {
Expand Down Expand Up @@ -96,7 +99,7 @@ More info about Jitsi's options can be found in these files:
* https://github.com/jitsi/jitsi-meet/blob/master/interface_config.js
* https://github.com/jitsi/jitsi-meet/blob/master/config.js

You may also choose to hide the conference call icon in either channels or private messages:
You may also choose to hide the conference call icon in either channels or direct messages:
```json
{
"channels": false,
Expand All @@ -108,4 +111,4 @@ Running your own conference server allows you to secure your conference rooms. W

## License

[ Licensed under the Apache License, Version 2.0](LICENSE).
[Licensed under the Apache License, Version 2.0](LICENSE).
Loading