GithubHelp home page GithubHelp logo

tryghost / ghost-android Goto Github PK

View Code? Open in Web Editor NEW
237.0 38.0 63.0 12.12 MB

🤖 Ghost for Android

License: MIT License

Java 74.78% CSS 5.51% HTML 0.47% JavaScript 2.51% Shell 0.02% Kotlin 16.70%
ghost android publishing blogging material-design

ghost-android's Introduction

Translate on Weblate

The official Ghost Android application. Get it here on the Google Play Store.

Get it on Google Play

Features

  • Simple, intuitive interface based on Material Design principles (along with some tasteful animations!)
  • Markdown editing with preview - swipe to switch between editing and previewing
  • 100% Markdown compatibility with Ghost - go ahead and use footnotes and code blocks like you're used to
  • Works with Ghost Pro (ghost.io) as well as self-hosted blogs
  • Offline mode: Ghost Android is designed to work 100% offline: just sync when you're connected later! Ideal for writing on the go
  • Attach tags and a cover image - upload images from your phone or a web link
  • Conflict handling - a simple UI to help decide what to do next when a post is edited from two places at once

Bug reports? Feature requests?

File an issue

Help translate Ghost Android

If you'd like to see support for your language in Ghost Android, you can easily contribute translations on Weblate. This requires no setup and no knowledge of Android development, just keep in mind a few simple rules:

  • Many strings have placeholders like "%s", "%d", "%2$s", etc. - keep these intact because other numbers and strings are inserted into these placeholders
  • Single and double quotes need to be preceded with a backslash character (\' and \" respectively)
  • For short strings, try to keep the translated string length close to the English one, because longer strings may not fit in the UI

If you need help getting started, drop a comment on this issue.

Developer setup

Setup is as simple as importing the project into Android Studio and building (assuming you have the correct build tools and Android SDK).

If you face any issues setting this up, please let me know by filing a new issue.

Contributors

Copyright & License

Copyright (c) 2013-2023 Vicky Chijwani & Ghost Foundation - Released under the MIT license. Ghost and the Ghost Logo are trademarks of Ghost Foundation Ltd. Please see our trademark policy for info on acceptable usage.

ghost-android's People

Contributors

comradekingu avatar conwid avatar cristears avatar disonds avatar eddiezane avatar erisds avatar fastbyte01 avatar flashfabrixx avatar gitter-badger avatar guillaumevidal avatar hififan avatar jcespinoza avatar joeegrigg avatar johnonolan avatar luen avatar mertcangokgoz avatar naofum avatar nistorcristian avatar nullbringer avatar omaranwa avatar realthargor avatar rezafaizarahman avatar sayem314 avatar sweetaaaaaa avatar thiagotomasi avatar ti-wb avatar vickychijwani avatar vistaus avatar weblate avatar yffengdong avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

ghost-android's Issues

Integration of Speech-to-text

Given the deployment to mobile and tablet devices running on Android it would be great to have the ability to use speech-to-text feature. This way, it would be possible to dictate your blog posts rather than typing them.

Eventually, this could be a keyboard-related feature on Android but surely an interesting addition to the pure Markdown based editor.

What's your opinion on that?

Regards, JoKi

saved on device, waiting to go online...

FILL THESE DETAILS FIRST:

  • Ghost version: 2.25.4
  • App version: 1.2.4

Fresh install on digital ocean, fresh install on Android 7.0 (Asus ZenfoneAR) will result in 'saved on device, waiting to go online...' when creating any blog post.

If this is related to #41 then status should be updated to bug or add a requirement for a Ghost version. Currently the app is not usable at all.

Stuck on welcome page.

  • Ghost version: 3.4.0
  • App version: 1.2.4

I inputed my blog url and clicked next step and then I got stucked.
I can login to my server by chrome browser.
image

(I'm using an Android 10 Pad.)

Planned rewrite?

Hello,
After I installed a Ghost Blog on my server I wanted to give Ghost Android App a go. But as we can see from related issues current app on the Play Store is not able to connect to a Ghost v3 API.

I checked out and read the code try to debug it but looking at it I can see it's not feasible to make it work with a v3 server, at least not without the help of the original author.

What are the plans for it? I'm willing to contribute to Android App if there is a plan to rewrite or refactor an app.

Besides this in the roadmap I can see an Android SDK, if you can create the issues for it I'm also willing to contribute to it.

APK for Android

Could someone upload previous stable version of ghost?

P/S: Is there going to be any future development on this? Or is there any plans for a new team?

[Crash] SettingRealmProxy - Trying to set non-nullable field 'value' to null

  • Ghost version: 2.14.3 (self-hosted)
  • App version: 1.2.2
  • Android version: 9.0
  • Device: Samsung Galaxy S8 (SM-G950F)

App crashes in main menu after successful log-in.
Cannot say any more, I am not familiar with Realm.


Stack trace:

FATAL EXCEPTION: main
Process: org.ghost.android, PID: 19607
java.lang.IllegalArgumentException: Trying to set non-nullable field 'value' to null.
	at io.realm.SettingRealmProxy.realmSet$value(SettingRealmProxy.java:191)
	at io.realm.SettingRealmProxy.copy(SettingRealmProxy.java:442)
	at io.realm.SettingRealmProxy.copyOrUpdate(SettingRealmProxy.java:428)
	at io.realm.BlogDataModuleMediator.copyOrUpdate(BlogDataModuleMediator.java:232)
	at io.realm.Realm.copyOrUpdate(Realm.java:1505)
	at io.realm.Realm.copyToRealmOrUpdate(Realm.java:1143)
	at me.vickychijwani.spectre.network.NetworkService.lambda$createOrUpdateModel$5$NetworkService(NetworkService.java:1062)
	at me.vickychijwani.spectre.network.NetworkService$$Lambda$5.execute(Unknown Source:6)
	at me.vickychijwani.spectre.model.RealmUtils.executeTransaction(RealmUtils.java:30)
	at me.vickychijwani.spectre.network.NetworkService.createOrUpdateModel(NetworkService.java:1061)
	at me.vickychijwani.spectre.network.NetworkService.createOrUpdateModel(NetworkService.java:1053)
	at me.vickychijwani.spectre.network.NetworkService.access$200(NetworkService.java:96)
	at me.vickychijwani.spectre.network.NetworkService$3.onResponse(NetworkService.java:325)
	at retrofit2.ExecutorCallAdapterFactory$ExecutorCallbackCall$1$1.run(ExecutorCallAdapterFactory.java:70)
	at android.os.Handler.handleCallback(Handler.java:873)
	at android.os.Handler.dispatchMessage(Handler.java:99)
	at android.os.Looper.loop(Looper.java:214)
	at android.app.ActivityThread.main(ActivityThread.java:7045)
	at java.lang.reflect.Method.invoke(Native Method)
	at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:493)
	at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:964)

