aboutsummaryrefslogtreecommitdiffstats
path: root/actionpack/test/template/asset_tag_helper_test.rb
Commit message (Collapse)AuthorAgeFilesLines
* Compare host scheme using case-insensitive regexpRafael Mendonça França2013-06-161-10/+30
| | | | | | | | | | | | | | | | | | Before: image_tag("HTTP://google.com") # => "<img alt=\"Google\" src=\"/assets/HTTP://google.com\" />" image_tag("http://google.com") # => "<img alt=\"Google\" src=\"http://google.com\" />" After: image_tag("HTTP://google.com") # => "<img alt=\"Google\" src=\"HTTP://google.com\" />" image_tag("http://google.com") # => "<img alt=\"Google\" src=\"http://google.com\" />" Backport of #10969
* Do not include application.js if it doesn't existsPrem Sichanugrist2012-08-061-0/+9
| | | | | | Rails were including 'application.js' to the pack when using `javascript_include_tag :all` even there's no application.js in the public directory.
* html_escape should escape single quotesSantiago Pastorino2012-08-021-8/+8
| | | | | | | | | | | | https://www.owasp.org/index.php/XSS_%28Cross_Site_Scripting%29_Prevention_Cheat_Sheet#RULE_.231_-_HTML_Escape_Before_Inserting_Untrusted_Data_into_HTML_Element_Content Closes #7215 Conflicts: actionpack/test/template/erb_util_test.rb actionpack/test/template/form_tag_helper_test.rb actionpack/test/template/text_helper_test.rb actionpack/test/template/url_helper_test.rb activesupport/lib/active_support/core_ext/string/output_safety.rb
* Revert "Deprecate `:mouseover` options for `image_tag` helper."Rafael Mendonça França2012-08-011-40/+8
| | | | | | | This reverts commit 1aff7725c7a04cde202cca906208560a55409e6a. Conflicts: actionpack/CHANGELOG.md
* Revert "Deprecate `:confirm` in favor of `:data => { :confirm => 'Text' }` ↵Rafael Mendonça França2012-08-011-8/+8
| | | | | | | | | | | option" Revert "Deprecate `:disable_with` in favor of `'data-disable-with'` option for `button_to` and `submit_tag` helpers." This reverts commit fc092a9cba5fceec38358072e50e09250cf58840. This reverts commit e9051e20aeb2c666db06b6217954737665878db7. This reverts commit d47d6e7eda3aa3e6aa28d0c17ac6801234bb97d1. This reverts commit 21141e777bdce8534e3755c8de7268324b3d8714.
* It should also include text/css => Build FixArun Agrawal2012-06-161-1/+1
|
* Merge pull request #6752 from steveklabnik/fix_5680Rafael Mendonça França2012-06-161-3/+11
| | | | Respect absolute paths in compute_source_path.
* Merge pull request #5020 from KL-7/fix-blank-image_tag-sourceJosé Valim2012-05-181-0/+1
| | | | Render img tag with empty src if empty string is passed to image_tag.
* Fix typoCarlos Galdino + Rafael Mendonça França2012-05-141-8/+8
|
* Deprecate `:mouseover` options for `image_tag` helper.Rafael Mendonça França2012-05-131-8/+40
|
* Merge pull request #3237 from sakuro/data-url-schemeRafael Mendonça França2012-05-131-1/+2
| | | | Support data: url scheme
* escape options for the stylesheet_link_tag methodAlexey Vakhov2011-09-251-0/+4
|
* Use shorter class-level File methods instead of going through File.stat.thedarkone2011-07-251-2/+2
|
* Changed a few instances of of words in the API docs written in British ↵Oemuer Oezkir2011-07-241-1/+1
| | | | | | English to American English(according to Weber)
* use Zlib.crc2 rather that bytes.sum, as per Aaron's suggestionXavier Noria2011-07-081-1/+2
| | | | | | That integer is rather irrelevant, the only thing that matters is that it is consistent and with no apparent bias. Zlib.crc32 is 8-10 times faster than bytes.sum, so use that.
* removing brittle assertionAaron Patterson2011-07-071-1/+0
|
* Using the sum of bytes instead the hash of the path when replacing the ↵Albert Callarisa Roca2011-07-081-2/+3
| | | | wildcard of the assets path because in ruby 1.9 is not consistent
* Merge pull request #1870 from chriseppstein/asset_urls_masterSantiago Pastorino2011-06-271-10/+20
|\ | | | | Asset urls master
| * Added a configuration setting:Chris Eppstein2011-06-271-6/+16
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | config.action_controller.default_asset_host_protocol It's best to leave this unset. When unset the :request protocol is used whenever it can be and :relative is used in the other situations. When set to :request then assets hosts will be disabled when there is no request in scope and will use the request protocol whenever a request is in scope. If set to :relative, then a relative protocol is always used except for stylesheet link tags which must use the :request protocol to avoid double downloads in IE6&7. Conflicts: actionpack/lib/sprockets/helpers/rails_helper.rb actionpack/test/template/sprockets_helper_test.rb
| * Stylesheet link tags should use the request protocol to avoid duplicate ↵Chris Eppstein2011-06-271-8/+8
| | | | | | | | | | | | | | | | | | download of stylesheets in IE7 and IE8. Conflicts: actionpack/lib/action_view/helpers/asset_tag_helpers/stylesheet_tag_helpers.rb actionpack/lib/sprockets/helpers/rails_helper.rb
| * Add asset_url helper and refactor the asset paths so that asset hosts can be ↵Chris Eppstein2011-06-271-4/+4
| | | | | | | | | | | | | | | | | | | | used during asset precompilation. Conflicts: actionpack/lib/action_view/asset_paths.rb actionpack/lib/sprockets/helpers/rails_helper.rb actionpack/test/template/sprockets_helper_test.rb
* | the generated ALT attribute for images no longer contains the digest, if anyXavier Noria2011-06-271-0/+8
|/
* asset helpers should understand scheme-relative URLsChad Krsek2011-04-261-0/+15
|
* Revert "asset helpers should understand scheme-relative URLs"Chad Krsek2011-04-251-15/+0
| | | | This reverts commit 057412ce38ead06307a887dca333837a99f84f22.
* asset helpers should understand scheme-relative URLsChad Krsek2011-04-251-0/+15
|
* Make static faster as we don't have to serve multiple paths anymore.José Valim2011-04-151-23/+0
|
* javascript_include_tag shouldn't raise if you register an expansion key with ↵Santiago Pastorino2011-02-281-2/+10
| | | | nil value
* Add tests for register expansion methods with key = []Santiago Pastorino2011-02-281-2/+12
|
* Applied changes to stylesheet_link_tag from javascript_include_tag which ↵Josh Kalderimis2011-02-131-0/+23
| | | | corrects issues with ordering and duplicates.
* This corrects two issues with javascript_include_tag, the order at which ↵Josh Kalderimis2011-02-131-1/+24
| | | | | | | | they are expanded, and removing duplicates. When individual js assets are specified, they will override the order of the same asset specified in an expansion. [#5938 state:resolved]
* Allow registering javascript/stylesheet_expansions to existing symbolsSantiago Pastorino2010-12-221-0/+19
|
* Do not use the same hash instance for expansions [#6114 state:resolved]Piotr Sarnacki2010-12-221-0/+8
| | | | | Using the same hash instance makes using the same expansions for both javascripts and stylesheets.
* Fix AssetIncludeTag ensuring that files are in the wrong directory [#6015 ↵Henning Koch2010-11-191-0/+44
| | | | | | state:resolved] Signed-off-by: Santiago Pastorino <santiago@wyeworks.com>
* incorporated most of the feedback from JoséJosh Kalderimis2010-11-161-2/+2
|
* removed an assert from a test as it was testing a private methodJosh Kalderimis2010-11-161-1/+0
|
* provide better error message if path is uri [#5914 state:resolved]Neeraj Singh2010-11-111-0/+11
| | | | Signed-off-by: José Valim <jose.valim@gmail.com>
* Use parentheses when using assert_match followed by a regexp to avoid warnings.Emilio Tagua2010-09-271-1/+1
|
* application.js should be the last file on javascript_include_tag(:all)Santiago Pastorino2010-09-191-8/+8
|
* Added ability to set asset_path for enginesPiotr Sarnacki2010-09-031-0/+23
|
* Tidy up asset tag a bit and make railties tests green again.José Valim2010-06-231-2/+2
|
* refactored the javascript asset tag helpers and moved the default scripts ↵Josh Kalderimis2010-06-231-15/+7
| | | | | | setup within the railtie Signed-off-by: José Valim <jose.valim@gmail.com>
* Updating image_tag to support cid:content_id "URLs"Mikel Lindsaar2010-06-071-0/+9
|
* Accept :alt => nil on image_tag [#4558 state:resolved]Marc-Andre Lafortune2010-05-151-1/+2
| | | | Signed-off-by: José Valim <jose.valim@gmail.com>
* adds #favicon_link_tag back, rdoc explains why it is useful, and how to get ↵Xavier Noria2010-04-081-0/+12
| | | | a link for Mobile Safari with it
* Revert "adds #favicon_link_tag and #apple_touch_icon_link_tag" -- these tags ↵David Heinemeier Hansson2010-04-081-20/+0
| | | | | | are too specific. This reverts commit 6891f46d10957f21f200fc4dc2b6076ff411b1da, ec8610cfdc32d0fe816fb22405e00ef1b6c90d73, and d18ff1b7efd96e7c08bc1a15137735be45f87e07.
* adds a default source to #apple_touch_icon_link_tagXavier Noria2010-04-071-0/+1
|
* new helpers #favicon_link_tag and #apple_touch_icon_link_tagXavier Noria2010-04-071-0/+19
|
* Refactored url_for in AV to have its own instances of the helpers instead of ↵wycats2010-04-031-15/+11
| | | | proxying back to the controller. This potentially allows for more standalone usage of AV. It also kicked up a lot of dust in the tests, which were mocking out controllers to get this behavior. By moving it to the view, it made a lot of the tests more standalone (a win)
* Updated asset_template_path to asset_path and have it also support a String ↵wycats2010-03-281-1/+8
| | | | [#4247 state:resolved]
* Allow customisation of asset path generation using a proc.Craig R Webster2010-03-281-0/+9
| | | | | | | | | | | | | | | | Set config.action_controller.asset_path_template to a proc that takes one argument - the direct, unchanged asset path - and returns a path to that asset using the scheme that your assets require. This is useful if you have a setup which scales by introducing new application servers where the mtime of the asset files may not be the same as those of the asset files on your previous servers, but it does require your web servers to have knowledge of the asset template paths that you rewrite to so it's not suitable for out-of-the-box use. An example of configuring asset path generation and rewriting these paths using Apache is included in actionpack/lib/action_view/helpers/asset_tag_helper.rb. Signed-off-by: wycats <wycats@gmail.com>