@open-iframe-resizer/core 1.3.0 → 1.4.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.
Files changed (2) hide show
  1. package/README.md +5 -30
  2. package/package.json +3 -3
package/README.md CHANGED
@@ -35,45 +35,20 @@ npm install @open-iframe-resizer/core
35
35
 
36
36
  ### React
37
37
 
38
- A React component is also available:
39
-
40
38
  ```bash
41
39
  npm install @open-iframe-resizer/react
42
40
  ```
43
41
 
44
- ## Notes
45
-
46
- ### Performing actions after a resize
47
-
48
- You can execute a custom function after an iframe has been resized. Also, you can use built-in functions
49
- like `updateParentScrollOnResize` to help keep the iframe within the viewport after resizing:
42
+ ### Vue
50
43
 
51
- ```javascript
52
- import { initialize, updateParentScrollOnResize } from "https://cdn.jsdelivr.net/npm/@open-iframe-resizer/core@latest/dist/index.min.js";
53
-
54
- initialize({ onIframeResize: updateParentScrollOnResize }, "#myIframe");
44
+ ```bash
45
+ npm install @open-iframe-resizer/vue
55
46
  ```
56
47
 
57
- ### Resize iframes from a different origin
58
-
59
- - If you have control over the embedded page, you need to load the script on your child page to enable messaging between the two windows (you do not need to call the initialize function in the child;
60
- loading the module is sufficient).
61
-
62
- Here is an example of the [parent page](https://codesandbox.io/p/sandbox/xj24pg) and the [child](https://codesandbox.io/p/sandbox/growing-iframe-msv4hr).
63
-
64
-
65
- - If you have no control over the child iframe domain, and, by chance, the child page loads the legacy *iframe-resizer* script, you can initialize the library with the compatibility mode; it will try
66
- to connect to the child iframe:
67
- ```javascript
68
- initialize({ enableLegacyLibSupport: true }, "#my-iframe");
69
- ```
70
-
71
- ### Comparison with iframe-resizer
48
+ ## Full documentation
72
49
 
73
- This library is very good, but it has changed its license, so it is no longer usable in closed-source projects for free.
74
- I decided to replicate some parts of the API, as it may facilitate migration to this project.
50
+ Explore the [full documentation](https://lemick.github.io/open-iframe-resizer/guides/getting-started/#_top)
75
51
 
76
- Some features from this library are missing, but they could be implemented in future versions.
77
52
 
78
53
  ## Browser support
79
54
 
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@open-iframe-resizer/core",
3
3
  "private": false,
4
- "version": "1.3.0",
4
+ "version": "1.4.0",
5
5
  "description": "Open-source modern iframe resizer",
6
6
  "license": "MIT",
7
7
  "repository": {
@@ -21,14 +21,14 @@
21
21
  "responsive"
22
22
  ],
23
23
  "type": "module",
24
- "main": "./dist/index.cjs",
24
+ "main": "./dist/index.umd.cjs",
25
25
  "module": "./dist/index.js",
26
26
  "typings": "./dist/index.d.ts",
27
27
  "exports": {
28
28
  ".": {
29
29
  "types": "./dist/index.d.ts",
30
30
  "import": "./dist/index.js",
31
- "require": "./dist/index.cjs"
31
+ "require": "./dist/index.umd.cjs"
32
32
  }
33
33
  },
34
34
  "files": [