Add new feature : Password on page

Hello World,

I would like to request a new feature.
It is possible to add a login/password (or just password) for a page (or page and post)

Regards,

Cursor moves to a new location randomly sometimes

Ghost version: 1.24.4
App version: 1.2.1
Device: Nexus 5
Android version: 7.1.2 (Lineage OS)

I struggle to find any pattern in this, other than, it happens when I'm using backspace. Instead of deleting the text I just wrote, the cursor is somewhere higher up, deleting something else until i notice, take my finger off the backspace and then try to remember what had been mistakenly deleted.

Android app unable to show existing posts

  • Ghost version: 1.23.0
  • App version: 1.1.3
  • Android version: 7.0
  • Motorola Moto G5

On logging in to Ghost (self hosted) with the app I'm unable to view existing posts. Instead I receive a toast which says Couldn't refresh data. This seems to come from the onDataRefreshedEvent() method of PostListActivity.java.

What is interesting is that I can create a new draft and that appears in the Ghost web UI, so clearly there is some communication working. Similarly, my correct blog name and avatar show in the app.

According to my webserver, the following has happened on the refresh request:

[30/May/2018:19:57:35 +0000] "GET /ghost/api/v0.1/settings/?type=blog HTTP/1.1" 304 0 "-" "okhttp/3.9.0"

