Commit Graph

317 Commits

Author SHA1 Message Date
Sebastian Gierlinger
a11822c80d Merge pull request #5144 from ErisDS/cache-update
Cache invalidation can no longer be so clever
2015-04-16 17:38:29 +02:00
Paul Adam Davis
9ea2f5535e Show correct type in publish button
Closes #5138

Shows the correct type (post or page)  in the publish button
2015-04-15 11:13:38 +01:00
Hannah Wolfe
1b585f213c Cache invalidation can no longer be so clever
no issue

With the introduction of the prev/next helpers (and soon, get helper) we can no longer make any assumptions
about exactly which pages need to be cleared from the cache when a post is published/unpublished.
2015-04-14 16:34:34 +01:00
Hannah Wolfe
14134fb4b0 Add media:content support to RSS
refs #2263, #4888

- Adds media:content element to Ghost Rt pSS feeds containing the post cover image if one is available
- Removes the prepending of the image to the `<description>` field
- Keeps the prepending of the image in `<content:encoded>`
2015-04-06 18:47:10 +01:00
Matt Enlow
242388f743 Merge pull request #5065 from ErisDS/rss-2263
Improve RSS feed
2015-04-04 07:55:33 -06:00
Hannah Wolfe
79d213436e Improve RSS feed
refs #2263

- Switch content type back to text/xml
- Use content:encode for full content
- Use meta description or first 50 words of content for description
2015-04-03 19:00:00 +01:00
Hannah Wolfe
68f32772d2 Improve the forgotten password flow
- if the user has filled out their email already when they hit 'forgotten password' then automatically  fill out and submit the form
- this will look better when we have spinners on the buttons
2015-04-03 17:32:18 +01:00
Hannah Wolfe
5db6fc4f18 No more CodeMirror
closes #4368, fixes #1240 (spellcheck), fixes #4974 & fixes #4983 (caret positioning bugs)

- Drop CodeMirror in favour of a plain text area
- Use rangyinputs to handle selections cross-browser
- Create an API for interacting with the textarea
- Replace marker manager with a much simpler image manager
- Reimplement shortcuts, including some bug fixes
2015-03-17 14:32:55 +00:00
Jason Williams
5b72a0eb18 fix routes test. ember-mocha@0.4.2 2015-03-11 12:37:42 -06:00
John O'Nolan
461834f96d Introduce new help menu 2015-03-09 11:53:40 +02:00
Hannah Wolfe
cde1842750 Check ids match on edit
no issue

- It should not be possible to provide a different ID in the object being edited to that provided in the URL
- We now send the id to check object to ensure there is a match

Credits: Matteo Beccaro
2015-02-28 16:25:37 +00:00
Eugene Kulabuhov
0e2709c42f [API] Retrieve next and previous post
closes #4262
- implementation based on #1545
- added integration test. Modified mocked posts because code requires published_at timestamps to be different.
- fixed 2 broken tests that depended on mocked posts to have "new Date()" as their timestamps
- added checks to only query db if next/previous post requested
2015-01-13 12:49:16 +00:00
Jason Williams
ac5d98e656 Merge pull request #4748 from rwjblue/remove-proxying
Remove ObjectController proxying behavior.
2015-01-02 15:18:15 -06:00
Jason Williams
9d82c2e360 Update test-related dependencies
No Issue
- nock@0.52.4
- should@4.4.2
    .eql no longer does type coercion.
- sinon@1.12.2
- supertest@0.15.0
2015-01-02 15:49:58 +00:00
Robert Jackson
a1ed9adf92
Remove ObjectController proxying behavior.
Ember.ObjectController (and Ember.ArrayController) will be deprecated in
Ember 1.11 (and removed from core in Ember 2.0). The reasoning is
detailed in the Ember 2.0 RFC.

This PR does the following:

* Updates templates/controllers/views to explicitly reference model
  properties (instead of relying on proxying behavior).
* Clearly delineate where certain properties are being set or retrieved
  from (for example it was not clear exactly where `scratch` and
  `titleScratch` were stored).
* Remove usage of `Ember.ObjectController`.
* Add JSCS rule to prevent future PR's from adding regressions.
2015-01-01 21:51:20 -05:00
Jason Williams
730e7ebcfa Adjust about page tests
No Issue
- Wait for list item element to appear before starting tests
  to make sure template partial has been rendered.
- Remove test for 20 list items as it's possible that there
  could be fewer than 20 contributors for during the window.
  Instead just test to make sure the list has at least one item.
2014-12-25 17:35:11 +00:00
Jason Williams
728e21424c Adjust casperjs test.
No Issue
- Keeping the tag entry input focused after sendKeys seems to
  make the test more reliable.
