Commit Graph

5906 Commits

Author SHA1 Message Date
Kevin Ansfield
d9d8446f02 deps: jscs@2.6.0 & ember-suave@1.2.3
no issue
- fixes an error that popped up after ember-suave's `brocolli-jscs` dependency moved to `2.6.0` which duplicated some of the rules that `ember-suave` used to implement
2015-12-04 09:58:03 +00:00
Austin Burdine
9f827204df fix 404 error handling in editor, tags, and team routes
closes #6094
- adds 404-handler mixin
- applies mixin to settings/tags/tag, editor/edit and team/user routes
- adds adapter-error test helper to override the default adapter error
2015-12-03 16:37:23 -06:00
Sebastian Gierlinger
67c93cb90d Merge pull request #6168 from ErisDS/labs-sync
Change server-side labs utility to be synchronous
2015-12-03 21:25:53 +01:00
Hannah Wolfe
4bfacf6b86 Change server-side labs utility to be synchronous
refs #6165

- Use the settings cache to populate config.labs whenever settings change
- Use the labs util just to check if a flag isSet synchronously
2015-12-03 16:05:50 +00:00
Hannah Wolfe
ea8533842d Merge pull request #6122 from kevinansfield/slug-query-with-include
Add count.posts support to user model on client
2015-12-03 14:48:21 +00:00
Gary Cao
75845ce4af Checkbox labels are cut off on mobile.
closes #6089
2015-12-02 18:28:50 +09:00
Sebastian Gierlinger
bc83dbce09 Merge pull request #6145 from ErisDS/view-refactor
Unify code for picking a template to render with
2015-12-02 10:02:31 +01:00
Sebastian Gierlinger
e5e5b1138a Merge pull request #6159 from bhops/cleanup
Remove undefined function in middleware
2015-12-02 10:00:31 +01:00
Brandon Hops
e5ee97bece Remove undefined function and fix some comments 2015-12-01 23:28:36 -08:00
Hannah Wolfe
7ebc7f7ff1 Merge pull request #6126 from sebgie/option-restore
Restore options
2015-12-02 12:13:36 +08:00
Hannah Wolfe
f8a05c533a Merge pull request #6154 from kevinansfield/use-embers-jquery
Remove `$` from jshint's predef, always use Ember's `$`
2015-12-02 12:07:54 +08:00
Hannah Wolfe
9f4c6957de Merge pull request #6155 from StevenMcD/issue_6140
Add .git folder to ignore folders list
2015-12-02 12:07:25 +08:00
Hannah Wolfe
1ba9929c59 Merge pull request #6058 from sebgie/middleware-refactor
OAuth Middleware refactor
2015-12-02 12:07:01 +08:00
Kevin Ansfield
413d999462 Remove $ from jshint's predef, always use Ember's $
no issue
- fixes problems with "re-definition of $" errors
2015-12-01 20:52:25 +00:00
Sebastian Gierlinger
ee275f4d0c OAuth Middleware refactor
refs #5286
- moved oauth server initialization to oauth.js
- moved generateAccessToken() to oauth.js
- added tests
2015-12-01 21:20:11 +01:00
StevenMcD
6956985c28 Add .git folder to ignore folders list
closes #6140
- simply added '.git' to the list of folder names to ignore when checking for valid themes.
2015-12-01 21:14:23 +02:00
Kevin Ansfield
81765c6af2 Fix sub-dir being added to navigation urls when installed in sub-dir
refs #4989
- fix handling of urls relative to base domain when ghost is installed in a sub folder

