pageflow 15.5.0 → 15.7.0

Sign up to get free protection for your applications and to get access to all the features.

Potentially problematic release.


This version of pageflow might be problematic. Click here for more details.

Files changed (270) hide show
  1. checksums.yaml +4 -4
  2. data/CHANGELOG.md +219 -87
  3. data/README.md +1 -2
  4. data/admins/pageflow/entry.rb +28 -57
  5. data/admins/pageflow/user.rb +1 -3
  6. data/app/assets/images/pageflow/admin/icons/buttons/editor.svg +2 -0
  7. data/app/assets/images/pageflow/admin/icons/buttons/preview.svg +2 -0
  8. data/app/assets/images/pageflow/admin/icons/buttons/show_public.svg +2 -0
  9. data/app/assets/images/pageflow/admin/icons/delete.svg +9 -0
  10. data/app/assets/images/pageflow/admin/icons/done.svg +6 -0
  11. data/app/assets/images/pageflow/admin/icons/edit.svg +7 -0
  12. data/app/assets/images/pageflow/admin/icons/editor.svg +2 -0
  13. data/app/assets/images/pageflow/admin/icons/folder.svg +8 -0
  14. data/app/assets/images/pageflow/admin/icons/folder_active.svg +8 -0
  15. data/app/assets/images/pageflow/admin/icons/info.svg +3 -0
  16. data/app/assets/images/pageflow/admin/icons/new.svg +5 -0
  17. data/app/assets/images/pageflow/admin/icons/preview.svg +2 -0
  18. data/app/assets/images/pageflow/admin/icons/published.svg +2 -0
  19. data/app/assets/images/pageflow/admin/icons/published_with_password.svg +2 -0
  20. data/app/assets/images/pageflow/admin/icons/show_public.svg +2 -0
  21. data/app/assets/images/pageflow/editor/blank_entry/logo.png +0 -0
  22. data/app/assets/images/pageflow/themes/default/embed_opt_in.svg +3 -0
  23. data/app/assets/images/pageflow/themes/default/embed_opt_out_info.svg +16 -0
  24. data/app/assets/javascripts/pageflow/admin/entries.js +9 -57
  25. data/app/assets/javascripts/pageflow/dist/ui.js +127 -10
  26. data/app/assets/stylesheets/pageflow/admin/active_admin_patches.scss +18 -16
  27. data/app/assets/stylesheets/pageflow/admin/badge_list.scss +25 -35
  28. data/app/assets/stylesheets/pageflow/admin/columns.scss +13 -11
  29. data/app/assets/stylesheets/pageflow/admin/embed_code.scss +1 -4
  30. data/app/assets/stylesheets/pageflow/admin/entries/folders.scss +44 -19
  31. data/app/assets/stylesheets/pageflow/admin/entries.scss +15 -31
  32. data/app/assets/stylesheets/pageflow/admin/features.scss +3 -1
  33. data/app/assets/stylesheets/pageflow/admin/forms.scss +14 -12
  34. data/app/assets/stylesheets/pageflow/admin/hint.scss +8 -14
  35. data/app/assets/stylesheets/pageflow/admin/icon_button.scss +25 -14
  36. data/app/assets/stylesheets/pageflow/admin/icon_link.scss +31 -15
  37. data/app/assets/stylesheets/pageflow/admin/publication_state_indicator.scss +14 -7
  38. data/app/assets/stylesheets/pageflow/admin/status_tags.scss +5 -4
  39. data/app/assets/stylesheets/pageflow/admin/tabs_view.scss +36 -34
  40. data/app/assets/stylesheets/pageflow/admin/tooltip_bubble.scss +15 -11
  41. data/app/assets/stylesheets/pageflow/admin.scss +12 -0
  42. data/app/assets/stylesheets/pageflow/editor/background_positioning.scss +15 -61
  43. data/app/assets/stylesheets/pageflow/editor/base.scss +28 -13
  44. data/app/assets/stylesheets/pageflow/editor/blank_entry.scss +6 -6
  45. data/app/assets/stylesheets/pageflow/editor/change_theme.scss +28 -71
  46. data/app/assets/stylesheets/pageflow/editor/composables.scss +2 -2
  47. data/app/assets/stylesheets/pageflow/editor/confirm_encoding.scss +18 -36
  48. data/app/assets/stylesheets/pageflow/editor/confirm_upload.scss +12 -39
  49. data/app/assets/stylesheets/pageflow/editor/dialogs.scss +39 -12
  50. data/app/assets/stylesheets/pageflow/editor/disabled_atmo_indicator.scss +3 -3
  51. data/app/assets/stylesheets/pageflow/editor/drop_down_button.scss +7 -10
  52. data/app/assets/stylesheets/pageflow/editor/emulation_mode_button.scss +3 -8
  53. data/app/assets/stylesheets/pageflow/editor/failures.scss +3 -3
  54. data/app/assets/stylesheets/pageflow/editor/file_import.scss +22 -38
  55. data/app/assets/stylesheets/pageflow/editor/file_meta_data.scss +3 -7
  56. data/app/assets/stylesheets/pageflow/editor/file_settings_dialog.scss +4 -24
  57. data/app/assets/stylesheets/pageflow/editor/file_stages.scss +10 -11
  58. data/app/assets/stylesheets/pageflow/editor/file_thumbnails.scss +4 -8
  59. data/app/assets/stylesheets/pageflow/editor/files.scss +7 -6
  60. data/app/assets/stylesheets/pageflow/editor/files_explorer.scss +13 -30
  61. data/app/assets/stylesheets/pageflow/editor/files_gallery.scss +15 -11
  62. data/app/assets/stylesheets/pageflow/editor/filtered_files.scss +6 -7
  63. data/app/assets/stylesheets/pageflow/editor/help.scss +19 -14
  64. data/app/assets/stylesheets/pageflow/editor/help_image.scss +1 -1
  65. data/app/assets/stylesheets/pageflow/editor/info_box.scss +19 -0
  66. data/app/assets/stylesheets/pageflow/editor/inputs/file_input.scss +7 -11
  67. data/app/assets/stylesheets/pageflow/editor/inputs/file_processing_state_display.scss +0 -2
  68. data/app/assets/stylesheets/pageflow/editor/inputs/reference.scss +7 -11
  69. data/app/assets/stylesheets/pageflow/editor/list.scss +13 -10
  70. data/app/assets/stylesheets/pageflow/editor/loading.scss +1 -1
  71. data/app/assets/stylesheets/pageflow/editor/locked.scss +9 -5
  72. data/app/assets/stylesheets/pageflow/editor/menu.scss +5 -5
  73. data/app/assets/stylesheets/pageflow/editor/notifications.scss +15 -14
  74. data/app/assets/stylesheets/pageflow/editor/other_entry_item.scss +7 -3
  75. data/app/assets/stylesheets/pageflow/editor/outline.scss +57 -19
  76. data/app/assets/stylesheets/pageflow/editor/page_links.scss +10 -8
  77. data/app/assets/stylesheets/pageflow/editor/page_selection.scss +2 -29
  78. data/app/assets/stylesheets/pageflow/editor/publish_entry.scss +5 -6
  79. data/app/assets/stylesheets/pageflow/editor/quotas.scss +2 -3
  80. data/app/assets/stylesheets/pageflow/editor/select_button.scss +12 -6
  81. data/app/assets/stylesheets/pageflow/editor/sidebar_footer.scss +1 -5
  82. data/app/assets/stylesheets/pageflow/editor/storyline_picker.scss +6 -2
  83. data/app/assets/stylesheets/pageflow/editor/text_tracks.scss +6 -22
  84. data/app/assets/stylesheets/pageflow/editor/widgets.scss +2 -2
  85. data/app/assets/stylesheets/pageflow/editor/wysihtml5.scss +35 -29
  86. data/app/assets/stylesheets/pageflow/mixins/background_icons.scss +3 -3
  87. data/app/assets/stylesheets/pageflow/mixins/buttons.scss +50 -68
  88. data/app/assets/stylesheets/pageflow/themes/default/base.scss +2 -0
  89. data/app/assets/stylesheets/pageflow/themes/default/consent/bar.scss +156 -0
  90. data/app/assets/stylesheets/pageflow/themes/default/consent/vendor_list.scss +62 -0
  91. data/app/assets/stylesheets/pageflow/themes/default/consent.scss +2 -0
  92. data/app/assets/stylesheets/pageflow/themes/default/logo/alignment.scss +7 -0
  93. data/app/assets/stylesheets/pageflow/themes/default/page/shadow.scss +44 -0
  94. data/app/assets/stylesheets/pageflow/themes/default/third_party_embed_consent.scss +103 -0
  95. data/app/assets/stylesheets/pageflow/ui/forms.scss +79 -84
  96. data/app/assets/stylesheets/pageflow/ui/functions.scss +56 -0
  97. data/app/assets/stylesheets/pageflow/ui/input/check_box_group_input.scss +2 -3
  98. data/app/assets/stylesheets/pageflow/ui/input/color_input.scss +6 -6
  99. data/app/assets/stylesheets/pageflow/ui/input/extended_select_input.scss +63 -50
  100. data/app/assets/stylesheets/pageflow/ui/normalize/forms.scss +153 -0
  101. data/app/assets/stylesheets/pageflow/ui/normalize.scss +278 -0
  102. data/app/assets/stylesheets/pageflow/ui/properties.scss +44 -0
  103. data/app/assets/stylesheets/pageflow/ui/table_cells/delete_row_table_cell.scss +1 -1
  104. data/app/assets/stylesheets/pageflow/ui/table_view.scss +14 -18
  105. data/app/assets/stylesheets/pageflow/ui/tabs_view.scss +8 -11
  106. data/app/assets/stylesheets/pageflow/ui/tooltip.scss +6 -8
  107. data/app/assets/stylesheets/pageflow/ui/validation_error_messages.scss +6 -0
  108. data/app/assets/stylesheets/pageflow/ui.scss +4 -0
  109. data/app/controllers/pageflow/edit_locks_controller.rb +3 -1
  110. data/app/helpers/pageflow/admin/entries_helper.rb +2 -12
  111. data/app/helpers/pageflow/embed_code_helper.rb +1 -1
  112. data/app/helpers/pageflow/entries_helper.rb +41 -2
  113. data/app/helpers/pageflow/file_background_images_helper.rb +1 -1
  114. data/app/helpers/pageflow/page_types_helper.rb +1 -1
  115. data/app/helpers/pageflow/themes_helper.rb +1 -1
  116. data/app/jobs/pageflow/poll_meta_data_from_zencoder_job.rb +1 -1
  117. data/app/jobs/pageflow/poll_zencoder_job.rb +1 -9
  118. data/app/models/pageflow/audio_file.rb +17 -0
  119. data/app/models/pageflow/audio_file_url_templates.rb +4 -1
  120. data/app/models/pageflow/customized_theme.rb +37 -0
  121. data/app/models/pageflow/draft_entry.rb +6 -59
  122. data/app/models/pageflow/entry_at_revision.rb +68 -0
  123. data/app/models/pageflow/entry_role_query.rb +44 -24
  124. data/app/models/pageflow/image_file_css_background_image_urls.rb +8 -2
  125. data/app/models/pageflow/published_entry.rb +9 -56
  126. data/app/models/pageflow/theme_customization.rb +46 -0
  127. data/app/models/pageflow/theme_customization_file.rb +58 -0
  128. data/app/models/pageflow/video_file.rb +11 -1
  129. data/app/models/pageflow/video_file_url_templates.rb +1 -0
  130. data/app/policies/pageflow/entry_policy.rb +4 -0
  131. data/app/state_machines/pageflow/media_encoding_state_machine.rb +23 -4
  132. data/app/views/admin/entries/_form.html.erb +50 -0
  133. data/app/views/admin/entries/entry_type_name_input.html.erb +5 -0
  134. data/app/views/admin/features/_form.html.erb +1 -1
  135. data/app/views/admin/memberships/_form.html.erb +2 -3
  136. data/app/views/admin/users/_form.html.erb +1 -1
  137. data/app/views/admin/users/invitation.html.erb +2 -2
  138. data/app/views/components/pageflow/admin/entry_user_badge_list.rb +10 -9
  139. data/app/views/components/pageflow/admin/members_tab.rb +5 -1
  140. data/app/views/components/pageflow/admin/revisions_tab.rb +13 -3
  141. data/app/views/components/pageflow/admin/timestamp.rb +20 -0
  142. data/app/views/components/pageflow/admin/user_account_badge_list.rb +5 -6
  143. data/app/views/pageflow/admin/entries/_cannot_add_user.html.erb +9 -5
  144. data/app/views/pageflow/admin/entries/_entry_type_name_input.html.erb +7 -0
  145. data/app/views/pageflow/audio_files/_audio_file.json.jbuilder +13 -0
  146. data/app/views/pageflow/editor/encoding_confirmations/_intro.html.erb +0 -0
  147. data/app/views/pageflow/editor/encoding_confirmations/check.json.jbuilder +14 -2
  148. data/config/initializers/paperclip.rb +16 -1
  149. data/config/locales/de.yml +24 -28
  150. data/config/locales/en.yml +19 -10
  151. data/db/migrate/20210528073122_create_pageflow_theme_customizations.rb +11 -0
  152. data/db/migrate/20210531090654_create_pageflow_theme_customization_files.rb +15 -0
  153. data/db/migrate/20210531102228_add_selected_file_ids_to_theme_customizations.rb +5 -0
  154. data/db/migrate/20211020085902_add_canonical_entry_url_prefix_to_themings.rb +5 -0
  155. data/db/migrate/20220503150010_add_peak_data_to_audio_files.rb +5 -0
  156. data/db/migrate/20220705084830_add_trailing_slash_in_canonical_urls_to_themings.rb +5 -0
  157. data/entry_types/paged/app/assets/javascripts/pageflow_paged/dist/editor.js +256 -124
  158. data/entry_types/paged/app/assets/javascripts/pageflow_paged/dist/frontend.js +566 -167
  159. data/entry_types/paged/app/assets/javascripts/pageflow_paged/dist/react-client.js +5 -5
  160. data/entry_types/paged/app/assets/javascripts/pageflow_paged/dist/react-server.js +4 -4
  161. data/entry_types/paged/app/helpers/pageflow_paged/third_party_embed_consent_helper.rb +38 -0
  162. data/entry_types/paged/app/views/pageflow_paged/third_party_embed_consent/_opt_in.html.erb +12 -0
  163. data/entry_types/paged/app/views/pageflow_paged/third_party_embed_consent/_opt_out_info.html.erb +10 -0
  164. data/entry_types/paged/config/initializers/features.rb +2 -0
  165. data/entry_types/paged/config/locales/new/video_contain.de.yml +7 -0
  166. data/entry_types/paged/config/locales/new/video_contain.en.yml +7 -0
  167. data/entry_types/scrolled/app/helpers/pageflow_scrolled/editor/seed_html_helper.rb +3 -0
  168. data/entry_types/scrolled/app/helpers/pageflow_scrolled/entry_json_seed_helper.rb +1 -0
  169. data/entry_types/scrolled/app/helpers/pageflow_scrolled/packs_helper.rb +58 -0
  170. data/entry_types/scrolled/app/helpers/pageflow_scrolled/react_server_side_rendering_helper.rb +37 -3
  171. data/entry_types/scrolled/app/helpers/pageflow_scrolled/themes_helper.rb +92 -6
  172. data/entry_types/scrolled/app/helpers/pageflow_scrolled/webpack_public_path_helper.rb +20 -0
  173. data/entry_types/scrolled/app/models/pageflow_scrolled/content_element.rb +7 -0
  174. data/entry_types/scrolled/app/views/pageflow_scrolled/editor/entries/_head.html.erb +5 -2
  175. data/entry_types/scrolled/app/views/pageflow_scrolled/editor/entries/_seed.json.jbuilder +5 -1
  176. data/entry_types/scrolled/app/views/pageflow_scrolled/entries/show.html.erb +5 -4
  177. data/entry_types/scrolled/app/views/pageflow_scrolled/entry_json_seed/_entry.json.jbuilder +16 -0
  178. data/entry_types/scrolled/app/views/pageflow_scrolled/entry_json_seed/_theme.json.jbuilder +13 -2
  179. data/entry_types/scrolled/app/views/pageflow_scrolled/entry_json_seed/_widget.json.jbuilder +2 -0
  180. data/entry_types/scrolled/config/locales/de.yml +1 -8
  181. data/entry_types/scrolled/config/locales/en.yml +1 -9
  182. data/entry_types/scrolled/config/locales/new/before_after_slider.de.yml +8 -0
  183. data/entry_types/scrolled/config/locales/new/before_after_slider.en.yml +8 -0
  184. data/entry_types/scrolled/config/locales/new/center_ragged.de.yml +8 -0
  185. data/entry_types/scrolled/config/locales/new/center_ragged.en.yml +9 -0
  186. data/entry_types/scrolled/config/locales/new/consent.de.yml +25 -0
  187. data/entry_types/scrolled/config/locales/new/consent.en.yml +24 -0
  188. data/entry_types/scrolled/config/locales/new/content_element_categories.de.yml +39 -0
  189. data/entry_types/scrolled/config/locales/new/content_element_categories.en.yml +39 -0
  190. data/entry_types/scrolled/config/locales/new/default_transition.de.yml +14 -0
  191. data/entry_types/scrolled/config/locales/new/default_transition.en.yml +14 -0
  192. data/entry_types/scrolled/config/locales/new/header_line_breaks.de.yml +28 -0
  193. data/entry_types/scrolled/config/locales/new/header_line_breaks.en.yml +27 -0
  194. data/entry_types/scrolled/config/locales/new/header_size.de.yml +17 -0
  195. data/entry_types/scrolled/config/locales/new/header_size.en.yml +17 -0
  196. data/entry_types/scrolled/config/locales/new/iframe_embed.de.yml +39 -0
  197. data/entry_types/scrolled/config/locales/new/iframe_embed.en.yml +39 -0
  198. data/entry_types/scrolled/config/locales/new/inline_loops.de.yml +26 -0
  199. data/entry_types/scrolled/config/locales/new/inline_loops.en.yml +26 -0
  200. data/entry_types/scrolled/config/locales/new/portrait_inline_image.de.yml +9 -0
  201. data/entry_types/scrolled/config/locales/new/portrait_inline_image.en.yml +9 -0
  202. data/entry_types/scrolled/config/locales/new/section_width.de.yml +10 -0
  203. data/entry_types/scrolled/config/locales/new/section_width.en.yml +10 -0
  204. data/entry_types/scrolled/config/locales/new/typography_variants.de.yml +7 -0
  205. data/entry_types/scrolled/config/locales/new/typography_variants.en.yml +7 -0
  206. data/entry_types/scrolled/config/locales/new/video_embed_poster.de.yml +8 -0
  207. data/entry_types/scrolled/config/locales/new/video_embed_poster.en.yml +8 -0
  208. data/entry_types/scrolled/config/locales/new/waveform_styles.de.yml +11 -0
  209. data/entry_types/scrolled/config/locales/new/waveform_styles.en.yml +12 -0
  210. data/entry_types/scrolled/config/locales/new/widgets.de.yml +6 -0
  211. data/entry_types/scrolled/config/locales/new/widgets.en.yml +6 -0
  212. data/entry_types/scrolled/lib/generators/pageflow_scrolled/install/install_generator.rb +29 -5
  213. data/entry_types/scrolled/lib/generators/pageflow_scrolled/install/templates/themes_plugin.rb.tt +8 -6
  214. data/entry_types/scrolled/lib/pageflow_scrolled/additional_packs.rb +37 -0
  215. data/entry_types/scrolled/lib/pageflow_scrolled/additional_seed_data.rb +57 -0
  216. data/entry_types/scrolled/lib/pageflow_scrolled/configuration.rb +49 -0
  217. data/entry_types/scrolled/lib/pageflow_scrolled/engine.rb +2 -0
  218. data/entry_types/scrolled/lib/pageflow_scrolled/plugin.rb +8 -0
  219. data/entry_types/scrolled/lib/pageflow_scrolled/react_widget_type.rb +42 -0
  220. data/entry_types/scrolled/lib/pageflow_scrolled.rb +17 -1
  221. data/entry_types/scrolled/lib/tasks/pageflow_scrolled/create_bundle_symlinks_for_yarn.rake +3 -2
  222. data/entry_types/scrolled/package/config/webpack.js +11 -0
  223. data/entry_types/scrolled/package/contentElements-editor.js +323 -89
  224. data/entry_types/scrolled/package/contentElements-frontend.css +1 -1
  225. data/entry_types/scrolled/package/contentElements-frontend.js +719 -529
  226. data/entry_types/scrolled/package/editor.js +459 -261
  227. data/entry_types/scrolled/package/frontend/{EditableText-7093fd0e.js → EditableInlineText.module-b9923660.js} +284 -362
  228. data/entry_types/scrolled/package/frontend/{i18n-4dc6c377.js → PhonePlatformContext-9fb97827.js} +199 -106
  229. data/entry_types/scrolled/package/frontend/{Viewer-e49e7807.js → Viewer-e2290ea0.js} +196 -79
  230. data/entry_types/scrolled/package/frontend/{Wavesurfer-0adf5667.js → Wavesurfer-7d9cf1b7.js} +16 -58
  231. data/entry_types/scrolled/package/frontend/{components-6a6793ca.js → components-6ab26015.js} +664 -671
  232. data/entry_types/scrolled/package/frontend/{getPrototypeOf-63c7c8e8.js → createSuper-d0f30da3.js} +34 -5
  233. data/entry_types/scrolled/package/frontend/index.css +1 -9
  234. data/entry_types/scrolled/package/frontend/index.js +1919 -2386
  235. data/entry_types/scrolled/package/frontend/{useBrowserFeature-91a4c29d.js → usePhonePlatform-2857c22b.js} +9 -8
  236. data/entry_types/scrolled/package/frontend-server.js +3 -6
  237. data/entry_types/scrolled/package/package.json +16 -8
  238. data/entry_types/scrolled/package/testHelpers.js +456 -0
  239. data/entry_types/scrolled/package/values/breakpoints.module.css +9 -0
  240. data/entry_types/scrolled/package/values/colors.module.css +5 -0
  241. data/entry_types/scrolled/package/widgets/defaultNavigation.css +9 -0
  242. data/entry_types/scrolled/package/widgets/defaultNavigation.js +612 -0
  243. data/entry_types/scrolled/spec/fixtures/image.svg +1 -0
  244. data/lib/pageflow/ability_mixin.rb +4 -0
  245. data/lib/pageflow/built_in_widget_type.rb +4 -0
  246. data/lib/pageflow/built_in_widget_types_plugin.rb +7 -0
  247. data/lib/pageflow/configuration.rb +34 -1
  248. data/lib/pageflow/entry_type.rb +11 -2
  249. data/lib/pageflow/entry_type_configuration.rb +2 -0
  250. data/lib/pageflow/file_type.rb +24 -0
  251. data/lib/pageflow/paperclip_processors/audio_waveform.rb +42 -0
  252. data/lib/pageflow/paperclip_processors/noop.rb +10 -0
  253. data/lib/pageflow/theme_customizations.rb +61 -0
  254. data/lib/pageflow/version.rb +1 -1
  255. data/lib/pageflow.rb +9 -0
  256. data/package/config/jest/index.js +2 -1
  257. data/package/config/postcss/scaleFunctions.js +71 -0
  258. data/package/editor.js +95 -85
  259. data/package/frontend.js +521 -161
  260. data/package/package.json +5 -3
  261. data/package/testHelpers.js +26 -5
  262. data/package/ui.js +124 -11
  263. data/spec/factories/draft_entries.rb +19 -1
  264. data/spec/factories/entries.rb +4 -0
  265. data/spec/factories/published_entries.rb +6 -0
  266. data/spec/fixtures/audio.ogg +0 -0
  267. metadata +119 -14
  268. data/app/views/admin/entries/_not_allowed_to_see_entry_types.json.jbuilder +0 -2
  269. data/app/views/admin/entries/entry_types.json.jbuilder +0 -4
  270. data/package/config/jest/transformers/upwardBabel.js +0 -5
