card 1.98.3 → 1.99.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (364) hide show
  1. checksums.yaml +4 -4
  2. data/VERSION +1 -1
  3. data/config/locales/de.yml +7 -7
  4. data/config/locales/en.yml +7 -7
  5. data/config/locales/es.yml +7 -7
  6. data/db/migrate_core_cards/20150610180019_add_recaptcha_key_and_admin_info_cards.rb +3 -3
  7. data/db/migrate_core_cards/20160801143221_change_bootstrap_card_type_to_scss.rb +1 -1
  8. data/db/migrate_core_cards/20160804112510_reorganize_scripts.rb +1 -1
  9. data/db/migrate_core_cards/20160908154210_add_trash_card.rb +1 -1
  10. data/db/migrate_core_cards/20180508210903_add_json_type.rb +3 -3
  11. data/db/migrate_core_cards/20180712042655_head_rule.rb +1 -1
  12. data/db/migrate_core_cards/{20180905061536_migrate_layouts.rb → 20180905061537_migrate_layouts.rb} +12 -1
  13. data/db/migrate_core_cards/20190204195039_add_rule_card.rb +3 -0
  14. data/db/migrate_core_cards/20190320091257_upgrade_recaptcha_to_v3.rb +5 -6
  15. data/db/migrate_core_cards/20190417142612_reorganize_scripts_2.rb +3 -3
  16. data/db/migrate_core_cards/20190502130029_add_shark_and_help_desk_role.rb +4 -5
  17. data/db/migrate_core_cards/20190618110446_add_dropdown_divider.rb +1 -1
  18. data/db/migrate_core_cards/20190710090209_homepage_tweaks.rb +17 -0
  19. data/db/migrate_core_cards/20190820155833_update_cardtype_type_structure.rb +7 -0
  20. data/db/migrate_core_cards/20190822093633_move_help_text_to_code.rb +38 -0
  21. data/db/migrate_core_cards/20190823220018_cleanup_for_decko_1_0.rb +21 -0
  22. data/db/migrate_core_cards/20190826132738_add_more_guides.rb +7 -0
  23. data/db/migrate_core_cards/20190829093961_cardtype_grouping.rb +16 -0
  24. data/db/migrate_core_cards/20190829205148_remove_add_help.rb +14 -0
  25. data/db/migrate_core_cards/20190830131820_setting_settings_aside.rb +17 -0
  26. data/db/migrate_core_cards/20190902161223_add_style_media.rb +7 -0
  27. data/db/migrate_core_cards/20190902193208_input_type.rb +22 -0
  28. data/db/migrate_core_cards/20190904174403_token_upgrade.rb +14 -0
  29. data/db/migrate_core_cards/20190909104250_add_cardtype_input_types.rb +10 -0
  30. data/db/migrate_core_cards/20190918200115_ensure_description_card.rb +13 -0
  31. data/db/migrate_core_cards/data/cards.yml +12 -8
  32. data/db/migrate_core_cards/data/cards/Xaccount +22 -0
  33. data/db/migrate_core_cards/data/cards/Xgetting_started +5 -5
  34. data/db/migrate_core_cards/data/cards/{Xgetting_started-link → Xgetting_started_link} +0 -0
  35. data/db/migrate_core_cards/data/cards/Xmain_menu +1 -1
  36. data/db/migrate_core_cards/data/cards/Xstructure-Xright-Xguide +12 -0
  37. data/db/migrate_core_cards/data/cards/administrator-dashboard +5 -0
  38. data/db/migrate_core_cards/data/cards/cardtype-Xtype-Xguide +24 -0
  39. data/db/migrate_core_cards/data/cards/cardtype-Xtype-Xstructure +3 -3
  40. data/db/migrate_core_cards/data/cards/shark-dashboard +2 -2
  41. data/db/migrate_core_cards/data/mailer/password_reset_email.html +6 -3
  42. data/db/migrate_core_cards/data/mailer/password_reset_email.txt +1 -1
  43. data/db/migrate_core_cards/data/mailer/verification_email.html +5 -2
  44. data/db/migrate_core_cards/data/mailer/verification_email.txt +2 -1
  45. data/db/seed/README.md +1 -1
  46. data/db/seed/new/card_actions.yml +2118 -2534
  47. data/db/seed/new/card_acts.yml +2 -2
  48. data/db/seed/new/card_references.yml +2326 -2466
  49. data/db/seed/new/cards.yml +2654 -3713
  50. data/db/seed/new/schema_migrations_core_cards.yml +77 -39
  51. data/db/seed/test/fixtures/card_actions.yml +3225 -3681
  52. data/db/seed/test/fixtures/card_acts.yml +503 -509
  53. data/db/seed/test/fixtures/card_changes.yml +66 -66
  54. data/db/seed/test/fixtures/card_references.yml +3135 -3275
  55. data/db/seed/test/fixtures/cards.yml +4187 -5516
  56. data/db/seed/test/fixtures/schema_migrations_core_cards.yml +77 -39
  57. data/db/{seed/test/seed.rb → test_seed.rb} +13 -11
  58. data/lib/card/auth.rb +1 -0
  59. data/lib/card/auth/current.rb +25 -27
  60. data/lib/card/auth/setup.rb +13 -12
  61. data/lib/card/auth/token.rb +38 -0
  62. data/lib/card/content.rb +34 -7
  63. data/lib/card/content/clean.rb +2 -1
  64. data/lib/card/content/truncate.rb +2 -0
  65. data/lib/card/env/success.rb +1 -14
  66. data/lib/card/error.rb +1 -0
  67. data/lib/card/format/content.rb +2 -2
  68. data/lib/card/format/error.rb +1 -1
  69. data/lib/card/format/nest.rb +1 -1
  70. data/lib/card/format/nesting.rb +2 -2
  71. data/lib/card/format/nesting/mode.rb +15 -15
  72. data/lib/card/mod/loader.rb +5 -0
  73. data/lib/card/model/save_helper.rb +2 -0
  74. data/lib/card/query.rb +1 -0
  75. data/lib/card/query/card_query/reference_attributes.rb +4 -2
  76. data/lib/card/seed_consts.rb +1 -1
  77. data/lib/card/set/format/abstract_format.rb +3 -5
  78. data/lib/card/set/format/abstract_format/view_opts.rb +1 -1
  79. data/lib/card/set/required_field.rb +8 -3
  80. data/lib/card/set_pattern.rb +10 -0
  81. data/lib/card/view/cache/stub.rb +3 -20
  82. data/lib/card/view/options.rb +4 -3
  83. data/lib/card/view/options/voo_api.rb +1 -1
  84. data/lib/cardio.rb +7 -1
  85. data/mod/Modfile +1 -0
  86. data/mod/account/set/abstract/account_field.rb +15 -0
  87. data/mod/account/set/abstract/accounted.rb +15 -0
  88. data/mod/account/set/all/account.rb +0 -4
  89. data/mod/account/set/right/account.rb +23 -151
  90. data/mod/account/set/right/account/events.rb +98 -0
  91. data/mod/account/set/right/account/views.rb +65 -0
  92. data/mod/account/set/right/api_key.rb +48 -0
  93. data/mod/account/set/right/email.rb +2 -2
  94. data/mod/account/set/right/password.rb +6 -9
  95. data/mod/account/set/right/salt.rb +5 -1
  96. data/mod/account/set/right/status.rb +10 -1
  97. data/mod/account/set/self/signin.rb +3 -3
  98. data/mod/account/set/type/role.rb +4 -0
  99. data/mod/account/set/type/signup.rb +31 -158
  100. data/mod/account/{template → set}/type/signup/core.haml +0 -0
  101. data/mod/account/set/type/signup/views.rb +93 -0
  102. data/mod/account/set/type/user.rb +16 -27
  103. data/mod/account/set/type/user/setup_help.haml +10 -0
  104. data/mod/account/spec/set/all/account_spec.rb +84 -98
  105. data/mod/account/spec/set/right/account_spec.rb +40 -33
  106. data/mod/account/spec/set/self/signin_spec.rb +2 -2
  107. data/mod/account/spec/set/type/signup_spec.rb +40 -78
  108. data/mod/ace_editor/db/migrate_core_cards/{20160805112548_delete_ace_help_card.rb → 20180805112548_delete_ace_help_card.rb} +1 -1
  109. data/mod/admin/set/self/debugger.rb +3 -0
  110. data/mod/admin/set/self/trash.rb +1 -1
  111. data/mod/basic_formats/set/all/all_css.rb +1 -1
  112. data/mod/basic_formats/set/all/all_csv.rb +1 -1
  113. data/mod/basic_formats/set/all/base.rb +19 -60
  114. data/mod/basic_formats/set/self/head.rb +1 -1
  115. data/mod/basic_types/set/type/html.rb +7 -3
  116. data/mod/basic_types/set/type/json.rb +1 -1
  117. data/mod/basic_types/set/type/plain_text.rb +1 -1
  118. data/mod/{standard → basic_types}/spec/set/type/html_spec.rb +6 -6
  119. data/mod/basic_types/spec/set/type/plain_text_spec.rb +7 -2
  120. data/mod/bootstrap/db/migrate_core_cards/20170719163733_update_bootswatch_themes_to_4_beta.rb +3 -3
  121. data/mod/bootstrap/db/migrate_core_cards/20180423160231_migrate_customized_bootstrap_skin.rb +2 -2
  122. data/mod/bootstrap/db/migrate_core_cards/20180423170283_add_type_bootswatch_skin.rb +1 -1
  123. data/mod/bootstrap/db/migrate_core_cards/lib/skin.rb +1 -1
  124. data/mod/bootstrap/lib/javascript/script_load_select2.js.coffee +26 -18
  125. data/mod/bootstrap/lib/stylesheets/style_bootstrap_cards.scss +18 -3
  126. data/mod/bootstrap/set/abstract/bootswatch_theme/html_views.rb +1 -1
  127. data/mod/bootstrap/set/all/bootstrap/helper.rb +9 -4
  128. data/mod/bootstrap/set/type/customized_bootswatch_skin.rb +1 -1
  129. data/mod/bootstrap/set/type_plus_right/customized_bootswatch_skin/colors.rb +1 -1
  130. data/mod/bootstrap/set/type_plus_right/customized_bootswatch_skin/colors/{editor.haml → input.haml} +0 -0
  131. data/mod/bootstrap/spec/set/all/bootstrap/form_spec.rb +2 -2
  132. data/mod/carrierwave/set/self/favicon.rb +5 -0
  133. data/mod/carrierwave/set/self/new_file.rb +1 -1
  134. data/mod/carrierwave/set/self/new_image.rb +1 -1
  135. data/mod/carrierwave/set/type/file.rb +1 -1
  136. data/mod/carrierwave/set/type/image.rb +2 -2
  137. data/mod/carrierwave/set/type/image/html_views.rb +0 -35
  138. data/mod/carrierwave/spec/set/type/image_spec.rb +1 -1
  139. data/mod/core/chunk/link.rb +4 -2
  140. data/mod/core/chunk/view_stub.rb +5 -4
  141. data/mod/core/set/abstract/code_file.rb +1 -1
  142. data/mod/core/set/all/codename.rb +2 -1
  143. data/mod/core/set/all/content.rb +59 -0
  144. data/mod/core/set/all/event_conditions.rb +17 -2
  145. data/mod/core/set/all/location_history.rb +1 -1
  146. data/mod/core/set/all/name.rb +1 -1
  147. data/mod/core/set/all/permissions.rb +6 -36
  148. data/mod/core/set/all/references.rb +9 -2
  149. data/mod/core/set/all/rules.rb +0 -5
  150. data/mod/core/set_pattern/03_type.rb +4 -0
  151. data/mod/core/set_pattern/07_right.rb +4 -0
  152. data/mod/core/set_pattern/08_type_plus_right.rb +4 -0
  153. data/mod/core/set_pattern/09_self.rb +4 -0
  154. data/mod/core/spec/chunk/link_spec.rb +6 -0
  155. data/mod/core/spec/chunk/nest_spec.rb +2 -2
  156. data/mod/core/spec/set/all/permissions_spec.rb +0 -10
  157. data/mod/core/spec/set/all/rules_spec.rb +6 -16
  158. data/mod/date/set/self/datepicker.rb +6 -0
  159. data/mod/date/set/type/date.rb +1 -1
  160. data/mod/date/spec/set/type/date_spec.rb +1 -1
  161. data/mod/edit/set/all/bridge/account_section.rb +16 -0
  162. data/mod/edit/set/all/bridge/bridge_pills.rb +47 -0
  163. data/mod/edit/set/all/bridge/related_section.rb +34 -0
  164. data/mod/edit/set/all/bridge/tab_views.rb +9 -40
  165. data/mod/edit/set/all/bridge/tab_visibility.rb +2 -2
  166. data/mod/edit/set/all/edit_content.rb +3 -3
  167. data/mod/edit/set/all/edit_inline.rb +15 -4
  168. data/mod/edit/set/all/edit_name.rb +5 -7
  169. data/mod/edit/set/all/edit_type.rb +25 -23
  170. data/mod/edit/set/all/editing.rb +5 -1
  171. data/mod/edit/set/all/editor.rb +28 -15
  172. data/mod/edit/set/all/form.rb +38 -17
  173. data/mod/edit/set/all/form_buttons.rb +11 -2
  174. data/mod/edit/set/all/formgroup.rb +5 -5
  175. data/mod/edit/set/all/nest_editor.rb +20 -4
  176. data/mod/edit/set/all/nest_editor/_help.haml +7 -0
  177. data/mod/edit/set/all/nest_editor/nest_editor.haml +3 -2
  178. data/mod/edit/set/all/new.rb +40 -23
  179. data/mod/edit/set/all/overlay_guide.haml +7 -0
  180. data/mod/edit/set/all/overlay_guide.rb +9 -0
  181. data/mod/edit/set/all/template_nest.rb +42 -0
  182. data/mod/edit/set/type/list.rb +15 -0
  183. data/mod/edit/set/type/plain_text.rb +13 -0
  184. data/mod/edit/set/type/pointer.rb +11 -0
  185. data/mod/edit/spec/set/all/bridge/tab_views_spec.rb +1 -1
  186. data/mod/email/set/all/email_html.rb +2 -2
  187. data/mod/email/set/all/email_text.rb +2 -2
  188. data/mod/follow/lib/card/follower_stash.rb +1 -1
  189. data/mod/follow/set/all/follow/followed_by.rb +1 -1
  190. data/mod/follow/set/all/notify/base_views.rb +3 -3
  191. data/mod/follow/set/right/following.rb +1 -1
  192. data/mod/follow/set/self/follow_defaults.rb +1 -1
  193. data/mod/follow/set/type/cardtype.rb +6 -0
  194. data/mod/follow/set/type_plus_right/user/follow.rb +1 -1
  195. data/mod/history/lib/card/act/act_renderer.rb +1 -1
  196. data/mod/history/lib/card/action.rb +2 -1
  197. data/mod/history/set/all/history_bridge.rb +0 -1
  198. data/mod/item/set/all/bar.rb +15 -7
  199. data/mod/machines/file/all_script_machine_output/file.js +38245 -69
  200. data/mod/machines/file/all_style_machine_output/file.css +4 -4
  201. data/mod/machines/file/script_html5shiv_printshiv_machine_output/file.js +1 -1
  202. data/mod/machines/lib/javascript/decko/bridge.js.coffee +4 -0
  203. data/mod/machines/lib/javascript/decko/card_menu.js.coffee +11 -0
  204. data/mod/machines/lib/javascript/decko/name_editor.js.coffee +1 -1
  205. data/mod/machines/lib/javascript/decko/nest_editor.js.coffee +3 -1
  206. data/mod/machines/lib/javascript/decko/nest_editor_name.js.coffee +29 -6
  207. data/mod/machines/lib/javascript/decko/overlay.js.coffee +3 -2
  208. data/mod/machines/lib/javascript/decko/slot.js.coffee +12 -2
  209. data/mod/machines/lib/stylesheets/style_cards.scss +43 -53
  210. data/mod/machines/lib/stylesheets/style_jquery_ui_smoothness.css +13 -13
  211. data/mod/machines/set/abstract/script.rb +1 -1
  212. data/mod/machines/set/type/css.rb +1 -1
  213. data/mod/media/lib/stylesheets/style_image_box.scss +79 -0
  214. data/mod/{utility → media}/set/abstract/media.rb +0 -0
  215. data/mod/{utility → media}/set/abstract/media/media_snippet.haml +0 -0
  216. data/mod/media/set/self/style_media.rb +6 -0
  217. data/mod/media/set/type/image.rb +38 -0
  218. data/mod/{utility → media}/spec/set/abstract/media_spec.rb +0 -0
  219. data/mod/navbar/set/right/enabled_roles.rb +1 -1
  220. data/mod/pointer/lib/javascript/script_pointer_config.js.coffee +13 -0
  221. data/mod/pointer/lib/javascript/script_pointer_list_editor.js.coffee +7 -2
  222. data/mod/pointer/set/abstract/02_pointer/html_views.rb +15 -6
  223. data/mod/pointer/set/abstract/02_pointer/html_views/checkbox_input.haml +1 -2
  224. data/mod/pointer/set/abstract/02_pointer/html_views/list_input.haml +1 -2
  225. data/mod/pointer/set/abstract/02_pointer/html_views/list_item.haml +2 -0
  226. data/mod/pointer/set/abstract/02_pointer/html_views/radio_input.haml +1 -2
  227. data/mod/pointer/set/abstract/02_pointer/options_api.rb +6 -13
  228. data/mod/pointer/set/right/{options.rb → content_options.rb} +0 -0
  229. data/mod/pointer/set/type/link_list.rb +23 -6
  230. data/mod/pointer/set/type/link_list/link_list_input.haml +24 -0
  231. data/mod/pointer/set/type/mirrored_list.rb +1 -1
  232. data/mod/pointer/spec/set/abstract/pointer/html_views_spec.rb +20 -18
  233. data/mod/pointer/spec/set/abstract/pointer/options_api_spec.rb +2 -1
  234. data/mod/pointer/spec/set/self/input_options_spec.rb +1 -1
  235. data/mod/rules/set/right/self.rb +3 -0
  236. data/mod/rules/set/rule/bar_view.rb +88 -0
  237. data/mod/rules/set/rule/bridge_rules_editor.rb +5 -10
  238. data/mod/rules/set/rule/editor.rb +40 -113
  239. data/mod/rules/set/rule/html_views.rb +13 -0
  240. data/mod/rules/set/rule/quick_editor.rb +39 -0
  241. data/mod/rules/set/rule/{editor → quick_editor}/quick_edit.haml +0 -0
  242. data/mod/rules/set/rule/{editor → quick_editor}/set_info.haml +1 -1
  243. data/mod/rules/set/rule/rule_form/buttons.rb +3 -1
  244. data/mod/rules/set/rule/rule_form/form_elements.rb +2 -2
  245. data/mod/rules/set/rule/rule_form/rule_set_radio.rb +3 -6
  246. data/mod/rules/set/rule/rule_form/set_selection.rb +3 -10
  247. data/mod/rules/set/rule/rules.rb +10 -1
  248. data/mod/rules/set/type/set.rb +37 -20
  249. data/mod/rules/set/type/set/html_views.rb +17 -35
  250. data/mod/rules/set/type/set/html_views/group_panel.haml +1 -1
  251. data/mod/rules/set/type/set/html_views/rule_lists.rb +42 -0
  252. data/mod/rules/set/type/set/html_views/template.rb +1 -32
  253. data/mod/rules/set/type/set/rules_filter.rb +24 -10
  254. data/mod/rules/set/type/set/setting_lists.rb +17 -24
  255. data/mod/rules/spec/set/rule/bar_view_spec.rb +15 -0
  256. data/mod/rules/spec/set/rule/editor_spec.rb +15 -1
  257. data/mod/rules/spec/set/type/set/html_views_spec.rb +0 -13
  258. data/mod/rules/spec/set/type/set/setting_lists_spec.rb +17 -0
  259. data/mod/rules/spec/set/type/set_spec.rb +3 -8
  260. data/mod/search/set/abstract/03_filter/form_helper.rb +9 -7
  261. data/mod/search/set/abstract/search/views.rb +2 -2
  262. data/mod/search/set/right/children.rb +4 -0
  263. data/mod/search/set/right/created.rb +3 -0
  264. data/mod/search/set/right/edited.rb +3 -0
  265. data/mod/search/set/right/editors.rb +3 -0
  266. data/mod/search/set/right/follow.rb +3 -0
  267. data/mod/search/set/right/linked_to_by.rb +3 -0
  268. data/mod/search/set/right/links_to.rb +3 -0
  269. data/mod/search/set/right/mates.rb +3 -0
  270. data/mod/search/set/right/nested_by.rb +3 -0
  271. data/mod/search/set/right/nests.rb +3 -0
  272. data/mod/search/set/right/referred_to_by.rb +3 -0
  273. data/mod/search/set/right/refers_to.rb +3 -0
  274. data/mod/search/set/self/search.rb +1 -1
  275. data/mod/search/set/type/search_type.rb +6 -5
  276. data/mod/settings/lib/card/setting.rb +17 -4
  277. data/mod/settings/set/abstract/permission.rb +6 -2
  278. data/mod/settings/set/all/supports_content_options.rb +7 -0
  279. data/mod/settings/set/right/content_option_view.rb +10 -0
  280. data/mod/settings/set/right/content_options.rb +18 -0
  281. data/mod/settings/set/right/default.rb +18 -2
  282. data/mod/settings/set/right/help.rb +2 -1
  283. data/mod/settings/set/right/input_type.rb +35 -0
  284. data/mod/settings/set/right/script.rb +6 -0
  285. data/mod/settings/set/right/structure.rb +7 -1
  286. data/mod/settings/set/right/style.rb +2 -2
  287. data/mod/settings/set/right/style/{editor.haml → input.haml} +0 -0
  288. data/mod/settings/set/self/autoname.rb +3 -1
  289. data/mod/settings/set/self/captcha.rb +4 -1
  290. data/mod/settings/set/self/content_option_view.rb +10 -0
  291. data/mod/settings/set/self/content_options.rb +10 -0
  292. data/mod/settings/set/self/create.rb +2 -1
  293. data/mod/settings/set/self/default.rb +1 -1
  294. data/mod/settings/set/self/delete.rb +2 -1
  295. data/mod/settings/set/self/guide.rb +1 -1
  296. data/mod/settings/set/self/head.rb +3 -1
  297. data/mod/settings/set/self/help.rb +3 -1
  298. data/mod/settings/set/self/input_type.rb +13 -0
  299. data/mod/settings/set/self/layout.rb +3 -1
  300. data/mod/settings/set/self/on_create.rb +2 -1
  301. data/mod/settings/set/self/on_delete.rb +2 -1
  302. data/mod/settings/set/self/on_update.rb +2 -1
  303. data/mod/settings/set/self/read.rb +2 -1
  304. data/mod/settings/set/self/structure.rb +3 -1
  305. data/mod/settings/set/self/style.rb +3 -1
  306. data/mod/settings/set/self/table_of_contents.rb +4 -1
  307. data/mod/settings/set/self/thanks.rb +3 -1
  308. data/mod/settings/set/self/update.rb +2 -1
  309. data/mod/settings/set/type/setting.rb +15 -37
  310. data/mod/settings/spec/set/right/comment_spec.rb +0 -27
  311. data/mod/settings/spec/set/right/create_spec.rb +1 -1
  312. data/mod/settings/spec/set/right/structure_spec.rb +13 -10
  313. data/mod/settings/spec/set/type/setting_spec.rb +1 -8
  314. data/mod/solid_cache/set/right/solid_cache.rb +3 -3
  315. data/mod/standard/set/all/comment.rb +1 -1
  316. data/mod/standard/set/all/error.rb +2 -2
  317. data/mod/standard/set/all/path.rb +7 -7
  318. data/mod/standard/set/all/rich_html/content.rb +41 -11
  319. data/mod/standard/set/all/rich_html/error.rb +14 -22
  320. data/mod/standard/set/all/rich_html/html_views/guide.rb +1 -1
  321. data/mod/standard/set/all/rich_html/html_views/help.rb +19 -7
  322. data/mod/standard/set/all/rich_html/html_views/info.rb +1 -1
  323. data/mod/standard/set/all/rich_html/menu.rb +50 -2
  324. data/mod/standard/set/all/rich_html/overlay.rb +23 -1
  325. data/mod/standard/set/all/rich_html/title.rb +3 -3
  326. data/mod/standard/set/right/discussion.rb +8 -2
  327. data/mod/standard/set/right/head.rb +4 -0
  328. data/mod/standard/set/right/type_plus_right.rb +4 -0
  329. data/mod/standard/set/self/cardtype.rb +42 -0
  330. data/mod/standard/set/self/sidebar.rb +5 -0
  331. data/mod/standard/set/type/basic.rb +1 -1
  332. data/mod/standard/set/type/cardtype.rb +25 -11
  333. data/mod/standard/set/type/number.rb +1 -1
  334. data/mod/standard/set/type/phrase.rb +1 -1
  335. data/mod/standard/set/type/toggle.rb +9 -1
  336. data/mod/standard/set/type/uri.rb +1 -1
  337. data/mod/standard/spec/set/all/error_spec.rb +1 -1
  338. data/mod/standard/spec/set/type/cardtype_spec.rb +4 -3
  339. data/mod/standard/spec/set/type/number_spec.rb +1 -1
  340. data/mod/standard/spec/set/type/phrase_spec.rb +1 -1
  341. data/mod/standard/spec/set/type/toggle_spec.rb +3 -4
  342. data/mod/standard/spec/set/type/uri_spec.rb +1 -1
  343. data/mod/tinymce_editor/set/self/tiny_mce.rb +7 -0
  344. metadata +116 -52
  345. data/db/migrate_core_cards/20190710090207_homepage_tweaks.rb +0 -12
  346. data/db/migrate_core_cards/data/cards/eagle-description +0 -1
  347. data/mod/account/set/right/token.rb +0 -55
  348. data/mod/account/spec/set/right/token_spec.rb +0 -23
  349. data/mod/bootstrap/set/abstract/bootswatch_theme/thumbnail.haml +0 -10
  350. data/mod/rules/set/rule/table.rb +0 -27
  351. data/mod/rules/set/rule/table_row.rb +0 -63
  352. data/mod/rules/set/type/set/html_views/nest_rules.rb +0 -14
  353. data/mod/rules/set/type/set/html_views/rules_bridge.rb +0 -21
  354. data/mod/rules/set/type/set/html_views/rules_table.haml +0 -11
  355. data/mod/rules/set/type/set/html_views/template/template_editor.haml +0 -6
  356. data/mod/rules/spec/set/rule/table_row_spec.rb +0 -9
  357. data/mod/rules/spec/set/rule/table_spec.rb +0 -15
  358. data/mod/settings/set/right/add_help.rb +0 -1
  359. data/mod/settings/set/self/accountable.rb +0 -3
  360. data/mod/settings/set/self/add_help.rb +0 -2
  361. data/mod/settings/set/self/input.rb +0 -3
  362. data/mod/settings/set/self/options.rb +0 -4
  363. data/mod/settings/set/self/options_label.rb +0 -4
  364. data/mod/settings/spec/set/right/add_help_spec.rb +0 -5
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 835df1fe634ac86b362129fc1848a32b625ac056
4
- data.tar.gz: 4c89dfc65e3c9d4b088189fb087b63b23f9a98e8
3
+ metadata.gz: eeeb9b091c1ba4ba4a19952639c917a7ad212144
4
+ data.tar.gz: d985620049eaca51f1bdbf1e6838ed28993f0643
5
5
  SHA512:
