From fda1545ccbc13b865247affc00cbb9e87402d815 Mon Sep 17 00:00:00 2001 From: Jeremy Jackson Date: Fri, 24 Jun 2011 14:06:05 -0600 Subject: [PATCH] removed haml, and adjusted object notation to support ruby 1.8.7 as well --- Gemfile | 7 +- Gemfile.lock | 2 - .../mercury/regions/editable.js.coffee | 2 +- app/controllers/mercury_controller.rb | 8 +- app/models/image.rb | 4 +- app/views/layouts/mercury.html.erb | 14 + app/views/layouts/mercury.html.haml | 8 - app/views/mercury/modals/character.html.erb | 253 ++++++++++++++++++ app/views/mercury/modals/character.html.haml | 252 ----------------- app/views/mercury/modals/htmleditor.html.erb | 11 + app/views/mercury/modals/htmleditor.html.haml | 8 - app/views/mercury/modals/link.html.erb | 40 +++ app/views/mercury/modals/link.html.haml | 31 --- app/views/mercury/modals/media.html.erb | 43 +++ app/views/mercury/modals/media.html.haml | 33 --- app/views/mercury/modals/sanitizer.html.erb | 5 + app/views/mercury/modals/sanitizer.html.haml | 4 - app/views/mercury/modals/table.html.erb | 66 +++++ app/views/mercury/modals/table.html.haml | 49 ---- app/views/mercury/palettes/backcolor.html.erb | 73 +++++ .../mercury/palettes/backcolor.html.haml | 79 ------ app/views/mercury/palettes/forecolor.html.erb | 73 +++++ .../mercury/palettes/forecolor.html.haml | 79 ------ .../{history.html.haml => history.html.erb} | 0 .../{notes.html.haml => notes.html.erb} | 0 app/views/mercury/panels/snippets.html.erb | 12 + app/views/mercury/panels/snippets.html.haml | 10 - .../mercury/selects/formatblock.html.erb | 11 + .../mercury/selects/formatblock.html.haml | 10 - app/views/mercury/selects/style.html.erb | 5 + app/views/mercury/selects/style.html.haml | 4 - app/views/mercury/snippets/example.html.erb | 1 + app/views/mercury/snippets/example.html.haml | 2 - .../mercury/snippets/example_options.html.erb | 23 ++ .../snippets/example_options.html.haml | 18 -- config/application.rb | 2 + config/initializers/secret_token.rb | 7 - config/routes.rb | 2 +- 38 files changed, 643 insertions(+), 608 deletions(-) create mode 100644 app/views/layouts/mercury.html.erb delete mode 100644 app/views/layouts/mercury.html.haml create mode 100644 app/views/mercury/modals/character.html.erb delete mode 100644 app/views/mercury/modals/character.html.haml create mode 100644 app/views/mercury/modals/htmleditor.html.erb delete mode 100644 app/views/mercury/modals/htmleditor.html.haml create mode 100644 app/views/mercury/modals/link.html.erb delete mode 100644 app/views/mercury/modals/link.html.haml create mode 100644 app/views/mercury/modals/media.html.erb delete mode 100644 app/views/mercury/modals/media.html.haml create mode 100644 app/views/mercury/modals/sanitizer.html.erb delete mode 100644 app/views/mercury/modals/sanitizer.html.haml create mode 100644 app/views/mercury/modals/table.html.erb delete mode 100644 app/views/mercury/modals/table.html.haml create mode 100644 app/views/mercury/palettes/backcolor.html.erb delete mode 100644 app/views/mercury/palettes/backcolor.html.haml create mode 100644 app/views/mercury/palettes/forecolor.html.erb delete mode 100644 app/views/mercury/palettes/forecolor.html.haml rename app/views/mercury/panels/{history.html.haml => history.html.erb} (100%) rename app/views/mercury/panels/{notes.html.haml => notes.html.erb} (100%) create mode 100644 app/views/mercury/panels/snippets.html.erb delete mode 100644 app/views/mercury/panels/snippets.html.haml create mode 100644 app/views/mercury/selects/formatblock.html.erb delete mode 100644 app/views/mercury/selects/formatblock.html.haml create mode 100644 app/views/mercury/selects/style.html.erb delete mode 100644 app/views/mercury/selects/style.html.haml create mode 100644 app/views/mercury/snippets/example.html.erb delete mode 100644 app/views/mercury/snippets/example.html.haml create mode 100644 app/views/mercury/snippets/example_options.html.erb delete mode 100644 app/views/mercury/snippets/example_options.html.haml delete mode 100644 config/initializers/secret_token.rb diff --git a/Gemfile b/Gemfile index 1b19dc1..d837623 100644 --- a/Gemfile +++ b/Gemfile @@ -4,13 +4,12 @@ gem 'rails', '3.1.0.rc4' # Assets and forms gem 'paperclip' -gem 'formtastic', git: 'git://github.com/justinfrench/formtastic.git' +gem 'formtastic', :git => 'git://github.com/justinfrench/formtastic.git' # Asset template engines gem 'json' gem 'sass-rails', "~> 3.1.0.rc" gem 'coffee-script' -gem 'haml' group :development, :test do gem 'uglifier' @@ -18,8 +17,8 @@ group :development, :test do gem 'jeweler' gem 'sqlite3' gem 'thin' - gem 'ruby-debug19', require: 'ruby-debug' - gem 'evergreen', git: 'git://github.com/jnicklas/evergreen.git', submodules: true, require: 'evergreen/rails' + gem 'ruby-debug19', :require => 'ruby-debug' + gem 'evergreen', :git => 'git://github.com/jnicklas/evergreen.git', :submodules => true, :require => 'evergreen/rails' end group :test do diff --git a/Gemfile.lock b/Gemfile.lock index a2f3d50..6552f50 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -96,7 +96,6 @@ GEM gherkin (2.4.0) json (>= 1.4.6) git (1.2.5) - haml (3.1.2) hike (1.1.0) i18n (0.6.0) jeweler (1.6.2) @@ -207,7 +206,6 @@ DEPENDENCIES database_cleaner evergreen! formtastic! - haml jeweler jquery-rails json diff --git a/app/assets/javascripts/mercury/regions/editable.js.coffee b/app/assets/javascripts/mercury/regions/editable.js.coffee index a39930f..696406c 100644 --- a/app/assets/javascripts/mercury/regions/editable.js.coffee +++ b/app/assets/javascripts/mercury/regions/editable.js.coffee @@ -18,7 +18,7 @@ class @Mercury.Regions.Editable extends Mercury.Region @specialContainer = jQuery.browser.mozilla && @element.get(0).tagName != 'DIV' # make it editable - # gecko: in this makes double clicking in textareas fail: https://bugzilla.mozilla.org/show_bug.cgi?id=490367 + # mozilla: this makes double clicking in textareas fail: https://bugzilla.mozilla.org/show_bug.cgi?id=490367 @element.get(0).contentEditable = true # make all snippets not editable, and set their versions to 1 diff --git a/app/controllers/mercury_controller.rb b/app/controllers/mercury_controller.rb index e30eb66..e048dc3 100644 --- a/app/controllers/mercury_controller.rb +++ b/app/controllers/mercury_controller.rb @@ -2,19 +2,19 @@ class MercuryController < ActionController::Base protect_from_forgery def edit - render text: '', layout: 'mercury' + render :text => '', :layout => 'mercury' end def resource - render action: "/#{params[:type]}/#{params[:resource]}", layout: false + render :action => "/#{params[:type]}/#{params[:resource]}", :layout => false end def snippet_options - render action: "/snippets/#{params[:name]}_options", layout: false + render :action => "/snippets/#{params[:name]}_options", :layout => false end def snippet_preview - render action: "/snippets/#{params[:name]}", layout: false + render :action => "/snippets/#{params[:name]}", :layout => false end end diff --git a/app/models/image.rb b/app/models/image.rb index b2c5b53..7c8af12 100644 --- a/app/models/image.rb +++ b/app/models/image.rb @@ -1,8 +1,8 @@ class Image < ActiveRecord::Base - has_attached_file :image, styles: { medium: "300x300>", thumb: "100x100>" } + has_attached_file :image, :styles => { :medium => "300x300>", :thumb => "100x100>" } - delegate :url, to: :image + delegate :url, :to => :image def serializable_hash(options = nil) options ||= {} diff --git a/app/views/layouts/mercury.html.erb b/app/views/layouts/mercury.html.erb new file mode 100644 index 0000000..112f28a --- /dev/null +++ b/app/views/layouts/mercury.html.erb @@ -0,0 +1,14 @@ + + + + <%= csrf_meta_tags %> + Mercury Editor + + + + + + + diff --git a/app/views/layouts/mercury.html.haml b/app/views/layouts/mercury.html.haml deleted file mode 100644 index a216d28..0000000 --- a/app/views/layouts/mercury.html.haml +++ /dev/null @@ -1,8 +0,0 @@ -!!! -%html - %head - %title Mercury Editor - = csrf_meta_tags - = stylesheet_link_tag "mercury" - = javascript_include_tag "mercury" - %body= javascript_tag 'new Mercury.PageEditor()' diff --git a/app/views/mercury/modals/character.html.erb b/app/views/mercury/modals/character.html.erb new file mode 100644 index 0000000..077ea25 --- /dev/null +++ b/app/views/mercury/modals/character.html.erb @@ -0,0 +1,253 @@ +
+
+
+
"
+
&
+
<
+
>
+
ˆ
+
˜
+
 
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
¡
+
¢
+
£
+
¤
+
¥
+
¦
+
§
+
¨
+
©
+
ª
+
º
+
«
+
¬
+
®
+
¯
+
°
+
±
+
¹
+
²
+
³
+
´
+
µ
+
+
·
+
¸
+
»
+
¼
+
½
+
¾
+
¿
+
×
+
÷
+
À
+
à
+
Á
+
á
+
Â
+
â
+
Ã
+
ã
+
Ä
+
ä
+
Å
+
å
+
È
+
è
+
É
+
é
+
Ê
+
ê
+
Ë
+
ë
+
Ì
+
ì
+
Í
+
í
+
Î
+
î
+
Ï
+
ï
+
Ò
+
ò
+
Ó
+
ó
+
Ô
+
ô
+
Õ
+
õ
+
Ö
+
ö
+
Ø
+
ø
+
Ù
+
ù
+
Ú
+
ú
+
Û
+
û
+
Ü
+
ü
+
Ý
+
ý
+
Ÿ
+
ÿ
+
Æ
+
æ
+
Œ
+
œ
+
Š
+
š
+
Ç
+
ç
+
Ð
+
ð
+
Ñ
+
ñ
+
Þ
+
þ
+
ß
+
ƒ
+
Α
+
Β
+
Γ
+
Δ
+
Ε
+
Ζ
+
Η
+
Θ
+
Ι
+
Κ
+
Λ
+
Μ
+
Ν
+
Ξ
+
Ο
+
Π
+
Ρ
+
Σ
+
Τ
+
Υ
+
Φ
+
Χ
+
Ψ
+
Ω
+
α
+
β
+
γ
+
δ
+
ε
+
ζ
+
η
+
θ
+
ι
+
κ
+
λ
+
μ
+
ν
+
ξ
+
ο
+
π
+
ρ
+
ς
+
σ
+
τ
+
υ
+
φ
+
χ
+
ψ
+
ω
+
ϑ
+
ϒ
+
ϖ
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file diff --git a/app/views/mercury/modals/character.html.haml b/app/views/mercury/modals/character.html.haml deleted file mode 100644 index a57a8a0..0000000 --- a/app/views/mercury/modals/character.html.haml +++ /dev/null @@ -1,252 +0,0 @@ -%form#mercury_insertCharacter{ style: 'width:456px' } - - .mercury-modal-pane-container - .mercury-modal-pane - - .character{ data: {entity: "#34"}, title: "quotation mark (APL quote)" } " - .character{ data: {entity: "#38"}, title: "ampersand" } & - .character{ data: {entity: "#60"}, title: "less-than sign" } < - .character{ data: {entity: "#62"}, title: "greater-than sign" } > - .character{ data: {entity: "#710"}, title: "modifier letter circumflex accent" } ˆ - .character{ data: {entity: "#732"}, title: "small tilde" } ˜ - .character{ data: {entity: "#160"}, title: "non-breaking space" }   - .character{ data: {entity: "#8194"}, title: "en space" }   - .character{ data: {entity: "#8195"}, title: "em space" }   - .character{ data: {entity: "#8201"}, title: "thin space" }   - .character{ data: {entity: "#8211"}, title: "en dash" } – - .character{ data: {entity: "#8212"}, title: "em dash" } — - .character{ data: {entity: "#8216"}, title: "left single quotation mark" } ‘ - .character{ data: {entity: "#8217"}, title: "right single quotation mark" } ’ - .character{ data: {entity: "#8218"}, title: "single low-9 quotation mark" } ‚ - .character{ data: {entity: "#8220"}, title: "left double quotation mark" } “ - .character{ data: {entity: "#8221"}, title: "right double quotation mark" } ” - .character{ data: {entity: "#8222"}, title: "double low-9 quotation mark" } „ - .character{ data: {entity: "#8224"}, title: "dagger" } † - .character{ data: {entity: "#8225"}, title: "double dagger" } ‡ - .character{ data: {entity: "#8240"}, title: "per mille sign" } ‰ - .character{ data: {entity: "#8249"}, title: "single left-pointing angle quotation mark" } ‹ - .character{ data: {entity: "#8250"}, title: "single right-pointing angle quotation mark" } › - .character{ data: {entity: "#161"}, title: "inverted exclamation mark" } ¡ - .character{ data: {entity: "#162"}, title: "cent sign" } ¢ - .character{ data: {entity: "#163"}, title: "pound sign" } £ - .character{ data: {entity: "#164"}, title: "currency sign" } ¤ - .character{ data: {entity: "#165"}, title: "yen sign" } ¥ - .character{ data: {entity: "#166"}, title: "broken bar" } ¦ - .character{ data: {entity: "#167"}, title: "section sign" } § - .character{ data: {entity: "#168"}, title: "spacing diaeresis" } ¨ - .character{ data: {entity: "#169"}, title: "copyright sign" } © - .character{ data: {entity: "#170"}, title: "feminine ordinal indicator" } ª - .character{ data: {entity: "#186"}, title: "masculine ordinal indicator" } º - .character{ data: {entity: "#171"}, title: "left pointing guillemet" } « - .character{ data: {entity: "#172"}, title: "not sign" } ¬ - .character{ data: {entity: "#174"}, title: "registered trade mark sign" } ® - .character{ data: {entity: "#175"}, title: "spacing macron" } ¯ - .character{ data: {entity: "#176"}, title: "degree sign" } ° - .character{ data: {entity: "#177"}, title: "plus-or-minus sign" } ± - .character{ data: {entity: "#185"}, title: "superscript one" } ¹ - .character{ data: {entity: "#178"}, title: "superscript digit two" } ² - .character{ data: {entity: "#179"}, title: "superscript digit three" } ³ - .character{ data: {entity: "#180"}, title: "acute accent" } ´ - .character{ data: {entity: "#181"}, title: "micro sign" } µ - .character{ data: {entity: "#182"}, title: "pilcrow sign" } ¶ - .character{ data: {entity: "#183"}, title: "middle dot" } · - .character{ data: {entity: "#184"}, title: "cedilla" } ¸ - .character{ data: {entity: "#187"}, title: "right-pointing double angle quotation mark" } » - .character{ data: {entity: "#188"}, title: "fraction one quarter" } ¼ - .character{ data: {entity: "#189"}, title: "fraction one half" } ½ - .character{ data: {entity: "#190"}, title: "fraction three quarters" } ¾ - .character{ data: {entity: "#191"}, title: "inverted question mark" } ¿ - .character{ data: {entity: "#215"}, title: "multiplication sign" } × - .character{ data: {entity: "#247"}, title: "division sign" } ÷ - .character{ data: {entity: "#192"}, title: "latin capital letter A with grave" } À - .character{ data: {entity: "#224"}, title: "latin small letter a with grave" } à - .character{ data: {entity: "#193"}, title: "latin capital letter A with acute" } Á - .character{ data: {entity: "#225"}, title: "latin small letter a with acute" } á - .character{ data: {entity: "#194"}, title: "latin capital letter A with circumflex" }  - .character{ data: {entity: "#226"}, title: "latin small letter a with circumflex" } â - .character{ data: {entity: "#195"}, title: "latin capital letter A with tilde" } à - .character{ data: {entity: "#227"}, title: "latin small letter a with tilde" } ã - .character{ data: {entity: "#196"}, title: "latin capital letter A with diaeresis" } Ä - .character{ data: {entity: "#228"}, title: "latin small letter a with diaeresis" } ä - .character{ data: {entity: "#197"}, title: "latin capital letter A with ring above" } Å - .character{ data: {entity: "#229"}, title: "latin small letter a with ring above" } å - .character{ data: {entity: "#200"}, title: "latin capital letter E with grave" } È - .character{ data: {entity: "#232"}, title: "latin small letter e with grave" } è - .character{ data: {entity: "#201"}, title: "latin capital letter E with acute" } É - .character{ data: {entity: "#233"}, title: "latin small letter e with acute" } é - .character{ data: {entity: "#202"}, title: "latin capital letter E with circumflex" } Ê - .character{ data: {entity: "#234"}, title: "latin small letter e with circumflex" } ê - .character{ data: {entity: "#203"}, title: "latin capital letter E with diaeresis" } Ë - .character{ data: {entity: "#235"}, title: "latin small letter e with diaeresis" } ë - .character{ data: {entity: "#204"}, title: "latin capital letter I with grave" } Ì - .character{ data: {entity: "#236"}, title: "latin small letter i with grave" } ì - .character{ data: {entity: "#205"}, title: "latin capital letter I with acute" } Í - .character{ data: {entity: "#237"}, title: "latin small letter i with acute" } í - .character{ data: {entity: "#206"}, title: "latin capital letter I with circumflex" } Î - .character{ data: {entity: "#238"}, title: "latin small letter i with circumflex" } î - .character{ data: {entity: "#207"}, title: "latin capital letter I with diaeresis" } Ï - .character{ data: {entity: "#239"}, title: "latin small letter i with diaeresis" } ï - .character{ data: {entity: "#210"}, title: "latin capital letter O with grave" } Ò - .character{ data: {entity: "#242"}, title: "latin small letter o with grave" } ò - .character{ data: {entity: "#211"}, title: "latin capital letter O with acute" } Ó - .character{ data: {entity: "#243"}, title: "latin small letter o with acute" } ó - .character{ data: {entity: "#212"}, title: "latin capital letter O with circumflex" } Ô - .character{ data: {entity: "#244"}, title: "latin small letter o with circumflex" } ô - .character{ data: {entity: "#213"}, title: "latin capital letter O with tilde" } Õ - .character{ data: {entity: "#245"}, title: "latin small letter o with tilde" } õ - .character{ data: {entity: "#214"}, title: "latin capital letter O with diaeresis" } Ö - .character{ data: {entity: "#246"}, title: "latin small letter o with diaeresis" } ö - .character{ data: {entity: "#216"}, title: "latin capital letter O with stroke" } Ø - .character{ data: {entity: "#248"}, title: "latin small letter o with stroke" } ø - .character{ data: {entity: "#217"}, title: "latin capital letter U with grave" } Ù - .character{ data: {entity: "#249"}, title: "latin small letter u with grave" } ù - .character{ data: {entity: "#218"}, title: "latin capital letter U with acute" } Ú - .character{ data: {entity: "#250"}, title: "latin small letter u with acute" } ú - .character{ data: {entity: "#219"}, title: "latin capital letter U with circumflex" } Û - .character{ data: {entity: "#251"}, title: "latin small letter u with circumflex" } û - .character{ data: {entity: "#220"}, title: "latin capital letter U with diaeresis" } Ü - .character{ data: {entity: "#252"}, title: "latin small letter u with diaeresis" } ü - .character{ data: {entity: "#221"}, title: "latin capital letter Y with acute" } Ý - .character{ data: {entity: "#253"}, title: "latin small letter y with acute" } ý - .character{ data: {entity: "#376"}, title: "latin capital letter Y with diaeresis" } Ÿ - .character{ data: {entity: "#255"}, title: "latin small letter y with diaeresis" } ÿ - .character{ data: {entity: "#198"}, title: "latin capital ligature AE" } Æ - .character{ data: {entity: "#230"}, title: "latin small ligature ae" } æ - .character{ data: {entity: "#338"}, title: "latin capital ligature OE" } Œ - .character{ data: {entity: "#339"}, title: "latin small ligature oe" } œ - .character{ data: {entity: "#352"}, title: "latin capital letter S with caron" } Š - .character{ data: {entity: "#353"}, title: "latin small letter s with caron" } š - .character{ data: {entity: "#199"}, title: "latin capital letter C with cedilla" } Ç - .character{ data: {entity: "#231"}, title: "latin small letter c with cedilla" } ç - .character{ data: {entity: "#208"}, title: "latin capital letter ETH" } Ð - .character{ data: {entity: "#240"}, title: "latin small letter eth" } ð - .character{ data: {entity: "#209"}, title: "latin capital letter N with tilde" } Ñ - .character{ data: {entity: "#241"}, title: "latin small letter n with tilde" } ñ - .character{ data: {entity: "#222"}, title: "latin capital letter THORN" } Þ - .character{ data: {entity: "#254"}, title: "latin small letter thorn" } þ - .character{ data: {entity: "#223"}, title: "latin small letter sharp s (ess-zed)" } ß - .character{ data: {entity: "#402"}, title: "latin small f with hook (function)" } ƒ - .character{ data: {entity: "#913"}, title: "greek capital letter alpha" } Α - .character{ data: {entity: "#914"}, title: "greek capital letter beta" } Β - .character{ data: {entity: "#915"}, title: "greek capital letter gamma" } Γ - .character{ data: {entity: "#916"}, title: "greek capital letter delta" } Δ - .character{ data: {entity: "#917"}, title: "greek capital letter epsilon" } Ε - .character{ data: {entity: "#918"}, title: "greek capital letter zeta" } Ζ - .character{ data: {entity: "#919"}, title: "greek capital letter eta" } Η - .character{ data: {entity: "#920"}, title: "greek capital letter theta" } Θ - .character{ data: {entity: "#921"}, title: "greek capital letter iota" } Ι - .character{ data: {entity: "#922"}, title: "greek capital letter kappa" } Κ - .character{ data: {entity: "#923"}, title: "greek capital letter lambda" } Λ - .character{ data: {entity: "#924"}, title: "greek capital letter mu" } Μ - .character{ data: {entity: "#925"}, title: "greek capital letter nu" } Ν - .character{ data: {entity: "#926"}, title: "greek capital letter xi" } Ξ - .character{ data: {entity: "#927"}, title: "greek capital letter omicron" } Ο - .character{ data: {entity: "#928"}, title: "greek capital letter pi" } Π - .character{ data: {entity: "#929"}, title: "greek capital letter rho" } Ρ - .character{ data: {entity: "#931"}, title: "greek capital letter sigma" } Σ - .character{ data: {entity: "#932"}, title: "greek capital letter tau" } Τ - .character{ data: {entity: "#933"}, title: "greek capital letter upsilon" } Υ - .character{ data: {entity: "#934"}, title: "greek capital letter phi" } Φ - .character{ data: {entity: "#935"}, title: "greek capital letter chi" } Χ - .character{ data: {entity: "#936"}, title: "greek capital letter psi" } Ψ - .character{ data: {entity: "#937"}, title: "greek capital letter omega" } Ω - .character{ data: {entity: "#945"}, title: "greek small letter alpha" } α - .character{ data: {entity: "#946"}, title: "greek small letter beta" } β - .character{ data: {entity: "#947"}, title: "greek small letter gamma" } γ - .character{ data: {entity: "#948"}, title: "greek small letter delta" } δ - .character{ data: {entity: "#949"}, title: "greek small letter epsilon" } ε - .character{ data: {entity: "#950"}, title: "greek small letter zeta" } ζ - .character{ data: {entity: "#951"}, title: "greek small letter eta" } η - .character{ data: {entity: "#952"}, title: "greek small letter theta" } θ - .character{ data: {entity: "#953"}, title: "greek small letter iota" } ι - .character{ data: {entity: "#954"}, title: "greek small letter kappa" } κ - .character{ data: {entity: "#955"}, title: "greek small letter lambda" } λ - .character{ data: {entity: "#956"}, title: "greek small letter mu" } μ - .character{ data: {entity: "#957"}, title: "greek small letter nu" } ν - .character{ data: {entity: "#958"}, title: "greek small letter xi" } ξ - .character{ data: {entity: "#959"}, title: "greek small letter omicron" } ο - .character{ data: {entity: "#960"}, title: "greek small letter pi" } π - .character{ data: {entity: "#961"}, title: "greek small letter rho" } ρ - .character{ data: {entity: "#962"}, title: "greek small letter final sigma" } ς - .character{ data: {entity: "#963"}, title: "greek small letter sigma" } σ - .character{ data: {entity: "#964"}, title: "greek small letter tau" } τ - .character{ data: {entity: "#965"}, title: "greek small letter upsilon" } υ - .character{ data: {entity: "#966"}, title: "greek small letter phi" } φ - .character{ data: {entity: "#967"}, title: "greek small letter chi" } χ - .character{ data: {entity: "#968"}, title: "greek small letter psi" } ψ - .character{ data: {entity: "#969"}, title: "greek small letter omega" } ω - .character{ data: {entity: "#977"}, title: "greek small letter theta symbol" } ϑ - .character{ data: {entity: "#978"}, title: "greek upsilon with hook symbol" } ϒ - .character{ data: {entity: "#982"}, title: "greek pi symbol" } ϖ - .character{ data: {entity: "#8226"}, title: "bullet (black small circle)" } • - .character{ data: {entity: "#8230"}, title: "horizontal ellipsis" } … - .character{ data: {entity: "#8242"}, title: "prime (minutes/feet)" } ′ - .character{ data: {entity: "#8243"}, title: "double prime (seconds/inches)" } ″ - .character{ data: {entity: "#8254"}, title: "overline" } ‾ - .character{ data: {entity: "#8260"}, title: "fraction slash" } ⁄ - .character{ data: {entity: "#8472"}, title: "Weierstrass p" } ℘ - .character{ data: {entity: "#8465"}, title: "imaginary part" } ℑ - .character{ data: {entity: "#8476"}, title: "real part symbol" } ℜ - .character{ data: {entity: "#8482"}, title: "trade mark sign" } ™ - .character{ data: {entity: "#8501"}, title: "first transfinite cardinal" } ℵ - .character{ data: {entity: "#8592"}, title: "leftwards arrow" } ← - .character{ data: {entity: "#8593"}, title: "upwards arrow" } ↑ - .character{ data: {entity: "#8594"}, title: "rightwards arrow" } → - .character{ data: {entity: "#8595"}, title: "downwards arrow" } ↓ - .character{ data: {entity: "#8596"}, title: "left right arrow" } ↔ - .character{ data: {entity: "#8629"}, title: "downwards arrow with corner leftwards" } ↵ - .character{ data: {entity: "#8656"}, title: "leftwards double arrow" } ⇐ - .character{ data: {entity: "#8657"}, title: "upwards double arrow" } ⇑ - .character{ data: {entity: "#8658"}, title: "rightwards double arrow" } ⇒ - .character{ data: {entity: "#8659"}, title: "downwards double arrow" } ⇓ - .character{ data: {entity: "#8660"}, title: "left right double arrow" } ⇔ - .character{ data: {entity: "#8704"}, title: "for all" } ∀ - .character{ data: {entity: "#8706"}, title: "partial differential" } ∂ - .character{ data: {entity: "#8707"}, title: "there exists" } ∃ - .character{ data: {entity: "#8709"}, title: "empty set (null set/diameter)" } ∅ - .character{ data: {entity: "#8711"}, title: "nabla (backward difference)" } ∇ - .character{ data: {entity: "#8712"}, title: "element of" } ∈ - .character{ data: {entity: "#8713"}, title: "not an element of" } ∉ - .character{ data: {entity: "#8715"}, title: "contains as member" } ∋ - .character{ data: {entity: "#8719"}, title: "n-ary product (product sign)" } ∏ - .character{ data: {entity: "#8721"}, title: "n-ary sumation" } ∑ - .character{ data: {entity: "#8722"}, title: "minus sign" } − - .character{ data: {entity: "#8727"}, title: "asterisk operator" } ∗ - .character{ data: {entity: "#8730"}, title: "square root (radical sign)" } √ - .character{ data: {entity: "#8733"}, title: "proportional to" } ∝ - .character{ data: {entity: "#8734"}, title: "infinity" } ∞ - .character{ data: {entity: "#8736"}, title: "angle" } ∠ - .character{ data: {entity: "#8743"}, title: "logical and (wedge)" } ∧ - .character{ data: {entity: "#8744"}, title: "logical or (vee)" } ∨ - .character{ data: {entity: "#8745"}, title: "intersection (cap)" } ∩ - .character{ data: {entity: "#8746"}, title: "union (cup)" } ∪ - .character{ data: {entity: "#8747"}, title: "integral" } ∫ - .character{ data: {entity: "#8756"}, title: "therefore" } ∴ - .character{ data: {entity: "#8764"}, title: "tilde operator (varies with/similar to)" } ∼ - .character{ data: {entity: "#8773"}, title: "approximately equal to" } ≅ - .character{ data: {entity: "#8776"}, title: "almost equal to (asymptotic to)" } ≈ - .character{ data: {entity: "#8800"}, title: "not equal to" } ≠ - .character{ data: {entity: "#8801"}, title: "identical to" } ≡ - .character{ data: {entity: "#8804"}, title: "less-than or equal to" } ≤ - .character{ data: {entity: "#8805"}, title: "greater-than or equal to" } ≥ - .character{ data: {entity: "#8834"}, title: "subset of" } ⊂ - .character{ data: {entity: "#8835"}, title: "superset of" } ⊃ - .character{ data: {entity: "#8836"}, title: "not a subset of" } ⊄ - .character{ data: {entity: "#8838"}, title: "subset of or equal to" } ⊆ - .character{ data: {entity: "#8839"}, title: "superset of or equal to" } ⊇ - .character{ data: {entity: "#8853"}, title: "circled plus (direct sum)" } ⊕ - .character{ data: {entity: "#8855"}, title: "circled times (vector product)" } ⊗ - .character{ data: {entity: "#8869"}, title: "up tack (orthogonal to/perpendicular)" } ⊥ - .character{ data: {entity: "#8901"}, title: "dot operator" } ⋅ - .character{ data: {entity: "#8968"}, title: "left ceiling (apl upstile)" } ⌈ - .character{ data: {entity: "#8969"}, title: "right ceiling" } ⌉ - .character{ data: {entity: "#8970"}, title: "left floor (apl downstile)" } ⌊ - .character{ data: {entity: "#8971"}, title: "right floor" } ⌋ - .character{ data: {entity: "#9001"}, title: "left-pointing angle bracket (bra)" } 〈 - .character{ data: {entity: "#9002"}, title: "right-pointing angle bracket (ket)" } 〉 - .character{ data: {entity: "#9674"}, title: "lozenge" } ◊ - .character{ data: {entity: "#9824"}, title: "black spade suit" } ♠ - .character{ data: {entity: "#9827"}, title: "black club suit (shamrock)" } ♣ - .character{ data: {entity: "#9829"}, title: "black heart suit (valentine)" } ♥ - .character{ data: {entity: "#9830"}, title: "black diamond suit" } ♦ - .character{ data: {entity: "#x2603"}, title: "snowman" } ☃ diff --git a/app/views/mercury/modals/htmleditor.html.erb b/app/views/mercury/modals/htmleditor.html.erb new file mode 100644 index 0000000..dacd793 --- /dev/null +++ b/app/views/mercury/modals/htmleditor.html.erb @@ -0,0 +1,11 @@ +<%= semantic_form_for 'htmlEditor', { :html => { :id => 'mercury_htmlEditor', :style => 'width:650px' } } do |f| %> + + + +
+ <%= f.buttons do %> + <%= f.commit_button 'Save and Replace' %> + <% end %> +
+ +<% end %> \ No newline at end of file diff --git a/app/views/mercury/modals/htmleditor.html.haml b/app/views/mercury/modals/htmleditor.html.haml deleted file mode 100644 index f3598c4..0000000 --- a/app/views/mercury/modals/htmleditor.html.haml +++ /dev/null @@ -1,8 +0,0 @@ -= semantic_form_for 'htmlEditor', { html: { id: 'mercury_htmlEditor', style: 'width:650px' } } do |f| - - %textarea.mercury-modal-pane-container{ rows: '5' } - - .mercury-modal-controls - - = f.buttons do - = f.commit_button 'Save and Replace' diff --git a/app/views/mercury/modals/link.html.erb b/app/views/mercury/modals/link.html.erb new file mode 100644 index 0000000..a4f67c1 --- /dev/null +++ b/app/views/mercury/modals/link.html.erb @@ -0,0 +1,40 @@ +<%= semantic_form_for 'link', { :html => { :id => 'mercury_link', style: 'width:600px' } } do |f| %> + +
+
+ <%= f.inputs :id => 'link_text_container' do %> + <%= f.input :text, :required => false, :label => 'Link Content' %> + <% end %> + + <%= f.inputs 'Standard Links' do %> + <%= f.input :external_url, :required => false, :input_html => { :class => 'selectable' }, + :label => 'URL'.html_safe %> + <% end %> + + <%= f.inputs 'Index / Bookmark Links' do %> + <%= f.input :existing_bookmark, :as => :select, :required => false, :input_html => { :class => 'selectable' }, :include_blank => false, + :collection => [], + :label => 'Existing Links'.html_safe %> + <%= f.input :new_bookmark, :required => false, :input_html => { :class => 'selectable' }, + :label => 'Bookmark'.html_safe %> + <% end %> + + <%= f.inputs 'Options' do %> + <%= f.input :target, :as => :select, :required => false, :include_blank => 'Self (the same window or tab)', + :collection => [['Blank (a new window or tab)', '_blank'], ['Top (removes any frames)', '_top'], ['Popup Window (javascript new window popup)', 'popup']], + :label => 'Link Target' %> + + <% end %> +
+
+ +
+ <%= f.buttons do %> + <%= f.commit_button 'Insert Link' %> + <% end %> +
+ +<% end %> \ No newline at end of file diff --git a/app/views/mercury/modals/link.html.haml b/app/views/mercury/modals/link.html.haml deleted file mode 100644 index 424fad3..0000000 --- a/app/views/mercury/modals/link.html.haml +++ /dev/null @@ -1,31 +0,0 @@ -= semantic_form_for 'link', { html: { id: 'mercury_link', style: 'width:600px' } } do |f| - - .mercury-modal-pane-container - .mercury-modal-pane - - = f.inputs id: 'link_text_container' do - = f.input :text, required: false, label: 'Link Content' - - = f.inputs 'Standard Links' do - = f.input :external_url, required: false, input_html: { class: 'selectable' }, - label: 'URL'.html_safe - - = f.inputs 'Index / Bookmark Links' do - = f.input :existing_bookmark, as: :select, required: false, input_html: { class: 'selectable' }, collection: [], include_blank: false, - label: 'Existing Links'.html_safe - = f.input :new_bookmark, required: false, input_html: { class: 'selectable' }, - label: 'Bookmark'.html_safe - - = f.inputs 'Options' do - = f.input :target, as: :select, required: false, label: 'Link Target', - include_blank: 'Self (the same window or tab)', - collection: [['Blank (a new window or tab)', '_blank'], ['Top (removes any frames)', '_top'], ['Popup Window (javascript new window popup)', 'popup']] - - #popup_options.link-target-options{ style: 'display:none' } - = f.input :popup_width, required: false, label: 'Popup Width' - = f.input :popup_height, required: false, label: 'Popup Height' - - .mercury-modal-controls - - = f.buttons do - = f.commit_button 'Insert Link' diff --git a/app/views/mercury/modals/media.html.erb b/app/views/mercury/modals/media.html.erb new file mode 100644 index 0000000..2b84293 --- /dev/null +++ b/app/views/mercury/modals/media.html.erb @@ -0,0 +1,43 @@ +<%= semantic_form_for 'media', { :html => { :id => 'mercury_media', :style => 'width:600px' } } do |f| %> + +
+
+ <%= f.inputs 'Images' do %> + <%= f.input :image_url, :required => false, :input_html => { :class => 'selectable' }, + :label => 'URL'.html_safe %> + <% end %> + + <%= f.inputs 'Videos' do %> + <%= f.input :youtube_url, :required => false, :input_html => { :class => 'selectable' }, + :label => 'YouTube Share URL'.html_safe %> + <%= f.input :vimeo_url, :required => false, :input_html => { :class => 'selectable' }, + :label => 'Vimeo URL'.html_safe %> + <% end %> + + <%= f.inputs 'Options' do %> +
+ <%= f.input :image_alignment, :as => :select, :required => false, :include_blank => 'None', + :collection => [['Left', 'left'], ['Right', 'right'], ['Top', 'top'], ['Middle', 'middle'], ['Bottom', 'bottom'], ['Absolute Middle', 'absmiddle'], ['Absolute Bottom', 'absbottom']], + :label => 'Alignment' %> +
+ + + + + <% end %> +
+
+ +
+ <%= f.buttons do %> + <%= f.commit_button 'Insert Media' %> + <% end %> +
+ +<% end %> diff --git a/app/views/mercury/modals/media.html.haml b/app/views/mercury/modals/media.html.haml deleted file mode 100644 index 5fab05c..0000000 --- a/app/views/mercury/modals/media.html.haml +++ /dev/null @@ -1,33 +0,0 @@ -= semantic_form_for 'media', { html: { id: 'mercury_media', style: 'width:600px' } } do |f| - - .mercury-modal-pane-container - .mercury-modal-pane - - = f.inputs 'Images' do - = f.input :image_url, required: false, input_html: { class: 'selectable' }, - label: 'URL'.html_safe - - = f.inputs 'Videos' do - = f.input :youtube_url, required: false, input_html: { class: 'selectable' }, - label: 'YouTube Share URL'.html_safe - = f.input :vimeo_url, required: false, input_html: { class: 'selectable' }, - label: 'Vimeo URL'.html_safe - - = f.inputs 'Options' do - - #image_url.media-options - = f.input :image_alignment, as: :select, required: false, label: 'Alignment', include_blank: 'None', - collection: [['Left', 'left'], ['Right', 'right'], ['Top', 'top'], ['Middle', 'middle'], ['Bottom', 'bottom'], ['Absolute Middle', 'absmiddle'], ['Absolute Bottom', 'absbottom']] - - #youtube_url.media-options{ :style => 'display:none' } - = f.input :youtube_width, required: false, label: 'Width', input_html: { value: '560' } - = f.input :youtube_height, required: false, label: 'Height', input_html: { value: '349' } - - #vimeo_url.media-options{ :style => 'display:none' } - = f.input :vimeo_width, required: false, label: 'Width', input_html: { value: '400' } - = f.input :vimeo_height, required: false, label: 'Height', input_html: { value: '225' } - - .mercury-modal-controls - - = f.buttons do - = f.commit_button 'Insert Media' diff --git a/app/views/mercury/modals/sanitizer.html.erb b/app/views/mercury/modals/sanitizer.html.erb new file mode 100644 index 0000000..f7f912b --- /dev/null +++ b/app/views/mercury/modals/sanitizer.html.erb @@ -0,0 +1,5 @@ +
+
It looks like you've pasted directly from Microsoft Office!

