favesalon-embed 1.0.4 → 1.0.5

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.
Files changed (177) hide show
  1. package/dist/custom-elements/index.d.ts +6 -0
  2. package/dist/{cjs/_commonjsHelpers-5cfcba41.js → favesalon-embed/_commonjsHelpers-a4f66ccd.js} +14 -6
  3. package/dist/favesalon-embed/app-globals-74127f4b.js +7 -0
  4. package/dist/favesalon-embed/chat-box.entry.js +55 -0
  5. package/dist/{esm → favesalon-embed}/chat-button.entry.js +4 -4
  6. package/dist/favesalon-embed/chat-form.entry.js +39 -0
  7. package/dist/favesalon-embed/chat-messages.entry.js +71 -0
  8. package/dist/favesalon-embed/chat-rooms.entry.js +111 -0
  9. package/dist/favesalon-embed/css-shim-b7d3d95f.js +4 -0
  10. package/dist/favesalon-embed/dom-64053c71.js +73 -0
  11. package/dist/favesalon-embed/favesalon-embed.css +114 -1
  12. package/dist/favesalon-embed/favesalon-embed.esm.js +148 -1
  13. package/dist/{esm → favesalon-embed}/google-map.entry.js +1 -1
  14. package/dist/{esm/index-a1c7583c.js → favesalon-embed/index-00b83e1c.js} +425 -15
  15. package/dist/favesalon-embed/index-888e99e3.js +3371 -0
  16. package/dist/favesalon-embed/index.esm.js +1 -0
  17. package/dist/{esm/chat-box_5.entry.js → favesalon-embed/lodash-d5526b38.js} +27 -243
  18. package/dist/{cjs/chat-button.cjs.entry.js → favesalon-embed/notify-sounds.entry.js} +20 -44
  19. package/dist/favesalon-embed/relativeTime-268e64b0.js +7 -0
  20. package/dist/{esm → favesalon-embed}/salon-booking-modal.entry.js +1 -1
  21. package/dist/{esm → favesalon-embed}/salon-booking.entry.js +3 -3
  22. package/dist/{esm → favesalon-embed}/salon-gift-card-modal.entry.js +1 -1
  23. package/dist/{esm → favesalon-embed}/salon-gift-card.entry.js +3 -3
  24. package/dist/{esm → favesalon-embed}/salon-info.entry.js +3 -3
  25. package/dist/{esm → favesalon-embed}/salon-latest-reviews.entry.js +4 -4
  26. package/dist/{collection/components/salon-latest-styles/index.js → favesalon-embed/salon-latest-styles.entry.js} +14 -99
  27. package/dist/{collection/components/salon-locations/index.js → favesalon-embed/salon-locations.entry.js} +15 -95
  28. package/dist/{esm → favesalon-embed}/salon-lookbook.entry.js +3 -3
  29. package/dist/{esm → favesalon-embed}/salon-ranking.entry.js +1 -1
  30. package/dist/{esm → favesalon-embed}/salon-reviews.entry.js +3 -3
  31. package/dist/{collection/components/salon-schedules/index.js → favesalon-embed/salon-schedules.entry.js} +14 -95
  32. package/dist/{esm → favesalon-embed}/salon-services.entry.js +3 -3
  33. package/dist/{esm → favesalon-embed}/salon-stylists.entry.js +3 -3
  34. package/dist/favesalon-embed/services-122dcf73.js +23886 -0
  35. package/dist/{cjs/services-d1bdf299.js → favesalon-embed/services-23eda072.js} +2487 -104
  36. package/dist/favesalon-embed/services-243eef47.js +23880 -0
  37. package/dist/favesalon-embed/services-260ea6eb.js +23883 -0
  38. package/dist/favesalon-embed/services-27607998.js +23886 -0
  39. package/dist/{esm/services-257442e2.js → favesalon-embed/services-46b2f0aa.js} +2482 -101
  40. package/dist/favesalon-embed/services-65a8cf4a.js +23887 -0
  41. package/dist/favesalon-embed/services-8f52210f.js +23880 -0
  42. package/dist/favesalon-embed/services-de32365e.js +23880 -0
  43. package/dist/favesalon-embed/services-e9cfcd2b.js +23885 -0
  44. package/dist/favesalon-embed/services-f7278483.js +23880 -0
  45. package/dist/favesalon-embed/services-f9872bea.js +23880 -0
  46. package/dist/favesalon-embed/shadow-css-98135883.js +387 -0
  47. package/dist/{esm → favesalon-embed}/style-detail.entry.js +4 -4
  48. package/dist/favesalon-embed/user-avatar.entry.js +50 -0
  49. package/dist/{esm/utils-e97485e0.js → favesalon-embed/utils-2c19db45.js} +6 -0
  50. package/dist/{collection/utils/utils.js → favesalon-embed/utils-89c2cff2.js} +14 -5
  51. package/dist/{cjs/utils-c5a33b3c.js → favesalon-embed/utils-e226fa04.js} +14 -5
  52. package/dist/favesalon-embed/utils-fd30fb29.js +32 -0
  53. package/dist/types/components/chat-box/index.d.ts +1 -0
  54. package/dist/types/components/chat-button/notify-sounds.d.ts +5 -0
  55. package/dist/types/components/chat-rooms/index.d.ts +6 -0
  56. package/dist/types/components.d.ts +21 -0
  57. package/dist/types/services/services.d.ts +1 -0
  58. package/dist/types/types/chat.d.ts +1 -0
  59. package/dist/types/types/user.d.ts +10 -0
  60. package/dist/types/utils/utils.d.ts +1 -0
  61. package/package.json +1 -1
  62. package/dist/cjs/chat-box_5.cjs.entry.js +0 -17439
  63. package/dist/cjs/colors-38421769.js +0 -69
  64. package/dist/cjs/favesalon-embed.cjs.js +0 -23
  65. package/dist/cjs/google-map.cjs.entry.js +0 -52
  66. package/dist/cjs/index-7f190886.js +0 -4396
  67. package/dist/cjs/index-dd8176c4.js +0 -1531
  68. package/dist/cjs/index.cjs.js +0 -2
  69. package/dist/cjs/loader.cjs.js +0 -22
  70. package/dist/cjs/relativeTime-3721080d.js +0 -9
  71. package/dist/cjs/salon-booking-modal.cjs.entry.js +0 -30
  72. package/dist/cjs/salon-booking.cjs.entry.js +0 -51
  73. package/dist/cjs/salon-gift-card-modal.cjs.entry.js +0 -29
  74. package/dist/cjs/salon-gift-card.cjs.entry.js +0 -51
  75. package/dist/cjs/salon-info.cjs.entry.js +0 -33
  76. package/dist/cjs/salon-latest-reviews.cjs.entry.js +0 -97
  77. package/dist/cjs/salon-latest-styles_3.cjs.entry.js +0 -241
  78. package/dist/cjs/salon-lookbook.cjs.entry.js +0 -222
  79. package/dist/cjs/salon-ranking.cjs.entry.js +0 -60
  80. package/dist/cjs/salon-reviews.cjs.entry.js +0 -193
  81. package/dist/cjs/salon-services.cjs.entry.js +0 -81
  82. package/dist/cjs/salon-stylists.cjs.entry.js +0 -118
  83. package/dist/cjs/style-detail.cjs.entry.js +0 -312
  84. package/dist/collection/collection-manifest.json +0 -33
  85. package/dist/collection/components/chat-box/index.css +0 -105
  86. package/dist/collection/components/chat-box/index.js +0 -138
  87. package/dist/collection/components/chat-button/index.css +0 -101
  88. package/dist/collection/components/chat-button/index.js +0 -155
  89. package/dist/collection/components/chat-form/index.css +0 -40
  90. package/dist/collection/components/chat-form/index.js +0 -79
  91. package/dist/collection/components/chat-messages/index.css +0 -48
  92. package/dist/collection/components/chat-messages/index.js +0 -142
  93. package/dist/collection/components/chat-rooms/index.css +0 -102
  94. package/dist/collection/components/chat-rooms/index.js +0 -157
  95. package/dist/collection/components/google-map/assets/map--placeholder.jpeg +0 -0
  96. package/dist/collection/components/google-map/index.css +0 -5
  97. package/dist/collection/components/google-map/index.js +0 -90
  98. package/dist/collection/components/salon-booking/index.css +0 -30
  99. package/dist/collection/components/salon-booking/index.js +0 -126
  100. package/dist/collection/components/salon-booking/salon-booking-modal.js +0 -92
  101. package/dist/collection/components/salon-gift-card/index.css +0 -30
  102. package/dist/collection/components/salon-gift-card/index.js +0 -126
  103. package/dist/collection/components/salon-gift-card/salon-gift-card-modal.js +0 -73
  104. package/dist/collection/components/salon-info/index.css +0 -1
  105. package/dist/collection/components/salon-info/index.js +0 -77
  106. package/dist/collection/components/salon-latest-reviews/index.css +0 -11
  107. package/dist/collection/components/salon-latest-reviews/index.js +0 -163
  108. package/dist/collection/components/salon-latest-styles/index.css +0 -12
  109. package/dist/collection/components/salon-locations/index.css +0 -24
  110. package/dist/collection/components/salon-lookbook/index.css +0 -15
  111. package/dist/collection/components/salon-lookbook/index.js +0 -368
  112. package/dist/collection/components/salon-ranking/index.css +0 -3
  113. package/dist/collection/components/salon-ranking/index.js +0 -117
  114. package/dist/collection/components/salon-reviews/index.css +0 -18
  115. package/dist/collection/components/salon-reviews/index.js +0 -249
  116. package/dist/collection/components/salon-schedules/index.css +0 -18
  117. package/dist/collection/components/salon-services/index.css +0 -1
  118. package/dist/collection/components/salon-services/index.js +0 -146
  119. package/dist/collection/components/salon-stylists/index.css +0 -43
  120. package/dist/collection/components/salon-stylists/index.js +0 -184
  121. package/dist/collection/components/style-detail/index.css +0 -76
  122. package/dist/collection/components/style-detail/index.js +0 -386
  123. package/dist/collection/components/user-avatar/index.css +0 -0
  124. package/dist/collection/components/user-avatar/index.js +0 -159
  125. package/dist/collection/constants/colors.js +0 -65
  126. package/dist/collection/global/global.js +0 -0
  127. package/dist/collection/index.js +0 -1
  128. package/dist/collection/mocks/users.js +0 -10
  129. package/dist/collection/services/services.js +0 -295
  130. package/dist/collection/types/chat.js +0 -23
  131. package/dist/collection/types/common.js +0 -11
  132. package/dist/collection/types/review.js +0 -39
  133. package/dist/collection/types/salon.js +0 -58
  134. package/dist/collection/types/service.js +0 -24
  135. package/dist/collection/types/style.js +0 -128
  136. package/dist/collection/types/stylist.js +0 -30
  137. package/dist/collection/types/user.js +0 -10
  138. package/dist/custom-elements/index.js +0 -44974
  139. package/dist/esm/_commonjsHelpers-66ac50f5.js +0 -32
  140. package/dist/esm/favesalon-embed.js +0 -18
  141. package/dist/esm/index-0494771f.js +0 -1504
  142. package/dist/esm/index.js +0 -1
  143. package/dist/esm/loader.js +0 -18
  144. package/dist/esm/polyfills/core-js.js +0 -11
  145. package/dist/esm/polyfills/css-shim.js +0 -1
  146. package/dist/esm/polyfills/dom.js +0 -79
  147. package/dist/esm/polyfills/es5-html-element.js +0 -1
  148. package/dist/esm/polyfills/index.js +0 -34
  149. package/dist/esm/polyfills/system.js +0 -6
  150. package/dist/esm/relativeTime-baa50aa2.js +0 -7
  151. package/dist/esm/salon-latest-styles_3.entry.js +0 -235
  152. package/dist/favesalon-embed/p-05a1c88a.entry.js +0 -1
  153. package/dist/favesalon-embed/p-0acf0447.entry.js +0 -1
  154. package/dist/favesalon-embed/p-0bc4f624.js +0 -1
  155. package/dist/favesalon-embed/p-1af1515f.entry.js +0 -1
  156. package/dist/favesalon-embed/p-1cba5fc9.entry.js +0 -1
  157. package/dist/favesalon-embed/p-39a4ef15.entry.js +0 -1
  158. package/dist/favesalon-embed/p-3e2cb05b.entry.js +0 -1
  159. package/dist/favesalon-embed/p-47e646f8.js +0 -1
  160. package/dist/favesalon-embed/p-487b311f.entry.js +0 -1
  161. package/dist/favesalon-embed/p-55387c2f.entry.js +0 -1
  162. package/dist/favesalon-embed/p-566f05b4.entry.js +0 -1
  163. package/dist/favesalon-embed/p-862a0de0.entry.js +0 -1
  164. package/dist/favesalon-embed/p-9fe0cbeb.js +0 -2
  165. package/dist/favesalon-embed/p-a33331cc.js +0 -1
  166. package/dist/favesalon-embed/p-aeeb7b5f.entry.js +0 -1
  167. package/dist/favesalon-embed/p-b08e5b54.js +0 -6
  168. package/dist/favesalon-embed/p-b5cca5fc.entry.js +0 -1
  169. package/dist/favesalon-embed/p-c7fb7af5.js +0 -1580
  170. package/dist/favesalon-embed/p-ccab56d8.js +0 -1
  171. package/dist/favesalon-embed/p-d6e13053.entry.js +0 -1
  172. package/dist/favesalon-embed/p-dee42d34.entry.js +0 -1
  173. package/dist/favesalon-embed/p-e661ca1d.entry.js +0 -1
  174. package/dist/favesalon-embed/p-eeceab9c.entry.js +0 -1
  175. package/dist/index.cjs.js +0 -1
  176. package/dist/index.js +0 -1
  177. /package/dist/{esm → favesalon-embed}/colors-ea36347a.js +0 -0