6
- metadata.gz: fe19dedcf5116d8ed7025da14b75dff968afc102e9fed7610e884101ef233493b1b498893c22be9d69cdf4d53e48ca24d35f9f0dad52ba04a03f7c76054e9112
7
- data.tar.gz: f235a00bd3c284f298dabbe9ae2a2ef7c6e955ca0ab96982d7f7afa8f121c9bcd9916814b0b556dcac339f228f57d64e2a03c8070a87e55ee4f7ef4b769f4f7d
6
+ metadata.gz: 878603101a1aa503616f7fea944513d490931abb05530ba18ad344795d2c8e173be4cfa9582cb1e09aab34c11806e11f18ab446e5e23fb86ab16523eb7eb30f0
7
+ data.tar.gz: a13e08715c72c33f5598335986ab667fce7cab449908018676b1c2aa81ad2edf87fec4da8f5ffa25da9924b6c1a75f7a155ce6651d4f77b5fbbd479bec369327
data/VERSION CHANGED
@@ -1 +1 @@
1
- 0.8.3
1
+ 0.9.0
@@ -475,9 +475,8 @@ de:
475
475
  set:
476
476
  right:
477
477
  account:
478
- error_not_allowed: nicht erlaubt für diese Karte
479
- sorry_email_reset: Entschuldigung, %{error_msg}. Please check your email for a new password reset link.
480
- required: erforderlich
478
+ events:
479
+ sorry_email_reset: Entschuldigung, %{error_msg}. Please check your email for a new password reset link.
481
480
  email:
