This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import { DOCUMENT } from "@angular/common"; | |
import { Inject, Injectable, Renderer2, RendererFactory2 } from "@angular/core"; | |
import { Observable, Subject } from "rxjs"; | |
declare var Tawk_API: any; | |
@Injectable() | |
export class TawkService { | |
private loaded: boolean; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public Task<PagedList<BoatDto>> Find(BoatCriteria criteria) | |
{ | |
return Adapter.Connect() | |
.CallAsync(async provider => | |
{ | |
var results = await _searchService.SearchBoatsAsync(criteria.Filter, | |
criteria.PageSize * criteria.PageNumber); | |
var unorderedResults = await provider.Boats() | |
.Where(b => results.Contains(b.Id)) | |
.Select(BoatMappings.Select()) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public class AzureSearchService : ISearchService | |
{ | |
private readonly SearchIndexClient _boatSearchClient; | |
public AzureSearchService() | |
{ | |
_boatSearchClient = new SearchIndexClient(ConfigurationsUtils.Configuration["SearchServiceName"], | |
ConfigurationsUtils.Configuration["SearchBoatsIndex"], | |
new SearchCredentials(ConfigurationsUtils.Configuration["SearchServiceQueryApiKey"])); | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public Task<PagedList<BoatDto>> Find(BoatCriteria criteria) | |
{ | |
return Adapter.Connect() | |
.CallAsync(async provider => | |
{ | |
var hasFilter = !string.IsNullOrWhiteSpace(criteria.Filter); | |
criteria.Filter = criteria.Filter?.ToLower(); | |
return await provider.Boats() | |
.Where(b => !hasFilter || b.Name.ToLower().Contains(criteria.Filter) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function playSoundAtPoint(video, currentSecond, secondToPlay, trackNumber, listen, pauseVideo) { | |
if (currentSecond >= secondToPlay) { | |
if (pauseVideo === true) { | |
video.pause(); | |
} | |
playTrack(trackNumber, listen); | |
return true; | |
} | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
if (annyang) { | |
// Let's define a command. | |
var commands = { | |
"(head for the) track": trackRecog, | |
"(into the) city": cityRecog, | |
"off road": offRoadRecog, | |
}; | |
// Add our commands to annyang | |
annyang.addCommands(commands); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function playTrack(trackNumber, listen) { | |
if (track) { | |
track.pause(); | |
} | |
if (typeof listen === 'undefined') { | |
listen = false; | |
} | |
var src = base + trackNumber + ".m4a"; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
_wq.push({ | |
id: introVideo, | |
onReady: function(video) { | |
} | |
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var currentVideo = ""; | |
var introVideo = "1wzvri8wjy"; | |
var video1a = "zgg2swo8hg"; | |
var video1b = "vnsh8ysowe"; | |
var video1c = "jrvtava20v"; | |
var video2a = "zu3hb0cgsg"; | |
var video2b = "ax6wlnb9jr"; | |
var video2c = "1wqp1t1yqv"; | |
window._wq = window._wq || []; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
//Link to the Wistia Player API files | |
<script charset="ISO-8859-1" src="//fast.wistia.com/assets/external/E-v1.js" async></script> | |
//Add where you'd like to place the player | |
<div class="wistia_embed wistia_async_[INSERT_VIDEO_ID_HERE]"> </div> |
NewerOlder