Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

add missing options types #49

Merged
merged 3 commits into from
Jun 26, 2024

Conversation

flashdesignory
Copy link
Collaborator

@flashdesignory flashdesignory commented Jun 24, 2024

additional types export for missing params

@kara

@flashdesignory
Copy link
Collaborator Author

@huang-julien - some missing types, now we export all param types needed as input for tpc

@@ -111,3 +111,21 @@ export interface GoogleTagManagerApi {
dataLayer: Record<string, any>[];
google_tag_manager: GoogleTagManager;
}

/* Google Maps Embed */
export interface GoogleMapsEmbedOptions {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
export interface GoogleMapsEmbedOptions {
export interface GoogleMapsEmbedQueries {

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think this should be suffixed with Queries instead of Options as width and height are missing.

GoogleMapsEmbedOptions should probably be something like
type GoogleMapsEmbedOptions = GoogleMapsEmbedQueries & GoogleMapsEmbedAttributes

Copy link
Collaborator Author

@flashdesignory flashdesignory Jun 24, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ah I see - yeah, makes sense to differentiate between attributes and params... how about:
GoogleMapsEmbedParams ? in that way it matches "attributes" and "params" keys in the json files: https://github.com/GoogleChromeLabs/third-party-capital/blob/main/src/third-parties/google-maps-embed/data.json#L12

src/types/type-declarations.ts Outdated Show resolved Hide resolved
@flashdesignory flashdesignory merged commit 521f22f into GoogleChromeLabs:main Jun 26, 2024
2 checks passed
@flashdesignory flashdesignory deleted the chore/types branch June 26, 2024 12:39
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants