@tinacms/app 1.0.5 → 1.0.7
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/appFiles/node_modules/.package-lock.json +3 -3
- package/appFiles/node_modules/@babel/parser/lib/index.js +42 -34
- package/appFiles/node_modules/@babel/parser/lib/index.js.map +1 -1
- package/appFiles/node_modules/@babel/parser/package.json +1 -1
- package/appFiles/src/App.tsx +1 -10
- package/appFiles/src/fields/rich-text/index.tsx +1 -10
- package/appFiles/src/fields/rich-text/monaco/error-message.tsx +0 -12
- package/appFiles/src/fields/rich-text/monaco/index.tsx +0 -12
- package/appFiles/src/fields/rich-text/monaco/use-debounce.ts +0 -12
- package/appFiles/src/lib/formify/index.ts +1 -10
- package/appFiles/src/lib/machines/document-machine.ts +1 -10
- package/appFiles/src/lib/machines/query-machine.ts +1 -10
- package/appFiles/src/lib/machines/util.ts +1 -10
- package/appFiles/src/main.tsx +1 -10
- package/appFiles/src/preview.tsx +1 -10
- package/appFiles/src/vite-env.d.ts +1 -10
- package/dist/index.js +16 -1
- package/package.json +5 -5
package/appFiles/src/App.tsx
CHANGED
|
@@ -1,14 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
|
|
3
|
-
Licensed under the Apache License, Version 2.0 (the "License");
|
|
4
|
-
you may not use this file except in compliance with the License.
|
|
5
|
-
You may obtain a copy of the License at
|
|
6
|
-
http://www.apache.org/licenses/LICENSE-2.0
|
|
7
|
-
Unless required by applicable law or agreed to in writing, software
|
|
8
|
-
distributed under the License is distributed on an "AS IS" BASIS,
|
|
9
|
-
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
10
|
-
See the License for the specific language governing permissions and
|
|
11
|
-
limitations under the License.
|
|
2
|
+
|
|
12
3
|
*/
|
|
13
4
|
|
|
14
5
|
import React, { Suspense } from 'react'
|
|
@@ -1,14 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
|
|
3
|
-
Licensed under the Apache License, Version 2.0 (the "License");
|
|
4
|
-
you may not use this file except in compliance with the License.
|
|
5
|
-
You may obtain a copy of the License at
|
|
6
|
-
http://www.apache.org/licenses/LICENSE-2.0
|
|
7
|
-
Unless required by applicable law or agreed to in writing, software
|
|
8
|
-
distributed under the License is distributed on an "AS IS" BASIS,
|
|
9
|
-
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
10
|
-
See the License for the specific language governing permissions and
|
|
11
|
-
limitations under the License.
|
|
2
|
+
|
|
12
3
|
*/
|
|
13
4
|
import RawEditor from './monaco'
|
|
14
5
|
|
|
@@ -1,18 +1,6 @@
|
|
|
1
1
|
/**
|
|
2
2
|
|
|
3
|
-
Copyright 2021 Forestry.io Holdings, Inc.
|
|
4
3
|
|
|
5
|
-
Licensed under the Apache License, Version 2.0 (the "License");
|
|
6
|
-
you may not use this file except in compliance with the License.
|
|
7
|
-
You may obtain a copy of the License at
|
|
8
|
-
|
|
9
|
-
http://www.apache.org/licenses/LICENSE-2.0
|
|
10
|
-
|
|
11
|
-
Unless required by applicable law or agreed to in writing, software
|
|
12
|
-
distributed under the License is distributed on an "AS IS" BASIS,
|
|
13
|
-
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
14
|
-
See the License for the specific language governing permissions and
|
|
15
|
-
limitations under the License.
|
|
16
4
|
|
|
17
5
|
*/
|
|
18
6
|
import React from 'react'
|
|
@@ -1,18 +1,6 @@
|
|
|
1
1
|
/**
|
|
2
2
|
|
|
3
|
-
Copyright 2021 Forestry.io Holdings, Inc.
|
|
4
3
|
|
|
5
|
-
Licensed under the Apache License, Version 2.0 (the "License");
|
|
6
|
-
you may not use this file except in compliance with the License.
|
|
7
|
-
You may obtain a copy of the License at
|
|
8
|
-
|
|
9
|
-
http://www.apache.org/licenses/LICENSE-2.0
|
|
10
|
-
|
|
11
|
-
Unless required by applicable law or agreed to in writing, software
|
|
12
|
-
distributed under the License is distributed on an "AS IS" BASIS,
|
|
13
|
-
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
14
|
-
See the License for the specific language governing permissions and
|
|
15
|
-
limitations under the License.
|
|
16
4
|
|
|
17
5
|
*/
|
|
18
6
|
|
|
@@ -1,18 +1,6 @@
|
|
|
1
1
|
/**
|
|
2
2
|
|
|
3
|
-
Copyright 2021 Forestry.io Holdings, Inc.
|
|
4
3
|
|
|
5
|
-
Licensed under the Apache License, Version 2.0 (the "License");
|
|
6
|
-
you may not use this file except in compliance with the License.
|
|
7
|
-
You may obtain a copy of the License at
|
|
8
|
-
|
|
9
|
-
http://www.apache.org/licenses/LICENSE-2.0
|
|
10
|
-
|
|
11
|
-
Unless required by applicable law or agreed to in writing, software
|
|
12
|
-
distributed under the License is distributed on an "AS IS" BASIS,
|
|
13
|
-
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
14
|
-
See the License for the specific language governing permissions and
|
|
15
|
-
limitations under the License.
|
|
16
4
|
|
|
17
5
|
*/
|
|
18
6
|
import { useState, useEffect } from 'react'
|
|
@@ -1,14 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
|
|
3
|
-
Licensed under the Apache License, Version 2.0 (the "License");
|
|
4
|
-
you may not use this file except in compliance with the License.
|
|
5
|
-
You may obtain a copy of the License at
|
|
6
|
-
http://www.apache.org/licenses/LICENSE-2.0
|
|
7
|
-
Unless required by applicable law or agreed to in writing, software
|
|
8
|
-
distributed under the License is distributed on an "AS IS" BASIS,
|
|
9
|
-
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
10
|
-
See the License for the specific language governing permissions and
|
|
11
|
-
limitations under the License.
|
|
2
|
+
|
|
12
3
|
*/
|
|
13
4
|
|
|
14
5
|
import * as G from 'graphql'
|
|
@@ -1,14 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
|
|
3
|
-
Licensed under the Apache License, Version 2.0 (the "License");
|
|
4
|
-
you may not use this file except in compliance with the License.
|
|
5
|
-
You may obtain a copy of the License at
|
|
6
|
-
http://www.apache.org/licenses/LICENSE-2.0
|
|
7
|
-
Unless required by applicable law or agreed to in writing, software
|
|
8
|
-
distributed under the License is distributed on an "AS IS" BASIS,
|
|
9
|
-
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
10
|
-
See the License for the specific language governing permissions and
|
|
11
|
-
limitations under the License.
|
|
2
|
+
|
|
12
3
|
*/
|
|
13
4
|
import { Client, Field, Form, FormOptions, TinaCMS } from 'tinacms'
|
|
14
5
|
import { assign, createMachine, sendParent } from 'xstate'
|
|
@@ -1,14 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
|
|
3
|
-
Licensed under the Apache License, Version 2.0 (the "License");
|
|
4
|
-
you may not use this file except in compliance with the License.
|
|
5
|
-
You may obtain a copy of the License at
|
|
6
|
-
http://www.apache.org/licenses/LICENSE-2.0
|
|
7
|
-
Unless required by applicable law or agreed to in writing, software
|
|
8
|
-
distributed under the License is distributed on an "AS IS" BASIS,
|
|
9
|
-
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
10
|
-
See the License for the specific language governing permissions and
|
|
11
|
-
limitations under the License.
|
|
2
|
+
|
|
12
3
|
*/
|
|
13
4
|
import { assign, createMachine, spawn } from 'xstate'
|
|
14
5
|
import {
|
|
@@ -1,14 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
|
|
3
|
-
Licensed under the Apache License, Version 2.0 (the "License");
|
|
4
|
-
you may not use this file except in compliance with the License.
|
|
5
|
-
You may obtain a copy of the License at
|
|
6
|
-
http://www.apache.org/licenses/LICENSE-2.0
|
|
7
|
-
Unless required by applicable law or agreed to in writing, software
|
|
8
|
-
distributed under the License is distributed on an "AS IS" BASIS,
|
|
9
|
-
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
10
|
-
See the License for the specific language governing permissions and
|
|
11
|
-
limitations under the License.
|
|
2
|
+
|
|
12
3
|
*/
|
|
13
4
|
import { DocumentBlueprint } from '../formify/types'
|
|
14
5
|
|
package/appFiles/src/main.tsx
CHANGED
|
@@ -1,14 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
|
|
3
|
-
Licensed under the Apache License, Version 2.0 (the "License");
|
|
4
|
-
you may not use this file except in compliance with the License.
|
|
5
|
-
You may obtain a copy of the License at
|
|
6
|
-
http://www.apache.org/licenses/LICENSE-2.0
|
|
7
|
-
Unless required by applicable law or agreed to in writing, software
|
|
8
|
-
distributed under the License is distributed on an "AS IS" BASIS,
|
|
9
|
-
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
10
|
-
See the License for the specific language governing permissions and
|
|
11
|
-
limitations under the License.
|
|
2
|
+
|
|
12
3
|
*/
|
|
13
4
|
|
|
14
5
|
import React from 'react'
|
package/appFiles/src/preview.tsx
CHANGED
|
@@ -1,14 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
|
|
3
|
-
Licensed under the Apache License, Version 2.0 (the "License");
|
|
4
|
-
you may not use this file except in compliance with the License.
|
|
5
|
-
You may obtain a copy of the License at
|
|
6
|
-
http://www.apache.org/licenses/LICENSE-2.0
|
|
7
|
-
Unless required by applicable law or agreed to in writing, software
|
|
8
|
-
distributed under the License is distributed on an "AS IS" BASIS,
|
|
9
|
-
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
10
|
-
See the License for the specific language governing permissions and
|
|
11
|
-
limitations under the License.
|
|
2
|
+
|
|
12
3
|
*/
|
|
13
4
|
import React from 'react'
|
|
14
5
|
import { useMachine } from '@xstate/react'
|
|
@@ -1,14 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
|
|
3
|
-
Licensed under the Apache License, Version 2.0 (the "License");
|
|
4
|
-
you may not use this file except in compliance with the License.
|
|
5
|
-
You may obtain a copy of the License at
|
|
6
|
-
http://www.apache.org/licenses/LICENSE-2.0
|
|
7
|
-
Unless required by applicable law or agreed to in writing, software
|
|
8
|
-
distributed under the License is distributed on an "AS IS" BASIS,
|
|
9
|
-
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
10
|
-
See the License for the specific language governing permissions and
|
|
11
|
-
limitations under the License.
|
|
2
|
+
|
|
12
3
|
*/
|
|
13
4
|
|
|
14
5
|
/// <reference types="vite/client" />
|
package/dist/index.js
CHANGED
|
@@ -375,13 +375,28 @@ var viteBuild = async ({
|
|
|
375
375
|
const alias = {
|
|
376
376
|
TINA_IMPORT: configPrebuildPath
|
|
377
377
|
};
|
|
378
|
+
const publicEnv = {};
|
|
379
|
+
Object.keys(process.env).forEach((key) => {
|
|
380
|
+
if (key.startsWith("TINA_PUBLIC_") || key.startsWith("NEXT_PUBLIC_") || key === "NODE_ENV" || key === "HEAD") {
|
|
381
|
+
try {
|
|
382
|
+
if (typeof process.env[key] === "string") {
|
|
383
|
+
publicEnv[key] = process.env[key];
|
|
384
|
+
} else {
|
|
385
|
+
publicEnv[key] = JSON.stringify(process.env[key]);
|
|
386
|
+
}
|
|
387
|
+
} catch (error) {
|
|
388
|
+
console.warn(`Could not stringify public env process.env.${key} env variable`);
|
|
389
|
+
console.warn(error);
|
|
390
|
+
}
|
|
391
|
+
}
|
|
392
|
+
});
|
|
378
393
|
const config = {
|
|
379
394
|
root: appRootPath,
|
|
380
395
|
base: `/${outputFolder}/`,
|
|
381
396
|
mode: local ? "development" : "production",
|
|
382
397
|
plugins: [(0, import_vite.splitVendorChunkPlugin)(), (0, import_plugin_react.default)(), viteTina()],
|
|
383
398
|
define: {
|
|
384
|
-
"process.env": `new Object(${JSON.stringify(
|
|
399
|
+
"process.env": `new Object(${JSON.stringify(publicEnv)})`,
|
|
385
400
|
__API_URL__: `"${apiUrl}"`
|
|
386
401
|
},
|
|
387
402
|
esbuild: {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@tinacms/app",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.7",
|
|
4
4
|
"main": "dist/index.js",
|
|
5
5
|
"exports": {
|
|
6
6
|
".": {
|
|
@@ -36,10 +36,10 @@
|
|
|
36
36
|
"@types/fs-extra": "^9.0.1",
|
|
37
37
|
"@types/react": "17.0.2",
|
|
38
38
|
"@types/react-dom": "17.0.2",
|
|
39
|
-
"@tinacms/scripts": "1.0.
|
|
40
|
-
"tinacms": "1.
|
|
41
|
-
"@tinacms/toolkit": "1.3.
|
|
42
|
-
"@tinacms/mdx": "1.
|
|
39
|
+
"@tinacms/scripts": "1.0.2",
|
|
40
|
+
"tinacms": "1.2.0",
|
|
41
|
+
"@tinacms/toolkit": "1.3.2",
|
|
42
|
+
"@tinacms/mdx": "1.2.0",
|
|
43
43
|
"jest": "^27.0.6"
|
|
44
44
|
},
|
|
45
45
|
"dependencies": {
|