@tinacms/app 1.0.6 → 1.1.0

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,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
- Copyright 2021 Forestry.io Holdings, Inc.
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
- Copyright 2021 Forestry.io Holdings, Inc.
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
- Copyright 2021 Forestry.io Holdings, Inc.
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
- Copyright 2021 Forestry.io Holdings, Inc.
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
 
@@ -1,14 +1,5 @@
1
1
  /**
2
- Copyright 2021 Forestry.io Holdings, Inc.
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'
@@ -1,14 +1,5 @@
1
1
  /**
2
- Copyright 2021 Forestry.io Holdings, Inc.
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
- Copyright 2021 Forestry.io Holdings, Inc.
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
@@ -378,7 +378,16 @@ var viteBuild = async ({
378
378
  const publicEnv = {};
379
379
  Object.keys(process.env).forEach((key) => {
380
380
  if (key.startsWith("TINA_PUBLIC_") || key.startsWith("NEXT_PUBLIC_") || key === "NODE_ENV" || key === "HEAD") {
381
- publicEnv[key] = JSON.stringify(process.env[key]);
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
+ }
382
391
  }
383
392
  });
384
393
  const config = {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@tinacms/app",
3
- "version": "1.0.6",
3
+ "version": "1.1.0",
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.1",
40
- "tinacms": "1.1.5",
41
- "@tinacms/toolkit": "1.3.1",
42
- "@tinacms/mdx": "1.1.1",
39
+ "@tinacms/scripts": "1.0.2",
40
+ "tinacms": "1.2.1",
41
+ "@tinacms/toolkit": "1.3.3",
42
+ "@tinacms/mdx": "1.3.0",
43
43
  "jest": "^27.0.6"
44
44
  },
45
45
  "dependencies": {