Commit Graph

77 Commits

Author SHA1 Message Date
Aileen Nowak 7af0f51b53 Blog icon uplod (#397)
refs TryGhost/Ghost#7688
- Adds new upload functionality for a blog icon in general settings.
- Icons will be uploaded to a new endpoint `uploads/icons` to trigger different validations.
2017-01-26 11:17:34 +00:00
John O'Mahoney 2ea63c6753 Show error message for invalid data in PostsPerPage (#419)
closes TryGhost/Ghost#7746
- Added gh-form-group around PostsPerPage
- Changed focusOut action to validate
- Removed now redundant `checkPostsPerPage()` call
2017-01-08 09:55:19 -06:00
Hannah Wolfe a2daccd990 💄 Adding id to themes title for inter-linking 2016-08-25 10:26:05 +01:00
Kevin Ansfield eb0db3fafe indicate folder names to tell duplicate themes apart
refs https://github.com/TryGhost/Ghost-Admin/pull/210
- removes unused `activeTheme` property on `gh-theme-table`
- updates label generation in `gh-theme-table` to add folder names when there are duplicate package.json name+version combos
2016-08-23 16:55:32 +01:00
Kevin Ansfield 5581c6ba5a theme management UI
refs https://github.com/TryGhost/Ghost/issues/7204, requires https://github.com/TryGhost/Ghost/pull/7209

- replaces theme dropdown with a table
- adds theme upload modal
    - validates theme mime type
    - prevents upload of `casper.zip` (default Casper theme can't be overwritten)
    - warns if an upload will overwrite an existing theme
    - gives option of immediately activating the uploaded theme or closing after successful upload
- adds theme activation link/action
- adds theme download link/action
- adds theme deletion modal
    - warns about no undo possibility
    - offers possibility to download theme
- modifies mirage config to handle theme changes
2016-08-23 12:42:38 +01:00
Kevin Ansfield 96f2d4088f Handle automatic timezone override
refs https://github.com/TryGhost/Ghost/pull/7142, https://github.com/TryGhost/Ghost/pull/7143
- moves timezone selection template and logic into a component
- detect if the current `activeTimezone` is not in our pre-defined list of timezones, if it isn't:
  - add a line indicating that there has been an override with the current `activeTimezone` value
  - add a blank option to the timezone select list
2016-07-26 11:50:24 +01:00
Austin Burdine c1367dac34 convert inputs to one-way inputs
no issue
- moves all inputs to use the data-down-actions-up component paradigm
2016-06-18 07:44:23 -04:00
Aileen Nowak be8b31ec85 Timezones: Always use the timezone of blog setting
closes TryGhost/Ghost#6406

follow-up PR of #2

- adds a `timeZone` Service to provide the offset (=timezone reg. moment-timezone) of the users blog settings
- `gh-datetime-input` will read the offset of the timezone now and adjust the `publishedAt` date with it. This is the date which will be shown in the PSM 'Publish Date' field. When the user writes a new date/time, the offset is considered and will be deducted again before saving it to the model. This way, we always work with a UTC publish date except for this input field.
- gets `availableTimezones` from `configuration/timezones` API endpoint
- adds a `moment-utc` transform on all date attr (`createdAt`, `updatedAt`, `publishedAt`, `unsubscribedAt` and `lastLogin`) to only work with UTC times on serverside
- when switching the timezone in the select box, the user will be shown the local time of the selected timezone
- `createdAt`-property in `gh-user-invited` returns now `moment(createdAt).fromNow()` as `createdAt` is a moment date already
- added clock service to show actual time ticking below select box
- default timezone is '(GMT) Greenwich Mean Time : Dublin, Edinburgh, London'
- if no timezone is saved in the settings yet, the default value will be used
- shows the local time in 'Publish Date'  in PSM by default, until user overwrites it
- adds dependency `moment-timezone 0.5.4` to `bower.json`

---------

**Tests:**

- sets except for clock service in test env
- adds fixtures to mirage
- adds `service.ajax` and `service:ghostPaths` to navigation-test.js
- adds unit test for `gh-format-timeago` helper
- updates acceptance test `general-setting`
- adds acceptance test for `editor`
- adds integration tests for `services/config` and `services/time-zone`

---------

**Todos:**

- [ ] Integration tests: ~~`services/config`~~, ~~`services/time-zone`~~, `components/gh-datetime-input`
- [x] Acceptance test: `editor`
- [ ] Unit tests: `utils/date-formatting`
- [ ] write issue for renaming date properties (e. g. `createdAt` to `createdAtUTC`) and translate those for server side with serializers
2016-06-03 16:23:39 +02:00
Aileen Nowak 0f9645f97d Structured Data 3.0
closes #6534
- new input fields in general settings incl. validation
- facebook and twitter as new models in settings.js
- adds values for facebook and twitter to default-settings.js
- adds blog helpers for facebook and twittter
- rather than saving the whole URL, the Twitter username incl. '@' will be extracted from URL and saved in the settings. The User will still input the full URL. After saving the blog setting, the stored Twitter username will be parsed again as the full URL and available in the input field. A custom transform is used for this.
- adding meta fields to be rendered in {{ghost_head}}:
	- '<meta property="article:publisher" content="https://www.facebook.com/page" />' and
	- '<meta name="twitter:site" content="@user"/>'
- adds facebook and twitter to unit test for structured data
- adds unit test for general settings
- adds acceptance test for new input fields in general settings
- adds a custom transform for twitter model to save only the username to the server
- adds unit test for transform
2016-05-08 17:43:59 +02:00
Kevin Ansfield d4ca5ced75 Don't share errors and hasValidated references between validator instances
no issue
- ensure that each validator instance gets it's own `errors` and `hasValidated` objects
- updates some uses of `ValidationEngine` that were relying on side-effects of the unintended reference sharing
- fixes issue with add subscriber modal displaying an error state after opening if it previously had errors when closing
2016-04-25 10:56:11 +01:00
Kevin Ansfield 97bb577496 Refactor modals
refs #5798, closes #5018
- adds new `gh-fullscreen-modal` component - modals are now specified in-context so that they can have deeper interaction with their surrounding components/controller/route, i.e. a modal component can be a thin confirm/deny wrapper over the underlying controller action keeping all context-sensitive logic in one place
- adds spin-buttons to all modals with async behaviour
- adds/improves behaviour of inline-validation in modals
- improves re-authenticate modal to properly handle validation and authentication errors
2016-01-12 20:53:08 +00:00
Hannah Wolfe f9e6bf9835 Form field icons load in default 'grey' state
ref #5652

- validations can be in default, success or error state
- adds check for 'hasValidated' if the validations haven't fired yet, the field is in the default state
- hasValidated is an Ember.Array which tracks the state for each field
2015-09-01 13:02:27 +01:00
Hannah Wolfe d40eb288c1 Spin button consistency
refs #5652

- always put button text inside opening/closing helper tag
- only include type if it is 'submit' as button is default
- wrap attributes in double quotes
2015-08-26 16:21:42 +01:00
John O'Nolan bfe62bac6c Prevent view titles from being cut off in Safari
See #5652
2015-08-12 09:17:01 +02:00
Austin Burdine 3c0bd3e8b2 add spin-button component & implement it
closes #3928
- adds spin-button component & styles
- implements spin-button in places where buttons trigger async tasks
2015-08-10 09:43:50 -06:00
Kevin Ansfield d4c8892ad5 Replace validation notifications with inline validations
issue #5409 & #5336

- update settings/general
- update signin
- update signup
- update edit user
- update reset password
- update setup/three
- remove `formatErrors` function from validationEngine mixin (it's no longer needed as inline validations should handle this instead)
2015-07-28 12:26:34 +01:00
Jason Williams 89102fdd6c Update Ember to 1.13.2
- Refactor to handle deprecations including removal of
  all Views, ArrayControllers, and ItemControllers.
2015-06-24 11:47:28 -05:00
Matt Enlow 3671f7a028 Add mobile menu open button and close on click outside nav
- Adds gh-view-title component to implement mobile menu button for titles on any page
- Refactors the `content-cover` out into the application template
- Fix various z-index issues with content-cover and gh-alert
- Move `.settings-menu-expanded` application view state from body to `.gh-viewport`
- Unify nav menu / mobile menu actions and code
2015-06-08 22:13:34 +02:00
John O'Nolan d168d8b960 New mobilemenu prototype 2015-06-08 22:13:34 +02:00
Austin Burdine e4041f438c remove settings email
closes #5299
- removes settings/general email field from both client and server side
- fixes tests to reflect removal of email
2015-05-22 15:23:31 -06:00
John O'Nolan b33745783d Content view 2015-05-22 19:02:06 +01:00
John O'Nolan 82a5b07c6b New settings headers 2015-05-22 19:02:06 +01:00
John O'Nolan dec115a1cc Integrate new admin frame 2015-05-22 19:02:05 +01:00
Hannah Wolfe c8f5104eed Theming updates for password protection
refs #4993, #5073

- Removed nonexistent helpers siteDescription and bodyClass from admin templates
- Changed password.hbs to private.hbs to match the route name
- added a new input_password helper for rendering the password input with the correct properties
- removed the forward input as this can be handled via urls only
- moved 'private' to routeKeywords
- added 'private' context
- minor update to text next to the password in settings
2015-05-13 19:48:24 +01:00
Austin Burdine f52c325a8c finish up password protection
closes #5073
- takes password protection out of labs and moves it to general settings
- adds random-words generator to randomly generate passwords
2015-05-12 12:02:18 -06:00
Matt Enlow 3cc7493dc2 Ember 1.11.1
- remove `bind-attr` all over the place
2015-04-05 21:13:30 -06:00
Matt Enlow 6bbc62d3c2 The great migration (EAK -> ember-cli) 2015-03-11 12:37:41 -06:00
Renamed from templates/settings/general.hbs (Browse further)