Commit Graph

79 Commits

Author SHA1 Message Date
Paul Adam Davis
7c310ad2df Add a URL preview componant
Closes #4499

- Introduces a URL preview component
- Added the component to tag settings and post settings
- Adds a new CSS file for this component which makes sure the preview never wraps onto multiple lines
2014-12-19 23:48:21 +00:00
Jason Williams
8d9df785be Prevent error when closing modal dialog
No Issue
- Moved sendAction outside of the event handler as calling it
  from inside was generating an error in the console.
2014-12-18 23:10:25 +00:00
Paul Adam Davis
4fb3fe62a9 Use CSS animations for modals
No issue

- Changes Modals to use CSS-based animations
- All modals have an animation, so the option is removed from the handlebars helper
- Removes `animation` from the handlebars helper, as all had one anyway
- Removed the `centered` style - All modals should be left-aligned
- Buttons now default to being on the left
- Cleans up some styles (modal body top spacing) which #4632 helped clean up
2014-12-15 18:23:42 +00:00
Hannah Wolfe
b9310a2716 Merge pull request #4613 from felixrieseberg/iss4506-2
Tag Cover Images
2014-12-12 10:46:58 +00:00
Felix Rieseberg
028a64eaee Tag Cover Images
Closes #4506

Works just like the Post Cover Images (and uses the same component)
Tiny changes to the component ensures that we can reuse it across Ghost
2014-12-10 17:48:18 -08:00
Vikhyat Korrapati
297c33b3f7 Fix active menu state on settings navigation
closes #4622
- unfocus ActivatingListItem link when clicked
2014-12-10 22:01:40 +05:30
Felix Rieseberg
69662bd5d2 gh-trim-focus-input autofocus fix for iOS Safari
Closes #4446
- Mobile Safari doesn’t support the HTML5 `autofocus` attribute, but
also doesn’t play nice with jQuery’s `focus()` and `select()` methods.
- Mobile Safari wouldn’t automatically select the input field anyway,
so this PR simply removes the “jumping input fields” error without
changing any actual behaviour.
- Disallowing the programmatic selection of input fields (with select,
focus or similar methods) is apparently considered a feature rather
than a bug (ref http://bugs.jquery.com/ticket/12789)
- `autofocus` attribute is now only set on non-iOS devices
2014-12-02 09:14:32 -08:00
Jason Williams
90d12fd990 Miscellaneous client cleanup
No issue
- Consolidate extension of Ember.Router.
- Remove unneeded local jshint flags and '_' as a global.
- Cleanup client README.md.
- Fix error message.
2014-11-29 02:42:08 +00:00
Hannah Wolfe
f4388712f8 Merge pull request #4502 from felixrieseberg/iss4431
Ensure Post Image Uploader Reset
2014-11-25 19:07:32 +00:00
Felix Rieseberg
ce9d590f34 Ensure Post Image Uploader Reset
Closes #4431

- The PSM does not reset on a transition from editor (existing post) to
editor (new post). If the existing post had a cover image, the image
uploader would not be reset during the transition and appear slightly
broken in the editor for the new post.
- In this PR: A reference to the uploader is saved, allowing the route
for editor/new to instruct the PSM controller to have the uploader
reset.
2014-11-24 09:43:17 -08: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
Matt Enlow
a9ce31ffe7 Fix high latency autosave bug in editor.new
Closes #4400
- Added focusCursorAtEnd property to codemirror component, to set the cursor at document end on load. Used for posts that have been edited
- centralized codemirror init code in component
2014-11-16 08:53:02 -07:00
Jason Williams
0f17378b26 Enable JSCS checking on client.
Refs #4001
- grunt-jscs@0.8.1 which provides ES6 support.
2014-10-25 16:13:04 +00:00
Jason Williams
9aa13330ba Fix up PR #3491, remove lodash from admin
Refs #3491
2014-10-23 19:44:53 +00:00
Robert Jackson
a3456b7e1c Remove lodash from admin client.
* Adds `bind`, `isFinite`, and `isNumber` utility functions from lodash.
* Use new util funtions instead of lodash throughout the codebase.
* Remove lodash from vendor builds.
2014-10-23 18:27:09 +00:00
Paul Adam Davis
6fd27796f4 Implement popovers 2014-10-20 22:09:45 +01: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
af4e1809e8 Autosave additions
issue #4259, issue #1413

- decrease timeout by 1 sec
- really actually turn off nprogress
2014-10-17 18:39:39 +02: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
Paul Adam Davis
e5b45c8d76 Rename popovers to dropdowns 2014-09-30 10:48:21 +01:00
Paul Adam Davis
bf69c9cf83 Fix flickering popover transitions
Closes #4138

- Removed JS animation to close in favour of CSS animations
2014-09-30 10:48:21 +01:00
Jason Williams
586de0141d Merge pull request #4132 from novaugust/fix-tab-pane-connection
Fix GhostTab and GhostTabPane array dependencies
2014-09-25 17:50:59 -05:00
Hannah Wolfe
086f96489e Merge pull request #4147 from ErisDS/shortcuts
Minor shortcut amends
2014-09-25 16:50:31 +01:00
Hannah Wolfe
4508ca2fa3 Minor shortcut amends
issue #1463

- disables some of codemirrors default shortcuts to prevent them clashing
- minor cleanup of shortcut listing
2014-09-24 16:11:17 +01:00
Hannah Wolfe
8bc84bd260 Fix button class on upload modal
no issue

- this makes sure that the cancel button on the upload modal gets the
  correct class
2014-09-24 15:26:23 +01:00
Matt Enlow
097c78aad1 Fix GhostTab and GhostTabPane array dependencies
No issue
- TabPanes weren't finding their tab due to not listing all their dependencies in Ember.computed
2014-09-23 20:22:15 -06:00
Hannah Wolfe
f991ab44b8 Merge pull request #4066 from halfdan/3939-psm3-meta
Meta data screen
2014-09-21 17:53:12 +01:00
Fabian Becker
30f56280e0 Meta data screen
closes #3939
- Add Seo Tab component to PSM
- Add new gh-blur-textarea component
- Refactor blur-input to use new text-input mixin
2014-09-21 15:13:06 +00:00
John O'Nolan
2f986160fd Merge pull request #4053 from PaulAdamDavis/css-bug-fixes
Tiny CSS bug fixes
2014-09-20 09:12:25 +02:00
Paul Adam Davis
81fe516481 Fix several tiny CSS bugs
Closes #4050

- Full-width invite user modal button
- `<select>` can be focused in Firefox
- Increase size of background images for avatars
- Add `-moz-osx-font-smoothing: grayscale;` to icons
2014-09-19 21:24:43 +01:00
Matt Enlow
f29231aa70 Add Tab components
Closes #3937
- Add ghost tab components
- Remove extra container div from Application view
- Move right-outlet viewing logic to application level
- Prepare PSM.hbs for tabbing
2014-09-18 18:15:43 -06:00
Felix Rieseberg
0048d393ac PSM: Cover Images
closes #3885
2014-09-16 13:32:43 -07:00
Matt Enlow
03bea5dbef js- prefix; fix content preview back button
Closes #1990, Ref #3810
- Add `js-` prefix to jQuery calls throughout code and templates
- move MarkdownComponent classNames to template
- Fix back button on posts content preview
- Remove dead code for preview tabbing jQuery
2014-09-02 22:29:32 -06:00
Matt Enlow
20f40e7e32 Change Ember function.property() to Ember.computed
Closes #3417
2014-08-19 10:01:17 -06:00
John O'Nolan
85b7819791 Implement new button markup 2014-08-17 14:57:07 +03:00
Robert Jackson
1d360b3d18
Do not focus post title when editing. 2014-08-08 11:37:24 -04:00
Hannah Wolfe
8e17efeac9 Merge pull request #3656 from rwjblue/activate-specific-tab-not-toggle
Activate specific tab that is tapped/clicked.
2014-08-07 19:32:14 +01:00
Robert Jackson
493fe8183b
Activate specific tab that is tapped/clicked. 2014-08-07 09:32:10 -04:00
Matt Enlow
1f608cf5ab Add open class to popover buttons
Ref#3603
- Popover Buttons now have an `open` class applied to them when their popover is open
- The open class is removed from the popover button at the start of the popover's fadeout
- Consolidated common code into popover-mixin
2014-08-06 18:23:03 -06:00
Maurice Williams
cb9f4f7c05 Stop event propagation when hitting "enter" in the gh-blur-input component
fixes #3516
- new behavior is disabled by default
- added new stopEnterKeyDownPropagation property enable new behavior
2014-08-03 00:48:05 -04:00
Matt Enlow
21abed7f9a Add User Role Dropdown
Closes #3402, Closes #3428

-------------------

 ### Components
- Added GhostSelectComponent to handle async select creation (h/t @rwjblue)
- Added GhostRolesSelector (extends GhostSelect) for displaying user role options
- Created StoreInjector for surgically inserting the store into things that normally wouldn't have them.

 ### Users Settings
- InviteNewUserModal now uses GhostRolesSelector & defaults to Author
- The role dropdown for user settings has permissions set per 3402

 ### User Model
- Added `role` property as an interface to getting and setting `roles`
- Refactored anything that set `roles` to set `role`
- isAdmin, isAuthor, isOwner and isEditor are all keyed off of `role` now

 ### Tests
- Added functional tests for Settings.Users
- updated settings.users and settings.users.user screens
- fix spacing on screens

 ### Server Fixtures
- Fixed owner fixture's roles
2014-07-30 17:59:14 -06:00
Jason Williams
b7be74907f Add a notify action to the notifications component
Refs #3160
- gh-notifications component now takes an optional notify
  parameter.  If present it will be invoked as an action
  when a notification is added or removed.
- Add a data-notification-count attribute to the main container
  that tracks the number of "top" notification messages that
  are currently being shown.
2014-07-17 17:34:38 +00:00
Paul Adam Davis
b08a4b1fe5 Check the end of notification fade-out animation 2014-07-13 15:00:25 +01:00
Jason Williams
1bf975af90 Turn on update notifications for Ember admin
Issue #3160
- Use notifications API to display available update notification.
- Remove update_notification handlebars helper as now both the
  check for an available update and the notification handling
  is run from the server's admin controller index method.
- Bind the notification's location property to a css class
  for styling.
- Refactor Ember notifications to better handle notification
  objects.  Move responsibility for css class generation onto
  the notification component.
- Refactor gh-notifications component to take a location argument
  that's used to assign a css class and filter notifications.
2014-07-11 15:02:26 +00:00
Matt Enlow
b1584f63c6 Added fadeout to gh-popover
Closes #2868
- Uses jQuery's `.fadeOut` whenever a popover is closed.

- Reordered `gh-popover`'s code into something a bit more logical and, if
  I may, pretty
- Renamed `open` property into `isOpen`. `isOpen` should only be
  manipulated via `close()` and `open()`
- Added `closing` property to help track state in the case of rapid clicks
  on a popover's button, allowing us to abort
` Added `open()` function
2014-07-03 13:13:18 -06:00
Kevin Ansfield
7e2e8b3376 Persistent notifications
closes #3057
- add Notification model
- update injected Notifications object to handle persistent notifications
- load server notifications on setup if logged in otherwise on successful sign-in
- changed all existing notifications.closeAll calls to closePassive
- fixed dismissable/dismissible spelling in server API & tests
- add notifications.closeNotification method so DELETE calls can be made for server-originating notifications
2014-07-01 11:36:21 +02:00
Fabian Becker
b2662bbdff Allow tabbing responsive editor when not on mobile.
fixes #3095
- Add `click` event to floatingheader
2014-06-25 12:30:57 +00:00
Jason Williams
39c0f219e6 Finish Debug screen for Ember admin
Closes #2847
2014-06-25 04:36:17 +00:00