File tree Expand file tree Collapse file tree 3 files changed +36
-0
lines changed
Expand file tree Collapse file tree 3 files changed +36
-0
lines changed Original file line number Diff line number Diff line change 55import * as zones from "./lib/zones.js" ;
66import * as section from "./lib/section.js" ;
77import * as story from "./lib/story.js" ;
8+ import * as homepage from "./lib/homepage.js" ;
89
910function distributeZones ( locker ) {
1011 // Add the communication bridge and vip method to the zones API
@@ -21,6 +22,9 @@ function distributeZones(locker) {
2122 case "story" :
2223 story . render ( locker ) ;
2324 break ;
25+ case "homepage" :
26+ homepage . render ( locker ) ;
27+ break ;
2428 default :
2529 reject ( "not a matching page type" ) ;
2630 }
Original file line number Diff line number Diff line change 1+ /*
2+ * Homepage template
3+ *
4+ * Note:
5+ * The DOM has not been updated to the grid yet, so this is
6+ * a manual set up for now.
7+ */
8+
9+ import * as zones from "./zones.js" ;
10+
11+ export function render ( locker ) {
12+ // Locker configs
13+ const market = locker . getConfig ( "marketInfo.domain" ) ;
14+
15+ // Community Events (iPublish)
16+ if ( locker . getConfig ( "zone.communityEvents" ) ) {
17+ const ipublish = zones . get ( "zone-community-events" ) ;
18+ ipublish . style . padding = 0 ;
19+ ipublish . dataset . market = market ;
20+ ipublish . zephr ( "zone-community-events" , market )
21+ ipublish . vip = document . querySelector ( "#zone-el-5" ) ;
22+ ipublish . inject ( ) ;
23+ }
24+ }
Original file line number Diff line number Diff line change @@ -65,6 +65,14 @@ export class Zone {
6565 return this . element . dataset ;
6666 }
6767
68+ /*
69+ * Getter to work with the element style object
70+ */
71+
72+ get style ( ) {
73+ return this . element . style ;
74+ }
75+
6876 /*
6977 * Zephr feature functionality
7078 * @param feature {string} the feature slug in Zephr
You can’t perform that action at this time.
0 commit comments