= ({
src={src}
width={width}
height={height}
+ allow={allow}
frameBorder="0"
/>
)
}
-interface IframeProps {
- src?: string
- width?: number
- height?: number
- title?: string
-}
-
Iframe.schema = {
title: 'editor.iframe.title',
type: 'object',
@@ -56,6 +53,11 @@ Iframe.schema = {
type: 'string',
default: null,
},
+ allow: {
+ title: 'editor.iframe.allow.title',
+ type: 'string',
+ default: null,
+ },
},
}
diff --git a/react/package.json b/react/package.json
index 1d98741..39514b2 100644
--- a/react/package.json
+++ b/react/package.json
@@ -24,8 +24,10 @@
"apollo-cache-inmemory": "^1.6.5",
"apollo-client": "^2.6.8",
"graphql": "^14.6.0",
- "typescript": "3.8.3",
- "vtex.css-handles": "http://vtex.vteximg.com.br/_v/public/typings/v1/vtex.css-handles@0.4.1/public/@types/vtex.css-handles"
+ "typescript": "3.9.7",
+ "vtex.css-handles": "http://vtex.vtexassets.com/_v/public/typings/v1/vtex.css-handles@0.4.4/public/@types/vtex.css-handles",
+ "vtex.render-runtime": "http://vtex.vtexassets.com/_v/public/typings/v1/vtex.render-runtime@8.126.11/public/@types/vtex.render-runtime",
+ "vtex.styleguide": "http://vtex.vtexassets.com/_v/public/typings/v1/vtex.styleguide@9.136.0/public/@types/vtex.styleguide"
},
"version": "0.2.0"
}
diff --git a/react/typings/css.d.ts b/react/typings/css.d.ts
deleted file mode 100644
index ce1bfff..0000000
--- a/react/typings/css.d.ts
+++ /dev/null
@@ -1,4 +0,0 @@
-declare module '*.css' {
- const css: any
- export default css
-}
diff --git a/react/typings/graphql.d.ts b/react/typings/graphql.d.ts
deleted file mode 100644
index ba891a0..0000000
--- a/react/typings/graphql.d.ts
+++ /dev/null
@@ -1,6 +0,0 @@
-declare module '*.graphql' {
- import { DocumentNode } from 'graphql'
-
- const value: DocumentNode
- export default value
-}
diff --git a/react/typings/storefront.d.ts b/react/typings/storefront.d.ts
deleted file mode 100644
index 5033033..0000000
--- a/react/typings/storefront.d.ts
+++ /dev/null
@@ -1,13 +0,0 @@
-import { FunctionComponent } from 'react'
-
-declare global {
- interface StorefrontFunctionComponent extends FunctionComponent
{
- getSchema?(props: P): object
- schema?: object
- }
-
- interface StorefrontComponent
extends Component
{
- getSchema?(props: P): object
- schema: object
- }
-}
diff --git a/react/typings/vtex.render-runtime.d.ts b/react/typings/vtex.render-runtime.d.ts
deleted file mode 100644
index 31bd9ea..0000000
--- a/react/typings/vtex.render-runtime.d.ts
+++ /dev/null
@@ -1,96 +0,0 @@
-/* Typings for `render-runtime` */
-declare module 'vtex.render-runtime' {
- import { Component, ComponentType, ReactElement, ReactType } from 'react'
-
- export interface NavigationOptions {
- page: string
- params?: any
- }
-
- export interface RenderContextProps {
- runtime: {
- navigate: (options: NavigationOptions) => void
- }
- }
-
- export interface RenderRuntime {
- account: string
- accountId: string
- appsEtag: string
- workspace: string
- disableSSR: boolean
- hints: {
- desktop: boolean
- mobile: boolean
- phone: boolean
- tablet: boolean
- }
- page: string
- route: Route
- version: string
- culture: Culture
- pages: Pages
- preview: boolean
- production: boolean
- publicEndpoint: string
- renderMajor: number
- query?: Record
- start: boolean
- runtimeMeta: {
- version: string
- config?: any
- }
- settings: {
- [app: string]: any
- }
- segmentToken: string
- rootPath?: string
- workspaceCookie: string
- hasNewExtensions: boolean
- navigate: (options: NavigationOptions) => void
- }
-
- interface ExtensionPointProps {
- id: string
- [key: string]: any
- }
-
- interface Pages {
- [name: string]: Page
- }
- interface Route {
- domain: string
- blockId: string
- canonicalPath?: string
- id: string
- params: Record
- path: string
- title?: string
- }
- interface Culture {
- availableLocales: string[]
- locale: string
- language: string
- country: string
- currency: string
- }
-
- export const ExtensionPoint: ComponentType
-
- interface ChildBlockProps {
- id: string
- }
-
- export const ChildBlock: ComponentType
- export const useChildBlock = ({ id: string }) => Object
-
- export const Helmet: ReactElement
- export const Link: ReactType
- export const NoSSR: ReactElement
- export const RenderContextConsumer: ReactElement
- export const canUseDOM: boolean
- export const withRuntimeContext: (
- Component: ComponentType
- ) => ComponentType
- export const useRuntime: () => RenderRuntime
-}
diff --git a/react/typings/vtex.styleguide.d.ts b/react/typings/vtex.styleguide.d.ts
deleted file mode 100644
index 231ca46..0000000
--- a/react/typings/vtex.styleguide.d.ts
+++ /dev/null
@@ -1,9 +0,0 @@
-declare module 'vtex.styleguide' {
- import { ComponentType } from 'react'
-
- export const Input: ComponentType
-
- interface InputProps {
- [key: string]: any
- }
-}
diff --git a/react/yarn.lock b/react/yarn.lock
index 1a35662..fd793d8 100644
--- a/react/yarn.lock
+++ b/react/yarn.lock
@@ -5296,7 +5296,12 @@ type-check@~0.3.2:
dependencies:
prelude-ls "~1.1.2"
-typescript@3.8.3, typescript@^3.7.3:
+typescript@3.9.7:
+ version "3.9.7"
+ resolved "https://registry.yarnpkg.com/typescript/-/typescript-3.9.7.tgz#98d600a5ebdc38f40cb277522f12dc800e9e25fa"
+ integrity sha512-BLbiRkiBzAwsjut4x/dsibSTB6yWpwT5qWmC2OfuCg3GgVQCSgMs4vEctYPhsaGtd0AeuuHMkjZ2h2WG8MSzRw==
+
+typescript@^3.7.3:
version "3.8.3"
resolved "https://registry.yarnpkg.com/typescript/-/typescript-3.8.3.tgz#409eb8544ea0335711205869ec458ab109ee1061"
integrity sha512-MYlEfn5VrLNsgudQTVJeNaQFUAI7DkhnOjdpAp4T+ku1TfQClewlbSuTVHiA+8skNBgaf02TL/kLOvig4y3G8w==
@@ -5412,9 +5417,17 @@ verror@1.10.0:
core-util-is "1.0.2"
extsprintf "^1.2.0"
-"vtex.css-handles@http://vtex.vteximg.com.br/_v/public/typings/v1/vtex.css-handles@0.4.1/public/@types/vtex.css-handles":
- version "0.4.1"
- resolved "http://vtex.vteximg.com.br/_v/public/typings/v1/vtex.css-handles@0.4.1/public/@types/vtex.css-handles#16fe9485e8e7183b94f28496ed8cdd741c83f227"
+"vtex.css-handles@http://vtex.vtexassets.com/_v/public/typings/v1/vtex.css-handles@0.4.4/public/@types/vtex.css-handles":
+ version "0.4.4"
+ resolved "http://vtex.vtexassets.com/_v/public/typings/v1/vtex.css-handles@0.4.4/public/@types/vtex.css-handles#8c45c6decf9acd2b944e07261686decff93d6422"
+
+"vtex.render-runtime@http://vtex.vtexassets.com/_v/public/typings/v1/vtex.render-runtime@8.126.11/public/@types/vtex.render-runtime":
+ version "8.126.11"
+ resolved "http://vtex.vtexassets.com/_v/public/typings/v1/vtex.render-runtime@8.126.11/public/@types/vtex.render-runtime#aceb734766093b56954ec19a074574b4c2c95242"
+
+"vtex.styleguide@http://vtex.vtexassets.com/_v/public/typings/v1/vtex.styleguide@9.136.0/public/@types/vtex.styleguide":
+ version "9.136.0"
+ resolved "http://vtex.vtexassets.com/_v/public/typings/v1/vtex.styleguide@9.136.0/public/@types/vtex.styleguide#0581000fd332db1889bbb2a24f230f824c0e00f6"
w3c-hr-time@^1.0.1:
version "1.0.1"