@tinacms/app 0.0.0-20230516192308 → 0.0.0-20230516195305

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,14 +1,14 @@
1
1
  # @tinacms/app
2
2
 
3
- ## 0.0.0-20230516192308
3
+ ## 0.0.0-20230516195305
4
4
 
5
5
  ### Patch Changes
6
6
 
7
7
  - 7f95c1ce5: Reorganize the way fields are presented on the form to allow for deep-linking
8
8
  - Updated dependencies [b3d98d159]
9
9
  - Updated dependencies [7f95c1ce5]
10
- - @tinacms/toolkit@0.0.0-20230516192308
11
- - tinacms@0.0.0-20230516192308
10
+ - @tinacms/toolkit@0.0.0-20230516195305
11
+ - tinacms@0.0.0-20230516195305
12
12
 
13
13
  ## 1.2.12
14
14
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@tinacms/app",
3
- "version": "0.0.0-20230516192308",
3
+ "version": "0.0.0-20230516195305",
4
4
  "main": "src/main.tsx",
5
5
  "license": "Apache-2.0",
6
6
  "devDependencies": {
@@ -28,7 +28,7 @@
28
28
  "typescript": "^4.6.4",
29
29
  "zod": "^3.14.3",
30
30
  "@tinacms/mdx": "1.3.10",
31
- "@tinacms/toolkit": "0.0.0-20230516192308",
32
- "tinacms": "0.0.0-20230516192308"
31
+ "@tinacms/toolkit": "0.0.0-20230516195305",
32
+ "tinacms": "0.0.0-20230516195305"
33
33
  }
34
34
  }
@@ -431,7 +431,7 @@ export const useGraphQLReducer = (
431
431
  } else {
432
432
  if (result.data) {
433
433
  setResults((results) => [
434
- ...results,
434
+ ...results.filter((result) => result.id !== payload.id),
435
435
  { id: payload.id, data: result.data },
436
436
  ])
437
437
  }
package/src/lib/util.ts CHANGED
@@ -113,7 +113,12 @@ export const getFormAndFieldNameFromMetadata = (
113
113
  ? fieldName.slice(value?.name?.length + 1)
114
114
  : fieldName
115
115
  if (localFieldName) {
116
- n = value.fields[localFieldName]
116
+ // If localFieldName is tags.2, just use `tags`
117
+ if (!isNaN(Number(localFieldName.split('.')[1]))) {
118
+ n = value.fields[localFieldName.split('.')[0]]
119
+ } else {
120
+ n = value.fields[localFieldName]
121
+ }
117
122
  } else {
118
123
  n = value.name
119
124
  }