[30/May/2018:19:57:35 +0000] "GET /ghost/api/v0.1/users/me/?include=roles&status=all HTTP/1.1" 304 0 "-" "okhttp/3.9.0"

[30/May/2018:19:57:35 +0000] "GET /ghost/api/v0.1/posts/?status=all&staticPages=all&include=tags&formats=mobiledoc,html&limit=30 HTTP/1.1" 200 14418 "-" "okhttp/3.9.0"

If I delete the draft in the web UI the app still shows it as existing. Editing the draft on the phone and saving it again as a draft results in saved on device, waiting to go online....

Any advice would be appreciated. Happy to assist with troubleshooting but I don't have another Ghost instance to experiment with.

1Password can't fill in credentials

FILL THESE DETAILS FIRST:

  • Ghost version: ghost.io
  • App version: 1.1.3

I use 1Password as my password manager. When I try to log on the following sequence happens:

  1. Enter url; I enter my blog url
  2. Enter username & password; I ask 1Password to fill these in for me
  3. 1Password prompts for my fingerprint; I supply it
  4. App goes back to the "enter url" screen and 1password is dismissed
  5. Goto 1

Very annoying ;).

Application doesn't show my published/unpublished stories

FILL THESE DETAILS FIRST:

  • Ghost version: 1.20.0
  • App version: 1.0.0

DESCRIBE YOUR ISSUE HERE

Hello, my web contains two users for two physical people. When I use Android application I can see just only drafts of second user. Neither my published or unpublished texts. I attached content of DB table users. My user is starting with D.... letter.

Thank you for help

2018-01-17 11_54_27-db browser for sqlite - c__ftp_ghost_content_data_ghost-local db

Mobiledoc editor (or: Build a Koenig-equivalent for Android/cross-platform)

Background

First off: What is mobiledoc and how does it relate to Ghost? 👀👇

Where we are today

Currently Ghost Android only supports posts with a single Markdown card. Only such posts can be previewed and edited; for all other posts, the app refuses to open them at all. When creating a new draft, the app presents a basic Markdown editor, as it was before Ghost 2.0, with no notion of "cards" or any other rich content at the moment.

What needs to get done

Full mobiledoc support (which, to be clear, is not currently planned) would involve implementing the following pieces:

  • Rendering mobiledoc: Take mobiledoc as input, and render it on Android using native/Flutter/React Native widgets
  • Card-based editor: Building on top of the renderer, create a card-based editor for Android, similar to the one in Ghost Admin on the web or in Medium's mobile app (note: the Medium app presents the UI differently, but the fundamental unit of editing can still be interpreted as a "card"). Naturally, the editor should store/serialize its contents in the mobiledoc format.

This work can be further broken down: once a foundation for rendering and manipulating the mobiledoc format is laid, the various card types can be implemented separately (see here for an up-to-date list of what mobiledoc cards Ghost Admin supports).

Interested in helping out? This could be an opportunity to learn Flutter or React Native! ✨

Given the nature of this project, it's going to be quite well-isolated from the rest of the Ghost Android codebase, which means it'll be a lot easier for someone new to get started 🚗💨

If you're interested in helping out (or even if you think you might be interested but would like more details first), just add a comment in this thread 💬

Why Flutter/React Native?

  • This project is mostly UI so those frameworks should be a good fit; not many Android-specific APIs will be required
  • Well-isolated from the rest of Ghost Android, should be easier to embed/integrate
  • The editor could be reused in a future Ghost iOS app, and if things go well, it may well make sense to adopt the framework for a full-fledged cross-platform app 👻📱

