Commit Graph

99 Commits (d04c02ac37e44a76d181588b933899a990468d8d)

Author SHA1 Message Date
Yamagishi Kazutoshi 19b8a7cf19 Add "private: true" to package.json (#3441) 2017-05-30 16:11:45 +02:00
Yamagishi Kazutoshi 60842608aa Remove unused React Storybook addon (#3434) 2017-05-30 15:12:12 +02:00
Yamagishi Kazutoshi 53d9bebaf3 Update dependencies of Node.js (#3067)
* Update autoprefixer to version 7.1.0

* Update axios to version 0.16.1

* Update babel-cli to version 6.24.1

* Update babel-eslint to version 7.2.3

* Update babel-preset-react to version 6.24.1

* Update coffee-script to version 1.12.6

* Update css-loader to version 0.28.1

* Update express to version 4.15.2

* Update js-yaml to version 3.8.4

* Update mocha to version 3.4.1

* Update jsdom to version 10.1.0

* Update npmlog to version 4.1.0

* Update postcss-smart-import to version 0.7.0

* Update postcss-loader to version 2.0.5

* Update pg to version 6.1.5

* Update prop-types to version 15.5.10

* Update rails-ujs to version 5.1.1

* Update redis to version 2.7.1

* Update sass-loader to version 6.0.5

* Update stringz to version 0.2.0

* Update webpack to version 2.5.1

* Update style-loader to version 0.17.0

* Update sinon to version 2.2.0

* Update react-motion to version 0.5.0

* Update react-notification to version 6.7.0

* Update react-redux-loading-bar to version 2.9.0

* Update react-intl to version 2.3.0

* Update redux-immutable to version 4.0.0

* Update reselect to version 3.0.1

* Update react-toggle to version 3.0.1

* Update react-simple-dropdown to version 3.0.0

* Update react-router to version 3.0.5

* Update react-router-scroll to version 0.4.2

* Update react-toggle to version 4.0.1

* yarn upgrade
2017-05-29 18:23:28 +02:00
Eugen Rochko 1245d4fdbc Improve streaming API cluster logging (#3370)
* Improve streaming API cluster logging

* Less verbose error middleware logging (stack trace useless there)

* Fix error logging

* Prevent potential issue

* Add missing "done()" in catch of Promise.all, websocket heartbeat re-implemented like in example

* I actually forgot a done(), the absolute madman
2017-05-28 16:25:26 +02:00
Eugen Rochko e600e0d0c5 Introduce react-textarea-autosize instead of using style.height side effects (#3334) 2017-05-26 18:22:23 +02:00
Nolan Lawson b69a1f599a Add improved performance marks for development mode (#3297) 2017-05-25 14:09:55 +02:00
Yamagishi Kazutoshi 19241464e8 Add localization of datetime in public page (#3296) 2017-05-25 14:09:25 +02:00
Yamagishi Kazutoshi fb854c1014 fix storybook (#3292) 2017-05-25 05:23:14 +02:00
Sorin Davidoi 5efcea69d2 Lazy load toots using IntersectionObserver (#3191)
* refactor(components/status_list): Lazy load using IntersectionObserver

* refactor(components/status_list): Avoid setState bottleneck

* refactor(components/status_list): Update state correctly

* fix(components/status): Render if isIntersecting is undefined

* refactor(components/status): Recycle timeout

* refactor(components/status): Reduce animation duration

* refactor(components/status): Use requestIdleCallback

* chore: Split polyfill bundles

* refactor(components/status_list): Increase rootMargin to 300%

* fix(components/status): Check if onRef is not defined

* chore: Add note about polyfill bundle splitting

* fix(components/status): Reduce animation duration to 0.3 seconds
2017-05-24 17:55:00 +02:00
Nolan Lawson bde004c68c Use node instead of babel-node for streaming (#3269) 2017-05-24 00:45:05 +02:00
Yamagishi Kazutoshi 5bb10252fa Focus the submit button (#3253)
Focus the submit button when confirmation modal is opened.

Also, changed cancellation link to button.
This makes the meaning clearer.
2017-05-23 13:10:41 +02:00
Nolan Lawson e228bdd3b6 Add webpack-bundle-analyzer for production builds (#3170) 2017-05-22 15:42:11 +02:00
Nolan Lawson 2d7aacf747 Only load Intl data for current language (#3130)
* Only load Intl data for current language

* Extract common chunk only from application.js and public.js

* Generate locale packs, avoid caching on window object
2017-05-22 15:06:06 +02:00
Yamagishi Kazutoshi e4ed0b155c Improve eslint rules (#3147)
* Add semi to ESLint rules

* Add padded-blocks to ESLint rules

* Add comma-dangle to ESLint rules

* add config/webpack and storyboard

* add streaming/

* yarn test:lint -- --fix
2017-05-20 17:31:47 +02:00
Yamagishi Kazutoshi d1f83bee86 Remove react-autosuggest (#3140)
react-autosuggest is added from b91faaebbb

Dependence removed from d088b3cade
2017-05-19 15:21:34 +02:00
Yamagishi Kazutoshi 9ab33ded34 Downgrade eslint-plugin-jsx-a11y to v4.0.0 (#3131)
In Code Climate, eslint-plugin-jsx-a11y v4.0.0 is used.
Therefore, it seems that a warning is displayed.

ref https://github.com/codeclimate/codeclimate-eslint/pull/273
2017-05-19 11:44:28 +02:00
Sorin Davidoi 200a8b4c79 feat(babel): Strip prop types (#3122)
* feat(babel): Strip prop types

* chore(babel): Indent

* fix(babel): Move babel-plugin-transform-react-remove-prop-types to dependencies
2017-05-19 02:42:21 +02:00
Nolan Lawson a91765191b Add transform-runtime for smaller Babel helpers (#3116) 2017-05-18 19:14:58 +02:00
Yamagishi Kazutoshi 4a3038618f Use babel-preset-env on Streaming Server (#2998)
* Use babel-preset-env on Streaming Server

Change the streaming server to use babel-preset-env as well as asset compilation.
This shortens the load time at first boot.

* remove babel-plugin-lodash
2017-05-14 13:47:31 +02:00
Yamagishi Kazutoshi 7bc8be7915 Remove Babel plugin for ES Modules (#2975)
* Remove Babel plugin for ES Modules

Processing of ES Modules is executed by Webpack.
Don't have to do it on Babel side.

* Add plugin for test
2017-05-14 12:59:40 +02:00
Daigo 3 Dango cb2738f6d0 Rebuild node-sass (#3002)
Got an error in asset precompile on Heroku:
Module build failed: Error: ENOENT: no such file or directory, scandir '/tmp/.../node_modules/node-sass/vendor'

ref: https://github.com/rails/webpacker#troubleshooting
2017-05-12 22:04:41 +02:00
Yamagishi Kazutoshi 2d254f9733 Use ES Class Fields & Static Properties (#3008)
Use ES Class Fields & Static Properties (currently stage 2) for improve class outlook.

Added babel-plugin-transform-class-properties as a Babel plugin.
2017-05-12 14:44:10 +02:00
Yamagishi Kazutoshi 64b3e75585 Remove dependencies that are no longer needed now (#2999)
There are some dependencies that are no longer needed anymore.
As a result, it took more time to install the package than necessary.

I want to delete them and shorten the installation time.
2017-05-12 04:04:41 +02:00
Nolan Lawson 4692cc8d98 Add dynamic polyfills for older browsers (#2985)
Fixes #2941
2017-05-11 11:26:06 +02:00
Yamagishi Kazutoshi 84a4758114 Remove jquery-ujs (#2939)
* Remove jquery-ujs

* fix for eslint
2017-05-09 14:50:43 +02:00
Yamagishi Kazutoshi f1bf2214bc Remove local_time gem, and add similar (#2875) 2017-05-07 15:22:54 +02:00
Nolan Lawson fa96b86b64 upgrade emojione-picker (#2874) 2017-05-07 15:22:42 +02:00
Nolan Lawson c9e8d229a4 add asynchronous emojione-picker (code-splitting) (#2863) 2017-05-07 02:42:38 +02:00
Koala Yeung 94460603c0 Eslintrc fix (#2850)
* eslintrc: adapt changes in eslint-plugin-jsx-a11y

* Replace 'jsx-a11y/img-has-alt' with 'jsx-a11y/alt-text'.
  Reference: evcohen/eslint-plugin-jsx-a11y@24b6193

* Replace 'jsx-a11y/onclick-has-focus' with 'jsx-a11y/interactive-supports-focus'
  Reference: evcohen/eslint-plugin-jsx-a11y@cbdfeb8

* Replace 'jsx-a11y/onclick-has-role' with 'jsx-a11y/no-noninteractive-element-interactions'
  Reference: evcohen/eslint-plugin-jsx-a11y@18c9b71

* Update eslint-plugin-jsx-a11y to 5.0.0

Follow the change in Code Climate. Make sure the same eslintrc
can be executed locally and in Code Climate.

* Convert .eslintrc.json to equivlant .eslintrc.yml

* Less quotes and commas, more readability, allow comment.
2017-05-06 21:26:54 +02:00
Eshin Kunishima 0a9c2152c9 Replace ws with uws (#2807)
* Replace ws with uws

* fix indent

* Adjust indentation

* remove trailing space
2017-05-06 17:05:38 +02:00
Nolan Lawson 63ad61a2b6 remove legacy decorators, use lodash.debounce (#2830) 2017-05-06 11:05:32 +02:00
Yamagishi Kazutoshi 842f4fab9f Move babel-plugin-lodash to dependencies from devDependencies (#2831) 2017-05-06 11:04:55 +02:00
Nolan Lawson 7a874f1f98 separate .babelrc for prod/dev, add babel-plugin-lodash (#2829) 2017-05-06 04:18:23 +02:00
Koala Yeung b1f14a1c7f Streamline javascript translation by improving translationRunner (#2808)
* package.json: Add "build:*" targets

* Improve react-intl-translations-manager workflow.
  * Added "build:production" to build production bundle.
  * Added "build:development" to build development bundle.

* Fix json translation files

* Run `yarn manage:translations` to fix translation files.
* Fix `pl.json` for syntax error.

* translationRunner: auto detect existing languages

* Auto detect existing rfc5646 language tag in *.json filenames
  in `app/javascript/mastodon/locale` folder. No need to manually
  define every new language in the languages array here.

* translationRunner: add more functionality

* Allow script user to specify language code to check.
* Added available language check.
* Added --force flag to force creation of unexists language.
* Added --help flag and help messages.

* gitignore: ignore npm-debug.log

* Fix webpack error if NODE_ENV is not defined

Default to use 'development' in config/webpack/configuration.js
2017-05-06 04:05:38 +02:00
Yamagishi Kazutoshi 93ec05f976 Decode IDNA in PreviewCard (#2781) 2017-05-04 15:52:08 +02:00
Eugen Rochko ef2af79a48 Replace sprockets/browserify with Webpack (#2617)
* Replace browserify with webpack

* Add react-intl-translations-manager

* Do not minify in development, add offline-plugin for ServiceWorker background cache updates

* Adjust tests and dependencies

* Fix production deployments

* Fix tests

* More optimizations

* Improve travis cache for npm stuff

* Re-run travis

* Add back support for custom.scss as before

* Remove offline-plugin and babili

* Fix issue with Immutable.List().unshift(...values) not working as expected

* Make travis load schema instead of running all migrations in sequence

* Fix missing React import in WarningContainer. Optimize rendering performance by using ImmutablePureComponent instead of
React.PureComponent. ImmutablePureComponent uses Immutable.is() to compare props. Replace dynamic callback bindings in
<UI />

* Add react definitions to places that use JSX

* Add Procfile.dev for running rails, webpack and streaming API at the same time
2017-05-03 02:04:16 +02:00
Michael Deeb 2d7bc2267c Added the repository field and a script for after npm version (#2459) 2017-04-26 01:51:51 +02:00
Ash Furrow 109d1bdcda Fixes string length issue for multibyte characters. (#2443) 2017-04-25 17:37:51 +02:00
Keiji, Yoshimi 89ad73a9af update emojione-picker for fixed warnings. (#2324) 2017-04-22 17:28:02 +02:00
Yamagishi Kazutoshi 542c134ed4 Remove deprecated features at React v15.5 (#1905)
* Remove deprecated features at React v15.5

- [x] React.PropTypes
- [x] react-addons-pure-render-mixin
- [x] react-addons-test-utils

* Uncommented out & Add browserify_rails options

* re-add react-addons-shallow

* Fix syntax error from resolve conflicts

* follow up 0ab0db9fe7
2017-04-21 20:05:35 +02:00
Mingye Wang 0fd613d2dc Use new ESLint filename (.json) (#2248)
* Use new ESLint filename (.json)

Codeclimate's ESLint 3 is complaining about the old filename. Let me try changing it.

* point eslint to new rc

(squash this)
2017-04-21 16:43:57 +02:00
Christoph Witzany 23b457c287 Make Docker image buildable on ARM (#2065)
* after yarn upgrade

* after manually removing node-gyp as top level dependency
2017-04-20 13:29:38 +02:00
Alda Marteau-Hardi f0cfb2cb90 Add the licence key in package.json (#1914) 2017-04-16 16:08:11 +02:00
Zac Anger 4afb6d9b15 Add eslint-plugin-jsx-a11y (#1651)
* Add eslint-plugin-jsx-a11y.

* Fix npm script.

* Adjust npm scripts so test also runs lint.

* Fix existing lint errors.

* Don't break on a11y issues.

* Add role and tabIndex.

* Add vim and Mac files to .gitignore and .dockerignore.

* Handle htmlFor (partially), a that's actually a button.

* Fix missing tabIndex.

* Add cursor:pointer to load-more

* Revert change to load_more.

* Fixes based on review.

* Update yarn.lock.

* Don't try to install fsevents on Linux (hides warning noise).
2017-04-15 13:27:27 +02:00
Eugen 5122f9ab3b Fix #1491 - Fix broken notifications, broken Link header parsing for exclude_types (#1548) 2017-04-11 22:53:58 +02:00
Gavin Mogan a710eec95c Dev Tooling fixes (eslint/editorconfig) (#1398)
* Add eslint to dev dependancies so it gets installed for the repo

yarn add --dev eslint babel-eslint eslint-plugin-reac

project specific version of eslint, you can globally install eslint-cli
if you want the global runtime, or add .bin to your path

* fix eslint errors about inconsitent returns

* eslint ignore the same as git ignore. allows for eslint .

* Add editorconfig file so everyones editor will be setup to follow the same standards
2017-04-11 00:36:03 +02:00
Eugen Rochko cdbfbbc691 Improve emojis - use SVGs where possible 2017-03-29 22:27:24 +02:00
Eugen Rochko b6dff981a2 Replace howler.js with simple <audio />, will hopefully resolve
some weird mobile browser behaviours
2017-03-13 17:12:30 +01:00
Eugen Rochko 6ded139be0 Fix #372 - Emoji picker 2017-03-02 00:57:55 +01:00
Eugen Rochko a24f95ae92 Fix broken dependency on inner react utility function 2017-02-26 01:34:56 +01:00