Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorFilipa Lacerda <filipa@gitlab.com>2017-09-07 12:26:51 +0300
committerFilipa Lacerda <filipa@gitlab.com>2017-09-07 12:26:51 +0300
commit38bcf699abf1f8cec7b4e11c914e1baae57f9b81 (patch)
treec76bf0a8ba84869abf7e02a5e1372a27d04bbed8 /app/assets/javascripts/settings_panels.js
parentedfb5d7b16f064519c7408eb69dd125726b0c652 (diff)
Get the project path through the DOM instead of `gon`
Open the settings section based on the location hash
Diffstat (limited to 'app/assets/javascripts/settings_panels.js')
-rw-r--r--app/assets/javascripts/settings_panels.js4
1 files changed, 4 insertions, 0 deletions
diff --git a/app/assets/javascripts/settings_panels.js b/app/assets/javascripts/settings_panels.js
index 7fa5996d600..8635ccece6e 100644
--- a/app/assets/javascripts/settings_panels.js
+++ b/app/assets/javascripts/settings_panels.js
@@ -41,4 +41,8 @@ export default function initSettingsPanels() {
$section.on('click.toggleSection', '.js-settings-toggle', () => toggleSection($section));
$section.find('.settings-content:not(.expanded)').on('scroll.expandSection', () => expandSection($section));
});
+
+ if (location.hash) {
+ expandSection($(location.hash));
+ }
}