favesalon-embed 0.1.0 → 1.0.0

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 (127) hide show
  1. package/dist/cjs/chat-button.cjs.entry.js +118 -0
  2. package/dist/cjs/favesalon-embed.cjs.js +7 -3
  3. package/dist/cjs/google-map_5.cjs.entry.js +26 -7
  4. package/dist/cjs/{index-e6bea8f5.js → index-47c2a5f6.js} +512 -208
  5. package/dist/cjs/loader.cjs.js +4 -3
  6. package/dist/cjs/relativeTime-3721080d.js +9 -0
  7. package/dist/cjs/salon-booking-modal.cjs.entry.js +3 -2
  8. package/dist/cjs/salon-booking.cjs.entry.js +3 -2
  9. package/dist/cjs/salon-gift-card-modal.cjs.entry.js +3 -2
  10. package/dist/cjs/salon-gift-card.cjs.entry.js +3 -2
  11. package/dist/cjs/salon-latest-reviews.cjs.entry.js +5 -3
  12. package/dist/cjs/salon-lookbook.cjs.entry.js +7 -3
  13. package/dist/cjs/salon-ranking.cjs.entry.js +3 -2
  14. package/dist/cjs/salon-reviews.cjs.entry.js +10 -3
  15. package/dist/cjs/salon-services.cjs.entry.js +6 -3
  16. package/dist/cjs/salon-stylists.cjs.entry.js +9 -3
  17. package/dist/cjs/services-125c82d8.js +21492 -0
  18. package/dist/cjs/style-detail.cjs.entry.js +11 -9
  19. package/dist/cjs/user-avatar.cjs.entry.js +7 -3
  20. package/dist/collection/collection-manifest.json +3 -2
  21. package/dist/collection/components/chat-button/index.css +122 -0
  22. package/dist/collection/components/chat-button/index.js +218 -0
  23. package/dist/collection/components/chat-conversation/index.js +103 -0
  24. package/dist/collection/components/google-map/index.js +72 -68
  25. package/dist/collection/components/salon-booking/index.css +5 -0
  26. package/dist/collection/components/salon-booking/index.js +85 -80
  27. package/dist/collection/components/salon-booking/salon-booking-modal.js +73 -69
  28. package/dist/collection/components/salon-gift-card/index.css +6 -1
  29. package/dist/collection/components/salon-gift-card/index.js +85 -80
  30. package/dist/collection/components/salon-gift-card/salon-gift-card-modal.js +56 -52
  31. package/dist/collection/components/salon-info/index.css +1 -0
  32. package/dist/collection/components/salon-info/index.js +60 -54
  33. package/dist/collection/components/salon-latest-reviews/index.css +3 -0
  34. package/dist/collection/components/salon-latest-reviews/index.js +131 -144
  35. package/dist/collection/components/salon-latest-styles/index.css +2 -0
  36. package/dist/collection/components/salon-latest-styles/index.js +143 -138
  37. package/dist/collection/components/salon-locations/index.css +3 -0
  38. package/dist/collection/components/salon-locations/index.js +112 -120
  39. package/dist/collection/components/salon-lookbook/index.css +3 -0
  40. package/dist/collection/components/salon-lookbook/index.js +182 -190
  41. package/dist/collection/components/salon-ranking/index.js +68 -65
  42. package/dist/collection/components/salon-reviews/index.css +3 -0
  43. package/dist/collection/components/salon-reviews/index.js +146 -183
  44. package/dist/collection/components/salon-schedules/index.css +3 -0
  45. package/dist/collection/components/salon-schedules/index.js +129 -151
  46. package/dist/collection/components/salon-services/index.css +1 -0
  47. package/dist/collection/components/salon-services/index.js +117 -127
  48. package/dist/collection/components/salon-stylists/index.css +8 -0
  49. package/dist/collection/components/salon-stylists/index.js +137 -136
  50. package/dist/collection/components/style-detail/index.css +14 -0
  51. package/dist/collection/components/style-detail/index.js +265 -340
  52. package/dist/collection/components/user-avatar/index.js +119 -112
  53. package/dist/collection/mocks/users.js +10 -0
  54. package/dist/collection/services/services.js +121 -0
  55. package/dist/collection/types/chat.js +23 -0
  56. package/dist/collection/types/user.js +1 -1
  57. package/dist/custom-elements/index.d.ts +6 -0
  58. package/dist/custom-elements/index.js +24628 -8605
  59. package/dist/esm/chat-button.entry.js +114 -0
  60. package/dist/esm/favesalon-embed.js +4 -3
  61. package/dist/esm/google-map_5.entry.js +26 -7
  62. package/dist/esm/{index-6af0a03d.js → index-3fae868e.js} +512 -209
  63. package/dist/esm/loader.js +4 -3
  64. package/dist/esm/polyfills/css-shim.js +1 -1
  65. package/dist/esm/relativeTime-cd452e6d.js +7 -0
  66. package/dist/esm/salon-booking-modal.entry.js +3 -2
  67. package/dist/esm/salon-booking.entry.js +3 -2
  68. package/dist/esm/salon-gift-card-modal.entry.js +3 -2
  69. package/dist/esm/salon-gift-card.entry.js +3 -2
  70. package/dist/esm/salon-latest-reviews.entry.js +5 -3
  71. package/dist/esm/salon-lookbook.entry.js +7 -3
  72. package/dist/esm/salon-ranking.entry.js +3 -2
  73. package/dist/esm/salon-reviews.entry.js +10 -3
  74. package/dist/esm/salon-services.entry.js +6 -3
  75. package/dist/esm/salon-stylists.entry.js +9 -3
  76. package/dist/esm/services-40a3e622.js +21485 -0
  77. package/dist/esm/style-detail.entry.js +10 -8
  78. package/dist/esm/user-avatar.entry.js +7 -3
  79. package/dist/favesalon-embed/favesalon-embed.esm.js +1 -1
  80. package/dist/favesalon-embed/p-019c5ccd.entry.js +1 -0
  81. package/dist/favesalon-embed/p-083a8821.entry.js +1 -0
  82. package/dist/favesalon-embed/p-0d0ed9ea.entry.js +1 -0
  83. package/dist/favesalon-embed/p-119db8de.entry.js +1 -0
  84. package/dist/favesalon-embed/p-1432c51b.entry.js +1 -0
  85. package/dist/favesalon-embed/p-22093506.entry.js +1 -0
  86. package/dist/favesalon-embed/p-32b314e9.js +2 -0
  87. package/dist/favesalon-embed/p-4a5eca9a.js +1 -1
  88. package/dist/favesalon-embed/p-58d2e9be.js +1 -0
  89. package/dist/favesalon-embed/p-71404b6a.entry.js +1 -0
  90. package/dist/favesalon-embed/p-857c3a61.entry.js +1 -0
  91. package/dist/favesalon-embed/p-99ec77f7.entry.js +1 -0
  92. package/dist/favesalon-embed/p-b0c3673a.entry.js +1 -0
  93. package/dist/favesalon-embed/p-b287b1ea.entry.js +1 -0
  94. package/dist/favesalon-embed/p-b3af7842.entry.js +1 -0
  95. package/dist/favesalon-embed/p-b630ae68.js +1580 -0
  96. package/dist/favesalon-embed/p-ce2c1c9a.entry.js +1 -0
  97. package/dist/favesalon-embed/p-d9b7ad58.entry.js +1 -0
  98. package/dist/favesalon-embed/p-fc9a5551.js +1 -1
  99. package/dist/types/components/chat-button/index.d.ts +24 -0
  100. package/dist/types/components.d.ts +22 -0
  101. package/dist/types/mocks/users.d.ts +10 -0
  102. package/dist/types/services/services.d.ts +15 -0
  103. package/dist/types/stencil-public-runtime.d.ts +85 -11
  104. package/dist/types/types/chat.d.ts +17 -0
  105. package/loader/index.d.ts +9 -0
  106. package/loader/package.json +1 -0
  107. package/package.json +3 -3
  108. package/readme.md +2 -2
  109. package/dist/cjs/services-eee8f251.js +0 -5634
  110. package/dist/esm/services-295247b1.js +0 -5627
  111. package/dist/favesalon-embed/p-292b97ba.entry.js +0 -1
  112. package/dist/favesalon-embed/p-4869dfed.entry.js +0 -1
  113. package/dist/favesalon-embed/p-4aee4fd9.entry.js +0 -1
  114. package/dist/favesalon-embed/p-5528c705.entry.js +0 -1
  115. package/dist/favesalon-embed/p-612ad685.entry.js +0 -1
  116. package/dist/favesalon-embed/p-75aef7e0.entry.js +0 -1
  117. package/dist/favesalon-embed/p-8c780874.entry.js +0 -1
  118. package/dist/favesalon-embed/p-8dbf04c5.js +0 -1
  119. package/dist/favesalon-embed/p-9f31061a.entry.js +0 -1
  120. package/dist/favesalon-embed/p-a60d78e9.entry.js +0 -1
  121. package/dist/favesalon-embed/p-a6debdae.entry.js +0 -1
  122. package/dist/favesalon-embed/p-bad1e9a7.entry.js +0 -1
  123. package/dist/favesalon-embed/p-c2ecb365.js +0 -1
  124. package/dist/favesalon-embed/p-c7dea70c.entry.js +0 -1
  125. package/dist/favesalon-embed/p-f0e14641.entry.js +0 -1
  126. package/dist/types/types/tmp.d.ts +0 -0
  127. /package/dist/{collection/types/tmp.js → types/components/chat-conversation/index.d.ts} +0 -0