@@ -0,0 +1,153 @@
1
+ // scss-lint:disable all
2
+
3
+ // Based on https://github.com/tailwindlabs/tailwindcss-forms/ 0.3.4
4
+
5
+ [type='text'],[type='email'],[type='url'],[type='password'],[type='number'],[type='date'],[type='datetime-local'],[type='month'],[type='search'],[type='tel'],[type='time'],[type='week'],[multiple],textarea,select {
6
+ -webkit-appearance: none;
7
+ -moz-appearance: none;
8
+ appearance: none;
9
+ background-color: #fff;
10
+ border-color: #6b7280;
11
+ border-width: 1px;
12
+ border-radius: 0px;
13
+ padding-top: 0.5rem;
14
+ padding-right: 0.75rem;
15
+ padding-bottom: 0.5rem;
16
+ padding-left: 0.75rem;
17
+ font-size: 1rem;
18
+ line-height: 1.5rem;
19
+ }
20
+
21
+ [type='text']:focus, [type='email']:focus, [type='url']:focus, [type='password']:focus, [type='number']:focus, [type='date']:focus, [type='datetime-local']:focus, [type='month']:focus, [type='search']:focus, [type='tel']:focus, [type='time']:focus, [type='week']:focus, [multiple]:focus, textarea:focus, select:focus {
22
+ outline: 2px solid transparent;
23
+ outline-offset: 2px;
24
+ border-color: #2563eb;
25
+ }
26
+
27
+ input::-moz-placeholder, textarea::-moz-placeholder {
28
+ color: #6b7280;
29
+ opacity: 1;
30
+ }
31
+
32
+ input:-ms-input-placeholder, textarea:-ms-input-placeholder {
33
+ color: #6b7280;
34
+ opacity: 1;
35
+ }
36
+
37
+ input::placeholder,textarea::placeholder {
38
+ color: #6b7280;
39
+ opacity: 1;
40
+ }
41
+
42
+ ::-webkit-datetime-edit-fields-wrapper {
43
+ padding: 0;
44
+ }
45
+
46
+ ::-webkit-date-and-time-value {
47
+ min-height: 1.5em;
48
+ }
49
+
50
+ select {
51
+ background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 20 20'%3e%3cpath stroke='%236b7280' stroke-linecap='round' stroke-linejoin='round' stroke-width='1.5' d='M6 8l4 4 4-4'/%3e%3c/svg%3e");
52
+ background-position: right 0.5rem center;
53
+ background-repeat: no-repeat;
54
+ background-size: 1.5em 1.5em;
55
+ padding-right: 2.5rem;
56
+ -webkit-print-color-adjust: exact;
57
+ color-adjust: exact;
58
+ }
59
+
60
+ [multiple] {
61
+ background-image: initial;
62
+ background-position: initial;
63
+ background-repeat: unset;
64
+ background-size: initial;
65
+ padding-right: 0.75rem;
66
+ -webkit-print-color-adjust: unset;
67
+ color-adjust: unset;
68
+ }
69
+
70
+ [type='checkbox'],[type='radio'] {
71
+ -webkit-appearance: none;
72
+ -moz-appearance: none;
73
+ appearance: none;
74
+ padding: 0;
75
+ -webkit-print-color-adjust: exact;
76
+ color-adjust: exact;
77
+ display: inline-block;
78
+ vertical-align: middle;
79
+ background-origin: border-box;
80
+ -webkit-user-select: none;
81
+ -moz-user-select: none;
82
+ -ms-user-select: none;
83
+ user-select: none;
84
+ flex-shrink: 0;
85
+ height: 1rem;
86
+ width: 1rem;
87
+ color: #2563eb;
88
+ background-color: #fff;
89
+ border-color: #6b7280;
90
+ border-width: 1px;
91
+ }
92
+
93
+ [type='checkbox'] {
94
+ border-radius: 0px;
95
+ }
96
+
97
+ [type='radio'] {
98
+ border-radius: 100%;
99
+ }
100
+
101
+ [type='checkbox']:focus,[type='radio']:focus {
102
+ outline: 2px solid transparent;
103
+ outline-offset: 2px;
104
+ }
105
+
106
+ [type='checkbox']:checked,[type='radio']:checked {
107
+ border-color: transparent;
108
+ background-color: currentColor;
109
+ background-size: 100% 100%;
110
+ background-position: center;
111
+ background-repeat: no-repeat;
112
+ }
113
+
114
+ [type='checkbox']:checked {
115
+ background-image: url("data:image/svg+xml,%3csvg viewBox='0 0 16 16' fill='white' xmlns='http://www.w3.org/2000/svg'%3e%3cpath d='M12.207 4.793a1 1 0 010 1.414l-5 5a1 1 0 01-1.414 0l-2-2a1 1 0 011.414-1.414L6.5 9.086l4.293-4.293a1 1 0 011.414 0z'/%3e%3c/svg%3e");
116
+ }
117
+
118
+ [type='radio']:checked {
119
+ background-image: url("data:image/svg+xml,%3csvg viewBox='0 0 16 16' fill='white' xmlns='http://www.w3.org/2000/svg'%3e%3ccircle cx='8' cy='8' r='3'/%3e%3c/svg%3e");
120
+ }
121
+
122
+ [type='checkbox']:checked:hover,[type='checkbox']:checked:focus,[type='radio']:checked:hover,[type='radio']:checked:focus {
123
+ border-color: transparent;
124
+ background-color: currentColor;
125
+ }
126
+
127
+ [type='checkbox']:indeterminate {
128
+ background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 16 16'%3e%3cpath stroke='white' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M4 8h8'/%3e%3c/svg%3e");
129
+ border-color: transparent;
130
+ background-color: currentColor;
131
+ background-size: 100% 100%;
132
+ background-position: center;
133
+ background-repeat: no-repeat;
134
+ }
135
+
136
+ [type='checkbox']:indeterminate:hover,[type='checkbox']:indeterminate:focus {
137
+ border-color: transparent;
138
+ background-color: currentColor;
139
+ }
140
+
141
+ [type='file'] {
142
+ background: unset;
143
+ border-color: inherit;
144
+ border-width: 0;
145
+ border-radius: 0;
146
+ padding: 0;
147
+ font-size: unset;
148
+ line-height: inherit;
149
+ }
150
+
151
+ [type='file']:focus {
152
+ outline: 1px auto -webkit-focus-ring-color;
153
+ }
@@ -0,0 +1,278 @@
1
+ @import "./normalize/forms";
2
+
3
+ // scss-lint:disable all
4
+ /*! modern-normalize v1.1.0 | MIT License | https://github.com/sindresorhus/modern-normalize */
5
+
6
+ /*
7
+ Document
8
+ ========
9
+ */
10
+
11
+ /**
12
+ 1. Correct the line height in all browsers.
13
+ 2. Prevent adjustments of font size after orientation changes in iOS.
14
+ 3. Use a more readable tab size (opinionated).
15
+ */
16
+
17
+ html {
18
+ line-height: 1.15; /* 1 */
19
+ -webkit-text-size-adjust: 100%; /* 2 */
20
+ -moz-tab-size: 4; /* 3 */
21
+ tab-size: 4; /* 3 */
22
+ }
23
+
24
+ /*
25
+ Sections
26
+ ========
27
+ */
28
+
29
+ /**
30
+ 1. Remove the margin in all browsers.
31
+ 2. Improve consistency of default fonts in all browsers. (https://github.com/sindresorhus/modern-normalize/issues/3)
32
+ */
33
+
34
+ body {
35
+ margin: 0; /* 1 */
36
+ font-family:
37
+ system-ui,
38
+ -apple-system, /* Firefox supports this but not yet `system-ui` */
39
+ 'Segoe UI',
40
+ Roboto,
41
+ Helvetica,
42
+ Arial,
43
+ sans-serif,
44
+ 'Apple Color Emoji',
45
+ 'Segoe UI Emoji'; /* 2 */
46
+ }
47
+
48
+ /*
49
+ Grouping content
50
+ ================
51
+ */
52
+
53
+ /**
54
+ 1. Add the correct height in Firefox.
55
+ 2. Correct the inheritance of border color in Firefox. (https://bugzilla.mozilla.org/show_bug.cgi?id=190655)
56
+ */
57
+
58
+ hr {
59
+ height: 0; /* 1 */
60
+ color: inherit; /* 2 */
61
+ }
62
+
63
+ /*
64
+ Text-level semantics
65
+ ====================
66
+ */
67
+
68
+ /**
69
+ Add the correct text decoration in Chrome, Edge, and Safari.
70
+ */
71
+
72
+ abbr[title] {
73
+ text-decoration: underline dotted;
74
+ }
75
+
76
+ /**
77
+ Add the correct font weight in Edge and Safari.
78
+ */
79
+
80
+ b,
81
+ strong {
82
+ font-weight: bolder;
83
+ }
84
+
85
+ /**
86
+ 1. Improve consistency of default fonts in all browsers. (https://github.com/sindresorhus/modern-normalize/issues/3)
87
+ 2. Correct the odd 'em' font sizing in all browsers.
88
+ */
89
+
90
+ code,
91
+ kbd,
92
+ samp,
93
+ pre {
94
+ font-family:
95
+ ui-monospace,
96
+ SFMono-Regular,
97
+ Consolas,
98
+ 'Liberation Mono',
99
+ Menlo,
100
+ monospace; /* 1 */
101
+ font-size: 1em; /* 2 */
102
+ }
103
+
104
+ /**
105
+ Add the correct font size in all browsers.
106
+ */
107
+
108
+ small {
109
+ font-size: 80%;
110
+ }
111
+
112
+ /**
113
+ Prevent 'sub' and 'sup' elements from affecting the line height in all browsers.
114
+ */
115
+
116
+ sub,
117
+ sup {
118
+ font-size: 75%;
119
+ line-height: 0;
120
+ position: relative;
121
+ vertical-align: baseline;
122
+ }
123
+
124
+ sub {
125
+ bottom: -0.25em;
126
+ }
127
+
128
+ sup {
129
+ top: -0.5em;
130
+ }
131
+
132
+ /*
133
+ Tabular data
134
+ ============
135
+ */
136
+
137
+ /**
138
+ 1. Remove text indentation from table contents in Chrome and Safari. (https://bugs.chromium.org/p/chromium/issues/detail?id=999088, https://bugs.webkit.org/show_bug.cgi?id=201297)
139
+ 2. Correct table border color inheritance in all Chrome and Safari. (https://bugs.chromium.org/p/chromium/issues/detail?id=935729, https://bugs.webkit.org/show_bug.cgi?id=195016)
140
+ */
141
+
142
+ table {
143
+ text-indent: 0; /* 1 */
144
+ border-color: inherit; /* 2 */
145
+ }
146
+
147
+ /*
148
+ Forms
149
+ =====
150
+ */
151
+
152
+ /**
153
+ 1. Change the font styles in all browsers.
154
+ 2. Remove the margin in Firefox and Safari.
155
+ */
156
+
157
+ button,
158
+ input,
159
+ optgroup,
160
+ select,
161
+ textarea {
162
+ font-family: inherit; /* 1 */
163
+ font-size: 100%; /* 1 */
164
+ line-height: 1.15; /* 1 */
165
+ margin: 0; /* 2 */
166
+ }
167
+
168
+ /**
169
+ Remove the inheritance of text transform in Edge and Firefox.
170
+ */
171
+
172
+ button,
173
+ select {
174
+ text-transform: none;
175
+ }
176
+
177
+ /**
178
+ Correct the inability to style clickable types in iOS and Safari.
179
+ */
180
+
181
+ button,
182
+ [type='button'],
183
+ [type='reset'],
184
+ [type='submit'] {
185
+ -webkit-appearance: button;
186
+ }
187
+
188
+ /**
189
+ Remove the inner border and padding in Firefox.
190
+ */
191
+
192
+ ::-moz-focus-inner {
193
+ border-style: none;
194
+ padding: 0;
195
+ }
196
+
197
+ /**
198
+ Restore the focus styles unset by the previous rule.
199
+ */
200
+
201
+ :-moz-focusring {
202
+ outline: 1px dotted ButtonText;
203
+ }
204
+
205
+ /**
206
+ Remove the additional ':invalid' styles in Firefox.
207
+ See: https://github.com/mozilla/gecko-dev/blob/2f9eacd9d3d995c937b4251a5557d95d494c9be1/layout/style/res/forms.css#L728-L737
208
+ */
209
+
210
+ :-moz-ui-invalid {
211
+ box-shadow: none;
212
+ }
213
+
214
+ /**
215
+ Remove the padding so developers are not caught out when they zero out 'fieldset' elements in all browsers.
216
+ */
217
+
218
+ legend {
219
+ padding: 0;
220
+ }
221
+
222
+ /**
223
+ Add the correct vertical alignment in Chrome and Firefox.
224
+ */
225
+
226
+ progress {
227
+ vertical-align: baseline;
228
+ }
229
+
230
+ /**
231
+ Correct the cursor style of increment and decrement buttons in Safari.
232
+ */
233
+
234
+ ::-webkit-inner-spin-button,
235
+ ::-webkit-outer-spin-button {
236
+ height: auto;
237
+ }
238
+
239
+ /**
240
+ 1. Correct the odd appearance in Chrome and Safari.
241
+ 2. Correct the outline style in Safari.
242
+ */
243
+
244
+ [type='search'] {
245
+ -webkit-appearance: textfield; /* 1 */
246
+ outline-offset: -2px; /* 2 */
247
+ }
248
+
249
+ /**
250
+ Remove the inner padding in Chrome and Safari on macOS.
251
+ */
252
+
253
+ ::-webkit-search-decoration {
254
+ -webkit-appearance: none;
255
+ }
256
+
257
+ /**
258
+ 1. Correct the inability to style clickable types in iOS and Safari.
259
+ 2. Change font properties to 'inherit' in Safari.
260
+ */
261
+
262
+ ::-webkit-file-upload-button {
263
+ -webkit-appearance: button; /* 1 */
264
+ font: inherit; /* 2 */
265
+ }
266
+
267
+ /*
268
+ Interactive
269
+ ===========
270
+ */
271
+
272
+ /*
273
+ Add the correct display in Chrome and Safari.
274
+ */
275
+
276
+ summary {
277
+ display: list-item;
278
+ }
@@ -0,0 +1,44 @@
1
+ :root { // scss-lint:disable PropertyCount
2
+ --ui-font-size: 13px;
3
+
4
+ --ui-surface-color: #fff;
5
+ --ui-backdrop-color: rgba(6, 32, 42, 0.6);
6
+
7
+ --ui-on-surface-color: hsl(197, 26%, 23%);
8
+ --ui-on-surface-color-light: hsla(197, 26%, 23%, 0.8);
9
+ --ui-on-surface-color-lighter: hsla(197, 26%, 23%, 0.3);
10
+ --ui-on-surface-color-lightest: hsla(197, 26%, 23%, 0.1);
11
+
12
+ --ui-on-surface-color-light-solid: #{mix(#06202a, #fff, 80%)};
13
+ --ui-on-surface-color-lighter-solid: #{mix(#06202a, #fff, 30%)};
14
+ --ui-on-surface-color-lightest-solid: #{mix(#06202a, #fff, 10%)};
15
+
16
+ --ui-primary-color: hsla(197, 37%, 24%);
17
+ --ui-primary-color-light: hsla(197, 37%, 24%, 0.6);
18
+ --ui-primary-color-lighter: hsla(197, 37%, 24%, 0.3);
19
+ --ui-primary-color-lightest: hsla(197, 37%, 24%, 0.1);
20
+
21
+ --ui-on-primary-color: rgba(255, 255, 255);
22
+ --ui-on-primary-color-light: rgba(255, 255, 255, 0.6);
23
+ --ui-on-primary-color-lighter: rgba(255, 255, 255, 0.3);
24
+ --ui-on-primary-color-lightest: rgba(255, 255, 255, 0.1);
25
+
26
+ --ui-selection-color: #99d4ec;
27
+ --ui-selection-color-light: hsla(197, 69%, 76%, 0.6);
28
+ --ui-selection-color-lighter: hsla(197, 69%, 76%, 0.3);
29
+ --ui-selection-color-lightest: hsla(197, 69%, 76%, 0.1);
30
+
31
+ --ui-error-color: #ff4d6d;
32
+ --ui-error-color-light: hsla(349, 100%, 65%, 0.6);
33
+ --ui-error-color-lighter: hsla(349, 100%, 65%, 0.3);
34
+ --ui-on-error-color: #fff;
35
+ --ui-on-error-surface-color: #912c3c;
36
+ --ui-error-surface-color: #{mix(#ff4d6d, #fff, 10%)};
37
+
38
+ --ui-box-shadow-sm: 0 1px 2px 0 rgb(0 0 0 / 0.05);
39
+ --ui-box-shadow: 0 1px 3px 0 rgb(0 0 0 / 0.25), 0 1px 2px -1px rgb(0 0 0 / 0.25);
40
+ --ui-box-shadow-md: 0 4px 6px -1px rgb(0 0 0 / 0.25), 0 2px 4px -2px rgb(0 0 0 / 0.25);
41
+ --ui-box-shadow-lg: 0 10px 15px -3px rgb(0 0 0 / 0.1), 0 4px 6px -4px rgb(0 0 0 / 0.1);
42
+ --ui-box-shadow-xl: 0 20px 25px -5px rgb(0 0 0 / 0.1), 0 8px 10px -6px rgb(0 0 0 / 0.1);
43
+ --ui-box-shadow-2xl: 0 25px 50px -12px rgb(0 0 0 / 0.25);
44
+ }
@@ -1,6 +1,6 @@
1
1
  .delete_row_table_cell {
2
2
  .remove {
3
- @include icon-only-button(#aaa);
3
+ @include icon-only-button("destructive");
4
4
  @include trash-icon;
5
5
  float: right;
6
6
  }
@@ -1,33 +1,29 @@
1
- $table-view-header-background-color: #444 !default;
2
- $table-view-header-color: #fff !default;
3
- $table-view-cell-background-color: #fff !default;
4
- $table-view-blank-slate-color: #888 !default;
5
- $table-view-selected-cell-background-color: #d2e5fa !default;
6
-
7
1
  .table_view {
8
2
  border-spacing: 0 1px;
3
+ margin-top: -1px;
9
4
 
10
5
  th {
11
- background-color: $table-view-header-background-color;
12
- color: $table-view-header-color;
13
- padding: 5px 10px;
6
+ padding: space(1) space(2);
7
+ border-bottom: solid 1px var(--ui-on-surface-color-lighter);
14
8
  text-align: left;
15
-
16
- font-size: 11px;
17
- text-transform: uppercase;
9
+ font-weight: 500;
18
10
  }
19
11
 
20
12
  td {
21
- background-color: $table-view-cell-background-color;
22
- padding: 10px;
13
+ padding: space(2);
14
+ }
15
+
16
+ tr:hover td {
17
+ background-color: var(--ui-selection-color-lighter);
23
18
  }
24
19
 
25
- .is_selected > td {
26
- background-color: $table-view-selected-cell-background-color;
20
+ tr.is_selected > td {
21
+ background-color: var(--ui-selection-color-light);
27
22
  }
28
23
 
29
- .blank_slate > td {
24
+ tr.blank_slate > td {
30
25
  text-align: center;
31
- color: $table-view-blank-slate-color;
26
+ background-color: transparent;
27
+ color: var(--ui-on-surface-color-light);
32
28
  }
33
29
  }
@@ -1,9 +1,9 @@
1
1
  .tabs_view {
2
2
  &-scroller {
3
- background-color: #e5e5e5;
4
3
  position: relative;
5
4
  overflow: hidden;
6
- height: 35px;
5
+ height: 36px;
6
+ border-bottom: solid 1px var(--ui-on-surface-color-lighter);
7
7
  }
8
8
 
9
9
  &-headers {
@@ -14,25 +14,22 @@
14
14
  li {
15
15
  display: inline-block;
16
16
  padding: 10px 10px;
17
- background-color: #e5e5e5;
18
17
  cursor: pointer;
18
+ color: var(--ui-on-surface-color-light);
19
+ height: 14px;
19
20
 
20
21
  &.active {
21
- background-color: #fff;
22
+ color: var(--ui-primary-color);
23
+ border-bottom: solid 2px var(--ui-primary-color);
24
+ font-weight: bold;
22
25
  }
23
26
 
24
27
  &.spinner {
25
28
  padding-left: 27px;
26
- @include background-icon-left;
29
+ @include background-icon-left($color: var(--ui-primary-color));
27
30
  @include background-icon-animation(blink);
28
31
  @include up-bold-icon;
29
32
  }
30
33
  }
31
34
  }
32
-
33
- &-container {
34
- background-color: #fff;
35
- padding: 10px;
36
- }
37
-
38
35
  }
@@ -1,18 +1,16 @@
1
1
  .tooltip {
2
- $background-color: rgba(0, 0, 0, 0.9);
3
-
4
2
  position: absolute;
5
3
  z-index: 10001;
6
4
  top: 40px;
7
5
  max-width: 70%;
8
6
  padding: 10px 15px;
9
- color: #fff;
10
- font-size: 13px;
7
+ color: var(--ui-on-primary-color);
11
8
  font-weight: normal;
12
9
  text-decoration: none;
13
10
  pointer-events: none;
14
11
  border-radius: 5px;
15
- background-color: $background-color;
12
+ background-color: var(--ui-primary-color);
13
+ box-shadow: var(--ui-box-shadow);
16
14
 
17
15
  opacity: 0;
18
16
  @include transition(opacity 0.15s ease);
@@ -24,7 +22,7 @@
24
22
  &:after {
25
23
  content: '';
26
24
  border-top: solid 10px transparent;
27
- border-right: solid 10px $background-color;
25
+ border-right: solid 10px var(--ui-primary-color);
28
26
  border-bottom: solid 10px transparent;
29
27
  border-left: solid 10px transparent;
30
28
  position: absolute;
@@ -37,7 +35,7 @@
37
35
  &:after {
38
36
  border-top: solid 10px transparent;
39
37
  border-right: solid 10px transparent;
40
- border-bottom: solid 10px $background-color;
38
+ border-bottom: solid 10px var(--ui-primary-color);
41
39
  border-left: solid 10px transparent;
42
40
 
43
41
  top: -20px;
@@ -49,7 +47,7 @@
49
47
  transform: translate(-50%, -100%);
50
48
 
51
49
  &:after {
52
- border-top: solid 10px $background-color;
50
+ border-top: solid 10px var(--ui-primary-color);
53
51
  border-right: solid 10px transparent;
54
52
  border-bottom: solid 10px transparent;
55
53
  border-left: solid 10px transparent;
@@ -0,0 +1,6 @@
1
+ .validation_error_messages {
2
+ padding: 0;
3
+ margin: 5px 0;
4
+ color: var(--ui-error-color);
5
+ list-style: none;
6
+ }
@@ -2,6 +2,9 @@
2
2
  @import "jquery.minicolors";
3
3
  @import "pageflow/mixins";
4
4
 
5
+ @import "./ui/properties";
6
+ @import "./ui/functions";
7
+
5
8
  %pageflow-ui {
6
9
  @import "./ui/forms";
7
10
  @import "./ui/input/color_input";
@@ -11,6 +14,7 @@
11
14
  @import "./ui/table_cells/icon_table_cell";
12
15
  @import "./ui/tabs_view";
13
16
  @import "./ui/tooltip";
17
+ @import "./ui/validation_error_messages";
14
18
  }
15
19
 
16
20
  @import "./ui/input/extended_select_input";
@@ -8,7 +8,9 @@ module Pageflow
8
8
  entry = Entry.find(params[:entry_id])
9
9
  authorize!(:edit, entry)
10
10
  entry.edit_lock.acquire(current_user, edit_lock_params)
11
- entry.snapshot(:creator => current_user)
11
+
12
+ entry.snapshot(creator: current_user) unless entry.feature_state('no_edit_lock_snapshot')
13
+
12
14
  respond_with(entry.reload.edit_lock, :location => entry_edit_lock_url(entry))
13
15
  end
14
16
 
@@ -19,18 +19,8 @@ module Pageflow
19
19
  end
20
20
  end
21
21
 
22
- def entry_type_collection
23
- entry_type_collection_for_config(Pageflow.config)
24
- end
25
-
26
- def entry_type_collection_for_account(target)
27
- entry_type_collection_for_config(Pageflow.config_for(target))
28
- end
29
-
30
- private
31
-
32
- def entry_type_collection_for_config(config)
33
- config.entry_types.map(&:name).index_by do |type|
22
+ def entry_type_collection(entry_types = Pageflow.config.entry_types)
23
+ entry_types.map(&:name).index_by do |type|
34
24
  I18n.t(type, scope: 'activerecord.values.pageflow/entry.type_names')
35
25
  end
36
26
  end
@@ -11,7 +11,7 @@ module Pageflow
11
11
  end
12
12
 
13
13
  def call
14
- %'<iframe src="#{url(entry)}" scrolling="no" allowfullscreen></iframe>'
14
+ %'<iframe src="#{url(entry)}" allowfullscreen></iframe>'
15
15
  end
16
16
 
17
17
  private