Coder Social home page Coder Social logo

flaque / quirk Goto Github PK

View Code? Open in Web Editor NEW
2.2K 22.0 3.6K 43.12 MB

✨🐙 A GPL Licensed Cognitive Behavioral Therapy app for iOS and Android. Currently a teaching tool

Home Page: https://quirk.fyi

License: GNU General Public License v3.0

JavaScript 0.05% Shell 0.46% Ruby 2.92% TypeScript 93.55% Java 2.37% Objective-C 0.63%
react-native expo ios android mental-health health typescript gplv3

quirk's Issues

Add Dynamic Font Sizes to Intro Screen

In some languages, words can be long. In some screens of the app, e.g. the introduction, the words get split at seemingly arbitrary letters. Languages can have their own hyphenation rules for long words and word wrapping.

Request for comments:

  • Automated hyphenation? Do various languages have libraries that could provide this "for free" by using a dependency?
  • Manual hyphenation? E.g. inserting soft hyphens into the translation files?
  • Other solutions? E.g. decreasing font size to fit words better? (and accept it wouldn't be 100% perfect)
  • Leave it as-is, consider it a minor cosmetic issue?

Typographical error in initial steps overview

Hello!

I've found a typo under the Alternative Thought point in the second to last slide when the user initially goes through the steps of correcting the posed Automatic Thought. It reads:

"It's true I missed George's party, I can appologize, and he'll probably forgive me"

It should read:

"It's true I missed George's party, I can apologize, and he'll probably forgive me"

TouchID protection for App

It would be nice if the app could be "protected" with TouchId or a password. This doesn't need to be the default, but could be enabled in the Settings.

Make an android version

I see the codebase is in react-native,

Can you share the reasoning behind not having an apk already?

Export / Backup / sync saved entries

I was wondering if you have any plans for allowing users to export the saved data in any way.

I see that the entries are only saved locally, so the options are:

  • have an on-demand "Export option" (format TBD)
  • have a sync / backup option where the data is stored in iCloud automatically, allowing the user to get the data from there if required (iCloud data should be human readable)

Any thoughts? I'd be happy to implement this and submit a PR if you can give me some directions.

Thanks!

wtf is wrong with the tests

Overview

Something's wrong with the tests. I'm pretty sure it's something to do with *.json files, since the commit that introduced them into the codepath of the tests is where things start breaking.

 FAIL  src/sanitize.test.ts
  ● Test suite failed to run

    Jest encountered an unexpected token

    This usually means that you are trying to import a file which Jest cannot parse, e.g. it's not plain JavaScript.

    By default, if Jest sees a Babel config, it will use that to transform your files, ignoring "node_modules".

    Here's what you can do:
     • To have some of your "node_modules" files transformed, you can specify a custom "transformIgnorePatterns" in your config.
     • If you need a custom transformation specify a "transform" option in your config.
     • If you simply want to mock your non-JS modules (e.g. binary assets) you can stub them out with the "moduleNameMapper" config option.

    You'll find more details and examples of these config options in the docs:
    https://jestjs.io/docs/en/configuration.html

    Details:

    /Users/evanconrad/dev/src/github.com/Flaque/quirk/node_modules/expo/build/environment/validate.js:1
    ({"Object.<anonymous>":function(module,exports,require,__dirname,__filename,global,jest){import {
                                                                                                    ^

    SyntaxError: Unexpected token {

      at ScriptTransformer._transformAndBuildScript (node_modules/@jest/transform/build/ScriptTransformer.js:471:17)
      at ScriptTransformer.transform (node_modules/@jest/transform/build/ScriptTransformer.js:513:25)
      at Object.<anonymous> (node_modules/expo/build/Expo.js:278:1)

At the moment, this is blocking #42

Audit and examine CBT Features of other apps

Overall Available Tools

CBT features from a table in the paper "User Experience of Cognitive Behavioral Therapy Apps for Depression: An Analysis of App functionality".

Therapeutic featuresDefinitionsCBT featureApps, n (%)
Dealing with negative automatic thoughtsIdentifying and challenging specific negative automatic thoughts about self or the worldYes15 (48)
Addressing negative thinking stylesIdentifying and challenging thinking styles and patterns; for example, catastrophizing, all-or-nothing thinkingYes9 (29)
Example activitiesExample of pleasurable activities to do to improve one’s moodYes9 (29)
Writing and self-reflectionDiaries and journalsNo6 (19)
Tracking moodTracking and annotating moodsYes5 (16)
Self-assessmentTests and scales to assess one’s well-beingNo5 (16)
Gratitude and affirmationsGratitude diary, examples of affirmations, ability to add affirmations, questions encouraging positive thinking about selfNo5 (16)
Information about CBTArticles, blog posts, and other resources explaining cognitive behavioral therapy, its components, and how it worksYes4 (13)
Information about depressionArticles, blog posts, videos, and other resources explaining depression, its symptoms, how it works, and how to deal with itYes3 (10)
Recording thoughts and emotionsRecording information about events, and thoughts and emotions that accompany themYes3 (10)
Scheduling activitiesPlanning activitiesYes3 (10)
Relaxation tracksCalming music, sounds of nature, etcNo3 (10)
General information about well-beingArticles, blog posts, videos, and other resources about mental health in general, health tips, well-being advice, nutrition, etcNo3 (10)
Tracking anxiety and worriesTracking anxiety incidents, worry listsNo3 (10)
Recording and monitoring daily activitiesRecording activities, matching activities with the calendar and mood informationYes2 (6)
Challenges and behavioral experimentsTasks to complete to practice (new) coping skillsYes2 (6)
Setting goalsSetting up specific goals to works towardYes2 (6)
Peer supportAbility to join forums or social networks, ask questions, and talk to othersNo2 (6)
Suicide preventionLinks to support services, ability to prepare a crisis planYes1 (3)
Challenging beliefsWritten exercises and examples of tasks to do to address one’s beliefs about the world and selfYes1 (3)
Breathing exercisesWritten or recorded (audio or video) instructions for breathing exercisesNo1 (3)
MindfulnessMindfulness meditation tracks and written exercise instructions; excludes other types of meditationNo1 (3)
Fun contentGames, jokes, and humorous content to provide distractions and improve one’s moodNo1 (3)
Inspirational quotesQuotes of famous people to provide motivation and lift one’s moodNo1 (3)
MeditationGuided meditation, topics to contemplate; excludes mindfulnessNo1 (3)
Physical exercise and yogaSuggestions for specific exercises or yoga sessionsNo1 (3)

We don't need to implement all of these, and in my opinion we shouldn't, but I'm keeping this here as an example of what the field is like.

Scope and single-purpose design

I would be really hesitant to suggest that "more features" are better here. From a product design perspective, more features can overwhelm a user, spread developer effort too thin, and eat up valuable UI real estate.

Plus, the more CBT and "general health" features we add, often the specific the app becomes. That makes it harder for folks with less common conditions to use the app.

For example, many CBT apps currently ask you to record your mood. While that is a CBT exercise, AFAIK it's not typically an exercise given to folks with panic attacks, OCD, or other non-depression conditions. So by adding it in, we're not just making the experience "better" for depressive users, we're making it worse for non-depressive users.

Often existing mental health app designers fall into a "captive market" hypothesis. They believe that in order to best treat their users, they must be the only mental health app. So rather than trying to do one thing really well, they try do to everything within the context of a single app. This ultimately leads to a poor user experience.

Landscape mode

I hate writing in portraid mode, I can't in fact! It would be nice if quirk supported landscape mode.

Consider mentioning that thoughts are only saved locally

Given that thoughts are quite sensitive, I think it might be worth telling folks during on-boarding that their data will never leave the device. Down the line it might even be a good idea to allow passcode protection of the list screen, but that’s just thinking out loud.

strange button press animation - disconnects from the action

I can not take a screenshot of it soo let me explain.

Go to the "Cognitive Distortion"
Hold down and do not release any of the buttons.
The button gets greyed out. Like deactivated.
Now release the button. It activates and gets highlighted.

I think you should confirm the press itself by highlighting too.
I feel no confirmation from the app during the press.
It feels disconnected and not reassuring.

Confirm press itself. Yes user I got your choosing.
Highlight after release to mark it active.

iPad app

Please add an iPad build.

And let me use the app in vertical and horizontal screen mode.

Thank you!

Screenshot Changelog

Overview

This thread is a place for rough screenshots of the current state of the app while it's in development, including which things need work.

Extremely important sticker concerns

Screen Shot 2019-04-10 at 4 11 14 PM

Proof of dope stickers

Sideways because photos are hard.

IMG_1956 (1)

How to get them

If you contributed to the project, I would love to mail you a sticker (along with a note of thanks!).

Specifically I'd like to call out these amazing people for their crazy awesome work:

  • @devinroche (you're in SF so I'ma just hand them to you)
  • @devilcius for the amazing Spanish translation
  • @idnovic for the amazing German translation (and the iPad support!)
  • @kwierbol for the amazing Polish translation
  • @Walther for the amazing Finnish translation
  • @Jos512 for the amazing Dutch translation
  • @jinto for the amazing Korean translation
  • @briankung for the Chinese localization, internationalization support and helping guide the entire translation effort. 🎉

Two ways to get them:

  • If you're in the bay area, let me buy you coffee and I'll give you a sticker in person!
  • If you're not, or just don't want to grab coffee, give me your address and I'll mail you one!

Send your address and preferred sticker-delivery-method to this email: [email protected]

Fixup Cognitive Distortion Input Items

Overview

The input items in the cognitive distortion selector are crap, we should fix them.

screen shot 2018-12-15 at 11 15 32 am

Steps

  • Give them a larger tappable area
  • Give them an feather icon on the far right
  • Maybe give it a light highlight on selected

Seeking Android Champion

Overview

I don't have an Android phone. I'd love to make this app really great on Android, but I don't use it and can't as easily verify that it's as bug free and stable as the iOS version.

So I'm seeking someone who would be willing to take on an "Android Champion" role.

Fix possible side-loaded trackers

While the README highlights the focus on privacy the resulting application sadly doesn't. I don't think it's intended so I hope that the report helps to start investigating the reasons for that and remove the tracks from the Code:

https://reports.exodus-privacy.eu.org/en/reports/69301/

The exodus report indicates that there are code signatures of 11 trackers/ad services involved. Important: It doesn't mean they are active, but that's something that should be investigated.

My idea where this comes from: Dependencies. Since I already mention I don't expect it to be intentional, there is likely that those trackers came as "side-loaded content" by one of the dependencies. Anyway, I think it's important to find and getting rid of them. Hope you get this fixed soon as the app is great! GPL 👍

Come up with a better input method

Overview

Current inputs are ugly looking. That outline is kinda gross. But we still need contrast.

screen shot 2018-12-15 at 11 11 25 am

Steps

  • Brainstorm better ideas
  • ???
  • Profit

Localization and internationalization of string assets

Thanks for nice project. It'll be great for applying CBT's techniques in life.
Is there any plans about preparing localization and internationalization?
When it's ready, I can help translating string assets to Korean.

Cannot launch app on Android

I wanted to run the app on my android phone but I just get a "Something went wrong" screen.

Error log shows:

Uncaught Error: Error while updating property 'borderRadius' of a view managed by: RTCView

Android Version 9
Device: OnePlus 5T

Weird "back to previous screen" behavior

When the user creates a thought, then presses the "go back to screen" button, it doesn't preserve the thought they were just on which messes with the way screens normally work. Plus, if you "swipe" left it has the correct effect.

Creation vs Editing screens

When you click on a list item, you go back to the creation screen with the items prefilled out. That makes it really easy to accidentally change or wipe something when you're just looking.

We should make it slightly harder to modify when you click on a list item. We can probably do that by having an entrance from the list view put the creation screen into an "view" mode and then having an edit button that the user needs to click on in order to be able to modify the inputs.

We should add the first illustration in the empty space

Overview

In the mocks, we have an illustration in the empty space on the list view, but not in the app at the moment.

Mock

screen shot 2018-12-15 at 12 24 18 pm

Current

screen shot 2018-12-15 at 12 24 39 pm

Steps

  • Figure out how React Native handles images
  • Maybe create multiple sizes of the illustration
  • Put the illustration in the empty space

Fix the save button

Overview

The save button should look like the mocks, over to the side and blue.

Current

screen shot 2018-12-15 at 11 17 14 am

Mock

screen shot 2018-12-15 at 11 17 59 am

Steps

  • Make button #546de5
  • Move button over to the right

Publishing Checklist

Overview

These are all the things that we need to do in order to publish. We're publishing first on iOS.

High Value Steps

These are required to publish for iOS.

Low Value Steps

These we should do, but aren't required to publish for iOS.

  • Make sure the app doesn't "break" on iPads
  • Configure the status bar so we're not clashing
  • Choose a PrimaryColor (Android)

Internationalize plan

Hi,
I’m a Korean programmer and had CBT before. I think it should be great if you support other languages.

I translated ‘groovy programming language’ into korean and contributed translation of ‘django girls’.

Do you have plan for internalization?

Different sentence structures in various languages

Problem

The sentence structure of some languages ​​(subject-object-predicate order) may be different.

Examples:

Introduction screen

Screenshot

English: "Welcome to quirk, the Cognitive Behavioral Therapy (CBT) App."
When translate this to Turkish, sentence structure is changing like this:
"Bilişsel Davranışçı Terapi (BDT) uygulaması quirk 'e hoş geldiniz!"
If we look at word by word:

  • "Bilişsel Davranışçı Terapi (BDT)" -> "Cognitive Behavioral Therapy (CBT)"
  • "uygulaması" -> "app"
  • " 'e " -> "to"
  • "hoş geldiniz" -> "Welcome"

I tried this for add this Turkish sentence:

"intro": {
  "line1":"",
  "emphasis1": "Bilişsel Davranışçı Terapi (BDT)",
  "line2":" uygulaması",
  "emphasis2": "quirk",
  "line3": "'e hoş geldiniz!"
},

but as you can see there is a little space before the word ("Bilişsel").

YourThoughtsArentYourThoughts screen

Screenshot

English: "Second: your thoughts can be automatic"
Turkish: "İkinci olarak: düşünceleriniz otomatikleşmiş olabilir"
Word by word:

  • "İkinci olarak" -> "Second"
  • "düşünceleriniz" -> "your thoughts"
  • "otomatikleşmiş" -> "automatic"
  • "olabilir" -> "can be"

I tried this:

"thoughts_arent_thoughts": {
  "line1": "İkinci olarak: düşünceleriniz",
  "emphasis1": "otomatikleşmiş",
  "line2": "olabilir."
},

but as you can see, there are missing word ("olabilir") on the screen.

Therefore, we need to be able to change the line order (including adding new lines).

Solution Suggestion

Such a structure came to my mind:

"intro": {
	"1": { "type": "emphasis", "text": "Bilişsel Davranışçı Terapi (BDT)" },
	"2": { "type": "line", "text": "uygulaması" },
	"3": { "type": "emphasis", "text": "quirk" },
	"4": { "type": "line", "text": " 'e hoş geldiniz!" }
},

Pseudo code:

var intro = {
	"1": { "type": "emphasis", "text": "Bilişsel Davranışçı Terapi (BDT)" },
	"2": { "type": "line", "text": "uygulaması" },
	"3": { "type": "emphasis", "text": "quirk" },
	"4": { "type": "line", "text": " 'e hoş geldiniz!" }
}

for (var line in intro) {
  var properties=intro[line];
  if (properties.type == "emphasis") {
    console.log("<Exaggerated>"+properties.text+"</Exaggerated>")
  } else {
    console.log(properties.text);
  }
}

Output:

"<Exaggerated>Bilişsel Davranışçı Terapi (BDT)</Exaggerated>"
"uygulaması"
"<Exaggerated>quirk</Exaggerated>"
" 'e hoş geldiniz!"

But I don't know how to implement this solution in React (I'm not React Developer) and I'm not sure this is a good solution. What you think about this solution? Or do you have any other suggestions?

Thanks for this amazing app. I would be happy to help contribute.

https://getquirk.app/ SSL issue

This site can’t provide a secure connection getquirk.app sent an invalid response.
Try running Windows Network Diagnostics.
ERR_SSL_PROTOCOL_ERROR

Publish on F-Droid

First off, let me say thank you for creating and open-sourcing such an app. You're awesome!

Have you thought about publishing the app on F-Droid?

Dark theme

It would be awesome if there was a dark theme.

Refactor the ui components

The UI file has a lot of tech debt :/

  • Convert them to typescript instead of proptypes
  • Whenever possible, make style a prop that you can pass in.

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.