@@ -1,8 +1,15 @@
1
- import { Component, Prop, h, State } from '@stencil/core';
1
+ import { h } from '@stencil/core';
2
2
  import { formatFullAddress, formatWebsiteUrl } from '../../utils/utils';
3
3
  import { Colors } from '../../constants/colors';
4
4
  import HttpService from '../../services/services';
5
5
  export class SalonLocations {
6
+ constructor() {
7
+ this.salonId = undefined;
8
+ this.salonInfo = undefined;
9
+ this.isLoading = undefined;
10
+ this.withBorder = undefined;
11
+ this.salonInfoState = undefined;
12
+ }
6
13
  componentWillLoad() {
7
14
  if (this.salonInfo) {
8
15
  this.salonInfoState = JSON.parse(this.salonInfo);
@@ -20,132 +27,117 @@ export class SalonLocations {
20
27
  }
21
28
  render() {
22
29
  if (this.isLoading) {
23
- return (h("div", { class: "view view--salon-locations" },
24
- h("div", { class: "view-content", style: this.withBorder ? { border: `1px solid ${Colors.Gray02}`, borderRadius: '4px' } : { padding: '0px' } },
25
- h("div", { style: {
26
- backgroundColor: Colors.Gray02,
27
- height: '20px',
28
- width: '120px',
29
- } }),
30
- h("div", { style: { marginTop: '24px' } },
31
- h("div", { style: {
32
- backgroundColor: Colors.Gray01,
33
- height: '16px',
34
- width: '50%',
35
- } }),
36
- h("div", { style: {
37
- backgroundColor: Colors.Gray01,
38
- height: '16px',
39
- width: '50%',
40
- marginTop: '8px',
41
- } }),
42
- h("div", { style: {
43
- backgroundColor: Colors.Gray01,
44
- height: '192px',
45
- width: '100%',
46
- marginTop: '24px',
47
- } })))));
30
+ return (h("div", { class: "view view--salon-locations" }, h("div", { class: "view-content", style: this.withBorder ? { border: `1px solid ${Colors.Gray02}`, borderRadius: '4px' } : { padding: '0px' } }, h("div", { style: {
31
+ backgroundColor: Colors.Gray02,
32
+ height: '20px',
33
+ width: '120px',
34
+ } }), h("div", { style: { marginTop: '24px' } }, h("div", { style: {
35
+ backgroundColor: Colors.Gray01,
36
+ height: '16px',
37
+ width: '50%',
38
+ } }), h("div", { style: {
39
+ backgroundColor: Colors.Gray01,
40
+ height: '16px',
41
+ width: '50%',
42
+ marginTop: '8px',
43
+ } }), h("div", { style: {
44
+ backgroundColor: Colors.Gray01,
45
+ height: '192px',
46
+ width: '100%',
47
+ marginTop: '24px',
48
+ } })))));
48
49
  }
49
50
  const { businessPhone, businessName, website, email, } = this.salonInfoState || {};
50
51
  const websiteUrl = formatWebsiteUrl(website);
51
52
  const fullAddress = formatFullAddress(this.salonInfoState);
52
- return (h("div", { class: "view view--salon-locations" },
53
- h("div", { class: "view-content", style: this.withBorder ? { border: `1px solid ${Colors.Gray02}`, borderRadius: '4px' } : { padding: '0px' } },
54
- h("div", { style: { fontSize: '18px', fontWeight: 'bold' } }, "Contact"),
55
- h("div", { class: "salon-contact--links", style: { marginTop: '16px' } },
56
- businessPhone && (h("div", { class: "salon-contact--links-item" },
57
- h("i", { class: "ri-phone-line", style: { color: Colors.Gray04, fontSize: '18px', marginRight: '6px' } }),
58
- " ",
59
- h("a", { href: `tel:${businessPhone}`, style: { color: Colors.TextColor, textDecoration: 'none' } }, businessPhone))),
60
- websiteUrl && (h("div", { class: "salon-contact--links-item" },
61
- h("i", { class: "ri-links-line", style: { color: Colors.Gray04, fontSize: '18px', marginRight: '6px' } }),
62
- " ",
63
- h("a", { target: websiteUrl && websiteUrl.indexOf(window.location.hostname) === -1 ? '_blank' : undefined, href: websiteUrl, style: { color: Colors.TextColor, textDecoration: 'none' } }, websiteUrl))),
64
- email && (h("div", { class: "salon-contact--links-item" },
65
- h("i", { class: "ri-mail-line", style: { color: Colors.Gray04, fontSize: '18px', marginRight: '6px' } }),
66
- " ",
67
- h("a", { href: `mailto:${email}`, style: { color: Colors.TextColor, textDecoration: 'none' } }, email)))),
68
- h("div", { class: "view--salon-info--map", style: { marginTop: '24px' } },
69
- h("google-map", { "location-name": businessName, "location-address": fullAddress })))));
53
+ return (h("div", { class: "view view--salon-locations" }, h("div", { class: "view-content", style: this.withBorder ? { border: `1px solid ${Colors.Gray02}`, borderRadius: '4px' } : { padding: '0px' } }, h("div", { style: { fontSize: '18px', fontWeight: 'bold' } }, "Contact"), h("div", { class: "salon-contact--links", style: { marginTop: '16px' } }, businessPhone && (h("div", { class: "salon-contact--links-item" }, h("i", { class: "ri-phone-line", style: { color: Colors.Gray04, fontSize: '18px', marginRight: '6px' } }), " ", h("a", { href: `tel:${businessPhone}`, style: { color: Colors.TextColor, textDecoration: 'none' } }, businessPhone))), websiteUrl && (h("div", { class: "salon-contact--links-item" }, h("i", { class: "ri-links-line", style: { color: Colors.Gray04, fontSize: '18px', marginRight: '6px' } }), " ", h("a", { target: websiteUrl && websiteUrl.indexOf(window.location.hostname) === -1 ? '_blank' : undefined, href: websiteUrl, style: { color: Colors.TextColor, textDecoration: 'none' } }, websiteUrl))), email && (h("div", { class: "salon-contact--links-item" }, h("i", { class: "ri-mail-line", style: { color: Colors.Gray04, fontSize: '18px', marginRight: '6px' } }), " ", h("a", { href: `mailto:${email}`, style: { color: Colors.TextColor, textDecoration: 'none' } }, email)))), h("div", { class: "view--salon-info--map", style: { marginTop: '24px' } }, h("google-map", { "location-name": businessName, "location-address": fullAddress })))));
70
54
  }
71
55
  static get is() { return "salon-locations"; }
72
- static get originalStyleUrls() { return {
73
- "$": ["index.less"]
74
- }; }
75
- static get styleUrls() { return {
76
- "$": ["index.css"]
77
- }; }
78
- static get properties() { return {
79
- "salonId": {
80
- "type": "number",
81
- "mutable": false,
82
- "complexType": {
83
- "original": "number",
84
- "resolved": "number",
85
- "references": {}
86
- },
87
- "required": false,
88
- "optional": false,
89
- "docs": {
90
- "tags": [],
91
- "text": ""
92
- },
93
- "attribute": "salon-id",
94
- "reflect": false
95
- },
96
- "salonInfo": {
97
- "type": "string",
98
- "mutable": false,
99
- "complexType": {
100
- "original": "string",
101
- "resolved": "string",
102
- "references": {}
103
- },
104
- "required": false,
105
- "optional": true,
106
- "docs": {
107
- "tags": [],
108
- "text": ""
109
- },
110
- "attribute": "salon-info",
111
- "reflect": false
112
- },
113
- "isLoading": {
114
- "type": "boolean",
115
- "mutable": false,
116
- "complexType": {
117
- "original": "boolean",
118
- "resolved": "boolean",
119
- "references": {}
120
- },
121
- "required": false,
122
- "optional": true,
123
- "docs": {
124
- "tags": [],
125
- "text": ""
56
+ static get originalStyleUrls() {
57
+ return {
58
+ "$": ["index.css"]
59
+ };
60
+ }
61
+ static get styleUrls() {
62
+ return {
63
+ "$": ["index.css"]
64
+ };
65
+ }
66
+ static get properties() {
67
+ return {
68
+ "salonId": {
69
+ "type": "number",
70
+ "mutable": false,
71
+ "complexType": {
72
+ "original": "number",
73
+ "resolved": "number",
74
+ "references": {}
75
+ },
76
+ "required": false,
77
+ "optional": false,
78
+ "docs": {
79
+ "tags": [],
80
+ "text": ""
81
+ },
82
+ "attribute": "salon-id",
83
+ "reflect": false
126
84
  },
127
- "attribute": "is-loading",
128
- "reflect": false
129
- },
130
- "withBorder": {
131
- "type": "boolean",
132
- "mutable": false,
133
- "complexType": {
134
- "original": "boolean",
135
- "resolved": "boolean",
136
- "references": {}
85
+ "salonInfo": {
86
+ "type": "string",
87
+ "mutable": false,
88
+ "complexType": {
89
+ "original": "string",
90
+ "resolved": "string",
91
+ "references": {}
92
+ },
93
+ "required": false,
94
+ "optional": true,
95
+ "docs": {
96
+ "tags": [],
97
+ "text": ""
98
+ },
99
+ "attribute": "salon-info",
100
+ "reflect": false
137
101
  },
138
- "required": false,
139
- "optional": true,
140
- "docs": {
141
- "tags": [],
142
- "text": ""
102
+ "isLoading": {
103
+ "type": "boolean",
104
+ "mutable": false,
105
+ "complexType": {
106
+ "original": "boolean",
107
+ "resolved": "boolean",
108
+ "references": {}
109
+ },
110
+ "required": false,
111
+ "optional": true,
112
+ "docs": {
113
+ "tags": [],
114
+ "text": ""
115
+ },
116
+ "attribute": "is-loading",
117
+ "reflect": false
143
118
  },
144
- "attribute": "with-border",
145
- "reflect": false
146
- }
147
- }; }
148
- static get states() { return {
149
- "salonInfoState": {}
150
- }; }
119
+ "withBorder": {
120
+ "type": "boolean",
121
+ "mutable": false,
122
+ "complexType": {
123
+ "original": "boolean",
124
+ "resolved": "boolean",
125
+ "references": {}
126
+ },
127
+ "required": false,
128
+ "optional": true,
129
+ "docs": {
130
+ "tags": [],
131
+ "text": ""
132
+ },
133
+ "attribute": "with-border",
134
+ "reflect": false
135
+ }
136
+ };
137
+ }
138
+ static get states() {
139
+ return {
140
+ "salonInfoState": {}
141
+ };
142
+ }
151
143
  }
@@ -2,11 +2,14 @@
2
2
  salon-lookbook .view-header {
3
3
  display: block !important;
4
4
  }
5
+
5
6
  salon-lookbook .salon-loobook--serch-result {
6
7
  margin-bottom: 16px;
7
8
  }
9
+
8
10
  salon-lookbook .salon-loobook--filter-wrapper > label,
9
11
  salon-lookbook .salon-loobook--sort-wrapper > label {
10
12
  display: none !important;
11
13
  }
12
14
  }
15
+