Sadly though, your browser wasn't able to properly handle what you pasted. But that's ok, because I've sanitized it for you!
+ + You can just copy and paste the sanitized content that appears above. +
diff --git a/app/views/mercury/modals/sanitizer.html.haml b/app/views/mercury/modals/sanitizer.html.haml deleted file mode 100644 index 2f73a7e..0000000 --- a/app/views/mercury/modals/sanitizer.html.haml +++ /dev/null @@ -1,4 +0,0 @@ -#mercury_sanitizer{ style: 'width:450px' } - .information It looks like you've pasted directly from Microsoft Office!

Sadly though, your browser wasn't able to properly handle what you pasted. But that's ok, because I've sanitized it for you! - %textarea{ rows: '20', wrap: 'off' } - %strong You can just copy and paste the sanitized content that appears above. diff --git a/app/views/mercury/modals/table.html.erb b/app/views/mercury/modals/table.html.erb new file mode 100644 index 0000000..ac34014 --- /dev/null +++ b/app/views/mercury/modals/table.html.erb @@ -0,0 +1,66 @@ +<%= semantic_form_for 'table', { :html => { :id => 'mercury_table', :style => 'width:700px' } } do |f| %> + +
+
+ +
+ + + + + + + + + + + +
   
   
+
+ +
+ <%= f.inputs do %> +
  • + + + + +
  • +
  • + + + + +
  • +
    +
  • + + + +
  • +
  • + + + +
  • + <% end %> + + + <%= f.inputs 'Options' do %> + <%= f.input :alignment, :as => :select, :required => false, :include_blank => 'None', + :collection => [['Left', 'left'], ['Right', 'right']] %> + <%= f.input :border, :required => false, :input_html => { :value => 1 } %> + <%= f.input :spacing, :required => false, :input_html => { :value => 0 } %> + <% end %> +
    + +
    +
    + +
    + <%= f.buttons do %> + <%= f.commit_button 'Insert Table' %> + <% end %> +
    + +<% end %> diff --git a/app/views/mercury/modals/table.html.haml b/app/views/mercury/modals/table.html.haml deleted file mode 100644 index f2b29d4..0000000 --- a/app/views/mercury/modals/table.html.haml +++ /dev/null @@ -1,49 +0,0 @@ -= semantic_form_for 'table', { html: { id: 'mercury_table', style: 'width:700px' } } do |f| - - .mercury-modal-pane-container - .mercury-modal-pane - - #table_display - - %table{ border: 1, cellspacing: 0 } - %tr - %td   - %td   - %td   - %tr - %td   - %td   - %td   - - #table_options - = f.inputs do - %li{ class: "select input optional", id: "table_rows_input" } - %label{ for: "table_rows" } Rows - %input{ type: 'button', name: 'insertRowBefore', class: 'action', value: 'Add Before' }/ - %input{ type: 'button', name: 'insertRowAfter', class: 'action', value: 'Add After' }/ - %input{ type: 'button', name: 'deleteRow', class: 'action', value: 'Remove' }/ - %li{ class: "select input optional", id: "table_columns_input" } - %label{ for: "table_columns" } Columns - %input{ type: 'button', name: 'insertColumnBefore', class: 'action', value: 'Add Before' }/ - %input{ type: 'button', name: 'insertColumnAfter', class: 'action', value: 'Add After' }/ - %input{ type: 'button', name: 'deleteColumn', class: 'action', value: 'Remove' }/ - %hr - %li{ class: "select input optional", id: "table_row_adjust_input" } - %label{ for: "table_row_adjust" } Row Span - %input{ type: 'button', name: 'increaseRowspan', class: 'action', value: '+' }/ - %input{ type: 'button', name: 'decreaseRowspan', class: 'action', value: '-' }/ - %li{ class: "select input optional", id: "table_column_adjust_input" } - %label{ for: "table_column_adjust" } Column Span - %input{ type: 'button', name: 'increaseColspan', class: 'action', value: '+' }/ - %input{ type: 'button', name: 'decreaseColspan', class: 'action', value: '-' }/ - - = f.inputs 'Options' do - = f.input :alignment, as: :select, required: false, include_blank: 'None', - collection: [['Left', 'left'], ['Right', 'right']] - = f.input :border, required: false, input_html: { value: 1 } - = f.input :spacing, required: false, input_html: { value: 0 } - - .mercury-modal-controls - - = f.buttons do - = f.commit_button 'Insert Table' diff --git a/app/views/mercury/palettes/backcolor.html.erb b/app/views/mercury/palettes/backcolor.html.erb new file mode 100644 index 0000000..d9f6fd8 --- /dev/null +++ b/app/views/mercury/palettes/backcolor.html.erb @@ -0,0 +1,73 @@ +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    Last Color Picked
    +
    \ No newline at end of file diff --git a/app/views/mercury/palettes/backcolor.html.haml b/app/views/mercury/palettes/backcolor.html.haml deleted file mode 100644 index 6bf6996..0000000 --- a/app/views/mercury/palettes/backcolor.html.haml +++ /dev/null @@ -1,79 +0,0 @@ -.mercury-color-picker - .picker{ style: "background:#FFFFFF" } - .picker{ style: "background:#FFCCCC" } - .picker{ style: "background:#FFCC99" } - .picker{ style: "background:#FFFF99" } - .picker{ style: "background:#FFFFCC" } - .picker{ style: "background:#99FF99" } - .picker{ style: "background:#99FFFF" } - .picker{ style: "background:#CCFFFF" } - .picker{ style: "background:#CCCCFF" } - .picker{ style: "background:#FFCCFF" } - - .picker{ style: "background:#CCCCCC" } - .picker{ style: "background:#FF6666" } - .picker{ style: "background:#FF9966" } - .picker{ style: "background:#FFFF66" } - .picker{ style: "background:#FFFF33" } - .picker{ style: "background:#66FF99" } - .picker{ style: "background:#33FFFF" } - .picker{ style: "background:#66FFFF" } - .picker{ style: "background:#9999FF" } - .picker{ style: "background:#FF99FF" } - - .picker{ style: "background:#C0C0C0" } - .picker{ style: "background:#FF0000" } - .picker{ style: "background:#FF9900" } - .picker{ style: "background:#FFCC66" } - .picker{ style: "background:#FFFF00" } - .picker{ style: "background:#33FF33" } - .picker{ style: "background:#66CCCC" } - .picker{ style: "background:#33CCFF" } - .picker{ style: "background:#6666CC" } - .picker{ style: "background:#CC66CC" } - - .picker{ style: "background:#999999" } - .picker{ style: "background:#CC0000" } - .picker{ style: "background:#FF6600" } - .picker{ style: "background:#FFCC33" } - .picker{ style: "background:#FFCC00" } - .picker{ style: "background:#33CC00" } - .picker{ style: "background:#00CCCC" } - .picker{ style: "background:#3366FF" } - .picker{ style: "background:#6633FF" } - .picker{ style: "background:#CC33CC" } - - .picker{ style: "background:#666666" } - .picker{ style: "background:#990000" } - .picker{ style: "background:#CC6600" } - .picker{ style: "background:#CC9933" } - .picker{ style: "background:#999900" } - .picker{ style: "background:#009900" } - .picker{ style: "background:#339999" } - .picker{ style: "background:#3333FF" } - .picker{ style: "background:#6600CC" } - .picker{ style: "background:#993399" } - - .picker{ style: "background:#333333" } - .picker{ style: "background:#660000" } - .picker{ style: "background:#993300" } - .picker{ style: "background:#996633" } - .picker{ style: "background:#666600" } - .picker{ style: "background:#006600" } - .picker{ style: "background:#336666" } - .picker{ style: "background:#000099" } - .picker{ style: "background:#333399" } - .picker{ style: "background:#663366" } - - .picker{ style: "background:#000000" } - .picker{ style: "background:#330000" } - .picker{ style: "background:#663300" } - .picker{ style: "background:#663333" } - .picker{ style: "background:#333300" } - .picker{ style: "background:#003300" } - .picker{ style: "background:#003333" } - .picker{ style: "background:#000066" } - .picker{ style: "background:#330099" } - .picker{ style: "background:#330033" } - - .last-picked Last Color Picked diff --git a/app/views/mercury/palettes/forecolor.html.erb b/app/views/mercury/palettes/forecolor.html.erb new file mode 100644 index 0000000..d9f6fd8 --- /dev/null +++ b/app/views/mercury/palettes/forecolor.html.erb @@ -0,0 +1,73 @@ +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    Last Color Picked
    +
    \ No newline at end of file diff --git a/app/views/mercury/palettes/forecolor.html.haml b/app/views/mercury/palettes/forecolor.html.haml deleted file mode 100644 index 6bf6996..0000000 --- a/app/views/mercury/palettes/forecolor.html.haml +++ /dev/null @@ -1,79 +0,0 @@ -.mercury-color-picker - .picker{ style: "background:#FFFFFF" } - .picker{ style: "background:#FFCCCC" } - .picker{ style: "background:#FFCC99" } - .picker{ style: "background:#FFFF99" } - .picker{ style: "background:#FFFFCC" } - .picker{ style: "background:#99FF99" } - .picker{ style: "background:#99FFFF" } - .picker{ style: "background:#CCFFFF" } - .picker{ style: "background:#CCCCFF" } - .picker{ style: "background:#FFCCFF" } - - .picker{ style: "background:#CCCCCC" } - .picker{ style: "background:#FF6666" } - .picker{ style: "background:#FF9966" } - .picker{ style: "background:#FFFF66" } - .picker{ style: "background:#FFFF33" } - .picker{ style: "background:#66FF99" } - .picker{ style: "background:#33FFFF" } - .picker{ style: "background:#66FFFF" } - .picker{ style: "background:#9999FF" } - .picker{ style: "background:#FF99FF" } - - .picker{ style: "background:#C0C0C0" } - .picker{ style: "background:#FF0000" } - .picker{ style: "background:#FF9900" } - .picker{ style: "background:#FFCC66" } - .picker{ style: "background:#FFFF00" } - .picker{ style: "background:#33FF33" } - .picker{ style: "background:#66CCCC" } - .picker{ style: "background:#33CCFF" } - .picker{ style: "background:#6666CC" } - .picker{ style: "background:#CC66CC" } - - .picker{ style: "background:#999999" } - .picker{ style: "background:#CC0000" } - .picker{ style: "background:#FF6600" } - .picker{ style: "background:#FFCC33" } - .picker{ style: "background:#FFCC00" } - .picker{ style: "background:#33CC00" } - .picker{ style: "background:#00CCCC" } - .picker{ style: "background:#3366FF" } - .picker{ style: "background:#6633FF" } - .picker{ style: "background:#CC33CC" } - - .picker{ style: "background:#666666" } - .picker{ style: "background:#990000" } - .picker{ style: "background:#CC6600" } - .picker{ style: "background:#CC9933" } - .picker{ style: "background:#999900" } - .picker{ style: "background:#009900" } - .picker{ style: "background:#339999" } - .picker{ style: "background:#3333FF" } - .picker{ style: "background:#6600CC" } - .picker{ style: "background:#993399" } - - .picker{ style: "background:#333333" } - .picker{ style: "background:#660000" } - .picker{ style: "background:#993300" } - .picker{ style: "background:#996633" } - .picker{ style: "background:#666600" } - .picker{ style: "background:#006600" } - .picker{ style: "background:#336666" } - .picker{ style: "background:#000099" } - .picker{ style: "background:#333399" } - .picker{ style: "background:#663366" } - - .picker{ style: "background:#000000" } - .picker{ style: "background:#330000" } - .picker{ style: "background:#663300" } - .picker{ style: "background:#663333" } - .picker{ style: "background:#333300" } - .picker{ style: "background:#003300" } - .picker{ style: "background:#003333" } - .picker{ style: "background:#000066" } - .picker{ style: "background:#330099" } - .picker{ style: "background:#330033" } - - .last-picked Last Color Picked diff --git a/app/views/mercury/panels/history.html.haml b/app/views/mercury/panels/history.html.erb similarity index 100% rename from app/views/mercury/panels/history.html.haml rename to app/views/mercury/panels/history.html.erb diff --git a/app/views/mercury/panels/notes.html.haml b/app/views/mercury/panels/notes.html.erb similarity index 100% rename from app/views/mercury/panels/notes.html.haml rename to app/views/mercury/panels/notes.html.erb diff --git a/app/views/mercury/panels/snippets.html.erb b/app/views/mercury/panels/snippets.html.erb new file mode 100644 index 0000000..8ad89be --- /dev/null +++ b/app/views/mercury/panels/snippets.html.erb @@ -0,0 +1,12 @@ +
    +
    + +
    + +
    diff --git a/app/views/mercury/panels/snippets.html.haml b/app/views/mercury/panels/snippets.html.haml deleted file mode 100644 index 10632f8..0000000 --- a/app/views/mercury/panels/snippets.html.haml +++ /dev/null @@ -1,10 +0,0 @@ -.mercury-snippet-panel - - .filter - %input.filter{ :type => 'text' } - - %ul - %li{ 'data-filter' => "example-snippet" } - = image_tag('mercury/default-snippet.png', 'data-snippet' => 'example' ) - %h4 Snippet Name - .description A one to two line long description of what this snippet does. diff --git a/app/views/mercury/selects/formatblock.html.erb b/app/views/mercury/selects/formatblock.html.erb new file mode 100644 index 0000000..bb48b56 --- /dev/null +++ b/app/views/mercury/selects/formatblock.html.erb @@ -0,0 +1,11 @@ +
    +

    Heading 1 <h1>

    +

    Heading 2 <h2>

    +

    Heading 3 <h3>

    +

    Heading 4 <h4>

    +
    Heading 5 <h5>
    +
    Heading 6 <h6>
    +
    Paragraph <p>
    +
    Blockquote <blockquote>
    +
    Formatted <pre>
    +
    diff --git a/app/views/mercury/selects/formatblock.html.haml b/app/views/mercury/selects/formatblock.html.haml deleted file mode 100644 index c75f2df..0000000 --- a/app/views/mercury/selects/formatblock.html.haml +++ /dev/null @@ -1,10 +0,0 @@ -.mercury-select-options - %h1{ data: {tag: "h1"} } Heading 1 <h1> - %h2{ data: {tag: "h2"} } Heading 2 <h2> - %h3{ data: {tag: "h3"} } Heading 3 <h3> - %h4{ data: {tag: "h4"} } Heading 4 <h4> - %h5{ data: {tag: "h5"} } Heading 5 <h5> - %h6{ data: {tag: "h6"} } Heading 6 <h6> - %div{ data: {tag: "p"} } Paragraph <p> - %div{ data: {tag: "blockquote"} } Blockquote <blockquote> - %div{ data: {tag: "pre"} } Formatted <pre> diff --git a/app/views/mercury/selects/style.html.erb b/app/views/mercury/selects/style.html.erb new file mode 100644 index 0000000..8804473 --- /dev/null +++ b/app/views/mercury/selects/style.html.erb @@ -0,0 +1,5 @@ +
    +
    Red text
    +
    Large bold text
    +
    Blue background
    +
    diff --git a/app/views/mercury/selects/style.html.haml b/app/views/mercury/selects/style.html.haml deleted file mode 100644 index 0f55ded..0000000 --- a/app/views/mercury/selects/style.html.haml +++ /dev/null @@ -1,4 +0,0 @@ -.mercury-select-options - .red{ data: {class: "red"} } Red text - .large-bold{ data: {class: "large-bold"} } Large bold text - .blue{ data: {class: "blue"} } Blue background diff --git a/app/views/mercury/snippets/example.html.erb b/app/views/mercury/snippets/example.html.erb new file mode 100644 index 0000000..7897e56 --- /dev/null +++ b/app/views/mercury/snippets/example.html.erb @@ -0,0 +1 @@ +<%= params[:options][:first_name] %> likes<%= params[:options][:favorite_beer] %> \ No newline at end of file diff --git a/app/views/mercury/snippets/example.html.haml b/app/views/mercury/snippets/example.html.haml deleted file mode 100644 index 2f6b816..0000000 --- a/app/views/mercury/snippets/example.html.haml +++ /dev/null @@ -1,2 +0,0 @@ -%strong= params[:options][:first_name] -= " likes #{params[:options][:favorite_beer]}" \ No newline at end of file diff --git a/app/views/mercury/snippets/example_options.html.erb b/app/views/mercury/snippets/example_options.html.erb new file mode 100644 index 0000000..35a5483 --- /dev/null +++ b/app/views/mercury/snippets/example_options.html.erb @@ -0,0 +1,23 @@ +<% @options = params[:options] || {} %> +<%= semantic_form_for 'options', { :html => { :style => 'width:600px' } } do |f| %> + +
    +
    + <%= f.inputs do %> + <%= f.input :first_name, :required => false, :label => 'First Name', + :input_html => {:value => @options[:first_name] || 'First Name'} %> + <% end %> + <%= f.inputs 'Options' do %> + <%= f.input :favorite_beer, :required => false, :label => 'Favorite Beer', + :input_html => {:value => @options[:favorite_beer] || 'PBR'} %> + <% end %> +
    +
    + +
    + <%= f.buttons do %> + <%= f.commit_button 'Insert Snippet' %> + <% end %> +
    + +<% end %> diff --git a/app/views/mercury/snippets/example_options.html.haml b/app/views/mercury/snippets/example_options.html.haml deleted file mode 100644 index 77cb50d..0000000 --- a/app/views/mercury/snippets/example_options.html.haml +++ /dev/null @@ -1,18 +0,0 @@ -- @options = params[:options] || {} -= semantic_form_for 'options', { html: { style: 'width:600px' } } do |f| - - .mercury-modal-pane-container - .mercury-modal-pane - - = f.inputs do - = f.input :first_name, required: false, label: 'First Name', - input_html: {value: @options[:first_name] || 'First Name'} - - = f.inputs 'Options' do - = f.input :favorite_beer, required: false, label: 'Favorite Beer', - input_html: {value: @options[:favorite_beer] || 'PBR'} - - .mercury-modal-controls - - = f.buttons do - = f.commit_button 'Insert Snippet' diff --git a/config/application.rb b/config/application.rb index d29ac1d..e9ad04a 100644 --- a/config/application.rb +++ b/config/application.rb @@ -11,6 +11,8 @@ class Application < Rails::Application require 'mercury-rails' require "#{root}/lib/mercury-rails" + config.secret_token = 'a3d5cd98078f032a81a26868464e582207929ed489825cc2259c1c92e86782698ee37e50d7de9c0d300900a1f523a2f3d153b90c104415ebd6b77dcabef7aae5' + # Settings in config/environments/* take precedence over those specified here. # Application configuration should go into files in config/initializers # -- all .rb files in that directory are automatically loaded. diff --git a/config/initializers/secret_token.rb b/config/initializers/secret_token.rb deleted file mode 100644 index e431a8c..0000000 --- a/config/initializers/secret_token.rb +++ /dev/null @@ -1,7 +0,0 @@ -# Be sure to restart your server when you modify this file. - -# Your secret key for verifying the integrity of signed cookies. -# If you change this key, all old signed cookies will become invalid! -# Make sure the secret is at least 30 characters and all random, -# no regular words or you'll be exposed to dictionary attacks. -Mercury::Application.config.secret_token = 'a3d5cd98078f032a81a26868464e582207929ed489825cc2259c1c92e86782698ee37e50d7de9c0d300900a1f523a2f3d153b90c104415ebd6b77dcabef7aae5' if defined?(Mercury::Application) diff --git a/config/routes.rb b/config/routes.rb index 4477a6a..111324c 100644 --- a/config/routes.rb +++ b/config/routes.rb @@ -10,6 +10,6 @@ end if defined?(Mercury::Application) - root to: "application#show" + root :to => "application#show" end end