Skip to content

Commit

Permalink
Merge pull request #45 from Kentico/snyk-upgrade-bfe06e99814c1a4d5351…
Browse files Browse the repository at this point in the history
…aee1b2228d17

[Snyk] Upgrade react-tooltip from 5.26.3 to 5.26.4
  • Loading branch information
bkapustik authored May 20, 2024
2 parents 35a4982 + 8916b48 commit 174af73
Show file tree
Hide file tree
Showing 15 changed files with 93 additions and 88 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -40,9 +40,9 @@ public class SampleDataGeneratorApplication : OverviewPageBase

private readonly IFormBuilderConfigurationSerializer formBuilderConfigurationSerializer;
private readonly IEventLogService eventLogService;
private readonly IConsentInfoProvider consentInfoProvider;
private readonly IBizFormInfoProvider bizFormInfoProvider;
private readonly IContactGroupInfoProvider contactGroupInfoProvider;
private readonly IInfoProvider<ConsentInfo> consentInfoProvider;
private readonly IInfoProvider<BizFormInfo> bizFormInfoProvider;
private readonly IInfoProvider<ContactGroupInfo> contactGroupInfoProvider;
private readonly ISettingsKeyInfoProvider settingsKeyInfoProvider;
private readonly IInfoProvider<WebsiteChannelInfo> websiteChannelInfoProvider;

