pageflow 15.7.1 → 16.0.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (201) hide show
  1. checksums.yaml +4 -4
  2. data/CHANGELOG.md +33 -243
  3. data/README.md +1 -9
  4. data/Rakefile +4 -1
  5. data/admins/pageflow/accounts.rb +12 -16
  6. data/admins/pageflow/entry.rb +57 -28
  7. data/admins/pageflow/entry_templates.rb +5 -7
  8. data/admins/pageflow/sites.rb +50 -0
  9. data/admins/pageflow/user.rb +7 -0
  10. data/app/assets/javascripts/pageflow/admin/entries.js +53 -4
  11. data/app/assets/stylesheets/pageflow/admin/permalink_input.scss +65 -0
  12. data/app/assets/stylesheets/pageflow/admin.scss +1 -0
  13. data/app/assets/stylesheets/pageflow/editor/base.scss +2 -6
  14. data/app/assets/stylesheets/pageflow/editor/dialogs.scss +2 -0
  15. data/app/assets/stylesheets/pageflow/editor/drop_down_button.scss +9 -0
  16. data/app/assets/stylesheets/pageflow/editor/info_box.scss +13 -3
  17. data/app/assets/stylesheets/pageflow/mixins/buttons.scss +1 -0
  18. data/app/assets/stylesheets/pageflow/page.scss +0 -2
  19. data/app/assets/stylesheets/pageflow/themes/default/page.scss +1 -1
  20. data/app/assets/stylesheets/pageflow/ui/forms.scss +4 -1
  21. data/app/controllers/pageflow/editor/file_import_controller.rb +32 -42
  22. data/app/controllers/pageflow/entries_controller.rb +27 -3
  23. data/app/helpers/pageflow/admin/permalinks_helper.rb +15 -0
  24. data/app/helpers/pageflow/common_entry_seed_helper.rb +1 -1
  25. data/app/helpers/pageflow/embed_code_helper.rb +1 -1
  26. data/app/helpers/pageflow/entries_helper.rb +25 -17
  27. data/app/helpers/pageflow/sites_helper.rb +11 -0
  28. data/app/helpers/pageflow/social_share_helper.rb +2 -2
  29. data/app/inputs/pageflow_permalink_input.rb +47 -0
  30. data/app/models/concerns/pageflow/permalinkable.rb +12 -0
  31. data/app/models/concerns/pageflow/reusable_file.rb +5 -0
  32. data/app/models/concerns/pageflow/uploadable_file.rb +4 -0
  33. data/app/models/pageflow/account.rb +7 -33
  34. data/app/models/pageflow/{cname_theming_request_scope.rb → cname_site_request_scope.rb} +3 -3
  35. data/app/models/pageflow/customized_theme.rb +5 -3
  36. data/app/models/pageflow/entry.rb +8 -4
  37. data/app/models/pageflow/entry_at_revision.rb +4 -3
  38. data/app/models/pageflow/entry_duplicate.rb +8 -1
  39. data/app/models/pageflow/entry_template.rb +4 -4
  40. data/app/models/pageflow/home_button.rb +7 -7
  41. data/app/models/pageflow/image_file_url_templates.rb +2 -2
  42. data/app/models/pageflow/permalink.rb +39 -0
  43. data/app/models/pageflow/permalink_directory.rb +10 -0
  44. data/app/models/pageflow/published_entry.rb +19 -2
  45. data/app/models/pageflow/revision.rb +1 -1
  46. data/app/models/pageflow/site.rb +59 -0
  47. data/app/models/pageflow/theme_customization.rb +1 -1
  48. data/app/models/pageflow/theme_customization_file.rb +6 -1
  49. data/app/policies/pageflow/account_policy.rb +2 -2
  50. data/app/policies/pageflow/entry_policy.rb +2 -2
  51. data/app/policies/pageflow/entry_template_policy.rb +1 -1
  52. data/app/policies/pageflow/{theming_policy.rb → site_policy.rb} +13 -11
  53. data/app/views/admin/accounts/_entry_template_details.html.arb +1 -1
  54. data/app/views/admin/accounts/_form.html.erb +4 -22
  55. data/app/views/admin/accounts/_site_defaults_inline_help.html.erb +5 -0
  56. data/app/views/admin/entries/_form.html.erb +11 -12
  57. data/app/views/admin/entries/_permalink_inputs.html.erb +6 -0
  58. data/app/views/admin/entries/_site_input.html.erb +15 -0
  59. data/app/views/admin/entries/{entry_type_name_input.html.erb → entry_site_and_type_name_input.html.erb} +3 -0
  60. data/app/views/admin/entries/permalink_inputs.html.erb +7 -0
  61. data/app/views/admin/entry_templates/_form.html.erb +5 -5
  62. data/app/views/admin/sites/_attributes_table.html.arb +9 -0
  63. data/app/views/admin/sites/_fields.html.erb +17 -0
  64. data/app/views/admin/sites/_form.html.erb +5 -0
  65. data/app/views/components/pageflow/admin/entries_tab.rb +1 -2
  66. data/app/views/components/pageflow/admin/entry_templates_tab.rb +10 -11
  67. data/app/views/components/pageflow/admin/features_tab.rb +1 -1
  68. data/app/views/components/pageflow/admin/sites_tab.rb +32 -0
  69. data/app/views/components/pageflow/admin/users_tab.rb +1 -2
  70. data/app/views/pageflow/editor/entries/seed.json.erb +1 -1
  71. data/app/views/pageflow/editor/file_import/start_import_job.json.jbuilder +10 -0
  72. data/app/views/pageflow/editor/sites/_site.json.jbuilder +1 -0
  73. data/app/views/pageflow/entries/{_theming.css.erb → _site.css.erb} +0 -0
  74. data/app/views/pageflow/entries/stylesheet.css.erb +1 -1
  75. data/app/views/pageflow/files/_file.json.jbuilder +1 -0
  76. data/app/views/pageflow/social_share/_entry_meta_tags.html.erb +1 -1
  77. data/app/views/pageflow/social_share/_page_meta_tags.html.erb +1 -1
  78. data/config/initializers/admin_resource_tabs.rb +29 -12
  79. data/config/initializers/mime_types.rb +1 -0
  80. data/config/locales/de.yml +19 -17
  81. data/config/locales/en.yml +19 -17
  82. data/config/routes.rb +8 -5
  83. data/db/migrate/20221024100724_create_pageflow_permalink_directories.rb +10 -0
  84. data/db/migrate/20221025074049_add_permalink_attributes_to_entries.rb +5 -0
  85. data/db/migrate/20221027065022_create_pageflow_permalinks.rb +12 -0
  86. data/db/migrate/20221215101134_rename_theming_to_site.rb +9 -0
  87. data/db/migrate/20221215120856_associate_entry_templates_with_sites.rb +34 -0
  88. data/db/migrate/20221219203023_add_name_to_sites.rb +5 -0
  89. data/db/migrate/20230103155934_associate_theme_customizations_with_sites.rb +27 -0
  90. data/entry_types/paged/app/assets/javascripts/pageflow_paged/dist/editor.js +176 -179
  91. data/entry_types/paged/app/assets/javascripts/pageflow_paged/dist/frontend.js +49 -7
  92. data/entry_types/paged/app/assets/javascripts/pageflow_paged/dist/react-client.js +5 -5
  93. data/entry_types/paged/app/assets/javascripts/pageflow_paged/dist/react-server.js +1 -1
  94. data/entry_types/paged/config/initializers/features.rb +2 -0
  95. data/entry_types/paged/config/locales/{new/help.de.yml → de.yml} +74 -65
  96. data/entry_types/paged/config/locales/{new/help.en.yml → en.yml} +66 -56
  97. data/entry_types/scrolled/app/helpers/pageflow_scrolled/favicon_helper.rb +39 -13
  98. data/entry_types/scrolled/app/helpers/pageflow_scrolled/generated_media_queries_helper.rb +55 -0
  99. data/entry_types/scrolled/app/helpers/pageflow_scrolled/themes_helper.rb +6 -2
  100. data/entry_types/scrolled/app/views/pageflow_scrolled/editor/entries/_head.html.erb +2 -0
  101. data/entry_types/scrolled/app/views/pageflow_scrolled/entries/_manifest.json.jbuilder +16 -0
  102. data/entry_types/scrolled/app/views/pageflow_scrolled/entries/show.html.erb +9 -3
  103. data/entry_types/scrolled/app/views/pageflow_scrolled/entry_json_seed/_entry.json.jbuilder +5 -5
  104. data/entry_types/scrolled/app/views/pageflow_scrolled/favicons/_entry.html.erb +16 -10
  105. data/entry_types/scrolled/config/locales/de.yml +265 -76
  106. data/entry_types/scrolled/config/locales/en.yml +266 -77
  107. data/entry_types/scrolled/lib/pageflow_scrolled/configuration.rb +3 -3
  108. data/entry_types/scrolled/lib/pageflow_scrolled/plugin.rb +14 -0
  109. data/entry_types/scrolled/lib/pageflow_scrolled/react_widget_type.rb +1 -1
  110. data/entry_types/scrolled/lib/pageflow_scrolled/seeds.rb +1 -1
  111. data/entry_types/scrolled/lib/pageflow_scrolled/web_app_manifest.rb +11 -0
  112. data/entry_types/scrolled/lib/pageflow_scrolled.rb +39 -1
  113. data/entry_types/scrolled/lib/tasks/pageflow_scrolled/storybook.rake +3 -2
  114. data/entry_types/scrolled/package/contentElements-editor.js +124 -38
  115. data/entry_types/scrolled/package/contentElements-frontend.css +1 -1
  116. data/entry_types/scrolled/package/contentElements-frontend.js +321 -27
  117. data/entry_types/scrolled/package/editor.js +1345 -739
  118. data/entry_types/scrolled/package/frontend/EditableInlineText.module-14c7b097.js +5314 -0
  119. data/entry_types/scrolled/package/frontend/{PhonePlatformContext-9fb97827.js → PhonePlatformContext-f6093cc6.js} +87 -223
  120. data/entry_types/scrolled/package/frontend/{Viewer-e2290ea0.js → Viewer-b6becc57.js} +6 -40
  121. data/entry_types/scrolled/package/frontend/arrowRight-78a7cee4.js +42 -0
  122. data/entry_types/scrolled/package/frontend/{components-6ab26015.js → components-b3160dd7.js} +546 -361
  123. data/entry_types/scrolled/package/frontend/index.css +1 -1
  124. data/entry_types/scrolled/package/frontend/index.js +398 -3692
  125. data/entry_types/scrolled/package/package.json +3 -2
  126. data/entry_types/scrolled/package/testHelpers.js +12 -2
  127. data/entry_types/scrolled/package/widgets/defaultNavigation.css +2 -2
  128. data/entry_types/scrolled/package/widgets/defaultNavigation.js +50 -40
  129. data/entry_types/scrolled/spec/fixtures/image.ico +0 -0
  130. data/lib/pageflow/ability_mixin.rb +16 -8
  131. data/lib/pageflow/admin/attributes_table_rows.rb +1 -1
  132. data/lib/pageflow/admin/form_inputs.rb +1 -1
  133. data/lib/pageflow/admin/tabs.rb +1 -1
  134. data/lib/pageflow/configuration/permissions.rb +3 -3
  135. data/lib/pageflow/configuration.rb +17 -17
  136. data/lib/pageflow/entry_export_import/entry_serialization.rb +1 -1
  137. data/lib/pageflow/entry_type.rb +6 -2
  138. data/lib/pageflow/primary_domain_entry_redirect.rb +7 -7
  139. data/lib/pageflow/seeds.rb +10 -10
  140. data/lib/pageflow/theme_customizations.rb +10 -10
  141. data/lib/pageflow/version.rb +1 -1
  142. data/package/editor.js +129 -156
  143. data/package/frontend.js +19 -2
  144. data/package/testHelpers.js +39 -6
  145. data/spec/factories/accounts.rb +5 -2
  146. data/spec/factories/draft_entries.rb +2 -2
  147. data/spec/factories/entries.rb +18 -1
  148. data/spec/factories/entry_templates.rb +1 -1
  149. data/spec/factories/permalink_directory.rb +6 -0
  150. data/spec/factories/permalinks.rb +4 -0
  151. data/spec/factories/published_entries.rb +4 -2
  152. data/spec/factories/sites.rb +9 -0
  153. metadata +50 -62
  154. data/app/assets/javascripts/pageflow/dist/editor.js +0 -11890
  155. data/app/assets/javascripts/pageflow/dist/frontend.js +0 -5800
  156. data/app/assets/javascripts/pageflow/dist/react-client.js +0 -22
  157. data/app/assets/javascripts/pageflow/dist/react-server.js +0 -19
  158. data/app/helpers/pageflow/themings_helper.rb +0 -11
  159. data/app/models/pageflow/theming.rb +0 -29
  160. data/app/views/admin/accounts/_theming_defaults_inline_help.html.erb +0 -5
  161. data/app/views/admin/accounts/_theming_details.html.arb +0 -5
  162. data/app/views/pageflow/editor/themings/_theming.json.jbuilder +0 -1
  163. data/entry_types/paged/config/locales/new/video_contain.de.yml +0 -7
  164. data/entry_types/paged/config/locales/new/video_contain.en.yml +0 -7
  165. data/entry_types/scrolled/config/locales/new/before_after_slider.de.yml +0 -8
  166. data/entry_types/scrolled/config/locales/new/before_after_slider.en.yml +0 -8
  167. data/entry_types/scrolled/config/locales/new/center_ragged.de.yml +0 -8
  168. data/entry_types/scrolled/config/locales/new/center_ragged.en.yml +0 -9
  169. data/entry_types/scrolled/config/locales/new/consent.de.yml +0 -25
  170. data/entry_types/scrolled/config/locales/new/consent.en.yml +0 -24
  171. data/entry_types/scrolled/config/locales/new/content_element_categories.de.yml +0 -39
  172. data/entry_types/scrolled/config/locales/new/content_element_categories.en.yml +0 -39
  173. data/entry_types/scrolled/config/locales/new/default_transition.de.yml +0 -14
  174. data/entry_types/scrolled/config/locales/new/default_transition.en.yml +0 -14
  175. data/entry_types/scrolled/config/locales/new/header_line_breaks.de.yml +0 -28
  176. data/entry_types/scrolled/config/locales/new/header_line_breaks.en.yml +0 -27
  177. data/entry_types/scrolled/config/locales/new/header_size.de.yml +0 -17
  178. data/entry_types/scrolled/config/locales/new/header_size.en.yml +0 -17
  179. data/entry_types/scrolled/config/locales/new/iframe_embed.de.yml +0 -39
  180. data/entry_types/scrolled/config/locales/new/iframe_embed.en.yml +0 -39
  181. data/entry_types/scrolled/config/locales/new/inline_loops.de.yml +0 -26
  182. data/entry_types/scrolled/config/locales/new/inline_loops.en.yml +0 -26
  183. data/entry_types/scrolled/config/locales/new/portrait_inline_image.de.yml +0 -9
  184. data/entry_types/scrolled/config/locales/new/portrait_inline_image.en.yml +0 -9
  185. data/entry_types/scrolled/config/locales/new/section_width.de.yml +0 -10
  186. data/entry_types/scrolled/config/locales/new/section_width.en.yml +0 -10
  187. data/entry_types/scrolled/config/locales/new/typography_variants.de.yml +0 -7
  188. data/entry_types/scrolled/config/locales/new/typography_variants.en.yml +0 -7
  189. data/entry_types/scrolled/config/locales/new/video_embed_poster.de.yml +0 -8
  190. data/entry_types/scrolled/config/locales/new/video_embed_poster.en.yml +0 -8
  191. data/entry_types/scrolled/config/locales/new/waveform_styles.de.yml +0 -11
  192. data/entry_types/scrolled/config/locales/new/waveform_styles.en.yml +0 -12
  193. data/entry_types/scrolled/config/locales/new/widgets.de.yml +0 -6
  194. data/entry_types/scrolled/config/locales/new/widgets.en.yml +0 -6
  195. data/entry_types/scrolled/lib/generators/pageflow_scrolled/install/templates/theme/favicons/browserconfig.xml +0 -9
  196. data/entry_types/scrolled/lib/generators/pageflow_scrolled/install/templates/theme/favicons/mstile-150x150.png +0 -0
  197. data/entry_types/scrolled/lib/generators/pageflow_scrolled/install/templates/theme/favicons/safari-pinned-tab.svg +0 -46
  198. data/entry_types/scrolled/lib/generators/pageflow_scrolled/install/templates/theme/favicons/site.webmanifest +0 -19
  199. data/entry_types/scrolled/package/frontend/EditableInlineText.module-b9923660.js +0 -993
  200. data/entry_types/scrolled/package/frontend/usePhonePlatform-2857c22b.js +0 -34
  201. data/spec/factories/themings.rb +0 -7
