panda_cms 0.5.10 → 0.6.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (81) hide show
  1. checksums.yaml +4 -4
  2. data/README.md +3 -1
  3. data/Rakefile +0 -1
  4. data/app/assets/builds/panda_cms.css +2415 -1
  5. data/app/assets/config/panda_cms_manifest.js +2 -0
  6. data/app/assets/stylesheets/panda_cms/application.tailwind.css +3 -27
  7. data/app/builders/panda_cms/form_builder.rb +1 -1
  8. data/app/components/panda_cms/admin/button_component.rb +6 -3
  9. data/app/components/panda_cms/admin/flash_message_component.rb +1 -1
  10. data/app/components/panda_cms/admin/tag_component.rb +1 -1
  11. data/app/components/panda_cms/code_component.rb +60 -0
  12. data/app/components/panda_cms/page_menu_component.html.erb +6 -4
  13. data/app/components/panda_cms/page_menu_component.rb +21 -12
  14. data/app/components/panda_cms/rich_text_component.html.erb +6 -38
  15. data/app/components/panda_cms/rich_text_component.rb +24 -7
  16. data/app/components/panda_cms/text_component.rb +25 -22
  17. data/app/controllers/panda_cms/admin/dashboard_controller.rb +14 -6
  18. data/app/controllers/panda_cms/admin/menus_controller.rb +1 -54
  19. data/app/controllers/panda_cms/admin/pages_controller.rb +2 -1
  20. data/app/controllers/panda_cms/admin/sessions_controller.rb +13 -6
  21. data/app/controllers/panda_cms/application_controller.rb +1 -1
  22. data/app/controllers/panda_cms/pages_controller.rb +1 -1
  23. data/app/controllers/panda_cms/posts_controller.rb +1 -1
  24. data/app/helpers/panda_cms/application_helper.rb +2 -2
  25. data/app/javascript/panda_cms/@hotwired--stimulus.js +4 -0
  26. data/app/javascript/panda_cms/@hotwired--turbo.js +160 -0
  27. data/app/javascript/panda_cms/@rails--actioncable--src.js +4 -0
  28. data/app/javascript/panda_cms/application_panda_cms.js +4 -0
  29. data/app/javascript/panda_cms/controllers/dashboard_controller.js +7 -0
  30. data/app/javascript/panda_cms/controllers/index.js +42 -0
  31. data/app/javascript/panda_cms/controllers/slug_controller.js +48 -0
  32. data/app/javascript/panda_cms/panda_cms_editable.js +248 -0
  33. data/app/javascript/panda_cms/tailwindcss-stimulus-components.js +4 -0
  34. data/app/lib/panda_cms/demo_site_generator.rb +1 -1
  35. data/app/lib/panda_cms/slug.rb +1 -1
  36. data/app/models/panda_cms/block.rb +2 -2
  37. data/app/models/panda_cms/page.rb +9 -3
  38. data/app/models/panda_cms/post.rb +1 -1
  39. data/app/models/panda_cms/template.rb +4 -2
  40. data/app/models/panda_cms/user.rb +9 -1
  41. data/app/views/panda_cms/admin/dashboard/show.html.erb +11 -9
  42. data/app/views/panda_cms/admin/forms/new.html.erb +6 -7
  43. data/app/views/panda_cms/admin/menus/index.html.erb +0 -2
  44. data/app/views/panda_cms/admin/pages/edit.html.erb +18 -16
  45. data/app/views/panda_cms/admin/pages/new.html.erb +6 -7
  46. data/app/views/panda_cms/admin/posts/_form.html.erb +4 -4
  47. data/app/views/panda_cms/admin/sessions/new.html.erb +1 -2
  48. data/app/views/panda_cms/admin/shared/_sidebar.html.erb +12 -16
  49. data/app/views/panda_cms/shared/_header.html.erb +14 -14
  50. data/app/views/panda_cms/shared/_importmap.html.erb +22 -0
  51. data/config/importmap.rb +11 -10
  52. data/config/initializers/panda_cms.rb +57 -55
  53. data/config/routes.rb +9 -9
  54. data/config/tailwind.config.js +1 -0
  55. data/db/migrate/20240205223709_create_panda_cms_pages.rb +6 -4
  56. data/lib/generators/panda_cms/install_generator.rb +3 -0
  57. data/lib/panda_cms/engine.rb +27 -22
  58. data/lib/panda_cms/version.rb +1 -1
  59. data/lib/panda_cms.rb +58 -10
  60. data/lib/tasks/panda_cms.rake +41 -57
  61. data/public/panda-cms-assets/rich_text_editor.css +568 -0
  62. metadata +216 -278
  63. data/app/javascript/base.js +0 -37
  64. data/app/javascript/controllers/menu_controller.js +0 -19
  65. data/app/javascript/controllers/text_controller.js +0 -78
  66. data/app/javascript/controllers/text_field_update_controller.js +0 -51
  67. data/app/javascript/vendor/stimulus-components-rails-nested-form.js +0 -2
  68. data/app/javascript/vendor/tailwindcss-stimulus-components.js +0 -2
  69. data/app/views/panda_cms/admin/menus/_form.html.erb +0 -21
  70. data/app/views/panda_cms/admin/menus/_menu_item_fields.html.erb +0 -7
  71. data/app/views/panda_cms/admin/menus/edit.html.erb +0 -58
  72. data/app/views/panda_cms/admin/menus/new.html.erb +0 -5
  73. data/public/panda-cms-assets/javascripts/base.js +0 -37
  74. data/public/panda-cms-assets/javascripts/controllers/menu_controller.js +0 -19
  75. data/public/panda-cms-assets/javascripts/controllers/text_field_update_controller.js +0 -23
  76. data/public/panda-cms-assets/javascripts/embed/editable.js +0 -358
  77. data/public/panda-cms-assets/javascripts/embed/rich_text.css +0 -1294
  78. data/public/panda-cms-assets/javascripts/vendor/stimulus-components-rails-nested-form.js +0 -2
  79. data/public/panda-cms-assets/javascripts/vendor/stimulus-loading.js +0 -113
  80. data/public/panda-cms-assets/javascripts/vendor/tailwindcss-stimulus-components.js +0 -2
  81. /data/db/migrate/{20240804110225_add_status_to_panda_cms_pages.rb → 20240315125411_add_status_to_panda_cms_pages.rb} +0 -0
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 4506c48d91d12c4ee82fefdfb7681146981501ea295990fb5426ef017b4cdb85
4
- data.tar.gz: dc535dfb2b5c440ea328ff443541b143b72eb1835542f3fd1688106629f142dc
3
+ metadata.gz: d703e97407899867cc2ba819715b0c042aa2bfeb52b550b975d692c755da6b29
4
+ data.tar.gz: 8cd9e111ac125f721a800b49e9447972b3c4e429e80441f5c5f7b27d713cfd66
5
5
  SHA512:
