Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Figure out a way for jdoc strings to be exposed to the AnkiDroid repo #208

Open
dae opened this issue Jun 19, 2022 · 0 comments
Open

Figure out a way for jdoc strings to be exposed to the AnkiDroid repo #208

dae opened this issue Jun 19, 2022 · 0 comments

Comments

@dae
Copy link
Contributor

dae commented Jun 19, 2022

The generated translation accessors include KDoc strings, so that you can hover over a call to see the text it will return, eg:

    /** Changed position of {$count} new cards. */
    fun browsingChangedNewPosition(`count`: Int): String {
        return translate(2, 25, mapOf("count" to asTranslateArg(`count`)))
    }


    /** Clear Unused Tags */
    fun browsingClearUnusedTags(): String {
        return translate(2, 26, mapOf())
    }


    /** A saved search with the name {$name} already exists. Do you want to overwrite it? */
    fun browsingConfirmSavedSearchOverwrite(`name`: String): String {
        return translate(2, 27, mapOf("name" to asTranslateArg(`name`)))
    }

Currently these are not visible when working on the AnkiDroid repo, as they don't get included in the generated .class files. Not essential, but would be nice to have if AnkiDroid wants to start using these.

Related: #15

dae added a commit to ankitects/Anki-Android-Backend that referenced this issue Jun 16, 2023
This fixes, partially, ankidroid#208. When used with a local Maven repo, it
works correctly. Unfortunately it doesn't fix things for the normal
case, as gradle/intellij seem to get confused when the library is in
an .aar instead of a jar.

Once this is fully working, it will allow people to hover over backend
functions/messages to get documentation, when it exists.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant