38 Commits

Author SHA1 Message Date
Robert Schäfer
00da9e8ecb
feat(backend): resize images with imagor (#8558)
* feat(backend): resize images with imagor

Open questions:
* Do we have external URLs for images? E.g. we have them for seeds. But
  in production?

* Do we want to apply image transformations on these as well? My current
implementation does not apply image transformations as of now. If we
want to do that, we will also expose internal URLs in the kubernetes
Cluster to the S3 endpoint to the client.

TODOs:
* The chat component is using a fixed size for all avatars at the moment.
Maybe we can pair-program on this how to implement responsive images in
this component library.

Commits:
* do not replace upload domain url in the database

* fix all webapp specs

* refactor: remove behaviour we won't need

We don't want to apply image transformations on files, right?

* refactor: replace the domain on read not on write

* wip: webapp fixes

* refactor(backend): add another url to config

I've given up. There seems to be no nice way to tell the minio to return
a location which differs from it's host name.

* refactor: add test for s3Service

* refactor(backend): proxy minio via backend in local development

Commits:
* provide tests for message attachments
* remove S3_PUBLIC_URL config value

* refactor: follow @ulfgebhardt's review

* add missing environment variable

---------

Co-authored-by: Ulf Gebhardt <ulf.gebhardt@webcraft-media.de>
2025-08-19 10:11:12 +02:00
e87a33eb3f
feat(backend): push posts (#8609)
* push posts

push posts

* unpush posts

* fix comment query

* locales

* fix locales

* fix tests

* Update webapp/locales/de.json

Co-authored-by: Wolfgang Huß <wolle.huss@pjannto.com>

* Update webapp/locales/de.json

Co-authored-by: Wolfgang Huß <wolle.huss@pjannto.com>

* Update webapp/locales/de.json

Co-authored-by: Wolfgang Huß <wolle.huss@pjannto.com>

* fix unpushedSuccessfully english message

* remove paremeters from unpushPost

* rename pushPostToTop -> pushPost, tests

* update locales & tests webapp

* fix lint

---------

Co-authored-by: Wolfgang Huß <wolle.huss@pjannto.com>
2025-06-03 17:57:21 +02:00
4b3a26d517
feat(webapp): shout comments (#8600)
* shout comments

* fix notifications

* Remove whitespace for empty category sections

* Overhaul post actions

* Adjust spacing

* Allow fine-grained size control for icons and circle buttons via css variables; adjust comments layout

* Adjust spacing

* Add test for ActionButton (WIP)

* Rename import

* Remove text and add count bubble

* Use filled icons to indicate active states

* Adjust sizes and orientation

* Remove unused properties, add test

* Fix ObserveButton test

* Fix ShoutButton test

* fix tests

* Adapt styles

* Adjust style for larger numbers

* Remove unused icon

* Fix test structure

* Remove unused class names

---------

Co-authored-by: Maximilian Harz <maxharz@gmail.com>
2025-05-31 00:13:15 +02:00
Max
33274e5b9a
feat(webapp): user teaser popover (#8450)
* calculate distance between current user and queried user

* fix query for unset location

* use database to calculate distance

* rename distance to distance to me, 100% calculation done in DB

* distanceToMe tests

* lint fixes

* remove comments

* Show user teaser popover with badges, Desktop

* Refactor UserTeaser and add mobile popover support

* Avoid click propagation (WIP)

* Prevent event propagation

* Adjust alignment and font sizes

* More spacing for statistics

* Add distance, simplify user link

* Refactor location info into own component

* Add tests for UserTeaserPopup

* Refactor and test LocationInfo

* Query distanceToMe, rename distance to distanceToMe

* Update test

* Improve tests for UserTeaser, WIP

* Fix tests

* DistanceToMe on User instead of Location

* Revert "DistanceToMe on User instead of Location"

This reverts commit 96c9db00a44cd120e47bfe9534d3e066a194744c.

* Fix notifications

* Refactor UserTeaser and fix location info

* Fix group member crash

* Show 0 distance

* Fit in popover on small screens

* Allow access to profile on desktop

* Revert backend changes

* Load user teaser popover data only when needed

* Fix type mismatch

* Refactor for clarity and accessibility

* Litte refactorings and improvements

* Fix popover test

* Adapt and fix tests

* Fix tests and bugs

* Add placeholder

* cypress: adapt user teaser locator to changes

* Remove delays and scrolling

* Disable popovers in notification list and fix layout

* Remove flickering

* Make overlay catch all pointer events on touch devices

* Re-add attribute for E2E test

* Fix test, return to mouseover

* fix snapshot

---------

Co-authored-by: Ulf Gebhardt <ulf.gebhardt@webcraft-media.de>
Co-authored-by: Wolfgang Huß <wolle.huss@pjannto.com>
Co-authored-by: mahula <lenzmath@posteo.de>
2025-05-05 23:54:13 +00:00
sebastian2357
2fd138697f
feat(webapp): badges UI (#8426)
- New badge UI, including editor.
- Adds config to enable/disable badges.

---------

Co-authored-by: Sebastian Stein <sebastian@codepassion.de>
Co-authored-by: Maximilian Harz <maxharz@gmail.com>
2025-04-25 16:55:46 +00:00
8cf405c549
feat(backend): badges (#8391)
* delete all old badges

* reward/unrewardBadge

* verification Badges

* name all badged accordingly

* more tests, lint

* seed badges

* profileBadge mechanic

* badgesUnusedCount

* seed profileBadges set

* configure profile badge count

* insert badges db:data:badges:default

* seed commands to seed default badges and allow to seed branding data

* copy data migrations when building docker

* typo

* correct data:branding command & document it

* test new functionality

* Update backend/src/db/seed/badges.ts

Co-authored-by: Max <maxharz@gmail.com>

* Update backend/src/db/seed/badges.ts

Co-authored-by: Max <maxharz@gmail.com>

* Update backend/src/db/seed/badges.ts

Co-authored-by: Max <maxharz@gmail.com>

* naming coventions

* final naming fix

lint

fix build

fix badge type in test

renamed badge_ to trophy_

lint fixes

small renameing

fixes

fix users spec

fix webapp queries

fix display

* expose badge description

---------

Co-authored-by: Max <maxharz@gmail.com>
2025-04-17 23:08:54 +00:00
Moriz Wahl
316c12bd35
provide information of the observing status of the post after creating a comment (#8310) 2025-03-31 20:41:39 +02:00
Moriz Wahl
538f409086
feat(backend): observe posts (#8292)
* After creating the post, the author of it automatically observes it to get notifications when there are interactions

* a user that comments a post, automatically observes that post to get notifications when there are more interactions on that post

* mutation that switches the state of the observation of a post on and off
2025-03-26 22:16:06 +01:00
Wolfgang Huß
e8d21147ae Split 'locationAndBadgesFragment' into 'locationFragment' and 'badgesFragment' 2023-01-12 10:53:43 +01:00
Wolfgang Huß
6d8149a77c Implement user location on map
- Deactivate map translation because it doesn't work.
2023-01-11 16:18:50 +01:00
Moriz Wahl
e27f9b00e6 remove location from group fragment, remove search type from search string on search page 2022-10-23 01:18:58 +02:00
Moriz Wahl
c17bdea4c4
Update webapp/graphql/Fragments.js
Co-authored-by: Wolfgang Huß <wolle.huss@pjannto.com>
2022-10-23 00:54:48 +02:00
Moriz Wahl
add85ef49c add graphql for group search 2022-10-21 17:52:06 +02:00
Wolfgang Huß
57f7a43d09 Test locations in group resolvers 2022-09-16 21:09:45 +02:00
Moriz Wahl
bc955003f7 add optional categories to teaser and post 2022-07-25 20:03:00 +02:00
589fe438e2
fix Search.feature 2021-04-12 13:24:53 +02:00
Moriz Wahl
1c3f628fb2 count views of post teaser 2021-03-01 15:33:20 +01:00
Moriz Wahl
d3eafc9b69 add clickedCount to PostTeaser 2021-02-22 21:13:24 +01:00
Moriz Wahl
664d3d2c42 image type in frontend 2021-02-04 21:05:04 +01:00
roschaefer
276ea79e8f Update prettier to v2 2020-03-24 21:11:11 +01:00
Robert Schäfer
512ef672bf
feat: Introduce graphql image type (#3043)
* refactor(graphql): Introduce image type

* Undo changes to .travis.yml

* chore: Upgrade travis to node LTS

- URL is available since v10

* chore: use lts

Co-authored-by: mattwr18 <mattwr18@gmail.com>
2020-03-16 15:32:19 +01:00
Mike Aono
d49afc25cf test(cypress): Cover "Pinned post" feature
* Implement cypress tests

- Start implementation of cypress tests for pinned posts

* Test that Admin can pin a post

- Tests the process of an admin pinning a post

* Resolve failing tests

- Fix ordering of posts immediately after pinning posts by reloading page
- Check that tests are pinned posts are displayed first for role user

* Refactor to seperate the initialization

- Of the post data created in the database during setup

* Fix toaster test

* test(cypress): Add missing parts for pin feature

* docs(cucumber): Link to admin 🥒 folder

* Follow @mattwr18's suggestions

* test(backend): Order pinned posts like frontend

@mattwr18 I think this was a false negative.

Co-authored-by: Robert Schäfer <git@roschaefer.de>
2020-01-23 20:30:12 +01:00
Moriz Wahl
a3cfbb09cb Fixes 2603 2019-12-23 15:24:51 +01:00
Alexander Friedland
ed617f8c83
Merge branch 'master' into 1746-Blur_explicit_Image_Content 2019-12-17 07:39:26 +01:00
roschaefer
107409ecee Fix duplicate fragment user issue
This is refactoring all our fragments and fixing the warning about an
existing name `user`. Apparently, fragments should have a unique name
globally.

I decided to call `userFragment`, `postFragment` the fragments for one
object and use different names to query for related objects.

I would be glad to learn a better way to handle this.
2019-12-14 00:37:42 +01:00
ogerly
a6cbbbeaf1 DB rename blurImage to imageBlurred 2019-12-12 10:42:52 +01:00
Alexander Friedland
b89e081bad
Merge branch 'master' into 1746-Blur_explicit_Image_Content 2019-12-11 10:39:55 +01:00
roschaefer
deefc4e12f Improve notification query performance
Just don't ask for stuff that you don't want to show anyways
2019-12-10 18:09:32 +01:00
Alexander Friedland
dee22d33db
Merge branch 'master' into 1746-Blur_explicit_Image_Content 2019-12-06 07:21:49 +01:00
ogerly
6ce797e8ef test review 2019-12-04 11:20:27 +01:00
ogerly
7f3f81822e blur the image ok. 2019-11-28 20:40:35 +01:00
mattwr18
b9d28e5a69 Set up frontend/backend to add imageAspectRatio
- on create and update
2019-11-21 11:32:42 +01:00
mattwr18
95be6eaee6 Initial commit to add placeholder image for Post 2019-11-20 16:52:20 +01:00
Moriz Wahl
19602d7311 language is fetched in postFragment 2019-11-11 22:21:59 +01:00
mattwr18
f871df02ae Start setting up frontend pinning/unpinning
- Add pin/unpin post to content menu
- Update apollo cache to reactively unpin
- Update apollo cache in root path to re-order Posts
- Order with pinned post first
- Start setting up filters, so that the pinned post is always the first
post visible
2019-10-17 17:56:16 +02:00
mattwr18
a5e3c52e1d Show that a Post/Comment has been edited 2019-10-03 12:01:04 +02:00
Wolfgang Huß
22a005eb1c Show categories translated in all places and even in tooltips
Show `#` symbol in front of hashtags.
Minor design changes on posts more info page.
2019-09-16 11:14:13 +02:00
roschaefer
99dd6ea20a Centralize fragments, fix @mattwr18's bugs
Most of those bugs weren't even introduced in this PR, e.g. the missing
`this.$i18n` for the comments mutations.
2019-09-03 21:28:29 +02:00