@fifthbell/brokaw 0.1.68 → 0.1.70

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 (55) hide show
  1. package/README.md +1 -1
  2. package/dist/cronkite-manifest.d.ts +205 -69
  3. package/dist/cronkite-manifest.js +288 -111
  4. package/dist/cronkite-manifest.json +1024 -125
  5. package/dist/instagram-image-template.d.ts +0 -1
  6. package/dist/instagram-image-template.js +0 -4
  7. package/dist/layouts.d.ts +1 -1
  8. package/dist/live-program-page/index.html +2 -2
  9. package/dist/live-program-page/live-program-manifest.json +6 -6
  10. package/dist/live-program-page/live-program.v0.1.70.css +3 -0
  11. package/dist/manifest-validation.d.ts +2 -2
  12. package/dist/manifest-validation.js +12 -16
  13. package/dist/outlet-config.d.ts +0 -1
  14. package/dist/outlet-config.js +0 -1
  15. package/dist/renderer.browser.js +12 -0
  16. package/dist/renderer.core.js +42 -258
  17. package/dist/renderer.d.ts +1 -1
  18. package/dist/renderer.js +1 -1
  19. package/dist/schemas/canonical-document.schema.json +30 -10
  20. package/dist/schemas/cronkite-manifest.schema.json +84 -450
  21. package/dist/schemas/social-image-input.schema.json +14 -0
  22. package/dist/search-copy.d.ts +65 -0
  23. package/dist/search-copy.js +65 -0
  24. package/dist/types/canonical-document-schema.generated.d.ts +48 -4
  25. package/dist/types/canonical-document-schema.generated.js +48 -4
  26. package/dist/types/canonical-document.generated.d.ts +14 -0
  27. package/dist/types/cronkite-manifest.generated.d.ts +101 -297
  28. package/package.json +2 -2
  29. package/src/partial-deps.json +221 -50
  30. package/src/styles/compiled.css +1 -1
  31. package/src/templates/partials/blocks/tiktok.hbs +1 -1
  32. package/src/templates/partials/blocks/x.hbs +4 -4
  33. package/src/templates/partials/components/article-main.hbs +1 -1
  34. package/src/templates/partials/components/body-block.hbs +31 -0
  35. package/src/templates/partials/components/breaking-news/live-updates-column.hbs +2 -2
  36. package/src/templates/partials/components/breaking-news.hbs +6 -8
  37. package/src/templates/partials/components/editorial-hero.hbs +2 -2
  38. package/src/templates/partials/components/home/landing.hbs +1 -1
  39. package/src/templates/partials/components/home/main.hbs +4 -1
  40. package/src/templates/partials/components/live-story/main.hbs +8 -18
  41. package/src/templates/partials/components/not-found/main.hbs +4 -4
  42. package/src/templates/partials/components/search/main.hbs +25 -15
  43. package/src/templates/partials/components/snack-meta-image-row.hbs +21 -0
  44. package/src/templates/partials/components/snack-meta-inline.hbs +43 -0
  45. package/src/templates/partials/components/snack-top-story.hbs +1 -0
  46. package/src/templates/partials/components/snack.hbs +3 -61
  47. package/src/templates/partials/components/spotlight-hero-slides.hbs +1 -0
  48. package/src/templates/partials/components/spotlight-hero.hbs +2 -2
  49. package/src/templates/partials/components/standalone-main.hbs +1 -1
  50. package/src/templates/partials/shell/doc-start-404.hbs +2 -4
  51. package/src/templates/partials/shell/doc-start-standard.hbs +9 -11
  52. package/src/templates/partials/shell/rum-loader.hbs +77 -0
  53. package/src/templates/templates/instagram-image.hbs +0 -2
  54. package/dist/live-program-page/live-program.v0.1.68.css +0 -3
  55. /package/dist/live-program-page/{live-program.v0.1.68.js → live-program.v0.1.70.js} +0 -0
@@ -4,18 +4,18 @@
4
4
  <h1 class='text-9xl font-bold text-[#8f0d00] dark:text-[#ff2e1a]' aria-label='Page not found error'>404</h1>
5
5
  </div>
6
6
 