482
481
  error_invalid_address: ungültige Adresse
483
482
  search_email_duplicate: E-Mail-Duplikat? (%{content})
@@ -497,7 +496,7 @@ de:
497
496
  db_card: Database Card Inspect
498
497
  status:
499
498
  deny_not_change_own_account: Du bist nicht berechtigt den Status deines eigenen Accounts zu ändern.
500
- token:
499
+ api_key:
501
500
  private_data: Private data
502
501
  error_token_not_found: kein Token gefunden
503
502
  error_token_expired: Token abgelaufen
@@ -527,13 +526,14 @@ de:
527
526
  error_not_recognized: unbekannt
528
527
  type:
529
528
  signup:
530
- sign_up: Registrieren
531
- invite: Einladen
529
+ views:
530
+ sign_up: Registrieren
531
+ invite: Einladen
532
+ missing_account: "ERROR: Signup-Karte ohne Account"
532
533
  send_invite: Sende Einladung
533
534
  first_last_help: üblicherweise Vor- und Nachname
534
535
  signed_up_on: "%{name} hat sich registriert am %{date}"
535
536
  was_signed_up_on: "%{name} wurde registriert am %{date}"
536
- missing_account: "ERROR: Signup-Karte ohne Account"
537
537
  send: Senden
538
538
  resend: Wieder senden
539
539
  verification: Eine E-Mail zur Verifikation wurde verschickt.
@@ -448,13 +448,14 @@ en:
448
448
  set:
449
449
  type:
450
450
  signup:
451
- sign_up: Sign up
452
- invite: Invite
451
+ views:
452
+ sign_up: Sign up
453
+ invite: Invite
454
+ missing_account: "ERROR: signup card missing account"
453
455
  send_invite: Send Invitation
454
456
  first_last_help: usually first and last name
455
457
  signed_up_on: "%{name} signed up on %{date}"
456
458
  was_signed_up_on: "%{name} was signed up on %{date}"
457
- missing_account: "ERROR: signup card missing account"
458
459
  send: Send
459
460
  resend: Resend
460
461
  verification: A verification email has been sent
@@ -476,9 +477,8 @@ en:
476
477
  setting_up: Lege an
477
478
  right:
478
479
  account:
479
- error_not_allowed: not allowed on this card
480
- sorry_email_reset: Sorry, %{error_msg}. Please check your email for a new password reset link.
481
- required: required
480
+ events:
481
+ sorry_email_reset: Sorry, %{error_msg}. Please check your email for a new password reset link.
482
482
  email:
483
483
  error_invalid_address: must be valid address
484
484
  search_email_duplicate: email duplicate? (%{content})
