diff --git a/src/Byteology.Website/Company/ContactsPage.razor b/src/Byteology.Website/Company/ContactsPage.razor index ced3fac..3223d2c 100644 --- a/src/Byteology.Website/Company/ContactsPage.razor +++ b/src/Byteology.Website/Company/ContactsPage.razor @@ -6,8 +6,8 @@ @using Byteology.Website.Inquiry @using Byteology.Website.Layout - + Keywords="@(new string[] { "schedule", "meeting" })" /> diff --git a/src/Byteology.Website/Company/ScheduleMeeting.razor b/src/Byteology.Website/Company/ScheduleMeeting.razor new file mode 100644 index 0000000..7bafb66 --- /dev/null +++ b/src/Byteology.Website/Company/ScheduleMeeting.razor @@ -0,0 +1,10 @@ +@page "/schedule-meeting/{link}" + +@layout BasicLayout + + + + +
diff --git a/src/Byteology.Website/Company/ScheduleMeeting.razor.cs b/src/Byteology.Website/Company/ScheduleMeeting.razor.cs new file mode 100644 index 0000000..f56a32c --- /dev/null +++ b/src/Byteology.Website/Company/ScheduleMeeting.razor.cs @@ -0,0 +1,19 @@ +namespace Byteology.Website.Company; + +using Microsoft.JSInterop; + +public partial class ScheduleMeeting : ComponentBase +{ + [Inject] + private IJSRuntime _jsRuntimeAsync { get; set; } = default!; + private IJSInProcessRuntime _jsRuntime => (IJSInProcessRuntime)_jsRuntimeAsync; + + [Parameter] + public string Link { get; set; } = null!; + + protected override void OnAfterRender(bool firstRender) + { + string link = $"https://calendly.com/tsvetan-igov/{Link}?background_color=090326&text_color=ffffff&primary_color=573ce2"; + _jsRuntime.InvokeVoid("initCalendly", link); + } +} \ No newline at end of file diff --git a/src/Byteology.Website/wwwroot/index.html b/src/Byteology.Website/wwwroot/index.html index 8cbadbc..aa21293 100644 --- a/src/Byteology.Website/wwwroot/index.html +++ b/src/Byteology.Website/wwwroot/index.html @@ -18,6 +18,7 @@
+ diff --git a/src/Byteology.Website/wwwroot/js/calendly.js b/src/Byteology.Website/wwwroot/js/calendly.js new file mode 100644 index 0000000..6689c48 --- /dev/null +++ b/src/Byteology.Website/wwwroot/js/calendly.js @@ -0,0 +1,6 @@ +window.initCalendly = (link) => { + Calendly.initInlineWidget({ + url: "https://calendly.com/tsvetan-igov/" + link + "?background_color=090326&text_color=ffffff&primary_color=573ce2", + parentElement: document.getElementById('calendly-embed') + }); +} \ No newline at end of file