Valery Sizov
7b327b68e3
Merge remote-tracking branch 'origin/master' into ce_upstream
2015-12-01 19:54:45 +02:00
Valery Sizov and Valery Sizov
7f214cee74
Migrate mailers to ActiveJob
2015-11-26 17:03:43 +02:00
Valery Sizov
18c7336892
Merge remote-tracking branch 'origin/master' into ce_upstream
2015-11-24 18:06:46 +02:00
Dmitriy Zaporozhets
49e32cb59f
Remove small code duplication in user_reference_filter.rb
...
Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com >
2015-11-17 12:55:16 +01:00
Dmitriy Zaporozhets
79fa6c646c
Remove duplication in reference filters
...
Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com >
2015-11-16 23:56:16 +01:00
Valery Sizov
0d9e08a891
Merge branch 'master' into ce-to-ee
2015-11-16 10:12:23 +02:00
Alec Cooper
4bb99677b1
Relative links in the README file shown on the repository homepage should point
...
to the default branch, not to master
2015-11-14 15:00:55 -05:00
Valery Sizov
93bcc9ca7f
Merge remote-tracking branch 'origin/master' into ce_upsteram
2015-11-05 14:26:35 +02:00
Douwe Maan
329e067ff1
Merge branch 'rs-dev-issue-2613' into 'master'
...
Add custom protocol whitelisting to SanitizationFilter
Addresses internal https://dev.gitlab.org/gitlab/gitlabhq/issues/2613
We allow any protocol for autolinks: irc://irc.freenode.net/git
But manual Markdown links with the same protocol get sanitized: `[This will not be clickable](irc://irc.freenode.net/git)`: [This will not be clickable](irc://irc.freenode.net/git)
To get around this we have to first allow *all* protocols, and then manually clean dangerous (i.e., `javascript:`) protocols.
See merge request !1496
2015-11-02 10:49:46 +00:00
Douwe Maan and Valery Sizov
b3314704d1
Update ExternalIssueReferenceFilter.
2015-10-23 17:55:16 +02:00
Valery Sizov
0f30be02eb
Merge remote-tracking branch 'origin/master' into ce_upstream
2015-10-23 13:01:19 +02:00
Yorick Peterse
afdc028516
Speed up searching for text references a bit
...
If a node is ignored there's no need for searching for a given pattern.
In turn, when searching for the pattern there's no need to construct a
MatchData object as we only care about presence (or lack thereof), not
the resulting matches.
In terms of performance this cuts down about 200 ms when loading
issue #2164 locally, though this varies a bit depending on system load.
2015-10-20 15:52:40 +02:00
Valery Sizov
8766c54bf2
Merge remote-tracking branch 'origin/master' into ce_upstream_15_10
2015-10-15 16:46:48 +03:00
Douwe Maan
95f0440a78
Merge branch 'master' into rs-redactor-filter
2015-10-15 11:26:58 +02:00
Valery Sizov
8f584d5f2c
Fix: Images cannot show when projects' path was changed
2015-10-14 18:50:35 +03:00
Douwe Maan
d313a7681b
Explicitly only parse references by specified filter
2015-10-14 09:46:06 +02:00
Douwe Maan
cd2583a3be
Code cleanup
2015-10-13 23:03:53 +02:00
Douwe Maan
93fcddd7a7
Allow ReferenceExtractor to efficiently load references from multiple texts at once
2015-10-13 22:53:05 +02:00
Douwe Maan
251e13666d
Efficiently load multiple references of one type.
2015-10-13 18:23:49 +02:00
Douwe Maan
5dd77358f6
Pass project to RedactorFilter
2015-10-13 13:36:47 +02:00
Douwe Maan
9d066bc941
Raise error when a ReferenceFilter doesn't implement referenced_by
2015-10-08 13:00:49 +02:00
Douwe Maan
e6419cecf4
Update inline doc
2015-10-08 13:00:49 +02:00
Robert Speicher
e0f9d3a547
Update ReferenceFilter docs
...
[ci skip]
2015-10-07 18:40:54 -04:00
Douwe Maan
72afcbcd37
Always allow references to the current project
2015-10-07 19:19:23 +02:00
Douwe Maan
f42cfa9e87
Refactor reference gathering to use a dedicated filter
2015-10-07 17:00:48 +02:00
Douwe Maan
4f629dab2a
Merge branch 'master' into rs-redactor-filter
2015-10-07 15:15:35 +02:00
Robert Speicher
16f8ca566b
Add custom protocol whitelisting to SanitizationFilter
...
Addresses internal https://dev.gitlab.org/gitlab/gitlabhq/issues/2613
2015-10-01 23:40:29 -04:00
Dmitriy Zaporozhets
80a983b492
Merge branch 'master' of dev.gitlab.org:gitlab/gitlabhq into ce-to-ee
...
Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com >
2015-09-22 12:25:41 +02:00
Robert Speicher
2b94f5fb06
Allow RelativeLinkFilter to go up multiple directories
2015-09-20 19:21:33 -04:00
Robert Speicher
619f04c196
Allow relative links to go up one directory level
2015-09-18 14:03:42 -04:00
Dmitriy Zaporozhets
1ba393de81
Merge branch 'master' of dev.gitlab.org:gitlab/gitlabhq into ce-to-ee
2015-09-16 10:26:10 +02:00
Dmitriy Zaporozhets
e3c30bf2e8
Merge branch 'master' into ci-and-ce-sitting-in-a-tree-k-i-s-s-i-n-g
...
Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com >
2015-09-11 16:32:11 +02:00
Douwe Maan
4f461fd45f
Merge branch 'rs-fix-highlighting' into 'master'
...
Syntax highlighting improvements
On the server side:
During development I would occasionally see SanitizationFilter sanitizing
the result of SyntaxHighlightFilter, even though its attributes were
whitelisted. This updates the `clean_spans` transformer to return the
whitelisted node as [suggested by the Sanitize docs](http://git.io/vZR8i ).
On the client side:
- Makes the syntax_highlight JS more flexible
- Adds JS specs
- Simplifies highlighting of new notes
- Adds highlighting to Markdown preview
See merge request !1278
2015-09-11 08:47:13 +00:00
Stan Hu
267687993a
Add comments and clean up test for !1274
2015-09-10 14:24:10 -07:00
Robert Speicher
e3c97ede96
RU-BO-COOOOOOOOP
2015-09-10 16:06:24 -04:00
Robert Speicher
7cbf5e4d18
Prevent result of SyntaxHighlightFilter being sanitized
2015-09-10 15:08:06 -04:00
Stan Hu
9d3344adbb
Gracefully handle errors in syntax highlighting by leaving the block unformatted
...
Closes #2433
2015-09-10 09:16:27 -07:00
Dmitriy Zaporozhets
0b5d627cd4
Merge branch 'master' into ci-and-ce-sitting-in-a-tree-k-i-s-s-i-n-g
2015-09-09 14:56:02 +02:00
Robert Speicher
8db4628b8a
Rescue from RecordNotFound in RedactorFilter
2015-09-01 17:59:09 -04:00
Robert Speicher
1ec68ea9c2
Default user_can_reference? to true when no attributes match
...
Now, a reference link with a `.gfm` class but without one of our
`data-*-id` attributes should be shown to the user rather than hidden.
2015-09-01 17:59:08 -04:00
Robert Speicher
7f75300573
Add RedactorFilter
2015-09-01 17:00:29 -04:00
Robert Speicher
454d227b45
Remove all permission checking from Reference filters
2015-09-01 16:58:38 -04:00
Robert Speicher
c104f4d590
Remove unnecessary strip from reference_class method
2015-08-31 16:23:46 -04:00
Robert Speicher
9bb06ae9ef
Make sure the main Gitlab::Markdown module gets loaded before filters
2015-08-27 16:02:49 -07:00
Robert Speicher
8e7111f79d
Reference filters no longer take a custom class context option
2015-08-27 15:36:26 -07:00
Robert Speicher
4340dd3eeb
Decouple Gitlab::Markdown from the GitlabMarkdownHelper
...
This module is now the sole source of knowledge for *how* we render
Markdown (and GFM).
2015-08-27 14:17:26 -07:00
Dmitriy Zaporozhets
243bf65124
Merge branch 'master' of dev.gitlab.org:gitlab/gitlabhq into ce-to-ee
...
Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com >
2015-08-26 17:15:12 +02:00
Douwe Maan
046b283127
Groundwork for merging CI into CE
2015-08-25 18:42:46 -07:00
Robert Speicher
747fe7520b
Remove trailing HTML entities from non-Rinku autolinks as well.
2015-08-20 18:25:16 -07:00
Dmitriy Zaporozhets
0fd7d3ebe0
Merge branch 'master' of dev.gitlab.org:gitlab/gitlabhq into ce-to-ee
...
Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com >
2015-08-10 16:01:53 +02:00