Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[IMP] survey: improve preview image style #2713

Open
wants to merge 5 commits into
base: master-survey-share-results-adsc
Choose a base branch
from

Conversation

anso-odoo
Copy link

@anso-odoo anso-odoo commented Aug 8, 2023

This PR improves the style of the image generated to be displayed when sharing the URL of the survey in social medias

Before :
image 1

After (without image):
preview_picture_fina_light

After (with image):
preview_picture_fina_dark

task-3290816

@robodoo
Copy link

robodoo commented Aug 8, 2023

This PR targets the un-managed branch odoo-dev/odoo:master-survey-share-results-adsc, it needs to be retargeted before it can be merged.

@anso-odoo anso-odoo force-pushed the master-survey-share-results-anso branch 11 times, most recently from 56c75d7 to e640239 Compare August 10, 2023 08:16
@anso-odoo
Copy link
Author

anso-odoo commented Aug 16, 2023

@schoffeniels & @Francois-frgi don't forget to check this please 👍
(task-3290816)

Copy link

@schoffeniels schoffeniels left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hello!
Nice job, I love the new designs and the code looks good overall.

I left a few propositions to improve it a little bit (comments between parenthesis are the warnings I get from the linter), but if you prefer you can keep things as is and once your part is done I'll merge it into my branch and do the changes myself, as someone else from my team will probably review the code as well afterwards 🙂
I also added a comment concerning the mask of the avatar not being transparent. I tested it and it seems to solve the issue.

Thanks !

addons/survey/models/survey_survey.py Outdated Show resolved Hide resolved
addons/survey/models/survey_survey.py Outdated Show resolved Hide resolved
addons/survey/models/survey_survey.py Outdated Show resolved Hide resolved
addons/survey/models/survey_survey.py Outdated Show resolved Hide resolved
addons/survey/models/survey_survey.py Outdated Show resolved Hide resolved
addons/survey/models/survey_survey.py Outdated Show resolved Hide resolved
addons/survey/models/survey_survey.py Outdated Show resolved Hide resolved
addons/survey/models/survey_survey.py Outdated Show resolved Hide resolved
addons/survey/models/survey_survey.py Outdated Show resolved Hide resolved
addons/survey/models/survey_survey.py Outdated Show resolved Hide resolved
@anso-odoo anso-odoo force-pushed the master-survey-share-results-anso branch 2 times, most recently from f730d39 to fada229 Compare August 17, 2023 15:11
@anso-odoo
Copy link
Author

Thanks a lot for the review @schoffeniels
Fixed all and took the opportunity to improve a bit the design too (bolder texts for better readability and a bit more spacing between the type of survey and the title so it displays better when the title is shorter)
cc @Francois-frgi

@anso-odoo anso-odoo marked this pull request as ready for review August 17, 2023 15:13
@robodoo
Copy link

robodoo commented Aug 17, 2023

This PR targets the un-managed branch odoo-dev/odoo:master-survey-share-results-adsc, it needs to be retargeted before it can be merged.

Purpose:
--------
Instead of having the survey title in the header on the start survey screen,
place it in the middle of the screen, on top of the survey description.
The title is a little bit higher than the middle on mobile devices.

Task-2842682
Purpose:
--------
Center the 'void survey' error message shown when landing on a survey
that has no question.

Task-2842682
Purpose:
--------
The results page of a survey is now "anyone with the link"-based access.

When clicking the "See Results" action on the survey, the URL of the page
opened can now be shared and used by anyone, even by public users.

A randomly generated "results_token" has been added to the survey model,
so that the result page is still kind of hidden (the URL can not be
rebuilt using other info such as the survey's name or the survey's
access token).

Task-2842682
Purpose:
--------
When sharing URLs on social medias, a link preview is usually shown.
When sharing a survey (or a survey's results), this preview now shows info
related to the survey (survey's title, description, and website), as well as
an image generated on the fly using the survey's information (title, user
and date, background image, some statistics, and "powered by odoo" logo).

The preview is not shown for surveys requiring users to log in, in order
to not disclose info about the survey.

Task-2842682
@schoffeniels schoffeniels force-pushed the master-survey-share-results-adsc branch from eac5261 to 7a9bcb1 Compare August 22, 2023 09:20
This commit improves the style of the image generated to be displayed
when sharing the URL of the survey in social medias

task-3290816
@anso-odoo anso-odoo force-pushed the master-survey-share-results-anso branch from fada229 to c555c22 Compare August 22, 2023 11:55
@schoffeniels schoffeniels force-pushed the master-survey-share-results-adsc branch 4 times, most recently from 8ecddcb to d65891c Compare March 6, 2024 13:34
@schoffeniels schoffeniels force-pushed the master-survey-share-results-adsc branch 2 times, most recently from 0ae04cb to 555a325 Compare March 13, 2024 08:02
@schoffeniels schoffeniels force-pushed the master-survey-share-results-adsc branch 8 times, most recently from 7efa95c to 577042a Compare March 22, 2024 15:11
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
3 participants