@tryghost/portal 2.37.7 → 2.37.9
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/README.md +30 -26
- package/package.json +4 -4
- package/umd/portal.min.js +48 -48
- package/umd/portal.min.js.map +1 -1
package/README.md
CHANGED
|
@@ -26,45 +26,49 @@ The script also adds custom class names to this element for open and close state
|
|
|
26
26
|
|
|
27
27
|
Refer the [docs](https://ghost.org/help/setup-members/#customize-portal-settings) to read about ways in which Portal can be customized for your site.
|
|
28
28
|
|
|
29
|
-
##
|
|
29
|
+
## Develop
|
|
30
30
|
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
- To use the local Portal script in a local Ghost site
|
|
36
|
-
- Update `config.local.json` in Ghost repo to add "portal" config pointing to local dev server url as instructed on terminal.
|
|
37
|
-
- By default, this uses port `5368` for loading local Portal script on Ghost site. It's also possible to specify a custom port when running the script using - `--port=xxxx`.
|
|
31
|
+
Run Portal within the Ghost monorepo with:
|
|
32
|
+
```
|
|
33
|
+
yarn dev --portal
|
|
34
|
+
```
|
|
38
35
|
|
|
39
|
-
|
|
36
|
+
Alternatively, use `yarn dev --all` to load Portal and other supported apps/services, see [dev.js](https://github.com/TryGhost/Ghost/blob/main/.github/scripts/dev.js) for more information.
|
|
40
37
|
|
|
41
|
-
|
|
38
|
+
---
|
|
42
39
|
|
|
43
|
-
|
|
40
|
+
To run Portal in a standalone fashion, use `yarn start` and open [http://localhost:3000](http://localhost:3000).
|
|
44
41
|
|
|
45
|
-
|
|
46
|
-
Open [http://localhost:3000](http://localhost:3000) to view it in the browser.
|
|
42
|
+
## Build
|
|
47
43
|
|
|
48
|
-
|
|
49
|
-
|
|
44
|
+
To create a production minified bundle in `umd/portal.min.js`:
|
|
45
|
+
```
|
|
46
|
+
yarn build
|
|
47
|
+
```
|
|
50
48
|
|
|
51
|
-
|
|
49
|
+
## Test
|
|
52
50
|
|
|
53
|
-
|
|
51
|
+
To run tests in watch mode:
|
|
52
|
+
```
|
|
53
|
+
yarn test
|
|
54
|
+
```
|
|
54
55
|
|
|
55
|
-
|
|
56
|
+
## Release
|
|
56
57
|
|
|
57
|
-
|
|
58
|
+
A patch release can be rolled out instantly in production, whereas a minor/major release requires the Ghost monorepo to be updated and released. In either case, you need sufficient permissions to release `@tryghost` packages on NPM.
|
|
58
59
|
|
|
59
|
-
|
|
60
|
+
### Patch release
|
|
60
61
|
|
|
61
|
-
|
|
62
|
+
1. Run `yarn ship` and select a patch version when prompted
|
|
63
|
+
2. (Optional) Clear JsDelivr cache to get the new version out instantly ([docs](https://www.notion.so/ghost/How-to-clear-jsDelivr-CDN-cache-2930bdbac02946eca07ac23ab3199bfa?pvs=4)). Typically, you'll need to open `https://purge.jsdelivr.net/ghost/portal@~${PORTAL_VERSION}/umd/portal.min.js` and
|
|
64
|
+
`https://purge.jsdelivr.net/ghost/portal@~${PORTAL_VERSION}/umd/main.css` in your browser, where `PORTAL_VERSION` is the latest minor version in `ghost/core/core/shared/config/defaults.json` ([code](https://github.com/TryGhost/Ghost/blob/0aef3d3beeebcd79a4bfd3ad27e0ac67554b5744/ghost/core/core/shared/config/defaults.json#L185))
|
|
62
65
|
|
|
63
|
-
|
|
66
|
+
### Minor / major release
|
|
64
67
|
|
|
65
|
-
`yarn ship`
|
|
68
|
+
1. Run `yarn ship` and select a minor or major version when prompted
|
|
69
|
+
2. Update the Portal version in `ghost/core/core/shared/config/defaults.json` to the new minor or major version ([code](https://github.com/TryGhost/Ghost/blob/0aef3d3beeebcd79a4bfd3ad27e0ac67554b5744/ghost/core/core/shared/config/defaults.json#L198))
|
|
70
|
+
3. Wait until a new version of Ghost is released
|
|
66
71
|
|
|
67
|
-
|
|
68
|
-
- Publishes package on npm as `@tryghost/portal` and creates an unpkg link for script at https://unpkg.com/@tryghost/portal@VERSION
|
|
72
|
+
# Copyright & License
|
|
69
73
|
|
|
70
|
-
(
|
|
74
|
+
Copyright (c) 2013-2024 Ghost Foundation - Released under the [MIT license](LICENSE).
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@tryghost/portal",
|
|
3
|
-
"version": "2.37.
|
|
3
|
+
"version": "2.37.9",
|
|
4
4
|
"license": "MIT",
|
|
5
5
|
"repository": {
|
|
6
6
|
"type": "git",
|
|
@@ -79,8 +79,8 @@
|
|
|
79
79
|
},
|
|
80
80
|
"devDependencies": {
|
|
81
81
|
"@babel/eslint-parser": "7.23.3",
|
|
82
|
-
"@doist/react-interpolate": "1.
|
|
83
|
-
"@sentry/react": "7.
|
|
82
|
+
"@doist/react-interpolate": "1.1.1",
|
|
83
|
+
"@sentry/react": "7.118.0",
|
|
84
84
|
"@sentry/tracing": "7.114.0",
|
|
85
85
|
"@testing-library/jest-dom": "5.17.0",
|
|
86
86
|
"@testing-library/react": "12.1.5",
|
|
@@ -91,7 +91,7 @@
|
|
|
91
91
|
"concurrently": "8.2.2",
|
|
92
92
|
"cross-fetch": "4.0.0",
|
|
93
93
|
"eslint-plugin-i18next": "6.0.3",
|
|
94
|
-
"jsdom": "
|
|
94
|
+
"jsdom": "24.1.0",
|
|
95
95
|
"react": "17.0.2",
|
|
96
96
|
"react-dom": "17.0.2",
|
|
97
97
|
"vite": "4.5.3",
|