Commit Graph

2307 Commits

Author SHA1 Message Date
Kevin Ansfield
b006eda9f0 Fix password reset
closes #6229
- removes `_super` call in the reset route's `setupController` hook to avoid a `model` property being set which was being picked up by the validation engine
- throw the error if we fail in the password reset process from something we aren't expecting
2015-12-15 21:51:36 +00:00
Kevin Ansfield
513ed0834b Merge pull request #6204 from kevinkucharczyk/unable-to-remove-small-background-image
Fix hidden delete button in image uploader for short images
2015-12-15 13:54:32 +00:00
Kevin Ansfield
ed62566946 Merge pull request #6160 from garyc40/bug-checkbox-labels
Checkbox labels are cut off on mobile.
2015-12-15 13:09:14 +00:00
Kevin Ansfield
c505262630 Remove setScrollClassName mixin and usage
no issue
- removes `setScrollClassName` mixin that was previously used to add a `.scrolling` class to scrollable elements that showed a shadow at the top of boxes when not scrolled to the top
2015-12-15 12:00:57 +00:00
Hannah Wolfe
e6f3c2442e Merge pull request #6200 from kevinansfield/reset-tags-scope-on-deactivate
Reset shortcuts scope when leaving tags route
2015-12-10 18:41:23 +00:00
Kevin P. Kucharczyk
71a92f6b75 Fix hidden delete button in image uploader for short images
closes #6194
- removed min-height animation from image uploader
2015-12-10 18:45:46 +01:00
Hannah Wolfe
54cfe71b79 Merge pull request #6184 from kevinansfield/fix-date-input
Fix changing text and jumping caret in PSM's date input
2015-12-10 16:29:36 +00:00
Hannah Wolfe
4819b8ae0b Merge pull request #6181 from kevinansfield/fix-404-handler
Prevent 404-handler mixin from erroring on non-adapter errors
2015-12-10 16:26:07 +00:00
Kevin Ansfield
e78b3730b2 Reset shortcuts scope when leaving tags route
refs #6191, #6192
- adds additional safeguard to tags route to ensure keymaster scope doesn't get stuck in a non-default scope that may break shortcuts elsewhere
2015-12-10 12:27:48 +00:00
Hannah Wolfe
3c25d768d8 Merge pull request #6153 from kevinansfield/fix-subdir-nav-issues
Fix sub-dir being added to navigation urls when installed in sub-dir
2015-12-09 21:27:43 +00:00
Kevin Ansfield
6bb32c2fe7 Fix changing text and jumping caret in PSM's date input
refs #5777
- adds new `gh-datetime-input` that takes a one-way-bound value and formats it, only triggering the supplied `update` action on focus-out
- fixes bug in PSM's `setPublishedAt` action if model's `published_at` is a Date object not a Moment object
2015-12-08 10:13:17 +00:00
Kevin Ansfield
9baa34500b Prevent 404-handler mixin from erroring on non-adapter errors
no issue
- add a check for existence of `error.errors` as that won't be present on non-404 errors - fixes non-404 errors such as "no action handled x" being hidden by a completely different error
2015-12-07 18:37:35 +00:00
Kevin Ansfield
f02fce75c3 Merge pull request #6178 from syaiful6/select-native
Fix Select Component
2015-12-07 10:40:40 +00:00
Syaiful Bahri
878e7b5678 Fix Select Component
jQuery instance isn't iterable, so we cant destructuring it.

