Fix third party typings (#59503)

This commit is contained in:
Jiachi Liu 2023-12-12 01:07:17 +01:00 committed by GitHub
parent bd5157c78c
commit 95168bf136
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
9 changed files with 12 additions and 11 deletions

View file

@ -1 +1 @@
export * from './dist/types/index'
export * from './dist/google/index'

View file

@ -12,7 +12,8 @@
}
},
"files": [
"dist"
"dist",
"google.d.ts"
],
"license": "MIT",
"scripts": {

View file

@ -4,8 +4,8 @@ import React, { useEffect } from 'react'
export type ScriptEmbed = {
html?: string | null
height?: number | null
width?: number | null
height?: string | number | null
width?: string | number | null
children?: React.ReactElement | React.ReactElement[]
dataNtpc?: string
}

View file

@ -1,4 +1,3 @@
import React from 'react'
import { GoogleMapsEmbed as TPCGoogleMapEmbed } from 'third-party-capital'
import ThirdPartyScriptEmbed from '../ThirdPartyScriptEmbed'

View file

@ -19,14 +19,15 @@ export type GAParams = {
}
export type GoogleMapsEmbed = {
height?: number
width?: number
height?: number | string
width?: number | string
mode: 'place' | 'view' | 'directions' | 'streetview' | 'search'
apiKey: string
style: string
allowfullscreen: boolean
loading: 'eager' | 'lazy'
style?: string
allowfullscreen?: boolean
loading?: 'eager' | 'lazy'
q?: string
id?: string
center?: string
zoom?: string
maptype?: string

View file

@ -9,7 +9,7 @@ const Page = () => {
}
return (
<div class="container">
<div className="container">
<GoogleAnalytics gaId="GA-XYZ" />
<h1>GA</h1>
<button id="ga-send" onClick={onClick}>