@meetelise/chat 1.22.69 → 1.22.71
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +1 -1
- package/public/demo/index.html +6 -4
- package/public/dist/index.js +68 -23
- package/src/WebComponent/LeadSourceClient.ts +3 -0
- package/src/WebComponent/Scheduler/date-picker.ts +8 -4
- package/src/WebComponent/Scheduler/time-picker.ts +2 -2
- package/src/WebComponent/Scheduler/tour-scheduler.ts +6 -1
- package/src/WebComponent/launcher/mobile-launcher.ts +7 -5
- package/src/WebComponent/me-chat.ts +1 -1
- package/src/WebComponent/me-select.ts +31 -5
- package/src/WebComponent/pubnub-chat.ts +17 -4
package/package.json
CHANGED
package/public/demo/index.html
CHANGED
|
@@ -151,6 +151,8 @@
|
|
|
151
151
|
></noscript>
|
|
152
152
|
<!-- End Google Tag Manager (noscript) -->
|
|
153
153
|
<!-- Webpack dev server will serve the bundle, index.js, at the path '/' -->
|
|
154
|
+
<!-- <script src="https://cdnjs.cloudflare.com/ajax/libs/axe-core/4.3.5/axe.min.js"></script> -->
|
|
155
|
+
|
|
154
156
|
<script type="module" async>
|
|
155
157
|
import MEChat from "/index.js";
|
|
156
158
|
// MEChat.healthcareStart({
|
|
@@ -171,6 +173,8 @@
|
|
|
171
173
|
};
|
|
172
174
|
|
|
173
175
|
MEChat.start({
|
|
176
|
+
organization: "lindy",
|
|
177
|
+
building: "c4cfc3ec-c4da-11ec-bda4-43aed00ca1b2",
|
|
174
178
|
// organization: "Pacific Urban Residential",
|
|
175
179
|
// building: "c06117dc-7a80-11ed-bc9a-c3e28c7281ff",
|
|
176
180
|
|
|
@@ -213,8 +217,8 @@
|
|
|
213
217
|
// organization: "cardinal-group",
|
|
214
218
|
// widgetType: "utilities",
|
|
215
219
|
|
|
216
|
-
organization: "test-company",
|
|
217
|
-
building: "e2e-test-yardi-building",
|
|
220
|
+
// organization: "test-company",
|
|
221
|
+
// building: "e2e-test-yardi-building",
|
|
218
222
|
// overrideRentgrata: true,
|
|
219
223
|
// onWidgetLoaded: onWidgetLoaded,
|
|
220
224
|
|
|
@@ -229,7 +233,6 @@
|
|
|
229
233
|
This is an example page for serving the chat widget locally. Source of
|
|
230
234
|
truth
|
|
231
235
|
</p>
|
|
232
|
-
|
|
233
236
|
<button id="reset" type="button">Restart conversation</button>
|
|
234
237
|
<button id="navigate" type="button">navigate</button>
|
|
235
238
|
<button id="unnavigate" type="button">unnavigate</button>
|
|
@@ -267,7 +270,6 @@
|
|
|
267
270
|
<a
|
|
268
271
|
href="javascript:void(0);"
|
|
269
272
|
onclick="window.eliseAi.onOpenSST(() => {
|
|
270
|
-
|
|
271
273
|
const meetEliseChats = document.getElementsByTagName('me-chat');
|
|
272
274
|
if (!meetEliseChats || meetEliseChats.length === 0) {
|
|
273
275
|
return;
|
package/public/dist/index.js
CHANGED
|
@@ -69,10 +69,12 @@ var e={8005:function(e,t,i){var n,r=this&&this.__extends||(n=function(e,t){retur
|
|
|
69
69
|
h2 {
|
|
70
70
|
font-weight: 400;
|
|
71
71
|
}
|
|
72
|
-
`],Ue([le({type:String})],Be.prototype,"heading",void 0),Ue([le({type:String})],Be.prototype,"subtitle",void 0),Ue([le({type:Boolean})],Be.prototype,"selected",void 0),Ue([le({attribute:!1})],Be.prototype,"onClick",void 0),Ue([le({attribute:!0})],Be.prototype,"primaryColor",void 0),Ue([le({attribute:!0})],Be.prototype,"backgroundColor",void 0),Ue([le({attribute:!0})],Be.prototype,"foregroundColorOnPrimaryBackgroundColor",void 0),Ue([le({attribute:!0})],Be.prototype,"foregroundColorOnSecondaryBackgroundColor",void 0),Be=Ue([ae("tour-type-option")],Be);var Ge={lessThanXSeconds:{one:"less than a second",other:"less than {{count}} seconds"},xSeconds:{one:"1 second",other:"{{count}} seconds"},halfAMinute:"half a minute",lessThanXMinutes:{one:"less than a minute",other:"less than {{count}} minutes"},xMinutes:{one:"1 minute",other:"{{count}} minutes"},aboutXHours:{one:"about 1 hour",other:"about {{count}} hours"},xHours:{one:"1 hour",other:"{{count}} hours"},xDays:{one:"1 day",other:"{{count}} days"},aboutXWeeks:{one:"about 1 week",other:"about {{count}} weeks"},xWeeks:{one:"1 week",other:"{{count}} weeks"},aboutXMonths:{one:"about 1 month",other:"about {{count}} months"},xMonths:{one:"1 month",other:"{{count}} months"},aboutXYears:{one:"about 1 year",other:"about {{count}} years"},xYears:{one:"1 year",other:"{{count}} years"},overXYears:{one:"over 1 year",other:"over {{count}} years"},almostXYears:{one:"almost 1 year",other:"almost {{count}} years"}};function ze(e){return function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},i=t.width?String(t.width):e.defaultWidth,n=e.formats[i]||e.formats[e.defaultWidth];return n}}const We={date:ze({formats:{full:"EEEE, MMMM do, y",long:"MMMM do, y",medium:"MMM d, y",short:"MM/dd/yyyy"},defaultWidth:"full"}),time:ze({formats:{full:"h:mm:ss a zzzz",long:"h:mm:ss a z",medium:"h:mm:ss a",short:"h:mm a"},defaultWidth:"full"}),dateTime:ze({formats:{full:"{{date}} 'at' {{time}}",long:"{{date}} 'at' {{time}}",medium:"{{date}}, {{time}}",short:"{{date}}, {{time}}"},defaultWidth:"full"})};var Ve={lastWeek:"'last' eeee 'at' p",yesterday:"'yesterday at' p",today:"'today at' p",tomorrow:"'tomorrow at' p",nextWeek:"eeee 'at' p",other:"P"};function Qe(e){return function(t,i){var n,r=i||{};if("formatting"===(r.context?String(r.context):"standalone")&&e.formattingValues){var o=e.defaultFormattingWidth||e.defaultWidth,a=r.width?String(r.width):o;n=e.formattingValues[a]||e.formattingValues[o]}else{var s=e.defaultWidth,l=r.width?String(r.width):e.defaultWidth;n=e.values[l]||e.values[s]}return n[e.argumentCallback?e.argumentCallback(t):t]}}const Ke={ordinalNumber:function(e,t){var i=Number(e),n=i%100;if(n>20||n<10)switch(n%10){case 1:return i+"st";case 2:return i+"nd";case 3:return i+"rd"}return i+"th"},era:Qe({values:{narrow:["B","A"],abbreviated:["BC","AD"],wide:["Before Christ","Anno Domini"]},defaultWidth:"wide"}),quarter:Qe({values:{narrow:["1","2","3","4"],abbreviated:["Q1","Q2","Q3","Q4"],wide:["1st quarter","2nd quarter","3rd quarter","4th quarter"]},defaultWidth:"wide",argumentCallback:function(e){return e-1}}),month:Qe({values:{narrow:["J","F","M","A","M","J","J","A","S","O","N","D"],abbreviated:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],wide:["January","February","March","April","May","June","July","August","September","October","November","December"]},defaultWidth:"wide"}),day:Qe({values:{narrow:["S","M","T","W","T","F","S"],short:["Su","Mo","Tu","We","Th","Fr","Sa"],abbreviated:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],wide:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"]},defaultWidth:"wide"}),dayPeriod:Qe({values:{narrow:{am:"a",pm:"p",midnight:"mi",noon:"n",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},abbreviated:{am:"AM",pm:"PM",midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},wide:{am:"a.m.",pm:"p.m.",midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"}},defaultWidth:"wide",formattingValues:{narrow:{am:"a",pm:"p",midnight:"mi",noon:"n",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"},abbreviated:{am:"AM",pm:"PM",midnight:"midnight",noon:"noon",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"},wide:{am:"a.m.",pm:"p.m.",midnight:"midnight",noon:"noon",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"}},defaultFormattingWidth:"wide"})};function Xe(e){return function(t){var i=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=i.width,r=n&&e.matchPatterns[n]||e.matchPatterns[e.defaultMatchWidth],o=t.match(r);if(!o)return null;var a,s=o[0],l=n&&e.parsePatterns[n]||e.parsePatterns[e.defaultParseWidth],u=Array.isArray(l)?$e(l,(function(e){return e.test(s)})):Ye(l,(function(e){return e.test(s)}));a=e.valueCallback?e.valueCallback(u):u,a=i.valueCallback?i.valueCallback(a):a;var d=t.slice(s.length);return{value:a,rest:d}}}function Ye(e,t){for(var i in e)if(e.hasOwnProperty(i)&&t(e[i]))return i}function $e(e,t){for(var i=0;i<e.length;i++)if(t(e[i]))return i}var Ze,et={ordinalNumber:(Ze={matchPattern:/^(\d+)(th|st|nd|rd)?/i,parsePattern:/\d+/i,valueCallback:function(e){return parseInt(e,10)}},function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},i=e.match(Ze.matchPattern);if(!i)return null;var n=i[0],r=e.match(Ze.parsePattern);if(!r)return null;var o=Ze.valueCallback?Ze.valueCallback(r[0]):r[0];o=t.valueCallback?t.valueCallback(o):o;var a=e.slice(n.length);return{value:o,rest:a}}),era:Xe({matchPatterns:{narrow:/^(b|a)/i,abbreviated:/^(b\.?\s?c\.?|b\.?\s?c\.?\s?e\.?|a\.?\s?d\.?|c\.?\s?e\.?)/i,wide:/^(before christ|before common era|anno domini|common era)/i},defaultMatchWidth:"wide",parsePatterns:{any:[/^b/i,/^(a|c)/i]},defaultParseWidth:"any"}),quarter:Xe({matchPatterns:{narrow:/^[1234]/i,abbreviated:/^q[1234]/i,wide:/^[1234](th|st|nd|rd)? quarter/i},defaultMatchWidth:"wide",parsePatterns:{any:[/1/i,/2/i,/3/i,/4/i]},defaultParseWidth:"any",valueCallback:function(e){return e+1}}),month:Xe({matchPatterns:{narrow:/^[jfmasond]/i,abbreviated:/^(jan|feb|mar|apr|may|jun|jul|aug|sep|oct|nov|dec)/i,wide:/^(january|february|march|april|may|june|july|august|september|october|november|december)/i},defaultMatchWidth:"wide",parsePatterns:{narrow:[/^j/i,/^f/i,/^m/i,/^a/i,/^m/i,/^j/i,/^j/i,/^a/i,/^s/i,/^o/i,/^n/i,/^d/i],any:[/^ja/i,/^f/i,/^mar/i,/^ap/i,/^may/i,/^jun/i,/^jul/i,/^au/i,/^s/i,/^o/i,/^n/i,/^d/i]},defaultParseWidth:"any"}),day:Xe({matchPatterns:{narrow:/^[smtwf]/i,short:/^(su|mo|tu|we|th|fr|sa)/i,abbreviated:/^(sun|mon|tue|wed|thu|fri|sat)/i,wide:/^(sunday|monday|tuesday|wednesday|thursday|friday|saturday)/i},defaultMatchWidth:"wide",parsePatterns:{narrow:[/^s/i,/^m/i,/^t/i,/^w/i,/^t/i,/^f/i,/^s/i],any:[/^su/i,/^m/i,/^tu/i,/^w/i,/^th/i,/^f/i,/^sa/i]},defaultParseWidth:"any"}),dayPeriod:Xe({matchPatterns:{narrow:/^(a|p|mi|n|(in the|at) (morning|afternoon|evening|night))/i,any:/^([ap]\.?\s?m\.?|midnight|noon|(in the|at) (morning|afternoon|evening|night))/i},defaultMatchWidth:"any",parsePatterns:{any:{am:/^a/i,pm:/^p/i,midnight:/^mi/i,noon:/^no/i,morning:/morning/i,afternoon:/afternoon/i,evening:/evening/i,night:/night/i}},defaultParseWidth:"any"})};const tt={code:"en-US",formatDistance:function(e,t,i){var n,r=Ge[e];return n="string"==typeof r?r:1===t?r.one:r.other.replace("{{count}}",t.toString()),null!=i&&i.addSuffix?i.comparison&&i.comparison>0?"in "+n:n+" ago":n},formatLong:We,formatRelative:function(e,t,i,n){return Ve[e]},localize:Ke,match:et,options:{weekStartsOn:0,firstWeekContainsDate:1}};function it(e){if(null===e||!0===e||!1===e)return NaN;var t=Number(e);return isNaN(t)?t:t<0?Math.ceil(t):Math.floor(t)}function nt(e,t){Le(2,arguments);var i=qe(e).getTime(),n=it(t);return new Date(i+n)}function rt(e,t){Le(2,arguments);var i=it(t);return nt(e,-i)}var ot=864e5;function at(e){Le(1,arguments);var t=1,i=qe(e),n=i.getUTCDay(),r=(n<t?7:0)+n-t;return i.setUTCDate(i.getUTCDate()-r),i.setUTCHours(0,0,0,0),i}function st(e){Le(1,arguments);var t=qe(e),i=t.getUTCFullYear(),n=new Date(0);n.setUTCFullYear(i+1,0,4),n.setUTCHours(0,0,0,0);var r=at(n),o=new Date(0);o.setUTCFullYear(i,0,4),o.setUTCHours(0,0,0,0);var a=at(o);return t.getTime()>=r.getTime()?i+1:t.getTime()>=a.getTime()?i:i-1}function lt(e){Le(1,arguments);var t=st(e),i=new Date(0);i.setUTCFullYear(t,0,4),i.setUTCHours(0,0,0,0);var n=at(i);return n}var ut=6048e5;function dt(e,t){Le(1,arguments);var i=t||{},n=i.locale,r=n&&n.options&&n.options.weekStartsOn,o=null==r?0:it(r),a=null==i.weekStartsOn?o:it(i.weekStartsOn);if(!(a>=0&&a<=6))throw new RangeError("weekStartsOn must be between 0 and 6 inclusively");var s=qe(e),l=s.getUTCDay(),u=(l<a?7:0)+l-a;return s.setUTCDate(s.getUTCDate()-u),s.setUTCHours(0,0,0,0),s}function ct(e,t){Le(1,arguments);var i=qe(e),n=i.getUTCFullYear(),r=t||{},o=r.locale,a=o&&o.options&&o.options.firstWeekContainsDate,s=null==a?1:it(a),l=null==r.firstWeekContainsDate?s:it(r.firstWeekContainsDate);if(!(l>=1&&l<=7))throw new RangeError("firstWeekContainsDate must be between 1 and 7 inclusively");var u=new Date(0);u.setUTCFullYear(n+1,0,l),u.setUTCHours(0,0,0,0);var d=dt(u,t),c=new Date(0);c.setUTCFullYear(n,0,l),c.setUTCHours(0,0,0,0);var p=dt(c,t);return i.getTime()>=d.getTime()?n+1:i.getTime()>=p.getTime()?n:n-1}function pt(e,t){Le(1,arguments);var i=t||{},n=i.locale,r=n&&n.options&&n.options.firstWeekContainsDate,o=null==r?1:it(r),a=null==i.firstWeekContainsDate?o:it(i.firstWeekContainsDate),s=ct(e,t),l=new Date(0);l.setUTCFullYear(s,0,a),l.setUTCHours(0,0,0,0);var u=dt(l,t);return u}var ht=6048e5;function ft(e,t){for(var i=e<0?"-":"",n=Math.abs(e).toString();n.length<t;)n="0"+n;return i+n}const mt=function(e,t){var i=e.getUTCFullYear(),n=i>0?i:1-i;return ft("yy"===t?n%100:n,t.length)},gt=function(e,t){var i=e.getUTCMonth();return"M"===t?String(i+1):ft(i+1,2)},vt=function(e,t){return ft(e.getUTCDate(),t.length)},yt=function(e,t){return ft(e.getUTCHours()%12||12,t.length)},bt=function(e,t){return ft(e.getUTCHours(),t.length)},wt=function(e,t){return ft(e.getUTCMinutes(),t.length)},St=function(e,t){return ft(e.getUTCSeconds(),t.length)},Tt=function(e,t){var i=t.length,n=e.getUTCMilliseconds();return ft(Math.floor(n*Math.pow(10,i-3)),t.length)};var xt={G:function(e,t,i){var n=e.getUTCFullYear()>0?1:0;switch(t){case"G":case"GG":case"GGG":return i.era(n,{width:"abbreviated"});case"GGGGG":return i.era(n,{width:"narrow"});default:return i.era(n,{width:"wide"})}},y:function(e,t,i){if("yo"===t){var n=e.getUTCFullYear(),r=n>0?n:1-n;return i.ordinalNumber(r,{unit:"year"})}return mt(e,t)},Y:function(e,t,i,n){var r=ct(e,n),o=r>0?r:1-r;return"YY"===t?ft(o%100,2):"Yo"===t?i.ordinalNumber(o,{unit:"year"}):ft(o,t.length)},R:function(e,t){return ft(st(e),t.length)},u:function(e,t){return ft(e.getUTCFullYear(),t.length)},Q:function(e,t,i){var n=Math.ceil((e.getUTCMonth()+1)/3);switch(t){case"Q":return String(n);case"QQ":return ft(n,2);case"Qo":return i.ordinalNumber(n,{unit:"quarter"});case"QQQ":return i.quarter(n,{width:"abbreviated",context:"formatting"});case"QQQQQ":return i.quarter(n,{width:"narrow",context:"formatting"});default:return i.quarter(n,{width:"wide",context:"formatting"})}},q:function(e,t,i){var n=Math.ceil((e.getUTCMonth()+1)/3);switch(t){case"q":return String(n);case"qq":return ft(n,2);case"qo":return i.ordinalNumber(n,{unit:"quarter"});case"qqq":return i.quarter(n,{width:"abbreviated",context:"standalone"});case"qqqqq":return i.quarter(n,{width:"narrow",context:"standalone"});default:return i.quarter(n,{width:"wide",context:"standalone"})}},M:function(e,t,i){var n=e.getUTCMonth();switch(t){case"M":case"MM":return gt(e,t);case"Mo":return i.ordinalNumber(n+1,{unit:"month"});case"MMM":return i.month(n,{width:"abbreviated",context:"formatting"});case"MMMMM":return i.month(n,{width:"narrow",context:"formatting"});default:return i.month(n,{width:"wide",context:"formatting"})}},L:function(e,t,i){var n=e.getUTCMonth();switch(t){case"L":return String(n+1);case"LL":return ft(n+1,2);case"Lo":return i.ordinalNumber(n+1,{unit:"month"});case"LLL":return i.month(n,{width:"abbreviated",context:"standalone"});case"LLLLL":return i.month(n,{width:"narrow",context:"standalone"});default:return i.month(n,{width:"wide",context:"standalone"})}},w:function(e,t,i,n){var r=function(e,t){Le(1,arguments);var i=qe(e),n=dt(i,t).getTime()-pt(i,t).getTime();return Math.round(n/ht)+1}(e,n);return"wo"===t?i.ordinalNumber(r,{unit:"week"}):ft(r,t.length)},I:function(e,t,i){var n=function(e){Le(1,arguments);var t=qe(e),i=at(t).getTime()-lt(t).getTime();return Math.round(i/ut)+1}(e);return"Io"===t?i.ordinalNumber(n,{unit:"week"}):ft(n,t.length)},d:function(e,t,i){return"do"===t?i.ordinalNumber(e.getUTCDate(),{unit:"date"}):vt(e,t)},D:function(e,t,i){var n=function(e){Le(1,arguments);var t=qe(e),i=t.getTime();t.setUTCMonth(0,1),t.setUTCHours(0,0,0,0);var n=t.getTime(),r=i-n;return Math.floor(r/ot)+1}(e);return"Do"===t?i.ordinalNumber(n,{unit:"dayOfYear"}):ft(n,t.length)},E:function(e,t,i){var n=e.getUTCDay();switch(t){case"E":case"EE":case"EEE":return i.day(n,{width:"abbreviated",context:"formatting"});case"EEEEE":return i.day(n,{width:"narrow",context:"formatting"});case"EEEEEE":return i.day(n,{width:"short",context:"formatting"});default:return i.day(n,{width:"wide",context:"formatting"})}},e:function(e,t,i,n){var r=e.getUTCDay(),o=(r-n.weekStartsOn+8)%7||7;switch(t){case"e":return String(o);case"ee":return ft(o,2);case"eo":return i.ordinalNumber(o,{unit:"day"});case"eee":return i.day(r,{width:"abbreviated",context:"formatting"});case"eeeee":return i.day(r,{width:"narrow",context:"formatting"});case"eeeeee":return i.day(r,{width:"short",context:"formatting"});default:return i.day(r,{width:"wide",context:"formatting"})}},c:function(e,t,i,n){var r=e.getUTCDay(),o=(r-n.weekStartsOn+8)%7||7;switch(t){case"c":return String(o);case"cc":return ft(o,t.length);case"co":return i.ordinalNumber(o,{unit:"day"});case"ccc":return i.day(r,{width:"abbreviated",context:"standalone"});case"ccccc":return i.day(r,{width:"narrow",context:"standalone"});case"cccccc":return i.day(r,{width:"short",context:"standalone"});default:return i.day(r,{width:"wide",context:"standalone"})}},i:function(e,t,i){var n=e.getUTCDay(),r=0===n?7:n;switch(t){case"i":return String(r);case"ii":return ft(r,t.length);case"io":return i.ordinalNumber(r,{unit:"day"});case"iii":return i.day(n,{width:"abbreviated",context:"formatting"});case"iiiii":return i.day(n,{width:"narrow",context:"formatting"});case"iiiiii":return i.day(n,{width:"short",context:"formatting"});default:return i.day(n,{width:"wide",context:"formatting"})}},a:function(e,t,i){var n=e.getUTCHours()/12>=1?"pm":"am";switch(t){case"a":case"aa":return i.dayPeriod(n,{width:"abbreviated",context:"formatting"});case"aaa":return i.dayPeriod(n,{width:"abbreviated",context:"formatting"}).toLowerCase();case"aaaaa":return i.dayPeriod(n,{width:"narrow",context:"formatting"});default:return i.dayPeriod(n,{width:"wide",context:"formatting"})}},b:function(e,t,i){var n,r=e.getUTCHours();switch(n=12===r?"noon":0===r?"midnight":r/12>=1?"pm":"am",t){case"b":case"bb":return i.dayPeriod(n,{width:"abbreviated",context:"formatting"});case"bbb":return i.dayPeriod(n,{width:"abbreviated",context:"formatting"}).toLowerCase();case"bbbbb":return i.dayPeriod(n,{width:"narrow",context:"formatting"});default:return i.dayPeriod(n,{width:"wide",context:"formatting"})}},B:function(e,t,i){var n,r=e.getUTCHours();switch(n=r>=17?"evening":r>=12?"afternoon":r>=4?"morning":"night",t){case"B":case"BB":case"BBB":return i.dayPeriod(n,{width:"abbreviated",context:"formatting"});case"BBBBB":return i.dayPeriod(n,{width:"narrow",context:"formatting"});default:return i.dayPeriod(n,{width:"wide",context:"formatting"})}},h:function(e,t,i){if("ho"===t){var n=e.getUTCHours()%12;return 0===n&&(n=12),i.ordinalNumber(n,{unit:"hour"})}return yt(e,t)},H:function(e,t,i){return"Ho"===t?i.ordinalNumber(e.getUTCHours(),{unit:"hour"}):bt(e,t)},K:function(e,t,i){var n=e.getUTCHours()%12;return"Ko"===t?i.ordinalNumber(n,{unit:"hour"}):ft(n,t.length)},k:function(e,t,i){var n=e.getUTCHours();return 0===n&&(n=24),"ko"===t?i.ordinalNumber(n,{unit:"hour"}):ft(n,t.length)},m:function(e,t,i){return"mo"===t?i.ordinalNumber(e.getUTCMinutes(),{unit:"minute"}):wt(e,t)},s:function(e,t,i){return"so"===t?i.ordinalNumber(e.getUTCSeconds(),{unit:"second"}):St(e,t)},S:function(e,t){return Tt(e,t)},X:function(e,t,i,n){var r=(n._originalDate||e).getTimezoneOffset();if(0===r)return"Z";switch(t){case"X":return Ct(r);case"XXXX":case"XX":return Ot(r);default:return Ot(r,":")}},x:function(e,t,i,n){var r=(n._originalDate||e).getTimezoneOffset();switch(t){case"x":return Ct(r);case"xxxx":case"xx":return Ot(r);default:return Ot(r,":")}},O:function(e,t,i,n){var r=(n._originalDate||e).getTimezoneOffset();switch(t){case"O":case"OO":case"OOO":return"GMT"+At(r,":");default:return"GMT"+Ot(r,":")}},z:function(e,t,i,n){var r=(n._originalDate||e).getTimezoneOffset();switch(t){case"z":case"zz":case"zzz":return"GMT"+At(r,":");default:return"GMT"+Ot(r,":")}},t:function(e,t,i,n){var r=n._originalDate||e;return ft(Math.floor(r.getTime()/1e3),t.length)},T:function(e,t,i,n){return ft((n._originalDate||e).getTime(),t.length)}};function At(e,t){var i=e>0?"-":"+",n=Math.abs(e),r=Math.floor(n/60),o=n%60;if(0===o)return i+String(r);var a=t||"";return i+String(r)+a+ft(o,2)}function Ct(e,t){return e%60==0?(e>0?"-":"+")+ft(Math.abs(e)/60,2):Ot(e,t)}function Ot(e,t){var i=t||"",n=e>0?"-":"+",r=Math.abs(e);return n+ft(Math.floor(r/60),2)+i+ft(r%60,2)}const It=xt;function Nt(e,t){switch(e){case"P":return t.date({width:"short"});case"PP":return t.date({width:"medium"});case"PPP":return t.date({width:"long"});default:return t.date({width:"full"})}}function Et(e,t){switch(e){case"p":return t.time({width:"short"});case"pp":return t.time({width:"medium"});case"ppp":return t.time({width:"long"});default:return t.time({width:"full"})}}const Rt={p:Et,P:function(e,t){var i,n=e.match(/(P+)(p+)?/)||[],r=n[1],o=n[2];if(!o)return Nt(e,t);switch(r){case"P":i=t.dateTime({width:"short"});break;case"PP":i=t.dateTime({width:"medium"});break;case"PPP":i=t.dateTime({width:"long"});break;default:i=t.dateTime({width:"full"})}return i.replace("{{date}}",Nt(r,t)).replace("{{time}}",Et(o,t))}};function _t(e){var t=new Date(Date.UTC(e.getFullYear(),e.getMonth(),e.getDate(),e.getHours(),e.getMinutes(),e.getSeconds(),e.getMilliseconds()));return t.setUTCFullYear(e.getFullYear()),e.getTime()-t.getTime()}var Pt=["D","DD"],Mt=["YY","YYYY"];function Ft(e){return-1!==Pt.indexOf(e)}function Dt(e){return-1!==Mt.indexOf(e)}function kt(e,t,i){if("YYYY"===e)throw new RangeError("Use `yyyy` instead of `YYYY` (in `".concat(t,"`) for formatting years to the input `").concat(i,"`; see: https://git.io/fxCyr"));if("YY"===e)throw new RangeError("Use `yy` instead of `YY` (in `".concat(t,"`) for formatting years to the input `").concat(i,"`; see: https://git.io/fxCyr"));if("D"===e)throw new RangeError("Use `d` instead of `D` (in `".concat(t,"`) for formatting days of the month to the input `").concat(i,"`; see: https://git.io/fxCyr"));if("DD"===e)throw new RangeError("Use `dd` instead of `DD` (in `".concat(t,"`) for formatting days of the month to the input `").concat(i,"`; see: https://git.io/fxCyr"))}var Ut=/[yYQqMLwIdDecihHKkms]o|(\w)\1*|''|'(''|[^'])+('|$)|./g,Bt=/P+p+|P+|p+|''|'(''|[^'])+('|$)|./g,Lt=/^'([^]*?)'?$/,qt=/''/g,Jt=/[a-zA-Z]/;function jt(e,t,i){Le(2,arguments);var n=String(t),r=i||{},o=r.locale||tt,a=o.options&&o.options.firstWeekContainsDate,s=null==a?1:it(a),l=null==r.firstWeekContainsDate?s:it(r.firstWeekContainsDate);if(!(l>=1&&l<=7))throw new RangeError("firstWeekContainsDate must be between 1 and 7 inclusively");var u=o.options&&o.options.weekStartsOn,d=null==u?0:it(u),c=null==r.weekStartsOn?d:it(r.weekStartsOn);if(!(c>=0&&c<=6))throw new RangeError("weekStartsOn must be between 0 and 6 inclusively");if(!o.localize)throw new RangeError("locale must contain localize property");if(!o.formatLong)throw new RangeError("locale must contain formatLong property");var p=qe(e);if(!He(p))throw new RangeError("Invalid time value");var h=_t(p),f=rt(p,h),m={firstWeekContainsDate:l,weekStartsOn:c,locale:o,_originalDate:p},g=n.match(Bt).map((function(e){var t=e[0];return"p"===t||"P"===t?(0,Rt[t])(e,o.formatLong,m):e})).join("").match(Ut).map((function(i){if("''"===i)return"'";var n=i[0];if("'"===n)return Ht(i);var a=It[n];if(a)return!r.useAdditionalWeekYearTokens&&Dt(i)&&kt(i,t,e),!r.useAdditionalDayOfYearTokens&&Ft(i)&&kt(i,t,e),a(f,i,o.localize,m);if(n.match(Jt))throw new RangeError("Format string contains an unescaped latin alphabet character `"+n+"`");return i})).join("");return g}function Ht(e){return e.match(Lt)[1].replace(qt,"'")}const Gt=(e,t)=>new Date(e,t+1,0).getDate(),zt=(e,t)=>new Date(e,t,1).getDay(),Wt=["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],Vt=["January","February","March","April","May","June","July","August","September","October","November","December"];var Qt=function(e,t,i,n){var r,o=arguments.length,a=o<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,i,n);else for(var s=e.length-1;s>=0;s--)(r=e[s])&&(a=(o<3?r(a):o>3?r(t,i,a):r(t,i))||a);return o>3&&a&&Object.defineProperty(t,i,a),a};let Kt=class extends re{constructor(){var e;super(...arguments),this._selectedDate=void 0,this.now=new Date,this._monthShown=this.defaultMonth&&-1!==Vt.indexOf(this.defaultMonth)?Vt.indexOf(this.defaultMonth):this.now.getMonth(),this.yearShown=null!==(e=this.defaultYear)&&void 0!==e?e:this.now.getFullYear()}set selectedDate(e){const t=this._selectedDate;this._selectedDate=e,this.requestUpdate("selectedDate",t),this.dispatchEvent(new Event("change",{composed:!0,bubbles:!0}))}get selectedDate(){return this._selectedDate}set monthShown(e){const t=this._monthShown;12===e?(this._monthShown=0,this.yearShown++):-1===e?(this._monthShown=11,this.yearShown--):this._monthShown=e,this.requestUpdate("monthShown",t)}get monthShown(){return this._monthShown}render(){const e=Gt(this.yearShown,this.monthShown),t=Wt[zt(this.yearShown,this.monthShown)],i=(n=this.yearShown,r=this.monthShown,Gt(r>0?n:n-1,(e=>e>0?e-1:11)(r)));var n,r;const o=Wt[((e,t)=>(zt(e,t)+Gt(e,t)%7-1)%7)(this.yearShown,this.monthShown)],a=[];if("Sunday"!==t)for(let e=Wt.indexOf(t);e>0;e--)a.push(i+1-e);const s=new Array(e).fill(null).map(((e,t)=>t+1)),l=[];if("Saturday"!==o){const e=[...Wt].reverse().indexOf(o);for(let t=1;t<=e;t++)l.push(t)}const u=[...a,...s,...l].map(((e,t)=>{var i,n,r;const o=this.yearShown<this.now.getFullYear()||this.yearShown===this.now.getFullYear()&&this.monthShown<this.now.getMonth()||this.yearShown===this.now.getFullYear()&&this.monthShown===this.now.getMonth()&&e<this.now.getDate(),l=t<a.length||t>=a.length+s.length,u=!l&&this.now.getMonth()===this.monthShown&&this.now.getDate()===e,d=!!this.selectedDate&&!l&&this.monthShown===function(e){return Le(1,arguments),qe(e).getMonth()}(this.selectedDate)&&this.yearShown===function(e){return Le(1,arguments),qe(e).getFullYear()}(this.selectedDate)&&e===function(e){return Le(1,arguments),qe(e).getDate()}(this.selectedDate),c=jt(new Date(this.yearShown,this.monthShown,e),"y-MM-dd"),p=!(null===(i=this.availabilities)||void 0===i?void 0:i[c])||0===(null===(r=null===(n=this.availabilities)||void 0===n?void 0:n[c])||void 0===r?void 0:r.length);return U`<span
|
|
72
|
+
`],Ue([le({type:String})],Be.prototype,"heading",void 0),Ue([le({type:String})],Be.prototype,"subtitle",void 0),Ue([le({type:Boolean})],Be.prototype,"selected",void 0),Ue([le({attribute:!1})],Be.prototype,"onClick",void 0),Ue([le({attribute:!0})],Be.prototype,"primaryColor",void 0),Ue([le({attribute:!0})],Be.prototype,"backgroundColor",void 0),Ue([le({attribute:!0})],Be.prototype,"foregroundColorOnPrimaryBackgroundColor",void 0),Ue([le({attribute:!0})],Be.prototype,"foregroundColorOnSecondaryBackgroundColor",void 0),Be=Ue([ae("tour-type-option")],Be);var Ge={lessThanXSeconds:{one:"less than a second",other:"less than {{count}} seconds"},xSeconds:{one:"1 second",other:"{{count}} seconds"},halfAMinute:"half a minute",lessThanXMinutes:{one:"less than a minute",other:"less than {{count}} minutes"},xMinutes:{one:"1 minute",other:"{{count}} minutes"},aboutXHours:{one:"about 1 hour",other:"about {{count}} hours"},xHours:{one:"1 hour",other:"{{count}} hours"},xDays:{one:"1 day",other:"{{count}} days"},aboutXWeeks:{one:"about 1 week",other:"about {{count}} weeks"},xWeeks:{one:"1 week",other:"{{count}} weeks"},aboutXMonths:{one:"about 1 month",other:"about {{count}} months"},xMonths:{one:"1 month",other:"{{count}} months"},aboutXYears:{one:"about 1 year",other:"about {{count}} years"},xYears:{one:"1 year",other:"{{count}} years"},overXYears:{one:"over 1 year",other:"over {{count}} years"},almostXYears:{one:"almost 1 year",other:"almost {{count}} years"}};function ze(e){return function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},i=t.width?String(t.width):e.defaultWidth,n=e.formats[i]||e.formats[e.defaultWidth];return n}}const We={date:ze({formats:{full:"EEEE, MMMM do, y",long:"MMMM do, y",medium:"MMM d, y",short:"MM/dd/yyyy"},defaultWidth:"full"}),time:ze({formats:{full:"h:mm:ss a zzzz",long:"h:mm:ss a z",medium:"h:mm:ss a",short:"h:mm a"},defaultWidth:"full"}),dateTime:ze({formats:{full:"{{date}} 'at' {{time}}",long:"{{date}} 'at' {{time}}",medium:"{{date}}, {{time}}",short:"{{date}}, {{time}}"},defaultWidth:"full"})};var Ve={lastWeek:"'last' eeee 'at' p",yesterday:"'yesterday at' p",today:"'today at' p",tomorrow:"'tomorrow at' p",nextWeek:"eeee 'at' p",other:"P"};function Qe(e){return function(t,i){var n,r=i||{};if("formatting"===(r.context?String(r.context):"standalone")&&e.formattingValues){var o=e.defaultFormattingWidth||e.defaultWidth,a=r.width?String(r.width):o;n=e.formattingValues[a]||e.formattingValues[o]}else{var s=e.defaultWidth,l=r.width?String(r.width):e.defaultWidth;n=e.values[l]||e.values[s]}return n[e.argumentCallback?e.argumentCallback(t):t]}}const Ke={ordinalNumber:function(e,t){var i=Number(e),n=i%100;if(n>20||n<10)switch(n%10){case 1:return i+"st";case 2:return i+"nd";case 3:return i+"rd"}return i+"th"},era:Qe({values:{narrow:["B","A"],abbreviated:["BC","AD"],wide:["Before Christ","Anno Domini"]},defaultWidth:"wide"}),quarter:Qe({values:{narrow:["1","2","3","4"],abbreviated:["Q1","Q2","Q3","Q4"],wide:["1st quarter","2nd quarter","3rd quarter","4th quarter"]},defaultWidth:"wide",argumentCallback:function(e){return e-1}}),month:Qe({values:{narrow:["J","F","M","A","M","J","J","A","S","O","N","D"],abbreviated:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],wide:["January","February","March","April","May","June","July","August","September","October","November","December"]},defaultWidth:"wide"}),day:Qe({values:{narrow:["S","M","T","W","T","F","S"],short:["Su","Mo","Tu","We","Th","Fr","Sa"],abbreviated:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],wide:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"]},defaultWidth:"wide"}),dayPeriod:Qe({values:{narrow:{am:"a",pm:"p",midnight:"mi",noon:"n",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},abbreviated:{am:"AM",pm:"PM",midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},wide:{am:"a.m.",pm:"p.m.",midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"}},defaultWidth:"wide",formattingValues:{narrow:{am:"a",pm:"p",midnight:"mi",noon:"n",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"},abbreviated:{am:"AM",pm:"PM",midnight:"midnight",noon:"noon",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"},wide:{am:"a.m.",pm:"p.m.",midnight:"midnight",noon:"noon",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"}},defaultFormattingWidth:"wide"})};function Xe(e){return function(t){var i=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=i.width,r=n&&e.matchPatterns[n]||e.matchPatterns[e.defaultMatchWidth],o=t.match(r);if(!o)return null;var a,s=o[0],l=n&&e.parsePatterns[n]||e.parsePatterns[e.defaultParseWidth],u=Array.isArray(l)?$e(l,(function(e){return e.test(s)})):Ye(l,(function(e){return e.test(s)}));a=e.valueCallback?e.valueCallback(u):u,a=i.valueCallback?i.valueCallback(a):a;var d=t.slice(s.length);return{value:a,rest:d}}}function Ye(e,t){for(var i in e)if(e.hasOwnProperty(i)&&t(e[i]))return i}function $e(e,t){for(var i=0;i<e.length;i++)if(t(e[i]))return i}var Ze,et={ordinalNumber:(Ze={matchPattern:/^(\d+)(th|st|nd|rd)?/i,parsePattern:/\d+/i,valueCallback:function(e){return parseInt(e,10)}},function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},i=e.match(Ze.matchPattern);if(!i)return null;var n=i[0],r=e.match(Ze.parsePattern);if(!r)return null;var o=Ze.valueCallback?Ze.valueCallback(r[0]):r[0];o=t.valueCallback?t.valueCallback(o):o;var a=e.slice(n.length);return{value:o,rest:a}}),era:Xe({matchPatterns:{narrow:/^(b|a)/i,abbreviated:/^(b\.?\s?c\.?|b\.?\s?c\.?\s?e\.?|a\.?\s?d\.?|c\.?\s?e\.?)/i,wide:/^(before christ|before common era|anno domini|common era)/i},defaultMatchWidth:"wide",parsePatterns:{any:[/^b/i,/^(a|c)/i]},defaultParseWidth:"any"}),quarter:Xe({matchPatterns:{narrow:/^[1234]/i,abbreviated:/^q[1234]/i,wide:/^[1234](th|st|nd|rd)? quarter/i},defaultMatchWidth:"wide",parsePatterns:{any:[/1/i,/2/i,/3/i,/4/i]},defaultParseWidth:"any",valueCallback:function(e){return e+1}}),month:Xe({matchPatterns:{narrow:/^[jfmasond]/i,abbreviated:/^(jan|feb|mar|apr|may|jun|jul|aug|sep|oct|nov|dec)/i,wide:/^(january|february|march|april|may|june|july|august|september|october|november|december)/i},defaultMatchWidth:"wide",parsePatterns:{narrow:[/^j/i,/^f/i,/^m/i,/^a/i,/^m/i,/^j/i,/^j/i,/^a/i,/^s/i,/^o/i,/^n/i,/^d/i],any:[/^ja/i,/^f/i,/^mar/i,/^ap/i,/^may/i,/^jun/i,/^jul/i,/^au/i,/^s/i,/^o/i,/^n/i,/^d/i]},defaultParseWidth:"any"}),day:Xe({matchPatterns:{narrow:/^[smtwf]/i,short:/^(su|mo|tu|we|th|fr|sa)/i,abbreviated:/^(sun|mon|tue|wed|thu|fri|sat)/i,wide:/^(sunday|monday|tuesday|wednesday|thursday|friday|saturday)/i},defaultMatchWidth:"wide",parsePatterns:{narrow:[/^s/i,/^m/i,/^t/i,/^w/i,/^t/i,/^f/i,/^s/i],any:[/^su/i,/^m/i,/^tu/i,/^w/i,/^th/i,/^f/i,/^sa/i]},defaultParseWidth:"any"}),dayPeriod:Xe({matchPatterns:{narrow:/^(a|p|mi|n|(in the|at) (morning|afternoon|evening|night))/i,any:/^([ap]\.?\s?m\.?|midnight|noon|(in the|at) (morning|afternoon|evening|night))/i},defaultMatchWidth:"any",parsePatterns:{any:{am:/^a/i,pm:/^p/i,midnight:/^mi/i,noon:/^no/i,morning:/morning/i,afternoon:/afternoon/i,evening:/evening/i,night:/night/i}},defaultParseWidth:"any"})};const tt={code:"en-US",formatDistance:function(e,t,i){var n,r=Ge[e];return n="string"==typeof r?r:1===t?r.one:r.other.replace("{{count}}",t.toString()),null!=i&&i.addSuffix?i.comparison&&i.comparison>0?"in "+n:n+" ago":n},formatLong:We,formatRelative:function(e,t,i,n){return Ve[e]},localize:Ke,match:et,options:{weekStartsOn:0,firstWeekContainsDate:1}};function it(e){if(null===e||!0===e||!1===e)return NaN;var t=Number(e);return isNaN(t)?t:t<0?Math.ceil(t):Math.floor(t)}function nt(e,t){Le(2,arguments);var i=qe(e).getTime(),n=it(t);return new Date(i+n)}function rt(e,t){Le(2,arguments);var i=it(t);return nt(e,-i)}var ot=864e5;function at(e){Le(1,arguments);var t=1,i=qe(e),n=i.getUTCDay(),r=(n<t?7:0)+n-t;return i.setUTCDate(i.getUTCDate()-r),i.setUTCHours(0,0,0,0),i}function st(e){Le(1,arguments);var t=qe(e),i=t.getUTCFullYear(),n=new Date(0);n.setUTCFullYear(i+1,0,4),n.setUTCHours(0,0,0,0);var r=at(n),o=new Date(0);o.setUTCFullYear(i,0,4),o.setUTCHours(0,0,0,0);var a=at(o);return t.getTime()>=r.getTime()?i+1:t.getTime()>=a.getTime()?i:i-1}function lt(e){Le(1,arguments);var t=st(e),i=new Date(0);i.setUTCFullYear(t,0,4),i.setUTCHours(0,0,0,0);var n=at(i);return n}var ut=6048e5;function dt(e,t){Le(1,arguments);var i=t||{},n=i.locale,r=n&&n.options&&n.options.weekStartsOn,o=null==r?0:it(r),a=null==i.weekStartsOn?o:it(i.weekStartsOn);if(!(a>=0&&a<=6))throw new RangeError("weekStartsOn must be between 0 and 6 inclusively");var s=qe(e),l=s.getUTCDay(),u=(l<a?7:0)+l-a;return s.setUTCDate(s.getUTCDate()-u),s.setUTCHours(0,0,0,0),s}function ct(e,t){Le(1,arguments);var i=qe(e),n=i.getUTCFullYear(),r=t||{},o=r.locale,a=o&&o.options&&o.options.firstWeekContainsDate,s=null==a?1:it(a),l=null==r.firstWeekContainsDate?s:it(r.firstWeekContainsDate);if(!(l>=1&&l<=7))throw new RangeError("firstWeekContainsDate must be between 1 and 7 inclusively");var u=new Date(0);u.setUTCFullYear(n+1,0,l),u.setUTCHours(0,0,0,0);var d=dt(u,t),c=new Date(0);c.setUTCFullYear(n,0,l),c.setUTCHours(0,0,0,0);var p=dt(c,t);return i.getTime()>=d.getTime()?n+1:i.getTime()>=p.getTime()?n:n-1}function pt(e,t){Le(1,arguments);var i=t||{},n=i.locale,r=n&&n.options&&n.options.firstWeekContainsDate,o=null==r?1:it(r),a=null==i.firstWeekContainsDate?o:it(i.firstWeekContainsDate),s=ct(e,t),l=new Date(0);l.setUTCFullYear(s,0,a),l.setUTCHours(0,0,0,0);var u=dt(l,t);return u}var ht=6048e5;function ft(e,t){for(var i=e<0?"-":"",n=Math.abs(e).toString();n.length<t;)n="0"+n;return i+n}const mt=function(e,t){var i=e.getUTCFullYear(),n=i>0?i:1-i;return ft("yy"===t?n%100:n,t.length)},gt=function(e,t){var i=e.getUTCMonth();return"M"===t?String(i+1):ft(i+1,2)},vt=function(e,t){return ft(e.getUTCDate(),t.length)},yt=function(e,t){return ft(e.getUTCHours()%12||12,t.length)},bt=function(e,t){return ft(e.getUTCHours(),t.length)},wt=function(e,t){return ft(e.getUTCMinutes(),t.length)},St=function(e,t){return ft(e.getUTCSeconds(),t.length)},Tt=function(e,t){var i=t.length,n=e.getUTCMilliseconds();return ft(Math.floor(n*Math.pow(10,i-3)),t.length)};var xt={G:function(e,t,i){var n=e.getUTCFullYear()>0?1:0;switch(t){case"G":case"GG":case"GGG":return i.era(n,{width:"abbreviated"});case"GGGGG":return i.era(n,{width:"narrow"});default:return i.era(n,{width:"wide"})}},y:function(e,t,i){if("yo"===t){var n=e.getUTCFullYear(),r=n>0?n:1-n;return i.ordinalNumber(r,{unit:"year"})}return mt(e,t)},Y:function(e,t,i,n){var r=ct(e,n),o=r>0?r:1-r;return"YY"===t?ft(o%100,2):"Yo"===t?i.ordinalNumber(o,{unit:"year"}):ft(o,t.length)},R:function(e,t){return ft(st(e),t.length)},u:function(e,t){return ft(e.getUTCFullYear(),t.length)},Q:function(e,t,i){var n=Math.ceil((e.getUTCMonth()+1)/3);switch(t){case"Q":return String(n);case"QQ":return ft(n,2);case"Qo":return i.ordinalNumber(n,{unit:"quarter"});case"QQQ":return i.quarter(n,{width:"abbreviated",context:"formatting"});case"QQQQQ":return i.quarter(n,{width:"narrow",context:"formatting"});default:return i.quarter(n,{width:"wide",context:"formatting"})}},q:function(e,t,i){var n=Math.ceil((e.getUTCMonth()+1)/3);switch(t){case"q":return String(n);case"qq":return ft(n,2);case"qo":return i.ordinalNumber(n,{unit:"quarter"});case"qqq":return i.quarter(n,{width:"abbreviated",context:"standalone"});case"qqqqq":return i.quarter(n,{width:"narrow",context:"standalone"});default:return i.quarter(n,{width:"wide",context:"standalone"})}},M:function(e,t,i){var n=e.getUTCMonth();switch(t){case"M":case"MM":return gt(e,t);case"Mo":return i.ordinalNumber(n+1,{unit:"month"});case"MMM":return i.month(n,{width:"abbreviated",context:"formatting"});case"MMMMM":return i.month(n,{width:"narrow",context:"formatting"});default:return i.month(n,{width:"wide",context:"formatting"})}},L:function(e,t,i){var n=e.getUTCMonth();switch(t){case"L":return String(n+1);case"LL":return ft(n+1,2);case"Lo":return i.ordinalNumber(n+1,{unit:"month"});case"LLL":return i.month(n,{width:"abbreviated",context:"standalone"});case"LLLLL":return i.month(n,{width:"narrow",context:"standalone"});default:return i.month(n,{width:"wide",context:"standalone"})}},w:function(e,t,i,n){var r=function(e,t){Le(1,arguments);var i=qe(e),n=dt(i,t).getTime()-pt(i,t).getTime();return Math.round(n/ht)+1}(e,n);return"wo"===t?i.ordinalNumber(r,{unit:"week"}):ft(r,t.length)},I:function(e,t,i){var n=function(e){Le(1,arguments);var t=qe(e),i=at(t).getTime()-lt(t).getTime();return Math.round(i/ut)+1}(e);return"Io"===t?i.ordinalNumber(n,{unit:"week"}):ft(n,t.length)},d:function(e,t,i){return"do"===t?i.ordinalNumber(e.getUTCDate(),{unit:"date"}):vt(e,t)},D:function(e,t,i){var n=function(e){Le(1,arguments);var t=qe(e),i=t.getTime();t.setUTCMonth(0,1),t.setUTCHours(0,0,0,0);var n=t.getTime(),r=i-n;return Math.floor(r/ot)+1}(e);return"Do"===t?i.ordinalNumber(n,{unit:"dayOfYear"}):ft(n,t.length)},E:function(e,t,i){var n=e.getUTCDay();switch(t){case"E":case"EE":case"EEE":return i.day(n,{width:"abbreviated",context:"formatting"});case"EEEEE":return i.day(n,{width:"narrow",context:"formatting"});case"EEEEEE":return i.day(n,{width:"short",context:"formatting"});default:return i.day(n,{width:"wide",context:"formatting"})}},e:function(e,t,i,n){var r=e.getUTCDay(),o=(r-n.weekStartsOn+8)%7||7;switch(t){case"e":return String(o);case"ee":return ft(o,2);case"eo":return i.ordinalNumber(o,{unit:"day"});case"eee":return i.day(r,{width:"abbreviated",context:"formatting"});case"eeeee":return i.day(r,{width:"narrow",context:"formatting"});case"eeeeee":return i.day(r,{width:"short",context:"formatting"});default:return i.day(r,{width:"wide",context:"formatting"})}},c:function(e,t,i,n){var r=e.getUTCDay(),o=(r-n.weekStartsOn+8)%7||7;switch(t){case"c":return String(o);case"cc":return ft(o,t.length);case"co":return i.ordinalNumber(o,{unit:"day"});case"ccc":return i.day(r,{width:"abbreviated",context:"standalone"});case"ccccc":return i.day(r,{width:"narrow",context:"standalone"});case"cccccc":return i.day(r,{width:"short",context:"standalone"});default:return i.day(r,{width:"wide",context:"standalone"})}},i:function(e,t,i){var n=e.getUTCDay(),r=0===n?7:n;switch(t){case"i":return String(r);case"ii":return ft(r,t.length);case"io":return i.ordinalNumber(r,{unit:"day"});case"iii":return i.day(n,{width:"abbreviated",context:"formatting"});case"iiiii":return i.day(n,{width:"narrow",context:"formatting"});case"iiiiii":return i.day(n,{width:"short",context:"formatting"});default:return i.day(n,{width:"wide",context:"formatting"})}},a:function(e,t,i){var n=e.getUTCHours()/12>=1?"pm":"am";switch(t){case"a":case"aa":return i.dayPeriod(n,{width:"abbreviated",context:"formatting"});case"aaa":return i.dayPeriod(n,{width:"abbreviated",context:"formatting"}).toLowerCase();case"aaaaa":return i.dayPeriod(n,{width:"narrow",context:"formatting"});default:return i.dayPeriod(n,{width:"wide",context:"formatting"})}},b:function(e,t,i){var n,r=e.getUTCHours();switch(n=12===r?"noon":0===r?"midnight":r/12>=1?"pm":"am",t){case"b":case"bb":return i.dayPeriod(n,{width:"abbreviated",context:"formatting"});case"bbb":return i.dayPeriod(n,{width:"abbreviated",context:"formatting"}).toLowerCase();case"bbbbb":return i.dayPeriod(n,{width:"narrow",context:"formatting"});default:return i.dayPeriod(n,{width:"wide",context:"formatting"})}},B:function(e,t,i){var n,r=e.getUTCHours();switch(n=r>=17?"evening":r>=12?"afternoon":r>=4?"morning":"night",t){case"B":case"BB":case"BBB":return i.dayPeriod(n,{width:"abbreviated",context:"formatting"});case"BBBBB":return i.dayPeriod(n,{width:"narrow",context:"formatting"});default:return i.dayPeriod(n,{width:"wide",context:"formatting"})}},h:function(e,t,i){if("ho"===t){var n=e.getUTCHours()%12;return 0===n&&(n=12),i.ordinalNumber(n,{unit:"hour"})}return yt(e,t)},H:function(e,t,i){return"Ho"===t?i.ordinalNumber(e.getUTCHours(),{unit:"hour"}):bt(e,t)},K:function(e,t,i){var n=e.getUTCHours()%12;return"Ko"===t?i.ordinalNumber(n,{unit:"hour"}):ft(n,t.length)},k:function(e,t,i){var n=e.getUTCHours();return 0===n&&(n=24),"ko"===t?i.ordinalNumber(n,{unit:"hour"}):ft(n,t.length)},m:function(e,t,i){return"mo"===t?i.ordinalNumber(e.getUTCMinutes(),{unit:"minute"}):wt(e,t)},s:function(e,t,i){return"so"===t?i.ordinalNumber(e.getUTCSeconds(),{unit:"second"}):St(e,t)},S:function(e,t){return Tt(e,t)},X:function(e,t,i,n){var r=(n._originalDate||e).getTimezoneOffset();if(0===r)return"Z";switch(t){case"X":return Ct(r);case"XXXX":case"XX":return Ot(r);default:return Ot(r,":")}},x:function(e,t,i,n){var r=(n._originalDate||e).getTimezoneOffset();switch(t){case"x":return Ct(r);case"xxxx":case"xx":return Ot(r);default:return Ot(r,":")}},O:function(e,t,i,n){var r=(n._originalDate||e).getTimezoneOffset();switch(t){case"O":case"OO":case"OOO":return"GMT"+At(r,":");default:return"GMT"+Ot(r,":")}},z:function(e,t,i,n){var r=(n._originalDate||e).getTimezoneOffset();switch(t){case"z":case"zz":case"zzz":return"GMT"+At(r,":");default:return"GMT"+Ot(r,":")}},t:function(e,t,i,n){var r=n._originalDate||e;return ft(Math.floor(r.getTime()/1e3),t.length)},T:function(e,t,i,n){return ft((n._originalDate||e).getTime(),t.length)}};function At(e,t){var i=e>0?"-":"+",n=Math.abs(e),r=Math.floor(n/60),o=n%60;if(0===o)return i+String(r);var a=t||"";return i+String(r)+a+ft(o,2)}function Ct(e,t){return e%60==0?(e>0?"-":"+")+ft(Math.abs(e)/60,2):Ot(e,t)}function Ot(e,t){var i=t||"",n=e>0?"-":"+",r=Math.abs(e);return n+ft(Math.floor(r/60),2)+i+ft(r%60,2)}const It=xt;function Nt(e,t){switch(e){case"P":return t.date({width:"short"});case"PP":return t.date({width:"medium"});case"PPP":return t.date({width:"long"});default:return t.date({width:"full"})}}function Et(e,t){switch(e){case"p":return t.time({width:"short"});case"pp":return t.time({width:"medium"});case"ppp":return t.time({width:"long"});default:return t.time({width:"full"})}}const Rt={p:Et,P:function(e,t){var i,n=e.match(/(P+)(p+)?/)||[],r=n[1],o=n[2];if(!o)return Nt(e,t);switch(r){case"P":i=t.dateTime({width:"short"});break;case"PP":i=t.dateTime({width:"medium"});break;case"PPP":i=t.dateTime({width:"long"});break;default:i=t.dateTime({width:"full"})}return i.replace("{{date}}",Nt(r,t)).replace("{{time}}",Et(o,t))}};function _t(e){var t=new Date(Date.UTC(e.getFullYear(),e.getMonth(),e.getDate(),e.getHours(),e.getMinutes(),e.getSeconds(),e.getMilliseconds()));return t.setUTCFullYear(e.getFullYear()),e.getTime()-t.getTime()}var Pt=["D","DD"],Mt=["YY","YYYY"];function Ft(e){return-1!==Pt.indexOf(e)}function Dt(e){return-1!==Mt.indexOf(e)}function kt(e,t,i){if("YYYY"===e)throw new RangeError("Use `yyyy` instead of `YYYY` (in `".concat(t,"`) for formatting years to the input `").concat(i,"`; see: https://git.io/fxCyr"));if("YY"===e)throw new RangeError("Use `yy` instead of `YY` (in `".concat(t,"`) for formatting years to the input `").concat(i,"`; see: https://git.io/fxCyr"));if("D"===e)throw new RangeError("Use `d` instead of `D` (in `".concat(t,"`) for formatting days of the month to the input `").concat(i,"`; see: https://git.io/fxCyr"));if("DD"===e)throw new RangeError("Use `dd` instead of `DD` (in `".concat(t,"`) for formatting days of the month to the input `").concat(i,"`; see: https://git.io/fxCyr"))}var Ut=/[yYQqMLwIdDecihHKkms]o|(\w)\1*|''|'(''|[^'])+('|$)|./g,Bt=/P+p+|P+|p+|''|'(''|[^'])+('|$)|./g,Lt=/^'([^]*?)'?$/,qt=/''/g,Jt=/[a-zA-Z]/;function jt(e,t,i){Le(2,arguments);var n=String(t),r=i||{},o=r.locale||tt,a=o.options&&o.options.firstWeekContainsDate,s=null==a?1:it(a),l=null==r.firstWeekContainsDate?s:it(r.firstWeekContainsDate);if(!(l>=1&&l<=7))throw new RangeError("firstWeekContainsDate must be between 1 and 7 inclusively");var u=o.options&&o.options.weekStartsOn,d=null==u?0:it(u),c=null==r.weekStartsOn?d:it(r.weekStartsOn);if(!(c>=0&&c<=6))throw new RangeError("weekStartsOn must be between 0 and 6 inclusively");if(!o.localize)throw new RangeError("locale must contain localize property");if(!o.formatLong)throw new RangeError("locale must contain formatLong property");var p=qe(e);if(!He(p))throw new RangeError("Invalid time value");var h=_t(p),f=rt(p,h),m={firstWeekContainsDate:l,weekStartsOn:c,locale:o,_originalDate:p},g=n.match(Bt).map((function(e){var t=e[0];return"p"===t||"P"===t?(0,Rt[t])(e,o.formatLong,m):e})).join("").match(Ut).map((function(i){if("''"===i)return"'";var n=i[0];if("'"===n)return Ht(i);var a=It[n];if(a)return!r.useAdditionalWeekYearTokens&&Dt(i)&&kt(i,t,e),!r.useAdditionalDayOfYearTokens&&Ft(i)&&kt(i,t,e),a(f,i,o.localize,m);if(n.match(Jt))throw new RangeError("Format string contains an unescaped latin alphabet character `"+n+"`");return i})).join("");return g}function Ht(e){return e.match(Lt)[1].replace(qt,"'")}const Gt=(e,t)=>new Date(e,t+1,0).getDate(),zt=(e,t)=>new Date(e,t,1).getDay(),Wt=["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],Vt=["January","February","March","April","May","June","July","August","September","October","November","December"];var Qt=function(e,t,i,n){var r,o=arguments.length,a=o<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,i,n);else for(var s=e.length-1;s>=0;s--)(r=e[s])&&(a=(o<3?r(a):o>3?r(t,i,a):r(t,i))||a);return o>3&&a&&Object.defineProperty(t,i,a),a};let Kt=class extends re{constructor(){var e;super(...arguments),this._selectedDate=void 0,this.now=new Date,this._monthShown=this.defaultMonth&&-1!==Vt.indexOf(this.defaultMonth)?Vt.indexOf(this.defaultMonth):this.now.getMonth(),this.yearShown=null!==(e=this.defaultYear)&&void 0!==e?e:this.now.getFullYear()}set selectedDate(e){const t=this._selectedDate;this._selectedDate=e,this.requestUpdate("selectedDate",t),this.dispatchEvent(new Event("change",{composed:!0,bubbles:!0}))}get selectedDate(){return this._selectedDate}set monthShown(e){const t=this._monthShown;12===e?(this._monthShown=0,this.yearShown++):-1===e?(this._monthShown=11,this.yearShown--):this._monthShown=e,this.requestUpdate("monthShown",t)}get monthShown(){return this._monthShown}render(){const e=Gt(this.yearShown,this.monthShown),t=Wt[zt(this.yearShown,this.monthShown)],i=(n=this.yearShown,r=this.monthShown,Gt(r>0?n:n-1,(e=>e>0?e-1:11)(r)));var n,r;const o=Wt[((e,t)=>(zt(e,t)+Gt(e,t)%7-1)%7)(this.yearShown,this.monthShown)],a=[];if("Sunday"!==t)for(let e=Wt.indexOf(t);e>0;e--)a.push(i+1-e);const s=new Array(e).fill(null).map(((e,t)=>t+1)),l=[];if("Saturday"!==o){const e=[...Wt].reverse().indexOf(o);for(let t=1;t<=e;t++)l.push(t)}const u=[...a,...s,...l].map(((e,t)=>{var i,n,r;const o=this.yearShown<this.now.getFullYear()||this.yearShown===this.now.getFullYear()&&this.monthShown<this.now.getMonth()||this.yearShown===this.now.getFullYear()&&this.monthShown===this.now.getMonth()&&e<this.now.getDate(),l=t<a.length||t>=a.length+s.length,u=!l&&this.now.getMonth()===this.monthShown&&this.now.getDate()===e,d=!!this.selectedDate&&!l&&this.monthShown===function(e){return Le(1,arguments),qe(e).getMonth()}(this.selectedDate)&&this.yearShown===function(e){return Le(1,arguments),qe(e).getFullYear()}(this.selectedDate)&&e===function(e){return Le(1,arguments),qe(e).getDate()}(this.selectedDate),c=jt(new Date(this.yearShown,this.monthShown,e),"y-MM-dd"),p=!(null===(i=this.availabilities)||void 0===i?void 0:i[c])||0===(null===(r=null===(n=this.availabilities)||void 0===n?void 0:n[c])||void 0===r?void 0:r.length);return U`<button
|
|
73
|
+
?disabled=${o||p||l}
|
|
73
74
|
class="dayNumber ${fe({past:o,differentMonth:l,today:u,selected:d,noAvailabilities:p})}"
|
|
74
|
-
|
|
75
|
-
|
|
75
|
+
>
|
|
76
|
+
${e}
|
|
77
|
+
</button>`})),d=Xt(7,u);return U`
|
|
76
78
|
<div id="calendar">
|
|
77
79
|
<div id="header">
|
|
78
80
|
<h1>${Vt[this.monthShown]} ${this.yearShown}</h1>
|
|
@@ -114,7 +116,7 @@ var e={8005:function(e,t,i){var n,r=this&&this.__extends||(n=function(e,t){retur
|
|
|
114
116
|
|
|
115
117
|
<div
|
|
116
118
|
id="rows"
|
|
117
|
-
@click="${e=>{const t=e.target;(null==t?void 0:t.closest("
|
|
119
|
+
@click="${e=>{const t=e.target;(null==t?void 0:t.closest("button.dayNumber:not(.differentMonth)"))&&(this.selectedDate=new Date(this.yearShown,this.monthShown,parseInt(t.innerText)))}}"
|
|
118
120
|
>
|
|
119
121
|
<div class="row">
|
|
120
122
|
<span class="dayInitial">S</span>
|
|
@@ -189,6 +191,8 @@ var e={8005:function(e,t,i){var n,r=this&&this.__extends||(n=function(e,t){retur
|
|
|
189
191
|
font-size: 12px;
|
|
190
192
|
text-align: center;
|
|
191
193
|
flex: 1 1 0px;
|
|
194
|
+
border: none;
|
|
195
|
+
background: none;
|
|
192
196
|
}
|
|
193
197
|
|
|
194
198
|
.dayInitial {
|
|
@@ -277,10 +281,10 @@ var e={8005:function(e,t,i){var n,r=this&&this.__extends||(n=function(e,t){retur
|
|
|
277
281
|
|
|
278
282
|
.timezone-display-text {
|
|
279
283
|
font-size: 12px;
|
|
280
|
-
|
|
284
|
+
color: #767676;
|
|
281
285
|
}
|
|
282
286
|
.select-tour-type-instructions {
|
|
283
|
-
color: #
|
|
287
|
+
color: #e60000;
|
|
284
288
|
}
|
|
285
289
|
|
|
286
290
|
#optionContainer {
|
|
@@ -394,7 +398,7 @@ var e={8005:function(e,t,i){var n,r=this&&this.__extends||(n=function(e,t){retur
|
|
|
394
398
|
font-family: "Helvetica Neue", Arial;
|
|
395
399
|
font-size: 14px;
|
|
396
400
|
}
|
|
397
|
-
`;var si=function(e,t,i,n){var r,o=arguments.length,a=o<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,i,n);else for(var s=e.length-1;s>=0;s--)(r=e[s])&&(a=(o<3?r(a):o>3?r(t,i,a):r(t,i))||a);return o>3&&a&&Object.defineProperty(t,i,a),a};let li=class extends re{constructor(){super(),this.options=[],this.placeholder="Select",this.activeOption=null,this.isOpen=!1,this.activeOptionIndex=null,this.focus=()=>{this.meSelect.focus()},this.toggleSelect=()=>{this.isOpen&&(this.activeOption=null),this.isOpen=!this.isOpen},this.setSelectedOption=(e,t=!0)=>{this.value!==e.value?this.value=e.value:this.value=void 0,t&&(this.isOpen=!this.isOpen,this.activeOption=null),this.value?this.meSelect.style.color="rgba(32, 32, 32, 1)":this.meSelect.style.color="rgba(32, 32, 32, 0.5)",this.dispatchEvent(new Event("change",{bubbles:!0,composed:!0}))},this.handleKeydown=(e,t)=>i=>{("string"==typeof e&&i.key===e||"object"==typeof e&&e.includes(i.key))&&t()},this.firstUpdated=()=>{this.value&&this.meSelect&&(this.meSelect.style.color="rgba(32, 32, 32, 1)")},document.addEventListener("click",(e=>{e.composedPath().includes(this.meSelect)||(this.isOpen=!1)}))}adjustScrollToActiveOption(){if(null!=this.activeOptionIndex){const e=this.renderRoot.querySelectorAll(".option")[this.activeOptionIndex];e&&e.scrollIntoView({block:"nearest"})}}render(){var e,t;return U`
|
|
401
|
+
`;var si=function(e,t,i,n){var r,o=arguments.length,a=o<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,i,n);else for(var s=e.length-1;s>=0;s--)(r=e[s])&&(a=(o<3?r(a):o>3?r(t,i,a):r(t,i))||a);return o>3&&a&&Object.defineProperty(t,i,a),a};let li=class extends re{constructor(){super(),this.options=[],this.placeholder="Select",this.activeOption=null,this.isOpen=!1,this.activeOptionIndex=null,this.focus=()=>{this.meSelect.focus()},this.toggleSelect=()=>{this.isOpen&&(this.activeOption=null),this.isOpen=!this.isOpen},this.setSelectedOption=(e,t=!0)=>{this.value!==e.value?this.value=e.value:this.value=void 0,t&&(this.isOpen=!this.isOpen,this.activeOption=null),this.value?this.meSelect.style.color="rgba(32, 32, 32, 1)":this.meSelect.style.color="rgba(32, 32, 32, 0.5)",this.dispatchEvent(new Event("change",{bubbles:!0,composed:!0}))},this.handleKeydown=(e,t)=>i=>{("string"==typeof e&&i.key===e||"object"==typeof e&&e.includes(i.key))&&t()},this.firstUpdated=()=>{this.value&&this.meSelect&&(this.meSelect.style.color="rgba(32, 32, 32, 1)")},document.addEventListener("click",(e=>{e.composedPath().includes(this.meSelect)||(this.isOpen=!1)}))}adjustScrollToActiveOption(){if(null!=this.activeOptionIndex){const e=this.renderRoot.querySelectorAll(".option")[this.activeOptionIndex];e&&e.scrollIntoView({block:"nearest"})}}render(){var e,t,i,n;return U`
|
|
398
402
|
<div id="outer-select-container">
|
|
399
403
|
<div
|
|
400
404
|
id="select"
|
|
@@ -403,9 +407,15 @@ var e={8005:function(e,t,i){var n,r=this&&this.__extends||(n=function(e,t){retur
|
|
|
403
407
|
@click=${()=>this.isOpen=!this.isOpen}
|
|
404
408
|
@keydown="${e=>{switch(e.key){case"Enter":case" ":e.preventDefault(),this.isOpen&&this.activeOption?this.setSelectedOption(this.activeOption):this.toggleSelect();break;case"Escape":e.preventDefault(),this.isOpen=!1;break;case"Tab":this.isOpen&&e.preventDefault();break;case"ArrowUp":e.preventDefault(),this.isOpen&&null!=this.activeOptionIndex&&(this.activeOptionIndex=Math.max(0,this.activeOptionIndex-1),this.activeOption=this.options[this.activeOptionIndex],this.adjustScrollToActiveOption());break;case"ArrowDown":e.preventDefault(),this.isOpen&&(null==this.activeOptionIndex?this.activeOptionIndex=0:this.activeOptionIndex<this.options.length-1&&this.activeOptionIndex++,this.activeOption=this.options[this.activeOptionIndex],this.adjustScrollToActiveOption())}}}"
|
|
405
409
|
>
|
|
406
|
-
<span id="selectText"
|
|
407
|
-
|
|
408
|
-
|
|
410
|
+
${(null===(e=this.options.find((e=>e.value===this.value)))||void 0===e?void 0:e.label)?U` <span id="selectText"
|
|
411
|
+
>${null!==(i=null===(t=this.options.find((e=>e.value===this.value)))||void 0===t?void 0:t.label)&&void 0!==i?i:this.placeholder}</span
|
|
412
|
+
>`:U` <input
|
|
413
|
+
readonly
|
|
414
|
+
placeholder="${this.placeholder}"
|
|
415
|
+
.value="${(null===(n=this.options.find((e=>e.value===this.value)))||void 0===n?void 0:n.label)||this.value||""}"
|
|
416
|
+
id="selectText"
|
|
417
|
+
/>`}
|
|
418
|
+
|
|
409
419
|
<svg
|
|
410
420
|
width="10"
|
|
411
421
|
height="6"
|
|
@@ -426,6 +436,7 @@ var e={8005:function(e,t,i){var n,r=this&&this.__extends||(n=function(e,t){retur
|
|
|
426
436
|
@mousemove="${()=>{this.activeOption=e}}"
|
|
427
437
|
@mouseleave="${()=>{this.activeOption=null}}"
|
|
428
438
|
class="option ${fe({active:this.activeOption===e})}"
|
|
439
|
+
tabindex="0"
|
|
429
440
|
>
|
|
430
441
|
${e.label}
|
|
431
442
|
</li>`))}
|
|
@@ -438,6 +449,20 @@ var e={8005:function(e,t,i){var n,r=this&&this.__extends||(n=function(e,t){retur
|
|
|
438
449
|
--light-border: 1px solid $light-border-color;
|
|
439
450
|
}
|
|
440
451
|
|
|
452
|
+
#selectText {
|
|
453
|
+
background-color: transparent;
|
|
454
|
+
border: none;
|
|
455
|
+
outline: none;
|
|
456
|
+
font-size: 14px;
|
|
457
|
+
line-height: 14px;
|
|
458
|
+
font-family: "Helvetica Neue", Arial;
|
|
459
|
+
width: 100%;
|
|
460
|
+
padding: 0;
|
|
461
|
+
height: 14px;
|
|
462
|
+
display: flex;
|
|
463
|
+
align-items: center;
|
|
464
|
+
}
|
|
465
|
+
|
|
441
466
|
ul {
|
|
442
467
|
padding-left: 0;
|
|
443
468
|
margin-bottom: 0;
|
|
@@ -471,10 +496,10 @@ var e={8005:function(e,t,i){var n,r=this&&this.__extends||(n=function(e,t){retur
|
|
|
471
496
|
align-items: center;
|
|
472
497
|
justify-content: space-between;
|
|
473
498
|
color: rgba(32, 32, 32, 0.5);
|
|
474
|
-
|
|
475
499
|
white-space: nowrap;
|
|
476
500
|
overflow: hidden;
|
|
477
501
|
text-overflow: ellipsis;
|
|
502
|
+
height: 30px;
|
|
478
503
|
}
|
|
479
504
|
|
|
480
505
|
::-webkit-scrollbar {
|
|
@@ -950,7 +975,7 @@ otherwise there's some empty space at the bottom of the button, which interferes
|
|
|
950
975
|
gap: 12px;
|
|
951
976
|
align-items: center;
|
|
952
977
|
}
|
|
953
|
-
`;class Yi{constructor(e,t,i,n){this.org=e,this.building=t,this.chatId=i,this.incomingProcessedLeadSource=n,this.featureFlags={}}setFeatureFlags(e){this.featureFlags={...this.featureFlags,...e}}ping(e){var t;fetch("https://app.meetelise.com/platformApi/connectors/talk_js/analytics",{method:"POST",credentials:"omit",keepalive:!0,headers:{"content-type":"application/json; charset=UTF-8"},body:JSON.stringify({eventType:e,chatId:this.chatId,url:location.href,org:this.org,building:this.building,referrer:document.referrer,featureFlags:this.featureFlags,campaignSources:$i(),incomingProcessedLeadSource:this.incomingProcessedLeadSource,webchatVersion:null!==(t="MISSING_ENV_VAR".npm_package_version)&&void 0!==t?t:"1.20.155"})})}}const $i=()=>{var e,t,i,n,r,o;try{const n=new URL(window.location.href).searchParams,r=null!==(i=null===(t=null===(e=window.RCTPCampaign)||void 0===e?void 0:e.CampaignDetails)||void 0===t?void 0:t.Source)&&void 0!==i?i:null,o=n.get("switch_cls[id]"),a=n.get("ilm");return{entrataCampaignSource:o,realpageCampaignSource:a,utmCampaignSource:n.get("utm_source"),yardiCampaignSource:r,bozzutoAdSource:ri("bozzuto_ad_source")}}catch(e){console.warn(`Couldnt get campaign sources from url, error: ${e}`);const t=document.createElement("iframe");if(t.style.display="none",document.body.appendChild(t),!t.contentWindow)return{entrataCampaignSource:null,realpageCampaignSource:null,utmCampaignSource:null,yardiCampaignSource:null,bozzutoAdSource:null};const i=t.contentWindow.URL;if(!i)return{entrataCampaignSource:null,realpageCampaignSource:null,utmCampaignSource:null,yardiCampaignSource:null,bozzutoAdSource:null};const a=new i(window.location.href).searchParams,s=null!==(o=null===(r=null===(n=window.RCTPCampaign)||void 0===n?void 0:n.CampaignDetails)||void 0===r?void 0:r.Source)&&void 0!==o?o:null;return{entrataCampaignSource:a.get("switch_cls[id]"),realpageCampaignSource:a.get("ilm"),utmCampaignSource:a.get("utm_source"),yardiCampaignSource:s,bozzutoAdSource:ri("bozzuto_ad_source")}}};var Zi;!function(e){e.error="error",e.info="info",e.warn="warn"}(Zi||(Zi={}));const en=async({logType:e,buildingSlug:i,orgSlug:n,logTitle:r,logData:o})=>{await t().post("https://app.meetelise.com/platformApi/webchat/logging",{...o},{headers:{"Content-Type":"application/json","building-slug":null!=i?i:"","org-slug":null!=n?n:"","log-type":null!=e?e:Zi.error,"log-title":r.toUpperCase().replace(/\s/g,"_")}})},tn=async({params:e,sampleRate:i})=>{try{if(Math.random()>=i)return;await t().post("https://app.meetelise.com/platformApi/webchat/log/signal",{...e,website_origin:window.location.origin,website_search:window.location.search})}catch(e){console.warn(e)}};function nn(){return rn()?function(){const e=window.location.search,t={};return e.split("?").slice(1).join("&").split("&").forEach((e=>{const[i,n]=e.split("=");i&&n&&(t[decodeURIComponent(i)]=decodeURIComponent(n))})),t}():function(){const e=new URLSearchParams(window.location.search),t=e.has("utm_content"),i=e.has("utm_source");if(t&&!i){const t=e.get("utm_content");e.delete("utm_content"),e.set("utm_source",t)}return Object.fromEntries(e)}()}const rn=()=>(window.location.search.match(/\?/g)||[]).length>1;var on=i(8367),an=i.n(on);function sn(e){return"avb"===e?"AVB Company Website":"property-website"}const ln=async(e,i=!1)=>{const n=`https://app.meetelise.com/eliseCrmApi/building/${e}/scheduling_status?observe_dynamic_scheduling=${i}`;try{return(await t().get(n)).data.is_enabled}catch(e){return!1}};var un=function(e,t,i,n){var r,o=arguments.length,a=o<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,i,n);else for(var s=e.length-1;s>=0;s--)(r=e[s])&&(a=(o<3?r(a):o>3?r(t,i,a):r(t,i))||a);return o>3&&a&&Object.defineProperty(t,i,a),a};let dn=class extends re{constructor(){super(...arguments),this.tourTypeOptions=[],this.chatId="",this.buildingId=0,this.buildingSlug="",this.sgtUrl="",this.selfGuidedToursTypeOffered="",this.selfGuidedTourEnabled=!1,this.escortedToursLink="",this.virtualToursLink="",this.orgSlug="",this.hasDynamicSchedulingEnabled=!1,this.leadSourceClient=null,this.buildingName="",this.tourType=null,this.shouldShowTourType={[cn.Guided]:!0,[cn.Self]:!0,[cn.Virtual]:!0},this.email="",this.phoneNumber="",this.availabilitiesGroupedByDay={},this.waitingForAvailabilities=!0,this.mobilePageIndex=0,this.isSubmitting=!1,this.tourIsBooked=!1,this.shouldAllowScheduling=!1,this.shouldAllowScheduleLoading=!0,this.promptForReschedule=!1,this.canceledReschedule=!1,this.leadSources=[],this.orgLegalName="",this.currentLeadSource="",this.featureFlagShowDropdown="",this.compactDesign=!1,this.primaryColor=Me,this.backgroundColor=Fe,this.foregroundColorOnPrimaryBackgroundColor="white",this.foregroundColorOnSecondaryBackgroundColor="black",this.firstNameInputValue="",this.lastNameInputValue="",this.leadSourceInputValue="",this.errorGettingAvailabilities=!1,this.firstUpdated=async()=>{try{const[e,t]=await Promise.all([ln(this.buildingId,this.hasDynamicSchedulingEnabled),Mi()]);this.shouldAllowScheduling=e,this.shouldAllowScheduleLoading=!1,en({logTitle:"AVAILABILITIES_EXIST_FOR_TOUR_TYPE",logData:t,logType:Zi.info,buildingSlug:this.buildingSlug,orgSlug:this.orgSlug});const i=Object.values(t).every((e=>!1===e)),n=!this.sgtUrl&&!this.escortedToursLink&&!this.virtualToursLink;if(i&&n)return this.errorGettingAvailabilities=!0,this.waitingForAvailabilities=!1,void en({logTitle:"NO_AVAILABILITIES_EXIST",logData:null,logType:Zi.warn,buildingSlug:this.buildingSlug,orgSlug:this.orgSlug});if(this.shouldShowTourType={[cn.Guided]:this.tourTypeOptions.map((e=>e.value)).includes("WITH_AGENT")&&(t[cn.Guided]||!!this.escortedToursLink),[cn.Self]:this.tourTypeOptions.map((e=>e.value)).includes("SELF_GUIDED")&&(t[cn.Self]||!!this.sgtUrl),[cn.Virtual]:this.tourTypeOptions.map((e=>e.value)).includes("VIRTUAL_SHOWING")&&(t[cn.Virtual]||!!this.virtualToursLink)},1===Object.values(this.shouldShowTourType).reduce(((e,t)=>!0===t?e+1:e),0)&&(this.tourType=Object.keys(this.shouldShowTourType).find((e=>this.shouldShowTourType[e]))),null===this.tourType)return void(this.waitingForAvailabilities=!1);this.availabilitiesGroupedByDay=await Fi(pn[this.tourType]),this.waitingForAvailabilities=!1}catch(e){this.errorGettingAvailabilities=!0,this.waitingForAvailabilities=!1,en({logTitle:"ERROR_LOADING_AVAILABILITIES",logData:{error:e},logType:Zi.error,buildingSlug:this.buildingSlug,orgSlug:this.orgSlug})}},this.willUpdate=async e=>{e.has("tourType")&&this.tourType&&(this.availabilitiesGroupedByDay=await Fi(pn[this.tourType]))},this.handlePhoneKeydown=e=>{var t;if(!(e instanceof KeyboardEvent&&e.target instanceof HTMLInputElement&&null!==e.target.selectionStart))return;const i=e.target.selectionStart;if(1!==e.key.length||Re(e)){if("Backspace"===e.key){if(Re(e))return;if(this.phoneInput.selectionEnd&&this.phoneInput.selectionStart&&this.phoneInput.selectionEnd-this.phoneInput.selectionStart>0)return;const t=this.phoneNumber.length,n=this.phoneNumber.slice(0,i).replace(/\D/g,""),r=this.phoneNumber.slice(i).replace(/\D/g,""),o=`${n.slice(0,-1)}${r}`;this.phoneNumber=Ie(o),this.phoneInput.value=this.phoneNumber;const a=i-(t-this.phoneNumber.length);return this.phoneInput.setSelectionRange(a,a),e.preventDefault(),void e.stopPropagation()}if(!["ArrowLeft","ArrowRight"].includes(e.key)||Re(e)||e.shiftKey)return;if("ArrowLeft"===e.key){const e=((null===(t=this.phoneNumber.slice(0,i).split(/\d+/).at(-1))||void 0===t?void 0:t.length)||0)+1,n=i-e>-1?i-e:0;this.phoneInput.setSelectionRange(n,n)}if("ArrowRight"===e.key){const e=(this.phoneNumber.slice(i).split(/\d+/)[0].length||0)+1,t=i+e<this.phoneNumber.length?i+e:this.phoneNumber.length;this.phoneInput.setSelectionRange(t,t)}e.preventDefault(),e.stopPropagation()}else{e.preventDefault(),e.stopPropagation();const t=this.phoneNumber.slice(0,i)+e.key+this.phoneNumber.slice(i);this.phoneNumber=Ie(t.replace(/\D/g,"")),this.phoneInput.value=this.phoneNumber}},this.handlePhoneKeyup=e=>{var t;if(!e.key)return;if(e.key.includes("Arrow")||["Meta","Shift","Control","Alt"].includes(e.key))return;const i=this.phoneInput.selectionStart,n=i?this.phoneInput.value.slice(i).replace(/\D/g,""):"";this.phoneNumber=Ie(this.phoneInput.value);let r=0,o=n.length;for(;o;)(null===(t=this.phoneNumber.at(r))||void 0===t?void 0:t.match(/\d/))&&o--,r++;const a=this.phoneInput.value.length-r+1;this.phoneInput.setSelectionRange(a,a)},this.onChangeEmail=e=>{e.target&&(this.email=e.target.value)},this.validators={tourType:()=>null!==this.tourType,dateAndTime:()=>!!this.selectedDate&&!!this.selectedTime,leadInfo:()=>{var e,t,i;return(!!(null===(e=this.firstNameInput)||void 0===e?void 0:e.value)||!!(null===(t=this.lastNameInput)||void 0===t?void 0:t.value))&&(null===(i=this.emailInput)||void 0===i?void 0:i.value.includes("@"))&&!!this.phoneNumber&&14===this.phoneNumber.length&&oi(this.phoneNumber)}},this.formIsValidForSubmission=()=>this.validators.tourType()&&this.validators.dateAndTime()&&this.validators.leadInfo(),this.timeStringToHoursAndMinutes=e=>{const[t,i]=e.split(/\D/g);return[parseInt(t)+(e.toLowerCase().includes("pm")?12:0),parseInt(i)]},this.submit=async()=>{var e,i,n,r,o,a,s,l,u,d,c,p,h,f,m;if(!this.selectedDate||!this.selectedTime||null===this.tourType)return;const g=new URLSearchParams(window.location.search);let v=null;v=this.selectedLeadSource&&this.selectedLeadSource.value&&this.selectedLeadSource.value.length>0?this.selectedLeadSource.value:this.leadSourceInputValue&&this.leadSourceInputValue.length>0?this.leadSourceInputValue:this.currentLeadSource;const y=[...new Set(v?[v,"property-website"]:["property-website"])];this.firstNameInput&&(this.firstNameInputValue=this.firstNameInput.value),this.lastNameInput&&(this.lastNameInputValue=this.lastNameInput.value),this.leadSourceInputValue=v,Wi("scheduleTourSubmitted",{email:this.email,phone:`+1${null===(e=this.phoneNumber.match(/\d/g))||void 0===e?void 0:e.join("")}`,firstName:null!==(n=null===(i=this.firstNameInput)||void 0===i?void 0:i.value)&&void 0!==n?n:this.firstNameInputValue,lastName:null!==(o=null===(r=this.lastNameInput)||void 0===r?void 0:r.value)&&void 0!==o?o:this.lastNameInputValue,tourType:hn[this.tourType],tourTime:`${this.selectedTime.datetime}${this.selectedTime.offset}`,originatingSource:y.find((e=>"property-website"!==e))||null});const b={referrer:document.referrer,email_address:this.email,phone_number:`+1${null===(a=this.phoneNumber.match(/\d/g))||void 0===a?void 0:a.join("")}`,building_id:this.buildingId,first_name:null!==(l=null===(s=this.firstNameInput)||void 0===s?void 0:s.value)&&void 0!==l?l:this.firstNameInputValue,last_name:null!==(d=null===(u=this.lastNameInput)||void 0===u?void 0:u.value)&&void 0!==d?d:this.lastNameInputValue,tour_type:hn[this.tourType],tour_time:`${this.selectedTime.datetime}${this.selectedTime.offset}`,cancel_existing_tours:this.promptForReschedule,lead_sources:[...new Set(v?[v,sn(this.orgSlug)]:[sn(this.orgSlug)])],query_params:Object.fromEntries(g.entries()),conversation_tracking_id:null===(c=this.leadSourceClient)||void 0===c?void 0:c.chatId};this.isSubmitting=!0;try{await t().post("https://app.meetelise.com/platformApi/state/create/v2/scheduleMe",b,{headers:{"building-slug":this.buildingSlug,"X-SecurityKey":"JRL8jV4VcSCwOSir5gWkpgNLfKghmhBG","org-slug":this.orgSlug}}),null===(p=this.leadSourceClient)||void 0===p||p.checkAndHandleForLogLeadSource({webchatAction:"tour-scheduler",stateId:null}),this.isSubmitting=!1,this.tourIsBooked=!0}catch(e){const t=e,i=(null===(f=null===(h=t.response)||void 0===h?void 0:h.data)||void 0===f?void 0:f.detail)||"Failed to book tour";if(t.response&&t.response.headers&&t.response.headers["funnel-prospect-conflicting-appointment-error"]){if(this.selectedDate&&this.selectedTime){const e=this.availabilitiesGroupedByDay[jt(this.selectedDate,"yyyy-MM-dd")];e&&(this.availabilitiesGroupedByDay[jt(this.selectedDate,"yyyy-MM-dd")]=e.filter((e=>e!==this.selectedTime)))}}else if(409===(null===(m=t.response)||void 0===m?void 0:m.status)&&!this.promptForReschedule)return this.promptForReschedule=!0,this.isSubmitting=!1,void(this.tourIsBooked=!1);alert(i),this.isSubmitting=!1,this.tourIsBooked=!1}},this.mobilePages=[{validate:this.validators.tourType,nextButtonText:"Next",nextButtonAction:()=>{this.mobilePageIndex++},render:()=>U`${this.tourTypeMenu()}`},{validate:this.validators.dateAndTime,nextButtonText:"Next",nextButtonAction:()=>{this.mobilePageIndex++},render:()=>U`${this.dateAndTimeMenu()}`},{validate:()=>this.validators.leadInfo(),nextButtonText:null,renderNextButton:()=>U` <action-confirm-button
|
|
978
|
+
`;class Yi{constructor(e,t,i,n){this.org=e,this.building=t,this.chatId=i,this.incomingProcessedLeadSource=n,this.featureFlags={}}setFeatureFlags(e){this.featureFlags={...this.featureFlags,...e}}ping(e){var t;fetch("https://app.meetelise.com/platformApi/connectors/talk_js/analytics",{method:"POST",credentials:"omit",keepalive:!0,headers:{"content-type":"application/json; charset=UTF-8"},body:JSON.stringify({eventType:e,chatId:this.chatId,url:location.href,org:this.org,building:this.building,referrer:document.referrer,featureFlags:this.featureFlags,campaignSources:$i(),incomingProcessedLeadSource:this.incomingProcessedLeadSource,webchatVersion:null!==(t="MISSING_ENV_VAR".npm_package_version)&&void 0!==t?t:"1.20.155"})})}}const $i=()=>{var e,t,i,n,r,o;try{const n=new URL(window.location.href).searchParams,r=null!==(i=null===(t=null===(e=window.RCTPCampaign)||void 0===e?void 0:e.CampaignDetails)||void 0===t?void 0:t.Source)&&void 0!==i?i:null,o=n.get("switch_cls[id]"),a=n.get("ilm");return{entrataCampaignSource:o,realpageCampaignSource:a,utmCampaignSource:n.get("utm_source"),yardiCampaignSource:r,bozzutoAdSource:ri("bozzuto_ad_source")}}catch(e){console.warn(`Couldnt get campaign sources from url, error: ${e}`);const t=document.createElement("iframe");if(t.style.display="none",document.body.appendChild(t),!t.contentWindow)return{entrataCampaignSource:null,realpageCampaignSource:null,utmCampaignSource:null,yardiCampaignSource:null,bozzutoAdSource:null};const i=t.contentWindow.URL;if(!i)return{entrataCampaignSource:null,realpageCampaignSource:null,utmCampaignSource:null,yardiCampaignSource:null,bozzutoAdSource:null};const a=new i(window.location.href).searchParams,s=null!==(o=null===(r=null===(n=window.RCTPCampaign)||void 0===n?void 0:n.CampaignDetails)||void 0===r?void 0:r.Source)&&void 0!==o?o:null;return{entrataCampaignSource:a.get("switch_cls[id]"),realpageCampaignSource:a.get("ilm"),utmCampaignSource:a.get("utm_source"),yardiCampaignSource:s,bozzutoAdSource:ri("bozzuto_ad_source")}}};var Zi;!function(e){e.error="error",e.info="info",e.warn="warn"}(Zi||(Zi={}));const en=async({logType:e,buildingSlug:i,orgSlug:n,logTitle:r,logData:o})=>{await t().post("https://app.meetelise.com/platformApi/webchat/logging",{...o},{headers:{"Content-Type":"application/json","building-slug":null!=i?i:"","org-slug":null!=n?n:"","log-type":null!=e?e:Zi.error,"log-title":r.toUpperCase().replace(/\s/g,"_")}})},tn=async({params:e,sampleRate:i})=>{try{if(Math.random()>=i)return;await t().post("https://app.meetelise.com/platformApi/webchat/log/signal",{...e,website_origin:window.location.origin,website_search:window.location.search})}catch(e){console.warn(e)}};function nn(){return rn()?function(){const e=window.location.search,t={};return e.split("?").slice(1).join("&").split("&").forEach((e=>{const[i,n]=e.split("=");i&&n&&(t[decodeURIComponent(i)]=decodeURIComponent(n))})),t}():function(){const e=new URLSearchParams(window.location.search),t=e.has("utm_content"),i=e.has("utm_source");if(t&&!i){const t=e.get("utm_content");e.delete("utm_content"),e.set("utm_source",t)}return Object.fromEntries(e)}()}const rn=()=>(window.location.search.match(/\?/g)||[]).length>1;var on=i(8367),an=i.n(on);function sn(e){return"avb"===e?"AVB Company Website":"windsor"===e?"Windsorcommunities.com":"property-website"}const ln=async(e,i=!1)=>{const n=`https://app.meetelise.com/eliseCrmApi/building/${e}/scheduling_status?observe_dynamic_scheduling=${i}`;try{return(await t().get(n)).data.is_enabled}catch(e){return!1}};var un=function(e,t,i,n){var r,o=arguments.length,a=o<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,i,n);else for(var s=e.length-1;s>=0;s--)(r=e[s])&&(a=(o<3?r(a):o>3?r(t,i,a):r(t,i))||a);return o>3&&a&&Object.defineProperty(t,i,a),a};let dn=class extends re{constructor(){super(...arguments),this.tourTypeOptions=[],this.chatId="",this.buildingId=0,this.buildingSlug="",this.sgtUrl="",this.selfGuidedToursTypeOffered="",this.selfGuidedTourEnabled=!1,this.escortedToursLink="",this.virtualToursLink="",this.orgSlug="",this.hasDynamicSchedulingEnabled=!1,this.leadSourceClient=null,this.buildingName="",this.tourType=null,this.shouldShowTourType={[cn.Guided]:!0,[cn.Self]:!0,[cn.Virtual]:!0},this.email="",this.phoneNumber="",this.availabilitiesGroupedByDay={},this.waitingForAvailabilities=!0,this.mobilePageIndex=0,this.isSubmitting=!1,this.tourIsBooked=!1,this.shouldAllowScheduling=!1,this.shouldAllowScheduleLoading=!0,this.promptForReschedule=!1,this.canceledReschedule=!1,this.leadSources=[],this.orgLegalName="",this.currentLeadSource="",this.featureFlagShowDropdown="",this.compactDesign=!1,this.primaryColor=Me,this.backgroundColor=Fe,this.foregroundColorOnPrimaryBackgroundColor="white",this.foregroundColorOnSecondaryBackgroundColor="black",this.firstNameInputValue="",this.lastNameInputValue="",this.leadSourceInputValue="",this.errorGettingAvailabilities=!1,this.firstUpdated=async()=>{try{const[e,t]=await Promise.all([ln(this.buildingId,this.hasDynamicSchedulingEnabled),Mi()]);this.shouldAllowScheduling=e,this.shouldAllowScheduleLoading=!1,en({logTitle:"AVAILABILITIES_EXIST_FOR_TOUR_TYPE",logData:t,logType:Zi.info,buildingSlug:this.buildingSlug,orgSlug:this.orgSlug});const i=Object.values(t).every((e=>!1===e)),n=!this.sgtUrl&&!this.escortedToursLink&&!this.virtualToursLink;if(i&&n)return this.errorGettingAvailabilities=!0,this.waitingForAvailabilities=!1,void en({logTitle:"NO_AVAILABILITIES_EXIST",logData:null,logType:Zi.warn,buildingSlug:this.buildingSlug,orgSlug:this.orgSlug});if(this.shouldShowTourType={[cn.Guided]:this.tourTypeOptions.map((e=>e.value)).includes("WITH_AGENT")&&(t[cn.Guided]||!!this.escortedToursLink),[cn.Self]:this.tourTypeOptions.map((e=>e.value)).includes("SELF_GUIDED")&&(t[cn.Self]||!!this.sgtUrl),[cn.Virtual]:this.tourTypeOptions.map((e=>e.value)).includes("VIRTUAL_SHOWING")&&(t[cn.Virtual]||!!this.virtualToursLink)},1===Object.values(this.shouldShowTourType).reduce(((e,t)=>!0===t?e+1:e),0)&&(this.tourType=Object.keys(this.shouldShowTourType).find((e=>this.shouldShowTourType[e]))),null===this.tourType)return void(this.waitingForAvailabilities=!1);this.availabilitiesGroupedByDay=await Fi(pn[this.tourType]),this.waitingForAvailabilities=!1}catch(e){this.errorGettingAvailabilities=!0,this.waitingForAvailabilities=!1,en({logTitle:"ERROR_LOADING_AVAILABILITIES",logData:{error:e},logType:Zi.error,buildingSlug:this.buildingSlug,orgSlug:this.orgSlug})}},this.willUpdate=async e=>{e.has("tourType")&&this.tourType&&(this.availabilitiesGroupedByDay=await Fi(pn[this.tourType]))},this.handlePhoneKeydown=e=>{var t;if(!(e instanceof KeyboardEvent&&e.target instanceof HTMLInputElement&&null!==e.target.selectionStart))return;const i=e.target.selectionStart;if(1!==e.key.length||Re(e)){if("Backspace"===e.key){if(Re(e))return;if(this.phoneInput.selectionEnd&&this.phoneInput.selectionStart&&this.phoneInput.selectionEnd-this.phoneInput.selectionStart>0)return;const t=this.phoneNumber.length,n=this.phoneNumber.slice(0,i).replace(/\D/g,""),r=this.phoneNumber.slice(i).replace(/\D/g,""),o=`${n.slice(0,-1)}${r}`;this.phoneNumber=Ie(o),this.phoneInput.value=this.phoneNumber;const a=i-(t-this.phoneNumber.length);return this.phoneInput.setSelectionRange(a,a),e.preventDefault(),void e.stopPropagation()}if(!["ArrowLeft","ArrowRight"].includes(e.key)||Re(e)||e.shiftKey)return;if("ArrowLeft"===e.key){const e=((null===(t=this.phoneNumber.slice(0,i).split(/\d+/).at(-1))||void 0===t?void 0:t.length)||0)+1,n=i-e>-1?i-e:0;this.phoneInput.setSelectionRange(n,n)}if("ArrowRight"===e.key){const e=(this.phoneNumber.slice(i).split(/\d+/)[0].length||0)+1,t=i+e<this.phoneNumber.length?i+e:this.phoneNumber.length;this.phoneInput.setSelectionRange(t,t)}e.preventDefault(),e.stopPropagation()}else{e.preventDefault(),e.stopPropagation();const t=this.phoneNumber.slice(0,i)+e.key+this.phoneNumber.slice(i);this.phoneNumber=Ie(t.replace(/\D/g,"")),this.phoneInput.value=this.phoneNumber}},this.handlePhoneKeyup=e=>{var t;if(!e.key)return;if(e.key.includes("Arrow")||["Meta","Shift","Control","Alt"].includes(e.key))return;const i=this.phoneInput.selectionStart,n=i?this.phoneInput.value.slice(i).replace(/\D/g,""):"";this.phoneNumber=Ie(this.phoneInput.value);let r=0,o=n.length;for(;o;)(null===(t=this.phoneNumber.at(r))||void 0===t?void 0:t.match(/\d/))&&o--,r++;const a=this.phoneInput.value.length-r+1;this.phoneInput.setSelectionRange(a,a)},this.onChangeEmail=e=>{e.target&&(this.email=e.target.value)},this.validators={tourType:()=>null!==this.tourType,dateAndTime:()=>!!this.selectedDate&&!!this.selectedTime,leadInfo:()=>{var e,t,i;return(!!(null===(e=this.firstNameInput)||void 0===e?void 0:e.value)||!!(null===(t=this.lastNameInput)||void 0===t?void 0:t.value))&&(null===(i=this.emailInput)||void 0===i?void 0:i.value.includes("@"))&&!!this.phoneNumber&&14===this.phoneNumber.length&&oi(this.phoneNumber)}},this.formIsValidForSubmission=()=>this.validators.tourType()&&this.validators.dateAndTime()&&this.validators.leadInfo(),this.timeStringToHoursAndMinutes=e=>{const[t,i]=e.split(/\D/g);return[parseInt(t)+(e.toLowerCase().includes("pm")?12:0),parseInt(i)]},this.submit=async()=>{var e,i,n,r,o,a,s,l,u,d,c,p,h,f,m;if(!this.selectedDate||!this.selectedTime||null===this.tourType)return;const g=new URLSearchParams(window.location.search);let v=null;v=this.selectedLeadSource&&this.selectedLeadSource.value&&this.selectedLeadSource.value.length>0?this.selectedLeadSource.value:this.leadSourceInputValue&&this.leadSourceInputValue.length>0?this.leadSourceInputValue:this.currentLeadSource;const y=[...new Set(v?[v,"property-website"]:["property-website"])];this.firstNameInput&&(this.firstNameInputValue=this.firstNameInput.value),this.lastNameInput&&(this.lastNameInputValue=this.lastNameInput.value),this.leadSourceInputValue=v,Wi("scheduleTourSubmitted",{email:this.email,phone:`+1${null===(e=this.phoneNumber.match(/\d/g))||void 0===e?void 0:e.join("")}`,firstName:null!==(n=null===(i=this.firstNameInput)||void 0===i?void 0:i.value)&&void 0!==n?n:this.firstNameInputValue,lastName:null!==(o=null===(r=this.lastNameInput)||void 0===r?void 0:r.value)&&void 0!==o?o:this.lastNameInputValue,tourType:hn[this.tourType],tourTime:`${this.selectedTime.datetime}${this.selectedTime.offset}`,originatingSource:y.find((e=>"property-website"!==e))||null});const b={referrer:document.referrer,email_address:this.email,phone_number:`+1${null===(a=this.phoneNumber.match(/\d/g))||void 0===a?void 0:a.join("")}`,building_id:this.buildingId,first_name:null!==(l=null===(s=this.firstNameInput)||void 0===s?void 0:s.value)&&void 0!==l?l:this.firstNameInputValue,last_name:null!==(d=null===(u=this.lastNameInput)||void 0===u?void 0:u.value)&&void 0!==d?d:this.lastNameInputValue,tour_type:hn[this.tourType],tour_time:`${this.selectedTime.datetime}${this.selectedTime.offset}`,cancel_existing_tours:this.promptForReschedule,lead_sources:[...new Set(v?[v,sn(this.orgSlug)]:[sn(this.orgSlug)])],query_params:Object.fromEntries(g.entries()),conversation_tracking_id:null===(c=this.leadSourceClient)||void 0===c?void 0:c.chatId};this.isSubmitting=!0;try{await t().post("https://app.meetelise.com/platformApi/state/create/v2/scheduleMe",b,{headers:{"building-slug":this.buildingSlug,"X-SecurityKey":"JRL8jV4VcSCwOSir5gWkpgNLfKghmhBG","org-slug":this.orgSlug}}),null===(p=this.leadSourceClient)||void 0===p||p.checkAndHandleForLogLeadSource({webchatAction:"tour-scheduler",stateId:null}),this.isSubmitting=!1,this.tourIsBooked=!0}catch(e){const t=e,i=(null===(f=null===(h=t.response)||void 0===h?void 0:h.data)||void 0===f?void 0:f.detail)||"Failed to book tour";if(t.response&&t.response.headers&&t.response.headers["funnel-prospect-conflicting-appointment-error"]){if(this.selectedDate&&this.selectedTime){const e=this.availabilitiesGroupedByDay[jt(this.selectedDate,"yyyy-MM-dd")];e&&(this.availabilitiesGroupedByDay[jt(this.selectedDate,"yyyy-MM-dd")]=e.filter((e=>e!==this.selectedTime)))}}else if(409===(null===(m=t.response)||void 0===m?void 0:m.status)&&!this.promptForReschedule)return this.promptForReschedule=!0,this.isSubmitting=!1,void(this.tourIsBooked=!1);alert(i),this.isSubmitting=!1,this.tourIsBooked=!1}},this.mobilePages=[{validate:this.validators.tourType,nextButtonText:"Next",nextButtonAction:()=>{this.mobilePageIndex++},render:()=>U`${this.tourTypeMenu()}`},{validate:this.validators.dateAndTime,nextButtonText:"Next",nextButtonAction:()=>{this.mobilePageIndex++},render:()=>U`${this.dateAndTimeMenu()}`},{validate:()=>this.validators.leadInfo(),nextButtonText:null,renderNextButton:()=>U` <action-confirm-button
|
|
954
979
|
id="schedule-bttn"
|
|
955
980
|
.onClick=${this.submit}
|
|
956
981
|
.isLoading=${this.isSubmitting}
|
|
@@ -1054,7 +1079,12 @@ xmlns="http://www.w3.org/2000/svg"
|
|
|
1054
1079
|
></time-picker>
|
|
1055
1080
|
</div>
|
|
1056
1081
|
</div>
|
|
1057
|
-
</div>`}closeButton(){return U` <button
|
|
1082
|
+
</div>`}closeButton(){return U` <button
|
|
1083
|
+
id="close-button"
|
|
1084
|
+
@click=${this.onCloseClicked}
|
|
1085
|
+
aria-label="Close"
|
|
1086
|
+
aria-describedby="close-button"
|
|
1087
|
+
>
|
|
1058
1088
|
<svg
|
|
1059
1089
|
width="19"
|
|
1060
1090
|
height="19"
|
|
@@ -2780,11 +2810,13 @@ xmlns="http://www.w3.org/2000/svg"
|
|
|
2780
2810
|
${this.renderListElement(this.hasSSTEnabled,this.onClickSSTOption,Ln("black"))}
|
|
2781
2811
|
${this.renderListElement(this.hasChatEnabled&&!this.hideChat,this.onChatTapped,qn("black"))}
|
|
2782
2812
|
${this.isMobileDesign||this.hideChat?"":U`
|
|
2783
|
-
<
|
|
2784
|
-
|
|
2785
|
-
|
|
2786
|
-
|
|
2787
|
-
|
|
2813
|
+
<li>
|
|
2814
|
+
<minimize-expand-button
|
|
2815
|
+
.onClick=${this.onClickMinimize}
|
|
2816
|
+
.primaryColor=${this.primaryColor}
|
|
2817
|
+
.toExpand=${!0}
|
|
2818
|
+
></minimize-expand-button>
|
|
2819
|
+
</li>
|
|
2788
2820
|
`}
|
|
2789
2821
|
</ul>
|
|
2790
2822
|
</div>`}};jn.styles=[Un],Jn([le({attribute:!0})],jn.prototype,"onClickMinimize",void 0),Jn([le({attribute:!0})],jn.prototype,"onClickEmailOption",void 0),Jn([le({attribute:!0})],jn.prototype,"onClickPhoneOption",void 0),Jn([le({attribute:!0})],jn.prototype,"onClickSSTOption",void 0),Jn([le({attribute:!0})],jn.prototype,"onChatTapped",void 0),Jn([le({attribute:!0})],jn.prototype,"hideChat",void 0),Jn([le({attribute:!0})],jn.prototype,"isMobileDesign",void 0),Jn([le({attribute:!0})],jn.prototype,"primaryColor",void 0),Jn([le({attribute:!0})],jn.prototype,"backgroundColor",void 0),Jn([le({attribute:!0})],jn.prototype,"hasChatEnabled",void 0),Jn([le({attribute:!0})],jn.prototype,"hasEmailEnabled",void 0),Jn([le({attribute:!0})],jn.prototype,"hasCallUsEnabled",void 0),Jn([le({attribute:!0})],jn.prototype,"hasTextUsEnabled",void 0),Jn([le({attribute:!0})],jn.prototype,"hasSSTEnabled",void 0),Jn([le({attribute:!0})],jn.prototype,"overrideRentgrata",void 0),jn=Jn([ae("mobile-launcher")],jn);const Hn=(e="white")=>B`<svg xmlns="http://www.w3.org/2000/svg" width="5" height="8" viewBox="0 0 5 8" fill="none">
|
|
@@ -4021,8 +4053,11 @@ xmlns="http://www.w3.org/2000/svg"
|
|
|
4021
4053
|
<div>
|
|
4022
4054
|
<div id="header-text">Utilities Chat</div>
|
|
4023
4055
|
</div>
|
|
4024
|
-
|
|
4025
|
-
|
|
4056
|
+
<button
|
|
4057
|
+
id="exit-chat-bttn"
|
|
4058
|
+
@click=${this.onClickExit}
|
|
4059
|
+
aria-label="Close chat"
|
|
4060
|
+
>
|
|
4026
4061
|
${Br("black")}
|
|
4027
4062
|
</button>
|
|
4028
4063
|
</div>
|
|
@@ -4133,7 +4168,11 @@ xmlns="http://www.w3.org/2000/svg"
|
|
|
4133
4168
|
</div>
|
|
4134
4169
|
</div>`:U``}
|
|
4135
4170
|
|
|
4136
|
-
<button
|
|
4171
|
+
<button
|
|
4172
|
+
id="exit-chat-bttn"
|
|
4173
|
+
@click=${this.onClickExit}
|
|
4174
|
+
aria-label="Close chat"
|
|
4175
|
+
>
|
|
4137
4176
|
${Br("black")}
|
|
4138
4177
|
</button>
|
|
4139
4178
|
</div>
|
|
@@ -4245,7 +4284,11 @@ xmlns="http://www.w3.org/2000/svg"
|
|
|
4245
4284
|
style=${Pe({background:this.primaryColor!==Me?De(this.primaryColor,.6):void 0})}
|
|
4246
4285
|
>
|
|
4247
4286
|
<div id="header-text">${this.building.name}</div>
|
|
4248
|
-
<button
|
|
4287
|
+
<button
|
|
4288
|
+
id="exit-chat-bttn"
|
|
4289
|
+
@click=${this.onClickExit}
|
|
4290
|
+
aria-label="Close chat"
|
|
4291
|
+
>
|
|
4249
4292
|
${Br("black")}
|
|
4250
4293
|
</button>
|
|
4251
4294
|
</div>
|
|
@@ -4324,6 +4367,8 @@ xmlns="http://www.w3.org/2000/svg"
|
|
|
4324
4367
|
id="send-message-bttn"
|
|
4325
4368
|
@click=${()=>this.sendMessage(this.messageInput.value)}
|
|
4326
4369
|
?disabled=${null===(o=this.myPubnub)||void 0===o?void 0:o.isCurrentlyStreamingMessage}
|
|
4370
|
+
aria-label="Send message"
|
|
4371
|
+
aria-describedby="Send message"
|
|
4327
4372
|
>
|
|
4328
4373
|
${ke(this.building.orgId,this.building.id)&&this.primaryColor!==Me?oo("black"):oo("white")}
|
|
4329
4374
|
</button>
|
|
@@ -4472,7 +4517,7 @@ xmlns="http://www.w3.org/2000/svg"
|
|
|
4472
4517
|
.onClick=${()=>{this.displayPubnubChat=!1,this.showTourNextToChat=!1,this.hideLauncher=!1,localStorage.setItem("isChatOpen","false")}}
|
|
4473
4518
|
></minimize-expand-button>
|
|
4474
4519
|
</div>`}}async handleChatInitializeAnalytics(){var e,t,i,n;this.analytics=new Yi(this.orgSlug,this.buildingSlug,null!==(t=null===(e=this.myPubnub)||void 0===e?void 0:e.channel)&&void 0!==t?t:"",null!==(n=null===(i=this.LeadSourceClient)||void 0===i?void 0:i.leadSource)&&void 0!==n?n:null),Math.random()<.05&&this.analytics.ping("webchat_heartbeat")}async restartConversation(){var e;null===(e=this.myPubnub)||void 0===e||e.handleDisconnect(),Nr(this.buildingSlug),this.myPubnub=null,this.displayPubnubChat=!1,await this.setupWebchat(),this.hideLauncher=!1}show(){this.launcher&&(this.launcher.style.display="")}hide(){this.launcher&&(this.launcher.style.display="none")}connectedCallback(){super.connectedCallback(),window.addEventListener("resize",this.adjustPositionChatAdditionalActions),window.addEventListener("keydown",this.handleKeydownTab)}getDeepActiveElement(){let e=document.activeElement,t=0;for(;(null==e?void 0:e.shadowRoot)&&(null==e?void 0:e.shadowRoot.activeElement);)if(t+=1,e=null==e?void 0:e.shadowRoot.activeElement,t>100){en({logType:Zi.error,buildingSlug:this.buildingSlug,logTitle:"[ERROR_GETTING_DEEP_ELEMENT]",logData:{message:"error getting deep active element"}});break}return e}updated(){this.adjustPositionChatAdditionalActions()}disconnectedCallback(){var e;null===(e=this.myPubnub)||void 0===e||e.handleDisconnect(),window.removeEventListener("resize",this.adjustPositionChatAdditionalActions),window.removeEventListener("keydown",this.handleKeydownTab),super.disconnectedCallback()}render(){var e,t,i,n,r,o,a,s,l,u,d,c,p,h,f,m,g,v,y,b,w,S,T,x,A,C,O,I,N,E,R,_,P,M,F;tr();const D=this.hideLauncher&&!this.isLoading&&!ii();return U`
|
|
4475
|
-
<meta name="viewport" content="width=device-width, initial-scale=1
|
|
4520
|
+
<meta name="viewport" content="width=device-width, initial-scale=1">
|
|
4476
4521
|
<div id="aria-describe-info" style="display: none;">
|
|
4477
4522
|
EliseAI widget that allows you to chat with a virtual assistant, book
|
|
4478
4523
|
a tour, contact the leasing office, and more.
|
|
@@ -21,6 +21,9 @@ export function getDefaultLeadSourceAttribution(orgSlug: string): string {
|
|
|
21
21
|
// if anything, should read from DB and give clients default ability to set this
|
|
22
22
|
return "AVB Company Website";
|
|
23
23
|
}
|
|
24
|
+
if (orgSlug === "windsor") {
|
|
25
|
+
return "Windsorcommunities.com";
|
|
26
|
+
}
|
|
24
27
|
return "property-website";
|
|
25
28
|
}
|
|
26
29
|
|
|
@@ -148,6 +148,8 @@ export class DatePicker extends LitElement {
|
|
|
148
148
|
font-size: 12px;
|
|
149
149
|
text-align: center;
|
|
150
150
|
flex: 1 1 0px;
|
|
151
|
+
border: none;
|
|
152
|
+
background: none;
|
|
151
153
|
}
|
|
152
154
|
|
|
153
155
|
.dayInitial {
|
|
@@ -267,7 +269,8 @@ export class DatePicker extends LitElement {
|
|
|
267
269
|
const hasNoAvailabilities =
|
|
268
270
|
!this.availabilities?.[dateString] ||
|
|
269
271
|
this.availabilities?.[dateString]?.length === 0;
|
|
270
|
-
return html`<
|
|
272
|
+
return html`<button
|
|
273
|
+
?disabled=${isPast || hasNoAvailabilities || isDifferentMonth}
|
|
271
274
|
class="dayNumber ${classMap({
|
|
272
275
|
past: isPast,
|
|
273
276
|
differentMonth: isDifferentMonth,
|
|
@@ -275,8 +278,9 @@ export class DatePicker extends LitElement {
|
|
|
275
278
|
selected: isSelected,
|
|
276
279
|
noAvailabilities: hasNoAvailabilities,
|
|
277
280
|
})}"
|
|
278
|
-
|
|
279
|
-
|
|
281
|
+
>
|
|
282
|
+
${dayNumber}
|
|
283
|
+
</button>`;
|
|
280
284
|
});
|
|
281
285
|
const rows = chunk(7, dayElements);
|
|
282
286
|
|
|
@@ -356,7 +360,7 @@ export class DatePicker extends LitElement {
|
|
|
356
360
|
id="rows"
|
|
357
361
|
@click="${(e: MouseEvent) => {
|
|
358
362
|
const target = e.target as HTMLElement | undefined;
|
|
359
|
-
if (target?.closest("
|
|
363
|
+
if (target?.closest("button.dayNumber:not(.differentMonth)"))
|
|
360
364
|
this.selectedDate = new Date(
|
|
361
365
|
this.yearShown,
|
|
362
366
|
this.monthShown,
|
|
@@ -787,7 +787,12 @@ export class TourScheduler extends LitElement {
|
|
|
787
787
|
}
|
|
788
788
|
|
|
789
789
|
closeButton(): TemplateResult {
|
|
790
|
-
return html` <button
|
|
790
|
+
return html` <button
|
|
791
|
+
id="close-button"
|
|
792
|
+
@click=${this.onCloseClicked}
|
|
793
|
+
aria-label="Close"
|
|
794
|
+
aria-describedby="close-button"
|
|
795
|
+
>
|
|
791
796
|
<svg
|
|
792
797
|
width="19"
|
|
793
798
|
height="19"
|
|
@@ -115,11 +115,13 @@ export class MobileLauncher extends LitElement {
|
|
|
115
115
|
)}
|
|
116
116
|
${!this.isMobileDesign && !this.hideChat
|
|
117
117
|
? html`
|
|
118
|
-
<
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
118
|
+
<li>
|
|
119
|
+
<minimize-expand-button
|
|
120
|
+
.onClick=${this.onClickMinimize}
|
|
121
|
+
.primaryColor=${this.primaryColor}
|
|
122
|
+
.toExpand=${true}
|
|
123
|
+
></minimize-expand-button>
|
|
124
|
+
</li>
|
|
123
125
|
`
|
|
124
126
|
: ""}
|
|
125
127
|
</ul>
|
|
@@ -867,7 +867,7 @@ export class MEChat extends LitElement {
|
|
|
867
867
|
this.hideLauncher && !this.isLoading && !isMobile();
|
|
868
868
|
|
|
869
869
|
return html`
|
|
870
|
-
<meta name="viewport" content="width=device-width, initial-scale=1
|
|
870
|
+
<meta name="viewport" content="width=device-width, initial-scale=1">
|
|
871
871
|
<div id="aria-describe-info" style="display: none;">
|
|
872
872
|
EliseAI widget that allows you to chat with a virtual assistant, book
|
|
873
873
|
a tour, contact the leasing office, and more.
|
|
@@ -108,6 +108,20 @@ export class MESelect extends LitElement {
|
|
|
108
108
|
--light-border: 1px solid $light-border-color;
|
|
109
109
|
}
|
|
110
110
|
|
|
111
|
+
#selectText {
|
|
112
|
+
background-color: transparent;
|
|
113
|
+
border: none;
|
|
114
|
+
outline: none;
|
|
115
|
+
font-size: 14px;
|
|
116
|
+
line-height: 14px;
|
|
117
|
+
font-family: "Helvetica Neue", Arial;
|
|
118
|
+
width: 100%;
|
|
119
|
+
padding: 0;
|
|
120
|
+
height: 14px;
|
|
121
|
+
display: flex;
|
|
122
|
+
align-items: center;
|
|
123
|
+
}
|
|
124
|
+
|
|
111
125
|
ul {
|
|
112
126
|
padding-left: 0;
|
|
113
127
|
margin-bottom: 0;
|
|
@@ -141,10 +155,10 @@ export class MESelect extends LitElement {
|
|
|
141
155
|
align-items: center;
|
|
142
156
|
justify-content: space-between;
|
|
143
157
|
color: rgba(32, 32, 32, 0.5);
|
|
144
|
-
|
|
145
158
|
white-space: nowrap;
|
|
146
159
|
overflow: hidden;
|
|
147
160
|
text-overflow: ellipsis;
|
|
161
|
+
height: 30px;
|
|
148
162
|
}
|
|
149
163
|
|
|
150
164
|
::-webkit-scrollbar {
|
|
@@ -249,10 +263,21 @@ export class MESelect extends LitElement {
|
|
|
249
263
|
}
|
|
250
264
|
}}"
|
|
251
265
|
>
|
|
252
|
-
|
|
253
|
-
|
|
254
|
-
|
|
255
|
-
|
|
266
|
+
${this.options.find((o) => o.value === this.value)?.label
|
|
267
|
+
? html` <span id="selectText"
|
|
268
|
+
>${this.options.find((o) => o.value === this.value)?.label ??
|
|
269
|
+
this.placeholder}</span
|
|
270
|
+
>`
|
|
271
|
+
: html` <input
|
|
272
|
+
readonly
|
|
273
|
+
placeholder="${this.placeholder}"
|
|
274
|
+
.value="${this.options.find((o) => o.value === this.value)
|
|
275
|
+
?.label ||
|
|
276
|
+
this.value ||
|
|
277
|
+
""}"
|
|
278
|
+
id="selectText"
|
|
279
|
+
/>`}
|
|
280
|
+
|
|
256
281
|
<svg
|
|
257
282
|
width="10"
|
|
258
283
|
height="6"
|
|
@@ -284,6 +309,7 @@ export class MESelect extends LitElement {
|
|
|
284
309
|
class="option ${classMap({
|
|
285
310
|
active: this.activeOption === option,
|
|
286
311
|
})}"
|
|
312
|
+
tabindex="0"
|
|
287
313
|
>
|
|
288
314
|
${option.label}
|
|
289
315
|
</li>`
|
|
@@ -266,8 +266,11 @@ export class PubnubChat extends LitElement {
|
|
|
266
266
|
<div>
|
|
267
267
|
<div id="header-text">Utilities Chat</div>
|
|
268
268
|
</div>
|
|
269
|
-
|
|
270
|
-
|
|
269
|
+
<button
|
|
270
|
+
id="exit-chat-bttn"
|
|
271
|
+
@click=${this.onClickExit}
|
|
272
|
+
aria-label="Close chat"
|
|
273
|
+
>
|
|
271
274
|
${XOutlineIcon("black")}
|
|
272
275
|
</button>
|
|
273
276
|
</div>
|
|
@@ -428,7 +431,11 @@ export class PubnubChat extends LitElement {
|
|
|
428
431
|
</div>`
|
|
429
432
|
: html``}
|
|
430
433
|
|
|
431
|
-
<button
|
|
434
|
+
<button
|
|
435
|
+
id="exit-chat-bttn"
|
|
436
|
+
@click=${this.onClickExit}
|
|
437
|
+
aria-label="Close chat"
|
|
438
|
+
>
|
|
432
439
|
${XOutlineIcon("black")}
|
|
433
440
|
</button>
|
|
434
441
|
</div>
|
|
@@ -599,7 +606,11 @@ export class PubnubChat extends LitElement {
|
|
|
599
606
|
})}
|
|
600
607
|
>
|
|
601
608
|
<div id="header-text">${this.building.name}</div>
|
|
602
|
-
<button
|
|
609
|
+
<button
|
|
610
|
+
id="exit-chat-bttn"
|
|
611
|
+
@click=${this.onClickExit}
|
|
612
|
+
aria-label="Close chat"
|
|
613
|
+
>
|
|
603
614
|
${XOutlineIcon("black")}
|
|
604
615
|
</button>
|
|
605
616
|
</div>
|
|
@@ -749,6 +760,8 @@ export class PubnubChat extends LitElement {
|
|
|
749
760
|
id="send-message-bttn"
|
|
750
761
|
@click=${() => this.sendMessage(this.messageInput.value)}
|
|
751
762
|
?disabled=${this.myPubnub?.isCurrentlyStreamingMessage}
|
|
763
|
+
aria-label="Send message"
|
|
764
|
+
aria-describedby="Send message"
|
|
752
765
|
>
|
|
753
766
|
${shouldUsePrimaryColorForChatFooter(
|
|
754
767
|
this.building.orgId,
|