Expand All @@ -60,9 +60,9 @@ public class SampleDataGeneratorApplication : OverviewPageBase
public SampleDataGeneratorApplication(
IFormBuilderConfigurationSerializer formBuilderConfigurationSerializer,
IEventLogService eventLogService,
IConsentInfoProvider consentInfoProvider,
IBizFormInfoProvider bizFormInfoProvider,
IContactGroupInfoProvider contactGroupInfoProvider,
IInfoProvider<ConsentInfo> consentInfoProvider,
IInfoProvider<BizFormInfo> bizFormInfoProvider,
IInfoProvider<ContactGroupInfo> contactGroupInfoProvider,
ISettingsKeyInfoProvider settingsKeyInfoProvider,
IInfoProvider<WebsiteChannelInfo> websiteChannelInfoProvider)
{
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
using System.Threading.Tasks;

using CMS.ContactManagement;
using CMS.DataEngine;
using CMS.DataProtection;
using CMS.Websites;
using CMS.Websites.Routing;
Expand All @@ -17,7 +18,7 @@ namespace DancingGoat.ViewComponents
{
public class TrackingConsentViewComponent : ViewComponent
{
private readonly IConsentInfoProvider consentInfoProvider;
private readonly IInfoProvider<ConsentInfo> consentInfoProvider;
private readonly IConsentAgreementService consentAgreementService;
private readonly IPreferredLanguageRetriever currentLanguageRetriever;
private readonly IWebPageDataContextRetriever webPageDataContextRetriever;
Expand All @@ -26,7 +27,7 @@ public class TrackingConsentViewComponent : ViewComponent


public TrackingConsentViewComponent(
IConsentInfoProvider consentInfoProvider,
IInfoProvider<ConsentInfo> consentInfoProvider,
IConsentAgreementService consentAgreementService,
IPreferredLanguageRetriever currentLanguageRetriever,
IWebPageDataContextRetriever webPageDataContextRetriever,
Expand Down
5 changes: 3 additions & 2 deletions examples/DancingGoat/Controllers/ConsentController.cs
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
using CMS.ContactManagement;
using CMS.DataEngine;
using CMS.DataProtection;
using CMS.Helpers;

Expand All @@ -13,10 +14,10 @@ public class ConsentController : Controller
{
private readonly ICurrentCookieLevelProvider cookieLevelProvider;
private readonly IConsentAgreementService consentAgreementService;
private readonly IConsentInfoProvider consentInfoProvider;
private readonly IInfoProvider<ConsentInfo> consentInfoProvider;


public ConsentController(ICurrentCookieLevelProvider cookieLevelProvider, IConsentAgreementService consentAgreementService, IConsentInfoProvider consentInfoProvider)
public ConsentController(ICurrentCookieLevelProvider cookieLevelProvider, IConsentAgreementService consentAgreementService, IInfoProvider<ConsentInfo> consentInfoProvider)
{
this.cookieLevelProvider = cookieLevelProvider;
this.consentAgreementService = consentAgreementService;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
using System.Linq;

using CMS.ContactManagement;
using CMS.DataEngine;
using CMS.DataProtection;

using DancingGoat;
Expand All @@ -24,7 +25,7 @@ public class DancingGoatPrivacyController : Controller
private const string ERROR_RESULT = "error";

private readonly IConsentAgreementService consentAgreementService;
private readonly IConsentInfoProvider consentInfoProvider;
private readonly IInfoProvider<ConsentInfo> consentInfoProvider;
private readonly IPreferredLanguageRetriever currentLanguageRetriever;
private ContactInfo currentContact;

Expand All @@ -43,7 +44,7 @@ private ContactInfo CurrentContact
}


public DancingGoatPrivacyController(IConsentAgreementService consentAgreementService, IConsentInfoProvider consentInfoProvider, IPreferredLanguageRetriever currentLanguageRetriever)
public DancingGoatPrivacyController(IConsentAgreementService consentAgreementService, IInfoProvider<ConsentInfo> consentInfoProvider, IPreferredLanguageRetriever currentLanguageRetriever)
{
this.consentAgreementService = consentAgreementService;
this.consentInfoProvider = consentInfoProvider;
Expand Down
2 changes: 1 addition & 1 deletion examples/DancingGoat/DancingGoat.csproj
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<Project Sdk="Microsoft.NET.Sdk.Web">
<PropertyGroup>
<RootNamespace>DancingGoat</RootNamespace>
<UserSecretsId>7e8a56d7-ac0a-4d47-af57-fc423c65eafb</UserSecretsId>
<UserSecretsId>7e8a56d7-ac0a-4d47-af57-fc423c65gafb</UserSecretsId>
<SeparatedAdmin Condition="'$(SeparatedAdmin)' == ''">false</SeparatedAdmin>
<Nullable>annotations</Nullable>
<RunAnalyzersDuringBuild>false</RunAnalyzersDuringBuild>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -30,16 +30,16 @@ internal class DancingGoatSamplesModule : Module
{
private const string DATA_PROTECTION_SAMPLES_ENABLED_SETTINGS_KEY_NAME = "DataProtectionSamplesEnabled";

private IContactInfoProvider contactInfoProvider;
private IInfoProvider<ContactInfo> contactInfoProvider;
private IMemberInfoProvider memberInfoProvider;
private IConsentAgreementInfoProvider consentAgreementInfoProvider;
private IBizFormInfoProvider bizFormInfoProvider;
private IAccountContactInfoProvider accountContactInfoProvider;
private ISettingsKeyInfoProvider settingsKeyInfoProvider;
private IActivityInfoProvider activityInfoProvider;
private ICountryInfoProvider countryInfoProvider;
private IStateInfoProvider stateInfoProvider;
private IAccountInfoProvider accountInfoProvider;
private IInfoProvider<ConsentAgreementInfo> consentAgreementInfoProvider;
private IInfoProvider<BizFormInfo> bizFormInfoProvider;
private IInfoProvider<AccountContactInfo> accountContactInfoProvider;
private IInfoProvider<SettingsKeyInfo> settingsKeyInfoProvider;
private IInfoProvider<ActivityInfo> activityInfoProvider;
private IInfoProvider<CountryInfo> countryInfoProvider;
private IInfoProvider<StateInfo> stateInfoProvider;
private IInfoProvider<AccountInfo> accountInfoProvider;


/// <summary>
Expand All @@ -57,16 +57,16 @@ protected override void OnInit()
{
base.OnInit();

contactInfoProvider = Service.Resolve<IContactInfoProvider>();
contactInfoProvider = Service.Resolve<IInfoProvider<ContactInfo>>();
memberInfoProvider = Service.Resolve<IMemberInfoProvider>();
consentAgreementInfoProvider = Service.Resolve<IConsentAgreementInfoProvider>();
bizFormInfoProvider = Service.Resolve<IBizFormInfoProvider>();
accountContactInfoProvider = Service.Resolve<IAccountContactInfoProvider>();
settingsKeyInfoProvider = Service.Resolve<ISettingsKeyInfoProvider>();
activityInfoProvider = Service.Resolve<IActivityInfoProvider>();
countryInfoProvider = Service.Resolve<ICountryInfoProvider>();
stateInfoProvider = Service.Resolve<IStateInfoProvider>();
accountInfoProvider = Service.Resolve<IAccountInfoProvider>();
consentAgreementInfoProvider = Service.Resolve<IInfoProvider<ConsentAgreementInfo>>();
bizFormInfoProvider = Service.Resolve<IInfoProvider<BizFormInfo>>();
accountContactInfoProvider = Service.Resolve<IInfoProvider<AccountContactInfo>>();
settingsKeyInfoProvider = Service.Resolve<IInfoProvider<SettingsKeyInfo>>();
activityInfoProvider = Service.Resolve<IInfoProvider<ActivityInfo>>();
countryInfoProvider = Service.Resolve<IInfoProvider<CountryInfo>>();
stateInfoProvider = Service.Resolve<IInfoProvider<StateInfo>>();
accountInfoProvider = Service.Resolve<IInfoProvider<AccountInfo>>();

InitializeSamples();
}
Expand All @@ -78,7 +78,7 @@ protected override void OnInit()
/// </summary>
private void InitializeSamples()
{
var dataProtectionSamplesEnabledSettingsKey = settingsKeyInfoProvider.Get(DATA_PROTECTION_SAMPLES_ENABLED_SETTINGS_KEY_NAME);
var dataProtectionSamplesEnabledSettingsKey = settingsKeyInfoProvider.Get().WhereEquals(nameof(SettingsKeyInfo.KeyName), DATA_PROTECTION_SAMPLES_ENABLED_SETTINGS_KEY_NAME).FirstOrDefault();
if (dataProtectionSamplesEnabledSettingsKey?.KeyValue.ToBoolean(false) ?? false)
{
RegisterSamples();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,14 +12,14 @@ namespace Samples.DancingGoat
/// </summary>
internal class SampleContactInfoIdentityCollector : IIdentityCollector
{
private readonly IContactInfoProvider contactInfoProvider;
private readonly IInfoProvider<ContactInfo> contactInfoProvider;


/// <summary>
/// Initializes a new instance of the <see cref="SampleContactInfoIdentityCollector"/> class.
/// </summary>
/// <param name="contactInfoProvider">Contact info provider.</param>
public SampleContactInfoIdentityCollector(IContactInfoProvider contactInfoProvider)
public SampleContactInfoIdentityCollector(IInfoProvider<ContactInfo> contactInfoProvider)
{
this.contactInfoProvider = contactInfoProvider;
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,13 +14,13 @@ namespace Samples.DancingGoat
/// </summary>
internal class SampleContactDataCollector : IPersonalDataCollector
{
private readonly IActivityInfoProvider activityInfoProvider;
private readonly ICountryInfoProvider countryInfoProvider;
private readonly IStateInfoProvider stateInfoProvider;
private readonly IConsentAgreementInfoProvider consentAgreementInfoProvider;
private readonly IAccountContactInfoProvider accountContactInfoProvider;
private readonly IAccountInfoProvider accountInfoProvider;
private readonly IBizFormInfoProvider bizFormInfoProvider;
private readonly IInfoProvider<ActivityInfo> activityInfoProvider;
private readonly IInfoProvider<CountryInfo> countryInfoProvider;
private readonly IInfoProvider<StateInfo> stateInfoProvider;
private readonly IInfoProvider<ConsentAgreementInfo> consentAgreementInfoProvider;
private readonly IInfoProvider<AccountContactInfo> accountContactInfoProvider;
private readonly IInfoProvider<AccountInfo> accountInfoProvider;
private readonly IInfoProvider<BizFormInfo> bizFormInfoProvider;


/// <summary>
Expand All @@ -34,13 +34,13 @@ internal class SampleContactDataCollector : IPersonalDataCollector
/// <param name="accountInfoProvider">Account info provider.</param>
/// <param name="bizFormInfoProvider">BizForm info provider.</param>
public SampleContactDataCollector(
IActivityInfoProvider activityInfoProvider,
ICountryInfoProvider countryInfoProvider,
IStateInfoProvider stateInfoProvider,
IConsentAgreementInfoProvider consentAgreementInfoProvider,
IAccountContactInfoProvider accountContactInfoProvider,
IAccountInfoProvider accountInfoProvider,
IBizFormInfoProvider bizFormInfoProvider)
IInfoProvider<ActivityInfo> activityInfoProvider,
IInfoProvider<CountryInfo> countryInfoProvider,
IInfoProvider<StateInfo> stateInfoProvider,
IInfoProvider<ConsentAgreementInfo> consentAgreementInfoProvider,
IInfoProvider<AccountContactInfo> accountContactInfoProvider,
IInfoProvider<AccountInfo> accountInfoProvider,
IInfoProvider<BizFormInfo> bizFormInfoProvider)
{
this.activityInfoProvider = activityInfoProvider;
this.countryInfoProvider = countryInfoProvider;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,13 +20,13 @@ namespace Samples.DancingGoat
internal class SampleContactDataCollectorCore
{
private readonly IPersonalDataWriter writer;
private readonly IActivityInfoProvider activityInfoProvider;
private readonly ICountryInfoProvider countryInfoProvider;
private readonly IStateInfoProvider stateInfoProvider;
private readonly IConsentAgreementInfoProvider consentAgreementInfoProvider;
private readonly IAccountContactInfoProvider accountContactInfoProvider;
private readonly IAccountInfoProvider accountInfoProvider;
private readonly IBizFormInfoProvider bizFormInfoProvider;
private readonly IInfoProvider<ActivityInfo> activityInfoProvider;
private readonly IInfoProvider<CountryInfo> countryInfoProvider;
private readonly IInfoProvider<StateInfo> stateInfoProvider;
private readonly IInfoProvider<ConsentAgreementInfo> consentAgreementInfoProvider;
private readonly IInfoProvider<AccountContactInfo> accountContactInfoProvider;
private readonly IInfoProvider<AccountInfo> accountInfoProvider;
private readonly IInfoProvider<BizFormInfo> bizFormInfoProvider;

// Lists store Tuples of database column names and their corresponding display names.
private readonly List<CollectedColumn> contactInfoColumns = new List<CollectedColumn> {
Expand Down Expand Up @@ -325,13 +325,13 @@ private object TransformConsentAction(string columnName, object columnValue)
/// <param name="bizFormInfoProvider">BizForm info provider.</param>
public SampleContactDataCollectorCore(
IPersonalDataWriter writer,
IActivityInfoProvider activityInfoProvider,
ICountryInfoProvider countryInfoProvider,
IStateInfoProvider stateInfoProvider,
IConsentAgreementInfoProvider consentAgreementInfoProvider,
IAccountContactInfoProvider accountContactInfoProvider,
IAccountInfoProvider accountInfoProvider,
IBizFormInfoProvider bizFormInfoProvider)
IInfoProvider<ActivityInfo> activityInfoProvider,
IInfoProvider<CountryInfo> countryInfoProvider,
IInfoProvider<StateInfo> stateInfoProvider,
IInfoProvider<ConsentAgreementInfo> consentAgreementInfoProvider,
IInfoProvider<AccountContactInfo> accountContactInfoProvider,
IInfoProvider<AccountInfo> accountInfoProvider,
IInfoProvider<BizFormInfo> bizFormInfoProvider)
{
this.writer = writer;
this.activityInfoProvider = activityInfoProvider;
Expand Down Expand Up @@ -401,11 +401,11 @@ private void WriteContacts(IEnumerable<ContactInfo> contacts)
var stateID = contactInfo.ContactStateID;
if (countryID != 0)
{
writer.WriteBaseInfo(countryInfoProvider.Get(countryID), countryInfoColumns);
writer.WriteBaseInfo(countryInfoProvider.Get().WithID(countryID).FirstOrDefault(), countryInfoColumns);
}
if (stateID != 0)
{
writer.WriteBaseInfo(stateInfoProvider.Get(stateID), stateInfoColumns);
writer.WriteBaseInfo(stateInfoProvider.Get().WithID(stateID).FirstOrDefault(), stateInfoColumns);
}

writer.WriteEndSection();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -35,10 +35,10 @@ internal class SampleContactPersonalDataEraser : IPersonalDataEraser
{ new Guid("DAAA080A-7B6B-489E-8150-290B1F24E715"), "Email" }
};

private readonly IConsentAgreementInfoProvider consentAgreementInfoProvider;
private readonly IBizFormInfoProvider bizFormInfoProvider;
private readonly IAccountContactInfoProvider accountContactInfoProvider;
private readonly IContactInfoProvider contactInfoProvider;
private readonly IInfoProvider<ConsentAgreementInfo> consentAgreementInfoProvider;
private readonly IInfoProvider<BizFormInfo> bizFormInfoProvider;
private readonly IInfoProvider<AccountContactInfo> accountContactInfoProvider;
private readonly IInfoProvider<ContactInfo> contactInfoProvider;


/// <summary>
Expand All @@ -49,10 +49,10 @@ internal class SampleContactPersonalDataEraser : IPersonalDataEraser
/// <param name="accountContactInfoProvider">Account contact info provider.</param>
/// <param name="contactInfoProvider">Contact info provider.</param>
public SampleContactPersonalDataEraser(
IConsentAgreementInfoProvider consentAgreementInfoProvider,
IBizFormInfoProvider bizFormInfoProvider,
IAccountContactInfoProvider accountContactInfoProvider,
IContactInfoProvider contactInfoProvider)
IInfoProvider<ConsentAgreementInfo> consentAgreementInfoProvider,
IInfoProvider<BizFormInfo> bizFormInfoProvider,
IInfoProvider<AccountContactInfo> accountContactInfoProvider,
IInfoProvider<ContactInfo> contactInfoProvider)
{
this.consentAgreementInfoProvider = consentAgreementInfoProvider;
this.bizFormInfoProvider = bizFormInfoProvider;
Expand Down Expand Up @@ -210,4 +210,4 @@ private void DeleteContacts(IEnumerable<ContactInfo> contacts, IDictionary<strin
}
}
}
}
}
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
using CMS.ContactManagement;
using CMS.DataEngine;
using CMS.MacroEngine;
using CMS.Membership;

Expand All @@ -9,14 +10,14 @@ public class FormContactGroupGenerator
private const string CONTACT_GROUP_DISPLAY_NAME = "Coffee samples applicants";
private const string CONTACT_GROUP_NAME = "CoffeeSamplesApplicants";

private readonly IContactGroupInfoProvider contactGroupInfoProvider;
private readonly IInfoProvider<ContactGroupInfo> contactGroupInfoProvider;


/// <summary>
/// Initializes a new instance of the <see cref="FormContactGroupGenerator"/> class.
/// </summary>
/// <param name="contactGroupInfoProvider">Contact group info provider.</param>
public FormContactGroupGenerator(IContactGroupInfoProvider contactGroupInfoProvider)
public FormContactGroupGenerator(IInfoProvider<ContactGroupInfo> contactGroupInfoProvider)
{
this.contactGroupInfoProvider = contactGroupInfoProvider;
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28,8 +28,8 @@ public class FormConsentGenerator
private const string CONSENT_SHORT_TEXT_ES = "<p>Por lo presente acepto que esta información proporcionada puede ser utilizada con fines de marketing y contenido de sitios web dirigidos.</p>";

private readonly IFormBuilderConfigurationSerializer formBuilderConfigurationSerializer;
private readonly IConsentInfoProvider consentInfoProvider;
private readonly IBizFormInfoProvider bizFormInfoProvider;
private readonly IInfoProvider<ConsentInfo> consentInfoProvider;
private readonly IInfoProvider<BizFormInfo> bizFormInfoProvider;


/// <summary>
Expand All @@ -40,8 +40,8 @@ public class FormConsentGenerator
/// <param name="bizFormInfoProvider">BizForm info provide.</param>
public FormConsentGenerator(
IFormBuilderConfigurationSerializer formBuilderConfigurationSerializer,
IConsentInfoProvider consentInfoProvider,
IBizFormInfoProvider bizFormInfoProvider)
IInfoProvider<ConsentInfo> consentInfoProvider,
IInfoProvider<BizFormInfo> bizFormInfoProvider)
{
this.formBuilderConfigurationSerializer = formBuilderConfigurationSerializer;
this.consentInfoProvider = consentInfoProvider;
Expand Down
Loading

0 comments on commit 174af73

Please sign in to comment.