@@ -8,6 +8,7 @@
8
8
  "license": "MIT",
9
9
  "dependencies": {
10
10
  "@egjs/view360": "^3.4.3",
11
+ "@headlessui/react": "^1.6.6",
11
12
  "core-js": "^3.6.5",
12
13
  "debounce": "^1.2.0",
13
14
  "deep-assign": "^3.0.0",
@@ -47,7 +48,7 @@
47
48
  "@testing-library/jest-dom": "^5.14.1",
48
49
  "@testing-library/react": "^12.0.0",
49
50
  "@testing-library/react-hooks": "^7.0.1",
50
- "@testing-library/user-event": "^13.5.0",
51
+ "@testing-library/user-event": "^14.4.3",
51
52
  "@typescript-eslint/eslint-plugin": "2.x",
52
53
  "@typescript-eslint/parser": "2.x",
53
54
  "babel-eslint": "10.x",
@@ -77,6 +78,6 @@
77
78
  "lint": "eslint .",
78
79
  "start-storybook": "start-storybook -s .storybook/static",
79
80
  "build-storybook": "build-storybook -s .storybook/static -o .storybook/out",
80
- "snapshot": "STORYBOOK_SPLIT=true build-storybook --quiet -s .storybook/static -o .storybook/out && PERCY_TOKEN=${PERCY_TOKEN:-$PT} percy-storybook --widths=1280 --build_dir=.storybook/out"
81
+ "snapshot": "build-storybook --quiet -s .storybook/static -o .storybook/out && PERCY_TOKEN=${PERCY_TOKEN:-$PT} percy-storybook --widths=1280 --build_dir=.storybook/out"
81
82
  }
82
83
  }
@@ -128,12 +128,16 @@ function normalizeSeed() {
128
128
  themeOptions: themeOptions,
129
129
  themeAssets: themeAssets
130
130
  }),
131
- additionalSeedData: additionalSeedData || {}
131
+ additionalSeedData: additionalSeedData || {
132
+ frontendVersion: 1
133
+ }
132
134
  },
133
135
  collections: {
134
136
  entries: normalizedEntries,
135
137
  imageFiles: normalizeCollection(imageFiles, {
136
138
  isReady: true,
139
+ basename: 'image',
140
+ extension: 'jpg',
137
141
  width: 1920,
138
142
  height: 1279,
139
143
  configuration: {}
@@ -183,7 +187,13 @@ function normalizeSections() {
183
187
  }, sectionDefaults)];
184
188
  }
