@tryghost/comments-ui 0.12.3 → 0.13.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +1 -1
- package/README.md +8 -70
- package/package.json +51 -61
- package/umd/comments-ui.min.js +139 -3
- package/umd/comments-ui.min.js.map +1 -1
- package/.env +0 -1
- package/umd/comments-ui.min.js.LICENSE.txt +0 -43
- package/umd/main.css +0 -1
package/LICENSE
CHANGED
package/README.md
CHANGED
|
@@ -1,79 +1,17 @@
|
|
|
1
|
-
# Comments
|
|
1
|
+
# Comments UI
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
Comments widget that is embedded at the bottom of posts in Ghost.
|
|
4
4
|
|
|
5
|
-
|
|
5
|
+
## Development
|
|
6
6
|
|
|
7
|
-
|
|
7
|
+
### Pre-requisites
|
|
8
8
|
|
|
9
|
-
|
|
9
|
+
- Run `yarn` in Ghost monorepo root
|
|
10
10
|
|
|
11
|
-
|
|
12
|
-
- Open [http://localhost:3000](http://localhost:3000) to view it in the browser.
|
|
13
|
-
- To use the local Comments script in a local Ghost site
|
|
14
|
-
- Update `config.local.json` in Ghost repo to add "comments" config pointing to local dev server url as instructed on terminal.
|
|
15
|
-
- By default, this uses port `5368` for loading local Comments script on Ghost site. It's also possible to specify a custom port when running the script using - `--port=xxxx`.
|
|
16
|
-
|
|
17
|
-
## Available Scripts
|
|
18
|
-
|
|
19
|
-
In the project directory, you can run:
|
|
20
|
-
|
|
21
|
-
### `yarn test`
|
|
22
|
-
|
|
23
|
-
Launches the test runner in the interactive watch mode.\
|
|
24
|
-
See the section about [running tests](https://facebook.github.io/create-react-app/docs/running-tests) for more information.
|
|
25
|
-
|
|
26
|
-
### `yarn build`
|
|
27
|
-
|
|
28
|
-
Builds the app for production to the `build` folder.\
|
|
29
|
-
It correctly bundles React in production mode and optimizes the build for the best performance.
|
|
30
|
-
|
|
31
|
-
The build is minified and the filenames include the hashes.\
|
|
32
|
-
Your app is ready to be deployed!
|
|
33
|
-
|
|
34
|
-
See the section about [deployment](https://facebook.github.io/create-react-app/docs/deployment) for more information.
|
|
35
|
-
|
|
36
|
-
### `yarn eject`
|
|
37
|
-
|
|
38
|
-
**Note: this is a one-way operation. Once you `eject`, you can't go back!**
|
|
39
|
-
|
|
40
|
-
If you aren't satisfied with the build tool and configuration choices, you can `eject` at any time. This command will remove the single build dependency from your project.
|
|
41
|
-
|
|
42
|
-
Instead, it will copy all the configuration files and the transitive dependencies (webpack, Babel, ESLint, etc) right into your project so you have full control over them. All of the commands except `eject` will still work, but they will point to the copied scripts so you can tweak them. At this point you're on your own.
|
|
43
|
-
|
|
44
|
-
You don't have to ever use `eject`. The curated feature set is suitable for small and middle deployments, and you shouldn't feel obligated to use this feature. However we understand that this tool wouldn't be useful if you couldn't customize it when you are ready for it.
|
|
45
|
-
|
|
46
|
-
## Learn More
|
|
47
|
-
|
|
48
|
-
You can learn more in the [Create React App documentation](https://facebook.github.io/create-react-app/docs/getting-started).
|
|
49
|
-
|
|
50
|
-
To learn React, check out the [React documentation](https://reactjs.org/).
|
|
51
|
-
|
|
52
|
-
### Code Splitting
|
|
53
|
-
|
|
54
|
-
This section has moved here: [https://facebook.github.io/create-react-app/docs/code-splitting](https://facebook.github.io/create-react-app/docs/code-splitting)
|
|
55
|
-
|
|
56
|
-
### Analyzing the Bundle Size
|
|
57
|
-
|
|
58
|
-
This section has moved here: [https://facebook.github.io/create-react-app/docs/analyzing-the-bundle-size](https://facebook.github.io/create-react-app/docs/analyzing-the-bundle-size)
|
|
59
|
-
|
|
60
|
-
### Making a Progressive Web App
|
|
61
|
-
|
|
62
|
-
This section has moved here: [https://facebook.github.io/create-react-app/docs/making-a-progressive-web-app](https://facebook.github.io/create-react-app/docs/making-a-progressive-web-app)
|
|
63
|
-
|
|
64
|
-
### Advanced Configuration
|
|
65
|
-
|
|
66
|
-
This section has moved here: [https://facebook.github.io/create-react-app/docs/advanced-configuration](https://facebook.github.io/create-react-app/docs/advanced-configuration)
|
|
67
|
-
|
|
68
|
-
### Deployment
|
|
69
|
-
|
|
70
|
-
This section has moved here: [https://facebook.github.io/create-react-app/docs/deployment](https://facebook.github.io/create-react-app/docs/deployment)
|
|
71
|
-
|
|
72
|
-
### `yarn build` fails to minify
|
|
73
|
-
|
|
74
|
-
This section has moved here: [https://facebook.github.io/create-react-app/docs/troubleshooting#npm-run-build-fails-to-minify](https://facebook.github.io/create-react-app/docs/troubleshooting#npm-run-build-fails-to-minify)
|
|
11
|
+
### Running via Ghost `yarn dev` in root folder
|
|
75
12
|
|
|
13
|
+
You can automatically start the comments dev server when developing Ghost by running Ghost (in root folder) via `yarn dev --all` or `yarn dev --comments`. This will host the comments JavaScript files, and makes sure that Ghost uses these locally hosted assets instead of the ones from the CDN.
|
|
76
14
|
|
|
77
15
|
# Copyright & License
|
|
78
16
|
|
|
79
|
-
Copyright (c) 2013-
|
|
17
|
+
Copyright (c) 2013-2023 Ghost Foundation - Released under the [MIT license](LICENSE).
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@tryghost/comments-ui",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.13.0",
|
|
4
4
|
"license": "MIT",
|
|
5
5
|
"repository": "git@github.com:TryGhost/comments-ui.git",
|
|
6
6
|
"author": "Ghost Foundation",
|
|
@@ -14,43 +14,21 @@
|
|
|
14
14
|
"access": "public",
|
|
15
15
|
"registry": "https://registry.npmjs.org/"
|
|
16
16
|
},
|
|
17
|
-
"dependencies": {
|
|
18
|
-
"@headlessui/react": "^1.6.6",
|
|
19
|
-
"@sentry/react": "^7.5.0",
|
|
20
|
-
"@tiptap/core": "^2.0.0-beta.182",
|
|
21
|
-
"@tiptap/extension-blockquote": "^2.0.0-beta.29",
|
|
22
|
-
"@tiptap/extension-document": "^2.0.0-beta.17",
|
|
23
|
-
"@tiptap/extension-hard-break": "^2.0.0-beta.33",
|
|
24
|
-
"@tiptap/extension-link": "^2.0.0-beta.43",
|
|
25
|
-
"@tiptap/extension-paragraph": "^2.0.0-beta.26",
|
|
26
|
-
"@tiptap/extension-placeholder": "^2.0.0-beta.53",
|
|
27
|
-
"@tiptap/extension-text": "^2.0.0-beta.17",
|
|
28
|
-
"@tiptap/react": "^2.0.0-beta.114",
|
|
29
|
-
"react": "17.0.2",
|
|
30
|
-
"react-dom": "17.0.2",
|
|
31
|
-
"react-scripts": "4.0.3"
|
|
32
|
-
},
|
|
33
17
|
"scripts": {
|
|
34
|
-
"
|
|
35
|
-
"
|
|
36
|
-
"
|
|
37
|
-
"
|
|
38
|
-
"
|
|
39
|
-
"
|
|
40
|
-
"
|
|
41
|
-
"
|
|
42
|
-
"test:
|
|
43
|
-
"
|
|
44
|
-
"eject": "react-scripts eject",
|
|
45
|
-
"lint": "eslint src --ext .js --cache",
|
|
18
|
+
"dev": "concurrently \"yarn preview --host -l silent\" \"yarn build:watch\"",
|
|
19
|
+
"dev:test": "vite build && vite preview --port 7175",
|
|
20
|
+
"build": "vite build",
|
|
21
|
+
"build:watch": "vite build --watch",
|
|
22
|
+
"preview": "vite preview",
|
|
23
|
+
"test": "vitest run --coverage && yarn test:e2e",
|
|
24
|
+
"test:e2e": "NODE_OPTIONS='--experimental-specifier-resolution=node --no-warnings' VITE_TEST=true playwright test",
|
|
25
|
+
"test:slowmo": "TIMEOUT=100000 PLAYWRIGHT_SLOWMO=1000 yarn test:e2e --headed",
|
|
26
|
+
"test:e2e:full": "ALL_BROWSERS=1 yarn test:e2e",
|
|
27
|
+
"lint": "eslint src --ext .js,.ts,.jsx,.tsx --cache",
|
|
46
28
|
"preship": "yarn lint",
|
|
47
|
-
"ship": "STATUS=$(git status --porcelain); echo $STATUS; if [ -z \"$STATUS\" ]; then yarn
|
|
48
|
-
"
|
|
49
|
-
"
|
|
50
|
-
"prepublishOnly": "yarn build",
|
|
51
|
-
"tailwind": "npx tailwindcss -i ./src/index.css -o ./public/main.css --watch --minify",
|
|
52
|
-
"cypress:open": "cypress open",
|
|
53
|
-
"cypress": "cypress run"
|
|
29
|
+
"ship": "STATUS=$(git status --porcelain); echo $STATUS; if [ -z \"$STATUS\" ]; then yarn version; fi",
|
|
30
|
+
"postship": "git push ${GHOST_UPSTREAM:-origin} --follow-tags && npm publish",
|
|
31
|
+
"prepublishOnly": "yarn build"
|
|
54
32
|
},
|
|
55
33
|
"browserslist": {
|
|
56
34
|
"production": [
|
|
@@ -64,31 +42,43 @@
|
|
|
64
42
|
"last 1 safari version"
|
|
65
43
|
]
|
|
66
44
|
},
|
|
67
|
-
"
|
|
68
|
-
"@
|
|
69
|
-
"@
|
|
70
|
-
"@
|
|
71
|
-
"
|
|
72
|
-
"
|
|
73
|
-
"
|
|
74
|
-
"
|
|
75
|
-
"
|
|
76
|
-
"
|
|
77
|
-
"
|
|
78
|
-
"
|
|
79
|
-
"
|
|
80
|
-
"
|
|
81
|
-
"
|
|
82
|
-
"ora": "5.4.1",
|
|
83
|
-
"postcss": "^8.4.14",
|
|
84
|
-
"rewire": "6.0.0",
|
|
85
|
-
"serve-handler": "6.1.3",
|
|
86
|
-
"source-map-explorer": "2.5.2",
|
|
87
|
-
"tailwindcss": "^3.1.4",
|
|
88
|
-
"webpack-cli": "3.3.12"
|
|
45
|
+
"dependencies": {
|
|
46
|
+
"@headlessui/react": "1.7.15",
|
|
47
|
+
"@tiptap/core": "2.0.4",
|
|
48
|
+
"@tiptap/extension-blockquote": "2.0.4",
|
|
49
|
+
"@tiptap/extension-document": "2.0.4",
|
|
50
|
+
"@tiptap/extension-hard-break": "2.0.4",
|
|
51
|
+
"@tiptap/extension-link": "2.0.4",
|
|
52
|
+
"@tiptap/extension-paragraph": "2.0.4",
|
|
53
|
+
"@tiptap/extension-placeholder": "2.0.4",
|
|
54
|
+
"@tiptap/extension-text": "2.0.4",
|
|
55
|
+
"@tiptap/pm": "2.0.4",
|
|
56
|
+
"@tiptap/react": "2.0.4",
|
|
57
|
+
"react": "17.0.2",
|
|
58
|
+
"react-dom": "17.0.2",
|
|
59
|
+
"react-string-replace": "1.1.1"
|
|
89
60
|
},
|
|
90
|
-
"
|
|
91
|
-
"
|
|
92
|
-
"
|
|
61
|
+
"devDependencies": {
|
|
62
|
+
"@playwright/test": "1.37.0",
|
|
63
|
+
"@testing-library/jest-dom": "5.16.5",
|
|
64
|
+
"@testing-library/react": "12.1.5",
|
|
65
|
+
"@testing-library/user-event": "14.4.3",
|
|
66
|
+
"@tryghost/i18n": "0.0.0",
|
|
67
|
+
"@vitejs/plugin-react": "4.0.4",
|
|
68
|
+
"@vitest/coverage-v8": "0.33.0",
|
|
69
|
+
"autoprefixer": "10.4.15",
|
|
70
|
+
"bson-objectid": "2.0.4",
|
|
71
|
+
"concurrently": "8.2.1",
|
|
72
|
+
"eslint-plugin-i18next": "6.0.3",
|
|
73
|
+
"eslint-plugin-react-hooks": "4.6.0",
|
|
74
|
+
"eslint-plugin-react-refresh": "0.4.3",
|
|
75
|
+
"eslint-plugin-tailwindcss": "3.13.0",
|
|
76
|
+
"jsdom": "22.1.0",
|
|
77
|
+
"postcss": "8.4.28",
|
|
78
|
+
"tailwindcss": "3.3.3",
|
|
79
|
+
"vite": "4.4.9",
|
|
80
|
+
"vite-plugin-css-injected-by-js": "3.3.0",
|
|
81
|
+
"vite-plugin-svgr": "3.2.0",
|
|
82
|
+
"vitest": "0.34.2"
|
|
93
83
|
}
|
|
94
84
|
}
|