@@ -498,7 +498,7 @@ en:
498
498
  db_card: Database Card Inspect
499
499
  status:
500
500
  deny_not_change_own_account: change the status of your own account
501
- token:
501
+ api_key:
502
502
  private_data: Private data
503
503
  error_token_not_found: no token found
504
504
  error_token_expired: expired token
@@ -482,13 +482,14 @@ es:
482
482
  set:
483
483
  type:
484
484
  signup:
485
- sign_up: Regístrate
486
- invite: Invitación
485
+ views:
486
+ sign_up: Regístrate
487
+ invite: Invitación
488
+ missing_account: "ERROR: tarjeta de registro cuenta faltante"
487
489
  send_invite: Enviar invitacion
488
490
  first_last_help: usualmente nombre y apellido
489
491
  signed_up_on: "%{name} se registró en %{date}"
490
492
  was_signed_up_on: "%{name} se registró en %{date}"
491
- missing_account: "ERROR: tarjeta de registro cuenta faltante"
492
493
  send: Enviar
493
494
  resend: Reenviar
494
495
  verification: Se envió un correo electrónico de verificación
@@ -510,9 +511,8 @@ es:
510
511
  setting_up: Ponte
511
512
  right:
512
513
  account:
513
- error_not_allowed: no permitido en esta tarjeta
514
- sorry_email_reset: Lo siento, %{error_msg}. Por favor revise su correo electrónico para un nuevo enlace de restablecimiento de contraseña.
515
- required: requerido
514
+ events:
515
+ sorry_email_reset: Lo siento, %{error_msg}. Por favor revise su correo electrónico para un nuevo enlace de restablecimiento de contraseña.
516
516
  email:
