@tinacms/app 2.2.3 → 2.2.4

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,5 +1,12 @@
1
1
  # @tinacms/app
2
2
 
3
+ ## 2.2.4
4
+
5
+ ### Patch Changes
6
+
7
+ - Updated dependencies [[`921f235`](https://github.com/tinacms/tinacms/commit/921f2356e4615d532d02eefa7103fdb70f83b97a), [`b551232`](https://github.com/tinacms/tinacms/commit/b5512326ad0ad9855bc75e2073a3ab2a8ec4c064), [`ea204c9`](https://github.com/tinacms/tinacms/commit/ea204c9045451f3ebea04f503e6158d2016613e4)]:
8
+ - tinacms@2.7.4
9
+
3
10
  ## 2.2.3
4
11
 
5
12
  ### Patch Changes
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@tinacms/app",
3
- "version": "2.2.3",
3
+ "version": "2.2.4",
4
4
  "main": "src/main.tsx",
5
5
  "license": "Apache-2.0",
6
6
  "devDependencies": {
@@ -23,6 +23,6 @@
23
23
  "typescript": "^5.7.3",
24
24
  "zod": "^3.24.2",
25
25
  "@tinacms/mdx": "1.6.1",
26
- "tinacms": "2.7.3"
26
+ "tinacms": "2.7.4"
27
27
  }
28
28
  }
@@ -1,36 +1,36 @@
1
- import React from 'react';
2
- import * as G from 'graphql';
3
- import { getIn } from 'final-form';
4
- import { z } from 'zod';
5
1
  // @ts-expect-error
6
2
  import schemaJson from 'SCHEMA_IMPORT';
7
- import { expandQuery, isConnectionType, isNodeType } from './expand-query';
3
+ import { getIn } from 'final-form';
4
+ import * as G from 'graphql';
5
+ import React from 'react';
6
+ import { useSearchParams } from 'react-router-dom';
8
7
  import {
8
+ Client,
9
+ Collection,
10
+ ErrorDialog,
9
11
  Form,
10
- TinaCMS,
12
+ FormOptions,
13
+ GlobalFormPlugin,
11
14
  NAMER,
12
- TinaSchema,
13
- useCMS,
14
- resolveField,
15
- Collection,
16
15
  Template,
16
+ TinaCMS,
17
17
  TinaField,
18
- Client,
19
- FormOptions,
20
- GlobalFormPlugin,
18
+ TinaSchema,
21
19
  TinaState,
22
- ErrorDialog,
20
+ resolveField,
21
+ useCMS,
23
22
  } from 'tinacms';
24
- import { createForm, createGlobalForm, FormifyCallback } from './build-form';
23
+ import { z } from 'zod';
24
+ import { FormifyCallback, createForm, createGlobalForm } from './build-form';
25
+ import { showErrorModal } from './errors';
26
+ import { expandQuery, isConnectionType, isNodeType } from './expand-query';
25
27
  import type {
26
- PostMessage,
27
28
  Payload,
28
- SystemInfo,
29
+ PostMessage,
29
30
  ResolvedDocument,
31
+ SystemInfo,
30
32
  } from './types';
31
33
  import { getFormAndFieldNameFromMetadata } from './util';
32
- import { useSearchParams } from 'react-router-dom';
33
- import { showErrorModal } from './errors';
34
34
 
35
35
  const sysSchema = z.object({
36
36
  breadcrumbs: z.array(z.string()),
@@ -559,6 +559,12 @@ export const useGraphQLReducer = (
559
559
  payload,
560
560
  ]);
561
561
  }
562
+ if (event.data.type === 'url-changed') {
563
+ cms.dispatch({
564
+ type: 'sidebar:set-loading-state',
565
+ value: true,
566
+ });
567
+ }
562
568
  },
563
569
  [cms, JSON.stringify(results)]
564
570
  );
package/src/lib/types.ts CHANGED
@@ -6,7 +6,8 @@ export type PostMessage =
6
6
  }
7
7
  | { type: 'field:selected'; fieldName: string }
8
8
  | { type: 'quick-edit'; value: boolean }
9
- | { type: 'user-select-form'; formId: string };
9
+ | { type: 'user-select-form'; formId: string }
10
+ | { type: 'url-changed' };
10
11
 
11
12
  export type Payload = {
12
13
  id: string;