Skip to content

Commit

Permalink
Merge pull request #1 from hirasaki1985/feature/v1.0.1_localstorage_f…
Browse files Browse the repository at this point in the history
…ix_bug_white_list

Feature/v1.0.1 localstorage fix bug white list
  • Loading branch information
hirasaki1985 authored Nov 8, 2024
2 parents 3129035 + f83ac8c commit c1065b8
Show file tree
Hide file tree
Showing 63 changed files with 1,342 additions and 880 deletions.
5 changes: 5 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,11 @@ googleミートの参加者でタイマーを共有する。
5. zipディレクトリにzipファイルが作成されているのを確認
6. zipファイルを解凍しておく

#### .envの値について
`VITE_APP_WHITE_LIST`でタイマーを表示するミーティングIDをカンマ区切りで設定できる。
もし`aaa-aaaa-aaa,bbb-bbbb-bbb,ccc*`と設定すれば、`aaa-aaaa-aaa,bbb-bbbb-bbb,頭がccc`のミーティングIDが対象となる。
`VITE_APP_WHITE_LIST=*`とすれば全てのミーティングIDで表示されるようになる。

### 1-3. プラグインの登録
1. Google Chromeの右上のアイコンで「拡張機能を管理」をクリック

Expand Down
3 changes: 3 additions & 0 deletions plugin/.env.sample
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
## App
VITE_APP_WHITE_LIST=*

## Firebase
VITE_FIREBASE_API_KEY=
VITE_FIREBASE_AUTH_DOMAIN=
Expand Down
38 changes: 31 additions & 7 deletions plugin/.eslintrc.json
Original file line number Diff line number Diff line change
@@ -1,13 +1,37 @@
{
"env": {
"browser": true,
"es2021": true,
"jest": true
},
"parser": "@typescript-eslint/parser",
"parserOptions": {
"ecmaVersion": "latest",
"sourceType": "module",
},
"plugins": ["@typescript-eslint/eslint-plugin"],
"extends": ["plugin:@typescript-eslint/recommended"],
"env": {
"node": true,
"sourceType": "module"
},
"rules": {}
"plugins": ["react", "react-hooks", "@typescript-eslint", "prettier", "jest"],
"extends": [
"eslint:recommended",
"plugin:react/recommended",
"plugin:react-hooks/recommended",
"plugin:@typescript-eslint/recommended",
"prettier"
],
"rules": {
"camelcase": "error",
"spaced-comment": "error",
"quotes": ["error", "single"],
"no-duplicate-imports": "error",

"@typescript-eslint/no-empty-function": "off",
"@typescript-eslint/no-empty-interface": "off",
"@typescript-eslint/no-unused-vars": "off",
"@typescript-eslint/no-namespace": "off",

"react/react-in-jsx-scope": "off",
"react/display-name": "off",
"react-hooks/rules-of-hooks": "off",
"react-hooks/exhaustive-deps": "off",
"react/prop-types": "off"
}
}
13 changes: 13 additions & 0 deletions plugin/.prettierignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
# Ignore artifacts:
node_modules
package-lock.json
.eslintrc.json
public
src/setupTests.ts
src/openapi
craco.config.js
jest.config.js
next.config.js
next-env.d.ts
.swc
coverage
7 changes: 6 additions & 1 deletion plugin/.prettierrc
Original file line number Diff line number Diff line change
@@ -1,4 +1,9 @@
{
"semi": false,
"tabWidth": 2,
"printWidth": 100,
"singleQuote": true,
"trailingComma": "all"
"trailingComma": "all",
"jsxSingleQuote": true,
"bracketSpacing": true
}
6 changes: 0 additions & 6 deletions plugin/babel.config.js

This file was deleted.

4 changes: 3 additions & 1 deletion plugin/jest.config.cjs → plugin/jest.config.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/** @type {import('ts-jest/dist/types').InitialOptionsTsJest} */
module.exports = {
export default {
preset: 'ts-jest',
testEnvironment: 'node',
testMatch: ['<rootDir>/**/__test__/**/*.test.{ts,tsx}'],
Expand All @@ -22,3 +22,5 @@ module.exports = {
customExportConditions: [''],
},
};


4 changes: 2 additions & 2 deletions plugin/manifest.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "GoogleMeetTimer",
"version": "1.0.0",
"manifest_version": 3,
"version": "1.0.1",
"manifest_version": 4,
"description": "Timer on Google Meet.",
"action": {
"default_popup": "popup.html"
Expand Down
19 changes: 12 additions & 7 deletions plugin/package.json
Original file line number Diff line number Diff line change
@@ -1,11 +1,13 @@
{
"name": "plugin",
"version": "1.0.0",
"version": "1.0.1",
"main": "dist/index.js",
"type": "module",
"scripts": {
"dev": "vite",
"test": "jest --runInBand --no-cache",
"lint:fix": "eslint --fix 'src/**/*.{js,jsx,ts,tsx,json}'",
"format": "prettier --write 'src/**/*.{js,jsx,ts,tsx,css,md,json}' --config ./.prettierrc",
"build": "pnpm build:clean && pnpm run build:vite && pnpm run build:css && pnpm run build:zip",
"build:clean": "rm -rf ./dist",
"build:vite": "vite build",
Expand All @@ -24,16 +26,21 @@
"@types/chrome": "^0.0.278",
"@types/jest": "^29.5.14",
"@types/node": "^22.7.7",
"@types/react": "^18.3.12",
"@types/react-dom": "^18.3.1",
"@typescript-eslint/eslint-plugin": "^5.0.0",
"@typescript-eslint/parser": "^5.0.0",
"@vitejs/plugin-react": "^4.3.3",
"autoprefixer": "^10.4.20",
"babel-jest": "^29.7.0",
"copyfiles": "^2.4.1",
"eslint": "^9.13.0",
"eslint-config-prettier": "^9.1.0",
"eslint-plugin-prettier": "^4.0.0",
"eslint-plugin-react": "^7.37.1",
"eslint": "^8.22.0",
"eslint-config-prettier": "^8.5.0",
"eslint-plugin-jest": "^26.8.7",
"eslint-plugin-prettier": "^4.2.1",
"eslint-plugin-react": "^7.30.1",
"eslint-plugin-react-hooks": "^4.6.0",
"eslint-plugin-storybook": "^0.8.0",
"globals": "^15.11.0",
"jest": "^29.7.0",
"postcss": "^8.4.47",
Expand All @@ -49,8 +56,6 @@
"vite-plugin-static-copy": "^2.0.0"
},
"dependencies": {
"@types/react": "^18.3.11",
"@types/react-dom": "^18.3.1",
"dayjs": "^1.11.13",
"firebase": "^10.14.1",
"react": "^18.3.1",
Expand Down
Loading

0 comments on commit c1065b8

Please sign in to comment.