Arpit Jalan
1e2b81991f
fix the build
2018-12-25 10:27:51 +05:30
Guo Xiang Tan
b64d760bb3
DEV: Improve tests to assert that the right HTML is generated.
2018-12-20 07:14:32 +08:00
Robin Ward
662cfc416b
FEATURE: Show a blurry preview when lazy loading images
...
This generates a 10x10 PNG thumbnail for each lightboxed image.
If Image Lazy Loading is enabled (IntersectionObserver API) then
we'll load the low res version when offscreen. As the image scrolls
in we'll swap it for the high res version.
We use a WeakMap to track the old image attributes. It's much less
memory than storing them as `data-*` attributes and swapping them
back and forth all the time.
2018-12-19 01:57:30 +08:00
Bianca Nenciu
825ae86857
FEATURE: Remove full quote only if first paragraph. ( #6793 )
2018-12-18 15:46:20 +01:00
Vinoth Kannan
efcea148eb
DEV: Use destroy! method to raise error if any (#0d3c1cde)
2018-12-18 03:05:43 +05:30
Vinoth Kannan
0d3c1cde90
FIX: Use find_by_id method to prevent record not found exception
2018-12-15 03:19:45 +05:30
Bianca Nenciu
7cac04e1a8
* FEATURE: Adds site setting to let quotes on direct replies.
...
* DEV: Added test.
* FIX: Do not bump topic when removing full quotes.
2018-12-12 15:42:53 +01:00
Bianca Nenciu
41e184280d
FEATURE: Remove full quotes of direct replies. ( #6729 )
2018-12-07 13:07:11 +01:00
Guo Xiang Tan
56034c733a
UX: Strip class when link is not oneboxed due to site setting limits.
2018-11-29 14:33:01 +08:00
Guo Xiang Tan
a1e77aa2ed
FEATURE: Reimplement SiteSetting.max_oneboxes_per_post
. ( #6668 )
...
Previously, the site setting was only effective on the client side of
things. Once the site setting was been reached, all oneboxes are not
rendered. This commit changes it such that the site setting is respected
both on the client and server side. The first N oneboxes are rendered and
once the limit has been reached, subsequent oneboxes will not be
rendered.
2018-11-27 16:00:31 +08:00
Guo Xiang Tan
482013a1d4
FIX: Group mentions missing after post processing.
2018-11-26 12:57:07 +08:00
Guo Xiang Tan
57e2f4990d
PERF: Move processing of inline onebox out of V8 context. ( #6658 )
2018-11-26 09:21:38 +08:00
Régis Hanol
306d77b54f
FIX: don't use srcset on cropped thumbnails
2018-10-25 16:08:10 +02:00
Vinoth Kannan
59be289084
FIX: Do not add lightbox to onebox images ( #6479 )
2018-10-11 08:57:21 +11:00
Vinoth Kannan
4000dddd32
Merge pull request #6458 from vinothkannans/fix-giphy
...
FIX: Display large/broken image placeholders for image oneboxes
2018-10-07 18:08:54 +05:30
Vinoth Kannan
c499872597
FIX: Display large/broken image placeholders for image oneboxes
2018-10-07 17:42:41 +05:30
Sam
ad0e768742
FEATURE: add support for responsive images in posts
...
When creating lightboxes we will attempt to create 1.5x and 2x thumbnails
for retina screens, this can be controlled with a new hidden site setting
called responsice_post_image_sizes, if you wish to create 3x images run
SiteSetting.responsive_post_image_sizes = "1|1.5|2|3"
The default should be good for most of the setups as it balances filesize
with quality. 3x thumbs can get big.
2018-10-03 13:44:53 +10:00
Guo Xiang Tan
434035f167
FIX: Link post to uploads in PostCreator
.
...
* This ensures that uploads are linked to their post on creation
instead of a background job which may be delayed if Sidekiq
is facing difficulties.
2018-09-06 11:18:11 +08:00
Joffrey JAFFEUX
10a3499d68
uses emoji versions for specs ( #6276 )
2018-08-16 13:45:30 +02:00
Régis Hanol
de92913bf4
FIX: store the topic links using the cooked upload url
2018-08-14 12:23:32 +02:00
Régis Hanol
bf4d98e89d
FIX: always store topic links using the upload url
2018-08-04 01:29:32 +02:00
Vinoth Kannan
6aee22b88f
FIX: Onebox images are not downloaded locally without css class
2018-08-01 02:51:02 +05:30
Guo Xiang Tan
806f0ca19d
FIX: URL with params for svg images should not be light boxed.
2018-06-20 10:47:14 +08:00
Guo Xiang Tan
c18b86d9b2
UX: Don't add light box for SVG images.
2018-06-18 17:11:06 +08:00
Arpit Jalan
b75b6de982
FIX: respect nofollow settings for onebox links
2018-03-26 18:21:16 +05:30
Robin Ward
31a0c4a9be
FEATURE: Add quote-modified
class if a quote has been modified
2018-03-13 13:41:06 -04:00
Régis Hanol
0559a4736a
FIX: don't double request when downloading a file
2018-02-24 12:35:57 +01:00
Sam
f028ffaf29
SECURITY: correct local onebox category checks
...
Also removes ugly "source_topic_id" from cooked posts
Patch was authored by @zogstrip
Signed-off-by: Sam <sam.saffron@gmail.com>
2018-02-14 10:40:46 +11:00
Régis Hanol
7d2283167a
UX: only crops images taller than 18:9 instead of 16:9
2018-01-31 22:31:16 +01:00
Régis Hanol
678e28794a
FIX: properly handle too large & broken images in posts
2017-11-16 15:45:07 +01:00
Régis Hanol
648832a643
fix the build
2017-11-15 11:53:14 +01:00
Vinoth Kannan
7b494a65c9
NEW: large image placeholder added in cooked html ( #5291 )
2017-11-15 11:30:47 +01:00
Régis Hanol
23baaa5dcc
FIX: don't crop iPhone X screenshots
2017-11-14 20:37:27 +01:00
Sam
3ac7d041ae
UX: generic onebox treats all square images as avatars and renders them smaller
2017-11-13 11:21:19 +11:00
Régis Hanol
cbdfc85466
FIX: images aren't lightboxed anymore (partially reverts 646c6eb7cd
)
2017-10-18 23:54:36 +02:00
Sam Saffron
646c6eb7cd
FEATURE: add :before_post_process_cooked hook
...
Also reduce amount of image downloading
2017-10-17 16:22:54 +11:00
Guo Xiang Tan
77d4c4d8dc
Fix all the errors to get our tests green on Rails 5.1.
2017-09-25 13:48:58 +08:00
Neil Lalonde
4a5907b116
Merge branch 'master' into search_posts_with_images
2017-07-31 10:44:41 -04:00
Guo Xiang Tan
5012d46cbd
Add rubocop to our build. ( #5004 )
2017-07-28 10:20:09 +09:00
Neil Lalonde
ea0e90b2b0
Merge branch 'master' into search_posts_with_images
2017-07-26 10:15:55 -04:00
Sam
627f5ddbd1
Correct specs
2017-07-17 18:00:25 -04:00
Sam Saffron
d0c5205a52
Feature: Change markdown engine to markdown it
...
This commit removes the old evilstreak markdownjs engine.
- Adds specs to WhiteLister and changes it to stop using globals
(Fixes large memory leak)
- Fixes edge cases around bbcode handling
- Removes mdtest which is no longer valid (to be replaced with
CommonMark)
- Updates MiniRacer to correct minor unmanaged memory leak
- Fixes plugin specs
2017-07-17 11:41:34 -04:00
Guo Xiang Tan
13f3de4bf6
Nuke all SiteSetting.stubs
from our codebase.
2017-07-07 15:09:14 +09:00
Régis Hanol
cdf8baac3b
fix specs due to new default emoji set
2017-06-26 23:36:30 +02:00
Jakub Macina
bf002e0873
Add extraction of image_url for oneboxed images. Fix search by images filter name.
2017-06-19 15:18:02 +02:00
Joffrey JAFFEUX
09d34b7642
emoji images are now v5 not v3
...
TODO: we should not hardcode this
2017-06-05 16:10:36 +02:00
Robin Ward
009e120e13
FIX: Don't raise an error when the img attribute cannot be found
2017-05-08 15:35:31 -04:00
Régis Hanol
02bb7beaaf
FIX: don't put attachments on the CDN when 'prevent anons from downloading files' is enabled
2017-02-07 18:06:44 +01:00
Arpit Jalan
19f7beaa2c
FIX: topic links were getting dropped when post is rebaked
2017-01-30 14:55:53 +05:30
Arpit Jalan
2d0c99636a
do not add rel noreferrer
2016-11-20 18:19:14 +05:30