Fixes an issue when ghost was installed to a sub-dir, e.g. `example.com/blog` and an attempt to link to `example.com/` or `example.com/something-else` would always be re-written to `example.com/blog/` or `example.com/blog/something-else`.
2015-12-01 15:23:21 +00:00
Sebastian Gierlinger
84c8149f6a Merge pull request #6152 from kevinansfield/cleanup-dependency
Remove unused `ember-resize` dependency
2015-12-01 14:58:24 +01:00
Kevin Ansfield
063f2c318c Merge pull request #6147 from garyc40/bug-uploader-bind
Properly binds "this" in uploader.js
2015-12-01 13:08:00 +00:00
Kevin Ansfield
f37a4b5580 Remove unused ember-resize dependency
no issue
- removes `ember-resize` dep that crept back in under the radar in the Ember 2.2 update
- updates `ember-cli-build`'s test dependencies to match the format specified in http://ember-cli.com/managing-dependencies/#test-assets
2015-12-01 11:03:53 +00:00
Kevin Ansfield
4ca82ed780 Merge pull request #5970 from acburdine/ember-2.1
Ember & Ember-Data 2.2 update
2015-12-01 10:56:52 +00:00
Hannah Wolfe
65fcd53f33 Merge pull request #6143 from acburdine/remove-casper
Remove casperjs from travis setup
2015-12-01 14:33:18 +08:00
Hannah Wolfe
8dbef11bc5 Updated node version text in README.md
no issue

- update README to match the new version support
2015-12-01 14:09:16 +08:00
Hannah Wolfe
395079cd2f Unify code for picking a template to render with
refs #5091

- 100% coverage for new frontend/templates file
- new module handles the logic for determining which template to render with
2015-12-01 12:05:46 +08:00
Gary Cao
e4c10c9688 Properly binds "this" in uploader.js
closes #6146
2015-12-01 12:50:31 +09:00
Austin Burdine
366e2fe3da deps: ember/ember-data@2.2.0 2015-11-30 12:23:47 -06:00
Kevin Ansfield
c884e67090 Merge pull request #6113 from acburdine/ember-cli-1.13.12
Update Ember-CLI to 1.13.13
2015-11-30 18:01:14 +00:00
Austin Burdine
ea64e5f8b6 remove casperjs from travis setup 2015-11-30 11:23:09 -06:00
Austin Burdine
7cbe7281a8 deps: ember-cli@1.13.13 2015-11-30 11:21:39 -06:00
Hannah Wolfe
8d5d89fb4a Merge pull request #6074 from kevinansfield/separate-travis-suites
Separate the client/server test suites on Travis
2015-11-30 23:46:52 +08:00
Kevin Ansfield
a102eff0ed Separate the server/client/lint test suites on Travis
no issue
- add separate grunt tasks for validating all/client/server test suites
- modify `grunt validate` to respect the `TEST_SUITE` env var if present
- default to `TEST_SUITE=server` on Travis
- add an individual builds to the Travis matrix that test the client and run linting as separate jobs
- don't run `ensureConfig` task if we're performing client-only tests

Previously we were duplicating the client tests and linting for every node and database version in our build matrix. Duplicating those tasks a waste of time/resources as the client tests are now completely isolated from the server and so different node/database versions have no effect. This PR is an attempt at removing the duplication to speed up our Travis runs.
2015-11-30 15:21:08 +00:00
Sebastian Gierlinger
fc9d9096aa Merge pull request #6078 from kevinansfield/always-call-super
Always call `_super` when using Ember hooks
2015-11-30 14:12:31 +01:00
Kevin Ansfield
571b9e783a Always call _super when using Ember hooks
no issue
- review use of Ember core hooks and add a call to `this._super` if missing
- fix a few occurrences of using the wrong component lifecycle hooks that could result in multiple/duplicate event handlers being attached

`_super` should always be called when overriding Ember's base hooks so that core functionality or app functionality added through extensions, mixins or addons is not lost. This is important as it guards against issues arising from later refactorings or core changes.