7
- <h2 class='text-4xl font-bold text-slate-900 dark:text-slate-100 mb-4'>Page Not Found</h2>
7
+ <h2 class='text-4xl font-bold text-slate-900 dark:text-slate-100 mb-4'>{{title}}</h2>
8
8
 
9
9
  <p class='font-secondary text-xl text-slate-600 dark:text-slate-400 mb-8 leading-relaxed'>
10
- We couldn't find the page you're looking for. The article or page you're trying to access may have been moved, deleted, or never existed.
10
+ {{excerpt}}
11
11
  </p>
12
12
 
13
13
  <a href='{{logoLink}}' class='inline-flex items-center gap-2 bg-[#b21100] hover:bg-[#8a0d00] dark:bg-[#ff2e1a] dark:hover:bg-[#cc2515] text-white font-bold py-3 px-6 rounded transition-colors'>
14
- <span>Go to Homepage</span>
14
+ <span>{{homeLinkLabel}}</span>
15
15
  </a>
16
16
 
17
17
  <div class='mt-12 pt-8 border-t border-slate-200 dark:border-slate-800'>
18
- <p class='text-sm text-slate-600 dark:text-slate-400 mb-4'>Or explore our categories:</p>
18
+ <p class='text-sm text-slate-600 dark:text-slate-400 mb-4'>{{categoriesLabel}}</p>
19
19
  <div class='flex flex-wrap justify-center gap-4'>