517
517
  error_invalid_address: debe ser una dirección válida
518
518
  search_email_duplicate: correo electrónico duplicado? (%{content})
@@ -532,7 +532,7 @@ es:
532
532
  db_card: Inspección de tarjeta de base de datos
533
533
  status:
534
534
  deny_not_change_own_account: cambiar el estado de su propia cuenta
535
- token:
535
+ api_key:
536
536
  private_data: Datos privados
537
537
  error_token_not_found: token no encontrado
538
538
  error_token_expired: token caducado
@@ -48,10 +48,10 @@ class AddRecaptchaKeyAndAdminInfoCards < Card::Migration::Core
48
48
  end
49
49
 
50
50
  def admin_only args
51
- create_or_update args.reverse_merge(type_id: Card::PhraseID)
51
+ create_or_update! args.reverse_merge(type_id: Card::PhraseID)
52
52
  %w(*read *update *delete).each do |perm|
53
- create_or_update name: "#{args[:name]}+*self+#{perm}",
54
- content: "[[Administrator]]"
53
+ create_or_update! name: "#{args[:name]}+*self+#{perm}",
54
+ content: "[[Administrator]]"
55
55
  end
56
56
  end
57
57
  end
@@ -2,7 +2,7 @@
2
2
 
3
3
  class ChangeBootstrapCardTypeToScss < Card::Migration::Core
4
4
  def up
5
- create_or_update name: "*machine cache", codename: "machine_cache"
5
+ create_or_update! name: "*machine cache", codename: "machine_cache"
6
6
  if (card = Card[:bootstrap_cards])
7
7
  card.update! type_id: Card::ScssID
8
8
  end
@@ -2,7 +2,7 @@
2
2
 
3
3
  class ReorganizeScripts < Card::Migration::Core
4
4
  def up
5
- create_or_update name: "*machine cache", codename: "machine_cache"
5
+ create_or_update! name: "*machine cache", codename: "machine_cache"
6
6
  ensure_card name: "script: mods", type_id: Card::PointerID,
