* Add uniqueness validation to broadcast titles in broadcast.rb
* WIP: properly test title uniqueness in broadcast_spec.rb
* Add unique index for title and type_of on Broadcasts
* Adds a unique index to the Broadcasts table
* Adds broadcast.rb to .rubocop_todo.yml
* Resolve merge conflicts
* Add spec around duplicate broadcasts in broadcasts_spec.rb
* Adjust broadcast to be inactive in broadcasts_spec.rb
* Feature 🚀 : Ability to delete messages in chat channels
- Sending message ID to frontend
- Deleting Message
- Use pusher to delete message realtime
* Minor Bug 🐞: Show message action only for current user
- User can delete or edit their own messages
* Test cases added
* Bug 🐞: Update message id for receiver
Message id was not sent to receiver by pusher
* Refactoring🛠: Message controller refactoring
* Test Cases📝 : Specs for Delete message added
* Feature 🚀 : Ability to edit messages
* Test Cases📝 : Specs for Edit message added
* 🐞 Channel List bug in mobile view
* changes in joining request responses
* 🛠 Request Managers Frontend ready
* changes in routes for adding and removing remembership
* 🚀 New routes implemented for request manager
* fix issues
* changes in api for remove membership
* Merge conflict resolved
* 🐞 Channel List bug in mobile view
* changes in joining request responses
* 🛠 Request Managers Frontend ready
* changes in routes for adding and removing remembership
* 🚀 New routes implemented for request manager
* fix issues
* changes in api for remove membership
* 🛠Optimizing for CodeClimate
* 🛠Optimizing again for CodeClimate
* 🛠Optimizing again 2 for CodeClimate
* 🛠 Added more test cases
* 🛠 Optimizing code
* 🛠 vscode file changed
* 🛠 Updated schema as requested
Co-authored-by: Parasgr-code <paras.gaur@skynox.tech>
* This change allows access to api/health_checks if you are coming from localhost
or 127.0.0.1. Pretty sweet huh?
The reason for this change is because I want to easily get to these healthcheck
end points from localhost without having to get the health-check-token beforehand.
Buttttt.... this addition has some issues. You can spoof the host header pretty
easily:
https://daniel.haxx.se/blog/2018/04/05/curl-another-host/
I thought about doing `return if !request.ssl? && request.local?`
to check of the request was over https or not. Any localhost healthcheck we do
directly to puma will be over http. Checking for TLS seemed like a logical next
check, but since we force https on the edge and not necessarily from the edge to
Puma the Host header can still be spoofed to get at these end points.
More info on host header attacks and what Rails 6 is doing about it:
https://github.com/rails/rails/issues/29893
While I do think it is a good idea to protect these healthcheck end points from
the outside world, I do want to be able to get to them easily locally. WWYD?
* Fix Health Check spec by stubbing request
Co-authored-by: mstruve <mollylbs@gmail.com>
* Implement Reddit liquid tag
* Set reddit content in locals
* Change Reddit liquid tag content layout
I decided a UI similar to the Stack Exchange tag would be better.
Now the Reddit tag looks a bit similar.
* Add tests for RedditTag
* Add reddit liquid tag example to docs
Also emphasize notice about compilation of article when using any
liquid tag
* Parse markdown text reddit content for RedditTag
* Display date RedditTag post was published
* Remove file location comments
* Change order of conditional for Reddit liquid tag
Sometimes the attribute `post_hint` might be null and neither condition
would apply.
* Add example to use Reddit liquid tag
* Change reddit svg icon for Reddit liquid tag
* handle and verify status of Reddit links
Here we make sure the passed link is a valid one in terms of URI composition (e.g. protocol)
but also that the URL is one that points to existing content in Reddit.
If the URL isn't returning anything but a successful response code (200) then
we treat it as an invalid one.
* Do not use VCR for RedditTag specs
The generated cassette for this tag was really huge (6000+ lines).
Using mocks (as in the MediumTag spec) still does the job and without
that huge VCR file.
* Remove index line from schema.db
* Improve RedditJsonFromUrlService
- Change User-Agent in requests to one read from app configuration
- Remove Reddit URL check by making a GET request
- Add regexp to validate URL looks like a Reddit URL
* Move RedditJsonFromUrlService methods to RedditTag
Also changed the way the request was being mocked. Previously, it was by
mocking the service class now I'm mocking HTTParty directly and returning
the JSON structure Reddit uses.
* Add 'feature_flag' field to pages table, form
* Add 'exist?' to FeatureFlag
* Test for feature flag when loading custom pages
* Refactor FeatureFlag.enabled? to check both boolean and user gates
* Ugly test fixes
* PR feedback and refactoring
* PR refactor: don't require database table!
* feat: alphabetize the site config page
* chore: move twitter hashtag into social media and rename Mailchimp list ID's to Newsletter
* chore: reorder the site config
* fix: don't show a broken image when the value does not exist
* if there are 3 or more parameters lets move it to its own method
* chore: empty line
* fix: seems like we couldn't update the token
* chore: amend the test to mimic the order on the site config
* chore: oops - add back the welcome_notifications_live_at
* Differentiate between welcome + announcement broadcasts
* Allow admins to filter between these two types in the `/internal/broadcasts` UI.
* Ensure that the index endpoint fetches the correct Broadcast models.
* Only allow one Announcement broadcast to be created at a time
* Also add some `announcement` and `welcome` scopes on the `Broadcast` class.
* Add flash[:success] messages in BroadcastsController.
* Add some tests for Announcement broadcast validations
* Remove unused active_announcement_params method
* Order Broadcasts by title, optimization improvements
* Fix missing closing tags in broadcast specs
--base-50: changed to #fff unreadable text in ten X hacker theme light-dark text making eye strain their that's why i changed to white it looks i tested in firefox and another bug in this theme is in case of mail
and usernames CSS properties are overriding please and that text is getting black out there Ex:-Hidden
* Added story sorting to Storybook.
* Added design system guidelines.
* Made Base in Storybook tree 2nd in the tree view.
* Now Components are 3rd in the treeview of Storybook.
* Now App Components are 4th in the treeview of Storybook.
* Froze node version to 12.16.0
* Revert "Froze node version to 12.16.0"
This reverts commit 093b119c7d7ca05ecb4e1c0234b24bcf8e7b10a4.
* Add download_broadcast to generator.rb
* Adds memoized download_broadcast method
* Adds send_download_notification method
* Adds send_download_notification to call method
* Add download_app to broadcasts.rb and seeds.rb
* Adds download_app broadcast info and copy to factory
* Adds download_app copy to seeds
* Add specs around #send_download_app_notification in generator_spec.rb
* Fix quotes around copy
* Remove extra space within copy
* Change models and related files
* Update controllers and specs
* More renaming
* Seek and destroy, I mean search and replace
* Round up the stragglers
* Ground control to Major Travis...
* More fixes
* PR feedback
* Various fixes
* Rename view
* Fix list query builder
* Unify request specs
* Fix some API spec errors
* Fix remaining API specs
* Make spec conform to API
* Fix leftover problems
* Fix JS tests
* Fix column name in select
* Fix API specs
* Fix search specs
* Paging Mr. Travis
* flare tag line height
* .
* new tabs on home
* instantclick
* Some JS cleanup for mobile view select event handler.
* eslint cleanup
* select arrow color
* quotes
* quotes
* .
* .
* omg
* .
* finally
* focus visible
Co-authored-by: Nick Taylor <nick@iamdeveloper.com>
* Rubocop unique index cop needs a static list of columns
* Add unique index on organizations secret
* Add unique index on chat_channel_memberships chat_channel_id
* Add unique index to chat_channel slug
* Add unique index to badge_achievements badge_id