One thing that is currently unclear is that although Flutter and React Native can both be embedded into existing apps, it is possible that some required APIs are missing, so some more exploration would be required before committing to one of these frameworks.

Of course, a pure native solution is also welcome.

Support multiple blogs

Pro users would like the option to sign in to multiple blogs and switch between them seamlessly.


Task list:

  • Rework storage architecture alongside other breaking changes for Ghost 1.0 (vickychijwani/quill#162)
  • Build UI for adding / removing blogs and switching among them
  • Remove android:launchMode="singleTop" attribute from LoginActivity in the manifest
  • Add lots of logging in AccountManager to help debug any issues that come up
  • Handle scenario where the password has changed
  • Test cases:
    • Trying to add a new account with a blog that was already added earlier (only allow a single account per blog)
    • Preserve the data Realm in the case where, e.g., credentials expire
    • Delete the data Realm when a blog is removed (i.e., explicitly logged out)

Migrated from vickychijwani/quill#148

Uploaded images have artificial name

Would be nice if the images would keep their original filename. Then it's easier to keep track which image is already used/uploaded.

Android version: 6.0.1
device: OnePlus X
App version: 1.0
Ghost version: 1.18

Screen rotation cancels image upload

Upload an images is canceled if screen rotates. At least the dialog showing the progress ia gone and nothing gets inserted into the text.

Android version: 6.0.1
device: OnePlus X
App version: 1.0
Ghost version: 1.18

"Couldn`t upload image" message on Xiaomi devices

FILL THESE DETAILS FIRST:

  • Ghost version: 1.21.3
  • App version: 1.1.1

Ghost-CLI version: 1.5.2
The application fails to load image from gallery: responds with "Couldn`t upload image" message.
Run on Xiaomi Mi Pad 1 (Android 4.4) / Xiaomi Mi4 (Android 6.0.1) all permissions requested by app are given.
Neither in-editor image, nor post images are insertable (inserting image from URL is OK).
So I assume there is some access problem.
Please tell how I can perform any debugging (if needed).

Cursor position reset when switching app

If you switch from ghost to another app and back and while editing a post the cursor is reset to the beginning of the post.

Android version: 6.0.1
device: OnePlus X
App version: 1.1.0
Ghost version: 1.18

Sync overrides conflicting changes

Sometimes a conflicting change between a post on server and android app is not detected.
We suspect it to occure if someone else then the original author modifies the post and the original author modifies it afterwards.

We have a workflow where the author writes a post offline and later syncs. The reviewer pulls the post and modifies offline and also syncs later when internet is available.
If both modifiy the post while offline and sync later, the authors version seems to win.

Modifying title doesn't change url

When changing the title of an already created post, the URL is not adjusted.
Doing the same in ghost-admin changes the URL.

In some cases this results in the URL being "/untitled"

Android version: 6.0.1
device: OnePlus X
App version: 1.0
Ghost version: 1.18

Upload images adds additional new lines

When upload an image addition new lines are inserted even is there is already a new line between the image markdown an the text blocks.

New lines should only be added if there is no newline between the inserted markdown code and the text blocks.

Multi image upload

When uploading images in the ghost-admin, you are able to select multiple images. The android app doesn't seem to support this. Since the app used to select the images supports multiselection, I suspect the cause is the ghost app.

Android version: 6.0.1
device: OnePlus X
App version: 1.0
Ghost version: 1.18

Placeholder text isn't removed automagically

  • Ghost version: 1.16.2 (Ghost(Pro))
  • App version: 1.0.0

When clicking in the post title I expect (like in Ghost interface) the placeholder (Untitled) text to be removed when I start typing. At the moment on my Pixel 2 whatever I type just gets append to it/placed wherever I click.

Ghost Android 1.0

In terms of functionality and feature parity - I don't think we need to add a whole lot. The only thing really missing, I think, is search and filtering from the content screen - and fleshing out more fields in the post settings menu. Anything beyond that is just a bonus!

The only main other question that I have is around what changes we could make in Ghost Core which would be beneficial to both Ghost Android and Ghost Desktop? In particular:

  • Proper write API support. I know auth is a bit of a hack RN. @ErisDS might have some thoughts
  • Offline support (you mentioned this before) - I'm not sure how much is involved, but def interested. /cc @felixrieseberg I know you've done some experimenting here
  • Anything else?

Those are all the main things that I can think of so far :)

