Molly Struve
091392cf1f
Remove webpush gem and code ( #4883 )
2019-11-22 16:46:11 -05:00
rhymes
027dbb027b
Return 401 instead of 500 when a channel is blocked ( #4721 )
2019-11-04 10:39:18 -05:00
Andy Zhao
73caa9a864
New Feature: Block Users ( #4411 )
...
* Prevent need for eager loading
* Add initial implementation of user block
* Remove debugger oops
* Add index and foreign keys for user_block table
* Use private method instead of exists
* Move channel handling logic to service object
* Update styling a bit
* Use profileDropdown file for future proofing
* Remove commented out code
* Render json: { result } for all endpoints
* Add statuses for sad paths
* Add better sad path handling in the JS
* Remove accidentally committed spec file
* Don't wait for DOM to load block button
* Use equality for accuracy in slug query
* Add status code for unauthorized requests
* Add missing comma sigh
2019-10-23 17:14:28 -04:00
Araslanov Evgeny
7de692156c
Add ChatChannels::IndexingJob ( #4317 ) [ci skip]
2019-10-15 16:13:10 -04:00
Jacob Herrington
099b188530
Rename uncommunicative variables ( #3890 )
...
* Clarify uncommunicative variables in labor classes
Single letter variable names are largely a question of preference, in
some cases I think that convention mitigates the opaque nature of single
letter variable names (e.g., e for error, i for index, etc).
However, in some cases they can be unclear and there isn't much reason
to use single letter variables unless for some reason character length is
really important.
In this case, I would prefer clarity in variable names over brevity of
code so I've used Reek to identify short variable names and I'm changing
them.
It's pretty boring, but hopefully incremental code love changes like
this one add up and improve readability and accessibility for those
interested in reading this codebase.
* Remove commented code from 2 years ago
* Clarify uncommunicative naming in services classes
There is some context for this change in 6b81880f
* Clarify uncommunicative naming in models
There is some context for this change in 6b81880f
* Clarify uncommunicative naming in liquid_tags
There is some context for this change in 6b81880f
2019-09-02 13:05:07 -04:00
cyrillefr
5146532c82
Move messages send_push delay calls to ActiveJob ( #3314 )
2019-07-08 18:00:19 -04:00
Ben Halpern
70580d0265
[WIP] Connect misc improvements/debugs ( #2880 )
...
* WIP Connect misc improvements/debugs
* Modify tests and update snapshots
* Change GitHub sidecar copy
2019-05-20 10:08:51 -04:00
Abraham Williams
9cb40e546b
Enables Rails cops ( #2186 )
...
* Enable Rails cops
* Fix Rails/DynamicFindBy
* Fix Rails/HttpStatus
* Fix Rails/Blank
* Fix Rails/RequestReferer
* Fix Rails/ActiveRecordAliases
* Fix Rails/FindBy
* Fix Rails/Presence
* Fix Rails/Delegate
* Fix Rails/Validation
* Fix Rails/PluralizationGrammar
* Fix Rails/Present
* Fix Rails/Output
* Fix Rails/Blank
* Fix Rails/FilePath
* Fix Rails/InverseOf
* Fix Rails/LexicallyScopedActionFilter
* Add Rails/OutputSafety to TODO
* Add Rails/HasManyOrHasOneDependent to TODO
* Add Rails/SkipsModelValidations to TODO
2019-03-25 09:25:55 -04:00
Tim Lange
3494264404
Enabled rubocop/lint ( #2130 )
...
* WIP: Enabled rubocop/lint
* FIX: Fixed failing test
* FIX: Small change to return
* FIX: Changed indent
2019-03-21 10:53:44 -04:00
Keshav Biswa
8d57d45ecc
Rubocop Style cops enabled ( #2056 )
...
* Rubocop enabled style/alias
* Enabled Style/ArrayJoin Cop
* Enabled Style/Attr
* Enabled Case Equality
* Enabled CharacterLiteral
* Enabled ColonMethodCall Cop
* Enabled CommentAnnotation cop
* Enabled PreferredHashMethods Cop
* Enabled DoubleNegation Cop
* Enabled EachWithObject Cop
* Enabled EmptyLiteral Cop
* Enabled EvenOdd Cop
* Enabled IfWithSemicolon Cop
* Enabled Lambda and LambdaCall Cop
* Enabled LineEndConcatenation Cop
* Enabled ModuleFunction Cop;
* Enable NegatedIf and NegatedWhile Cop
* Enabled NilComparison Cop
* Enabled Not Cop
* Enabled NumericLiterals Cop
* Enabled OneLineConditional Cop
* Enabled PercentLiteralDelimiters Cop
* Excluded internal/users_controller from negated_if cop
* Reverted the double negation change from github_issue_tag and github_issue.rb"
* Enabled PerlBackrefs Cop
* Changed Regexp.last_match(1) to Regexp.last_match(0)
* Enabled proc cop
* Enabled RaiseArgs Cop
* Reverted Regexp.last_match(0) to Regexp.last_match(1)
* Enabled SelfAssignment Cop
* Enabled SingleLineMethods Cop
* Enabled SpecialGlobalVars Cop
* Enabled VariableInterpolation Cop
* Enabled WhenThen Cop
* Enabled WhileUntilModifier Cop
* Enabled WordArray Cop
* Enabled IfUnlessModifier Cop
* Enabled GuardClause Cop
2019-03-15 18:33:54 -04:00
rhymes
dee7429883
Replace each with find_each for AR queries ( #1557 )
2019-01-15 16:38:03 -05:00
Mario See
8bb1716935
connect chat message markdown styling ( #1487 )
...
* remove inline markdown rule
* broaden evaluate_inline_markdown
basically same as evaluate_markdown but without class attributes
* remove inline markdown parser
* change code block color and background
* even out code padding top/bottom
2019-01-08 17:48:12 -05:00
rhymes
6553f08d94
Rubocop cleanups ( #1415 )
...
* Update rubocop-todo.yml with new violations
* Fix Layout/EmptyLine* rules
* Fix Layout/Indentation* rules
* Fix remaining Layout/* rules
* Fix Lint/DuplicateMethods by removing unused accessor
* Fix Lint/IneffectiveAccessModifier
* Fix Lint/MissingCopEnableDirective
* Re-run rubocop auto gen config
* Fix Layout/RescueEnsureAlignment
* Fix Naming/* rules
* Fix some RSpec/* rules
* Fix typos
* Fix RSpec/LetBeforeExamples
* Series should only be an attr_writer, not an attr_accessor
* Fix RSpec/InstanceVariable
* Fix RSpec/InstanceVariable
* Fix RSpec/RepeatedDescription and RSpec/RepeatedExample
* Fix Style/ClassAndModuleChildren
* Fix Style/ConditionalAssignment
* Fix some Style/* rules
* Trigger Travis CI build because failing tests are not failing locally
* Revert "Fix Style/ClassAndModuleChildren"
This reverts commit 1686801d8a1516ba1894f79e24401a20dea65f99.
2019-01-02 11:20:02 -05:00
Ben Halpern
b34ee48c1f
Fix hanging /connect notification issue ( #1174 )
...
* Adjust channel opened check to mitigate race conditions maybe
* Add fix to jump user straight to apporpriate unopened channel
2018-11-21 12:08:09 -05:00
Maksim Litvinov
33db32e5f4
Fix rubocop lints ( #794 )
2018-10-03 13:00:09 -04:00
Ben Halpern
01e43a99e7
Fix /connect bug and add email-if-inactive functionality ( #482 )
...
* Add basic functionality for connect message emails
* Fix lint
* Add connect messages email permission
2018-08-27 14:29:53 -04:00
rhymes
e588fa7ece
Code cleanups ( #659 )
...
* Initial automatic cleanup with rubocop
* Fix syntax error introduced by rubocop
* Cleanup seeds file
* Cleanup lib folder
* Exclude bin folder because it contains auto generated files
* Make Rubocop a little bit more chatty
* Block length should not include comments in the count
* Cleanup config folder
* Cleanup specs
* Updated Rubocop version and generated a todo file
* Fix broken ArticlesApi spec
* Fix tests
* Restored rubocop pre-commit hook
2018-08-07 11:00:13 -04:00
Ben Halpern
05789f6ef6
Add client-side /connect maxlength and add badge setting on model only ( #660 )
2018-08-06 10:45:01 -04:00
Mac Siri
40f488d991
Migrate to Travis CI (part 2) ( #591 )
...
* Update Travis.yml
* Update README
* Update README
* Adjust test to not rely on env vars
* Update encryption
* Refactor
* Update env key
* Stub AWS calls
* Create ApplicationConfig
* Fix specs
* Fix lint
* Update ApplicationConfig
* Remove travis env vars
* Fix lint
* Extend character limit to 100
* Add env to travis
* Take out auto-restart after deploy
* Immediately discarded test cache
* Stub GA in request specs
* Stub Pusher
* Fix broken specs
* Update fixture
* Add CodeClimate id
* Change CodeClimate key
* Remove merge mistakes
* WIP
* Add Envied gem & Change README
* Add missing keys
* Add missing key
* Update fixture
* Fix broken spec
* Add Slack Notification for Travis
* Fix wording
* Fix typo
2018-07-20 20:17:18 -04:00
Ben Halpern
e2dbd7cfcc
Remove beta label on /connect and other small changes ( #589 )
...
* Remove beta label on /connect and other small changes
* Add better placeholder for narrow screens
* Adjust comma/bracket placement
* Add description to chat channels
2018-07-16 14:48:38 -04:00
Arun Kumar
9b753a4e9c
Refactor channel permission method ( #584 )
2018-07-16 10:55:18 -04:00
Ben Halpern
e995e081ad
Add rich links to /connect and remove auto sidecar opening ( #582 )
2018-07-13 16:56:26 -04:00
Ben Halpern
926991f5fc
Fix timezone issues and small adjustment to connect features ( #548 )
2018-07-05 16:39:04 -04:00
Ben Halpern
eaa13a53fb
Update serviceworker notficiations
2018-07-03 19:06:23 -04:00
Ben Halpern
5194c9828c
Add proper pagination and fix small issues with /connect ( #503 )
...
* Add proper pagination and fix small issues with /connect
2018-06-27 16:06:15 -04:00
Ben Halpern
0941b2e4fb
Add some tests around model validations ( #459 )
...
* Modify sample_application.yml and write test
* Add ahrefs verification
* Add some tests around model validations
* Indent an end
* Add a few tests
* Add tests and reserved words
* Fix live articles spec typo
* Modify ga_events_controller
2018-06-20 17:14:08 -04:00
Ben Halpern
74d098f580
Fix bugs and add video
2018-06-18 12:53:43 -04:00
Ben Halpern
e124decabc
Adjust messages_controller to send message before it is persisted if it is valid ( #434 )
2018-06-13 17:35:17 -04:00
Ben Halpern
7d018f049e
Make adjustments and fixes to DEV Conncect ( #427 )
...
* Make adjustments and fixes to DEV Conncect
* Make various small changes and add settings icon
2018-06-13 14:46:30 -04:00
Ben Halpern
87c6a758bb
Add top bar indicator and other Connect features ( #424 )
...
* Add algolia public search key
* Add status to chat_channels
2018-06-12 18:24:57 -04:00
Ben Halpern
cfb0bff881
Fix /live and codemirror stuff ( #417 )
2018-06-11 14:56:52 -04:00
Ben Halpern
7bc3e60283
Add browser push notifications (attempt) ( #412 )
2018-06-09 17:33:58 -04:00
Ben Halpern
bf56ad5cb4
Add message HTML and other goodies ( #411 )
2018-06-08 23:15:21 -04:00
Ben Halpern
ab85216621
Update chat and modify article score calc indexing ( #395 )
2018-06-06 16:08:12 -04:00
Ben Halpern
4171a0814a
Add basic alpha DM functionality to chat ( #375 )
...
* Initial chat DM features
* Update functionality for DM chats
2018-06-01 16:21:48 -04:00
Mac Siri
7cb65649e4
Update chat app ( #326 )
...
* Fix spacing
* Update webpacker gem to 3.5
* Add custom preact-compact config
* Add babel-loader to resolve a weird issue
* Add react-textarea-autocomplete
* Move 2 dependencies into devDependencies
* Add babel-eslint & eslint-plugin-babel
* Refactor chat
* Add fixed width to chat's channels
* Add timestamp for chat
* Fix long word issue
* Add showTimestamp options to chat
* Add profile image to chat
* Make profile image in chat circle
* Improve message send logic
* Add proper user session handling for chat
* Choose profile user image source for chat
* Adjust user's text color
* Fix lint
2018-05-21 13:19:56 -04:00
Mac Siri
b4292ade33
Implement chatroom ( #308 )
...
* Fix multiple chat loading bug
* Open profile links in chat via new tab
* Add unmount handling for chat
* Add overscroll property to chat
* Add channel_name to ChatChannel model
* Create route and page for chatroom WIP
* Expose ChatChannel id to live page
* Implement multichannel support WIP
* Implement chatroom page WIP
* Add css for chatroom
* Update chat's moderation
* Refactor chat's message type
* Swap the use of :message_markdown & :message_html
* Add channel permissions WIP
* Fix failing specs
* Adjust json reponses
* Add empty message prevention
* Update participant error message
* Change Workshop channel to General
2018-05-14 12:50:32 -04:00
Mac Siri
8003191a4e
Create Chat app ( #175 )
...
* Setup Pusher gem
* Create ChatChannel and Message model
* Create ChatChannelController
* Add back fix-db-schema-conflicts gem
* Add pusher-js package
* Add validations on Message & ChatChannel models
* Update Route
* Create MessageController
* Update ChatChannelController
* Create Chat app WIP
* Extract messenger render to Message Component
* Implement live chat WIP
* Implement live chat WIP (2)
* Add style and scrollToBottom feature for chat
* Create getUserDataAndCsrfToken function
* Add feature toggle to the new live chat
* Clean up ChatChannelsController & create spec
* Update ChatChannel spec
* Update Message spec
* Create MessagesController spec & refactor
* Clean up Chat app
* Fix lint
* Add character limit to Message
2018-04-04 14:19:57 -07:00