As example of lost functionality, there were a number of routes that extended from `AuthenticatedRoute` but then overrode the `beforeModel` hook without calling `_super` which meant that the route was no longer treated as authenticated.
2015-11-30 12:45:37 +00:00
Sebastian Gierlinger
e5d9865792 Merge pull request #6020 from kevinansfield/suave
Use ember-suave and standardise client's es6 usage
2015-11-30 12:46:39 +01:00
Kevin Ansfield
3d6856614f Use es6 across client and add ember-suave to enforce rules
no issue
- add ember-suave dependency
- upgrade grunt-jscs dependency
- add a new .jscsrc for the client's tests directory that extends from client's base .jscsrc
- separate client tests in Gruntfile jscs task so they pick up the test's .jscsrc
- standardize es6 usage across client
2015-11-30 10:41:01 +00:00
Kevin Ansfield
9437b8eeef Merge pull request #6108 from mixonic/no-rerender-selectors
Unify mobile state in JS, drop resize
2015-11-30 08:45:03 +00:00
Hannah Wolfe
1ce7f2251a Merge pull request #6136 from bhops/remove-405-test
Remove unused base_test.js
2015-11-30 10:06:26 +08:00
Brandon Hops
0a06af02d5 Remove unused base_test.js 2015-11-28 18:46:13 -08:00
Hannah Wolfe
55045ae784 Version bump to 0.7.2 2015-11-27 13:13:25 +08:00
Hannah Wolfe
2ea4f67dd4 Merge pull request #6131 from sebgie/issue#6106-1
Origin Header revisited
2015-11-27 00:32:51 +08:00
Hannah Wolfe
a8d13dd332 Merge pull request #6129 from kevinansfield/invalid-origin-errors
Display error message on setup if origin doesn't match config.js url
2015-11-27 00:25:57 +08:00
Hannah Wolfe
cd5188a32a Merge pull request #6130 from kevinansfield/missing-signin-error
Fix missing error on signin when server has gone away
2015-11-26 23:07:44 +08:00
Sebastian Gierlinger
245095c199 Origin Header revisited
closes #6106
- added override for my-ghost-blog.com
- added local IP addresses to be allowed
- changed localhost/127.0.0.1 to be allowed in production
2015-11-26 13:11:31 +01:00
Kevin Ansfield
0462dfed39 Display error message on setup if origin doesn't match config.js url
refs #6106
- add error handler for authentication step of blog setup
- move setup acceptance test out of 'settings' folder
2015-11-26 11:22:16 +00:00
Kevin Ansfield
f2c7e34c3f Fix missing error on signin when server has gone away
no issue
- `session.authenticate` calls out to jQuery for the ajax request which then raises it's own error but returns nothing when the server is not reachable. This is a quick fix so that we don't error and can pass through to the default error handler in the authentication step.
2015-11-26 11:15:17 +00:00
Sebastian Gierlinger
03760c3674 Merge pull request #6128 from ErisDS/startup-check
Docs link & unique error codes for startup checks
2015-11-26 10:32:22 +01:00
Hannah Wolfe
f25039c4b9 Docs link & unique error codes for startup checks
refs #5821, #6063

- switch out help test to go to a comprehensive doc
- change error codes from 1 to unique codes
2015-11-26 16:20:11 +08:00
Hannah Wolfe
34d329ef56 Upgrading Casper to 1.2.6 2015-11-26 09:33:40 +08:00
Matthew Beale
402b27c7e9 Unify mobile state in JS, drop resize
In `gh-content-view-container` the visibility of another DOM node was
being used to detect if a given view was mobile or not. This means the
UI needed to have layout forced (and DOM rendered) before the content
view container would render a second time. This is slow interaction with
the DOM (forcing layout) and slow for Ember's renderer (it needs to
render the container once with a default, then again when the value
changes).

Additionally there were two ways resize was being observed. The
`Window.matchMedia` API was used for some styles and the `ember-resize`
addon used to detect other changes. Here I've unified around just the
`Window.matcheMedia` API but abstracted it behind a service.

Sizes are exposed as properties that can be bound to or used directly in
templates.
2015-11-25 11:54:08 -05:00
Sebastian Gierlinger
014e2c88dd Restore options
refs #6122
- restore original options after delete
- this is a fix for one use case, long term we should aim to leave
options untouched and execute special queries with temporary data
2015-11-25 09:59:27 +01:00