tinacms 2.7.3 → 2.7.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.
@@ -1,10 +1,10 @@
1
- import { TokenObject } from '../auth/authenticate';
2
1
  import { BranchData, EventBus } from '@tinacms/toolkit';
3
2
  import { DocumentNode, GraphQLSchema } from 'graphql';
3
+ import { TokenObject } from '../auth/authenticate';
4
+ import { AuthProvider, Schema, TinaSchema } from '@tinacms/schema-tools';
5
+ import { SearchClient } from '@tinacms/search/dist/index-client';
4
6
  import gql from 'graphql-tag';
5
- import { TinaSchema, Schema, AuthProvider } from '@tinacms/schema-tools';
6
7
  import { TinaCloudProject } from './types';
7
- import { SearchClient } from '@tinacms/search/dist/index-client';
8
8
  export * from './authProvider';
9
9
  export type OnLoginFunc = (args: {
10
10
  token?: TokenObject;
package/dist/react.js CHANGED
@@ -18,6 +18,9 @@
18
18
  React.useEffect(() => {
19
19
  setIsClient(true);
20
20
  setData(props.data);
21
+ parent.postMessage({
22
+ type: "url-changed"
23
+ });
21
24
  }, [id]);
22
25
  React.useEffect(() => {
23
26
  if (quickEditEnabled) {
package/dist/react.mjs CHANGED
@@ -15,6 +15,9 @@ function useTina(props) {
15
15
  React.useEffect(() => {
16
16
  setIsClient(true);
17
17
  setData(props.data);
18
+ parent.postMessage({
19
+ type: "url-changed"
20
+ });
18
21
  }, [id]);
19
22
  React.useEffect(() => {
20
23
  if (quickEditEnabled) {
@@ -1,5 +1,5 @@
1
- import React from 'react';
2
1
  import { Media } from '../../core';
2
+ import React from 'react';
3
3
  export interface MediaRequest {
4
4
  directory?: string;
5
5
  onSelect?(_media: Media): void;
@@ -1,5 +1,5 @@
1
1
  import * as React from 'react';
2
- import { BranchSwitcherProps, Branch } from './types';
2
+ import { Branch, BranchSwitcherProps } from './types';
3
3
  export declare function formatBranchName(str: string): string;
4
4
  export declare const BranchSwitcherLegacy: ({ listBranches, createBranch, chooseBranch, }: BranchSwitcherProps) => React.JSX.Element;
5
5
  export declare const getFilteredBranchList: (branchList: Branch[], filter: string, currentBranchName: string) => Branch[];
@@ -1,5 +1,5 @@
1
1
  import * as React from 'react';
2
- import { BranchSwitcherProps, Branch } from './types';
2
+ import { Branch, BranchSwitcherProps } from './types';
3
3
  export declare function formatBranchName(str: string): string;
4
4
  export declare const BranchSwitcher: (props: BranchSwitcherProps) => React.JSX.Element;
5
5
  export declare const EditoralBranchSwitcher: ({ listBranches, createBranch, chooseBranch, setModalTitle, }: BranchSwitcherProps) => React.JSX.Element;
@@ -1,13 +1,13 @@
1
1
  import { Plugin } from '../core';
2
2
  import type { IconType } from 'react-icons';
3
3
  /**
4
- * Represents a Tina Cloud Config that should be accessible via the CMS.
4
+ * Represents a TinaCloud Config that should be accessible via the CMS.
5
5
  *
6
6
  * The purpose of these configs is to give a way to display & edit information
7
- * about TIna Cloud Configuration
7
+ * about TinaCloud Configuration
8
8
  * cases may include:
9
9
  *
10
- * * Tina Cloud Project Configuration
10
+ * * TinaCloud Project Configuration
11
11
  * * User Management
12
12
  */
13
13
  export interface CloudConfigPlugin extends Plugin {
@@ -1,8 +1,9 @@
1
- import * as React from 'react';
2
1
  import type { Form } from '../../forms';
3
- export declare const FormsView: ({ children, }: {
4
- children?: React.ReactChild | React.ReactChild[];
5
- }) => React.JSX.Element;
2
+ import * as React from 'react';
3
+ export interface FormsViewProps {
4
+ loadingPlaceholder?: React.FC;
5
+ }
6
+ export declare const FormsView: ({ loadingPlaceholder }?: FormsViewProps) => React.JSX.Element;
6
7
  export interface MultiformFormHeaderProps {
7
8
  activeForm: {
8
9
  activeFieldName?: string;
@@ -0,0 +1,2 @@
1
+ import * as React from 'react';
2
+ export declare const SidebarLoadingPlaceholder: () => React.JSX.Element;
@@ -0,0 +1,2 @@
1
+ import * as React from 'react';
2
+ export declare const SidebarNoFormsPlaceholder: () => React.JSX.Element;
@@ -1,5 +1,5 @@
1
- import { EventBus, Callback } from '../core';
2
1
  import * as React from 'react';
2
+ import { Callback, EventBus } from '../core';
3
3
  export interface SidebarStateOptions {
4
4
  position?: SidebarPosition;
5
5
  buttons?: SidebarButtons;
@@ -22,7 +22,7 @@ export declare type DefaultSidebarState = 'open' | 'closed';
22
22
  export declare class SidebarState {
23
23
  private events;
24
24
  private _isOpen;
25
- placeholder: React.FC;
25
+ loadingPlaceholder: React.FC;
26
26
  defaultState: DefaultSidebarState;
27
27
  position: SidebarPosition;
28
28
  renderNav: boolean;
@@ -58,6 +58,9 @@ export type TinaAction = {
58
58
  } | {
59
59
  type: 'sidebar:set-display-state';
60
60
  value: TinaState['sidebarDisplayState'] | 'openOrFull';
61
+ } | {
62
+ type: 'sidebar:set-loading-state';
63
+ value: boolean;
61
64
  };
62
65
  export interface TinaState {
63
66
  activeFormId: string | null;
@@ -76,6 +79,7 @@ export interface TinaState {
76
79
  }[];
77
80
  formLists: FormList[];
78
81
  editingMode: 'visual' | 'basic';
82
+ isLoadingContent: boolean;
79
83
  quickEditSupported: boolean;
80
84
  sidebarDisplayState: 'closed' | 'open' | 'fullscreen';
81
85
  }
@@ -1,6 +1,6 @@
1
+ import type { Config } from '@tinacms/schema-tools';
1
2
  import AsyncLock from 'async-lock';
2
3
  import type { GraphQLError } from 'graphql';
3
- import type { Config } from '@tinacms/schema-tools';
4
4
  import type { Cache } from '../cache/index';
5
5
  export declare const TINA_HOST = "content.tinajs.io";
6
6
  export interface TinaClientArgs<GenQueries = Record<string, unknown>> {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "tinacms",
3
- "version": "2.7.3",
3
+ "version": "2.7.5",
4
4
  "main": "dist/index.js",
5
5
  "module": "./dist/index.mjs",
6
6
  "exports": {
@@ -129,9 +129,9 @@
129
129
  "webfontloader": "1.6.28",
130
130
  "yup": "^1.6.1",
131
131
  "zod": "^3.24.2",
132
- "@tinacms/mdx": "1.6.1",
133
- "@tinacms/schema-tools": "1.7.2",
134
- "@tinacms/search": "1.0.41"
132
+ "@tinacms/mdx": "1.6.2",
133
+ "@tinacms/schema-tools": "1.7.3",
134
+ "@tinacms/search": "1.0.43"
135
135
  },
136
136
  "devDependencies": {
137
137
  "@graphql-tools/utils": "^10.8.1",
@@ -164,7 +164,7 @@
164
164
  "typescript": "^5.7.3",
165
165
  "vite": "^5.4.14",
166
166
  "vitest": "^2.1.9",
167
- "@tinacms/scripts": "1.3.3"
167
+ "@tinacms/scripts": "1.3.4"
168
168
  },
169
169
  "peerDependencies": {
170
170
  "react": ">=16.14.0",
@@ -1,8 +0,0 @@
1
- /**
2
-
3
-
4
-
5
- */
6
- import * as React from 'react';
7
- export declare const PendingFormsPlaceholder: () => React.JSX.Element;
8
- export declare const NoFormsPlaceholder: () => React.JSX.Element;