2014-12-18 20:22:48 +00:00
Jason Williams
56e4798dcf Update to Ember 1.9.0.
No Issue
- Ember@1.9.0
- Handlebars@2.0.0
- grunt-ember-templates@0.5.0-alpha
2014-12-10 16:24:20 +00:00
Paul Adam Davis
4e6c867183 Change sitemap root location
Closes #4590

- Removes `-index` from the root sitemap
- Removes redirects (which send sitemap.xml to sitemap-index.xml)
- Adjust tests
2014-12-07 11:59:43 +00:00
Paul Adam Davis
3b87aa2895 About Page Tests
Closes #4508

Tests for:

- Version number is a number
- Database type is an allowed 1 of 3
- There are 20 contributors
- First contributor has an image tag and image src exists, alt tag, title tag, href to github
2014-12-05 14:40:59 +00:00
Sebastian Gierlinger
9b8141bb08 Merge pull request #4530 from ErisDS/issue-4498
API - no more m-2-m relation ids by default
2014-12-02 20:49:47 +01:00
Hannah Wolfe
4cb909542a API - no more m-2-m relation ids by default
closes #4498

- remove toJSON code which returns only IDs from objects
- don't auto-include tags & fields in post responses
- don't auto-include roles in user responses
- fix #allthethings that made assumptions about the auto-includes, or otherwise were only working because of the auto-include
2014-12-02 19:24:44 +00:00
Jacob Gable
2cfa18475a Generate sitemap files
Closes #623

