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

Add 'hide_order_copy_link' parameter to hide 'Order a copy' #1430

Merged
merged 2 commits into from
Apr 3, 2020

Conversation

ChrisBAshton
Copy link
Contributor

@ChrisBAshton ChrisBAshton commented Apr 3, 2020

What & why

Attachment is used on admin-facing pages as well as user-facing
pages. Their requirements for a preview are somewhat different,
and having 'Order a copy' doesn't fit the design for them.

I've chosen to make this a boolean, following the style of the
'hide_opendocument_metadata' parameter, rather than inventing
some sort of 'admin context' which is open to misinterpretation.

Trello: https://trello.com/c/UET4vx6k/1439-update-attachment-component-to-accommodate-new-attachment-design

Visual Changes

Screenshot 2020-04-03 at 12 49 56

See https://govuk-publis-hide-order-mpkgzj.herokuapp.com/component-guide/attachment

@bevanloon bevanloon temporarily deployed to govuk-publis-hide-order-mpkgzj April 3, 2020 11:38 Inactive
@bevanloon bevanloon temporarily deployed to govuk-publis-hide-order-mpkgzj April 3, 2020 11:39 Inactive
@ChrisBAshton ChrisBAshton force-pushed the hide-order-copy-link-from-admins branch from 3b89313 to ff56da5 Compare April 3, 2020 11:45
@bevanloon bevanloon temporarily deployed to govuk-publis-hide-order-mpkgzj April 3, 2020 11:45 Inactive
@ChrisBAshton ChrisBAshton marked this pull request as ready for review April 3, 2020 11:50
Copy link
Contributor

@benthorner benthorner left a comment

Choose a reason for hiding this comment

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

Thanks @ChrisBAshton! Just a few minor things to fix...

spec/components/attachment_spec.rb Outdated Show resolved Hide resolved
Attachment is used on admin-facing pages as well as user-facing
pages. Their requirements for a preview are somewhat different,
and having 'Order a copy' doesn't fit the design for them.

I've chosen to make this a boolean, following the style of the
'hide_opendocument_metadata' parameter, rather than inventing
some sort of 'admin context' which is open to misinterpretation.
@ChrisBAshton ChrisBAshton force-pushed the hide-order-copy-link-from-admins branch from ff56da5 to 7672fa3 Compare April 3, 2020 14:06
@bevanloon bevanloon temporarily deployed to govuk-publis-hide-order-mpkgzj April 3, 2020 14:06 Inactive
@ChrisBAshton ChrisBAshton merged commit bbeaff4 into master Apr 3, 2020
@ChrisBAshton ChrisBAshton deleted the hide-order-copy-link-from-admins branch April 3, 2020 14:18
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants