Commit graph

70 commits

Author SHA1 Message Date
Ben Halpern
8b1755a2b3
Add organization to feed and adjust page styling (#1089)
* Add organization to feed and adjust page styling

* Add conditional indexing to article agolia

* Early return in algolia org logic

* Make org optional in algolia

* Modify org cta styling
2018-11-12 12:28:51 -05:00
Gautam krishna.R
b63380ba74 Disable reaction buttons until fetch completes (#989) 2018-11-12 10:38:01 -05:00
Ben Halpern
119b86c655
Fix action bar issue and adjust cache_buster (#1082) 2018-11-07 18:55:07 -05:00
Gatlee
b865ad9f69 Improve optimistic rendering to article reactions (#681)
* Refactor article reactions for increased readability and to insert optimistic rendering later. No functional changes

* Added optimistic rendering

* Fixed comments to fit with style

* Reverts state on error as well
2018-11-07 12:24:55 -05:00
Ben Halpern
302e8f202d
Add HTML variants for cta optimization and other nav bar adjustments (#970)
* Add HTML variants for cta optimization and other nav bar adjustments

* Fix 1==1 non-random mistake

* Spruce up org call-to-action

* Change default text color

* Add html variant trial and success request specs

* Fix article sidebar caching issue

* One line adjustment

* Modify schema

* Add include ActionView::Helpers::TagHelper to user_tag_spec

* Modify follow_button to remove session context

* Dummy commit

* Change Edit Article to Edit Post

* Dummy commit

* Fix rubocop concerns

* Fix rubocop style
2018-10-22 17:03:57 -04:00
Nick Karnik
2136b105a3 Implement ability to style text in comments using hotkeys (#959)
* Resolves #891
    * This is applied to root level comments as well as nested replies.
    * We are handling latest browsers and special cases for FF, IE8/9/10
    * All newer browser except FF support undo/redo functionality in the exact reverse order of text insertion
    * Refactored some code
    * Support for Bold & Italic text
    * Support for Text Links
    * In a subsequent change, we can consider adding hotkey for image URL
        * Didn't add this feature at the moment since there's no universally accepted key-combination for image URL's that I know of
    * IE 8-11 is not supported because it is a bit convoluted and I don't have a way to test it reliably
        * We can revisit this if it is really needed and find a jQuery plugin to handle it
2018-10-19 15:39:22 -04:00
Mac Siri
c35544a154 Replace sprocket-es6 with new uglifier feature (#928) 2018-10-19 13:12:07 -04:00
Ben Halpern
ca403ee01e
Adjust article show view css (revert sticky css) (#954)
* Adjust article show view css

* Change color subtly
2018-10-18 16:02:54 -04:00
Ben Halpern
8184baed83
Adjust analytics styling and accuracy (#951)
* Adjust analytics styling and accuracy

* Add video button back in
2018-10-18 12:19:49 -04:00
Ben Halpern
57fff54cd8
Remove es6 code from non-es6 area (#904) 2018-10-13 20:02:49 -04:00
Ben Halpern
221c363af0
Reduce queries in typical stories#show response + small fixes (#903)
* Reduce queries in typical stories#show response + small fixes

* Change const to git in non-es6 code
2018-10-13 19:38:38 -04:00
Nick Karnik
a3649b8d09 Added the ability to press Ctrl+Enter Or Command+Enter to submit comments. (#885)
* Resolves #245
    * This is applied to root level comments as well as nested replies.
    * We are ensuring that user has commented at least once which means
      they have accepted the code of conduct before

Style changes as per suggestions in code review
2018-10-13 14:24:53 -04:00
Ben Halpern
ecb9645775
Make changes to editor (#837)
* Make changes to editor

* Make minor fixes and console log removals

* Fix test in article form

* Adjust rspec test
2018-10-05 16:03:06 -04:00
Ben Halpern
483a7410af
Change impression event to view in Google Analytics (#805)
* Add tracking for home page featured impressions/clicks

* Change impression event to view in Google Analytics
2018-10-03 14:35:34 -04:00
Ben Halpern
a0491657dd
Add tracking for home page featured impressions/clicks (#804) 2018-10-03 14:05:00 -04:00
Ben Halpern
7e48a23afa
Ben/add more recent posts to home feed (#775)
* Add meta to sidebar and adjust ranking algo

* Update home feed to show more recent posts from folks you follow

* Only show recent posts on home feed if user signed in
2018-09-30 14:05:59 -04:00
Ben Halpern
4205d50bd8
Make home feed more relevant and varied (#757) 2018-09-27 13:21:51 -04:00
Ben Halpern
8074113663
Revert linting issues (#651) 2018-09-13 15:18:19 -04:00
Ben Halpern
dd32580ab1
Make article actions bar sticky (#648)
* Make article actions bar sticky

* Fix article load edge case

* Fix logic check
2018-09-13 13:52:35 -04:00
Ben Halpern
eeb408511a
Add extra caching to home query (#643)
* Update home feed logic and display

* Remove console log

* Add extra caching to home query

* Fix conflict
2018-09-12 16:34:10 -04:00
Ben Halpern
91f99036df
Update feed for slightly more customized top articles (#642)
* Update home feed logic and display

* Remove console log
2018-09-12 15:27:54 -04:00
Andy Zhao
7d7863da1f Add nofollow to /moderate links (#592) 2018-09-04 17:09:28 -04:00
AshWhitear
ce45d0ef81 Update all necessary follow buttons on click (#433) 2018-08-28 15:34:09 -04:00
Jonny Buchanan
34efec4b5d Stop using the Fake Notifications Dark Pattern (#288) 2018-08-08 18:31:35 -04:00
Andy Zhao
2e0929f438 Scroll to typing cursor to prevent weird skipping (#644) 2018-08-01 10:10:49 -04:00
Andy Zhao
92e7e109f2 Remove resizing function from old editor (#640)
* Remove resizing function from old editor

* Move return statement to only jump function
2018-07-31 15:33:46 -04:00
Ben Halpern
1181a952ed
Fix small caching issues and adjust serviceworker logic (#632)
* Fix small caching issues and adjust serviceworker logic

* Assign state to follow buttons to avoid refetch

* Modify serviceworker push issue

* Change asset_path to javascript_pack_path in serviceworker

* Change javascript_pack_path to javascript_path in serviceworker

* Remove javascript_path for now
2018-07-30 10:43:29 -07:00
Andy Zhao
6c937df21c Filter out user input name (#633) 2018-07-30 07:55:45 -07:00
Mac Siri
0f3342bcec [WIP] Implement non front-matter editor (#415)
* Create alternate editor

* Install linkstate (?)

Not sure how it disappear in the first place

* Run yarn install

* Modulize ArticleForm component

* Refactor

* Isolating css WIP

* Implement simplified frontmatter-less editor

* Modulize individual form element

* Ajust props names

* Transform json params to snakecase

* Remove codes

* Update /new, almost there for release

* Fix editor resize issues

* Change defaultvalue to value in article form tag element

* Modify html buttons in article form
2018-07-27 20:12:33 -07:00
Mac Siri
9e19593559 Change mods-actions' display logic (#630)
* Add username to deploy-track

* Change mod-actions' show logic

* Remove comment
2018-07-27 11:55:14 -07:00
Mac Siri
379829719f Misc DX improvement (#621)
* Add updated rack env keys

* Tone-down rack-timeout config

* Avoid cl_image_path in development

* Update README & create env var template

* Update Travis notification config

* Expand Seed file

* Manually-set Rack-timeout config vars

* Fix lint

* Fix Typo(?)

* Add ChatChannel to Seed

* Disable fbq when not in production

* Tweak after_deploy script

* Fix condition

* Change fbq clause
2018-07-25 22:08:17 -07:00
Ben Halpern
7edb371cba
Remove ENV var for algolia and make global var (#609)
* Remove ENV var for algolia and make global var

* Add :: and give test value to ALGOLIASEARCH_PUBLIC_SEARCH_ONLY_KEY
2018-07-21 12:09:14 -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
Nick Taylor
18980034d3 Nick/feature/search to preact (#532)
* Works, but lots of cleanup/questions.

* Fixed comment.

* Only want the search script to load once with InstantClick active.

* Removed unnecessary DOMContentLoaded from copy paste.

* 🔧 Enabled (P)React Devtools.

* Updated comment about reactToEvent.

* Removed unnecessary server-side generated JS for search.

* <Search /> component now has component state.

* Search functions are in there own module now.

* 👷Refactor

* Render propped it up.

* Fixed issue with encoding of search term.

* Removed data-no-instant attr from script.

* 👷Refactor

* Now flash of search loading is avoided..

* Moved search under components folder.

* Tests

* fixedEncodeURIComponent does not need to be exported.

* Tests

* Folders to ignore from the VS Code Local History extension.

* Tests

* Snapshot test for <Search /> component.

* Tests

* Now the <SearchContainer /> handles the '/' key shortcut.

* Made the search box ID a prop defaulting to 'nav-search'

* Excluded barrel files from code coverage.

* Componentized search CSS.

* Storybook stories for <Search /> component.

* Removed extension folders to ignore.

* Fixed logic for "/" key triggering search.

* updated jest snapshot for <Search /> component.

* updated package.json lock file.

* Disabled the import/prefer-default-export rule.

* Now search term clears if not on a non-search results page.

* removed comment that is no longer valid.

* No longer using render prop for Search. Doesn't make sense as it's not stuff that is reused.

* Added preact-render-spy do dev deps.
2018-07-19 17:02:48 -04:00
Andy Zhao
41d028cc5a Use non-prettiered JS file instead (#563) 2018-07-10 14:54:31 -04:00
Andy Zhao
e7466fc436 [Done] Add Reaction Policy Spec (#547)
* Delete old files and combine into one spec

* Write new reaction request spec

* Use a single route for logged in/out reaction count

* Refactor a bit

* Remove unused file

* Add reaction policy and spec

* Fix eslint issue

* Remove dead route
2018-07-10 14:12:04 -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
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
Jess Lee
ce082da041 Display Sidebar & Local Time For Events (#438)
* show timestamp in local time

* Implement initializeTimeFixer

* Add Misc work WIP

* add local time to calendar event

* add local dates

* update localtime for calendar event

* show timestamp in local time

* Implement initializeTimeFixer

* Add Misc work WIP

* add local time to calendar event

* add local dates

* update localtime for calendar event

* return if no utc times on page

* add events sidebar

* only show 3 events on sidebar

* Change wording on events header

They won't all be streams
2018-06-19 10:51:20 -04:00
Andy Zhao
cfd95a65af Update "Connect Twitter acct" in settings with new callback url (#439)
* Update "Connect Twitter acct" in settings with new callback url

* Remove name from comments (#437)
2018-06-15 12:52:14 -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
04aa888d5c
Add inline moderation buttons (#401) 2018-06-07 12:47:31 -04:00
Ben Halpern
ab85216621
Update chat and modify article score calc indexing (#395) 2018-06-06 16:08:12 -04:00
Ben Halpern
8d6b0d868d
Modify and finalize live now for events (#346)
* Add MVP for live events

* Modify and finalize live now for events

* Add profile to front end of live article indicator

* Check for footer container before doing calculations on it
2018-05-23 14:46:46 -04:00
Ben Halpern
f073eb5754
Add badges and org cta (#324)
* Make org proof a required field

* Fix color picker and other minor org adjustments

* Add MVP of org add'l sidebar

* Add proof to org factory

* Fix org create action and fix tests

* Add new org fields to admin panel & lint

* Add proof to org edit for backward compatibility

* Add org info to edit preview

* Move preview edit notice to inside article div

* MVP of badge "final" steps

* Add info to user sidebar and clean up badge commit

* Modify sidebar for data

* Add organization decorator

* Add conditional so only users have new swipe nav, not orgs

* Add cloudinary prefix to badges

* Disallow duplicate badges
2018-05-17 18:22:37 -04:00
Andy Zhao
f1cd542427 Add follow tracking for orgs with working follow (#300) 2018-05-10 09:54:46 -04:00
Ben Halpern
2001963863
Misc change to styles (#255)
* Add user articles to sidebar

* Add organization save-all functionality

* Adjust articles that show up in side sticky bar

* Add conditional for @user_stickies to show up

* Misc change to styles

* Slight change

* Modified footer center show stuff
2018-04-28 16:55:11 -04:00
Mac Siri
4bc9020956 Implement comment preview feature (#223)
* Create #preview endpoint for CommentController

* Create comment preview button WIP

* Implement preview feature for reply comment W

* Style preview button CSS WIP

* Style preview button CSS WIP

* Tweak markdown toggle logic and add styling

* Update comment feature spec

* Add error handling for comment preview & fix lint

* Extract handleCommentPreview into it's own file

* Adjust functionality for comment preview [WIP]

* Modify comment preview functionality and CSS

* Adjust code style based on linter
2018-04-24 14:30:52 -04:00
Mac Siri
18f0003187 Use JSON instead of FormData for comment-creation (#216)
* Use JSON instead of FormData for comment-creation

* Fix lint
2018-04-17 17:32:45 -07:00
Ben Halpern
80de5a96a8
Modify copy and style of comment signin cta (#202) 2018-04-11 15:17:12 -07:00