- Add basic init and eventing scaffold
- Add sitemap-index.xml generation
- Broke out generators to individual files, added request handler
- Add page, author and tag xml files; add index mapping
- Add SiteMapManager unit tests
- Add Generators tests
- Cache invalidation headers for sitemap-*.xml
- Redirect sitemap.xml to index and rename to sitemap-index
- Handle page convert and publish/draft changes
- Add very basic functional test for route existence
- Add cache headers to sitemap routes
2014-11-30 10:49:45 -08:00
Jason Williams
86cb690474 Merge pull request #4518 from ErisDS/rss-fixes
Change RSS content type & use absolute URL in meta
2014-11-28 13:07:07 -06:00
Hannah Wolfe
6f0bca8d57 Merge pull request #4522 from felixrieseberg/iss4487
Dynamic Titles in Ghost Admin
2014-11-28 19:06:44 +00:00
Felix Rieseberg
7c4381c812 Dynamic Titles in Ghost Admin
- Every route can set a title token that is combined with the blog’s
title, resulting in titles like ‘Content - Test Blog’.
- Subroutes are supported (‘Settings - General - Test Blog’)
- The blog’s name is applied to and taken from the `config` object to
spare Ember a REST call via `store.find(‘settings’)`.
- Tests have been changed to test for the new titles.
- The initially proposed solution
(https://github.com/paddle8/ember-document-title) doesn’t play nice
with EAK, which is why I went with this solution
(https://gist.github.com/machty/8413411) by Ember.JS core dev @Machty.
2014-11-27 15:41:00 -08:00
Hannah Wolfe
31ae0c6923 Change RSS content type & use absolute URL in meta
no issue

- changes the content type for the RSS feeds from text/xml to
  application/rss+xml
- changes the link rel=alternate tag to use an absolute URL for the feed
  in the blog meta data
2014-11-24 22:33:49 +00:00
Hannah Wolfe
cb726d57ef Adding comprehensive subdirectory route tests
closes #2230, refs #4477, #4476

- Test that subdirectories route correctly no matter how they're specified
2014-11-24 08:28:34 +00:00
Hannah Wolfe
50f8b29bdd Fix issue with editor and images
ref #4459

- move initMarkers back to its original home
- add new test that a post with an image can be edited
2014-11-17 21:55:12 +00:00
Paul Adam Davis
f8282ad22f Refactor component styles
Continues on from #4401

- Reformats the Sass to match our new style (property order, comments, & white space)
- Changes the modal container to a class from an ID (and adjust tests)
2014-11-13 11:28:22 +00:00
Jason Williams
817b8d2906 Improve handling of forked processes in tests.
Closes #4277
- Increase the wait time for forked processes to spin up.
- If we give up on waiting for a forked process, send it a
  kill signal so if it comes alive later it doesn't sit in the
  background forever.
- Fail fast if test setup fails instead of waiting for the timeout.
2014-10-31 16:00:35 +00:00
Jason Williams
de63f56f68 Update Ember to 1.8.0.
Closes #4316
- Ember@1.8.0.
- Ember-Data@1.0.0-beta.11.
- Change templates to use new Ember.Select syntax and other minor
  cleanup.
- Adjust functional tests.
2014-10-30 06:01:22 +00:00
Hannah Wolfe
5199a007b5 frontend functional tests -> frontend route tests
no issue

- Some of the tests were duplicated and all of these tests are faster and easier to do with super test as we aren't testing interactions
- Introduced a new test util to toggle permalinks which allows us to test the different structures
- Using cheerio in route tests to test the HTML / XML output is well formed
2014-10-19 21:10:13 +02:00
Paul Adam Davis
a32e5a7135 Move unrelated editor cover code to the right place
Closes #4106

Moved the `.editor-close` styles to `post-settings-menu.scss`
2014-10-21 13:14:07 +01:00
Sebastian Gierlinger
425c99423f Test improvements
refs #4309
- replace waitForResource with waitForSelector to prevent UI timing
issues.
2014-10-20 22:05:41 +02:00
Jason Williams
58fda8a9a4 Cancel pending auto-save if manual save occurs
Closes #4309
2014-10-20 18:40:45 +00:00
Hannah Wolfe
fbccc36f77 More autosave improvements
issue #4305, issue #4259, issue #1413

- change new->edit transitionToRoute to be replaceRoute
- auto focus in the editor on transition to the edit route
- change the one-time autosave to happen on codemirror focusin instead of title focusout
- re-add removed tests, and reorder broken test
2014-10-18 17:27:05 +02:00
Jason Williams
b05da0f1e4 Auto-save changes
Refs #4259
- Auto-save new post when title loses focus.
- If a post has '(Untitled)' for a title, regenerate slugs
  on all title changes--same behavior as a new post that does
  not yet have a slug.
- Adjust some functional tests to handle the automatic transition
  from editor/new to editor/editor and the URL changes that go
  along with it.
2014-10-17 22:52:43 +00:00
Hannah Wolfe
6e3fa3a2cf Merge pull request #4259 from novaugust/auto-save
Auto save draft posts
2014-10-17 19:04:07 +03:00
Hannah Wolfe
d44a97405b Merge pull request #4220 from felixrieseberg/iss4211
Shorter user slugs (if possible)
2014-10-16 21:23:50 +03:00
Paul Adam Davis
028b878721 Rename .object-list to .user-list
No issue
References todo comment in [users.scss](91c07e37bf/core/client/assets/sass/layouts/users.scss (L6-L7))

- Renames anything starting with `.object-list` to `.user-list`
- Adjusts tests to match
2014-10-13 22:43:03 +01:00
Matt Enlow
a9fb2af7ea Autosave Draft posts
Ref #1413
- If the user stops typing for 5 seconds, a "typingPause" action is sent from the GhCodemirrorComponent
- Editor-base-controller ties the "typingPause" action to its "autosave"
- If a post is being saved and does not have a title, the title is set to "(Untitled)"
- Cleanup editor base controller property dependencies and code
2014-10-13 15:28:27 -06:00
Felix Rieseberg
0025f3d6de Shorter user slugs (if possible)
Closes #4211
2014-10-01 23:27:21 +02:00
Fabian Becker
40254adc92 Implements module tests
closes #2521
- Add new module tests
- Implements new `test-module` task to specifically run module tests
2014-09-29 22:33:09 +02:00
Fabian Becker
1d1f24d3d4 Properly server shared files
refs #3992
- Don't use path.join for URLs
- Cache robots.txt for 1h instead of 1y
2014-09-25 14:14:20 +02:00
Hannah Wolfe
e5e7488d4d Fix cache-control header for API routes
closes #4157

- adds cache-control header back to api routes
- moves cache rules object into testUtils
- adds cache-control header test to every existing API test
2014-09-25 11:06:28 +01:00
Fabian Becker
aed5d346a7 Static page and feature options in new PSM
closes #4109
- Add featured option
- Move static page/featured to other place
- Change wording on static page
2014-09-24 12:29:17 +00:00
Fabian Becker
2c3abeee03 Naming cleanup
closes #4069
- Rename everything from camelCase to lowercase + dashes
- Remove usage of `server`, `app` and `instance`
2014-09-20 21:09:16 +02:00
Fabian Becker
f2fcb5b62b Let Ghost serve favicon instead of using dependency
no ref
- Remove static-favicon dependency
- Refactor robots.txt middleware to also serve favicon
- Add ETag
2014-09-18 13:51:41 +02:00
Harry Wolff
469aaa398c Add jscs task to grunt file and clean up files to adhere to jscs rules.
resolves #1920

- updates all files to conform to style settings.
2014-09-17 21:44:29 -04:00