Patch #42515 » 0003-Rename-app-assets-application.js-to-application-legacy.js-keeping-app-javascript-application.js-default.patch
| app/helpers/application_helper.rb | ||
|---|---|---|
|
if Setting.wiki_tablesort_enabled?
|
||
|
tags << javascript_include_tag('tablesort-5.2.1.min.js', 'tablesort-5.2.1.number.min.js')
|
||
|
end
|
||
|
tags << javascript_include_tag('application', 'responsive')
|
||
|
tags << javascript_include_tag('application-legacy', 'responsive')
|
||
|
unless User.current.pref.warn_on_leaving_unsaved == '0'
|
||
|
warn_text = escape_javascript(l(:text_warn_on_leaving_unsaved))
|
||
|
tags <<
|
||
| app/javascript/controllers/quote_reply_controller.js | ||
|---|---|---|
|
static targets = [ 'content' ];
|
||
|
quote(event) {
|
||
|
event.preventDefault();
|
||
|
const { url, textFormatting } = event.params;
|
||
|
const selectedRange = QuoteExtractor.extract(this.contentTarget);
|
||
| app/views/layouts/base.html.erb | ||
|---|---|---|
|
<%= favicon %>
|
||
|
<%= stylesheet_link_tag 'jquery/jquery-ui-1.13.2', 'tribute-5.1.3', 'application', 'responsive', :media => 'all' %>
|
||
|
<%= stylesheet_link_tag 'rtl', :media => 'all' if l(:direction) == 'rtl' %>
|
||
|
<%= javascript_importmap_tags 'main' %>
|
||
|
<%= javascript_importmap_tags %>
|
||
|
<%= javascript_heads %>
|
||
|
<%= heads_for_theme %>
|
||
|
<%= heads_for_auto_complete(@project) %>
|
||
| config/importmap.rb | ||
|---|---|---|
|
# Pin npm packages by running ./bin/importmap
|
||
|
pin "main"
|
||
|
pin "application"
|
||
|
pin "@hotwired/stimulus", to: "stimulus.min.js"
|
||
|
pin "@hotwired/stimulus-loading", to: "stimulus-loading.js"
|
||
|
pin_all_from "app/javascript/controllers", under: "controllers"
|
||