From 8e9d3ceddf117b120550908dbdfd08452c4a7478 Mon Sep 17 00:00:00 2001 From: Paige Sun Date: Fri, 11 Sep 2020 15:02:53 -0700 Subject: [PATCH] 7/7 Log attribution context from the image component Summary: Changelog: [Internal] Log attribution context from the Fabric image component Reviewed By: fkgozali Differential Revision: D23547930 fbshipit-source-id: 125f34dac85ff6ac52a798bb1a36394436cb2c0f --- ReactCommon/react/renderer/components/image/ImageProps.cpp | 7 ++++++- ReactCommon/react/renderer/components/image/ImageProps.h | 1 + 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/ReactCommon/react/renderer/components/image/ImageProps.cpp b/ReactCommon/react/renderer/components/image/ImageProps.cpp index c716b786f7d..4a496bba12d 100644 --- a/ReactCommon/react/renderer/components/image/ImageProps.cpp +++ b/ReactCommon/react/renderer/components/image/ImageProps.cpp @@ -30,7 +30,12 @@ ImageProps::ImageProps(const ImageProps &sourceProps, const RawProps &rawProps) capInsets( convertRawProp(rawProps, "capInsets", sourceProps.capInsets, {})), tintColor( - convertRawProp(rawProps, "tintColor", sourceProps.tintColor, {})) {} + convertRawProp(rawProps, "tintColor", sourceProps.tintColor, {})), + internal_analyticTag(convertRawProp( + rawProps, + "internal_analyticTag", + sourceProps.internal_analyticTag, + {})) {} } // namespace react } // namespace facebook diff --git a/ReactCommon/react/renderer/components/image/ImageProps.h b/ReactCommon/react/renderer/components/image/ImageProps.h index 7ed6ac4e180..7ecfc27b8f7 100644 --- a/ReactCommon/react/renderer/components/image/ImageProps.h +++ b/ReactCommon/react/renderer/components/image/ImageProps.h @@ -26,6 +26,7 @@ class ImageProps final : public ViewProps { const Float blurRadius{}; const EdgeInsets capInsets{}; const SharedColor tintColor{}; + const std::string internal_analyticTag{}; }; } // namespace react