7
7
  codename: "script_mods"
8
8
  ensure_card name: "script: editors", type_id: Card::PointerID,
@@ -2,6 +2,6 @@
2
2
 
3
3
  class AddTrashCard < Card::Migration::Core
4
4
  def up
5
- create_or_update name: "*trash", codename: "trash"
5
+ create_or_update! name: "*trash", codename: "trash"
6
6
  end
7
7
  end
@@ -3,8 +3,8 @@
3
3
  class AddJsonType < Card::Migration::Core
4
4
  def up
5
5
  ensure_card "json", codename: "json", type_id: Card::CardtypeID
6
- update_card :ace, type_id: Card::JsonID
7
- update_card :prose_mirror, type_id: Card::JsonID
8
- update_card :tiny_mce, type_id: Card::JsonID
6
+ update_card! :ace, type_id: Card::JsonID
7
+ update_card! :prose_mirror, type_id: Card::JsonID
8
+ update_card! :tiny_mce, type_id: Card::JsonID
9
9
  end
10
10
  end
@@ -2,7 +2,7 @@
2
2
 
3
3
  class HeadRule < Card::Migration::Core
4
4
  def up
5
- update_card :head, type_id: Card::SettingID
5
+ update_card! :head, type_id: Card::SettingID
6
6
  ensure_card [:all, :head],
7
7
  type_id: Card::HTMLID,
8
8
  content: "{{*head|core}}"
@@ -15,10 +15,21 @@ class MigrateLayouts < Card::Migration::Core
15
15
 
16
16
  puts "updating layout '#{card.name}'"
17
17
  card.update! content: body.to_s
18
+ rescue Card::Error => e
19
+ card.update! type_id: Card::HtmlID, content: body.to_s
20
+ puts "failed to complete layout upgrade for '#{card.name}': #{e.message}.\n" \
21
+ "To fix, go to /#{card.name.url_key}?view=edit and change type to Layout. \n" \
22
+ "You will need to make sure the layout content includes a main nest ({{_main}})."
18
23
  end
19
24
 
20
25
  def body_tag card
21
- card.content[/<body[^>]+>.*<\/body>/mi]
26
+ card.content[/<body[^>]*>.*<\/body>/mi] || add_body_tag(card)
27
+ end
28
+
29
+ def add_body_tag card
30
+ content = card.content.gsub('<!DOCTYPE HTML>', '')
31
+ .gsub(/\{\{\*head[^}]*\}\}/i, '').strip
32
+ "<body>\n #{content}\n</body>"
22
33
  end
23
34
 
24
35
  def create_head_rules layout_card
@@ -3,5 +3,8 @@
3
3
  class AddRuleCard < Card::Migration::Core
4
4
  def up
5
5
  ensure_card "*rule", codename: "rule", type_id: Card::SetID
6
+
7
+ # the following re-registers set patterns, now including the rule pattern
8
+ Card::Mod::Loader.reload_mods
6
9
  end
7
10
  end
@@ -2,8 +2,8 @@
2
2
 
3
3
  class UpgradeRecaptchaToV3 < Card::Migration::Core
4
4
  def up
5
- update_card [:recaptcha_settings, :self, :structure],
6
- content: <<-STRING
5
+ update_card! [:recaptcha_settings, :self, :structure],
6
+ content: <<-STRING
7
7
  {{+site key}}
8
8
  {{+secret key}}
9
9
  {{+minimum score}}
@@ -14,10 +14,9 @@ class UpgradeRecaptchaToV3 < Card::Migration::Core
14
14
  codename = "recaptcha_#{old_name}_key".to_sym
15
15
  next unless Card::Codename[codename]
16
16
 
17
- update_card codename,
18
- name: "#{Card[:recaptcha_settings].name}+#{new_name} key",
19
- codename: "recaptcha_#{new_name}_key"
20
-
17
+ update_card! codename,
18
+ name: "#{Card[:recaptcha_settings].name}+#{new_name} key",
19
+ codename: "recaptcha_#{new_name}_key"
21
20
  end
22
21
 
23
22
  ensure_card [Card[:recaptcha_settings].name, "minimum score"],
@@ -4,9 +4,9 @@ class ReorganizeScripts2 < Card::Migration::Core
4
4
  def up
5
5
  delete_code_card :script_card_menu
6
6
  if Card::Codename[:script_slot]
7
- update_card :script_slot, name: "script: decko",
8
- codename: "script_decko",
9
- update_referers: true
7
+ update_card! :script_slot, name: "script: decko",
8
+ codename: "script_decko",
9
+ update_referers: true
10
10
  end
11
11
  if (card = Card[:all, :script])
12
12
  card.drop_item "script: card menu"
@@ -3,16 +3,15 @@
3
3
  class AddSharkAndHelpDeskRole < Card::Migration::Core
4
4
  def up
5
5
  # delete_code_card :eagle
6
- # update :anyone_signed_in, name: "Eagle", update_referers: true
7
6
  ensure_role "Shark", codename: "shark"
8
7
  ensure_role "Help Desk", codename: "help_desk"
9
8
 
10
9
  ensure_card "*account settings",
11
10
  codename: "account_settings", type_id: Card::BasicID
12
11
 
13
- update_card "Decker Menu", name: "Shark Menu", update_referers: true
14
- update_card :ace, name: "*ace"
15
- update_card "*google_analytics_key", name: "*google analytics key"
12
+ update_card! "Decker Menu", name: "Shark Menu", update_referers: true
13
+ update_card! :ace, name: "*ace"
14
+ update_card! "*google_analytics_key", name: "*google analytics key"
16
15
 
17
16
  remove_deprecated_cards
18
17
  delete_right_read_permissions
@@ -25,7 +24,7 @@ class AddSharkAndHelpDeskRole < Card::Migration::Core
25
24
  administrator+dashboard administrator+description
26
25
  shark+dashboard shark+description
27
26
  help_desk+dashboard help_desk+description
28
- anyone_signed_in+dashboard eagle+description
27
+ anyone_signed_in+dashboard
29
28
  *recaptcha_settings+*self+*structure
