/** * This code was generated by [react-native-codegen](https://www.npmjs.com/package/react-native-codegen). * * Do not edit this file as changes may cause incorrect behavior and will be lost * once the code is regenerated. * * @generated by codegen project: GeneratePropsCpp.js */ #include "Props.h" #include #include namespace facebook::react { EnrichedMarkdownProps::EnrichedMarkdownProps( const PropsParserContext &context, const EnrichedMarkdownProps &sourceProps, const RawProps &rawProps): ViewProps(context, sourceProps, rawProps), markdown(convertRawProp(context, rawProps, "markdown", sourceProps.markdown, {})), markdownStyle(convertRawProp(context, rawProps, "markdownStyle", sourceProps.markdownStyle, {})), enableImagePress(convertRawProp(context, rawProps, "enableImagePress", sourceProps.enableImagePress, {false})), enableTaskListItemToggle(convertRawProp(context, rawProps, "enableTaskListItemToggle", sourceProps.enableTaskListItemToggle, {true})), enableCodeBlockPress(convertRawProp(context, rawProps, "enableCodeBlockPress", sourceProps.enableCodeBlockPress, {false})), enableBlockContextMenu(convertRawProp(context, rawProps, "enableBlockContextMenu", sourceProps.enableBlockContextMenu, {true})), enableLinkPreview(convertRawProp(context, rawProps, "enableLinkPreview", sourceProps.enableLinkPreview, {true})), selectable(convertRawProp(context, rawProps, "selectable", sourceProps.selectable, {false})), selectionColor(convertRawProp(context, rawProps, "selectionColor", sourceProps.selectionColor, {})), selectionHandleColor(convertRawProp(context, rawProps, "selectionHandleColor", sourceProps.selectionHandleColor, {})), md4cFlags(convertRawProp(context, rawProps, "md4cFlags", sourceProps.md4cFlags, {})), isGFM(convertRawProp(context, rawProps, "isGFM", sourceProps.isGFM, {true})), allowFontScaling(convertRawProp(context, rawProps, "allowFontScaling", sourceProps.allowFontScaling, {true})), maxFontSizeMultiplier(convertRawProp(context, rawProps, "maxFontSizeMultiplier", sourceProps.maxFontSizeMultiplier, {0.0})), allowTrailingMargin(convertRawProp(context, rawProps, "allowTrailingMargin", sourceProps.allowTrailingMargin, {false})), streamingAnimation(convertRawProp(context, rawProps, "streamingAnimation", sourceProps.streamingAnimation, {false})), streamingConfig(convertRawProp(context, rawProps, "streamingConfig", sourceProps.streamingConfig, {})), spoilerOverlay(convertRawProp(context, rawProps, "spoilerOverlay", sourceProps.spoilerOverlay, {std::string{"particles"}})), contextMenuItems(convertRawProp(context, rawProps, "contextMenuItems", sourceProps.contextMenuItems, {})), imageRequestHeaders(convertRawProp(context, rawProps, "imageRequestHeaders", sourceProps.imageRequestHeaders, {})), linkPillContent(convertRawProp(context, rawProps, "linkPillContent", sourceProps.linkPillContent, {})), linkRecognition(convertRawProp(context, rawProps, "linkRecognition", sourceProps.linkRecognition, {})), linkContextMenuItems(convertRawProp(context, rawProps, "linkContextMenuItems", sourceProps.linkContextMenuItems, {})), selectionMenuConfig(convertRawProp(context, rawProps, "selectionMenuConfig", sourceProps.selectionMenuConfig, {})), accessibilityLabels(convertRawProp(context, rawProps, "accessibilityLabels", sourceProps.accessibilityLabels, {})), textBreakStrategy(convertRawProp(context, rawProps, "textBreakStrategy", sourceProps.textBreakStrategy, {std::string{"highQuality"}})), lineBreakStrategyIOS(convertRawProp(context, rawProps, "lineBreakStrategyIOS", sourceProps.lineBreakStrategyIOS, {std::string{"none"}})), writingDirection(convertRawProp(context, rawProps, "writingDirection", sourceProps.writingDirection, {std::string{"first-strong"}})), numberOfLines(convertRawProp(context, rawProps, "numberOfLines", sourceProps.numberOfLines, {0})), ellipsizeMode(convertRawProp(context, rawProps, "ellipsizeMode", sourceProps.ellipsizeMode, {std::string{"tail"}})) {} #ifdef RN_SERIALIZABLE_STATE ComponentName EnrichedMarkdownProps::getDiffPropsImplementationTarget() const { return "EnrichedMarkdown"; } folly::dynamic EnrichedMarkdownProps::getDiffProps( const Props* prevProps) const { static const auto defaultProps = EnrichedMarkdownProps(); const EnrichedMarkdownProps* oldProps = prevProps == nullptr ? &defaultProps : static_cast(prevProps); if (this == oldProps) { return folly::dynamic::object(); } folly::dynamic result = HostPlatformViewProps::getDiffProps(prevProps); if (markdown != oldProps->markdown) { result["markdown"] = markdown; } if (markdownStyle != oldProps->markdownStyle) { result["markdownStyle"] = toDynamic(markdownStyle); } if (enableImagePress != oldProps->enableImagePress) { result["enableImagePress"] = enableImagePress; } if (enableTaskListItemToggle != oldProps->enableTaskListItemToggle) { result["enableTaskListItemToggle"] = enableTaskListItemToggle; } if (enableCodeBlockPress != oldProps->enableCodeBlockPress) { result["enableCodeBlockPress"] = enableCodeBlockPress; } if (enableBlockContextMenu != oldProps->enableBlockContextMenu) { result["enableBlockContextMenu"] = enableBlockContextMenu; } if (enableLinkPreview != oldProps->enableLinkPreview) { result["enableLinkPreview"] = enableLinkPreview; } if (selectable != oldProps->selectable) { result["selectable"] = selectable; } if (selectionColor != oldProps->selectionColor) { result["selectionColor"] = *selectionColor; } if (selectionHandleColor != oldProps->selectionHandleColor) { result["selectionHandleColor"] = *selectionHandleColor; } if (md4cFlags != oldProps->md4cFlags) { result["md4cFlags"] = toDynamic(md4cFlags); } if (isGFM != oldProps->isGFM) { result["isGFM"] = isGFM; } if (allowFontScaling != oldProps->allowFontScaling) { result["allowFontScaling"] = allowFontScaling; } if ((maxFontSizeMultiplier != oldProps->maxFontSizeMultiplier) && !(std::isnan(maxFontSizeMultiplier) && std::isnan(oldProps->maxFontSizeMultiplier))) { result["maxFontSizeMultiplier"] = maxFontSizeMultiplier; } if (allowTrailingMargin != oldProps->allowTrailingMargin) { result["allowTrailingMargin"] = allowTrailingMargin; } if (streamingAnimation != oldProps->streamingAnimation) { result["streamingAnimation"] = streamingAnimation; } if (streamingConfig != oldProps->streamingConfig) { result["streamingConfig"] = toDynamic(streamingConfig); } if (spoilerOverlay != oldProps->spoilerOverlay) { result["spoilerOverlay"] = spoilerOverlay; } if (contextMenuItems != oldProps->contextMenuItems) { result["contextMenuItems"] = toDynamic(contextMenuItems); } if (imageRequestHeaders != oldProps->imageRequestHeaders) { result["imageRequestHeaders"] = toDynamic(imageRequestHeaders); } if (linkPillContent != oldProps->linkPillContent) { result["linkPillContent"] = toDynamic(linkPillContent); } if (linkRecognition != oldProps->linkRecognition) { result["linkRecognition"] = toDynamic(linkRecognition); } if (linkContextMenuItems != oldProps->linkContextMenuItems) { result["linkContextMenuItems"] = toDynamic(linkContextMenuItems); } if (selectionMenuConfig != oldProps->selectionMenuConfig) { result["selectionMenuConfig"] = toDynamic(selectionMenuConfig); } if (accessibilityLabels != oldProps->accessibilityLabels) { result["accessibilityLabels"] = toDynamic(accessibilityLabels); } if (textBreakStrategy != oldProps->textBreakStrategy) { result["textBreakStrategy"] = textBreakStrategy; } if (lineBreakStrategyIOS != oldProps->lineBreakStrategyIOS) { result["lineBreakStrategyIOS"] = lineBreakStrategyIOS; } if (writingDirection != oldProps->writingDirection) { result["writingDirection"] = writingDirection; } if (numberOfLines != oldProps->numberOfLines) { result["numberOfLines"] = numberOfLines; } if (ellipsizeMode != oldProps->ellipsizeMode) { result["ellipsizeMode"] = ellipsizeMode; } return result; } #endif EnrichedMarkdownTextInputProps::EnrichedMarkdownTextInputProps( const PropsParserContext &context, const EnrichedMarkdownTextInputProps &sourceProps, const RawProps &rawProps): ViewProps(context, sourceProps, rawProps), defaultValue(convertRawProp(context, rawProps, "defaultValue", sourceProps.defaultValue, {})), placeholder(convertRawProp(context, rawProps, "placeholder", sourceProps.placeholder, {})), placeholderTextColor(convertRawProp(context, rawProps, "placeholderTextColor", sourceProps.placeholderTextColor, {})), editable(convertRawProp(context, rawProps, "editable", sourceProps.editable, {false})), autoFocus(convertRawProp(context, rawProps, "autoFocus", sourceProps.autoFocus, {false})), scrollEnabled(convertRawProp(context, rawProps, "scrollEnabled", sourceProps.scrollEnabled, {false})), markdownShortcuts(convertRawProp(context, rawProps, "markdownShortcuts", sourceProps.markdownShortcuts, {})), autoCapitalize(convertRawProp(context, rawProps, "autoCapitalize", sourceProps.autoCapitalize, {})), multiline(convertRawProp(context, rawProps, "multiline", sourceProps.multiline, {false})), cursorColor(convertRawProp(context, rawProps, "cursorColor", sourceProps.cursorColor, {})), selectionColor(convertRawProp(context, rawProps, "selectionColor", sourceProps.selectionColor, {})), markdownStyle(convertRawProp(context, rawProps, "markdownStyle", sourceProps.markdownStyle, {})), color(convertRawProp(context, rawProps, "color", sourceProps.color, {})), fontSize(convertRawProp(context, rawProps, "fontSize", sourceProps.fontSize, {0.0})), lineHeight(convertRawProp(context, rawProps, "lineHeight", sourceProps.lineHeight, {0.0})), fontFamily(convertRawProp(context, rawProps, "fontFamily", sourceProps.fontFamily, {})), fontWeight(convertRawProp(context, rawProps, "fontWeight", sourceProps.fontWeight, {})), isOnChangeMarkdownSet(convertRawProp(context, rawProps, "isOnChangeMarkdownSet", sourceProps.isOnChangeMarkdownSet, {false})), contextMenuItems(convertRawProp(context, rawProps, "contextMenuItems", sourceProps.contextMenuItems, {})), selectionMenuConfig(convertRawProp(context, rawProps, "selectionMenuConfig", sourceProps.selectionMenuConfig, {})), formatMenuConfig(convertRawProp(context, rawProps, "formatMenuConfig", sourceProps.formatMenuConfig, {})), linkRegex(convertRawProp(context, rawProps, "linkRegex", sourceProps.linkRegex, {})), mentionIndicators(convertRawProp(context, rawProps, "mentionIndicators", sourceProps.mentionIndicators, {})), writingDirection(convertRawProp(context, rawProps, "writingDirection", sourceProps.writingDirection, {std::string{"first-strong"}})) {} #ifdef RN_SERIALIZABLE_STATE ComponentName EnrichedMarkdownTextInputProps::getDiffPropsImplementationTarget() const { return "EnrichedMarkdownTextInput"; } folly::dynamic EnrichedMarkdownTextInputProps::getDiffProps( const Props* prevProps) const { static const auto defaultProps = EnrichedMarkdownTextInputProps(); const EnrichedMarkdownTextInputProps* oldProps = prevProps == nullptr ? &defaultProps : static_cast(prevProps); if (this == oldProps) { return folly::dynamic::object(); } folly::dynamic result = HostPlatformViewProps::getDiffProps(prevProps); if (defaultValue != oldProps->defaultValue) { result["defaultValue"] = defaultValue; } if (placeholder != oldProps->placeholder) { result["placeholder"] = placeholder; } if (placeholderTextColor != oldProps->placeholderTextColor) { result["placeholderTextColor"] = *placeholderTextColor; } if (editable != oldProps->editable) { result["editable"] = editable; } if (autoFocus != oldProps->autoFocus) { result["autoFocus"] = autoFocus; } if (scrollEnabled != oldProps->scrollEnabled) { result["scrollEnabled"] = scrollEnabled; } if (markdownShortcuts != oldProps->markdownShortcuts) { result["markdownShortcuts"] = toDynamic(markdownShortcuts); } if (autoCapitalize != oldProps->autoCapitalize) { result["autoCapitalize"] = autoCapitalize; } if (multiline != oldProps->multiline) { result["multiline"] = multiline; } if (cursorColor != oldProps->cursorColor) { result["cursorColor"] = *cursorColor; } if (selectionColor != oldProps->selectionColor) { result["selectionColor"] = *selectionColor; } if (markdownStyle != oldProps->markdownStyle) { result["markdownStyle"] = toDynamic(markdownStyle); } if (color != oldProps->color) { result["color"] = *color; } if ((fontSize != oldProps->fontSize) && !(std::isnan(fontSize) && std::isnan(oldProps->fontSize))) { result["fontSize"] = fontSize; } if ((lineHeight != oldProps->lineHeight) && !(std::isnan(lineHeight) && std::isnan(oldProps->lineHeight))) { result["lineHeight"] = lineHeight; } if (fontFamily != oldProps->fontFamily) { result["fontFamily"] = fontFamily; } if (fontWeight != oldProps->fontWeight) { result["fontWeight"] = fontWeight; } if (isOnChangeMarkdownSet != oldProps->isOnChangeMarkdownSet) { result["isOnChangeMarkdownSet"] = isOnChangeMarkdownSet; } if (contextMenuItems != oldProps->contextMenuItems) { result["contextMenuItems"] = toDynamic(contextMenuItems); } if (selectionMenuConfig != oldProps->selectionMenuConfig) { result["selectionMenuConfig"] = toDynamic(selectionMenuConfig); } if (formatMenuConfig != oldProps->formatMenuConfig) { result["formatMenuConfig"] = toDynamic(formatMenuConfig); } if (linkRegex != oldProps->linkRegex) { result["linkRegex"] = toDynamic(linkRegex); } if (mentionIndicators != oldProps->mentionIndicators) { result["mentionIndicators"] = toDynamic(mentionIndicators); } if (writingDirection != oldProps->writingDirection) { result["writingDirection"] = writingDirection; } return result; } #endif EnrichedMarkdownTextProps::EnrichedMarkdownTextProps( const PropsParserContext &context, const EnrichedMarkdownTextProps &sourceProps, const RawProps &rawProps): ViewProps(context, sourceProps, rawProps), markdown(convertRawProp(context, rawProps, "markdown", sourceProps.markdown, {})), markdownStyle(convertRawProp(context, rawProps, "markdownStyle", sourceProps.markdownStyle, {})), enableImagePress(convertRawProp(context, rawProps, "enableImagePress", sourceProps.enableImagePress, {false})), enableTaskListItemToggle(convertRawProp(context, rawProps, "enableTaskListItemToggle", sourceProps.enableTaskListItemToggle, {true})), enableCodeBlockPress(convertRawProp(context, rawProps, "enableCodeBlockPress", sourceProps.enableCodeBlockPress, {false})), enableBlockContextMenu(convertRawProp(context, rawProps, "enableBlockContextMenu", sourceProps.enableBlockContextMenu, {true})), enableLinkPreview(convertRawProp(context, rawProps, "enableLinkPreview", sourceProps.enableLinkPreview, {true})), selectable(convertRawProp(context, rawProps, "selectable", sourceProps.selectable, {false})), selectionColor(convertRawProp(context, rawProps, "selectionColor", sourceProps.selectionColor, {})), selectionHandleColor(convertRawProp(context, rawProps, "selectionHandleColor", sourceProps.selectionHandleColor, {})), md4cFlags(convertRawProp(context, rawProps, "md4cFlags", sourceProps.md4cFlags, {})), isGFM(convertRawProp(context, rawProps, "isGFM", sourceProps.isGFM, {false})), allowFontScaling(convertRawProp(context, rawProps, "allowFontScaling", sourceProps.allowFontScaling, {true})), maxFontSizeMultiplier(convertRawProp(context, rawProps, "maxFontSizeMultiplier", sourceProps.maxFontSizeMultiplier, {0.0})), allowTrailingMargin(convertRawProp(context, rawProps, "allowTrailingMargin", sourceProps.allowTrailingMargin, {false})), streamingAnimation(convertRawProp(context, rawProps, "streamingAnimation", sourceProps.streamingAnimation, {false})), streamingConfig(convertRawProp(context, rawProps, "streamingConfig", sourceProps.streamingConfig, {})), spoilerOverlay(convertRawProp(context, rawProps, "spoilerOverlay", sourceProps.spoilerOverlay, {std::string{"particles"}})), contextMenuItems(convertRawProp(context, rawProps, "contextMenuItems", sourceProps.contextMenuItems, {})), imageRequestHeaders(convertRawProp(context, rawProps, "imageRequestHeaders", sourceProps.imageRequestHeaders, {})), linkPillContent(convertRawProp(context, rawProps, "linkPillContent", sourceProps.linkPillContent, {})), linkRecognition(convertRawProp(context, rawProps, "linkRecognition", sourceProps.linkRecognition, {})), linkContextMenuItems(convertRawProp(context, rawProps, "linkContextMenuItems", sourceProps.linkContextMenuItems, {})), selectionMenuConfig(convertRawProp(context, rawProps, "selectionMenuConfig", sourceProps.selectionMenuConfig, {})), accessibilityLabels(convertRawProp(context, rawProps, "accessibilityLabels", sourceProps.accessibilityLabels, {})), textBreakStrategy(convertRawProp(context, rawProps, "textBreakStrategy", sourceProps.textBreakStrategy, {std::string{"highQuality"}})), lineBreakStrategyIOS(convertRawProp(context, rawProps, "lineBreakStrategyIOS", sourceProps.lineBreakStrategyIOS, {std::string{"none"}})), writingDirection(convertRawProp(context, rawProps, "writingDirection", sourceProps.writingDirection, {std::string{"first-strong"}})), numberOfLines(convertRawProp(context, rawProps, "numberOfLines", sourceProps.numberOfLines, {0})), ellipsizeMode(convertRawProp(context, rawProps, "ellipsizeMode", sourceProps.ellipsizeMode, {std::string{"tail"}})) {} #ifdef RN_SERIALIZABLE_STATE ComponentName EnrichedMarkdownTextProps::getDiffPropsImplementationTarget() const { return "EnrichedMarkdownText"; } folly::dynamic EnrichedMarkdownTextProps::getDiffProps( const Props* prevProps) const { static const auto defaultProps = EnrichedMarkdownTextProps(); const EnrichedMarkdownTextProps* oldProps = prevProps == nullptr ? &defaultProps : static_cast(prevProps); if (this == oldProps) { return folly::dynamic::object(); } folly::dynamic result = HostPlatformViewProps::getDiffProps(prevProps); if (markdown != oldProps->markdown) { result["markdown"] = markdown; } if (markdownStyle != oldProps->markdownStyle) { result["markdownStyle"] = toDynamic(markdownStyle); } if (enableImagePress != oldProps->enableImagePress) { result["enableImagePress"] = enableImagePress; } if (enableTaskListItemToggle != oldProps->enableTaskListItemToggle) { result["enableTaskListItemToggle"] = enableTaskListItemToggle; } if (enableCodeBlockPress != oldProps->enableCodeBlockPress) { result["enableCodeBlockPress"] = enableCodeBlockPress; } if (enableBlockContextMenu != oldProps->enableBlockContextMenu) { result["enableBlockContextMenu"] = enableBlockContextMenu; } if (enableLinkPreview != oldProps->enableLinkPreview) { result["enableLinkPreview"] = enableLinkPreview; } if (selectable != oldProps->selectable) { result["selectable"] = selectable; } if (selectionColor != oldProps->selectionColor) { result["selectionColor"] = *selectionColor; } if (selectionHandleColor != oldProps->selectionHandleColor) { result["selectionHandleColor"] = *selectionHandleColor; } if (md4cFlags != oldProps->md4cFlags) { result["md4cFlags"] = toDynamic(md4cFlags); } if (isGFM != oldProps->isGFM) { result["isGFM"] = isGFM; } if (allowFontScaling != oldProps->allowFontScaling) { result["allowFontScaling"] = allowFontScaling; } if ((maxFontSizeMultiplier != oldProps->maxFontSizeMultiplier) && !(std::isnan(maxFontSizeMultiplier) && std::isnan(oldProps->maxFontSizeMultiplier))) { result["maxFontSizeMultiplier"] = maxFontSizeMultiplier; } if (allowTrailingMargin != oldProps->allowTrailingMargin) { result["allowTrailingMargin"] = allowTrailingMargin; } if (streamingAnimation != oldProps->streamingAnimation) { result["streamingAnimation"] = streamingAnimation; } if (streamingConfig != oldProps->streamingConfig) { result["streamingConfig"] = toDynamic(streamingConfig); } if (spoilerOverlay != oldProps->spoilerOverlay) { result["spoilerOverlay"] = spoilerOverlay; } if (contextMenuItems != oldProps->contextMenuItems) { result["contextMenuItems"] = toDynamic(contextMenuItems); } if (imageRequestHeaders != oldProps->imageRequestHeaders) { result["imageRequestHeaders"] = toDynamic(imageRequestHeaders); } if (linkPillContent != oldProps->linkPillContent) { result["linkPillContent"] = toDynamic(linkPillContent); } if (linkRecognition != oldProps->linkRecognition) { result["linkRecognition"] = toDynamic(linkRecognition); } if (linkContextMenuItems != oldProps->linkContextMenuItems) { result["linkContextMenuItems"] = toDynamic(linkContextMenuItems); } if (selectionMenuConfig != oldProps->selectionMenuConfig) { result["selectionMenuConfig"] = toDynamic(selectionMenuConfig); } if (accessibilityLabels != oldProps->accessibilityLabels) { result["accessibilityLabels"] = toDynamic(accessibilityLabels); } if (textBreakStrategy != oldProps->textBreakStrategy) { result["textBreakStrategy"] = textBreakStrategy; } if (lineBreakStrategyIOS != oldProps->lineBreakStrategyIOS) { result["lineBreakStrategyIOS"] = lineBreakStrategyIOS; } if (writingDirection != oldProps->writingDirection) { result["writingDirection"] = writingDirection; } if (numberOfLines != oldProps->numberOfLines) { result["numberOfLines"] = numberOfLines; } if (ellipsizeMode != oldProps->ellipsizeMode) { result["ellipsizeMode"] = ellipsizeMode; } return result; } #endif } // namespace facebook::react