Commit Graph

21 Commits

Author SHA1 Message Date
google-labs-jules[bot]
8564ec7a7c Add comments to photos (#4130)
* Add comments to photos

Extend the photo show page to support comments by logged in users.

- Make the Comment model polymorphic.
- Update the Photo and Post models to have comments.
- Update the comments controller to handle the polymorphic association.
- Update the photo show page to display comments and a comment form.
- Create a reusable comments partial.

* Add migration

* Fix tests

* Fix tests

* Slightly fix tests

* Fix variables

* Add field

* Refactor slightly

* Refactor slightly

* Refactor slightly

* Refactor

* Photos respond to this as well

* Refactor to polymorphic_url

* Rename

* Wrong relationship

* Refactor and fix tests

* Fix relationships

* Fix rendering

* Fix tests

* Fix model tests

* Fix test

* Fix test

* Fix test

* Fix test

* Fix controller spec

* Fix view tests

---------

Co-authored-by: google-labs-jules[bot] <161369871+google-labs-jules[bot]@users.noreply.github.com>
Co-authored-by: Daniel O'Connor <daniel.oconnor@gmail.com>
2025-08-24 21:10:16 +09:30
Daniel O'Connor
12ff09ad51 Add Accessibility assertions to rspec, replacing accessbility-lint + fixes (#3573)
* Add dep

* Add tests around accessibility

* Add examples in a few places

* Try to fix screenshots

* Remove redundant role

* Adjust rules, colors, etc so tests pass

* Update app/assets/stylesheets/overrides.scss

* Wrap in label

* Omit rule, which is failing with a false positive

* Update index.haml

* Update _blurb.html.haml
2024-01-22 22:09:27 +10:30
Brenda Wallace
13419d37bb pull-right becomes text-right 2019-05-19 11:50:04 +12:00
Brenda Wallace
9ecf210ffb More form tidy up 2019-04-27 19:19:42 +12:00
Brenda Wallace
2b7144c1fd Fixed trailing quote in haml 2017-02-04 15:07:18 +13:00
Brenda Wallace
785ae33a42 Haml clean up for comments views 2017-02-04 14:07:59 +13:00
Miles Gould
897eac4fae Merge branch 'pr/727' into dev 2015-07-17 00:31:00 +01:00
Cjay Billones
bb88041fef [Refactoring] Replace .count and .length with .size for collections
Improved program efficiency (in querying in particular) by replacing .count and .length with .size for collections.

Fix error in refactoring

Reverted some .size into .count
2015-06-25 12:09:03 +08:00
Manmeet Singh
b9b2f4a57e Placing cursor in textarea on page load of write post and write comment views 2015-03-07 16:36:15 +05:30
Skud
a684efcf2a b3ified some of the forms 2014-08-11 13:02:08 +10:00
Amy Hendrix
db9ef0bc83 Full-width form elements 2014-07-13 20:28:20 -04:00
Skud
e17dcf8671 Reordered comments: they are now DESC by default
Added scope "post_order" to order them ASC for display on post page.
Also tweaked post/comment views a bit.
2013-05-24 14:36:58 +10:00
Miles Gould
2b84fa8bad Show previous comments when creating a comment.
- Move "show previous comments" into a partial
 - invoke said partial from the new comment form
 - add tests.
2013-04-29 21:30:26 +01:00
Cesy Avon
f3cb251180 Merge branch 'standardise_buttons' of https://github.com/phazel/growstuff into dev 2013-03-24 01:56:24 -07:00
gnattery
d26b3d42ed standardise button styles 2013-03-21 00:37:46 +11:00
Skud
17309723d5 show markdown help on post and comment pages 2013-03-20 22:08:09 +11:00
Skud
62af897bf1 various prettification 2013-02-08 16:55:55 +11:00
Skud
b6c759e521 edit comments 2013-02-08 14:49:07 +11:00
Skud
ae59b1e18d pass post_id through to comment 2013-02-08 14:37:57 +11:00
Skud
a0a88bee11 comment form shouldn't have author/post fields 2013-02-08 14:14:07 +11:00
gnattery
3cff543184 rails g scaffold Comment 2013-02-06 14:49:49 +11:00