@@ -0,0 +1 @@
1
+
@@ -1,138 +1,15 @@
1
- import { r as registerInstance, h } from './index-0494771f.js';
2
- import { C as Colors } from './colors-ea36347a.js';
3
- import { H as HttpService, d as dayjs_min, a as dateFormat } from './services-257442e2.js';
4
- import { r as relativeTime } from './relativeTime-baa50aa2.js';
5
- import { c as createCommonjsModule, a as commonjsGlobal } from './_commonjsHelpers-66ac50f5.js';
6
-
7
- const indexCss$4 = ".chat-widget,.chat-widget--sidebar,.chat-widget--content{display:flex;height:100%;width:100%}.chat-widget{font-size:16px;position:relative;font-family:'Roboto', sans-serif;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale}.chat-widget--sidebar,.chat-widget--content{background-color:#fff;border:1px solid #EFEFEF;position:absolute;inset:0;flex-direction:column}.chat-widget .chat-widget--sidebar{z-index:10}.chat-widget .chat-widget--content{z-index:5}.chat-widget.has-chat-room .chat-widget--content{z-index:10}.chat-widget--content-header{background-color:#001529;border-bottom:1px solid #EFEFEF;display:flex;align-items:center;justify-content:space-between;padding:16px}.chat-widget--content-title{font-size:20px;font-weight:600;line-height:1;margin:0}.chat-widget--content-close{border:1px solid #fff;cursor:pointer;display:block;position:absolute;z-index:1000;top:50%;right:0;width:30px;height:30px;transform:translate(0, -50%);-moz-border-radius:30px;-webkit-border-radius:30px;border-radius:30px;background-size:contain;background-repeat:no-repeat;background-position:center center;background-image:url('data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAADwAAAA8CAYAAAA6/NlyAAAAAXNSR0IArs4c6QAAA3hJREFUaAXlm8+K00Acx7MiCIJH/yw+gA9g25O49SL4AO3Bp1jw5NvktC+wF88qevK4BU97EmzxUBCEolK/n5gp3W6TTJPfpNPNF37MNsl85/vN/DaTmU6PknC4K+pniqeKJ3k8UnkvDxXJzzy+q/yaxxeVHxW/FNHjgRSeKt4rFoplzaAuHHDBGR2eS9G54reirsmienDCTRt7xwsp+KAoEmt9nLaGitZxrBbPFNaGfPloGw2t4JVamSt8xYW6Dg1oCYo3Yv+rCGViV160oMkcd8SYKnYV1Nb1aEOjCe6L5ZOiLfF120EjWhuBu3YIZt1NQmujnk5F4MgOpURzLfAwOBSTmzp3fpDxuI/pabxpqOoz2r2HLAb0GMbZKlNV5/Hg9XJypguryA7lPF5KMdTZQzHjqxNPhWhzIuAruOl1eNqKEx1tSh5rfbxdw7mOxCq4qS68ZTjKS1YVvilu559vWvFHhh4rZrdyZ69Vmpgdj8fJbDZLJpNJ0uv1cnr/gjrUhQMuI+ANjyuwftQ0bbL6Erp0mM/ny8Fg4M3LtdRxgMtKl3jwmIHVxYXChFy94/Rmpa/pTbNUhstKV+4Rr8lLQ9KlUvJKLyG8yvQ2s9SBy1Jb7jV5a0yapfF6apaZLjLLcWtd4sNrmJUMHyM+1xibTjH82Zh01TNlhsrOhdKTe00uAzZQmN6+KW+sDa/JD2PSVQ873m29yf+1Q9VDzfEYlHi1G5LKBBWZbtEsHbFwb1oYDwr1ZiF/2bnCSg1OBE/pfr9/bWx26UxJL3ONPISOLKUvQza0LZUxSKyjpdTGa/vDEr25rddbMM0Q3O6Lx3rqFvU+x6UrRKQY7tyrZecmD9FODy8uLizTmilwNj0kraNcAJhOp5aGVwsAGD5VmJBrWWbJSgWT9zrzWepQF47RaGSiKfeGx6Szi3gzmX/HHbihwBser4B9UJYpFBNX4R6vTn3VQnez0SymnrHQMsRYGTr1dSk34ljRqS/EMd2pLQ8YBp3a1PLfcqCpo8gtHkZFHKkTX6fs3MY0blKnth66rKCnU0VRGu37ONrQaA4eZDFtWAu2fXj9zjFkxTBOo8F7t926gTp/83Kyzzcy2kZD6xiqxTYnHLRFm3vHiRSwNSjkz3hoIzo8lCKWUlg/YtGs7tObunDAZfpDLbfEI15zsEIY3U/x/gHHc/G1zltnAgAAAABJRU5ErkJggg==')}@media (min-width: 992px){.chat-widget--sidebar,.chat-widget--content{position:static;width:auto;-moz-border-radius:8px;-webkit-border-radius:8px;border-radius:8px}.chat-widget--sidebar{min-width:320px;max-width:320px;margin-right:24px}.chat-widget--content{flex-grow:1;flex-shrink:1}.chat-rooms--search,.chat-widget--content-header{-moz-border-radius:8px 8px 0 0;-webkit-border-radius:8px 8px 0 0;border-radius:8px 8px 0 0}}";
8
-
9
- const ChatBox = class {
10
- constructor(hostRef) {
11
- registerInstance(this, hostRef);
12
- this.onClickRoom = (chatRoom) => {
13
- this.activeRoom = chatRoom;
14
- };
15
- this.primaryColor = undefined;
16
- this.accessToken = undefined;
17
- this.senderId = undefined;
18
- this.chatRooms = undefined;
19
- this.activeRoom = undefined;
20
- }
21
- componentWillLoad() {
22
- this.fetchData();
23
- }
24
- async fetchData() {
25
- try {
26
- this.chatRooms = await HttpService().fetchChatRooms(this.accessToken);
27
- (this.chatRooms || []).forEach((chatRoom) => {
28
- HttpService().fetchChatMessages(chatRoom.uid, (messages) => {
29
- this.chatRooms = [...(this.chatRooms || [])].map((room) => {
30
- if (chatRoom.uid === room.uid) {
31
- room.messages = messages;
32
- }
33
- return room;
34
- });
35
- });
36
- });
37
- }
38
- catch (e) {
39
- this.chatRooms = [];
40
- }
41
- }
42
- render() {
43
- const senderInfo = this.activeRoom ? (this.activeRoom.members || []).find(user => user.id === Number(this.senderId)) : null;
44
- const receiverInfo = this.activeRoom ? (this.activeRoom.members || []).find(user => user.id !== Number(this.senderId)) : null;
45
- return (h("div", { class: `chat-widget ${this.activeRoom ? 'has-chat-room' : ''}` }, h("div", { class: "chat-widget--sidebar" }, h("chat-rooms", { "sender-id": Number(this.senderId), activeRoom: this.activeRoom, chatRooms: this.chatRooms, onClickRoom: this.onClickRoom })), h("div", { class: "chat-widget--content" }, receiverInfo && (h("div", { class: "chat-widget--content-header" }, h("user-avatar", { size: 40, avatar: receiverInfo.avatar, name: h("div", { class: "chat-room--user-name", style: { color: '#fff' } }, receiverInfo.fullName), shortName: String(receiverInfo.fullName || '').charAt(0) }), h("div", { style: { position: 'relative' } }, h("div", { class: "chat-widget--content-close", onClick: () => this.onClickRoom(null) })))), h("div", { style: {
46
- flexShrink: '1',
47
- flexGrow: '1',
48
- overflowY: 'auto',
49
- padding: '16px',
50
- } }, this.activeRoom && (h("chat-messages", { sender: senderInfo, receiver: receiverInfo, messages: this.activeRoom.messages || [], "chat-room-id": this.activeRoom.uid })), !this.activeRoom && (h("div", { style: { paddingTop: '72px', textAlign: 'center' } }, h("div", { class: "chat-widget--content-title" }, "Welcome back!"), h("div", { style: { marginTop: "12px" } }, "Select any user in left hand side to get started.")))), this.activeRoom && (h("div", { style: { borderTop: `1px solid ${Colors.Gray02}` } }, h("chat-form", { "sender-id": Number(senderInfo.id), "chat-room-id": this.activeRoom.uid }))))));
51
- }
52
- };
53
- ChatBox.style = indexCss$4;
54
-
55
- const indexCss$3 = ".chat-form{display:flex;height:56px;width:100%}.chat-form #chat-form--input{border:none;outline:none;flex-shrink:1;flex-grow:1;height:100%;font-size:16px;padding-left:16px;padding-right:16px;-moz-border-radius:6px;-webkit-border-radius:6px;border-radius:6px}.chat-form>button{background-color:#001529;border:none;color:#fff;cursor:pointer;font-size:16px;min-width:80px;height:42px;margin:7px;-moz-border-radius:4px;-webkit-border-radius:4px;border-radius:4px}.chat-form>button:hover,.chat-form>button:focus,.chat-form>button:active{background-color:#001529}";
56
-
57
- const ChatForm = class {
58
- constructor(hostRef) {
59
- registerInstance(this, hostRef);
60
- this.onSubmitMessage = async () => {
61
- try {
62
- const elNewMessage = document.getElementById('chat-form--input');
63
- if (!!elNewMessage.value) {
64
- await HttpService().sendChatMessage({
65
- message: elNewMessage.value,
66
- senderId: this.senderId,
67
- chatRoomId: this.chatRoomId,
68
- });
69
- elNewMessage.value = '';
70
- }
71
- }
72
- catch (error) { }
73
- };
74
- this.senderId = undefined;
75
- this.chatRoomId = undefined;
76
- }
77
- render() {
78
- return (h("div", { class: "chat-form" }, h("input", { id: "chat-form--input", type: "text", placeholder: "Enter a message...", onKeyPress: (evt) => {
79
- if (evt.key === 'Enter') {
80
- evt.preventDefault();
81
- this.onSubmitMessage();
82
- }
83
- } }), h("button", { type: "button", onClick: () => this.onSubmitMessage() }, "Send")));
84
- }
85
- };
86
- ChatForm.style = indexCss$3;
87
-
88
- const indexCss$2 = ".chat-message{overflow:hidden;clear:both;min-width:240px}.chat-message+.chat-message{margin-top:6px}.chat-message--meta{display:flex}.chat-message--title{background-color:#F1F1F1;padding:8px 12px;position:relative;float:left;margin-top:6px;-moz-border-radius:0 10px 10px 10px;-webkit-border-radius:0 10px 10px 10px;border-radius:0 10px 10px 10px}.chat-message--time{clear:both;color:#999;font-size:75%;padding-top:2px}.chat-message.is-owner .chat-message--content{margin-left:12px}.chat-message.is-guest .chat-message--meta{flex-direction:row-reverse}.chat-message.is-guest .chat-message--title{background-color:#EFF7FF;float:right;margin-right:12px;text-align:right;-moz-border-radius:10px 0 10px 10px;-webkit-border-radius:10px 0 10px 10px;border-radius:10px 0 10px 10px}";
89
-
90
- dayjs_min.extend(relativeTime);
91
- const ChatMessages = class {
92
- constructor(hostRef) {
93
- registerInstance(this, hostRef);
94
- this.markMessagesAsRead = async () => {
95
- try {
96
- const unreadMessages = (this.messages || []).filter(message => {
97
- return Boolean(message.unRead) && message.senderId !== this.sender.id;
98
- });
99
- if (unreadMessages.length > 0) {
100
- await HttpService().markMessagesAsRead(this.chatRoomId, unreadMessages);
101
- }
102
- }
103
- catch (e) { }
104
- };
105
- this.scrollToLastMessage = () => {
106
- const targetElement = document.getElementById('chat--last-message');
107
- targetElement && targetElement.scrollIntoView();
108
- };
109
- this.renderMessage = (chatMessage) => {
110
- const { message, senderId, timestamp } = chatMessage;
111
- const isOwner = this.sender.id === senderId;
112
- const todayStr = dayjs_min().format(dateFormat);
113
- const messageDayStr = dayjs_min(timestamp).format(dateFormat);
114
- return (h("div", { class: `chat-message ${isOwner ? 'is-owner' : 'is-guest'}` }, h("div", { class: "chat-message--meta" }, h("user-avatar", { size: 40, shortName: String(((isOwner ? this.sender : this.receiver) || {}).fullName || '').charAt(0), avatar: ((isOwner ? this.sender : this.receiver) || {}).avatar }), h("div", { class: "chat-message--content" }, h("div", { class: "chat-message--title" }, message), timestamp && (h("div", { class: "chat-message--time" }, todayStr === messageDayStr ? dayjs_min(timestamp).format('HH:mm') : dayjs_min(timestamp).fromNow()))))));
115
- };
116
- this.sender = {};
117
- this.receiver = {};
118
- this.messages = [];
119
- this.chatRoomId = undefined;
120
- }
121
- componentDidLoad() {
122
- this.markMessagesAsRead();
123
- }
124
- componentDidUpdate() {
125
- this.scrollToLastMessage();
126
- }
127
- render() {
128
- const isEmpty = (this.messages || []).length === 0;
129
- return (h("div", { class: "chat-messages" }, !isEmpty && this.messages.map(this.renderMessage), isEmpty && (h("div", { style: { padding: '48px', textAlign: 'center' } }, h("div", { style: { color: Colors.Green04 } }, "No messages yet"))), h("div", { id: "chat--last-message" })));
130
- }
131
- };
132
- ChatMessages.style = indexCss$2;
1
+ import { a as createCommonjsModule, c as commonjsGlobal } from './_commonjsHelpers-a4f66ccd.js';
133
2
 
134
3
  var lodash = createCommonjsModule(function (module, exports) {
135
- (function() {
4
+ /**
5
+ * @license
6
+ * Lodash <https://lodash.com/>
7
+ * Copyright OpenJS Foundation and other contributors <https://openjsf.org/>
8
+ * Released under MIT license <https://lodash.com/license>
9
+ * Based on Underscore.js 1.8.3 <http://underscorejs.org/LICENSE>
10
+ * Copyright Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors
11
+ */
12
+ ;(function() {
136
13
 
137
14
  /** Used as a safe reference for `undefined` in pre-ES5 environments. */
138
15
  var undefined$1;
@@ -562,7 +439,7 @@ var lodash = createCommonjsModule(function (module, exports) {
562
439
  var root = freeGlobal || freeSelf || Function('return this')();
563
440
 
564
441
  /** Detect free variable `exports`. */
565
- var freeExports = exports && !exports.nodeType && exports;
442
+ var freeExports = 'object' == 'object' && exports && !exports.nodeType && exports;
566
443
 
567
444
  /** Detect free variable `module`. */
568
445
  var freeModule = freeExports && 'object' == 'object' && module && !module.nodeType && module;
@@ -17308,7 +17185,21 @@ var lodash = createCommonjsModule(function (module, exports) {
17308
17185
  var _ = runInContext();
17309
17186
 
17310
17187
  // Some AMD build optimizers, like r.js, check for condition patterns like:
17311
- if (freeModule) {
17188
+ if (typeof undefined$1 == 'function' && typeof undefined$1.amd == 'object' && undefined$1.amd) {
17189
+ // Expose Lodash on the global object to prevent errors when Lodash is
17190
+ // loaded by a script tag in the presence of an AMD loader.
17191
+ // See http://requirejs.org/docs/errors.html#mismatch for more details.
17192
+ // Use `_.noConflict` to remove Lodash from the global object.
17193
+ root._ = _;
17194
+
17195
+ // Define as an anonymous module so, through path mapping, it can be
17196
+ // referenced as the "underscore" module.
17197
+ undefined$1(function() {
17198
+ return _;
17199
+ });
17200
+ }
17201
+ // Check for `exports` after `define` in case a build optimizer adds it.
17202
+ else if (freeModule) {
17312
17203
  // Export for Node.js.
17313
17204
  (freeModule.exports = _)._ = _;
17314
17205
  // Export for CommonJS support.
@@ -17321,111 +17212,4 @@ var lodash = createCommonjsModule(function (module, exports) {
17321
17212
  }.call(commonjsGlobal));
17322
17213
  });
17323
17214
 
17324
- const indexCss$1 = "chat-rooms,.chat-rooms{display:flex;flex-direction:column;height:100%;width:100%}.chat-rooms--search{background-color:#001529;border-bottom:1px solid #EFEFEF;display:flex;padding:16px}.chat-rooms--search>input{background-color:#F5F5F5;border:1px solid #EFEFEF;height:40px;width:100%;font-size:16px;padding-left:16px;padding-right:16px;-moz-border-radius:4px;-webkit-border-radius:4px;border-radius:4px}.chat-rooms--search>input:hover,.chat-rooms--search>input:active{border:1px solid #DBDBDB}.chat-rooms--search>button{background-color:#F5F5F5;border:1px solid #EFEFEF;font-size:16px;min-width:80px;height:40px;margin-left:12px;-moz-border-radius:4px;-webkit-border-radius:4px;border-radius:4px}.chat-rooms--list{flex-grow:1;flex-shrink:1;overflow-y:auto}.chat-room{cursor:pointer;display:flex;position:relative;margin-bottom:1px;padding:12px 16px}.chat-room:hover,.chat-room.is-active{background-color:#F5F5F5}.chat-room--user{flex-grow:1;flex-shrink:1;overflow:hidden}.chat-room--user-name{font-size:16px;font-weight:600;line-height:18px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.chat-room--latest-message{font-size:12px;line-height:14px;margin-top:4px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.chat-room--user-indicator{background-color:rgb(240, 90, 97);border:1px solid rgb(255, 255, 255);height:8px;width:8px;position:absolute;right:8px;top:50%;transform:translate(0, -50%);-moz-border-radius:8px;-webkit-border-radius:8px;border-radius:8px}";
17325
-
17326
- const ChatRooms = class {
17327
- constructor(hostRef) {
17328
- registerInstance(this, hostRef);
17329
- this.clickRoom = (chatRoom) => {
17330
- this.onClickRoom(chatRoom);
17331
- };
17332
- this.onSearchRooms = lodash.debounce((keyword) => {
17333
- this.keyword = keyword;
17334
- }, 500);
17335
- this.renderChatRoom = (chatRoom, index) => {
17336
- const { uid, members, messages } = chatRoom;
17337
- const receiverUser = members.find(user => user.id !== this.senderId);
17338
- const isActiveRoom = (this.activeRoom || {}).uid === uid;
17339
- let unreadMessages = 0;
17340
- const lastMessage = lodash.last(messages || []);
17341
- (messages || []).forEach(message => {
17342
- if (Boolean(message.unRead) && message.senderId !== this.senderId) {
17343
- unreadMessages += 1;
17344
- }
17345
- });
17346
- return (h("div", { key: `chat-room--${uid}-${index}`, class: `chat-room ${isActiveRoom ? 'is-active' : ''}`, onClick: () => !isActiveRoom && this.clickRoom(chatRoom) }, h("div", { class: "chat-room--user" }, h("user-avatar", { size: 48, avatar: receiverUser.avatar, name: h("div", { class: "chat-room--user-name" }, receiverUser.fullName), description: lastMessage && (h("div", { class: "chat-room--latest-message" }, lastMessage.senderId === this.senderId ? 'You: ' : '', lastMessage.message)), shortName: String(receiverUser.fullName || '').charAt(0) })), unreadMessages > 0 && (h("div", { class: "chat-room--user-indicator" }))));
17347
- };
17348
- this.senderId = undefined;
17349
- this.chatRooms = undefined;
17350
- this.activeRoom = undefined;
17351
- this.onClickRoom = undefined;
17352
- this.keyword = undefined;
17353
- }
17354
- render() {
17355
- const visibleRooms = (this.chatRooms || []).filter(chatRoom => {
17356
- if (this.keyword) {
17357
- const receiverUser = chatRoom.members.find(user => user.id !== this.senderId);
17358
- return String(receiverUser.fullName).toLowerCase().indexOf(String(this.keyword).toLowerCase()) > -1;
17359
- }
17360
- return true;
17361
- });
17362
- return (h("div", { class: "chat-rooms" }, h("div", { class: "chat-rooms--search" }, h("input", { autoComplete: "off", placeholder: "Enter a name...", onInput: evt => this.onSearchRooms(evt.target.value) })), h("div", { class: "chat-rooms--list" }, !this.chatRooms && [1, 2, 3, 4].map(fakeId => (h("div", { key: `chat-room--${fakeId}`, class: "chat-room" }, h("div", { class: "chat-room--user" }, h("div", { style: { display: "flex", alignItems: "center" } }, h("div", { style: {
17363
- backgroundColor: Colors.Gray02,
17364
- borderRadius: '50%',
17365
- height: `48px`,
17366
- width: `48px`,
17367
- minWidth: `48px`,
17368
- } }), h("div", { style: {
17369
- flexShrink: '1',
17370
- flexGrow: '1',
17371
- marginLeft: '12px',
17372
- } }, h("div", { style: {
17373
- backgroundColor: Colors.Gray02,
17374
- height: '16px',
17375
- width: '30%',
17376
- } }), h("div", { style: {
17377
- backgroundColor: Colors.Gray01,
17378
- marginTop: '12px',
17379
- height: '16px',
17380
- width: '60%',
17381
- } }))))))), this.chatRooms && visibleRooms.length > 0 && visibleRooms.map(this.renderChatRoom), this.chatRooms && visibleRooms.length === 0 && (h("div", { style: { color: Colors.Gray04, padding: '64px 24px', textAlign: 'center' } }, "No available users")))));
17382
- }
17383
- };
17384
- ChatRooms.style = indexCss$1;
17385
-
17386
- const indexCss = "";
17387
-
17388
- const UserAvatar = class {
17389
- constructor(hostRef) {
17390
- registerInstance(this, hostRef);
17391
- this.size = 24;
17392
- this.name = undefined;
17393
- this.description = undefined;
17394
- this.nameStyle = undefined;
17395
- this.shortName = undefined;
17396
- this.avatar = undefined;
17397
- }
17398
- render() {
17399
- return (h("div", { style: { display: "flex", alignItems: "center" } }, this.avatar && (h("div", { style: {
17400
- border: `1px solid ${Colors.White}`,
17401
- backgroundImage: `url("${this.avatar}")`,
17402
- backgroundColor: Colors.Gray01,
17403
- backgroundPosition: 'center center',
17404
- backgroundSize: 'cover',
17405
- borderRadius: '50%',
17406
- height: `${this.size}px`,
17407
- width: `${this.size}px`,
17408
- minWidth: `${this.size}px`,
17409
- } })), !this.avatar && (h("div", { style: {
17410
- border: `1px solid ${Colors.White}`,
17411
- backgroundColor: Colors.Gray01,
17412
- borderRadius: '50%',
17413
- display: 'flex',
17414
- alignItems: 'center',
17415
- justifyContent: 'center',
17416
- height: `${this.size}px`,
17417
- width: `${this.size}px`,
17418
- minWidth: `${this.size}px`,
17419
- } }, this.shortName)), this.name && (h("div", { style: {
17420
- flexShrink: '1',
17421
- flexGrow: '1',
17422
- marginLeft: '12px',
17423
- overflow: 'hidden',
17424
- whiteSpace: 'nowrap',
17425
- textOverflow: 'ellipsis',
17426
- } }, h("div", { style: Object.assign({}, this.nameStyle) }, this.name), this.description && h("div", { style: { color: '#999999' } }, this.description)))));
17427
- }
17428
- };
17429
- UserAvatar.style = indexCss;
17430
-
17431
- export { ChatBox as chat_box, ChatForm as chat_form, ChatMessages as chat_messages, ChatRooms as chat_rooms, UserAvatar as user_avatar };
17215
+ export { lodash as l };
@@ -1,55 +1,31 @@
1
- 'use strict';
2
-
3
- Object.defineProperty(exports, '__esModule', { value: true });
4
-
5
- const index = require('./index-dd8176c4.js');
6
- const colors = require('./colors-38421769.js');
7
- const services = require('./services-d1bdf299.js');
8
- require('./_commonjsHelpers-5cfcba41.js');
1
+ import { r as registerInstance, h } from './index-888e99e3.js';
9
2
 
10
3
  const indexCss = "@import url('https://fonts.googleapis.com/css2?family=Roboto:ital,wght@0,400;0,500;0,700;1,400;1,500;1,700&display=swap'); chat-button{position:relative}.chat-button--indicator{cursor:pointer;position:absolute;inset:0}.chat-button--counter{background-color:rgb(240, 90, 97);border:1px solid rgb(255, 255, 255);position:absolute;right:6px;top:0px;height:8px;width:8px;-moz-border-radius:8px;-webkit-border-radius:8px;border-radius:8px}.chat-box{font-family:'Roboto', sans-serif;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale;background-color:#fff;display:flex;flex-direction:column;position:fixed;inset:0px;z-index:20000;font-size:16px;text-align:left;color:#141414}.chat-box--header{display:flex;justify-content:space-between;padding:16px;position:relative}.chat-box--title{color:#fff;font-size:20px;font-weight:600;line-height:1;display:flex;align-items:center;justify-content:space-between;margin:0}.chat-box--close{cursor:pointer;display:block;position:absolute;z-index:1000;top:50%;right:0;width:30px;height:30px;transform:translate(0, -50%);background-size:contain;background-repeat:no-repeat;background-position:center center;background-image:url('data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAADwAAAA8CAYAAAA6/NlyAAAAAXNSR0IArs4c6QAAA3hJREFUaAXlm8+K00Acx7MiCIJH/yw+gA9g25O49SL4AO3Bp1jw5NvktC+wF88qevK4BU97EmzxUBCEolK/n5gp3W6TTJPfpNPNF37MNsl85/vN/DaTmU6PknC4K+pniqeKJ3k8UnkvDxXJzzy+q/yaxxeVHxW/FNHjgRSeKt4rFoplzaAuHHDBGR2eS9G54reirsmienDCTRt7xwsp+KAoEmt9nLaGitZxrBbPFNaGfPloGw2t4JVamSt8xYW6Dg1oCYo3Yv+rCGViV160oMkcd8SYKnYV1Nb1aEOjCe6L5ZOiLfF120EjWhuBu3YIZt1NQmujnk5F4MgOpURzLfAwOBSTmzp3fpDxuI/pabxpqOoz2r2HLAb0GMbZKlNV5/Hg9XJypguryA7lPF5KMdTZQzHjqxNPhWhzIuAruOl1eNqKEx1tSh5rfbxdw7mOxCq4qS68ZTjKS1YVvilu559vWvFHhh4rZrdyZ69Vmpgdj8fJbDZLJpNJ0uv1cnr/gjrUhQMuI+ANjyuwftQ0bbL6Erp0mM/ny8Fg4M3LtdRxgMtKl3jwmIHVxYXChFy94/Rmpa/pTbNUhstKV+4Rr8lLQ9KlUvJKLyG8yvQ2s9SBy1Jb7jV5a0yapfF6apaZLjLLcWtd4sNrmJUMHyM+1xibTjH82Zh01TNlhsrOhdKTe00uAzZQmN6+KW+sDa/JD2PSVQ873m29yf+1Q9VDzfEYlHi1G5LKBBWZbtEsHbFwb1oYDwr1ZiF/2bnCSg1OBE/pfr9/bWx26UxJL3ONPISOLKUvQza0LZUxSKyjpdTGa/vDEr25rddbMM0Q3O6Lx3rqFvU+x6UrRKQY7tyrZecmD9FODy8uLizTmilwNj0kraNcAJhOp5aGVwsAGD5VmJBrWWbJSgWT9zrzWepQF47RaGSiKfeGx6Szi3gzmX/HHbihwBser4B9UJYpFBNX4R6vTn3VQnez0SymnrHQMsRYGTr1dSk34ljRqS/EMd2pLQ8YBp3a1PLfcqCpo8gtHkZFHKkTX6fs3MY0blKnth66rKCnU0VRGu37ONrQaA4eZDFtWAu2fXj9zjFkxTBOo8F7t926gTp/83Kyzzcy2kZD6xiqxTYnHLRFm3vHiRSwNSjkz3hoIzo8lCKWUlg/YtGs7tObunDAZfpDLbfEI15zsEIY3U/x/gHHc/G1zltnAgAAAABJRU5ErkJggg==')}@media (min-width: 768px){.chat-box{border:1px solid #fff;left:unset;top:unset;right:1px;bottom:0px;height:420px;max-height:90vh;width:600px;-moz-border-radius:8px 8px 0px 0px;-webkit-border-radius:8px 8px 0px 0px;border-radius:8px 8px 0px 0px;-moz-box-shadow:rgba(0, 0, 0, 0.1) 0px 0px 24px;-webkit-box-shadow:rgba(0, 0, 0, 0.1) 0px 0px 24px;box-shadow:rgba(0, 0, 0, 0.1) 0px 0px 24px}.chat-box--header{-moz-border-radius:8px 8px 0px 0px;-webkit-border-radius:8px 8px 0px 0px;border-radius:8px 8px 0px 0px}}";
11
4
 
12
- const ChatButton = class {
5
+ const NotifySounds = class {
13
6
  constructor(hostRef) {
14
- index.registerInstance(this, hostRef);
15
- this.primaryColor = undefined;
16
- this.accessToken = undefined;
17
- this.senderId = undefined;
18
- this.receiverId = undefined;
19
- this.senderInfo = {};
20
- this.receiverInfo = {};
21
- this.chatRoom = {};
22
- this.chatMessages = undefined;
23
- this.isChatExpanded = undefined;
7
+ registerInstance(this, hostRef);
24
8
  }
25
- componentWillLoad() {
26
- this.fetchData();
9
+ componentDidLoad() {
10
+ const btnPlaySound = document.getElementById('chat--play-sound');
11
+ btnPlaySound.click();
27
12
  }
28
- async fetchData() {
29
- try {
30
- this.chatRoom = await services.HttpService().createChatRoom(this.receiverId, this.accessToken);
31
- if (this.chatRoom) {
32
- services.HttpService().fetchChatMessages(this.chatRoom.uid, (messages) => this.chatMessages = messages);
33
- this.senderInfo = this.chatRoom.members.find(user => user.id === Number(this.senderId));
34
- this.receiverInfo = this.chatRoom.members.find(user => user.id === Number(this.receiverId));
35
- }
36
- }
37
- catch (e) { }
13
+ playSound() {
14
+ const audioPlayer = new Audio('https://res.cloudinary.com/reckon-mini-sites/video/upload/v1696198815/favesalon/notification--message_i9wsj8.mp3');
15
+ audioPlayer.play();
38
16
  }
17
+ ;
39
18
  render() {
40
- const unreadMessages = (this.chatMessages || []).filter(message => {
41
- return Boolean(message.unRead) && message.senderId !== this.senderInfo.id;
42
- });
43
- return (index.h("div", null, index.h("div", { class: "chat-button--indicator", onClick: () => this.isChatExpanded = true }, unreadMessages.length > 0 && index.h("span", { class: "chat-button--counter" })), index.h("div", { class: "chat-box", style: this.isChatExpanded ? {} : { display: 'none' } }, index.h("div", { class: "chat-box--header", style: {
44
- backgroundColor: this.primaryColor || '#f05a61',
45
- } }, index.h("h3", { class: "chat-box--title" }, "Chat"), index.h("div", { style: { position: 'relative' } }, index.h("div", { class: "chat-box--close", onClick: () => this.isChatExpanded = false }))), index.h("div", { style: {
46
- flexShrink: '1',
47
- flexGrow: '1',
48
- overflowY: 'auto',
49
- padding: '16px',
50
- } }, index.h("chat-messages", { sender: this.senderInfo, receiver: this.receiverInfo, messages: this.chatMessages || [], "chat-room-id": this.chatRoom.uid })), index.h("div", { style: { borderTop: `1px solid ${colors.Colors.Gray02}` } }, index.h("chat-form", { "sender-id": this.senderInfo.id ? Number(this.senderInfo.id) : null, "chat-room-id": this.chatRoom.uid })))));
19
+ return (h("button", { id: "chat--play-sound", onClick: () => this.playSound(), style: {
20
+ border: 'none',
21
+ display: 'block',
22
+ overflow: 'hidden',
23
+ height: '1px',
24
+ width: '1px',
25
+ padding: '0',
26
+ } }, "Play"));
51
27
  }
52
28
  };
53
- ChatButton.style = indexCss;
29
+ NotifySounds.style = indexCss;
54
30
 
55
- exports.chat_button = ChatButton;
31
+ export { NotifySounds as notify_sounds };
@@ -0,0 +1,7 @@
1
+ import { a as createCommonjsModule, c as commonjsGlobal } from './_commonjsHelpers-a4f66ccd.js';
2
+
3
+ var relativeTime = createCommonjsModule(function (module, exports) {
4
+ !function(r,e){"object"=='object'&&"undefined"!='object'?module.exports=e():"function"==typeof undefined&&undefined.amd?undefined(e):(r="undefined"!=typeof globalThis?globalThis:r||self).dayjs_plugin_relativeTime=e();}(commonjsGlobal,(function(){"use strict";return function(r,e,t){r=r||{};var n=e.prototype,o={future:"in %s",past:"%s ago",s:"a few seconds",m:"a minute",mm:"%d minutes",h:"an hour",hh:"%d hours",d:"a day",dd:"%d days",M:"a month",MM:"%d months",y:"a year",yy:"%d years"};function i(r,e,t,o){return n.fromToBase(r,e,t,o)}t.en.relativeTime=o,n.fromToBase=function(e,n,i,d,u){for(var f,a,s,l=i.$locale().relativeTime||o,h=r.thresholds||[{l:"s",r:44,d:"second"},{l:"m",r:89},{l:"mm",r:44,d:"minute"},{l:"h",r:89},{l:"hh",r:21,d:"hour"},{l:"d",r:35},{l:"dd",r:25,d:"day"},{l:"M",r:45},{l:"MM",r:10,d:"month"},{l:"y",r:17},{l:"yy",d:"year"}],m=h.length,c=0;c<m;c+=1){var y=h[c];y.d&&(f=d?t(e).diff(i,y.d,!0):i.diff(e,y.d,!0));var p=(r.rounding||Math.round)(Math.abs(f));if(s=f>0,p<=y.r||!y.r){p<=1&&c>0&&(y=h[c-1]);var v=l[y.l];u&&(p=u(""+p)),a="string"==typeof v?v.replace("%d",p):v(p,n,y.l,s);break}}if(n)return a;var M=s?l.future:l.past;return "function"==typeof M?M(a):M.replace("%s",a)},n.to=function(r,e){return i(r,e,this,!0)},n.from=function(r,e){return i(r,e,this)};var d=function(r){return r.$u?t.utc():t()};n.toNow=function(r){return this.to(d(this),r)},n.fromNow=function(r){return this.from(d(this),r)};}}));
5
+ });
6
+
7
+ export { relativeTime as r };
@@ -1,4 +1,4 @@
1
- import { r as registerInstance, h } from './index-0494771f.js';
1
+ import { r as registerInstance, h } from './index-888e99e3.js';
2
2
  import { C as Colors } from './colors-ea36347a.js';
3
3
 
4
4
  const indexCss = ".salon-modal.salon-modal--booking:before{display:none}.salon-modal.salon-modal--booking .salon-modal--inner,.salon-modal.salon-modal--booking .salon-modal--content{max-width:none;width:100%;height:100%}.salon-modal.salon-modal--booking .salon-modal--close{background-color:#EFEFEF;width:40px;height:40px;right:16px;top:16px;-moz-border-radius:50px;-webkit-border-radius:50px;border-radius:50px}@media (min-width: 768px){.salon-modal.salon-modal--booking .salon-modal--close{right:20px;top:20px}}";
@@ -1,7 +1,7 @@
1
- import { r as registerInstance, h } from './index-0494771f.js';
2
- import { c as color, l as lib } from './index-a1c7583c.js';
1
+ import { r as registerInstance, h } from './index-888e99e3.js';
2
+ import { c as color, l as lib } from './index-00b83e1c.js';
3
3
  import { C as Colors } from './colors-ea36347a.js';
4
- import './_commonjsHelpers-66ac50f5.js';
4
+ import './_commonjsHelpers-a4f66ccd.js';
5
5
 
6
6
  const indexCss = ".salon-modal.salon-modal--booking:before{display:none}.salon-modal.salon-modal--booking .salon-modal--inner,.salon-modal.salon-modal--booking .salon-modal--content{max-width:none;width:100%;height:100%}.salon-modal.salon-modal--booking .salon-modal--close{background-color:#EFEFEF;width:40px;height:40px;right:16px;top:16px;-moz-border-radius:50px;-webkit-border-radius:50px;border-radius:50px}@media (min-width: 768px){.salon-modal.salon-modal--booking .salon-modal--close{right:20px;top:20px}}";
7
7
 
@@ -1,4 +1,4 @@
1
- import { r as registerInstance, h } from './index-0494771f.js';
1
+ import { r as registerInstance, h } from './index-888e99e3.js';
2
2
  import { C as Colors } from './colors-ea36347a.js';
3
3
 
4
4
  const indexCss = ".salon-modal.salon-modal--gift-card:before{display:none}.salon-modal.salon-modal--gift-card .salon-modal--inner,.salon-modal.salon-modal--gift-card .salon-modal--content{max-width:none;width:100%;height:100%}.salon-modal.salon-modal--gift-card .salon-modal--close{background-color:#EFEFEF;width:40px;height:40px;right:16px;top:16px;-moz-border-radius:50px;-webkit-border-radius:50px;border-radius:50px}@media (min-width: 768px){.salon-modal.salon-modal--gift-card .salon-modal--close{right:20px;top:20px}}";
@@ -1,7 +1,7 @@
1
- import { r as registerInstance, h } from './index-0494771f.js';
2
- import { c as color, l as lib } from './index-a1c7583c.js';
1
+ import { r as registerInstance, h } from './index-888e99e3.js';
2
+ import { c as color, l as lib } from './index-00b83e1c.js';
3
3
  import { C as Colors } from './colors-ea36347a.js';
4
- import './_commonjsHelpers-66ac50f5.js';
4
+ import './_commonjsHelpers-a4f66ccd.js';
5
5
 
6
6
  const indexCss = ".salon-modal.salon-modal--gift-card:before{display:none}.salon-modal.salon-modal--gift-card .salon-modal--inner,.salon-modal.salon-modal--gift-card .salon-modal--content{max-width:none;width:100%;height:100%}.salon-modal.salon-modal--gift-card .salon-modal--close{background-color:#EFEFEF;width:40px;height:40px;right:16px;top:16px;-moz-border-radius:50px;-webkit-border-radius:50px;border-radius:50px}@media (min-width: 768px){.salon-modal.salon-modal--gift-card .salon-modal--close{right:20px;top:20px}}";
7
7
 
@@ -1,6 +1,6 @@
1
- import { r as registerInstance, h } from './index-0494771f.js';
2
- import { H as HttpService } from './services-257442e2.js';
3
- import './_commonjsHelpers-66ac50f5.js';
1
+ import { r as registerInstance, h } from './index-888e99e3.js';
2
+ import { H as HttpService } from './services-260ea6eb.js';
3
+ import './_commonjsHelpers-a4f66ccd.js';
4
4
  import './colors-ea36347a.js';
5
5
 
6
6
  const indexCss = "";
@@ -1,8 +1,8 @@
1
- import { r as registerInstance, h } from './index-0494771f.js';
2
- import { H as HttpService, d as dayjs_min, s as shortDateYearFormat } from './services-257442e2.js';
1
+ import { r as registerInstance, h } from './index-888e99e3.js';
2
+ import { H as HttpService, d as dayjs_min, s as shortDateYearFormat } from './services-260ea6eb.js';
3
3
  import { C as Colors } from './colors-ea36347a.js';
4
- import { g as getRatingText } from './utils-e97485e0.js';
5
- import './_commonjsHelpers-66ac50f5.js';
4
+ import { g as getRatingText } from './utils-fd30fb29.js';
5
+ import './_commonjsHelpers-a4f66ccd.js';
6
6
 
7
7
  const indexCss = ".salon-latest-reviews .salon-review{min-width:280px}@media (min-width: 768px){.salon-latest-reviews .salon-review{min-width:300px}}";
8
8
 
@@ -1,9 +1,13 @@
1
- import { h } from '@stencil/core';
2
- import { Colors } from '../../constants/colors';
3
- import { isVideoMedia } from '../../types/style';
4
- import HttpService from '../../services/services';
5
- export class SalonLatestStyles {
6
- constructor() {
1
+ import { r as registerInstance, h } from './index-888e99e3.js';
2
+ import { C as Colors } from './colors-ea36347a.js';
3
+ import { H as HttpService, i as isVideoMedia } from './services-260ea6eb.js';
4
+ import './_commonjsHelpers-a4f66ccd.js';
5
+
6
+ const indexCss = "salon-latest-styles .view--salon-styles--item{width:120px;height:120px}@media (min-width: 1024px){salon-latest-styles .view--salon-styles--item{width:200px;height:200px}}";
7
+
8
+ const SalonLatestStyles = class {
9
+ constructor(hostRef) {
10
+ registerInstance(this, hostRef);
7
11
  this.salonId = undefined;
8
12
  this.isLoading = undefined;
9
13
  this.withBorder = undefined;
@@ -88,96 +92,7 @@ export class SalonLatestStyles {
88
92
  } }))))));
89
93
  })))));
90
94
  }
91
- static get is() { return "salon-latest-styles"; }
92
- static get originalStyleUrls() {
93
- return {
94
- "$": ["index.css"]
95
- };
96
- }
97
- static get styleUrls() {
98
- return {
99
- "$": ["index.css"]
100
- };
101
- }
102
- static get properties() {
103
- return {
104
- "salonId": {
105
- "type": "number",
106
- "mutable": false,
107
- "complexType": {
108
- "original": "number",
109
- "resolved": "number",
110
- "references": {}
111
- },
112
- "required": false,
113
- "optional": false,
114
- "docs": {
115
- "tags": [],
116
- "text": ""
117
- },
118
- "attribute": "salon-id",
119
- "reflect": false
120
- },
121
- "isLoading": {
122
- "type": "boolean",
123
- "mutable": false,
124
- "complexType": {
125
- "original": "boolean",
126
- "resolved": "boolean",
127
- "references": {}
128
- },
129
- "required": false,
130
- "optional": true,
131
- "docs": {
132
- "tags": [],
133
- "text": ""
134
- },
135
- "attribute": "is-loading",
136
- "reflect": false
137
- },
138
- "withBorder": {
139
- "type": "boolean",
140
- "mutable": false,
141
- "complexType": {
142
- "original": "boolean",
143
- "resolved": "boolean",
144
- "references": {}
145
- },
146
- "required": false,
147
- "optional": true,
148
- "docs": {
149
- "tags": [],
150
- "text": ""
151
- },
152
- "attribute": "with-border",
153
- "reflect": false
154
- }
155
- };
156
- }
157
- static get states() {
158
- return {
159
- "isLoadingState": {},
160
- "latestStyles": {}
161
- };
162
- }
163
- static get methods() {
164
- return {
165
- "fetchData": {
166
- "complexType": {
167
- "signature": "() => Promise<boolean>",
168
- "parameters": [],
169
- "references": {
170
- "Promise": {
171
- "location": "global"
172
- }
173
- },
174
- "return": "Promise<boolean>"
175
- },
176
- "docs": {
177
- "text": "",
178
- "tags": []
179
- }
180
- }
181
- };
182
- }
183
- }
95
+ };
96
+ SalonLatestStyles.style = indexCss;
97
+
98
+ export { SalonLatestStyles as salon_latest_styles };