spree_summernote 3.0.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (58) hide show
  1. checksums.yaml +7 -0
  2. data/.gitignore +17 -0
  3. data/.rspec +1 -0
  4. data/Gemfile +7 -0
  5. data/LICENSE +21 -0
  6. data/README.md +32 -0
  7. data/Rakefile +46 -0
  8. data/app/assets/javascripts/spree/backend/spree_summernote.js +3 -0
  9. data/app/assets/javascripts/spree_summernote/locales/summernote-ar-AR.js +97 -0
  10. data/app/assets/javascripts/spree_summernote/locales/summernote-ca-ES.js +95 -0
  11. data/app/assets/javascripts/spree_summernote/locales/summernote-cs-CZ.js +96 -0
  12. data/app/assets/javascripts/spree_summernote/locales/summernote-da-DK.js +107 -0
  13. data/app/assets/javascripts/spree_summernote/locales/summernote-de-DE.js +97 -0
  14. data/app/assets/javascripts/spree_summernote/locales/summernote-es-ES.js +98 -0
  15. data/app/assets/javascripts/spree_summernote/locales/summernote-es-EU.js +96 -0
  16. data/app/assets/javascripts/spree_summernote/locales/summernote-fa-IR.js +98 -0
  17. data/app/assets/javascripts/spree_summernote/locales/summernote-fi-FI.js +97 -0
  18. data/app/assets/javascripts/spree_summernote/locales/summernote-fr-FR.js +100 -0
  19. data/app/assets/javascripts/spree_summernote/locales/summernote-he-IL.js +100 -0
  20. data/app/assets/javascripts/spree_summernote/locales/summernote-hu-HU.js +98 -0
  21. data/app/assets/javascripts/spree_summernote/locales/summernote-id-ID.js +96 -0
  22. data/app/assets/javascripts/spree_summernote/locales/summernote-it-IT.js +97 -0
  23. data/app/assets/javascripts/spree_summernote/locales/summernote-ja-JP.js +97 -0
  24. data/app/assets/javascripts/spree_summernote/locales/summernote-ko-KR.js +103 -0
  25. data/app/assets/javascripts/spree_summernote/locales/summernote-nb-NO.js +97 -0
  26. data/app/assets/javascripts/spree_summernote/locales/summernote-nl-NL.js +97 -0
  27. data/app/assets/javascripts/spree_summernote/locales/summernote-pl-PL.js +105 -0
  28. data/app/assets/javascripts/spree_summernote/locales/summernote-pt-BR.js +96 -0
  29. data/app/assets/javascripts/spree_summernote/locales/summernote-pt-PT.js +96 -0
  30. data/app/assets/javascripts/spree_summernote/locales/summernote-ro-RO.js +95 -0
  31. data/app/assets/javascripts/spree_summernote/locales/summernote-ru-RU.js +100 -0
  32. data/app/assets/javascripts/spree_summernote/locales/summernote-sk-SK.js +95 -0
  33. data/app/assets/javascripts/spree_summernote/locales/summernote-sl-SI.js +99 -0
  34. data/app/assets/javascripts/spree_summernote/locales/summernote-sr-RS-Latin.js +97 -0
  35. data/app/assets/javascripts/spree_summernote/locales/summernote-sr-RS.js +97 -0
  36. data/app/assets/javascripts/spree_summernote/locales/summernote-sv-SE.js +97 -0
  37. data/app/assets/javascripts/spree_summernote/locales/summernote-th-TH.js +99 -0
  38. data/app/assets/javascripts/spree_summernote/locales/summernote-tr-TR.js +104 -0
  39. data/app/assets/javascripts/spree_summernote/locales/summernote-uk-UA.js +99 -0
  40. data/app/assets/javascripts/spree_summernote/locales/summernote-vi-VN.js +97 -0
  41. data/app/assets/javascripts/spree_summernote/locales/summernote-zh-CN.js +96 -0
  42. data/app/assets/javascripts/spree_summernote/locales/summernote-zh-TW.js +95 -0
  43. data/app/assets/javascripts/spree_summernote/summernote.js +7006 -0
  44. data/app/assets/javascripts/spree_summernote/summernote_locales.js +2 -0
  45. data/app/assets/javascripts/spree_summernote/summernote_settings.js +50 -0
  46. data/app/assets/stylesheets/spree/backend/spree_summernote.css +5 -0
  47. data/app/assets/stylesheets/spree_summernote/summernote-bs3.css +5442 -0
  48. data/app/assets/stylesheets/spree_summernote/summernote.css +1 -0
  49. data/bin/rails +7 -0
  50. data/config/locales/en.yml +5 -0
  51. data/config/routes.rb +3 -0
  52. data/lib/generators/spree_summernote/install/install_generator.rb +15 -0
  53. data/lib/spree_summernote/engine.rb +20 -0
  54. data/lib/spree_summernote/factories.rb +6 -0
  55. data/lib/spree_summernote.rb +2 -0
  56. data/spec/spec_helper.rb +87 -0
  57. data/spree_summernote.gemspec +32 -0
  58. metadata +268 -0
@@ -0,0 +1,2 @@
1
+ // Manifest file to include summernote locale files
2
+ //= require_tree ./locales
@@ -0,0 +1,50 @@
1
+ (function() {
2
+ // Spree's locales are different to Summernotes
3
+ // Summernote defaults to english if it doesn't get what's being set
4
+ var metaTranslations = {
5
+ "ca": "ca-ES",
6
+ "cs": "cs-CZ",
7
+ "da": "da-DK",
8
+ "de": "de-DE",
9
+ "es": "es-ES",
10
+ "fa": "fa-FA",
11
+ "fi": "fi-FI",
12
+ "fr": "fr-FR",
13
+ "id": "id-ID",
14
+ "it": "it-IT",
15
+ "ja": "ja-JP",
16
+ "ko": "ko-KR",
17
+ "nb": "nb-NO",
18
+ "nl": "nl-NL",
19
+ "pl": "pl-PL",
20
+ "pt": "pt-PT",
21
+ "ro": "ro-RO",
22
+ "ru": "ru-RU",
23
+ "sk": "sk-SK",
24
+ "sl-SI": "sl-SI",
25
+ "sv": "sv-SE",
26
+ "th": "th-TH",
27
+ "uk": "uk-UA",
28
+ "vi": "vi-VN",
29
+ "zh-CN": "zh-CN",
30
+ "zh-TW": "zh-TW"
31
+ };
32
+
33
+ $(document).ready(function() {
34
+
35
+ var locale = $('html').attr('lang');
36
+ var translation = metaTranslations[locale];
37
+ var selectors = [
38
+ '.summernote',
39
+ '.description .panel-body textarea',
40
+ '#product_description',
41
+ '#taxon_description',
42
+ '#promotion_description'
43
+ ].join(',');
44
+
45
+ $(selectors).summernote({
46
+ lang: translation
47
+ });
48
+
49
+ });
50
+ })();
@@ -0,0 +1,5 @@
1
+ /*
2
+ *= require font-awesome
3
+ *= require spree_summernote/summernote
4
+ *= require spree_summernote/summernote-bs3
5
+ */