@cocreate/element-prototype 1.14.1 → 1.16.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/CHANGELOG.md CHANGED
@@ -1,3 +1,27 @@
1
+ # [1.16.0](https://github.com/CoCreate-app/CoCreate-element-prototype/compare/v1.15.0...v1.16.0) (2023-11-25)
2
+
3
+
4
+ ### Bug Fixes
5
+
6
+ * update licensing details ([4aeb6f8](https://github.com/CoCreate-app/CoCreate-element-prototype/commit/4aeb6f88f74467e09e68f10187eef534d2b95395))
7
+
8
+
9
+ ### Features
10
+
11
+ * upgrade dependencies for latest features and fixes ([0a04fc1](https://github.com/CoCreate-app/CoCreate-element-prototype/commit/0a04fc1a9d64bd47aa92848f93f851d10ab213a1))
12
+
13
+ # [1.15.0](https://github.com/CoCreate-app/CoCreate-element-prototype/compare/v1.14.1...v1.15.0) (2023-11-25)
14
+
15
+
16
+ ### Bug Fixes
17
+
18
+ * pass attributes renamed to state ([66fa12e](https://github.com/CoCreate-app/CoCreate-element-prototype/commit/66fa12e5081566507d71da273da654d96c3b4b96))
19
+
20
+
21
+ ### Features
22
+
23
+ * upgrade dependencies for latest features and fixes ([0ddf814](https://github.com/CoCreate-app/CoCreate-element-prototype/commit/0ddf814a498565331edb886bb69e9aeaccfb9655))
24
+
1
25
  ## [1.14.1](https://github.com/CoCreate-app/CoCreate-element-prototype/compare/v1.14.0...v1.14.1) (2023-11-22)
2
26
 
3
27
 
package/README.md CHANGED
@@ -9,7 +9,6 @@ A simple element-prototype component in vanilla javascript. Easily configured us
9
9
  ![GitHub](https://img.shields.io/github/license/CoCreate-app/CoCreate-element-prototype?style=flat-square)
10
10
  ![GitHub](https://img.shields.io/static/v1?style=flat-square&label=&message=Hiring&color=blueviolet)
11
11
 
12
-
13
12
  ![CoCreate-element-prototype](https://cdn.cocreate.app/docs/CoCreate-element-prototype.gif)
14
13
 
15
14
  ## [Docs & Demo](https://cocreate.app/docs/element-prototype)
@@ -40,12 +39,12 @@ $ yarn install @cocreate/element-prototype
40
39
 
41
40
  # Table of Contents
42
41
 
43
- - [Table of Contents](#table-of-contents)
44
- - [Announcements](#announcements)
45
- - [Roadmap](#roadmap)
46
- - [How to Contribute](#how-to-contribute)
47
- - [About](#about)
48
- - [License](#license)
42
+ - [Table of Contents](#table-of-contents)
43
+ - [Announcements](#announcements)
44
+ - [Roadmap](#roadmap)
45
+ - [How to Contribute](#how-to-contribute)
46
+ - [About](#about)
47
+ - [License](#license)
49
48
 
50
49
  <a name="announcements"></a>
51
50
 
@@ -79,6 +78,14 @@ We want this library to be community-driven, and CoCreate led. We need your help
79
78
 
80
79
  We appreciate your continued support, thank you!
81
80
 
81
+ <a name="license"></a>
82
+
82
83
  # License
83
84
 
84
- [The MIT License (MIT)](https://github.com/CoCreate-app/CoCreate-element-prototype/blob/master/LICENSE)
85
+ This software is dual-licensed under the GNU Affero General Public License version 3 (AGPLv3) and a commercial license.
86
+
87
+ - **Open Source Use**: For open-source projects and non-commercial use, this software is available under the AGPLv3. The AGPLv3 allows you to freely use, modify, and distribute this software, provided that all modifications and derivative works are also licensed under the AGPLv3. For the full license text, see the [LICENSE file](https://github.com/CoCreate-app/CoCreate-element-prototype/blob/master/LICENSE).
88
+
89
+ - **Commercial Use**: For-profit companies and individuals intending to use this software for commercial purposes must obtain a commercial license. The commercial license is available when you sign up for an API key on our [website](https://cocreate.app). This license permits proprietary use and modification of the software without the copyleft requirements of the AGPLv3. It is ideal for integrating this software into proprietary commercial products and applications.
90
+
91
+ If you have not purchased a commercial license and intend to use this software for commercial purposes, you are required to sign up for an API key on our website.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@cocreate/element-prototype",
3
- "version": "1.14.1",
3
+ "version": "1.16.0",
4
4
  "description": "A simple element-prototype component in vanilla javascript. Easily configured using HTML5 data-attributes and/or JavaScript API.",
5
5
  "keywords": [
6
6
  "element-prototype",
@@ -58,6 +58,6 @@
58
58
  "webpack-log": "^3.0.1"
59
59
  },
60
60
  "dependencies": {
61
- "@cocreate/utils": "^1.27.4"
61
+ "@cocreate/utils": "^1.29.0"
62
62
  }
63
63
  }
package/src/setValue.js CHANGED
@@ -93,7 +93,7 @@ const setValue = (el, value) => {
93
93
  else {
94
94
  let newElement = document.createElement("div");
95
95
  newElement.innerHTML = value;
96
- setPass(newElement)
96
+ setState(newElement)
97
97
 
98
98
  let CoCreateJS = newElement.querySelector('script[src*="CoCreate.js"], script[src*="CoCreate.min.js"]')
99
99
  if (CoCreateJS)
@@ -132,7 +132,7 @@ const setValue = (el, value) => {
132
132
  if (el.tagName == 'HEAD' || el.tagName == 'BODY') {
133
133
  el.removeAttribute('array');
134
134
  el.removeAttribute('object');
135
- el.removeAttribute('pass_id');
135
+ el.removeAttribute('state_id');
136
136
 
137
137
  let scripts = el.querySelectorAll('script');
138
138
  for (let script of scripts) {
@@ -141,11 +141,11 @@ const setValue = (el, value) => {
141
141
  }
142
142
  };
143
143
 
144
- function setPass(el) {
145
- if (CoCreate.pass) {
146
- let passElements = el.querySelectorAll('[pass_id]');
147
- if (passElements)
148
- CoCreate.pass.initElements(passElements)
144
+ function setState(el) {
145
+ if (CoCreate.state) {
146
+ let stateElements = el.querySelectorAll('[state_id]');
147
+ if (stateElements)
148
+ CoCreate.state.initElements(stateElements)
149
149
  }
150
150
  }
151
151