6
- metadata.gz: a58f9c56ad932fc4ca2a85dbd629b0487ae03d2df75c14ab483fd096aefe7eaca9bbc4e033366df43612329b93fc3f29ffedcdfd6a0f262ee7445ccd81298c09
7
- data.tar.gz: f510e836ecf49d6ec9600805e4ee91e81d81e5dd13eabbd29c286714617b6d4ce86e8ec962ce0d9b36bc0db431578f34b7ab4be9de3460f1b69e7042a2eef59d
6
+ metadata.gz: 357cd56e8fcb1ba6f0266c820f516a47b168812843a5b024cb03f65c131a852ae0ff985782f2a048cce6b4170998ba0644b178c9772af41c93e3802993c6de72
7
+ data.tar.gz: 72c27644d6b690b93579cf112d5e9eb7b018d9bd02a46ca0bd994a868b71c1f7ed1fae0612821b3d533799d7d3cf67167ec4dd913713b2977bed3578ca8e02e4
data/README.md CHANGED
@@ -24,7 +24,9 @@ To create a new Rails app, run the command below, replacing `demo` with the name
24
24
  rails new demo $(curl -fsSL https://raw.githubusercontent.com/pandacms/generator/main/.railsrc) -m https://raw.githubusercontent.com/pandacms/generator/main/template.rb
25
25
  ```
26
26
 
27
- `cd` into your directory (e.g. `demo`) and run `bin/dev`. You'll see a basic website has automatically been created for you at http://localhost:3000/
27
+ `cd` into your directory (e.g. `demo`), and you'll see `rails db:migrate` and `rails db:seed` have already been run for you.
28
+
29
+ Then run `bin/dev`. You'll see a basic website has automatically been created for you at http://localhost:3000/
28
30
 
29
31
  The easiest way for you to get started is to visit http://localhost:3000/admin and login with your GitHub credentials. As the first user, you'll automatically have an administrator account created.
30
32
 
data/Rakefile CHANGED
@@ -3,6 +3,5 @@ require "bundler/setup"
3
3
  APP_RAKEFILE = File.expand_path("spec/dummy/Rakefile", __dir__)
4
4
  load "rails/tasks/engine.rake"
5
5
  load "rails/tasks/statistics.rake"
6
- load APP_RAKEFILE if File.exist?(APP_RAKEFILE)
7
6
 
8
7
  require "bundler/gem_tasks"