30
29
  *account_settings+*right+*structure
31
30
  *getting_started+shark
@@ -3,6 +3,6 @@
3
3
  class AddDropdownDivider < Card::Migration::Core
4
4
  def up
5
5
  ensure_code_card "*dropdown divider", type_id: Card::HtmlID
6
- merge_pristine_cards %w[*main_menu *getting_started+link]
6
+ merge_pristine_cards %w[*main_menu *getting_started_link]
7
7
  end
8
8
  end
@@ -0,0 +1,17 @@
1
+ # -*- encoding : utf-8 -*-
2
+
3
+ class HomepageTweaks < Card::Migration::Core
4
+ def up
5
+ merge_cards ["*getting started", "*main menu", "*getting started links"]
6
+ update_card! :wagn_bot, name: "Decko Bot", update_referers: true
7
+ delete_code_card :customized_skin
8
+ delete_code_card :bootswatch_theme
9
+ unless Card.fetch_name(:basic) == "RichText"
10
+ update_card! :basic, name: "RichText", update_referers: true
11
+ end
12
+ unless Card.fetch_name(:json) == "JSON"
13
+ update_card! :json, name: "JSON", update_referers: true
14
+ end
15
+ delete_card "*getting started+links"
16
+ end
17
+ end
@@ -0,0 +1,7 @@
1
+ # -*- encoding : utf-8 -*-
2
+
3
+ class UpdateCardtypeTypeStructure < Card::Migration::Core
4
+ def up
5
+ merge_cards %w[cardtype+*type+*structure Administrator+dashboard Shark+dashboard]
6
+ end
7
+ end
@@ -0,0 +1,38 @@
1
+ # -*- encoding : utf-8 -*-
2
+
3
+ class MoveHelpTextToCode < Card::Migration::Core
4
+ def up
5
+ update_card! "*sidebar", codename: "sidebar"
6
+ Card::Cache.reset_all
7
+
8
+ # avoid that "list" as input option gets the description of the cardtype "list"
9
+ ensure_card [:input, :right, :options_label], "options description"
10
+
11
+
12
+ remove_setting_help_rules
13
+ remove_search_help_rules
14
+ remove_self_help_rules :favicon, :tiny_mce, :favicon, :datepicker, "*debugger",
15
+ :prose_mirror, :sidebar
16
+ end
17
+
18
+ def remove_search_help_rules
19
+ %i[created edited children includes refers_to links_to included_by linked_to_by
20
+ referred_to_by mates editors follow].each do |trait|
21
+ delete_card [trait, :right, :help]
22
+ end
23
+ end
24
+
25
+ def remove_setting_help_rules
26
+ %i[script input read update create delete accountable add_help autoname captcha create
27
+ default structure comment follow_fields options thanks layout options_label help
28
+ head table_of_contents style on_create on_update on_delete].each do |trait|
29
+ delete_card [trait, :right, :help]
30
+ end
31
+ end
32
+
33
+ def remove_self_help_rules *anchors
34
+ anchors.each do |a|
35
+ delete_card [a, :self, :help]
36
+ end
37
+ end
38
+ end
@@ -0,0 +1,21 @@
1
+ # -*- encoding : utf-8 -*-
2
+
3
+ class CleanupForDecko10 < Card::Migration::Core
4
+ def up
5
+ ensure_card "Cards with account", codename: "cards_with_account",
6
+ content: '{"right_plus": "*account"}'
7
+
8
+ %i[delete create update comment].each do |perm|
9
+ delete_card [perm, :right, :options]
10
+ end
11
+ delete_card "*missing link"
12
+ # delete_card "tags"
13
+ delete_card "*tagged"
14
+ merge_cards "*account"
15
+ update_card! "*included by",
16
+ name: "*nested by", codename: "nested_by", update_referers: true
17
+ update_card! "*includes",
18
+ name: "*nests", codename: "nests", update_referers: true
19
+ ensure_card "*members", codename: "members"
20
+ end
21
+ end
@@ -0,0 +1,7 @@
1
+ # -*- encoding : utf-8 -*-
2
+
3
+ class AddMoreGuides < Card::Migration::Core
4
+ def up
5
+ merge_cards %w[Cardtype+*type+*guide *structure+*right+*guide]
6
+ end
7
+ end
@@ -0,0 +1,16 @@
1
+ # -*- encoding : utf-8 -*-
2
+
3
+ class CardtypeGrouping < Card::Migration::Core
4
+ CONTENT =
5
+ <<-EOT
6
+ {{+description|content}}
7
+
8
+ {{_|add_button}} {{_|configure_button}}
9
+
10
+ {{_|grouped_list}}
11
+ EOT
12
+
13
+ def up
14
+ ensure_card [:cardtype, :self, :structure], content: CONTENT
15
+ end
16
+ end
@@ -0,0 +1,14 @@
1
+ # -*- encoding : utf-8 -*-
2
+
3
+ class RemoveAddHelp < Card::Migration::Core
4
+ def up
5
+ Card.search(right: { codename: "add_help" },
6
+ left: { type_id: Card::SetID }).each do |card|
7
+ next if Card.exists? [card.left, :help]
8
+
9
+ ensure_card [card.left, :help], content: card.content
10
+ end
11
+ delete_code_card :add_help
12
+ Card::Cache.reset_all
13
+ end
14
+ end
@@ -0,0 +1,17 @@
1
+ # -*- encoding : utf-8 -*-
2
+
3
+ class SettingSettingsAside < Card::Migration::Core
4
+ def up
5
+ ensure_card %i[account right create], "Administrator"
6
+ ensure_card %i[signup account type_plus_right create], "_left"
7
+ ensure_card %i[user account type_plus_right create], "_left"
8
+
9
+ %i[email password status token salt].each do |field|
10
+ # now handled by inheritance
11
+ delete_card [field, :right, :create]
12
+ end
13
+
14
+ delete_code_card :accountable
15
+ delete_code_card :comment
16
+ end
17
+ end