Commit Graph

21 Commits

Author SHA1 Message Date
Javi Martín
a6e6a90bef Add alt test to proposal images in mail 2024-11-12 18:25:20 +01:00
Javi Martín
6d6c067296 Use an empty alt attribute for decorative images
This way people using screen readers will know that the image is a
decorative one.
2024-11-12 18:25:20 +01:00
Javi Martín
7c740f1daa Remove duplicate HTML in dashboard mail preview
We noticed this while editing the styles for this class in the previous
commits.
2022-10-28 13:58:04 +02:00
Javi Martín
091abfc944 Use Active Storage to render attachments
This way we fix a bug we mentioned in commit 930bb753c which caused
links to documents to be broken when editing their title because the
title was used to generate the URL of the document.

Note we're still using Paperclip to render cached attachments because
this is the only case where we store files with just Paperclip and not
Active Storage.

With Active Storage, we render attachments just like any other resource,
using `polymorphic_path`. Paperclip included the `url` method in the
model; since the model doesn't have access to the request parameters
(like the host), this was inconvenient because it wasn't possible to
generate absolute URLs with Paperclip.

In order to simplify the code and make it similar to the way we used
Paperclip, we're adding a `variant` method accepting the name of a
variant and returning the variant.
2022-02-23 18:21:38 +01:00
Javi Martín
da055edb37 Simplify rendering proposal image in dashboard
So it's now similar to the way we render images in other places.
2021-09-24 16:36:35 +02:00
Javi Martín
6b1864fbcd Sanitize translations instead of using _html
Using the `_html` suffix in an i18n key is the same as using `html_safe`
on it, which means that translation could potentially be used for XSS
attacks.
2019-10-09 19:46:47 +02:00
Javi Martín
00a6f5b601 Remove <%== usage displaying settings
Using `<%==` is the same as using `raw`. I'm not sure if we meant
`sanitize` in this case, or it's just a typo. I'm assuming the latter
since we don't use anything similar in any other places.
2019-10-08 19:10:14 +02:00
Javi Martín
cf9e36c767 Replace single quotes with double quotes
Most of these quotes were in the dashboard branch before we added the
rule for double quotes.
2019-09-10 19:21:03 +02:00
Javi Martín
911fe4e481 Simplify calls to render partial
We're also adding a bit of consistency, since most of our calls to
partial rendering omit the `partial` and `locals` keys.
2019-09-04 15:00:36 +02:00
decabeza
0517ae04a6 Remove consul logo 2019-04-24 13:57:04 +02:00
decabeza
cbc89dae8c Replace html_safe to i18n _html 2019-03-19 17:35:39 +01:00
decabeza
71c6a6edbc Rename images using underscores 2019-03-19 17:18:21 +01:00
Alessandro Cuoghi
44964c35f9 Added quotes images
- Created white quote images png (before and after)
- Added images quotes to preview email and email.
- Added max width to images quotes png
2019-02-02 19:18:27 +01:00
Alessandro Cuoghi
56dadcb701 Changed logo image
- The original logo is white. Created black version for white background.
- Added logo in preview email and send email.
2019-02-02 19:18:27 +01:00
Alessandro Cuoghi
394a7e55ee Fixed some style preview email and email
- Removed class large-7
- Changed font size preview-email and email
- Changed text color in the email
- Changed some font size and padding in the email
- Added some padding in preview email
- Pass scss-lint
- Changed padding and added font size.
2019-02-02 19:18:27 +01:00
Alessandro Cuoghi
70171b0e17 Fix PDF and email
- Inserted normal quotation marks
- Remove class quote
- Added max width mail preview
- Added some styles in the email
- Added image decide_madrid at the end of the email
- Added cover to the image preview poster and PDF
- Passed scss lint
2019-02-02 19:18:27 +01:00
Alessandro Cuoghi
4ec858f1a0 Email Style
- Added style as per email sent
- Change color
- Changed alignment title
- Added image decide madrid
- Added Shadow to image
2019-02-02 19:18:26 +01:00
decabeza
5d00952b05 Improves styles for dashboard mailer preview 2018-10-13 13:01:38 +02:00
decabeza
e9a5580f9a Adds styles to dashboard mailing views 2018-10-05 18:45:58 +02:00
Juan Salvador Pérez García
9eaa990145 Added default image for proposal dashboard mailing 2018-07-25 17:01:30 +02:00
Juan Salvador Pérez García
8876b285ce Fixes #229
Adds email feature for proposals dashboard
2018-07-25 13:28:44 +02:00