Commit Graph

83 Commits

Author SHA1 Message Date
GitLab Bot aad3ac9e5e Add latest changes from gitlab-org/gitlab@master 2021-04-26 15:10:20 +00:00
GitLab Bot 0ff373dc41 Add latest changes from gitlab-org/gitlab@master 2020-12-15 15:09:59 +00:00
GitLab Bot 2ac4833015 Add latest changes from gitlab-org/gitlab@master 2020-10-08 18:08:32 +00:00
GitLab Bot 207ec5c078 Add latest changes from gitlab-org/gitlab@master 2020-07-12 09:09:08 +00:00
GitLab Bot 340fd2966e Add latest changes from gitlab-org/gitlab@master 2020-06-04 00:08:17 +00:00
GitLab Bot 41e8b05e8d Add latest changes from gitlab-org/gitlab@master 2020-05-13 12:07:54 +00:00
GitLab Bot c74b7b5e43 Add latest changes from gitlab-org/gitlab@master 2020-04-28 12:09:44 +00:00
GitLab Bot db061f4432 Add latest changes from gitlab-org/gitlab@master 2020-04-22 18:09:52 +00:00
GitLab Bot 2c72daf2f1 Add latest changes from gitlab-org/gitlab@master 2020-03-30 18:08:07 +00:00
GitLab Bot 85e494935a Add latest changes from gitlab-org/gitlab@master 2020-01-14 15:07:55 +00:00
GitLab Bot 190e204dec Add latest changes from gitlab-org/gitlab@master 2019-11-17 12:06:19 +00:00
GitLab Bot 8f210aebe1 Add latest changes from gitlab-org/gitlab@master 2019-10-31 21:06:28 +00:00
GitLab Bot 8c7eab92cd Add latest changes from gitlab-org/gitlab@master 2019-10-23 03:06:01 +00:00
Luke Duncalfe 93a618f0e5 New wiki page redirects user to random slug
Previously we asked a user to enter a new slug before taking them to
the Create Page page.

As a UX improvement, we now take them to a randomly generated URI so
they can begin creating their new page.

https://gitlab.com/gitlab-org/gitlab-ce/issues/46299
2019-08-21 09:33:12 +12:00
Alex Kalderimis c03ae6201f Allowing all users to view history
This removes the create_wiki permission check from the history
controller, allowing show and history to have the same level of
permissions.

Fixes https://gitlab.com/gitlab-org/gitlab-ce/issues/29528
2019-07-23 22:40:23 +00:00
George Thomas a9707e8cf7
Rewrite `if:` argument in before_action and alike when `only:` is also used
Closes #55564
This is first discovered in #54739 (comment 122609857) that if both if: and only:
are used in a before_action or after_action or alike, if: is completely ignored.
2019-07-18 10:04:06 +05:30
Francisco Javier López dde69bfb2a Added list_pages method to avoid loading all wiki pages content
Inside a wiki, when we show the sidebar or browse to the `pages`,
all page contents are retrieved from Gitaly and that is a waste
of resources, since no content from that pages are going to be
showed.

This MR introduces the method `ProjectWiki#list_pages`,
which uses new wiki_list_pages RPC call to retrieve
pages without content

Also in the `WikisController` we're using the method to show
pages in the sidebar and also on the `pages` page.
2019-04-25 04:19:07 +00:00
Igor 866b58a54e Allow to sort wiki pages by date and title
- Add controls for sorting by title and date
- Execute Gitaly call which now accepts sorting params for wikis
2019-04-04 16:28:56 +00:00
Martin Wortschack 5660690787 Externalize strings in projects controllers
- concerns
- dashboard
- groups
- import
2019-03-27 16:52:52 +00:00
Francisco Javier López b8cf360e2a Fixed bug with the content disposition with wiki attachments 2018-10-17 15:47:05 +00:00
gfyoung 12ee2753c1 Enable even more frozen string in app/controllers
Enables frozen string for some vestigial files as
well as the following:

