Commit 5f3a287 1 parent a6a5f9d commit 5f3a287 Copy full SHA for 5f3a287
File tree 5 files changed +920
-992
lines changed
5 files changed +920
-992
lines changed Original file line number Diff line number Diff line change @@ -134,6 +134,7 @@ export class JSONTemplate {
134
134
'@type' : 'Offer' ,
135
135
sku : v . sku ,
136
136
mpn,
137
+ name : v . name ,
137
138
url : offerUrl ,
138
139
image : v . images ?. [ 0 ] ?. url ?? image ,
139
140
availability : v . inStock ? 'InStock' : 'OutOfStock' ,
Original file line number Diff line number Diff line change 16
16
export default {
17
17
'thepixel--bul-eds' : ( await import ( './thepixel--bul-eds.js' ) ) . default ,
18
18
'wilson-ecommerce--wilson' : ( await import ( './wilson-ecommerce--wilson.js' ) ) . default ,
19
+ 'visualcomfort--adobe-edge' : ( await import ( './visualcomfort--adobe-edge.js' ) ) . default ,
20
+ 'visualcomfort--adobe-edge-stage' : ( await import ( './visualcomfort--adobe-edge.js' ) ) . default ,
19
21
} ;
Original file line number Diff line number Diff line change
1
+ /*
2
+ * Copyright 2024 Adobe. All rights reserved.
3
+ * This file is licensed to you under the Apache License, Version 2.0 (the "License");
4
+ * you may not use this file except in compliance with the License. You may obtain a copy
5
+ * of the License at http://www.apache.org/licenses/LICENSE-2.0
6
+ *
7
+ * Unless required by applicable law or agreed to in writing, software distributed under
8
+ * the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS
9
+ * OF ANY KIND, either express or implied. See the License for the specific language
10
+ * governing permissions and limitations under the License.
11
+ */
12
+
13
+ import { JSONTemplate } from '../JSONTemplate.js' ;
14
+
15
+ export default class extends JSONTemplate {
16
+ // eslint-disable-next-line class-methods-use-this
17
+ renderBrand ( ) {
18
+ return {
19
+ brand : {
20
+ '@type' : 'Brand' ,
21
+ name : this . product . attributeMap ?. brand ?? 'Visual Comfort' ,
22
+ } ,
23
+ } ;
24
+ }
25
+
26
+ renderOffers ( ) {
27
+ const baseOffers = super . renderOffers ( ) ;
28
+ return baseOffers . map ( ( o ) => ( {
29
+ ...o ,
30
+ shippingDetails : {
31
+ '@type' : 'OfferShippingDetails' ,
32
+ shippingDestination : {
33
+ '@type' : 'DefinedRegion' ,
34
+ addressCountry : {
35
+ '@type' : 'Country' ,
36
+ name : 'US' ,
37
+ } ,
38
+ } ,
39
+ deliveryTime : {
40
+ '@type' : 'ShippingDeliveryTime' ,
41
+ businessDays : {
42
+ '@type' : 'OpeningHoursSpecification' ,
43
+ } ,
44
+ } ,
45
+ } ,
46
+ } ) ) ;
47
+ }
48
+ }
You can’t perform that action at this time.
0 commit comments