Changes get lost on leaving post

Sometimes a change in an post is not shown in the preview of the post. Leaving the post can result in loosing the change.

Possible reason: when opening the post the phone had an internet connection. During editing the connection is lost.

Migrate open issues?!

How is it that a deal breaker like this issue from 2015(!!!) is not yet fixed or at least migrated to this repo?
vickychijwani/quill#81
The whole app is useless to anyone who has more than 29 drafts...

This is more than just disappointing.

Conflict resolution: can't upload version from device

  • Ghost version: 1.24.4
  • App version: 1.1.3

I'd written something but there was a conflict. If I selected to upload the version from my phone, every time I pressed "accept" it would briefly show me the home screen but then immediately come back to the same dialogue. force stopping did nothing. It just wouldn't allow me to do anything else until I selected to download instead of upload. And also you can't select and copy the text, so I had to manually read and type out again on the desktop what I'd written on my phone.

No access to development http sites

  • Ghost version: X.Y.Z
  • App version: 1.2.1

The app interface, on the first screen, strictly enforces a https address. This prevents access to a local Ghost instance running in development mode. It would be nice to have a checkbox or some other mechanism to allow that.

Posts created by contributors are not syncing

FILL THESE DETAILS FIRST:

  • Ghost version: 1.25.3
  • App version: 1.2.1

Issue #1

When users with “Contributor” role try to write a post using the Ghost mobile app, it doesn’t sync to the server.

I was going through a debugging session and found the following error when a contributor tries to create a post.

{“errors”:[{“message”:“You do not have permission to add posts”,“errorType”:“NoPermissionError”}]}

Issue #2

When this happens, Ghost mobile app keeps trying to sync with the server and finally it goes through the spam prevention system resulting in the following error

{“errors”:[{“message”:“Too many attempts try again in an hour”,“context”:“Only 100 tries per IP address every 3600 seconds.”,“errorType”:“TooManyRequestsError”}]}

Then no one in the same network can even log in to the app within an hour.

Support for multiple blogs

This is more of a feature request, than a bug: Is it possible to add support for multiple blogs without the need to logout from one to login to another? I currently have 3 blogs using Ghost.

App crashes on Android P beta (Pixel 2 XL)

FILL THESE DETAILS FIRST:

  • Ghost version: ghost.io
  • App version: 1.1.3

I'm able to enter my blog url and logon details, Directly after that the app crashes:

IllegalArgumentException
me.vickychijwani.spectre.util.PostUtils
getStatusColor:186

Allow viewing and editing beyond the latest 30 posts

Pagination needs to be implemented. This issue is especially problematic for users with more than 30 drafts as they are all sorted to the top, which means no published posts are accessible.

This is currently complicated to implement because of offline mode:

  • How do we handle posts that are cached locally but are not present on the current page of posts fetched? How do we know whether such a post has been deleted or simply pushed onto a later page? What if it's been edited offline?
  • Also, what about posts beyond the first page that are already cached? When and how will they be updated? Because the current idea is to always fetch the first page of posts on app start / resume, plus any new pages when the user scrolls to the bottom.

Some ideas:

  • Show all drafts + first N published posts

Migrated from vickychijwani/quill#81

Upload image doesn't check for internet connection

To upload images an internet connection is required. If the phone doesn't have a connection the upload button starts the image selection dialog and tries to upload which will fail but only after a long timeout.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.