* app/controllers/projects/**/*.rb
* app/controllers/sherlock/**/*.rb
* app/controllers/snippets/**/*.rb
* app/controllers/users/**/*.rb

Partially addresses #47424.
2018-09-25 22:43:49 -07:00
Francisco Javier López ade320d2db Fix bug with Wiki pages encoding 2018-07-31 06:08:19 +00:00
Stan Hu c8ff6b7c73 Use limit parameter to retrieve Wikis from Gitaly
Without this parameter, every load of a Wiki page will load all the Wiki pages
in the repository for the sidebar. This is a significant performance penalty
that can significant slow the display of all Wiki pages.

Relates to #40101
2018-07-24 15:36:31 -07:00
Lin Jen-Shin d9f26586b4 Merge remote-tracking branch 'upstream/master' into 14995-custom_wiki_sidebar
* upstream/master: (467 commits)
  Update docs board features tier
  Upgrade grape-path-helpers to 1.0.6
  Remove healthchecks from prometheus endpoint
  Fix find_branch call sites
  Ensure Encoding.default_external is set to UTF-8 when running QA scenarios
  i18n: externalize strings from 'app/views/admin/groups'
  Backport mr widget changes from EE
  Allow to toggle notifications for issues due soon
  Vuex test helper improvements
  whitespace
  Make more ref RPC's mandatory
  Resolve "Improve performance of MR Changes tab: reduce event listeners on scroll event"
  Remove old service architecture from Vue docs
  Adding spec to test basic forking functionalities
  Fix performance problem of accessing tag list for projects api endpoints
  typo
  Add sleep to QA test before installing tiller
  Include Vue files that are not covered by tests in test coverage
  Remove Repository#path memoization
  Resolve "do not set updated_at when creating note"
  ...
