From 8bb7d207087aa4e8f32f468bf159abdb413c4816 Mon Sep 17 00:00:00 2001 From: Rob Gries Date: Mon, 27 May 2024 09:47:16 -0400 Subject: [PATCH] Use npm package to fix deploy issues --- bookmarklet/README.md | 1 + bookmarklet/package.json | 8 ++++++-- package-lock.json | 21 +++++++++++++-------- package.json | 2 +- src/components/pages/PageBase.jsx | 6 ++---- 5 files changed, 23 insertions(+), 15 deletions(-) create mode 100644 bookmarklet/README.md diff --git a/bookmarklet/README.md b/bookmarklet/README.md new file mode 100644 index 00000000..0c638e77 --- /dev/null +++ b/bookmarklet/README.md @@ -0,0 +1 @@ +# bookmarklet diff --git a/bookmarklet/package.json b/bookmarklet/package.json index 14cd68d5..c0292df8 100644 --- a/bookmarklet/package.json +++ b/bookmarklet/package.json @@ -1,5 +1,5 @@ { - "name": "bookmarklet", + "name": "@code-with-durham/bookmarklet", "version": "0.1.0", "description": "Bookmark that forwards Portal case info for parsing", "main": "index.js", @@ -7,5 +7,9 @@ "test": "echo \"Error: no test specified\" && exit 1" }, "author": "Rob Gries", - "license": "ISC" + "license": "ISC", + "repository": { + "type": "git", + "url": "https://github.com/deardurham/dear-petition/bookmarklet" + } } diff --git a/package-lock.json b/package-lock.json index aac282ac..d2888a22 100644 --- a/package-lock.json +++ b/package-lock.json @@ -8,6 +8,7 @@ "name": "dearpetition", "version": "0.1.0", "dependencies": { + "@code-with-durham/bookmarklet": "0.1.0", "@fortawesome/fontawesome-svg-core": "^1.2.35", "@fortawesome/free-solid-svg-icons": "^5.15.3", "@fortawesome/react-fontawesome": "^0.1.14", @@ -15,7 +16,6 @@ "@popperjs/core": "^2.11.2", "@reduxjs/toolkit": "^1.7.2", "axios": "^0.21.2", - "bookmarklet": "file:./bookmarklet", "classnames": "^2.3.1", "date-fns": "^2.28.0", "file-saver": "^2.0.5", @@ -57,7 +57,9 @@ } }, "bookmarklet": { + "name": "@code-with-durham/bookmarklet", "version": "0.1.0", + "extraneous": true, "license": "ISC" }, "node_modules/@adobe/css-tools": { @@ -554,6 +556,11 @@ "node": ">=6.9.0" } }, + "node_modules/@code-with-durham/bookmarklet": { + "version": "0.1.0", + "resolved": "https://registry.npmjs.org/@code-with-durham/bookmarklet/-/bookmarklet-0.1.0.tgz", + "integrity": "sha512-ETkdcMwl/fC735OzcqOtsCi4hXRkh9ia+Lia7b8HTfXDZfbvbfvqLlnyUhuwRLfWtuPPX9bARgEaNTkUXf8GOQ==" + }, "node_modules/@emotion/babel-plugin": { "version": "11.11.0", "resolved": "https://registry.npmjs.org/@emotion/babel-plugin/-/babel-plugin-11.11.0.tgz", @@ -2270,10 +2277,6 @@ "node": ">=8" } }, - "node_modules/bookmarklet": { - "resolved": "bookmarklet", - "link": true - }, "node_modules/brace-expansion": { "version": "1.1.11", "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.11.tgz", @@ -8093,6 +8096,11 @@ "to-fast-properties": "^2.0.0" } }, + "@code-with-durham/bookmarklet": { + "version": "0.1.0", + "resolved": "https://registry.npmjs.org/@code-with-durham/bookmarklet/-/bookmarklet-0.1.0.tgz", + "integrity": "sha512-ETkdcMwl/fC735OzcqOtsCi4hXRkh9ia+Lia7b8HTfXDZfbvbfvqLlnyUhuwRLfWtuPPX9bARgEaNTkUXf8GOQ==" + }, "@emotion/babel-plugin": { "version": "11.11.0", "resolved": "https://registry.npmjs.org/@emotion/babel-plugin/-/babel-plugin-11.11.0.tgz", @@ -9314,9 +9322,6 @@ "integrity": "sha512-jDctJ/IVQbZoJykoeHbhXpOlNBqGNcwXJKJog42E5HDPUwQTSdjCHdihjj0DlnheQ7blbT6dHOafNAiS8ooQKA==", "dev": true }, - "bookmarklet": { - "version": "file:bookmarklet" - }, "brace-expansion": { "version": "1.1.11", "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.11.tgz", diff --git a/package.json b/package.json index d5abd649..a8512ec7 100644 --- a/package.json +++ b/package.json @@ -10,7 +10,7 @@ "@popperjs/core": "^2.11.2", "@reduxjs/toolkit": "^1.7.2", "axios": "^0.21.2", - "bookmarklet": "file:./bookmarklet", + "@code-with-durham/bookmarklet": "0.1.0", "classnames": "^2.3.1", "date-fns": "^2.28.0", "file-saver": "^2.0.5", diff --git a/src/components/pages/PageBase.jsx b/src/components/pages/PageBase.jsx index a976a9fd..e052cff0 100644 --- a/src/components/pages/PageBase.jsx +++ b/src/components/pages/PageBase.jsx @@ -23,10 +23,8 @@ import { DropdownMenu } from '../elements/DropdownMenu'; import { FontAwesomeIcon } from '@fortawesome/react-fontawesome'; import { faCaretDown, faExternalLinkAlt } from '@fortawesome/free-solid-svg-icons'; -// eslint-disable-next-line import/no-unresolved -import { generateBookmarklet } from 'bookmarklet'; -// eslint-disable-next-line import/no-unresolved -import bookmarkletMetadata from 'bookmarklet/package.json'; +import { generateBookmarklet } from '@code-with-durham/bookmarklet'; +import bookmarkletMetadata from '@code-with-durham/bookmarklet/package.json'; const bookmarkletVersion = `v${bookmarkletMetadata.version}`;