closes https://github.com/TryGhost/Ghost/issues/6171
2015-12-07 16:44:54 +07:00
Austin Burdine
fc31ad69d2 add team acceptance test 2015-12-06 15:24:06 -06:00
Hannah Wolfe
f44d7441bb Merge pull request #6161 from kevinansfield/jscs-deps
deps: jscs@2.6.0 & ember-suave@1.2.3
2015-12-04 10:33:19 +00:00
Kevin Ansfield
d2ada96e4e Merge pull request #6098 from acburdine/tag-404
Fix 404 error handling in editor, tags, and team routes
2015-12-04 10:20:22 +00:00
Kevin Ansfield
16f83c9c71 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
9d333533ac 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
Hannah Wolfe
52986b5033 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
468a2d87ed Checkbox labels are cut off on mobile.
closes #6089
2015-12-02 18:28:50 +09:00
Kevin Ansfield
300f7d0226 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
Kevin Ansfield
ca3b612779 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
425eada226 Merge pull request #6152 from kevinansfield/cleanup-dependency
Remove unused `ember-resize` dependency
2015-12-01 14:58:24 +01:00
Kevin Ansfield
76e2fe229a 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
f23166190d 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
Gary Cao
302fa98361 Properly binds "this" in uploader.js
closes #6146
2015-12-01 12:50:31 +09:00
Austin Burdine
46786e7065 deps: ember/ember-data@2.2.0 2015-11-30 12:23:47 -06:00
Austin Burdine
77a44907a9 deps: ember-cli@1.13.13 2015-11-30 11:21:39 -06:00
Kevin Ansfield
e01ffa3620 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
Kevin Ansfield
2f4f6db133 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
71e956a9eb 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
1f13fb4c65 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
Kevin Ansfield
6c3336976e 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
e0c368bd90 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
Matthew Beale
e79b07fd31 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
Kevin Ansfield
259559e6b2 Add count.posts support to user model on client
no issue
- moves adapter tests from unit to integration as we are not testing them in isolation
- add test for querying user's by slug with `include=count.posts`
- add `count` attribute to User model
2015-11-24 17:11:35 +00:00
Kevin Ansfield
9416e753dd Specify full SHAs when importing packages in bower.json
no issue
- removes warning: `bower password-generator#49accd7    short-sha Consider using longer commit SHA to avoid conflicts`
- fixes error: `bower jqueryui-touch-punch#*    error key must be a string or number. undefined`
2015-11-24 16:39:14 +00:00
Kevin Ansfield
c151be05de Update client for tag.post_count -> tag.count.posts rename
refs #6105
- adds `raw` ember-data transform to handle standard JSON `count` attribute
- update mirage factory to return correct `count.posts` format
- rename all uses of `post_count` to `count.posts`
2015-11-23 19:57:56 +00:00
Kevin Ansfield
933d6cd677 Merge pull request #6099 from acburdine/user-adapter
Implement custom user adapter to pull users by slug
2015-11-23 14:52:01 +00:00
Austin Burdine
31e4c9f753 implement custom user adapter to pull users by slug
closes #6095
- implements custom user adapter for the `/team/:slug/` route
- abstracts slug-url behavior into a mixin (used in /settings/tags/ as well)
- adds unit tests for both tag and user adapters
2015-11-23 07:48:08 -06:00
Matthew Beale
3e881027cc Use private properties for unobserved render state
* Drop set for local private editor property
* Only run preview setup on didInsertElement
* Drop set for local scrollWrapper prop
* Selectize setup on afterRender instead of next
* Use local props for editor save timers
2015-11-21 09:25:21 -05:00
Matthew Beale
6aa171077e Properly use htmlSafe styles 2015-11-20 17:48:48 -05:00
Hannah Wolfe
43bb09ef23 Fix & futureproof author filter
refs #5943
2015-11-20 10:13:30 +00:00
Hannah Wolfe
f285f8f948 Update author query to use filter
refs #5943
2015-11-19 21:53:24 +00:00
Sebastian Gierlinger
02429072ce Merge pull request #6049 from ErisDS/labs-text
Update public API labs flag text
2015-11-18 09:05:29 +01:00
Hannah Wolfe
3031a17728 Update public API labs flag text 2015-11-17 21:28:16 +00:00
Hannah Wolfe
0508f5775d Merge pull request #6076 from kevinansfield/setup-flow-test
Add acceptance test for setup flow happy-path
2015-11-16 21:47:45 +00:00
Hannah Wolfe
c9e7b6e906 Merge pull request #6071 from kevinansfield/fix-store-push-deprecations
Fix `store.push` deprecations in user model test
2015-11-16 21:27:39 +00:00
Kevin Ansfield
675a1221fa Add acceptance test for setup flow happy-path
refs #6039
- add `jquery-deparam` ember testing dependency for use in mirage config
- setup necessary mirage fixtures & endpoints for successful testing of setup flow's happy-path
- add happy-path acceptance test for setup flow
2015-11-15 11:51:19 +00:00