185
189
 
186
- return normalizeCollection(sections, sectionDefaults);
190
+ return normalizeCollection(sections, sectionDefaults).map(function (section) {
191
+ return _objectSpread2(_objectSpread2({}, section), {}, {
192
+ configuration: _objectSpread2({
193
+ transition: sectionDefaults.configuration.transition
194
+ }, section.configuration)
195
+ });
196
+ });
187
197
  }
188
198
 
189
199
  function normalizeChapters() {
@@ -1,4 +1,4 @@
1
- .DefaultNavigation-module_navigationBar__2RK0h{--default-navigation-bar-height:var(--theme-default-navigation-bar-height,50px);--default-navigation-scroller-top:var(--theme-default-navigation-scroller-top,0);--default-navigation-scroll-button-top:var(--theme-default-navigation-scroll-button-top,5px);--default-navigation-chapter-link-height:var(--theme-default-navigation-chapter-link-height,50px);--default-navigation-progress-indicator-height:var(--theme-default-navigation-progress-indicator-height,10px);font-family:var(--theme-widget-font-family);position:fixed;top:calc(-1*var(--default-navigation-bar-height));transition:top .15s;z-index:10000;width:100%;text-align:center;height:0;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none}.DefaultNavigation-module_navigationBarExpanded__C3sLq{top:0}.DefaultNavigation-module_navigationBarContentWrapper__3narH{position:relative;z-index:2;background-color:var(--theme-widget-surface-color);color:var(--theme-widget-on-surface-color);height:var(--default-navigation-bar-height);box-sizing:border-box;padding-top:var(--default-navigation-scroller-top)}.DefaultNavigation-module_menuIcon__2bb8s{position:absolute;top:0;left:12px;height:var(--default-navigation-bar-height)}.DefaultNavigation-module_contextIcons__2e65s{position:absolute;top:0;right:12px;display:flex}.DefaultNavigation-module_contextIcons__2e65s>*{pointer-events:auto}.DefaultNavigation-module_contextIcon__ELsqa{cursor:pointer;width:40px;height:var(--default-navigation-bar-height);color:var(--theme-widget-secondary-color);fill:currentcolor;stroke:currentColor}.DefaultNavigation-module_contextIcon__ELsqa svg{width:35px;height:35px;margin:7px 2px}.DefaultNavigation-module_contextIcon__ELsqa:hover,div:focus-within>.DefaultNavigation-module_contextIcon__ELsqa{color:var(--theme-widget-primary-color)}.DefaultNavigation-module_logo__3gUbx{top:0;left:15px;height:100%;max-width:15%}.DefaultNavigation-module_logo__3gUbx img{height:100%;max-width:100%;-o-object-fit:contain;object-fit:contain}.DefaultNavigation-module_chapterList__3VoXX{padding:0;margin:0;list-style:none;display:flex}.DefaultNavigation-module_chapterListItem__1YF5e{position:relative;padding:0 5px;border-right:1px solid #e9e9e9}.DefaultNavigation-module_chapterListItem__1YF5e:last-of-type{border-right:none}.DefaultNavigation-module_navigationTooltip__26Fvn{opacity:1!important;box-shadow:0 0 .3125rem rgba(0,0,0,.2)}.DefaultNavigation-module_progressBar__1jvov{position:relative;background-color:hsla(0,0%,76.1%,.8);height:8px;width:100%}.DefaultNavigation-module_progressIndicator__2d_e3{position:absolute;top:0;left:0;width:0;height:100%;background-color:var(--theme-accent-color)}@media screen and (max-width:767px){.DefaultNavigation-module_logo__3gUbx{max-width:30%}.DefaultNavigation-module_hasChapters__3ab-r .DefaultNavigation-module_logo__3gUbx{left:65px}.DefaultNavigation-module_navigationChapters__3M6zh{display:block;position:fixed;top:calc(var(--default-navigation-bar-height) + var(--default-navigation-progress-indicator-height));left:0;background:var(--theme-widget-background-color);width:100vw;bottom:0;-ms-scroll-chaining:none;overscroll-behavior:contain;overflow:scroll}.DefaultNavigation-module_navigationChaptersHidden__2TrUo{display:none}.DefaultNavigation-module_chapterList__3VoXX{display:block;padding-top:var(--default-navigation-bar-height);box-sizing:border-box;min-height:101%}.DefaultNavigation-module_chapterListItem__1YF5e{width:80vw;padding:25px 10vw;border-right:none}.DefaultNavigation-module_chapterListItem__1YF5e:after,.DefaultNavigation-module_chapterListItem__1YF5e:before{display:table;content:" ";border-top:1px solid #646464;width:14%;margin:0 43%;transition:width .15s,margin .15s}.DefaultNavigation-module_chapterListItem__1YF5e:hover:after,.DefaultNavigation-module_chapterListItem__1YF5e:hover:before{border-top:1px solid var(--theme-widget-primary-color);width:80%;margin:0 10%}.DefaultNavigation-module_chapterListItem__1YF5e p{margin-top:0}.DefaultNavigation-module_progressBar__1jvov{height:var(--default-navigation-progress-indicator-height)}}@media print{.DefaultNavigation-module_navigationBar__2RK0h{position:relative;top:0;height:auto}.DefaultNavigation-module_logo__3gUbx{left:0}.DefaultNavigation-module_chapterList__3VoXX,.DefaultNavigation-module_contextIcons__2e65s,.DefaultNavigation-module_progressBar__1jvov{display:none}}@media (min-width:768px){.HamburgerIcon-module_burgerMenuIconContainer__3aBkk{display:none}}.HamburgerIcon-module_burgerMenuIcon__1WUV0{outline:none}
1
+ .DefaultNavigation-module_navigationBar__2RK0h{--default-navigation-bar-height:var(--theme-default-navigation-bar-height,50px);--default-navigation-scroller-top:var(--theme-default-navigation-scroller-top,0);--default-navigation-scroll-button-top:var(--theme-default-navigation-scroll-button-top,5px);--default-navigation-chapter-link-height:var(--theme-default-navigation-chapter-link-height,50px);--default-navigation-progress-bar-height:var(--theme-default-navigation-progress-bar-height,8px);--default-navigation-separator-color:var(--theme-default-navigation-separator-color,#e9e9e9);font-family:var(--theme-widget-font-family);position:fixed;top:calc(-1*var(--default-navigation-bar-height));transition:top .15s;z-index:10000;width:100%;text-align:center;height:0;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none}.DefaultNavigation-module_navigationBarExpanded__C3sLq{top:0}.DefaultNavigation-module_navigationBarContentWrapper__3narH{position:relative;z-index:2;background-color:var(--theme-widget-surface-color);color:var(--theme-widget-on-surface-color);height:var(--default-navigation-bar-height);box-sizing:border-box;padding-top:var(--default-navigation-scroller-top)}.DefaultNavigation-module_menuIcon__2bb8s{position:absolute;top:0;left:12px;height:var(--default-navigation-bar-height)}.DefaultNavigation-module_contextIcons__2e65s{position:absolute;top:0;right:12px;display:flex}.DefaultNavigation-module_contextIcons__2e65s>*{pointer-events:auto}.DefaultNavigation-module_contextIcon__ELsqa{cursor:pointer;width:40px;height:var(--default-navigation-bar-height);color:var(--theme-widget-secondary-color);fill:currentcolor;stroke:currentColor}.DefaultNavigation-module_contextIcon__ELsqa svg{width:35px;height:35px;margin:7px 2px}.DefaultNavigation-module_contextIcon__ELsqa:hover,div:focus-within>.DefaultNavigation-module_contextIcon__ELsqa{color:var(--theme-widget-primary-color)}.DefaultNavigation-module_logo__3gUbx{top:0;left:15px;height:100%;max-width:15%}.DefaultNavigation-module_logo__3gUbx img{height:100%;max-width:100%;-o-object-fit:contain;object-fit:contain}.DefaultNavigation-module_chapterList__3VoXX{padding:0;margin:0;list-style:none;display:flex}.DefaultNavigation-module_chapterListItem__1YF5e{position:relative;padding:0 5px;border-right:1px solid var(--default-navigation-separator-color)}.DefaultNavigation-module_chapterListItem__1YF5e:last-of-type{border-right:none}.DefaultNavigation-module_navigationTooltip__26Fvn{opacity:1!important;box-shadow:0 0 .3125rem rgba(0,0,0,.2)}.DefaultNavigation-module_progressBar__1jvov{position:relative;background-color:var(--theme-default-navigation-progress-bar-background-color,hsla(0,0%,76.1%,.8));height:var(--default-navigation-progress-bar-height);width:100%}.DefaultNavigation-module_progressIndicator__2d_e3{position:absolute;top:0;left:0;width:0;height:100%;background-color:var(--theme-default-navigation-progress-bar-indicator-color,var(--theme-accent-color))}@media screen and (max-width:767px){.DefaultNavigation-module_navigationBar__2RK0h{--default-navigation-progress-bar-height:var(--theme-default-navigation-progress-bar-height,10px)}.DefaultNavigation-module_logo__3gUbx{max-width:30%}.DefaultNavigation-module_hasChapters__3ab-r .DefaultNavigation-module_logo__3gUbx{left:65px}.DefaultNavigation-module_navigationChapters__3M6zh{display:block;position:fixed;top:calc(var(--default-navigation-bar-height) + var(--default-navigation-progress-bar-height));left:0;background:var(--theme-widget-background-color);width:100vw;bottom:0;-ms-scroll-chaining:none;overscroll-behavior:contain;overflow:scroll}.DefaultNavigation-module_navigationChaptersHidden__2TrUo{display:none}.DefaultNavigation-module_chapterList__3VoXX{display:block;padding-top:var(--default-navigation-bar-height);box-sizing:border-box;min-height:101%}.DefaultNavigation-module_chapterListItem__1YF5e{padding:1rem;margin:0 1.5rem;border-right:none;border-bottom:1px solid var(--default-navigation-separator-color)}.DefaultNavigation-module_chapterListItem__1YF5e:last-child{border-bottom:none}.DefaultNavigation-module_chapterListItem__1YF5e p{margin-top:0}}@media print{.DefaultNavigation-module_navigationBar__2RK0h{position:relative;top:0;height:auto}.DefaultNavigation-module_logo__3gUbx{left:0}.DefaultNavigation-module_chapterList__3VoXX,.DefaultNavigation-module_contextIcons__2e65s,.DefaultNavigation-module_progressBar__1jvov{display:none}}@media (min-width:768px){.HamburgerIcon-module_burgerMenuIconContainer__3aBkk{display:none}}.HamburgerIcon-module_burgerMenuIcon__1WUV0{outline:none}.HamburgerIcon-module_small__asAkY{--hamburger-icon-transform:scale(0.7);--hamburger-icon-line-width:3px}
2
2
 
3
3
  /*!
4
4
  * Hamburgers
@@ -6,4 +6,4 @@
6
6
  * @author Jonathan Suh @jonsuh
7
7
  * @site https://jonsuh.com/hamburgers
8
8
  * @link https://github.com/jonsuh/hamburgers
9
- */.HamburgerIcons-module_hamburger__SOreS{display:inline-block;cursor:pointer;transition-property:opacity,filter;transition-duration:.15s;transition-timing-function:linear;font:inherit;color:inherit;text-transform:none;background-color:transparent;border:0;margin:0;overflow:visible}.HamburgerIcons-module_hamburger__SOreS.HamburgerIcons-module_is-active__2jpzX .HamburgerIcons-module_hamburger-inner__Wv7Dn,.HamburgerIcons-module_hamburger__SOreS.HamburgerIcons-module_is-active__2jpzX .HamburgerIcons-module_hamburger-inner__Wv7Dn:after,.HamburgerIcons-module_hamburger__SOreS.HamburgerIcons-module_is-active__2jpzX .HamburgerIcons-module_hamburger-inner__Wv7Dn:before{background-color:var(--theme-accent-color)}.HamburgerIcons-module_hamburger-box__10MR1{width:40px;height:24px;display:inline-block;position:relative;vertical-align:top}.HamburgerIcons-module_hamburger-inner__Wv7Dn{display:block;top:50%;margin-top:-2px}.HamburgerIcons-module_hamburger-inner__Wv7Dn,.HamburgerIcons-module_hamburger-inner__Wv7Dn:after,.HamburgerIcons-module_hamburger-inner__Wv7Dn:before{width:30px;height:4px;background-color:var(--theme-widget-primary-color);border-radius:4px;position:absolute;transition-property:transform;transition-duration:.15s;transition-timing-function:ease}.HamburgerIcons-module_hamburger-inner__Wv7Dn:after,.HamburgerIcons-module_hamburger-inner__Wv7Dn:before{content:"";display:block}.HamburgerIcons-module_hamburger-inner__Wv7Dn:before{top:-10px}.HamburgerIcons-module_hamburger-inner__Wv7Dn:after{bottom:-10px}.HamburgerIcons-module_hamburger--collapse__1xOkf .HamburgerIcons-module_hamburger-inner__Wv7Dn{top:auto;bottom:0;transition-duration:.13s;transition-delay:.13s;transition-timing-function:cubic-bezier(.55,.055,.675,.19)}.HamburgerIcons-module_hamburger--collapse__1xOkf .HamburgerIcons-module_hamburger-inner__Wv7Dn:after{top:-20px;transition:top .2s cubic-bezier(.33333,.66667,.66667,1) .2s,opacity .1s linear}.HamburgerIcons-module_hamburger--collapse__1xOkf .HamburgerIcons-module_hamburger-inner__Wv7Dn:before{transition:top .12s cubic-bezier(.33333,.66667,.66667,1) .2s,transform .13s cubic-bezier(.55,.055,.675,.19)}.HamburgerIcons-module_hamburger--collapse__1xOkf.HamburgerIcons-module_is-active__2jpzX .HamburgerIcons-module_hamburger-inner__Wv7Dn{transform:translate3d(0,-10px,0) rotate(-45deg);transition-delay:.22s;transition-timing-function:cubic-bezier(.215,.61,.355,1)}.HamburgerIcons-module_hamburger--collapse__1xOkf.HamburgerIcons-module_is-active__2jpzX .HamburgerIcons-module_hamburger-inner__Wv7Dn:after{top:0;opacity:0;transition:top .2s cubic-bezier(.33333,0,.66667,.33333),opacity .1s linear .22s}.HamburgerIcons-module_hamburger--collapse__1xOkf.HamburgerIcons-module_is-active__2jpzX .HamburgerIcons-module_hamburger-inner__Wv7Dn:before{top:0;transform:rotate(-90deg);transition:top .1s cubic-bezier(.33333,0,.66667,.33333) .16s,transform .13s cubic-bezier(.215,.61,.355,1) .25s}.ChapterLink-module_chapterLink__3YspQ{line-height:42px;color:var(--theme-widget-primary-color);text-decoration:none;position:relative;display:block;font-family:inherit;font-weight:700;font-size:1rem;height:42px;white-space:nowrap;padding:0 10px;margin:4px 0}.ChapterLink-module_chapterLink__3YspQ:hover,.ChapterLink-module_chapterLinkActive__9i8SL{color:var(--theme-accent-color)}.ChapterLink-module_summary__2ZfRU{color:var(--theme-widget-on-background-color)}.ChapterLink-module_tooltipBubble__3VRUO{display:none}@media (min-width:768px){.ChapterLink-module_summary__2ZfRU{display:none}.ChapterLink-module_tooltipBubble__3VRUO{display:block}}.LegalInfoMenu-module_legalInfoTooltip__Qmf8u{text-align:left}.LegalInfoMenu-module_scroller__3NPW_{overflow:auto;max-height:40vh;scrollbar-width:thin;margin-right:-5px;padding-right:5px}.LegalInfoMenu-module_scroller__3NPW_::-webkit-scrollbar{width:3px}.LegalInfoMenu-module_scroller__3NPW_::-webkit-scrollbar-thumb{background-color:var(--theme-widget-secondary-color);border-radius:2px}.LegalInfoMenu-module_scroller__3NPW_::-webkit-scrollbar-track{background-color:var(--theme-widget-surface-color)}.LegalInfoMenu-module_links__1kpsd{position:relative;padding-top:5px;padding-bottom:5px}.LegalInfoMenu-module_links__1kpsd:before{content:"";position:absolute;top:0;left:-5px;right:-5px;border-top:1px solid var(--theme-widget-primary-color);opacity:.1}.LegalInfoMenu-module_legalInfoTooltip__Qmf8u:after{left:90%!important}.LegalInfoMenu-module_legalInfoTooltip__Qmf8u p{margin:0 0 .5em}.LegalInfoMenu-module_legalInfoTooltip__Qmf8u a{color:var(--theme-accent-color)}.LegalInfoMenu-module_legalInfoLink__gkXaF{display:block;margin-top:5px}.SharingMenu-module_shareIcon__2iW2l svg{width:40px;height:40px;margin:5px 0}header .share svg{fill:var(--theme-widget-primary-color)}header .share:hover svg{fill:var(--theme-accent-color)}.SharingMenu-module_sharingTooltip__2Tyev{width:160px;padding:0!important}.SharingMenu-module_sharingTooltip__2Tyev:after{left:90%!important}.SharingMenu-module_shareLinkContainer__3-3W6{display:inline-block;width:80px;height:60px;cursor:pointer;color:transparent;text-align:center}.SharingMenu-module_shareLink__3PdRE{position:relative;color:var(--theme-widget-primary-color);text-decoration:none}.SharingMenu-module_shareLink__3PdRE:hover{color:var(--theme-accent-color)}.SharingMenu-module_shareIcon__2iW2l{width:80px;height:25px;margin-top:5px;margin-bottom:3px}.ToggleMuteButton-module_button__1ACmo{color:var(--theme-widget-primary-color)}.ToggleMuteButton-module_animate__pd1yK{position:relative}.ToggleMuteButton-module_animate__pd1yK:before{content:"";display:block;position:absolute;top:50%;left:50%;margin:-5px;z-index:-1;width:10px;height:10px;background-color:#ddd;border-radius:5px;-webkit-animation:ToggleMuteButton-module_pulse__2UN7Q .5s ease .2s 1;animation:ToggleMuteButton-module_pulse__2UN7Q .5s ease .2s 1;-webkit-animation-fill-mode:forwards;animation-fill-mode:forwards;pointer-events:none}@-webkit-keyframes ToggleMuteButton-module_pulse__2UN7Q{0%{opacity:.8}to{transform:scale(40);opacity:0}}@keyframes ToggleMuteButton-module_pulse__2UN7Q{0%{opacity:.8}to{transform:scale(40);opacity:0}}.SkipLinks-module_link__HMj9l{position:absolute;z-index:10000;top:-1000em;left:-1000em;display:block;border:1px solid #eee;border-radius:5px;padding:5px;background:#00375a;text-align:center;line-height:25px;color:#fff}.SkipLinks-module_link__HMj9l:focus{left:13.8%;top:13%}.utils-module_clip__34eot{clip:rect(0,auto,auto,0);-webkit-clip-path:polygon(0 0,100% 0,100% 100%,0 100%);clip-path:polygon(0 0,100% 0,100% 100%,0 100%)}.utils-module_unstyledButton__3rgne{border:0;padding:0;background-color:transparent;text-align:initial}.ScrollButton-module_button__1GKRF{position:absolute;top:var(--default-navigation-scroll-button-top);height:40px;width:20px;opacity:0;visibility:hidden;transition:opacity .2s ease,visibility .2s ease;z-index:1}.ScrollButton-module_button__1GKRF svg{width:18px;height:18px;color:var(--theme-widget-primary-color)}.ScrollButton-module_visible__29yco{opacity:1;visibility:visible}.ScrollButton-module_start__1XPra{right:80%}.ScrollButton-module_end__3PxQt{left:79%}@media screen and (min-width:768px){.Scroller-module_scroller__139cK{overflow:hidden;scroll-behavior:smooth;padding-bottom:90vh;pointer-events:none;margin:0 auto;width:58%}.Scroller-module_scroller__139cK>*{pointer-events:auto}@supports ((-webkit-clip-path:polygon(0 0)) or (clip-path:polygon(0 0))){.Scroller-module_scroller__139cK{width:auto;-webkit-clip-path:polygon(20% 0,79% 0,79% var(--default-navigation-chapter-link-height),100% var(--default-navigation-chapter-link-height),100% 400%,0 400%,0 var(--default-navigation-chapter-link-height),20% var(--default-navigation-chapter-link-height));clip-path:polygon(20% 0,79% 0,79% var(--default-navigation-chapter-link-height),100% var(--default-navigation-chapter-link-height),100% 400%,0 400%,0 var(--default-navigation-chapter-link-height),20% var(--default-navigation-chapter-link-height));-webkit-mask:linear-gradient(90deg,transparent 0,transparent 20%,#000 22%,#000 77%,transparent 79%,transparent) top,linear-gradient(90deg,#000 0,#000) bottom;mask:linear-gradient(90deg,transparent 0,transparent 20%,#000 22%,#000 77%,transparent 79%,transparent) top,linear-gradient(90deg,#000 0,#000) bottom;-webkit-mask-size:100% var(--default-navigation-chapter-link-height),100% calc(100% - var(--default-navigation-chapter-link-height));mask-size:100% var(--default-navigation-chapter-link-height),100% calc(100% - var(--default-navigation-chapter-link-height));-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat}.Scroller-module_inner__3dhuM{display:inline-block;margin:0 22%}}}
9
+ */.HamburgerIcons-module_hamburger__SOreS{display:inline-block;cursor:pointer;transition-property:opacity,filter;transition-duration:.15s;transition-timing-function:linear;font:inherit;color:inherit;text-transform:none;background-color:transparent;border:0;margin:0;overflow:visible}.HamburgerIcons-module_hamburger__SOreS.HamburgerIcons-module_is-active__2jpzX .HamburgerIcons-module_hamburger-inner__Wv7Dn,.HamburgerIcons-module_hamburger__SOreS.HamburgerIcons-module_is-active__2jpzX .HamburgerIcons-module_hamburger-inner__Wv7Dn:after,.HamburgerIcons-module_hamburger__SOreS.HamburgerIcons-module_is-active__2jpzX .HamburgerIcons-module_hamburger-inner__Wv7Dn:before{background-color:var(--theme-accent-color)}.HamburgerIcons-module_hamburger-box__10MR1{width:40px;height:24px;display:inline-block;position:relative;vertical-align:top;transform:var(--hamburger-icon-transform)}.HamburgerIcons-module_hamburger-inner__Wv7Dn{display:block;top:50%;margin-top:-2px}.HamburgerIcons-module_hamburger-inner__Wv7Dn,.HamburgerIcons-module_hamburger-inner__Wv7Dn:after,.HamburgerIcons-module_hamburger-inner__Wv7Dn:before{width:30px;height:var(--hamburger-icon-line-width,4px);background-color:var(--theme-widget-primary-color);border-radius:4px;position:absolute;transition-property:transform;transition-duration:.15s;transition-timing-function:ease}.HamburgerIcons-module_hamburger-inner__Wv7Dn:after,.HamburgerIcons-module_hamburger-inner__Wv7Dn:before{content:"";display:block}.HamburgerIcons-module_hamburger-inner__Wv7Dn:before{top:-10px}.HamburgerIcons-module_hamburger-inner__Wv7Dn:after{bottom:-10px}.HamburgerIcons-module_hamburger--collapse__1xOkf .HamburgerIcons-module_hamburger-inner__Wv7Dn{top:auto;bottom:0;transition-duration:.13s;transition-delay:.13s;transition-timing-function:cubic-bezier(.55,.055,.675,.19)}.HamburgerIcons-module_hamburger--collapse__1xOkf .HamburgerIcons-module_hamburger-inner__Wv7Dn:after{top:-20px;transition:top .2s cubic-bezier(.33333,.66667,.66667,1) .2s,opacity .1s linear}.HamburgerIcons-module_hamburger--collapse__1xOkf .HamburgerIcons-module_hamburger-inner__Wv7Dn:before{transition:top .12s cubic-bezier(.33333,.66667,.66667,1) .2s,transform .13s cubic-bezier(.55,.055,.675,.19)}.HamburgerIcons-module_hamburger--collapse__1xOkf.HamburgerIcons-module_is-active__2jpzX .HamburgerIcons-module_hamburger-inner__Wv7Dn{transform:translate3d(0,-10px,0) rotate(-45deg);transition-delay:.22s;transition-timing-function:cubic-bezier(.215,.61,.355,1)}.HamburgerIcons-module_hamburger--collapse__1xOkf.HamburgerIcons-module_is-active__2jpzX .HamburgerIcons-module_hamburger-inner__Wv7Dn:after{top:0;opacity:0;transition:top .2s cubic-bezier(.33333,0,.66667,.33333),opacity .1s linear .22s}.HamburgerIcons-module_hamburger--collapse__1xOkf.HamburgerIcons-module_is-active__2jpzX .HamburgerIcons-module_hamburger-inner__Wv7Dn:before{top:0;transform:rotate(-90deg);transition:top .1s cubic-bezier(.33333,0,.66667,.33333) .16s,transform .13s cubic-bezier(.215,.61,.355,1) .25s}.ChapterLink-module_chapterLink__3YspQ{line-height:42px;color:var(--theme-widget-primary-color);text-decoration:none;position:relative;display:block;font-family:inherit;font-weight:700;font-size:1rem;height:42px;white-space:nowrap;padding:0 10px;margin:4px 0}.ChapterLink-module_chapterLink__3YspQ:hover,.ChapterLink-module_chapterLinkActive__9i8SL{color:var(--theme-accent-color)}.ChapterLink-module_summary__2ZfRU{color:var(--theme-widget-on-background-color)}.ChapterLink-module_tooltipBubble__3VRUO{display:none}@media (min-width:768px){.ChapterLink-module_summary__2ZfRU{display:none}.ChapterLink-module_tooltipBubble__3VRUO{display:block}}.LegalInfoMenu-module_legalInfoTooltip__Qmf8u{text-align:left}.LegalInfoMenu-module_scroller__3NPW_{overflow:auto;max-height:40vh;scrollbar-width:thin;margin-right:-5px;padding-right:5px}.LegalInfoMenu-module_scroller__3NPW_::-webkit-scrollbar{width:3px}.LegalInfoMenu-module_scroller__3NPW_::-webkit-scrollbar-thumb{background-color:var(--theme-widget-secondary-color);border-radius:2px}.LegalInfoMenu-module_scroller__3NPW_::-webkit-scrollbar-track{background-color:var(--theme-widget-surface-color)}.LegalInfoMenu-module_links__1kpsd{position:relative;padding-top:5px;padding-bottom:5px}.LegalInfoMenu-module_links__1kpsd:before{content:"";position:absolute;top:0;left:-5px;right:-5px;border-top:1px solid var(--theme-widget-primary-color);opacity:.1}.LegalInfoMenu-module_legalInfoTooltip__Qmf8u:after{left:90%!important}.LegalInfoMenu-module_legalInfoTooltip__Qmf8u p{margin:0 0 .5em}.LegalInfoMenu-module_legalInfoTooltip__Qmf8u a{color:var(--theme-accent-color)}.LegalInfoMenu-module_legalInfoLink__gkXaF{display:block;margin-top:5px}header .share svg{fill:var(--theme-widget-primary-color)}header .share:hover svg{fill:var(--theme-accent-color)}.SharingMenu-module_sharingTooltip__2Tyev{width:160px;padding:0!important}.SharingMenu-module_sharingTooltip__2Tyev:after{left:90%!important}.SharingMenu-module_shareLinkContainer__3-3W6{display:inline-block;width:80px;height:60px;cursor:pointer;color:transparent;text-align:center}.SharingMenu-module_shareLink__3PdRE{position:relative;color:var(--theme-widget-primary-color);text-decoration:none}.SharingMenu-module_shareLink__3PdRE:hover{color:var(--theme-accent-color)}.SharingMenu-module_shareLink__3PdRE svg{width:80px;height:25px;margin-top:5px;margin-bottom:3px}.ToggleMuteButton-module_button__1ACmo{color:var(--theme-widget-primary-color)}.ToggleMuteButton-module_animate__pd1yK{position:relative}.ToggleMuteButton-module_animate__pd1yK:before{content:"";display:block;position:absolute;top:50%;left:50%;margin:-5px;z-index:-1;width:10px;height:10px;background-color:#ddd;border-radius:5px;-webkit-animation:ToggleMuteButton-module_pulse__2UN7Q .5s ease .2s 1;animation:ToggleMuteButton-module_pulse__2UN7Q .5s ease .2s 1;-webkit-animation-fill-mode:forwards;animation-fill-mode:forwards;pointer-events:none}@-webkit-keyframes ToggleMuteButton-module_pulse__2UN7Q{0%{opacity:.8}to{transform:scale(40);opacity:0}}@keyframes ToggleMuteButton-module_pulse__2UN7Q{0%{opacity:.8}to{transform:scale(40);opacity:0}}.SkipLinks-module_link__HMj9l{position:absolute;z-index:10000;top:-1000em;left:-1000em;display:block;border:1px solid #eee;border-radius:5px;padding:5px;background:#00375a;text-align:center;line-height:25px;color:#fff}.SkipLinks-module_link__HMj9l:focus{left:13.8%;top:13%}.utils-module_clip__34eot{clip:rect(0,auto,auto,0);-webkit-clip-path:polygon(0 0,100% 0,100% 100%,0 100%);clip-path:polygon(0 0,100% 0,100% 100%,0 100%)}.utils-module_unstyledButton__3rgne{border:0;padding:0;background-color:transparent;text-align:initial}.ScrollButton-module_button__1GKRF{position:absolute;top:var(--default-navigation-scroll-button-top);height:40px;width:20px;opacity:0;visibility:hidden;transition:opacity .2s ease,visibility .2s ease;z-index:1}.ScrollButton-module_button__1GKRF svg{width:18px;height:18px;color:var(--theme-widget-primary-color)}.ScrollButton-module_visible__29yco{opacity:1;visibility:visible}.ScrollButton-module_start__1XPra{right:80%}.ScrollButton-module_end__3PxQt{left:79%}@media screen and (min-width:768px){.Scroller-module_scroller__139cK{overflow:hidden;scroll-behavior:smooth;padding-bottom:90vh;pointer-events:none;margin:0 auto;width:58%}.Scroller-module_scroller__139cK>*{pointer-events:auto}@supports ((-webkit-clip-path:polygon(0 0)) or (clip-path:polygon(0 0))){.Scroller-module_scroller__139cK{width:auto;-webkit-clip-path:polygon(20% 0,79% 0,79% var(--default-navigation-chapter-link-height),100% var(--default-navigation-chapter-link-height),100% 400%,0 400%,0 var(--default-navigation-chapter-link-height),20% var(--default-navigation-chapter-link-height));clip-path:polygon(20% 0,79% 0,79% var(--default-navigation-chapter-link-height),100% var(--default-navigation-chapter-link-height),100% 400%,0 400%,0 var(--default-navigation-chapter-link-height),20% var(--default-navigation-chapter-link-height));-webkit-mask:linear-gradient(90deg,transparent 0,transparent 20%,#000 22%,#000 77%,transparent 79%,transparent) top,linear-gradient(90deg,#000 0,#000) bottom;mask:linear-gradient(90deg,transparent 0,transparent 20%,#000 22%,#000 77%,transparent 79%,transparent) top,linear-gradient(90deg,#000 0,#000) bottom;-webkit-mask-size:100% var(--default-navigation-chapter-link-height),100% calc(100% - var(--default-navigation-chapter-link-height));mask-size:100% var(--default-navigation-chapter-link-height),100% calc(100% - var(--default-navigation-chapter-link-height));-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat}.Scroller-module_inner__3dhuM{display:inline-block;margin:0 22%}}}
@@ -1,4 +1,4 @@
1
- import { useI18n, utils, Tooltip, useFileRights, useLegalInfo, useCredits, Widget, ThemeIcon, usePhonePlatform, useShareProviders, useShareUrl, useMediaMuted, useTheme, useOnUnmuteMedia, useChapters, useCurrentChapter, useScrollPosition, frontend } from 'pageflow-scrolled/frontend';
1
+ import { useTheme, useI18n, utils, Tooltip, useFileRights, useLegalInfo, useCredits, Widget, ThemeIcon, useShareUrl, useMediaMuted, useOnUnmuteMedia, useChapters, useCurrentChapter, usePhonePlatform, useShareProviders, useScrollPosition, frontend } from 'pageflow-scrolled/frontend';
2
2
  import React, { useRef, useEffect, useCallback, useState } from 'react';
3
3
  import classNames from 'classnames';
4
4
  import { media } from 'pageflow/frontend';
@@ -79,18 +79,20 @@ function _slicedToArray(arr, i) {
79
79
 
80
80
  var styles = {"breakpoint-below-md":"(max-width: 767px)","navigationBar":"DefaultNavigation-module_navigationBar__2RK0h scope-defaultNavigation","navigationBarExpanded":"DefaultNavigation-module_navigationBarExpanded__C3sLq","navigationBarContentWrapper":"DefaultNavigation-module_navigationBarContentWrapper__3narH","menuIcon":"DefaultNavigation-module_menuIcon__2bb8s","contextIcons":"DefaultNavigation-module_contextIcons__2e65s","contextIcon":"DefaultNavigation-module_contextIcon__ELsqa utils-module_unstyledButton__3rgne","logo":"DefaultNavigation-module_logo__3gUbx","chapterList":"DefaultNavigation-module_chapterList__3VoXX scope-defaultNavigationChapterList","chapterListItem":"DefaultNavigation-module_chapterListItem__1YF5e","navigationTooltip":"DefaultNavigation-module_navigationTooltip__26Fvn","progressBar":"DefaultNavigation-module_progressBar__1jvov","progressIndicator":"DefaultNavigation-module_progressIndicator__2d_e3","hasChapters":"DefaultNavigation-module_hasChapters__3ab-r","navigationChapters":"DefaultNavigation-module_navigationChapters__3M6zh","navigationChaptersHidden":"DefaultNavigation-module_navigationChaptersHidden__2TrUo"};
81
81
 
82
- var styles$1 = {"breakpoint-md":"(min-width: 768px)","burgerMenuIconContainer":"HamburgerIcon-module_burgerMenuIconContainer__3aBkk","burgerMenuIcon":"HamburgerIcon-module_burgerMenuIcon__1WUV0"};
82
+ var styles$1 = {"breakpoint-md":"(min-width: 768px)","burgerMenuIconContainer":"HamburgerIcon-module_burgerMenuIconContainer__3aBkk","burgerMenuIcon":"HamburgerIcon-module_burgerMenuIcon__1WUV0","small":"HamburgerIcon-module_small__asAkY"};
83
83
 
84
84
  var hamburgerIconStyles = {"hamburger":"HamburgerIcons-module_hamburger__SOreS","is-active":"HamburgerIcons-module_is-active__2jpzX","hamburger-inner":"HamburgerIcons-module_hamburger-inner__Wv7Dn","hamburger-box":"HamburgerIcons-module_hamburger-box__10MR1","hamburger--collapse":"HamburgerIcons-module_hamburger--collapse__1xOkf"};
85
85
 
86
86
  function HamburgerIcon(props) {
87
+ var theme = useTheme();
88
+
87
89
  var _useI18n = useI18n(),
88
90
  t = _useI18n.t;
89
91
 
90
92
  return /*#__PURE__*/React.createElement("div", {
91
93
  className: styles$1.burgerMenuIconContainer
92
94
  }, /*#__PURE__*/React.createElement("button", {
93
- className: classNames(styles.menuIcon, styles$1.burgerMenuIcon, hamburgerIconStyles.hamburger, hamburgerIconStyles['hamburger--collapse'], _defineProperty({}, hamburgerIconStyles['is-active'], !props.mobileNavHidden)),
95
+ className: classNames(styles.menuIcon, styles$1.burgerMenuIcon, hamburgerIconStyles.hamburger, hamburgerIconStyles['hamburger--collapse'], _defineProperty({}, styles$1.small, theme.options.defaultNavigationMenuIconVariant === 'small'), _defineProperty({}, hamburgerIconStyles['is-active'], !props.mobileNavHidden)),
94
96
  title: props.mobileNavHidden ? t('pageflow_scrolled.public.navigation.open_mobile_menu') : t('pageflow_scrolled.public.navigation.close_mobile_menu'),
95
97
  type: "button",
96
98
  onClick: props.onClick
@@ -177,8 +179,8 @@ function LegalInfoMenu(props) {
177
179
  role: "creditsBoxFooter"
178
180
  }));
179
181
  return /*#__PURE__*/React.createElement(Tooltip, {
180
- horizontalOffset: -30,
181
- arrowPos: 120,
182
+ horizontalOffset: props.tooltipOffset - 30,
183
+ arrowPos: 120 - props.tooltipOffset,
182
184
  content: content
183
185
  }, /*#__PURE__*/React.createElement("button", {
184
186
  className: classNames(styles.contextIcon),
@@ -189,13 +191,10 @@ function LegalInfoMenu(props) {
189
191
  })));
190
192
  }
191
193
 
192
- var styles$4 = {"shareIcon":"SharingMenu-module_shareIcon__2iW2l","sharingTooltip":"SharingMenu-module_sharingTooltip__2Tyev","shareLinkContainer":"SharingMenu-module_shareLinkContainer__3-3W6","shareLink":"SharingMenu-module_shareLink__3PdRE"};
194
+ var styles$4 = {"sharingTooltip":"SharingMenu-module_sharingTooltip__2Tyev","shareLinkContainer":"SharingMenu-module_shareLinkContainer__3-3W6","shareLink":"SharingMenu-module_shareLink__3PdRE"};
193
195
 
194
- function SharingMenu() {
195
- var isPhonePlatform = usePhonePlatform();
196
- var shareProviders = useShareProviders({
197
- isPhonePlatform: isPhonePlatform
198
- });
196
+ function SharingMenu(_ref) {
197
+ var shareProviders = _ref.shareProviders;
199
198
  var shareUrl = useShareUrl();
200
199
 
201
200
  var _useI18n = useI18n(),
@@ -203,7 +202,6 @@ function SharingMenu() {
203
202
 
204
203
  function renderShareLinks(shareProviders) {
205
204
  return shareProviders.map(function (shareProvider) {
206
- var Icon = shareProvider.icon;
207
205
  return /*#__PURE__*/React.createElement("div", {
208
206
  key: shareProvider.name,
209
207
  className: styles$4.shareLinkContainer
@@ -212,26 +210,21 @@ function SharingMenu() {
212
210
  href: shareProvider.url.replace('%{url}', shareUrl),
213
211
  target: '_blank',
214
212
  rel: "noopener noreferrer"
215
- }, /*#__PURE__*/React.createElement(Icon, {
216
- className: styles$4.shareIcon
213
+ }, /*#__PURE__*/React.createElement(ThemeIcon, {
214
+ name: shareProvider.iconName
217
215
  }), shareProvider.name));
218
216
  });
219
217
  }
220
-
221
- if (shareProviders.length > 0) {
222
- return /*#__PURE__*/React.createElement(Tooltip, {
223
- horizontalOffset: -70,
224
- arrowPos: 160,
225
- content: renderShareLinks(shareProviders)
226
- }, /*#__PURE__*/React.createElement("button", {
227
- className: classNames(styles.contextIcon),
228
- title: t('pageflow_scrolled.public.navigation.share')
229
- }, /*#__PURE__*/React.createElement(ThemeIcon, {
230
- name: "share"
231
- })));
232
- } else {
233
- return null;
234
- }
218
+ return /*#__PURE__*/React.createElement(Tooltip, {
219
+ horizontalOffset: -70,
220
+ arrowPos: 160,
221
+ content: renderShareLinks(shareProviders)
222
+ }, /*#__PURE__*/React.createElement("button", {
223
+ className: classNames(styles.contextIcon),
224
+ title: t('pageflow_scrolled.public.navigation.share')
225
+ }, /*#__PURE__*/React.createElement(ThemeIcon, {
226
+ name: "share"
227
+ })));
235
228
  }
236
229
 
237
230
  var styles$5 = {"button":"ToggleMuteButton-module_button__1ACmo","animate":"ToggleMuteButton-module_animate__pd1yK","pulse":"ToggleMuteButton-module_pulse__2UN7Q"};
@@ -502,9 +495,11 @@ function Scroller(_ref) {
502
495
  }
503
496
  }
504
497
 
505
- function DefaultNavigation(props) {
498
+ function DefaultNavigation(_ref) {
506
499
  var _chapters$, _chapters$2, _classNames2;
507
500
 
501
+ var configuration = _ref.configuration;
502
+
508
503
  var _useState = useState(true),
509
504
  _useState2 = _slicedToArray(_useState, 2),
510
505
  navExpanded = _useState2[0],
@@ -522,9 +517,13 @@ function DefaultNavigation(props) {
522
517
 
523
518
  var chapters = useChapters();
524
519
  var currentChapter = useCurrentChapter();
525
- useScrollPosition(function (_ref) {
526
- var prevPos = _ref.prevPos,
527
- currPos = _ref.currPos;
520
+ var isPhonePlatform = usePhonePlatform();
521
+ var shareProviders = useShareProviders({
522
+ isPhonePlatform: isPhonePlatform
523
+ });
524
+ useScrollPosition(function (_ref2) {
525
+ var prevPos = _ref2.prevPos,
526
+ currPos = _ref2.currPos;
528
527
  var expand = currPos.y > prevPos.y || // Mobile Safari reports positive scroll position
529
528
  // during scroll bounce animation when scrolling
530
529
  // back to the top. Make sure navigation bar
@@ -532,9 +531,9 @@ function DefaultNavigation(props) {
532
531
  currPos.y >= 0;
533
532
  if (expand !== navExpanded) setNavExpanded(expand);
534
533
  }, [navExpanded]);
535
- useScrollPosition(function (_ref2) {
536
- var prevPos = _ref2.prevPos,
537
- currPos = _ref2.currPos;
534
+ useScrollPosition(function (_ref3) {
535
+ var prevPos = _ref3.prevPos,
536
+ currPos = _ref3.currPos;
538
537
  var current = currPos.y * -1; // Todo: Memoize and update on window resize
539
538
 
540
539
  var total = document.body.clientHeight - window.innerHeight;
@@ -587,8 +586,9 @@ function DefaultNavigation(props) {
587
586
  }, renderChapterLinks(chapters))));
588
587
  }
589
588
 
590
- return /*#__PURE__*/React.createElement("header", {
591
- className: classNames(styles.navigationBar, (_classNames2 = {}, _defineProperty(_classNames2, styles.navigationBarExpanded, navExpanded || !mobileNavHidden), _defineProperty(_classNames2, styles.hasChapters, hasChapters), _classNames2))
589
+ var hideSharingButton = configuration.hideSharingButton || !shareProviders.length;
590
+ return /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement("header", {
591
+ className: classNames(styles.navigationBar, (_classNames2 = {}, _defineProperty(_classNames2, styles.navigationBarExpanded, navExpanded || !isPhonePlatform && configuration.fixedOnDesktop || !mobileNavHidden), _defineProperty(_classNames2, styles.hasChapters, hasChapters), _classNames2))
592
592
  }, /*#__PURE__*/React.createElement("div", {
593
593
  className: styles.navigationBarContentWrapper
594
594
  }, hasChapters && /*#__PURE__*/React.createElement(HamburgerIcon, {
@@ -596,7 +596,11 @@ function DefaultNavigation(props) {
596
596
  mobileNavHidden: mobileNavHidden
597
597
  }), /*#__PURE__*/React.createElement(SkipLinks, null), /*#__PURE__*/React.createElement(Logo, null), renderNav(), /*#__PURE__*/React.createElement("div", {
598
598
  className: classNames(styles.contextIcons)
599
- }, /*#__PURE__*/React.createElement(ToggleMuteButton, null), /*#__PURE__*/React.createElement(LegalInfoMenu, null), /*#__PURE__*/React.createElement(SharingMenu, null))), /*#__PURE__*/React.createElement("div", {
599
+ }, !configuration.hideToggleMuteButton && /*#__PURE__*/React.createElement(ToggleMuteButton, null), /*#__PURE__*/React.createElement(LegalInfoMenu, {
600
+ tooltipOffset: hideSharingButton ? -40 : 0
601
+ }), !hideSharingButton && /*#__PURE__*/React.createElement(SharingMenu, {
602
+ shareProviders: shareProviders
603
+ }))), /*#__PURE__*/React.createElement("div", {
600
604
  className: styles.progressBar,
601
605
  onMouseEnter: handleProgressBarMouseEnter
602
606
  }, /*#__PURE__*/React.createElement("span", {
@@ -604,7 +608,13 @@ function DefaultNavigation(props) {
604
608
  style: {
605
609
  width: readingProgress + '%'
606
610
  }
607
- })));
611
+ }))), /*#__PURE__*/React.createElement(Widget, {
612
+ role: "defaultNavigationExtra",
613
+ props: {
614
+ navigationExpanded: navExpanded,
615
+ mobileNavigationVisible: !mobileNavHidden
616
+ }
617
+ }));
608
618
  }
609
619
 
610
620
  frontend.widgetTypes.register('defaultNavigation', {
@@ -95,7 +95,11 @@ module Pageflow
95
95
  Admin::EntryTabPolicy.new(user, tab).see?
96
96
  end
97
97
 
98
- can :see_theming_admin_tab, Admin::Tab do |tab|
98
+ can :see_site_admin_tab, Admin::Tab do |tab|
99
+ Admin::AdminOnlyTabPolicy.new(user, tab).see?
100
+ end
101
+
102
+ can :see_account_admin_tab, Admin::Tab do |tab|
99
103
  Admin::AdminOnlyTabPolicy.new(user, tab).see?
100
104
  end
101
105
 
@@ -112,8 +116,8 @@ module Pageflow
112
116
  AccountPolicy.new(user, account).configure_folder_on?
113
117
  end
114
118
 
115
- can :update_theming_on_entry_of, Account do |account|
116
- AccountPolicy.new(user, account).update_theming_on_entry_of?
119
+ can :update_site_on_entry_of, Account do |account|
120
+ AccountPolicy.new(user, account).update_site_on_entry_of?
117
121
  end
118
122
 
119
123
  can :create, Entry do |entry|
@@ -180,8 +184,8 @@ module Pageflow
180
184
  EntryPolicy.new(user, entry).update_feature_configuration_on?
181
185
  end
182
186
 
183
- can :update_theming_on, Entry do |entry|
184
- EntryPolicy.new(user, entry).update_theming_on?
187
+ can :update_site_on, Entry do |entry|
188
+ EntryPolicy.new(user, entry).update_site_on?
185
189
  end
186
190
 
187
191
  can :use_files, Entry, EntryPolicy::Scope.new(user, Entry).resolve do |entry|
@@ -222,8 +226,12 @@ module Pageflow
222
226
  EntryPolicy.new(user, storyline.revision.entry).edit?
223
227
  end
224
228
 
225
- can :edit, Theming do |theming|
226
- ThemingPolicy.new(user, theming).edit?
229
+ can :read, Site do |site|
230
+ SitePolicy.new(user, site).read?
231
+ end
232
+
233
+ can :update, Site do |site|
234
+ SitePolicy.new(user, site).update?
227
235
  end
228
236
 
229
237
  can :create, EntryTemplate do |entry_template|
@@ -275,7 +283,7 @@ module Pageflow
275
283
  can :manage, [Entry, Revision]
276
284
  can :manage, Pageflow.config.file_types.map(&:model)
277
285
  can :manage, Folder
278
- can :manage, Theming
286
+ can :manage, Site
279
287
  can :manage, EntryTemplate
280
288
  can :manage, ::User
281
289
  end
@@ -12,7 +12,7 @@ module Pageflow
12
12
 
13
13
  # Insert an additional row into an attribute table.
14
14
  #
15
- # @param resource_name [Symbol] Either :entry, :account or :theming.
15
+ # @param resource_name [Symbol] Either :entry, :account or :site.
16
16
  #
17
17
  # @param name [Symbol] Name of the attribute to display.
18
18
  #
@@ -11,7 +11,7 @@ module Pageflow
11
11
  # Register a proc which adds additional inputs to admin forms.
12
12
  #
13
13
  # @param resource_name [Symbol] A resource name like `:entry`,
14
- # `:account` or `:theming`
14
+ # `:account` or `:site`
15
15
  # @param attribute_name [Symbol] The name of the additional
16
16
  # attribute
17
17
  # @param options [Hash] Formtastic options
@@ -9,7 +9,7 @@ module Pageflow
9
9
  # Display additional tabs on admin resource pages.
10
10
  #
11
11
  # @param [Symbol] resource_name A resource name like `:entry`,
12
- # `:user` or `:account`
12
+ # `:user`, `:account` or `:site`.
13
13
  # @param [Hash] options
14
14
  # @option options [Symbol] :name Unique identifier.
15
15
  # @option options [Arbre::Component] :component Component to
@@ -6,7 +6,7 @@ module Pageflow
6
6
  def initialize
7
7
  @only_admins_may_update_features = false
8
8
  @only_admins_may_see_admin_boolean = false
9
- @only_admins_may_update_theming = false
9
+ @only_admins_may_update_site = false
10
10
  end
11
11
 
12
12
  # Restrict access to features tabs to admins. Defaults to false.
@@ -18,10 +18,10 @@ module Pageflow
18
18
  # @since 12.1
19
19
  attr_accessor :only_admins_may_see_admin_boolean
20
20
 
21
- # Restrict access to theming drop down on entry edit admin page
21
+ # Restrict access to site drop down on entry edit admin page
22
22
  # to admins. Defaults to false.
23
23
  # @since 12.1
24
- attr_accessor :only_admins_may_update_theming
24
+ attr_accessor :only_admins_may_update_site
25
25
  end
26
26
  end
27
27
  end
@@ -151,21 +151,21 @@ module Pageflow
151
151
  attr_accessor :editor_routing_constraint
152
152
 
153
153
  # Either a lambda or an object with a `call` method taking two
154
- # parameters: An `ActiveRecord` scope of {Pageflow::Theming} records
154
+ # parameters: An `ActiveRecord` scope of {Pageflow::Site} records
155
155
  # and an {ActionDispatch::Request} object. Has to return the scope
156
- # in which to find themings.
156
+ # in which to find sites.
157
157
  #
158
- # Defaults to {CnameThemingRequestScope} which finds themings
158
+ # Defaults to {CnameSiteRequestScope} which finds sites
159
159
  # based on the request subdomain. Can be used to alter the logic
160
- # of finding a theming whose home_url to redirect to when visiting
160
+ # of finding a site whose home_url to redirect to when visiting
161
161
  # the public root path.
162
162
  #
163
163
  # Example:
164
164
  #
165
- # config.theming_request_scope = lambda do |themings, request|
166
- # themings.where(id: Pageflow::Account.find_by_name!(request.subdomain).default_theming_id)
165
+ # config.site_request_scope = lambda do |sites, request|
166
+ # sites.where(id: Pageflow::Account.find_by_name!(request.subdomain).default_site_id)
167
167
  # end
168
- attr_accessor :theming_request_scope
168
+ attr_accessor :site_request_scope
169
169
 
170
170
  # Either a lambda or an object with a `call` method taking two
171
171
  # parameters: An `ActiveRecord` scope of `Pageflow::Entry` records
@@ -196,7 +196,7 @@ module Pageflow
196
196
  attr_accessor :public_entry_redirect
197
197
 
198
198
  # Either a lambda or an object with a `call` method taking a
199
- # {Theming} as paramater and returing a hash of options used to
199
+ # {Site} as paramater and returing a hash of options used to
200
200
  # construct the url of a published entry.
201
201
  #
202
202
  # Can be used to change the host of the url under which entries
@@ -204,13 +204,13 @@ module Pageflow
204
204
  #
205
205
  # Example:
206
206
  #
207
- # config.public_entry_url_options = lambda do |theming|
208
- # {host: "#{theming.account.name}.example.com"}
207
+ # config.public_entry_url_options = lambda do |site|
208
+ # {host: "#{site.account.name}.example.com"}
209
209
  # end
210
210
  attr_accessor :public_entry_url_options
211
211
 
212
212
  # Either a lambda or an object with a `call` method taking a
213
- # {Theming} as paramater and returing a hash of options used to
213
+ # {Site} as paramater and returing a hash of options used to
214
214
  # construct the embed url of a published entry.
215
215
  attr_accessor :entry_embed_url_options
216
216
 
@@ -281,7 +281,7 @@ module Pageflow
281
281
  # @since 0.10
282
282
  attr_accessor :available_public_locales
283
283
 
284
- # Array of sharing providers which can be configured on theming level.
284
+ # Array of sharing providers which can be configured on site level.
285
285
  # Defaults to `[:facebook, :twitter, :linked_in, :whats_app, :telegram, :email]`.
286
286
  # @since 14.1
287
287
  attr_accessor :available_share_providers
@@ -310,7 +310,7 @@ module Pageflow
310
310
 
311
311
  # Share provider defaults.
312
312
  #
313
- # Default share providers for new themings.
313
+ # Default share providers for new sites.
314
314
  # Must be a subset or equal to `available_share_providers`
315
315
  # @since 14.1
316
316
  attr_accessor :default_share_providers
@@ -402,10 +402,10 @@ module Pageflow
402
402
  @thumbnail_styles = Defaults::THUMBNAIL_STYLES.dup
403
403
  @css_rendered_thumbnail_styles = Defaults::CSS_RENDERED_THUMBNAIL_STYLES.dup
404
404
 
405
- @theming_request_scope = CnameThemingRequestScope.new
405
+ @site_request_scope = CnameSiteRequestScope.new
406
406
  @public_entry_request_scope = lambda { |entries, request| entries }
407
407
  @public_entry_redirect = ->(_entry, _request) { nil }
408
- @public_entry_url_options = Pageflow::ThemingsHelper::DEFAULT_PUBLIC_ENTRY_OPTIONS
408
+ @public_entry_url_options = Pageflow::SitesHelper::DEFAULT_PUBLIC_ENTRY_OPTIONS
409
409
  @entry_embed_url_options = {protocol: 'https'}
410
410
 
411
411
  @transform_theme_customization_overrides = ->(overrides, _entry) { overrides }
@@ -515,9 +515,9 @@ module Pageflow
515
515
  end
516
516
 
517
517
  # @api private
518
- def theming_url_options(theming)
518
+ def site_url_options(site)
519
519
  options = public_entry_url_options
520
- options.respond_to?(:call) ? options.call(theming) : options
520
+ options.respond_to?(:call) ? options.call(site) : options
521
521
  end
522
522
 
523
523
  # @api private
@@ -44,7 +44,7 @@ module Pageflow
44
44
  def create_entry(data, options)
45
45
  entry_data = data.except(*DEFAULT_REMOVAL_COLUMNS)
46
46
  entry_data['account_id'] = options[:account].id
47
- entry_data['theming_id'] = options[:account].default_theming.id
47
+ entry_data['site_id'] = options[:account].default_site.id
48
48
  Entry.create!(entry_data.merge(skip_draft_creation: true))
49
49
  end
50
50
 
@@ -5,7 +5,7 @@ module Pageflow
5
5
  class EntryType
6
6
  # @api private
7
7
  attr_reader :name, :frontend_app, :editor_fragment_renderer, :configuration, :editor_app,
8
- :theme_files
8
+ :theme_files, :web_app_manifest
9
9
 
10
10
  # @param name [String] A unique name.
11
11
  #
@@ -27,14 +27,18 @@ module Pageflow
27
27
  # entry type and which Paperclip styles shall be processed:
28
28
  # `{logo: {content_type: %r{^image/}, styles: {small:
29
29
  # '300x300>'}}`.
30
+ #
31
+ # @param web_app_manifest [#call] Receives published entry and
32
+ # returns JSON for webmanifest file.
30
33
  def initialize(name:, frontend_app:, editor_fragment_renderer:, configuration:, editor_app: nil,
31
- theme_files: {})
34
+ theme_files: {}, web_app_manifest: nil)
32
35
  @name = name
33
36
  @frontend_app = frontend_app
34
37
  @editor_fragment_renderer = editor_fragment_renderer
35
38
  @configuration = configuration
36
39
  @editor_app = editor_app
37
40
  @theme_files = theme_files
41
+ @web_app_manifest = web_app_manifest
38
42
  end
39
43
  end
40
44
  end
@@ -5,20 +5,20 @@ module Pageflow
5
5
  # @since 12.4
6
6
  class PrimaryDomainEntryRedirect
7
7
  def call(entry, request)
8
- theming = entry.theming
8
+ site = entry.site
9
9
 
10
- if theming.cname.present? &&
11
- !known_domains(theming).include?(request.host)
12
- [request.protocol, theming.cname, request.fullpath].join
10
+ if site.cname.present? &&
11
+ !known_domains(site).include?(request.host)
12
+ [request.protocol, site.cname, request.fullpath].join
13
13
  end
14
14
  end
15
15
 
16
16
  private
17
17
 
18
- def known_domains(theming)
18
+ def known_domains(site)
19
19
  [
20
- theming.cname,
21
- (theming.additional_cnames || '').split(',').map(&:strip)
20
+ site.cname,
21
+ (site.additional_cnames || '').split(',').map(&:strip)
22
22
  ].flatten
23
23
  end
24
24
  end