From 1e0f72a7e193a899908366718e262216d97908d8 Mon Sep 17 00:00:00 2001 From: anna-dingler <98650930+anna-dingler@users.noreply.github.com> Date: Thu, 15 Dec 2022 16:41:41 -0800 Subject: [PATCH 1/6] Switch to gotFocus (#8148) (#8150) --- source/uwp/Renderer/lib/AdaptiveChoiceSetInputRenderer.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/source/uwp/Renderer/lib/AdaptiveChoiceSetInputRenderer.cpp b/source/uwp/Renderer/lib/AdaptiveChoiceSetInputRenderer.cpp index 2c59484bb0..fa4cf52ad5 100644 --- a/source/uwp/Renderer/lib/AdaptiveChoiceSetInputRenderer.cpp +++ b/source/uwp/Renderer/lib/AdaptiveChoiceSetInputRenderer.cpp @@ -238,8 +238,8 @@ namespace winrt::AdaptiveCards::Rendering::Uwp::implementation autoSuggestBox.ItemsSource(choiceList); // When we get focus open the suggestion list. This ensures the choices are shown on first focus. - autoSuggestBox.GettingFocus( - [](IInspectable const& sender, winrt::GettingFocusEventArgs const& /* args */) -> void + autoSuggestBox.GotFocus( + [](IInspectable const& sender, winrt::RoutedEventArgs const& /* args */) -> void { if (const auto autoSuggestBox = sender.try_as()) { From 61db685b59e91387d71c6aa091def653617c93c2 Mon Sep 17 00:00:00 2001 From: Joseph Woo Date: Thu, 15 Dec 2022 21:06:27 -0800 Subject: [PATCH 2/6] Update custom.props --- custom.props | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/custom.props b/custom.props index 5f5fedc380..4a7e41ce8c 100644 --- a/custom.props +++ b/custom.props @@ -2,9 +2,9 @@ 3 - 0 + 1 - 3.0.2 + 3.1.0 AdaptiveCards From 0593d95a94d4446d97b3d39349a1c707315ae313 Mon Sep 17 00:00:00 2001 From: anna-dingler <98650930+anna-dingler@users.noreply.github.com> Date: Thu, 12 Jan 2023 16:01:01 -0800 Subject: [PATCH 3/6] [UWP] Update custom.props for object model release (#8225) * Update custom.props for object model release * Updated Xcode version (#8222) * removed build step as they are redundant (#8201) * removed build step as they are redundant * added pod installation step Co-authored-by: Joseph Woo --- .pipelines/templates/ios-ci-template.yml | 11 +++++++---- custom.props | 4 ++-- 2 files changed, 9 insertions(+), 6 deletions(-) diff --git a/.pipelines/templates/ios-ci-template.yml b/.pipelines/templates/ios-ci-template.yml index 2e54f36777..7331f25712 100644 --- a/.pipelines/templates/ios-ci-template.yml +++ b/.pipelines/templates/ios-ci-template.yml @@ -1,5 +1,9 @@ steps: -- template: ios-build-template.yml +- task: CocoaPods@0 + displayName: 'Installing dependency via pod' + inputs: + workingDirectory: 'source/ios/AdaptiveCards' + forceRepoUpdate: false - task: Xcode@5 displayName: 'Sample App Unit Test' @@ -7,7 +11,7 @@ steps: actions: 'test' xcWorkspacePath: 'source/ios/AdaptiveCards/AdaptiveCards.xcworkspace' scheme: 'ADCIOSVisualizer' - xcodeVersion: '12' + xcodeVersion: 'default' packageApp: false signingOption: 'default' sdk: 'iphonesimulator' @@ -15,13 +19,12 @@ steps: destinationSimulators: 'iPhone 12' - task: Xcode@5 - displayName: 'Framework Unit Test' inputs: actions: 'test' xcWorkspacePath: 'source/ios/AdaptiveCards/AdaptiveCards.xcworkspace' scheme: 'AdaptiveCards' - xcodeVersion: '12' + xcodeVersion: 'default' packageApp: false signingOption: 'default' sdk: 'iphonesimulator' diff --git a/custom.props b/custom.props index 4a7e41ce8c..a24ca7b33c 100644 --- a/custom.props +++ b/custom.props @@ -1,10 +1,10 @@ - 3 + 1 1 - 3.1.0 + 1.1.0 AdaptiveCards From 90b97be59b0f76f2ff8ab822c2ebed96eedb6422 Mon Sep 17 00:00:00 2001 From: anna-dingler <98650930+anna-dingler@users.noreply.github.com> Date: Fri, 13 Jan 2023 10:35:11 -0800 Subject: [PATCH 4/6] [UWP Renderer] Add a null check to inline action rendering (#8228) * Update custom.props for object model release * Updated Xcode version (#8222) * removed build step as they are redundant (#8201) * removed build step as they are redundant * added pod installation step * Add a null check for inline Actions Co-authored-by: Joseph Woo --- source/uwp/Renderer/lib/AdaptiveTextInputRenderer.cpp | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/source/uwp/Renderer/lib/AdaptiveTextInputRenderer.cpp b/source/uwp/Renderer/lib/AdaptiveTextInputRenderer.cpp index f86c3b7186..b02432afed 100644 --- a/source/uwp/Renderer/lib/AdaptiveTextInputRenderer.cpp +++ b/source/uwp/Renderer/lib/AdaptiveTextInputRenderer.cpp @@ -41,8 +41,14 @@ namespace winrt::AdaptiveCards::Rendering::Uwp::implementation bool isMultiline = adaptiveTextInput.IsMultiline(); winrt::TextInputStyle style = adaptiveTextInput.TextInputStyle(); isMultiline &= style != winrt::TextInputStyle::Password; - textBoxParentContainer = render_xaml::ActionHelpers::HandleInlineAction( + auto textBoxWithInlineAction = render_xaml::ActionHelpers::HandleInlineAction( renderContext, renderArgs, inputUIElement, textBoxParentContainer, isMultiline, inlineAction); + + // If the inlineAction is ShowCard, textBoxWithInlineAction will be null and we should not update the parent container + if (textBoxWithInlineAction) + { + textBoxParentContainer = textBoxWithInlineAction; + } } if (!adaptiveTextInput.IsMultiline()) From 85676f6d953bd12ef3a9d8c3507f9c40a6c269d8 Mon Sep 17 00:00:00 2001 From: Anna Dingler Date: Mon, 16 Jan 2023 22:06:56 -0800 Subject: [PATCH 5/6] Update min/max handling for inputs --- source/uwp/Renderer/lib/InputValue.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/source/uwp/Renderer/lib/InputValue.cpp b/source/uwp/Renderer/lib/InputValue.cpp index 5ba2803b6c..b0b0d2a4a8 100644 --- a/source/uwp/Renderer/lib/InputValue.cpp +++ b/source/uwp/Renderer/lib/InputValue.cpp @@ -184,13 +184,13 @@ namespace winrt::AdaptiveCards::Rendering::Uwp if (max) { double maxDouble = max.Value(); - isValid = (currentDouble <= maxDouble); + isValid &= (currentDouble <= maxDouble); } if (min) { double minDouble = min.Value(); - isValid = (currentDouble >= minDouble); + isValid &= (currentDouble >= minDouble); } } catch (...) @@ -278,7 +278,7 @@ namespace winrt::AdaptiveCards::Rendering::Uwp unsigned int minHours, minMinutes; if (::AdaptiveCards::DateTimePreparser::TryParseSimpleTime(minTimeStdString, minHours, minMinutes)) { - winrt::TimeSpan minTime{(int64_t)(minHours * 60 + minMinutes) * 1000000 * 60}; + winrt::TimeSpan minTime{(int64_t)(minHours * 60 + minMinutes) * 10000000 * 60}; isMaxMinValid &= currentTime.count() >= minTime.count(); } } From 2000d3ab79666299523062171c85ea3a3b36f50c Mon Sep 17 00:00:00 2001 From: anna-dingler <98650930+anna-dingler@users.noreply.github.com> Date: Tue, 17 Jan 2023 16:09:35 -0800 Subject: [PATCH 6/6] [UWP][Infra] Update nuget files for release (#6576) (#8240) * [UWP][Infra] Update nuget files for release (#6576) * Add new nuspec files * Fix nuspec * Update build copy script * Add dependency to renderer * 1.5 website schema explorer updates (#6550) * Updating schema explorer properties * adding tableCell to toc and attempting whitespace fix * indentation fix indentation fix * Removing filtered prop Removing filtered prop - it's auto generated in our build Co-authored-by: RahulAmlekar * Custom.props to 1.0.0 for Object model build * Update dependency version Co-authored-by: Rahul Amlekar Co-authored-by: RahulAmlekar Co-authored-by: Rebecca Muraira * Remove blank lines Co-authored-by: almedina-ms <35784165+almedina-ms@users.noreply.github.com> Co-authored-by: Rahul Amlekar Co-authored-by: RahulAmlekar Co-authored-by: Rebecca Muraira --- source/uwp/Build/CopySignFiles.cmd | 24 ++++++++++++++++++++++++ 1 file changed, 24 insertions(+) diff --git a/source/uwp/Build/CopySignFiles.cmd b/source/uwp/Build/CopySignFiles.cmd index 2a68b57984..92fe67eef1 100644 --- a/source/uwp/Build/CopySignFiles.cmd +++ b/source/uwp/Build/CopySignFiles.cmd @@ -4,10 +4,12 @@ REM This script copies the dll and winmd files to have different names to be sig REM setting platform variables set AC=AdaptiveCards set ACUWP=AdaptiveCards.Rendering.Uwp +set ACOM=AdaptiveCards.ObjectModel.Uwp REM setting path variables set ACROOT=source\uwp\ set ACPATH=AdaptiveCardRenderer\ +set ACPATHOM=AdaptiveCardsObjectModel\ set BINPATH=Release\ if "%2" == "" goto :usage @@ -34,6 +36,21 @@ call :checkedCopy %ACROOT%x64\Release\%ACPATH%%ACUWP%.dll tosign\%ACPATH%x64\%AC call :checkedCopy %ACROOT%ARM\Release\%ACPATH%%ACUWP%.dll tosign\%ACPATH%ARM\%ACUWP%.dll call :checkedCopy %ACROOT%ARM64\Release\%ACPATH%%ACUWP%.dll tosign\%ACPATH%ARM64\%ACUWP%.dll +REM AdaptiveCards +echo %ACPATHOM% +REM AdaptiveCards ObjectModel + +mkdir tosign\%ACPATHOM%\Win32 +mkdir tosign\%ACPATHOM%\x64 +mkdir tosign\%ACPATHOM%\ARM +mkdir tosign\%ACPATHOM%\ARM64 + +call :checkedCopy %ACROOT%\Release\%ACPATHOM%%ACOM%.winmd tosign\%ACPATHOM%%ACOM%.winmd +call :checkedCopy %ACROOT%Release\%ACPATHOM%%ACOM%.dll tosign\%ACPATHOM%Win32\%ACOM%.dll +call :checkedCopy %ACROOT%x64\Release\%ACPATHOM%%ACOM%.dll tosign\%ACPATHOM%x64\%ACOM%.dll +call :checkedCopy %ACROOT%ARM\Release\%ACPATHOM%%ACOM%.dll tosign\%ACPATHOM%ARM\%ACOM%.dll +call :checkedCopy %ACROOT%ARM64\Release\%ACPATHOM%%ACOM%.dll tosign\%ACPATHOM%ARM64\%ACOM%.dll + popd goto :end @@ -47,6 +64,13 @@ call :checkedCopy signed\%ACPATH%x64\%ACUWP%.dll %ACROOT%x64\Release\%ACPATH%%AC call :checkedCopy signed\%ACPATH%ARM\%ACUWP%.dll %ACROOT%ARM\Release\%ACPATH%%ACUWP%.dll call :checkedCopy signed\%ACPATH%ARM64\%ACUWP%.dll %ACROOT%ARM64\Release\%ACPATH%%ACUWP%.dll +REM AdaptiveCardsObjectModel +call :checkedCopy signed\%ACPATHOM%%ACOM%.winmd %ACROOT%Release\%ACPATHOM%%ACOM%.winmd +call :checkedCopy signed\%ACPATHOM%Win32\%ACOM%.dll %ACROOT%Release\%ACPATHOM%%ACOM%.dll +call :checkedCopy signed\%ACPATHOM%x64\%ACOM%.dll %ACROOT%x64\Release\%ACPATHOM%%ACOM%.dll +call :checkedCopy signed\%ACPATHOM%ARM\%ACOM%.dll %ACROOT%ARM\Release\%ACPATHOM%%ACOM%.dll +call :checkedCopy signed\%ACPATHOM%ARM64\%ACOM%.dll %ACROOT%ARM64\Release\%ACPATHOM%%ACOM%.dll + popd goto :end