2018-07-13 17:34:27 +08:00
Lin Jen-Shin 9286f5b934 Use stable gitlab-styles and eliminate offenses 2018-07-09 21:13:08 +08:00
Lin Jen-Shin 4ee08b77bc Updates from `rubocop -a` 2018-07-09 21:13:08 +08:00
Lin Jen-Shin 849f9995d9 Merge remote-tracking branch 'upstream/master' into 14995-custom_wiki_sidebar
* upstream/master: (4180 commits)
  Enable frozen string literals for app/workers/*.rb
  Resolve "Search dropdown hides & shows when typing"
  Revert merge request widget button max height
  Update CHANGELOG.md for 11.0.2
  Update external link icon in header user dropdown
  Added Diff Viewer to new VUE based MR page
  Fixed eslint failure in IDE spec helpers
  Use refs instead of querySelector.
  Show file in tree on WebIDE open
  Resolve "Remove unused bootstrap component CSS"
  Resolve "Explain what Groups are in the New Group page"
  [QA] Make sure we wait for the deploy key list to load
  Update _scopes_form.html.haml to remove duplicate information
  Use the branch instead of the tag to install
  port the EE changes
  Add index on deployable_type/id for deployments
  Add a helper to rename a column using a background migration
  Fix performance bottleneck when rendering large wiki pages
  Port Namespace#root_ancestor to CE
  Remove duplicate spec
  ...
2018-06-27 16:15:06 +08:00
Lin Jen-Shin 74b5c4daf9 Bring changes from EE 2018-06-26 01:33:12 +08:00
Paul Slaughter 67199aed62 Add helpful messages to empty wiki view 2018-05-29 07:28:49 +00:00
Francisco Javier López e8a27a67fa Fix Custom hooks are not triggered by UI wiki edit 2018-04-18 17:50:56 +00:00
Lin Jen-Shin ef6b3e0271 Introduce #find_sidebar and use a constant to find the page 2018-03-26 17:16:01 +08:00
Lin Jen-Shin 44e4fd0b1c Avoid loading default sidebar if there's a customized one 2018-03-26 16:13:43 +08:00
Joshua Sooter 4333fbf2e4 Added support for custom wiki sidebar using _sidebar.md in the wiki root. If _sidebar.md exists it will be parsed and rendered otherwise the default sidebar file list will display
deleted _sidebar_custom.html.haml and modified _sidebar.html.haml to check for sidebar_page and render it or the default wiki page list. Also removed white space.

fix indent in show.html.haml

restore newline at end of ile

Add a newline at the end of changelogs/custom_wiki_sidebar.yml
2018-03-23 00:30:54 +08:00
Douwe Maan 5db5a9cbd1 Merge branch 'master' into 'zj-wiki-page-versions'
# Conflicts:
#   Gemfile
#   Gemfile.lock
2018-02-06 16:08:06 +00:00
Francisco Javier López 27c08a1689 Allow moving wiki pages from the UI 2018-02-05 17:17:21 +00:00
Zeger-Jan van de Weg 1c0437d95e
Client implementation for WikiPageVerion
Part of gitlab-org/gitaly#639
2018-01-22 10:08:46 +01:00
Rémy Coutable 4f09d099e9 Merge branch '18040-rubocop-line-break-after-guard-clause' into 'master'
Adds Rubocop rule for line break after guard clause

Closes #18040

See merge request gitlab-org/gitlab-ce!15188
2017-11-20 09:22:14 +00:00
Francisco Javier López ff26ea818c Resolve "Performance issues when loading large number of wiki pages" 2017-11-17 11:48:32 +00:00
Jacopo 181cd299f9 Adds Rubocop rule for line break after guard clause
Adds a rubocop rule (with autocorrect) to ensure line break after guard clauses.
2017-11-16 17:58:29 +01:00
Vitaliy @blackst0ne Klachkov 64bb19069d Add support for markdown preview to group milestones 2017-10-11 20:03:19 +11:00
Jacob Vosmaer (GitLab) 5dd26d4e5a Hide Gollum inside Gitlab::Git::Wiki 2017-10-03 16:58:33 +00:00
Hiroyuki Sato 9b25bbc45d Merge branch 'master' into 1827-prevent-concurrent-editing-wiki
Conflicts:
	app/controllers/projects/wikis_controller.rb
	app/views/projects/wikis/edit.html.haml
	spec/features/projects/wiki/user_updates_wiki_page_spec.rb
2017-07-23 21:26:02 +09:00
Douwe Maan fe13f11041 Create and use project path helpers that only need a project, no namespace 2017-07-05 11:11:59 -05:00
blackst0ne a544e46bb0 Add a rubocop rule to check if a method 'redirect_to' is used without explicitly set 'status' in 'destroy' actions of controllers 2017-06-07 09:45:16 +11:00
Rares Sfirlogea 45e4c66565 Display slash commands outcome when previewing Markdown
Remove slash commands from Markdown preview and display their outcome next to
the text field.
Introduce new "explanation" block to our slash commands DSL.
Introduce optional "parse_params" block to slash commands DSL that allows to
process a parameter before it is passed to "explanation" or "command" blocks.
Pass path for previewing Markdown as "data" attribute instead of setting
a variable on "window".
2017-05-04 17:02:25 +02:00
Jarka Kadlecova 87327c5845 Support preview_markdown action for personal_snippets 2017-04-26 12:51:06 +02:00
Keifer Furzland ddd97f3c91
Update wikis_controller.rb to use strong params 2017-03-25 20:57:32 -05:00
Dongqing Hu 2dd9b8a38a Fix Project Wiki update 2017-03-20 13:53:23 +00:00
Rémy Coutable c5e34da01d
Remove explicit `require` calls, and use `require_dependency` when needed
See
http://guides.rubyonrails.org/autoloading_and_reloading_constants.html
for more info.

Signed-off-by: Rémy Coutable <remy@rymai.me>
2017-03-13 14:29:55 +01:00
Hiroyuki Sato a5521bad40 Prevent concurrent editing wiki 2017-03-08 18:42:50 +09:00