diff --git a/custom.d.ts b/custom.d.ts new file mode 100644 index 0000000..5537959 --- /dev/null +++ b/custom.d.ts @@ -0,0 +1,8 @@ +import "react"; + +declare module "react" { + interface StyleHTMLAttributes extends React.HTMLAttributes { + jsx?: boolean; + global?: boolean; + } +} diff --git a/package-lock.json b/package-lock.json index 6280584..fd3e1bd 100644 --- a/package-lock.json +++ b/package-lock.json @@ -8,8 +8,15 @@ "name": "apple-style-notes-plugin", "version": "1.0.0", "license": "MIT", + "dependencies": { + "react": "^19.0.0", + "react-dom": "^19.0.0", + "zustand": "^5.0.3" + }, "devDependencies": { "@types/node": "^16.11.6", + "@types/react": "^19.0.4", + "@types/react-dom": "^19.0.2", "@typescript-eslint/eslint-plugin": "5.29.0", "@typescript-eslint/parser": "5.29.0", "builtin-modules": "3.3.0", @@ -602,6 +609,26 @@ "dev": true, "license": "MIT" }, + "node_modules/@types/react": { + "version": "19.0.4", + "resolved": "https://registry.npmmirror.com/@types/react/-/react-19.0.4.tgz", + "integrity": "sha512-3O4QisJDYr1uTUMZHA2YswiQZRq+Pd8D+GdVFYikTutYsTz+QZgWkAPnP7rx9txoI6EXKcPiluMqWPFV3tT9Wg==", + "devOptional": true, + "license": "MIT", + "dependencies": { + "csstype": "^3.0.2" + } + }, + "node_modules/@types/react-dom": { + "version": "19.0.2", + "resolved": "https://registry.npmmirror.com/@types/react-dom/-/react-dom-19.0.2.tgz", + "integrity": "sha512-c1s+7TKFaDRRxr1TxccIX2u7sfCnc3RxkVyBIUA2lCpyqCF+QoAwQ/CBg7bsMdVwP120HEH143VQezKtef5nCg==", + "dev": true, + "license": "MIT", + "peerDependencies": { + "@types/react": "^19.0.0" + } + }, "node_modules/@types/tern": { "version": "0.23.9", "resolved": "https://registry.npmmirror.com/@types/tern/-/tern-0.23.9.tgz", @@ -1022,6 +1049,13 @@ "node": ">= 8" } }, + "node_modules/csstype": { + "version": "3.1.3", + "resolved": "https://registry.npmmirror.com/csstype/-/csstype-3.1.3.tgz", + "integrity": "sha512-M1uQkMl8rQK/szD0LNhtqxIPLpimGm8sOBwU7lLnCpSbTyY3yeU1Vc7l4KT5zT4s/yOxHH5O7tIuuLOCnLADRw==", + "devOptional": true, + "license": "MIT" + }, "node_modules/debug": { "version": "4.4.0", "resolved": "https://registry.npmmirror.com/debug/-/debug-4.4.0.tgz", @@ -2056,6 +2090,27 @@ ], "license": "MIT" }, + "node_modules/react": { + "version": "19.0.0", + "resolved": "https://registry.npmmirror.com/react/-/react-19.0.0.tgz", + "integrity": "sha512-V8AVnmPIICiWpGfm6GLzCR/W5FXLchHop40W4nXBmdlEceh16rCN8O8LNWm5bh5XUX91fh7KpA+W0TgMKmgTpQ==", + "license": "MIT", + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/react-dom": { + "version": "19.0.0", + "resolved": "https://registry.npmmirror.com/react-dom/-/react-dom-19.0.0.tgz", + "integrity": "sha512-4GV5sHFG0e/0AD4X+ySy6UJd3jVl1iNsNHdpad0qhABJ11twS3TTBnseqsKurKcsNqCEFeGL3uLpVChpIO3QfQ==", + "license": "MIT", + "dependencies": { + "scheduler": "^0.25.0" + }, + "peerDependencies": { + "react": "^19.0.0" + } + }, "node_modules/regexpp": { "version": "3.2.0", "resolved": "https://registry.npmmirror.com/regexpp/-/regexpp-3.2.0.tgz", @@ -2133,6 +2188,12 @@ "queue-microtask": "^1.2.2" } }, + "node_modules/scheduler": { + "version": "0.25.0", + "resolved": "https://registry.npmmirror.com/scheduler/-/scheduler-0.25.0.tgz", + "integrity": "sha512-xFVuu11jh+xcO7JOAGJNOXld8/TcEHK/4CituBUeUb5hqxJLj9YuemAEuvm9gQ/+pgXYfbQuqAkiYu+u7YEsNA==", + "license": "MIT" + }, "node_modules/semver": { "version": "7.6.3", "resolved": "https://registry.npmmirror.com/semver/-/semver-7.6.3.tgz", @@ -2392,6 +2453,35 @@ "funding": { "url": "https://github.com/sponsors/sindresorhus" } + }, + "node_modules/zustand": { + "version": "5.0.3", + "resolved": "https://registry.npmmirror.com/zustand/-/zustand-5.0.3.tgz", + "integrity": "sha512-14fwWQtU3pH4dE0dOpdMiWjddcH+QzKIgk1cl8epwSE7yag43k/AD/m4L6+K7DytAOr9gGBe3/EXj9g7cdostg==", + "license": "MIT", + "engines": { + "node": ">=12.20.0" + }, + "peerDependencies": { + "@types/react": ">=18.0.0", + "immer": ">=9.0.6", + "react": ">=18.0.0", + "use-sync-external-store": ">=1.2.0" + }, + "peerDependenciesMeta": { + "@types/react": { + "optional": true + }, + "immer": { + "optional": true + }, + "react": { + "optional": true + }, + "use-sync-external-store": { + "optional": true + } + } } } } diff --git a/package.json b/package.json index 0cf1604..5cada08 100644 --- a/package.json +++ b/package.json @@ -13,6 +13,8 @@ "license": "MIT", "devDependencies": { "@types/node": "^16.11.6", + "@types/react": "^19.0.4", + "@types/react-dom": "^19.0.2", "@typescript-eslint/eslint-plugin": "5.29.0", "@typescript-eslint/parser": "5.29.0", "builtin-modules": "3.3.0", @@ -20,5 +22,10 @@ "obsidian": "latest", "tslib": "2.4.0", "typescript": "4.7.4" + }, + "dependencies": { + "react": "^19.0.0", + "react-dom": "^19.0.0", + "zustand": "^5.0.3" } } diff --git a/tsconfig.json b/tsconfig.json index 1d53216..a5eda17 100644 --- a/tsconfig.json +++ b/tsconfig.json @@ -12,7 +12,8 @@ "isolatedModules": true, "strictNullChecks": true, "lib": ["DOM", "ES5", "ES6", "ES7"], - "jsx": "react-jsx" + "jsx": "react-jsx", + "allowSyntheticDefaultImports": true }, - "include": ["**/*.ts"] + "include": ["**/*.ts", "**/*.tsx"] }