@cocreate/render 1.41.3 → 1.41.5

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,17 @@
1
+ ## [1.41.5](https://github.com/CoCreate-app/CoCreate-render/compare/v1.41.4...v1.41.5) (2024-08-24)
2
+
3
+
4
+ ### Bug Fixes
5
+
6
+ * handling of array index ([3a7cae6](https://github.com/CoCreate-app/CoCreate-render/commit/3a7cae6270af70497356cd88e0287ae4d1740d0f))
7
+
8
+ ## [1.41.4](https://github.com/CoCreate-app/CoCreate-render/compare/v1.41.3...v1.41.4) (2024-06-23)
9
+
10
+
11
+ ### Bug Fixes
12
+
13
+ * bump dependencies ([73a6ba3](https://github.com/CoCreate-app/CoCreate-render/commit/73a6ba3043dd1558aaea163714eee3c41cda8566))
14
+
1
15
  ## [1.41.3](https://github.com/CoCreate-app/CoCreate-render/compare/v1.41.2...v1.41.3) (2024-06-23)
2
16
 
3
17
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@cocreate/render",
3
- "version": "1.41.3",
3
+ "version": "1.41.5",
4
4
  "description": "A simple render component in vanilla javascript. Easily configured using HTML5 attributes and/or JavaScript API.",
5
5
  "keywords": [
6
6
  "render",
@@ -58,10 +58,10 @@
58
58
  "webpack-log": "^3.0.1"
59
59
  },
60
60
  "dependencies": {
61
- "@cocreate/actions": "^1.18.3",
61
+ "@cocreate/actions": "^1.18.4",
62
62
  "@cocreate/api": "^1.4.2",
63
63
  "@cocreate/element-prototype": "^1.23.0",
64
- "@cocreate/observer": "^1.16.2",
65
- "@cocreate/utils": "^1.34.0"
64
+ "@cocreate/observer": "^1.16.3",
65
+ "@cocreate/utils": "^1.34.1"
66
66
  }
67
67
  }
package/src/index.js CHANGED
@@ -615,8 +615,9 @@ async function renderValue(node, data, placeholder, renderAs, renderedNode, inde
615
615
  let value;
616
616
  try {
617
617
 
618
- if (match[1] === 'index' && index >= 0) { // {[]} - Dot-notation
618
+ if (match[1] === 'index' && index >= 0) { // {{index}} - index
619
619
  value = index
620
+ match[0] = '{{' + match[1] + '}}'
620
621
  } else if (match[1].startsWith('[') && match[1].endsWith(']')) { // {[]} - Dot-notation
621
622
  match[1] = match[1].slice(1, -1);
622
623
  value = getRenderValue(node, data, match[1], renderAs);