elabs 2.0.0.pre
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +7 -0
- data/.eslintrc.yml +26 -0
- data/.gitignore +49 -0
- data/.gitlab-ci.yml +93 -0
- data/.haml-lint.yml +4 -0
- data/.node-version +1 -0
- data/.rspec +1 -0
- data/.rubocop.yml +59 -0
- data/.ruby-version +1 -0
- data/.simplecov +5 -0
- data/.stylelintrc.yml +218 -0
- data/CHANGELOG.md +273 -0
- data/CODE_OF_CONDUCT.md +78 -0
- data/Gemfile +75 -0
- data/Gemfile.lock +376 -0
- data/LICENSE +21 -0
- data/LICENSES.md +6 -0
- data/README.md +41 -0
- data/ROADMAP.md +61 -0
- data/Rakefile +32 -0
- data/app/assets/config/elabs_manifest.js +3 -0
- data/app/assets/images/elabs/preview_placeholder.png +0 -0
- data/app/assets/images/elabs/preview_placeholder_nsfw.png +0 -0
- data/app/assets/javascripts/elabs/application.js +27 -0
- data/app/assets/javascripts/elabs/helpers-codemirror.js +29 -0
- data/app/assets/javascripts/elabs/helpers-markdown.js +42 -0
- data/app/assets/javascripts/elabs/helpers.js +17 -0
- data/app/assets/javascripts/elabs/modals.js +19 -0
- data/app/assets/javascripts/elabs/tabs.js +32 -0
- data/app/assets/stylesheets/elabs/_colors.scss +345 -0
- data/app/assets/stylesheets/elabs/_icons.scss +9 -0
- data/app/assets/stylesheets/elabs/_variables.scss +13 -0
- data/app/assets/stylesheets/elabs/app/_acts.scss +58 -0
- data/app/assets/stylesheets/elabs/app/_alerts.scss +3 -0
- data/app/assets/stylesheets/elabs/app/_buttons.scss +21 -0
- data/app/assets/stylesheets/elabs/app/_comments.scss +1 -0
- data/app/assets/stylesheets/elabs/app/_content.scss +10 -0
- data/app/assets/stylesheets/elabs/app/_content_uploads.scss +39 -0
- data/app/assets/stylesheets/elabs/app/_empty.scss +19 -0
- data/app/assets/stylesheets/elabs/app/_errors.scss +9 -0
- data/app/assets/stylesheets/elabs/app/_filter_links.scss +27 -0
- data/app/assets/stylesheets/elabs/app/_forms.scss +69 -0
- data/app/assets/stylesheets/elabs/app/_helpers.scss +3 -0
- data/app/assets/stylesheets/elabs/app/_languages.scss +6 -0
- data/app/assets/stylesheets/elabs/app/_layout.scss +194 -0
- data/app/assets/stylesheets/elabs/app/_licenses.scss +6 -0
- data/app/assets/stylesheets/elabs/app/_link-to-top.scss +8 -0
- data/app/assets/stylesheets/elabs/app/_medias.scss +12 -0
- data/app/assets/stylesheets/elabs/app/_modals.scss +53 -0
- data/app/assets/stylesheets/elabs/app/_nsfw.scss +5 -0
- data/app/assets/stylesheets/elabs/app/_pagination.scss +16 -0
- data/app/assets/stylesheets/elabs/app/_tabs.scss +54 -0
- data/app/assets/stylesheets/elabs/app/_tags.scss +6 -0
- data/app/assets/stylesheets/elabs/app/_toolbars.scss +3 -0
- data/app/assets/stylesheets/elabs/app/_users.scss +6 -0
- data/app/assets/stylesheets/elabs/app/admin-members/_forms.scss +6 -0
- data/app/assets/stylesheets/elabs/app/admin-members/_indexes.scss +70 -0
- data/app/assets/stylesheets/elabs/app/admin-members/_layout.scss +17 -0
- data/app/assets/stylesheets/elabs/app/areas/_devise.scss +31 -0
- data/app/assets/stylesheets/elabs/app/components/_cards.scss +16 -0
- data/app/assets/stylesheets/elabs/app/components/_container.scss +4 -0
- data/app/assets/stylesheets/elabs/app/mixins/_classifier-card.scss +16 -0
- data/app/assets/stylesheets/elabs/app/mixins/_content-card.scss +58 -0
- data/app/assets/stylesheets/elabs/app/mixins/_content-full.scss +39 -0
- data/app/assets/stylesheets/elabs/app/mixins/_icon.scss +9 -0
- data/app/assets/stylesheets/elabs/application.css +14 -0
- data/app/assets/stylesheets/elabs/lib/_codemirror.scss +26 -0
- data/app/assets/stylesheets/elabs/lib/fontawesome/_fontawesome.scss +38 -0
- data/app/assets/stylesheets/elabs/lib/fontawesome/_fonts.scss +42 -0
- data/app/assets/stylesheets/elabs/lib/fontawesome/_icons.scss +1118 -0
- data/app/assets/stylesheets/elabs/lib/knacss/_knacss-variables.scss +230 -0
- data/app/assets/stylesheets/elabs/lib/knacss/_knacss.scss +59 -0
- data/app/assets/stylesheets/elabs/style.scss +72 -0
- data/app/controllers/elabs/acts_controller.rb +12 -0
- data/app/controllers/elabs/admin/admin_application_controller.rb +19 -0
- data/app/controllers/elabs/admin/admin_content_application_controller.rb +66 -0
- data/app/controllers/elabs/admin/albums_controller.rb +10 -0
- data/app/controllers/elabs/admin/articles_controller.rb +10 -0
- data/app/controllers/elabs/admin/languages_controller.rb +77 -0
- data/app/controllers/elabs/admin/licenses_controller.rb +77 -0
- data/app/controllers/elabs/admin/notes_controller.rb +10 -0
- data/app/controllers/elabs/admin/projects_controller.rb +10 -0
- data/app/controllers/elabs/admin/reports_controller.rb +34 -0
- data/app/controllers/elabs/admin/tags_controller.rb +56 -0
- data/app/controllers/elabs/admin/uploads_controller.rb +10 -0
- data/app/controllers/elabs/admin/users_controller.rb +43 -0
- data/app/controllers/elabs/albums_controller.rb +26 -0
- data/app/controllers/elabs/articles_controller.rb +25 -0
- data/app/controllers/elabs/auth/callbacks_controller.rb +38 -0
- data/app/controllers/elabs/auth/confirmations_controller.rb +43 -0
- data/app/controllers/elabs/auth/passwords_controller.rb +47 -0
- data/app/controllers/elabs/auth/registrations_controller.rb +70 -0
- data/app/controllers/elabs/auth/sessions_controller.rb +36 -0
- data/app/controllers/elabs/auth/unlocks_controller.rb +38 -0
- data/app/controllers/elabs/concerns/elabs_controller.rb +18 -0
- data/app/controllers/elabs/concerns/localizable.rb +11 -0
- data/app/controllers/elabs/concerns/reportable.rb +17 -0
- data/app/controllers/elabs/content_application_controller.rb +45 -0
- data/app/controllers/elabs/elabs_application_controller.rb +95 -0
- data/app/controllers/elabs/languages_controller.rb +36 -0
- data/app/controllers/elabs/licenses_controller.rb +31 -0
- data/app/controllers/elabs/member/albums_controller.rb +11 -0
- data/app/controllers/elabs/member/articles_controller.rb +11 -0
- data/app/controllers/elabs/member/member_application_controller.rb +12 -0
- data/app/controllers/elabs/member/member_content_application_controller.rb +128 -0
- data/app/controllers/elabs/member/notes_controller.rb +11 -0
- data/app/controllers/elabs/member/preferences_controller.rb +36 -0
- data/app/controllers/elabs/member/projects_controller.rb +11 -0
- data/app/controllers/elabs/member/uploads_controller.rb +11 -0
- data/app/controllers/elabs/member/users_controller.rb +28 -0
- data/app/controllers/elabs/notes_controller.rb +25 -0
- data/app/controllers/elabs/projects_controller.rb +30 -0
- data/app/controllers/elabs/reports_controller.rb +36 -0
- data/app/controllers/elabs/tags_controller.rb +36 -0
- data/app/controllers/elabs/uploads_controller.rb +24 -0
- data/app/controllers/elabs/users_controller.rb +36 -0
- data/app/helpers/elabs/acts_helper.rb +22 -0
- data/app/helpers/elabs/admin_content_helper.rb +54 -0
- data/app/helpers/elabs/application_helper.rb +54 -0
- data/app/helpers/elabs/content_filters_helper.rb +97 -0
- data/app/helpers/elabs/content_renderer_helper.rb +13 -0
- data/app/helpers/elabs/member_content_helper.rb +47 -0
- data/app/helpers/elabs/thumbnails_helper.rb +28 -0
- data/app/helpers/elabs/time_helper.rb +19 -0
- data/app/helpers/elabs/uploads_helper.rb +19 -0
- data/app/jobs/elabs/application_job.rb +4 -0
- data/app/mailers/elabs/application_mailer.rb +6 -0
- data/app/models/elabs/act.rb +7 -0
- data/app/models/elabs/album.rb +24 -0
- data/app/models/elabs/albums_tag.rb +21 -0
- data/app/models/elabs/albums_upload.rb +21 -0
- data/app/models/elabs/application_content_record.rb +10 -0
- data/app/models/elabs/application_record.rb +5 -0
- data/app/models/elabs/article.rb +23 -0
- data/app/models/elabs/articles_tag.rb +21 -0
- data/app/models/elabs/comment.rb +12 -0
- data/app/models/elabs/concerns/actable_entity.rb +52 -0
- data/app/models/elabs/concerns/content_entity.rb +70 -0
- data/app/models/elabs/concerns/countable_entity.rb +81 -0
- data/app/models/elabs/concerns/taggable.rb +33 -0
- data/app/models/elabs/language.rb +17 -0
- data/app/models/elabs/license.rb +15 -0
- data/app/models/elabs/note.rb +21 -0
- data/app/models/elabs/notes_tag.rb +21 -0
- data/app/models/elabs/preference.rb +9 -0
- data/app/models/elabs/project.rb +25 -0
- data/app/models/elabs/projects_album.rb +21 -0
- data/app/models/elabs/projects_article.rb +21 -0
- data/app/models/elabs/projects_note.rb +21 -0
- data/app/models/elabs/projects_tag.rb +21 -0
- data/app/models/elabs/projects_upload.rb +21 -0
- data/app/models/elabs/report.rb +11 -0
- data/app/models/elabs/tag.rb +18 -0
- data/app/models/elabs/upload.rb +28 -0
- data/app/models/elabs/uploads_tag.rb +21 -0
- data/app/models/elabs/user.rb +30 -0
- data/app/validators/elabs/associated_author_validator.rb +11 -0
- data/app/views/elabs/acts/_act.json.jbuilder +2 -0
- data/app/views/elabs/acts/_filters.html.haml +3 -0
- data/app/views/elabs/acts/index.html.haml +27 -0
- data/app/views/elabs/acts/index.json.jbuilder +1 -0
- data/app/views/elabs/admin/albums/_album.json.jbuilder +2 -0
- data/app/views/elabs/admin/albums/index.html.haml +43 -0
- data/app/views/elabs/admin/albums/index.json.jbuilder +1 -0
- data/app/views/elabs/admin/articles/_article.json.jbuilder +2 -0
- data/app/views/elabs/admin/articles/index.html.haml +41 -0
- data/app/views/elabs/admin/articles/index.json.jbuilder +1 -0
- data/app/views/elabs/admin/languages/_form.html.haml +18 -0
- data/app/views/elabs/admin/languages/_language.json.jbuilder +2 -0
- data/app/views/elabs/admin/languages/edit.html.haml +6 -0
- data/app/views/elabs/admin/languages/index.html.haml +34 -0
- data/app/views/elabs/admin/languages/index.json.jbuilder +1 -0
- data/app/views/elabs/admin/languages/new.html.haml +3 -0
- data/app/views/elabs/admin/licenses/_form.html.haml +25 -0
- data/app/views/elabs/admin/licenses/_license.json.jbuilder +2 -0
- data/app/views/elabs/admin/licenses/edit.html.haml +6 -0
- data/app/views/elabs/admin/licenses/index.html.haml +42 -0
- data/app/views/elabs/admin/licenses/index.json.jbuilder +1 -0
- data/app/views/elabs/admin/licenses/new.html.haml +3 -0
- data/app/views/elabs/admin/notes/_note.json.jbuilder +2 -0
- data/app/views/elabs/admin/notes/index.html.haml +40 -0
- data/app/views/elabs/admin/notes/index.json.jbuilder +1 -0
- data/app/views/elabs/admin/projects/_project.json.jbuilder +2 -0
- data/app/views/elabs/admin/projects/index.html.haml +45 -0
- data/app/views/elabs/admin/projects/index.json.jbuilder +1 -0
- data/app/views/elabs/admin/reports/index.html.haml +27 -0
- data/app/views/elabs/admin/reports/index.json.jbuilder +1 -0
- data/app/views/elabs/admin/tags/_form.html.haml +17 -0
- data/app/views/elabs/admin/tags/_tag.json.jbuilder +2 -0
- data/app/views/elabs/admin/tags/edit.html.haml +6 -0
- data/app/views/elabs/admin/tags/index.html.haml +27 -0
- data/app/views/elabs/admin/tags/index.json.jbuilder +1 -0
- data/app/views/elabs/admin/uploads/_upload.json.jbuilder +2 -0
- data/app/views/elabs/admin/uploads/index.html.haml +45 -0
- data/app/views/elabs/admin/uploads/index.json.jbuilder +1 -0
- data/app/views/elabs/admin/users/_admin_user.json.jbuilder +2 -0
- data/app/views/elabs/admin/users/index.html.haml +33 -0
- data/app/views/elabs/admin/users/index.json.jbuilder +1 -0
- data/app/views/elabs/admin/users/show.html.haml +26 -0
- data/app/views/elabs/admin/users/show.json.jbuilder +1 -0
- data/app/views/elabs/albums/_album.html.haml +38 -0
- data/app/views/elabs/albums/_album.json.jbuilder +2 -0
- data/app/views/elabs/albums/_filters.html.haml +8 -0
- data/app/views/elabs/albums/index.html.haml +9 -0
- data/app/views/elabs/albums/index.json.jbuilder +1 -0
- data/app/views/elabs/albums/show.html.haml +60 -0
- data/app/views/elabs/albums/show.json.jbuilder +1 -0
- data/app/views/elabs/articles/_article.html.haml +30 -0
- data/app/views/elabs/articles/_article.json.jbuilder +2 -0
- data/app/views/elabs/articles/_filters.html.haml +8 -0
- data/app/views/elabs/articles/index.html.haml +9 -0
- data/app/views/elabs/articles/index.json.jbuilder +1 -0
- data/app/views/elabs/articles/show.html.haml +45 -0
- data/app/views/elabs/articles/show.json.jbuilder +1 -0
- data/app/views/elabs/auth/confirmations/new.html.haml +26 -0
- data/app/views/elabs/auth/passwords/edit.html.haml +31 -0
- data/app/views/elabs/auth/passwords/new.html.haml +23 -0
- data/app/views/elabs/auth/registrations/edit.html.haml +48 -0
- data/app/views/elabs/auth/registrations/new.html.haml +34 -0
- data/app/views/elabs/auth/sessions/_new.html.haml +15 -0
- data/app/views/elabs/auth/sessions/new.html.haml +8 -0
- data/app/views/elabs/auth/shared/_links.html.haml +16 -0
- data/app/views/elabs/auth/unlocks/new.html.haml +23 -0
- data/app/views/elabs/comments/_comment.json.jbuilder +2 -0
- data/app/views/elabs/comments/_comments.html.haml +21 -0
- data/app/views/elabs/comments/_form.html.haml +31 -0
- data/app/views/elabs/languages/_associations.html.haml +51 -0
- data/app/views/elabs/languages/_filters.html.haml +6 -0
- data/app/views/elabs/languages/_language.json.jbuilder +2 -0
- data/app/views/elabs/languages/index.html.haml +33 -0
- data/app/views/elabs/languages/index.json.jbuilder +1 -0
- data/app/views/elabs/languages/show.html.haml +38 -0
- data/app/views/elabs/languages/show.json.jbuilder +1 -0
- data/app/views/elabs/layouts/_empty.html.haml +3 -0
- data/app/views/elabs/layouts/_footer.html.haml +6 -0
- data/app/views/elabs/layouts/_hidden_entry.html.haml +6 -0
- data/app/views/elabs/layouts/_hidden_entry_full.html.haml +6 -0
- data/app/views/elabs/layouts/_language_menu.html.haml +2 -0
- data/app/views/elabs/layouts/_menu.html.haml +72 -0
- data/app/views/elabs/layouts/admin_application.html.haml +21 -0
- data/app/views/elabs/layouts/application.html.haml +37 -0
- data/app/views/elabs/layouts/lists/_albums.html.haml +10 -0
- data/app/views/elabs/layouts/lists/_projects.html.haml +10 -0
- data/app/views/elabs/layouts/lists/_tags.html.haml +9 -0
- data/app/views/elabs/layouts/mailer.html.haml +8 -0
- data/app/views/elabs/layouts/mailer.text.haml +1 -0
- data/app/views/elabs/layouts/member_application.html.haml +21 -0
- data/app/views/elabs/licenses/_associations.html.haml +51 -0
- data/app/views/elabs/licenses/_filters.html.haml +3 -0
- data/app/views/elabs/licenses/_license.json.jbuilder +2 -0
- data/app/views/elabs/licenses/index.html.haml +27 -0
- data/app/views/elabs/licenses/index.json.jbuilder +1 -0
- data/app/views/elabs/licenses/show.html.haml +44 -0
- data/app/views/elabs/licenses/show.json.jbuilder +1 -0
- data/app/views/elabs/member/albums/_album.json.jbuilder +2 -0
- data/app/views/elabs/member/albums/_form.html.haml +64 -0
- data/app/views/elabs/member/albums/edit.html.haml +6 -0
- data/app/views/elabs/member/albums/index.html.haml +49 -0
- data/app/views/elabs/member/albums/index.json.jbuilder +1 -0
- data/app/views/elabs/member/albums/new.html.haml +3 -0
- data/app/views/elabs/member/articles/_article.json.jbuilder +2 -0
- data/app/views/elabs/member/articles/_form.html.haml +70 -0
- data/app/views/elabs/member/articles/edit.html.haml +6 -0
- data/app/views/elabs/member/articles/index.html.haml +47 -0
- data/app/views/elabs/member/articles/index.json.jbuilder +1 -0
- data/app/views/elabs/member/articles/new.html.haml +3 -0
- data/app/views/elabs/member/layouts/_empty.html.haml +4 -0
- data/app/views/elabs/member/layouts/_markdown-preview.html.haml +8 -0
- data/app/views/elabs/member/notes/_form.html.haml +54 -0
- data/app/views/elabs/member/notes/_note.json.jbuilder +2 -0
- data/app/views/elabs/member/notes/edit.html.haml +6 -0
- data/app/views/elabs/member/notes/index.html.haml +47 -0
- data/app/views/elabs/member/notes/index.json.jbuilder +1 -0
- data/app/views/elabs/member/notes/new.html.haml +3 -0
- data/app/views/elabs/member/preferences/_form.html.haml +20 -0
- data/app/views/elabs/member/preferences/edit.html.haml +3 -0
- data/app/views/elabs/member/projects/_form.html.haml +71 -0
- data/app/views/elabs/member/projects/_project.json.jbuilder +2 -0
- data/app/views/elabs/member/projects/edit.html.haml +6 -0
- data/app/views/elabs/member/projects/index.html.haml +53 -0
- data/app/views/elabs/member/projects/index.json.jbuilder +1 -0
- data/app/views/elabs/member/projects/new.html.haml +3 -0
- data/app/views/elabs/member/uploads/_form.html.haml +67 -0
- data/app/views/elabs/member/uploads/_upload.json.jbuilder +2 -0
- data/app/views/elabs/member/uploads/edit.html.haml +6 -0
- data/app/views/elabs/member/uploads/index.html.haml +61 -0
- data/app/views/elabs/member/uploads/index.json.jbuilder +1 -0
- data/app/views/elabs/member/uploads/new.html.haml +3 -0
- data/app/views/elabs/member/users/_form.html.haml +38 -0
- data/app/views/elabs/notes/_filters.html.haml +7 -0
- data/app/views/elabs/notes/_note.html.haml +31 -0
- data/app/views/elabs/notes/_note.json.jbuilder +2 -0
- data/app/views/elabs/notes/index.html.haml +9 -0
- data/app/views/elabs/notes/index.json.jbuilder +1 -0
- data/app/views/elabs/notes/show.html.haml +44 -0
- data/app/views/elabs/notes/show.json.jbuilder +1 -0
- data/app/views/elabs/projects/_associations.html.haml +46 -0
- data/app/views/elabs/projects/_filters.html.haml +8 -0
- data/app/views/elabs/projects/_project.html.haml +29 -0
- data/app/views/elabs/projects/index.html.haml +9 -0
- data/app/views/elabs/projects/index.json.jbuilder +1 -0
- data/app/views/elabs/projects/show.html.haml +71 -0
- data/app/views/elabs/projects/show.json.jbuilder +1 -0
- data/app/views/elabs/reports/_form.html.haml +29 -0
- data/app/views/elabs/tags/_associations.html.haml +51 -0
- data/app/views/elabs/tags/_filters.html.haml +3 -0
- data/app/views/elabs/tags/_tag.json.jbuilder +2 -0
- data/app/views/elabs/tags/index.html.haml +26 -0
- data/app/views/elabs/tags/index.json.jbuilder +1 -0
- data/app/views/elabs/tags/show.html.haml +34 -0
- data/app/views/elabs/tags/show.json.jbuilder +1 -0
- data/app/views/elabs/uploads/_filters.html.haml +7 -0
- data/app/views/elabs/uploads/_player.html.haml +10 -0
- data/app/views/elabs/uploads/_preview.html.haml +17 -0
- data/app/views/elabs/uploads/_upload.html.haml +41 -0
- data/app/views/elabs/uploads/_upload.json.jbuilder +2 -0
- data/app/views/elabs/uploads/index.html.haml +9 -0
- data/app/views/elabs/uploads/index.json.jbuilder +1 -0
- data/app/views/elabs/uploads/show.html.haml +58 -0
- data/app/views/elabs/uploads/show.json.jbuilder +1 -0
- data/app/views/elabs/users/_associations.html.haml +51 -0
- data/app/views/elabs/users/_filters.html.haml +4 -0
- data/app/views/elabs/users/_user.html.haml +31 -0
- data/app/views/elabs/users/_user.json.jbuilder +2 -0
- data/app/views/elabs/users/index.html.haml +7 -0
- data/app/views/elabs/users/index.json.jbuilder +1 -0
- data/app/views/elabs/users/show.html.haml +48 -0
- data/app/views/elabs/users/show.json.jbuilder +1 -0
- data/bin/rails +14 -0
- data/config.ru +5 -0
- data/config/brakeman.ignore +124 -0
- data/config/brakeman.yml +3 -0
- data/config/cucumber.yml +9 -0
- data/config/routes.rb +116 -0
- data/db/migrate/20180813000000_devise_update_users.rb +15 -0
- data/db/migrate/20180813000001_create_languages.rb +16 -0
- data/db/migrate/20180813000002_create_tags.rb +14 -0
- data/db/migrate/20180813000004_create_licenses.rb +17 -0
- data/db/migrate/20180813000005_create_reports.rb +15 -0
- data/db/migrate/20180813000006_create_comments.rb +15 -0
- data/db/migrate/20180813000007_create_acts.rb +10 -0
- data/db/migrate/20180813000008_create_preferences.rb +13 -0
- data/db/migrate/20180813000009_create_active_storage_tables.active_storage.rb +26 -0
- data/db/migrate/20180813000010_create_albums.rb +23 -0
- data/db/migrate/20180813000011_create_articles.rb +23 -0
- data/db/migrate/20180813000012_create_notes.rb +21 -0
- data/db/migrate/20180813000013_create_uploads.rb +26 -0
- data/db/migrate/20180813000014_create_projects.rb +44 -0
- data/db/seeds.rb +10 -0
- data/db/seeds_development.rb +21 -0
- data/db/seeds_production.rb +0 -0
- data/docs/contributing.md +52 -0
- data/docs/cucumber_terms.md +9 -0
- data/docs/migrating.md +4 -0
- data/docs/overriding.md +20 -0
- data/docs/setup.md +136 -0
- data/docs/tips.md +13 -0
- data/elabs.gemspec +25 -0
- data/lib/assets/javascripts/README-highlight.js.md +39 -0
- data/lib/assets/javascripts/codemirror-5.39.2/addon/mode/overlay.js +90 -0
- data/lib/assets/javascripts/codemirror-5.39.2/lib/codemirror.js +9684 -0
- data/lib/assets/javascripts/codemirror-5.39.2/mode/clike/clike.js +834 -0
- data/lib/assets/javascripts/codemirror-5.39.2/mode/css/css.js +832 -0
- data/lib/assets/javascripts/codemirror-5.39.2/mode/gfm/gfm.js +129 -0
- data/lib/assets/javascripts/codemirror-5.39.2/mode/htmlmixed/htmlmixed.js +152 -0
- data/lib/assets/javascripts/codemirror-5.39.2/mode/javascript/javascript.js +896 -0
- data/lib/assets/javascripts/codemirror-5.39.2/mode/markdown/markdown.js +882 -0
- data/lib/assets/javascripts/codemirror-5.39.2/mode/meta.js +217 -0
- data/lib/assets/javascripts/codemirror-5.39.2/mode/xml/xml.js +402 -0
- data/lib/assets/javascripts/highlight.js-9.12.0/highlight.pack.js +2 -0
- data/lib/assets/javascripts/markdown-it-8.4.2.min.js +1 -0
- data/lib/assets/stylesheets/codemirror-5.39.2/lib/codemirror.css +346 -0
- data/lib/assets/stylesheets/codemirror-5.39.2/theme/base16-dark.css +38 -0
- data/lib/assets/stylesheets/codemirror-5.39.2/theme/base16-light.css +38 -0
- data/lib/assets/stylesheets/highlight.js-9.12.0/styles/atelier-sulphurpool-light.css +69 -0
- data/lib/elabs.rb +41 -0
- data/lib/elabs/engine.rb +5 -0
- data/lib/elabs/version.rb +3 -0
- data/lib/generators/elabs/assets_generator.rb +36 -0
- data/lib/generators/elabs/devise_views_generator.rb +24 -0
- data/lib/generators/elabs/install_generator.rb +26 -0
- data/lib/generators/elabs/required_assets_generator.rb +26 -0
- data/lib/generators/elabs/views_generator.rb +25 -0
- data/lib/generators/templates/elabs.rb +25 -0
- data/lib/generators/templates/fast_gettext.rb +3 -0
- data/lib/tasks/.keep +0 -0
- data/lib/tasks/cucumber.rake +75 -0
- data/lib/tasks/elabs_tasks.rake +4 -0
- data/lib/tasks/factory_bot.rake +14 -0
- data/lib/tasks/wipe.rake +31 -0
- data/locale/app.pot +1124 -0
- data/locale/devise_strings.rb +88 -0
- data/locale/en/app.edit.po +1123 -0
- data/locale/en/app.po +1123 -0
- data/locale/en/app.po.time_stamp +0 -0
- data/locale/fr/app.edit.po +1126 -0
- data/locale/fr/app.po +1125 -0
- data/locale/fr/app.po.time_stamp +0 -0
- data/locale/model_attributes.rb +85 -0
- data/package.json +22 -0
- data/script/cucumber +10 -0
- data/tmp/pids/.keep +0 -0
- data/yarn.lock +2759 -0
- metadata +463 -0
@@ -0,0 +1,230 @@
|
|
1
|
+
/* stylelint-disable */
|
2
|
+
|
3
|
+
// Config file and project variables
|
4
|
+
|
5
|
+
// ----------------
|
6
|
+
// Breakpoints zone
|
7
|
+
// ----------------
|
8
|
+
|
9
|
+
// Warning: you should use your own values, regardless of the devices
|
10
|
+
// Best practice is Mobile First: (min-width: $breakpoint)
|
11
|
+
$tiny : 480px !default; // or 'em' if you prefer, of course
|
12
|
+
$small : 576px !default;
|
13
|
+
$medium : 768px !default;
|
14
|
+
$large : 992px !default;
|
15
|
+
$extra-large : 1200px !default;
|
16
|
+
|
17
|
+
// ----------
|
18
|
+
// Fonts zone
|
19
|
+
// ----------
|
20
|
+
|
21
|
+
// Font families
|
22
|
+
$font-family-base : 'Open Sans', 'Helvetica Neue', Helvetica, Arial, sans-serif; // system font stack
|
23
|
+
$font-family-headings : $font-family-base; // font for h1, h2.. h6
|
24
|
+
$font-family-monospace : consolas, courier, monospace; // font for code and samples
|
25
|
+
|
26
|
+
// Font sizes (1.6rem value is "16px" equivalent)
|
27
|
+
$font-size-base : 1.6rem !default;
|
28
|
+
|
29
|
+
$font-sizes: (
|
30
|
+
base: (
|
31
|
+
mobile : 1.4rem,
|
32
|
+
desktop : $font-size-base
|
33
|
+
),
|
34
|
+
h1: (
|
35
|
+
mobile : 2.8rem,
|
36
|
+
desktop : 3.2rem
|
37
|
+
),
|
38
|
+
h2: (
|
39
|
+
mobile : 2.4rem,
|
40
|
+
desktop : 2.8rem
|
41
|
+
),
|
42
|
+
h3: (
|
43
|
+
mobile : 2.0rem,
|
44
|
+
desktop : 2.4rem
|
45
|
+
),
|
46
|
+
h4: (
|
47
|
+
mobile : 1.8rem,
|
48
|
+
desktop : 2.0rem
|
49
|
+
),
|
50
|
+
h5: (
|
51
|
+
mobile : 1.6rem,
|
52
|
+
desktop : 1.8rem
|
53
|
+
),
|
54
|
+
h6: (
|
55
|
+
mobile : 1.4rem,
|
56
|
+
desktop : 1.6rem
|
57
|
+
)
|
58
|
+
) !default;
|
59
|
+
|
60
|
+
// Line heights
|
61
|
+
$line-height-s : 1.3 !default;
|
62
|
+
$line-height-base : 1.5 !default;
|
63
|
+
$line-height-l : 1.7 !default;
|
64
|
+
|
65
|
+
// Default margin-bottom
|
66
|
+
$margin-bottom-base : 1rem !default;
|
67
|
+
$headings-margin-bottom : $margin-bottom-base /2 !default;
|
68
|
+
$paragraph-margin-bottom: $margin-bottom-base !default;
|
69
|
+
|
70
|
+
// Font weights
|
71
|
+
$weight-light : 200 !default;
|
72
|
+
$weight-book : 300 !default;
|
73
|
+
$weight-regular : 400 !default;
|
74
|
+
$weight-medium : 500 !default;
|
75
|
+
$weight-bold : 700 !default;
|
76
|
+
|
77
|
+
// Activate hyphenation on small screens
|
78
|
+
$hyphens: false !default;
|
79
|
+
|
80
|
+
// ------------
|
81
|
+
// Spacing zone
|
82
|
+
// ------------
|
83
|
+
|
84
|
+
// Grid gutters (for .has-gutter-* classes)
|
85
|
+
$grid-gutters: (
|
86
|
+
'': 1rem,
|
87
|
+
'-l': 2rem,
|
88
|
+
'-xl': 4rem
|
89
|
+
) !default;
|
90
|
+
|
91
|
+
// Spacings
|
92
|
+
$spacer-tiny : .5rem !default;
|
93
|
+
$spacer-tiny-plus : .7rem !default;
|
94
|
+
$spacer-small : 1rem !default;
|
95
|
+
$spacer-small-plus : 1.5rem !default;
|
96
|
+
$spacer-medium : 2rem !default;
|
97
|
+
$spacer-medium-plus : 3rem !default;
|
98
|
+
$spacer-large : 4rem !default;
|
99
|
+
$spacer-large-plus : 6rem !default;
|
100
|
+
$spacer-extra-large : 8rem !default;
|
101
|
+
$spacer-extra-large-plus : 12rem !default;
|
102
|
+
$spacer-ultra-large : 16rem !default;
|
103
|
+
$spacer-ultra-large-plus : 20rem !default;
|
104
|
+
|
105
|
+
// z-indexes
|
106
|
+
$zindex-navigation : 1000 !default;
|
107
|
+
$zindex-dropdown : 2000 !default;
|
108
|
+
$zindex-popover : 3000 !default;
|
109
|
+
$zindex-tooltip : 4000 !default;
|
110
|
+
$zindex-modal : 5000 !default;
|
111
|
+
$zindex-notification : 6000 !default;
|
112
|
+
$zindex-debug : 7000 !default;
|
113
|
+
|
114
|
+
// ----------
|
115
|
+
// Color zone
|
116
|
+
// ----------
|
117
|
+
|
118
|
+
// Color names
|
119
|
+
$white : $color-white;
|
120
|
+
$gray-100 : $color-grey-100;
|
121
|
+
$gray-200 : $color-grey-200;
|
122
|
+
$gray-300 : $color-grey-300;
|
123
|
+
$gray-400 : $color-grey-400;
|
124
|
+
$gray-500 : $color-grey-500;
|
125
|
+
$gray-600 : $color-grey-600;
|
126
|
+
$gray-700 : $color-grey-700;
|
127
|
+
$gray-800 : $color-grey-800;
|
128
|
+
$gray-900 : $color-grey-900;
|
129
|
+
$black : $color-black;
|
130
|
+
|
131
|
+
$blue-300 : $color-blue-300;
|
132
|
+
$blue-500 : $color-blue-500;
|
133
|
+
$green-500 : $color-green-500;
|
134
|
+
$orange-500 : $color-orange-500;
|
135
|
+
$red-500 : $color-red-500;
|
136
|
+
|
137
|
+
// Semantic colors
|
138
|
+
//$color-brand : $green-500;
|
139
|
+
//$color-primary : $blue-500;
|
140
|
+
//$color-success : $green-500;
|
141
|
+
//$color-info : $blue-300;
|
142
|
+
//$color-warning : $orange-500;
|
143
|
+
//$color-danger : $red-500;
|
144
|
+
//$color-inverse : $gray-800;
|
145
|
+
//$color-ghost : transparent;
|
146
|
+
//$color-muted : $gray-200;
|
147
|
+
|
148
|
+
//$color-base : $gray-900;
|
149
|
+
$background-base : $color-background-base;
|
150
|
+
|
151
|
+
$forms-color : $gray-800;
|
152
|
+
|
153
|
+
// ---------------
|
154
|
+
// Components zone
|
155
|
+
// ---------------
|
156
|
+
|
157
|
+
// Component: links
|
158
|
+
//$link-color : $gray-800;
|
159
|
+
//$link-color-hover : darken($link-color, 15%);
|
160
|
+
$link-decoration : underline;
|
161
|
+
$link-decoration-hover : underline;
|
162
|
+
|
163
|
+
// Global border-radius
|
164
|
+
$border-radius: 0 !default;
|
165
|
+
|
166
|
+
// Component: quotes
|
167
|
+
$quote-color : $color-grey-200;
|
168
|
+
|
169
|
+
// Component: arrows
|
170
|
+
$arrow-color : $color-black;
|
171
|
+
|
172
|
+
// Components: checkboxes, radios, switches
|
173
|
+
$checkbox-color: $color-white;
|
174
|
+
$checkbox-background: $gray-800;
|
175
|
+
$checkbox-size: 2rem;
|
176
|
+
$checkbox-border-radius: 4px;
|
177
|
+
$radio-color: $gray-800;
|
178
|
+
$radio-background: $color-white;
|
179
|
+
$switch-color: $color-white;
|
180
|
+
$switch-background: $gray-800;
|
181
|
+
$switch-size: 2rem;
|
182
|
+
$switch-border-radius: 3em;
|
183
|
+
|
184
|
+
// Component: tables
|
185
|
+
//$table-border : $gray-500;
|
186
|
+
//$table-caption-color : $gray-800;
|
187
|
+
//$table-background : transparent;
|
188
|
+
//$table-head-color : $color-base;
|
189
|
+
//$table-head-background : transparent;
|
190
|
+
//$table-footer-color : $color-base;
|
191
|
+
//$table-footer-background : transparent;
|
192
|
+
|
193
|
+
// Components: buttons, badges, alerts color variants list
|
194
|
+
// Convention is: name - background-color - color - border
|
195
|
+
$variants-list: (
|
196
|
+
(download, $color-brand, $white, none),
|
197
|
+
(primary, $color-primary, $white, none),
|
198
|
+
(new, $color-primary, $white, none),
|
199
|
+
(save, $color-success, $white, none),
|
200
|
+
(show, $color-primary, $white, none),
|
201
|
+
(edit, $color-primary, $white, none),
|
202
|
+
(success, $color-success, $white, none),
|
203
|
+
(info, $color-info, $black, none),
|
204
|
+
(notice, $color-info, $black, none),
|
205
|
+
(warning, $color-warning, $black, none),
|
206
|
+
(lock, $color-warning, $black, none),
|
207
|
+
(danger, $color-danger, $white, none),
|
208
|
+
(destroy, $color-danger, $white, none),
|
209
|
+
(inverse, $color-inverse, $white, none),
|
210
|
+
(ghost, $color-ghost, $white, 0 0 0 1px $white inset)
|
211
|
+
) !default;
|
212
|
+
|
213
|
+
// Component: tabs
|
214
|
+
$tabs-border : $gray-200;
|
215
|
+
$tabs-active-border : $gray-800;
|
216
|
+
$tabs-color : $color-base;
|
217
|
+
$tabs-active-color : $gray-800;
|
218
|
+
$tabs-background : transparent;
|
219
|
+
$tabs-active-background : transparent;
|
220
|
+
$tabs-border-radius : 0;
|
221
|
+
|
222
|
+
// Component: nav burger button
|
223
|
+
$burger-color : $gray-800;
|
224
|
+
$burger-background : transparent;
|
225
|
+
$burger-hover-background : transparent;
|
226
|
+
$burger-size : 2.6rem;
|
227
|
+
$burger-weight : 5px; // size of stripes
|
228
|
+
$burger-padding : 0;
|
229
|
+
|
230
|
+
/* stylelint-enable */
|
@@ -0,0 +1,59 @@
|
|
1
|
+
/* stylelint-disable */
|
2
|
+
|
3
|
+
/*!
|
4
|
+
* www.KNACSS.com v7.0.6 (mai, 25 2018) @author: Alsacreations, Raphael Goetter
|
5
|
+
* Licence WTFPL http://www.wtfpl.net/
|
6
|
+
*/
|
7
|
+
|
8
|
+
/* ----------------------------- */
|
9
|
+
/* ==Table Of Content */
|
10
|
+
/* ----------------------------- */
|
11
|
+
|
12
|
+
/*
|
13
|
+
1- Reboot (basic reset)
|
14
|
+
2- Libraries :
|
15
|
+
- Base
|
16
|
+
- Print
|
17
|
+
- Layout (alignment, modules, positionning)
|
18
|
+
- Utilities (width and spacers helpers)
|
19
|
+
- Responsive helpers
|
20
|
+
- WordPress reset (disabled by default)
|
21
|
+
- Grillade (Grid System)
|
22
|
+
3- Components :
|
23
|
+
- Media object
|
24
|
+
- Skip Links for accessibility
|
25
|
+
- Tables
|
26
|
+
- Forms
|
27
|
+
- Buttons
|
28
|
+
- Checkbox
|
29
|
+
- Tabs
|
30
|
+
- Tags
|
31
|
+
- Badges
|
32
|
+
- Alerts
|
33
|
+
*/
|
34
|
+
|
35
|
+
@import "knacss/sass/_vendor/reboot"; // Bootstrap reboot (basic reset) (CSS file renamed and imported as if it was a partial because of libsass)
|
36
|
+
@import "knacss/sass/_config/mixins";
|
37
|
+
|
38
|
+
// Core Libraries
|
39
|
+
@import "knacss/sass/_library/base"; // basic styles
|
40
|
+
@import "knacss/sass/_library/print"; // print quick reset
|
41
|
+
@import "knacss/sass/_library/layout"; // alignment, modules, positionning
|
42
|
+
@import "knacss/sass/_library/utilities"; // width and spacer helpers
|
43
|
+
@import "knacss/sass/_library/responsive"; // Responsive Web Design helpers
|
44
|
+
@import "knacss/sass/_library/grillade-grid"; // grid system with Grid Layout
|
45
|
+
|
46
|
+
// Components
|
47
|
+
//@import "knacss/sass/components/media"; // media object
|
48
|
+
//@import "knacss/sass/components/skip-links"; // skip links
|
49
|
+
//@import "knacss/sass/components/tables"; // data tables consistency
|
50
|
+
@import "knacss/sass/components/forms"; // forms consistency and styles
|
51
|
+
@import "knacss/sass/components/buttons"; // buttons styles
|
52
|
+
@import "knacss/sass/components/checkbox"; // checkbox, radio, switch styles
|
53
|
+
//@import "knacss/sass/components/tabs"; // tabs styles
|
54
|
+
//@import "knacss/sass/components/arrows"; // arrows styles
|
55
|
+
//@import "knacss/sass/components/tags"; // tags styles
|
56
|
+
//@import "knacss/sass/components/badges"; // badges styles
|
57
|
+
@import "knacss/sass/components/alerts"; // alerts styles
|
58
|
+
|
59
|
+
/* stylelint-enable */
|
@@ -0,0 +1,72 @@
|
|
1
|
+
/* ------------------
|
2
|
+
Elabs variables
|
3
|
+
------------------ */
|
4
|
+
@import 'colors';
|
5
|
+
@import 'variables';
|
6
|
+
|
7
|
+
// Mixins
|
8
|
+
@import 'app/mixins/classifier-card';
|
9
|
+
@import 'app/mixins/content-card';
|
10
|
+
@import 'app/mixins/content-full';
|
11
|
+
@import 'app/mixins/icon';
|
12
|
+
|
13
|
+
/* ------------------
|
14
|
+
Libraries
|
15
|
+
------------------ */
|
16
|
+
@import 'lib/knacss/knacss-variables';
|
17
|
+
@import 'lib/knacss/knacss';
|
18
|
+
@import 'lib/fontawesome/fonts';
|
19
|
+
@import 'lib/fontawesome/fontawesome';
|
20
|
+
@import 'lib/fontawesome/icons';
|
21
|
+
@import 'icons';
|
22
|
+
|
23
|
+
/* ------------------
|
24
|
+
Elabs elements
|
25
|
+
------------------ */
|
26
|
+
|
27
|
+
// Helpers
|
28
|
+
@import 'app/helpers';
|
29
|
+
|
30
|
+
// App specific components
|
31
|
+
@import 'app/components/cards';
|
32
|
+
@import 'app/components/container';
|
33
|
+
|
34
|
+
// App specific areas
|
35
|
+
@import 'app/areas/devise';
|
36
|
+
|
37
|
+
// App specific elements
|
38
|
+
@import 'app/acts';
|
39
|
+
@import 'app/alerts';
|
40
|
+
@import 'app/buttons';
|
41
|
+
@import 'app/comments';
|
42
|
+
@import 'app/content';
|
43
|
+
@import 'app/content_uploads';
|
44
|
+
@import 'app/empty';
|
45
|
+
@import 'app/errors';
|
46
|
+
@import 'app/filter_links';
|
47
|
+
@import 'app/forms';
|
48
|
+
@import 'app/languages';
|
49
|
+
@import 'app/layout';
|
50
|
+
@import 'app/licenses';
|
51
|
+
@import 'app/link-to-top';
|
52
|
+
@import 'app/medias';
|
53
|
+
@import 'app/modals';
|
54
|
+
@import 'app/nsfw';
|
55
|
+
@import 'app/pagination';
|
56
|
+
@import 'app/tabs';
|
57
|
+
@import 'app/tags';
|
58
|
+
@import 'app/toolbars';
|
59
|
+
@import 'app/users';
|
60
|
+
|
61
|
+
// Admin zone
|
62
|
+
@import 'app/admin-members/forms';
|
63
|
+
@import 'app/admin-members/indexes';
|
64
|
+
@import 'app/admin-members/layout';
|
65
|
+
|
66
|
+
// Other manually downloaded libraries
|
67
|
+
@import 'codemirror-5.39.2/lib/codemirror';
|
68
|
+
@import 'codemirror-5.39.2/theme/base16-light';
|
69
|
+
@import 'highlight.js-9.12.0/styles/atelier-sulphurpool-light';
|
70
|
+
|
71
|
+
// Overrides
|
72
|
+
@import 'lib/codemirror';
|
@@ -0,0 +1,12 @@
|
|
1
|
+
module Elabs
|
2
|
+
class ActsController < ElabsApplicationController
|
3
|
+
ALLOWED_ORDER_FROM = %w[created_at].freeze
|
4
|
+
DEFAULT_ORDER = { created_at: :desc }.freeze
|
5
|
+
|
6
|
+
# GET /acts
|
7
|
+
# GET /acts.json
|
8
|
+
def index
|
9
|
+
@acts = scope_request(Act).page(params[:page]).per(self.class::MAX_ITEMS_PER_PAGE)
|
10
|
+
end
|
11
|
+
end
|
12
|
+
end
|
@@ -0,0 +1,19 @@
|
|
1
|
+
module Elabs
|
2
|
+
module Admin
|
3
|
+
class AdminApplicationController < ElabsApplicationController
|
4
|
+
DEFAULT_ORDER_FIELD = 'id'.freeze
|
5
|
+
MAX_ITEMS_PER_PAGE = Elabs.max_admin_items_per_page
|
6
|
+
|
7
|
+
before_action :authenticate_admin!
|
8
|
+
|
9
|
+
layout 'elabs/layouts/admin_application'
|
10
|
+
|
11
|
+
private
|
12
|
+
|
13
|
+
def authenticate_admin!
|
14
|
+
authenticate_user!
|
15
|
+
redirect_to user_url(current_user.id), status: :unauthorized unless current_user.admin?
|
16
|
+
end
|
17
|
+
end
|
18
|
+
end
|
19
|
+
end
|
@@ -0,0 +1,66 @@
|
|
1
|
+
module Elabs
|
2
|
+
module Admin
|
3
|
+
class AdminContentApplicationController < AdminApplicationController
|
4
|
+
MODEL = nil
|
5
|
+
SINGULAR_NAME = nil
|
6
|
+
PLURAL_NAME = nil
|
7
|
+
|
8
|
+
before_action :set_entity, only: %i[destroy toggle_lock]
|
9
|
+
|
10
|
+
# GET /<entity>
|
11
|
+
# GET /<entity>.json
|
12
|
+
def index
|
13
|
+
order = params['order_by'] || self.class::DEFAULT_ORDER_FIELD
|
14
|
+
direction = params['direction'] || 'desc'
|
15
|
+
create_instance_variable self.class::PLURAL_NAME, self.class::MODEL.order(order => direction).page(params[:page]).per(self.class::MAX_ITEMS_PER_PAGE)
|
16
|
+
end
|
17
|
+
|
18
|
+
# DELETE /<entity>/1
|
19
|
+
# DELETE /<entity>/1.json
|
20
|
+
def destroy
|
21
|
+
@entity.destroy
|
22
|
+
respond_to do |format|
|
23
|
+
format.html { redirect_to index_url, notice: format(_('%<model_name>s was successfully destroyed.'), model_name: self.class::SINGULAR_NAME.capitalize) }
|
24
|
+
format.json { head :no_content }
|
25
|
+
end
|
26
|
+
end
|
27
|
+
|
28
|
+
# PUT /<entity>/1/toggle_lock
|
29
|
+
def toggle_lock
|
30
|
+
if @entity.toggle(:locked).save
|
31
|
+
respond_to do |format|
|
32
|
+
format.html { redirect_to index_url, notice: lock_message(@entity) }
|
33
|
+
format.json { render :show, status: :ok }
|
34
|
+
end
|
35
|
+
else
|
36
|
+
respond_to do |format|
|
37
|
+
format.html { redirect_to index_url, error: 'An error prevented to update this entity' }
|
38
|
+
format.json { render json: @entity.errors, status: :unprocessable_entity }
|
39
|
+
end
|
40
|
+
end
|
41
|
+
end
|
42
|
+
|
43
|
+
private
|
44
|
+
|
45
|
+
# Use callbacks to share common setup or constraints between actions.
|
46
|
+
def set_entity
|
47
|
+
id = params[:id] || params["#{self.class::SINGULAR_NAME}_id"]
|
48
|
+
@entity = self.class::MODEL.find(id)
|
49
|
+
create_instance_variable self.class::SINGULAR_NAME
|
50
|
+
end
|
51
|
+
|
52
|
+
def index_url
|
53
|
+
"admin_#{self.class::PLURAL_NAME}".to_sym
|
54
|
+
end
|
55
|
+
|
56
|
+
def lock_message(entity)
|
57
|
+
message = if entity.locked?
|
58
|
+
_('%<model_name>s was successfully locked.')
|
59
|
+
else
|
60
|
+
_('%<model_name>s was successfully unlocked.')
|
61
|
+
end
|
62
|
+
format(message, model_name: self.class::SINGULAR_NAME.capitalize)
|
63
|
+
end
|
64
|
+
end
|
65
|
+
end
|
66
|
+
end
|