20
20
  {{#if navigation.categories}}
21
21
  {{#each navigation.categories}}
@@ -1,12 +1,12 @@
1
1
  <main class='flex-1 container mx-auto px-4'>
2
2
  <div class='mx-auto max-w-5xl py-10'>
3
3
  <header class='mb-8'>
4
- <p class='text-xs font-bold uppercase tracking-[0.2em] text-[#8f0d00]'>Search</p>
4
+ <p class='text-xs font-bold uppercase tracking-[0.2em] text-[#8f0d00]'>{{searchCopy.eyebrow}}</p>
5
5
  <h1 class='mt-3 text-4xl md:text-5xl font-bold text-slate-900 dark:text-slate-100 font-encode'>
6
- Find Stories Fast
6
+ {{searchCopy.heading}}
7
7
  </h1>
8
8
  <p class='font-secondary mt-3 text-lg text-slate-600 dark:text-slate-400'>
9
- Search titles and excerpts across current-language coverage.
9
+ {{searchCopy.intro}}
10
10
  </p>
11
11
  </header>
12
12
 
@@ -18,14 +18,14 @@
18
18
  type='search'
19
19
  autocomplete='off'
20
20
  spellcheck='false'
21
- placeholder='Search stories...'
21
+ placeholder='{{searchCopy.placeholder}}'
22
22
  class='w-full rounded-xl border border-slate-300 dark:border-slate-700 bg-white dark:bg-slate-950 px-4 py-3 text-base text-slate-900 dark:text-slate-100 placeholder:text-slate-400 dark:placeholder:text-slate-500 focus:outline-none focus:ring-2 focus:ring-[#b21100]/40'
23
23
  />
24
24
  <button
25
25
  type='submit'
26
26
  class='rounded-xl bg-[#b21100] hover:bg-[#8f0d00] text-white px-6 py-3 font-bold uppercase tracking-wide text-sm transition-colors'
27
27
  >
28
- Search
28
+ {{searchCopy.submit}}
29
29
  </button>
30
30
  </form>
31
31
  <p id='search-results-meta' class='mt-4 text-sm text-slate-500 dark:text-slate-400'></p>
@@ -37,11 +37,20 @@
37
37
  </div>
38
38
  </main>
39
39
 
40
+ <script type='application/json' id='search-page-copy'>{{{jsonString searchCopy}}}</script>
40
41
  <script>
41
42
  (function () {
42
43
  const PAGE_SIZE = 20;
43
44
  const CDN_BASE = 'https://cdn.fifthbell.com/content';
44
45
  const cache = window.__fifthbellSearchCache || (window.__fifthbellSearchCache = new Map());
46
+ const copyElement = document.getElementById('search-page-copy');
47
+ let copy = {};
48
+ try {
49
+ copy = JSON.parse(copyElement?.textContent || '{}');
50
+ } catch {
51
+ copy = {};
52
+ }
53
+ const text = (key, fallback) => typeof copy[key] === 'string' ? copy[key] : fallback;
45
54
 
46
55
  const form = document.getElementById('search-page-form');
47
56
  const input = document.getElementById('search-page-input');
@@ -297,14 +306,14 @@
297
306
  function renderResults(language, query, page, results) {
298
307
  const total = results.length;
299
308
  if (!query) {
300
- meta.textContent = 'Start typing to search in this language.';
301
- renderEmptyState('No query yet.');
309
+ meta.textContent = text('emptyPrompt', 'Start typing to search in this language.');
310
+ renderEmptyState(text('emptyState', 'No query yet.'));
302
311
  return;
303
312
  }
304
313
 
305
314
  if (total === 0) {
306
- meta.textContent = `No matches for "${query}".`;
307
- renderEmptyState('Try a different keyword.');
315
+ meta.textContent = `${text('noResults', 'No matches for')} "${query}".`;
316
+ renderEmptyState(text('tryAnother', 'Try a different keyword.'));
308
317
  return;
309
318
  }
310
319
 
@@ -314,7 +323,8 @@
314
323
  const end = Math.min(start + PAGE_SIZE, total);
315
324
  const visible = results.slice(start, end);
316
325
 
317
- meta.textContent = `${total} result${total === 1 ? '' : 's'} for "${query}" • Page ${currentPage} of ${totalPages}`;
326
+ const resultLabel = total === 1 ? text('resultSingular', 'result') : text('resultPlural', 'results');
327
+ meta.textContent = `${total} ${resultLabel} ${text('forQuery', 'for')} "${query}" • ${text('page', 'Page')} ${currentPage} ${text('of', 'of')} ${totalPages}`;
318
328
 
319
329
  list.innerHTML = visible
320
330
  .map((article) => {
@@ -340,7 +350,7 @@
340
350
  const pageLinks = [];
341
351
  if (currentPage > 1) {
342
352
  pageLinks.push(
343
- `<a class="rounded-lg border border-slate-300 dark:border-slate-700 px-3 py-2 text-sm hover:bg-slate-100 dark:hover:bg-slate-800 transition-colors" href="${escapeHtml(toHref(language, query, currentPage - 1))}">Previous</a>`
353
+ `<a class="rounded-lg border border-slate-300 dark:border-slate-700 px-3 py-2 text-sm hover:bg-slate-100 dark:hover:bg-slate-800 transition-colors" href="${escapeHtml(toHref(language, query, currentPage - 1))}">${escapeHtml(text('previous', 'Previous'))}</a>`
344
354
  );
345
355
  }
346
356
 
@@ -360,7 +370,7 @@
360
370
 
361
371
  if (currentPage < totalPages) {
362
372
  pageLinks.push(
363
- `<a class="rounded-lg border border-slate-300 dark:border-slate-700 px-3 py-2 text-sm hover:bg-slate-100 dark:hover:bg-slate-800 transition-colors" href="${escapeHtml(toHref(language, query, currentPage + 1))}">Next</a>`
373
+ `<a class="rounded-lg border border-slate-300 dark:border-slate-700 px-3 py-2 text-sm hover:bg-slate-100 dark:hover:bg-slate-800 transition-colors" href="${escapeHtml(toHref(language, query, currentPage + 1))}">${escapeHtml(text('next', 'Next'))}</a>`
364
374
  );
365
375
  }
366
376
 
@@ -377,7 +387,7 @@
377
387
  return;
378
388
  }
379
389
 
380
- meta.textContent = 'Searching...';
390
+ meta.textContent = text('searching', 'Searching...');
381
391
  list.innerHTML = '';
382
392
  pagination.innerHTML = '';
383
393
 
@@ -386,8 +396,8 @@
386
396
  const results = searchArticles(articles, state.q);
387
397
  renderResults(language, state.q, state.page, results);
388
398
  } catch (error) {
389
- meta.textContent = 'Search is temporarily unavailable.';
390
- renderEmptyState('We could not load the search index right now.');
399
+ meta.textContent = text('unavailable', 'Search is temporarily unavailable.');
400
+ renderEmptyState(text('loadFailure', 'We could not load the search index right now.'));
391
401
  }
392
402
  }
393
403
 
@@ -0,0 +1,21 @@
1
+ {{#if category}}
2
+ <div class='w-full flex items-center justify-between {{#if metaTextSize}}{{metaTextSize}}{{else}}text-xs{{/if}} mb-2'>
3
+ <span class='text-[#8f0d00] dark:text-[#ff2e1a] uppercase font-bold tracking-wider'>{{category}}</span>
4
+ {{#if readTime}}
5
+ <span class='article-time text-slate-500 dark:text-slate-400'>{{readTime}}</span>
6
+ {{/if}}
7
+ </div>
8
+ {{else if (lookup categories 0)}}
9
+ {{#with (lookup categories 0)}}
10
+ <div class='w-full flex items-center justify-between {{#if ../metaTextSize}}{{../metaTextSize}}{{else}}text-xs{{/if}} mb-2'>
11
+ <span class='text-[#8f0d00] dark:text-[#ff2e1a] uppercase font-bold tracking-wider'>{{name}}</span>
12
+ {{#if ../readTime}}
13
+ <span class='article-time text-slate-500 dark:text-slate-400'>{{../readTime}}</span>
14
+ {{/if}}
15
+ </div>
16
+ {{/with}}
17
+ {{else if readTime}}
18
+ <div class='w-full flex items-center justify-end {{#if metaTextSize}}{{metaTextSize}}{{else}}text-xs{{/if}} mb-2'>
19
+ <span class='article-time text-slate-500 dark:text-slate-400'>{{readTime}}</span>
20
+ </div>
21
+ {{/if}}
@@ -0,0 +1,43 @@
1
+ {{#if (eq showImage false)}}
2
+ {{#if category}}
3
+ <div class='flex items-center {{#if metaTextSize}}{{metaTextSize}}{{else}}text-xs{{/if}} mb-2'>
4
+ <span class='text-[#8f0d00] dark:text-[#ff2e1a] uppercase font-bold tracking-wider'>{{category}}</span>
5
+ {{#if readTime}}<span class='mx-2 text-slate-400 dark:text-slate-500'>•</span><span class='article-time text-slate-500 dark:text-slate-400'>{{readTime}}</span>{{/if}}
6
+ </div>
7
+ {{else if (lookup categories 0)}}
8
+ {{#with (lookup categories 0)}}
9
+ <div class='flex items-center {{#if ../metaTextSize}}{{../metaTextSize}}{{else}}text-xs{{/if}} mb-2'>
10
+ <span class='text-[#8f0d00] dark:text-[#ff2e1a] uppercase font-bold tracking-wider'>{{name}}</span>
11
+ {{#if ../readTime}}<span class='mx-2 text-slate-400 dark:text-slate-500'>•</span><span class='article-time text-slate-500 dark:text-slate-400'>{{../readTime}}</span>{{/if}}
12
+ </div>
13
+ {{/with}}
14
+ {{else if readTime}}
15
+ <div class='flex items-center {{#if metaTextSize}}{{metaTextSize}}{{else}}text-xs{{/if}} mb-2'><span class='article-time text-slate-500 dark:text-slate-400'>{{readTime}}</span></div>
16
+ {{/if}}
17
+ {{else}}
18
+ {{#unless (coalesce image featuredImage.url)}}
19
+ {{#if category}}
20
+ <div class='flex items-center {{#if metaTextSize}}{{metaTextSize}}{{else}}text-xs{{/if}} mb-2'>
21
+ <span class='text-[#8f0d00] dark:text-[#ff2e1a] uppercase font-bold tracking-wider'>{{category}}</span>
22
+ {{#if readTime}}
23
+ <span class='mx-2 text-slate-400 dark:text-slate-500'>•</span>
24
+ <span class='article-time text-slate-500 dark:text-slate-400'>{{readTime}}</span>
25
+ {{/if}}
26
+ </div>
27
+ {{else if (lookup categories 0)}}
28
+ {{#with (lookup categories 0)}}
29
+ <div class='flex items-center {{#if ../metaTextSize}}{{../metaTextSize}}{{else}}text-xs{{/if}} mb-2'>
30
+ <span class='text-[#8f0d00] dark:text-[#ff2e1a] uppercase font-bold tracking-wider'>{{name}}</span>
31
+ {{#if ../readTime}}
32
+ <span class='mx-2 text-slate-400 dark:text-slate-500'>•</span>
33
+ <span class='article-time text-slate-500 dark:text-slate-400'>{{../readTime}}</span>
34
+ {{/if}}
35
+ </div>
36
+ {{/with}}
37
+ {{else if readTime}}
38
+ <div class='flex items-center {{#if metaTextSize}}{{metaTextSize}}{{else}}text-xs{{/if}} mb-2'>
39
+ <span class='article-time text-slate-500 dark:text-slate-400'>{{readTime}}</span>
40
+ </div>
41
+ {{/if}}
42
+ {{/unless}}
43
+ {{/if}}
@@ -0,0 +1 @@
1
+ {{> components/snack}}
@@ -1,71 +1,13 @@
1
- {{#*inline 'snackMetaImageRow'}}
2
- {{#if category}}
3
- <div class='w-full flex items-center justify-between {{#if metaTextSize}}{{metaTextSize}}{{else}}text-xs{{/if}} mb-2'>
4
- <span class='text-[#8f0d00] dark:text-[#ff2e1a] uppercase font-bold tracking-wider'>{{category}}</span>
5
- {{#if readTime}}
6
- <span class='article-time text-slate-500 dark:text-slate-400'>{{readTime}}</span>
7
- {{/if}}
8
- </div>
9
- {{else if (lookup categories 0)}}
10
- {{#with (lookup categories 0)}}
11
- <div class='w-full flex items-center justify-between {{#if ../metaTextSize}}{{../metaTextSize}}{{else}}text-xs{{/if}} mb-2'>
12
- <span class='text-[#8f0d00] dark:text-[#ff2e1a] uppercase font-bold tracking-wider'>{{name}}</span>
13
- {{#if ../readTime}}
14
- <span class='article-time text-slate-500 dark:text-slate-400'>{{../readTime}}</span>
15
- {{/if}}
16
- </div>
17
- {{/with}}
18
- {{else if readTime}}
19
- <div class='w-full flex items-center justify-end {{#if metaTextSize}}{{metaTextSize}}{{else}}text-xs{{/if}} mb-2'>
20
- <span class='article-time text-slate-500 dark:text-slate-400'>{{readTime}}</span>
21
- </div>
22
- {{/if}}
23
- {{/inline}}
24
-
25
- {{#*inline 'snackMetaInline'}}
26
- {{#if category}}
27
- <div class='flex items-center {{#if metaTextSize}}{{metaTextSize}}{{else}}text-xs{{/if}} mb-2'>
28
- <span class='text-[#8f0d00] dark:text-[#ff2e1a] uppercase font-bold tracking-wider'>{{category}}</span>
29
- {{#if readTime}}
30
- <span class='mx-2 text-slate-400 dark:text-slate-500'>•</span>
31
- <span class='article-time text-slate-500 dark:text-slate-400'>{{readTime}}</span>
32
- {{/if}}
33
- </div>
34
- {{else if (lookup categories 0)}}
35
- {{#with (lookup categories 0)}}
36
- <div class='flex items-center {{#if ../metaTextSize}}{{../metaTextSize}}{{else}}text-xs{{/if}} mb-2'>
37
- <span class='text-[#8f0d00] dark:text-[#ff2e1a] uppercase font-bold tracking-wider'>{{name}}</span>
38
- {{#if ../readTime}}
39
- <span class='mx-2 text-slate-400 dark:text-slate-500'>•</span>
40
- <span class='article-time text-slate-500 dark:text-slate-400'>{{../readTime}}</span>
41
- {{/if}}
42
- </div>
43
- {{/with}}
44
- {{else if readTime}}
45
- <div class='flex items-center {{#if metaTextSize}}{{metaTextSize}}{{else}}text-xs{{/if}} mb-2'>
46
- <span class='article-time text-slate-500 dark:text-slate-400'>{{readTime}}</span>
47
- </div>
48
- {{/if}}
49
- {{/inline}}
50
-
51
1
  <article class='{{#if className}}flex flex-col h-full {{className}} items-stretch{{else}}flex flex-col h-full py-4 border-t border-slate-100 dark:border-slate-800 items-stretch{{/if}}'>
52
2
  {{#unless (eq showImage false)}}
53
- {{#if image}}
54
- {{> snackMetaImageRow}}
55
- {{else if featuredImage.url}}
56
- {{> snackMetaImageRow}}
3
+ {{#if (coalesce image featuredImage.url)}}
4
+ {{> components/snack-meta-image-row}}
57
5
  {{/if}}
58
6
  {{/unless}}
59
7
 
60
8
  <div class='{{#if (eq showImage false)}}flex flex-col h-full{{else if image}}flex items-start gap-4{{else if featuredImage.url}}flex items-start gap-4{{else}}flex flex-col h-full{{/if}}'>
61
9
  <div class='flex-1'>
62
- {{#if (eq showImage false)}}
63
- {{> snackMetaInline}}
64
- {{else if image}}
65
- {{else if featuredImage.url}}
66
- {{else}}
67
- {{> snackMetaInline}}
68
- {{/if}}
10
+ {{> components/snack-meta-inline}}
69
11
 
70
12
  <h3 class='{{#if titleFontWeight}}{{titleFontWeight}}{{else}}font-bold{{/if}} {{#if titleTextSize}}{{titleTextSize}}{{else}}text-lg{{/if}} leading-snug text-slate-900 dark:text-slate-100 {{#if titleClasses}}{{titleClasses}}{{else}}font-encode{{/if}}'>
71
13
  <a href='{{url}}' class='hover:text-[#8f0d00] dark:hover:text-[#ff2e1a] transition-colors'>{{title}}</a>
@@ -0,0 +1 @@
1
+ {{> components/spotlight-hero}}
@@ -31,10 +31,10 @@
31
31
 
32
32
  <div class='w-full max-w-[592px] border-l border-white pl-4 md:pl-10 flex flex-col gap-4 md:gap-6 mb-8 md:mb-12'>
33
33
  <h1 class='text-3xl md:text-[44px] leading-tight md:leading-[56px] font-bold text-white font-encode'>
34
- <a href='{{articleUrl slug=slug categories=categories language=@root.language}}' class='hover:text-slate-300 transition-colors'>{{title}}</a>
34
+ <a href='{{url}}' class='hover:text-slate-300 transition-colors'>{{title}}</a>
35
35
  </h1>
36
36
  <p class='font-secondary text-xl md:text-2xl leading-7 md:leading-8 text-white self-stretch'>{{excerpt}}</p>
37
- <a href='{{articleUrl slug=slug categories=categories language=@root.language}}' class='border border-[#717273] rounded-md px-4 py-[11px] h-11 flex items-center justify-center whitespace-nowrap self-start hover:bg-white/10 transition-colors'>
37
+ <a href='{{url}}' class='border border-[#717273] rounded-md px-4 py-[11px] h-11 flex items-center justify-center whitespace-nowrap self-start hover:bg-white/10 transition-colors'>
38
38
  <span class='text-white text-base font-medium leading-[22px] font-sans'>Read More</span>
39
39
  </a>
40
40
  </div>
@@ -22,7 +22,7 @@
22
22
 
23
23
  <div class="prose dark:prose-invert max-w-none">
24
24
  {{#each body}}
25
- {{> (lookup . "type")}}
25
+ {{> components/body-block}}
26
26
  {{/each}}
27
27
  </div>
28
28
  </main>
@@ -5,13 +5,11 @@
5
5
  <meta name='viewport' content='width=device-width, initial-scale=1' />
6
6
  <link rel='preload' as='style' href='https://cdn.fifthbell.com/content/fonts/fonts.css' onload="this.rel='stylesheet';this.media='all'" />
7
7
  <noscript><link href='https://cdn.fifthbell.com/content/fonts/fonts.css' rel='stylesheet' /></noscript>
8
+ <link href='https://cdn.fifthbell.com/content/styles/brokaw.css' rel='stylesheet' />
8
9
  <meta name='description' content='{{#if seo.metaDescription}}{{seo.metaDescription}}{{else}}Page not found{{/if}}' />
9
10
  <link rel='canonical' href='{{canonicalUrl}}' />
10
11
  <title>{{#if seo.metaTitle}}{{seo.metaTitle}}{{else}}404 - Page Not Found | fifthbell{{/if}}</title>
11
- <style>{{{styles}}}</style>
12
- {{#if rumConfig}}
13
- {{{rumLoader rumConfig layout language}}}
14
- {{/if}}
12
+ {{> shell/rum-loader}}
15
13
  {{#if gaConfig}}
16
14
  <script async src='https://www.googletagmanager.com/gtag/js?id={{{gaConfig.measurementId}}}'></script>
17
15
  <script>
@@ -4,6 +4,7 @@
4
4
  <meta charset='UTF-8' />
5
5
  <meta name='viewport' content='width=device-width, initial-scale=1' />
6
6
  <link href='https://cdn.fifthbell.com/content/fonts/fonts.css' rel='stylesheet' />
7
+ <link href='https://cdn.fifthbell.com/content/styles/brokaw.css' rel='stylesheet' />
7
8
  {{#if (eq layout 'homepage')}}
8
9
  {{#if hero.url}}
9
10
  <link rel='preload' as='image' href='{{hero.url}}' fetchpriority='high' />
@@ -13,9 +14,9 @@
13
14
  <link rel='preload' as='image' href='{{featuredImage.url}}' fetchpriority='high' />
14
15
  {{/if}}
15
16
  {{/if}}
16
- <meta name='description' content='{{#if seo.metaDescription}}{{seo.metaDescription}}{{else if excerpt}}{{excerpt}}{{else}}{{resolveHeadTitle this}}{{/if}}' />
17
+ <meta name='description' content='{{#if seo.metaDescription}}{{seo.metaDescription}}{{else}}{{excerpt}}{{/if}}' />
17
18
  <link rel='canonical' href='{{canonicalUrl}}' />
18
- <meta property='og:title' content='{{resolveHeadTitle this}}' />
19
+ <meta property='og:title' content='{{#if seo.metaTitle}}{{seo.metaTitle}}{{else}}{{title}} | fifthbell{{/if}}' />
19
20
  <meta property='og:description' content='{{#if seo.metaDescription}}{{seo.metaDescription}}{{else}}{{excerpt}}{{/if}}' />
20
21
  <meta property='og:url' content='{{canonicalUrl}}' />
21
22
  <meta property='og:site_name' content='fifthbell' />
@@ -24,29 +25,26 @@
24
25
  {{else}}
25
26
  <meta property='og:type' content='website' />
26
27
  {{/if}}
27
- {{#with (socialImageUrl (coalesce seo.ogImage featuredImage.url)) as |socialImage|}}
28
+ {{#with (socialImageUrl this) as |socialImage|}}
28
29
  {{#if socialImage}}
29
30
  <meta property='og:image' content='{{socialImage}}' />
30
31
  <meta property='og:image:type' content='image/jpeg' />
31
32
  <meta property='og:image:width' content='1200' />
32
33
  <meta property='og:image:height' content='630' />
33
- <meta property='og:image:alt' content='{{#if featuredImage.alt}}{{featuredImage.alt}}{{else}}{{resolveHeadTitle this}}{{/if}}' />
34
+ <meta property='og:image:alt' content='{{socialImageAlt @root}}' />
34
35
  {{/if}}
35
36
  <meta name='twitter:card' content='{{#if socialImage}}summary_large_image{{else}}summary{{/if}}' />
36
37
  {{#if socialImage}}
37
38
  <meta name='twitter:image' content='{{socialImage}}' />
38
39
  <meta name='twitter:image:src' content='{{socialImage}}' />
39
- <meta name='twitter:image:alt' content='{{#if featuredImage.alt}}{{featuredImage.alt}}{{else}}{{resolveHeadTitle this}}{{/if}}' />
40
+ <meta name='twitter:image:alt' content='{{socialImageAlt @root}}' />
40
41
  {{/if}}
41
42
  {{/with}}
42
43
  <meta name='twitter:site' content='@thisisfifthbell' />
43
- <meta name='twitter:title' content='{{resolveHeadTitle this}}' />
44
+ <meta name='twitter:title' content='{{#if seo.metaTitle}}{{seo.metaTitle}}{{else}}{{title}} | fifthbell{{/if}}' />
44
45
  <meta name='twitter:description' content='{{#if seo.metaDescription}}{{seo.metaDescription}}{{else}}{{excerpt}}{{/if}}' />
45
- <title>{{resolveHeadTitle this}}</title>
46
- <style>{{{styles}}}</style>
47
- {{#if rumConfig}}
48
- {{{rumLoader rumConfig layout language}}}
49
- {{/if}}
46
+ <title>{{#if seo.metaTitle}}{{seo.metaTitle}}{{else}}{{title}} | fifthbell{{/if}}</title>
47
+ {{> shell/rum-loader}}
50
48
  {{#if gaConfig}}
51
49
  <script async src='https://www.googletagmanager.com/gtag/js?id={{{gaConfig.measurementId}}}'></script>
52
50
  <script>
@@ -0,0 +1,77 @@
1
+ {{#if rumConfig}}
2
+ <script data-brokaw-rum-loader>
3
+ (function () {
4
+ try {
5
+ function containsSensitiveErrorData(event) {
6
+ var reason = event && event.reason;
7
+ var error = event && event.error;
8
+ var candidate = [
9
+ event && event.message,
10
+ event && event.filename,
11
+ typeof reason === 'string' ? reason : reason && reason.message,
12
+ error && error.message
13
+ ].filter(Boolean).join(' ');
14
+ return candidate.length > 256 || /(?:https?:\/\/|[?#]|authorization|bearer|credential|password|passcode|api[_-]?key|access[_-]?token|refresh[_-]?token|<[^>]+>|[{}][^{}]{8,}[{}])/i.test(candidate);
15
+ }
16
+
17
+ (function (namespace, appMonitorId, applicationVersion, region, source, clientConfig, client, script) {
18
+ client = window.AwsRumClient = {
19
+ q: [],
20
+ n: namespace,
21
+ i: appMonitorId,
22
+ v: applicationVersion,
23
+ r: region,
24
+ c: clientConfig
25
+ };
26
+ window[namespace] = function (command, payload) {
27
+ client.q.push({ c: command, p: payload });
28
+ };
29
+ script = document.createElement('script');
30
+ script.async = true;
31
+ script.crossOrigin = 'anonymous';
32
+ script.src = source;
33
+ script.onerror = function () {
34
+ client.q = [];
35
+ window[namespace] = function () {};
36
+ };
37
+ document.head.appendChild(script);
38
+ })(
39
+ 'cwr',
40
+ {{{jsonString rumConfig.appMonitorId}}},
41
+ {{{jsonString rumConfig.applicationVersion}}},
42
+ {{{jsonString rumConfig.region}}},
43
+ 'https://client.rum.us-east-1.amazonaws.com/3.0.0/cwr.js',
44
+ {
45
+ identityPoolId: {{{jsonString rumConfig.identityPoolId}}},
46
+ guestRoleArn: {{{jsonString rumConfig.guestRoleArn}}},
47
+ sessionSampleRate: 1,
48
+ endpoint: 'https://dataplane.rum.' + {{{jsonString rumConfig.region}}} + '.amazonaws.com',
49
+ telemetries: [
50
+ ['errors', { stackTraceLength: 0, ignore: containsSensitiveErrorData }],
51
+ ['performance', {
52
+ ignore: function (entry) { return entry && entry.entryType === 'resource'; },
53
+ recordAllTypes: [],
54
+ sampleTypes: []
55
+ }]
56
+ ],
57
+ allowCookies: false,
58
+ enableXRay: false,
59
+ recordResourceUrl: false,
60
+ pageIdFormat: 'PATH',
61
+ disableAutoPageView: true
62
+ }
63
+ );
64
+
65
+ window.cwr('recordPageView', {
66
+ pageId: window.location.pathname,
67
+ pageAttributes: {
68
+ page_type: {{{jsonString layout}}},
69
+ content_language: {{{jsonString language}}}
70
+ }
71
+ });
72
+ } catch (_rumError) {
73
+ // Monitoring is optional and must never block rendering or navigation.
74
+ }
75
+ })();
76
+ </script>
77
+ {{/if}}
@@ -149,8 +149,6 @@
149
149
  </div>
150
150
  {{#if qrCodeHtml}}
151
151
  {{{qrCodeHtml}}}
152
- {{else if url}}
153
- {{{instagramQrCode url}}}
154
152
  {{/if}}
155
153
  <div class="category-label">{{categoryName}}</div>
156
154
  </header>