0
0
mirror of https://github.com/ankidroid/Anki-Android.git synced 2024-09-19 19:42:17 +02:00
Commit Graph

19583 Commits

Author SHA1 Message Date
Mike Hardy
7fbfcae180 docs: add comment on when deprecated code may be removed
I dislike seeing this build-time deprecation warning every build,
and investigated if we could remove this. We can't but I was able
to see when, so I wrote it out in order to not forget and spend
the time researching again

The comment I left should show up in standard searches for removable
code based on VERSION_CODES / minSdk when we bump versions
2024-08-19 23:30:36 +00:00
Robozinho
a33e6eab7d fix: template previewer UI
the template previewer was tightly coupled with the template editor, and
that isn't a good design. To solve that, I decoupled the template
previewer in two fragments: a view and a standalone page.
All of the original style of the template previewer was fixed.

I gave credits to BrayanDSO in TemplatePreviewerPage.kt because most of
the code is his and I don't want the credits myself

I also removed the duplicated TabLayout in the card editor because it
didn't make sense to me.
2024-08-19 22:27:23 +00:00
Robozinho
aa6022ad70 refactor: move status bar color change 2024-08-19 22:27:23 +00:00
Mike Hardy
91b984a6a1 test: compare whole string not first char in NoteEditor test
this test is marked flaky so it won't ever run in CI but it was
failing locally for me every time as it was comparing the first
char of the string it pulled to a string, instead of string vs string
2024-08-19 15:04:33 +00:00
AnkiDroid Translations
127fa3287f Updated strings from Crowdin 2024-08-19 14:57:53 +00:00
Ashish Yadav
5889d13b28 chore: add tooltip text in instant note editor buttons 2024-08-19 14:19:12 +00:00
dependabot[bot]
9541b3a8ee chore(deps): bump gradle/actions from 3 to 4
Bumps [gradle/actions](https://github.com/gradle/actions) from 3 to 4.
- [Release notes](https://github.com/gradle/actions/releases)
- [Commits](https://github.com/gradle/actions/compare/v3...v4)

---
updated-dependencies:
- dependency-name: gradle/actions
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
2024-08-19 14:13:14 +00:00
AnkiDroid Translations
75f17dfb0b Updated strings from Crowdin 2024-08-19 12:17:53 +00:00
AnkiDroid Translations
edfdb88d25 Updated strings from Crowdin 2024-08-19 08:55:30 +00:00
Sahil-Mandal15
3f7dcfdb8d
Fix: Tell the users why card type deletion fails when this would orphan note. (#16840)
* added the alertDialog when users deletes the card type that causes orphan note which describes why the card type cannot be deleted also added the messages into the strings.xml

* completing changes requested for the fix-16789

* made changes in the test file to match the text in the fix:16789

* removed the unused string after adding the new string to test case.
2024-08-18 23:21:45 -05:00
AnkiDroid Translations
bd756fc49a Updated strings from Crowdin 2024-08-19 04:04:35 +00:00
Voczi
ce6b0864a5 fix: new reviewer crashes when adding a note 2024-08-18 14:15:42 -03:00
Arthur Milchior
6967cc8732 Correct description 2024-08-18 12:12:32 +00:00
shuvashish76
bc942c2f9f Add files via upload 2024-08-18 12:12:32 +00:00
shuvashish76
6f52a3259f Delete old app icon 2024-08-18 12:12:32 +00:00
shuvashish76
d5439af1c4 Update new full_description 2024-08-18 12:12:32 +00:00
shuvashish76
941640778b Add fastlane metadata for F-Droid
Addresses #7999
2024-08-18 12:12:32 +00:00
SanjaySargam
e1a553b3cf cardbrowser: keyboard shortcuts
Keyboard shortcuts:

Ctrl+Shift+A : Add tag
Ctrl+Shift+E : Export selected cards
Ctrl+Alt+N : Reset card progress
Ctrl+Alt+T : Toggle cards/notes
T : Show filter by tags
Ctrl+Shift+S : Reposition selected cards
Ctrl+Alt+S : Show saved searches
Ctrl+S : Save search
Alt+S : Show suspended cards
Ctrl+Shift+J : Toggle bury cards
Ctrl+J : Toggle suspended cards
Ctrl+Shift+I : Card Info
Ctrl+O : Show order dialog
Ctrl+M : Mark note
Ctrl+Z : Undo
ESC : Select none
Ctrl+1 : Red flag
Ctrl+2 : Orange flag
Ctrl+3 : Green flag
Ctrl+4 : Blue flag
Ctrl+5 : Pink flag
Ctrl+6 : Turqoise flag
Ctrl+7 : Purple flag
2024-08-17 17:27:08 +00:00
Ashish Yadav
f108911ff6 fix: IllegalStateException in audio player 2024-08-17 17:26:02 +00:00
Sumit Singh
f0e5c32ada refactor: commons compress improvements 2024-08-17 01:45:55 +00:00
Mike Hardy
1e1e46d7e2 Bumped version to 2.19alpha11 2024-08-17 01:47:07 +00:00
Mike Hardy
34e48ad35b build(ci): reclaim disk space on emulator runner
it is relatively easy to do an rm-rf directly but there are maintained
workflow actions that remove everything for you

This is the most-maintained fork of the most popular one I've used before

It defaults to true, and each item you remove takes time. I think dotnet
is the biggest one and should be sufficient so only remove it and that
should be sufficient
2024-08-17 00:50:24 +00:00
AnkiDroid Translations
d9fd9445a6 Updated strings from Crowdin 2024-08-17 00:50:24 +00:00
Brayan Oliveira
4af8ad3a8b feat: Hide 'Hard' and 'Easy' buttons setting
It is a frequently requested feature, helps a big number of users that
only use two buttons, and it is quite simple to implement
2024-08-16 03:28:49 +00:00
Ashish Yadav
c85da52161 test: unit test to ensure MultimediaBottomSheet is shown 2024-08-16 02:59:47 +00:00
David Allison
fe52f06d85 docs: dependencies - changelogs (AGP) 2024-08-16 02:55:15 +00:00
David Allison
9a949ae90c test: fix hangs on Linux
In PR 16620, I encountered the following error on
ubuntu CI

After research, `CppAssetManager2` errors are  typically due to memory leaks, often by not calling close on Scenarios

```
TagsDialogTest > test_SearchTag_spaceWillBeFilteredCorrectly FAILED
    java.lang.OutOfMemoryError: Java heap space
        at org.robolectric.res.android.ResourceTypes$ResTable_typeSpec.getSpecFlags(ResourceTypes.java:1095)
        at org.robolectric.res.android.LoadedArsc$TypeSpec.GetFlagsForEntryIndex(LoadedArsc.java:116)
        at org.robolectric.res.android.CppAssetManager2.FindEntry(CppAssetManager2.java:699)
        at org.robolectric.res.android.CppAssetManager2.GetResource(CppAssetManager2.java:869)
        at org.robolectric.res.android.CppAssetManager2.ResolveReference(CppAssetManager2.java:935)
        at org.robolectric.res.android.AttributeResolution10.ApplyStyle(AttributeResolution10.java:414)
        at org.robolectric.shadows.ShadowArscAssetManager10.nativeApplyStyle_measured(ShadowArscAssetManager10.java:1414)
        at org.robolectric.shadows.ShadowArscAssetManager10.lambda$nativeApplyStyle$1(ShadowArscAssetManager10.java:1374)
        at org.robolectric.shadows.ShadowArscAssetManager10$$Lambda/0x00007f40d092a740.run(Unknown Source)
        at org.robolectric.util.PerfStatsCollector.measure(PerfStatsCollector.java:82)
        at org.robolectric.shadows.ShadowArscAssetManager10.nativeApplyStyle(ShadowArscAssetManager10.java:1371)
        at java.base/java.lang.invoke.LambdaForm$DMH/0x00007f40d0946800.invokeStatic(LambdaForm$DMH)
        at java.base/java.lang.invoke.LambdaForm$MH/0x00007f40d0948800.guardWithCatch(LambdaForm$MH)
        at java.base/java.lang.invoke.LambdaForm$MH/0x00007f40d0ab3400.delegate(LambdaForm$MH)
        at java.base/java.lang.invoke.LambdaForm$MH/0x00007f40d094ac00.guard(LambdaForm$MH)
        at java.base/java.lang.invoke.LambdaForm$MH/0x00007f40d094b000.linkToCallSite(LambdaForm$MH)
        at android.content.res.AssetManager.nativeApplyStyle(AssetManager.java)
        at android.content.res.AssetManager.applyStyle(AssetManager.java:1147)
        at java.base/java.lang.invoke.LambdaForm$DMH/0x00007f40d0941400.invokeSpecial(LambdaForm$DMH)
        at java.base/java.lang.invoke.LambdaForm$MH/0x00007f40d0943c00.guardWithCatch(LambdaForm$MH)
        at java.base/java.lang.invoke.LambdaForm$MH/0x00007f40d0ab3000.delegate(LambdaForm$MH)
        at java.base/java.lang.invoke.LambdaForm$MH/0x00007f40d0946000.guard(LambdaForm$MH)
        at java.base/java.lang.invoke.LambdaForm$MH/0x00007f40d0946400.linkToCallSite(LambdaForm$MH)
        at android.content.res.AssetManager.applyStyle(AssetManager.java)
        at android.content.res.ResourcesImpl$ThemeImpl.obtainStyledAttributes(ResourcesImpl.java:1394)
        at java.base/java.lang.invoke.LambdaForm$DMH/0x00007f40d035d400.invokeSpecial(LambdaForm$DMH)
        at java.base/java.lang.invoke.LambdaForm$MH/0x00007f40d093fc00.guardWithCatch(LambdaForm$MH)
        at java.base/java.lang.invoke.LambdaForm$MH/0x00007f40d035dc00.delegate(LambdaForm$MH)
        at java.base/java.lang.invoke.LambdaForm$MH/0x00007f40d0940c00.guard(LambdaForm$MH)
        at java.base/java.lang.invoke.LambdaForm$MH/0x00007f40d0941000.linkToCallSite(LambdaForm$MH)
        at android.content.res.ResourcesImpl$ThemeImpl.obtainStyledAttributes(ResourcesImpl.java)
        at android.content.res.Resources$Theme.obtainStyledAttributes(Resources.java:1692)
```
2024-08-16 02:43:04 +00:00
David Allison
b4ba390061 chore: allow optionally displaying a ListPreference
This exists as we want a dialog to show either a List or an EditText,
and both the framework classes require inheritance

For Issue 3114
2024-08-16 02:19:34 +00:00
David Allison
0d46ac3523 chore: guard against null getExternalFilesDirs
I know `getExternalFilesDir(null)!!` can throw, I'm unsure
if the array can throw, but it's best to be safe here
2024-08-16 02:19:34 +00:00
David Allison
9175d9ec29 chore: 'DialogFragmentProvider' - make optional
If a call to super is requested, `null` may be returned
In this case, `super` would be called

This is useful if you would optionally want to inherit from
a class (say `EditTextPreference`), but also allow conditionally
return a different fragment
2024-08-16 02:19:34 +00:00
David Allison
6ab15ec3ea feat(tool): format issue/PR links in Discord
Links to the repo are unpleasant to see:

* Link previews are too large & distracting
* Links without a preview give no context

I want something which both gives context, and is compact

`macos-clipboard-to-discord` converts an issue link:
https://github.com/ankidroid/Anki-Android/pull/16804

into:
* A link with text: "#16804: refactor/docs: `libs.versions.toml` changelogs/renames"
* Without a preview
* Redirecting to the correct PR

`./format-for-discord` performs this formatting: accepting a PR/Issue number: 16804
and outputting the above to stdout
2024-08-15 20:01:16 -06:00
Mike Hardy
977fd5685e
Dependency updates 20240815 (#16877)
* build(deps): bump androidxFragmentKtx from 1.8.1 to 1.8.2 (#16780)

Bumps `androidxFragmentKtx` from 1.8.1 to 1.8.2.

Updates `androidx.fragment:fragment-ktx` from 1.8.1 to 1.8.2

Updates `androidx.fragment:fragment-testing` from 1.8.1 to 1.8.2

Updates `androidx.fragment:fragment-testing-manifest` from 1.8.1 to 1.8.2

---
updated-dependencies:
- dependency-name: androidx.fragment:fragment-ktx
  dependency-type: direct:production
  update-type: version-update:semver-patch
- dependency-name: androidx.fragment:fragment-testing
  dependency-type: direct:production
  update-type: version-update:semver-patch
- dependency-name: androidx.fragment:fragment-testing-manifest
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

* build(deps): bump androidx.annotation:annotation from 1.8.0 to 1.8.1 (#16782)

Bumps androidx.annotation:annotation from 1.8.0 to 1.8.1.

---
updated-dependencies:
- dependency-name: androidx.annotation:annotation
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

* build(deps): bump hamcrest from 2.2 to 3.0 (#16802)

Bumps `hamcrest` from 2.2 to 3.0.

Updates `org.hamcrest:hamcrest` from 2.2 to 3.0
- [Release notes](https://github.com/hamcrest/JavaHamcrest/releases)
- [Changelog](https://github.com/hamcrest/JavaHamcrest/blob/master/CHANGES.md)
- [Commits](https://github.com/hamcrest/JavaHamcrest/compare/v2.2...v3.0)

Updates `org.hamcrest:hamcrest-library` from 2.2 to 3.0
- [Release notes](https://github.com/hamcrest/JavaHamcrest/releases)
- [Changelog](https://github.com/hamcrest/JavaHamcrest/blob/master/CHANGES.md)
- [Commits](https://github.com/hamcrest/JavaHamcrest/compare/v2.2...v3.0)

---
updated-dependencies:
- dependency-name: org.hamcrest:hamcrest
  dependency-type: direct:production
  update-type: version-update:semver-major
- dependency-name: org.hamcrest:hamcrest-library
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

* build(deps): bump com.google.protobuf:protobuf-kotlin-lite (#16801)

Bumps com.google.protobuf:protobuf-kotlin-lite from 4.27.2 to 4.27.3.

---
updated-dependencies:
- dependency-name: com.google.protobuf:protobuf-kotlin-lite
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

* build(deps): bump androidx.activity:activity from 1.9.0 to 1.9.1 (#16781)

Bumps androidx.activity:activity from 1.9.0 to 1.9.1.

---
updated-dependencies:
- dependency-name: androidx.activity:activity
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

* build(deps): bump kotlinTest from 2.0.0 to 2.0.10 (#16835)

Bumps `kotlinTest` from 2.0.0 to 2.0.10.

Updates `org.jetbrains.kotlin:kotlin-test` from 2.0.0 to 2.0.10
- [Release notes](https://github.com/JetBrains/kotlin/releases)
- [Changelog](https://github.com/JetBrains/kotlin/blob/master/ChangeLog.md)
- [Commits](https://github.com/JetBrains/kotlin/commits)

Updates `org.jetbrains.kotlin:kotlin-test-junit` from 2.0.0 to 2.0.10
- [Release notes](https://github.com/JetBrains/kotlin/releases)
- [Changelog](https://github.com/JetBrains/kotlin/blob/master/ChangeLog.md)
- [Commits](https://github.com/JetBrains/kotlin/commits)

Updates `org.jetbrains.kotlin:kotlin-test-junit5` from 2.0.0 to 2.0.10
- [Release notes](https://github.com/JetBrains/kotlin/releases)
- [Changelog](https://github.com/JetBrains/kotlin/blob/master/ChangeLog.md)
- [Commits](https://github.com/JetBrains/kotlin/commits)

---
updated-dependencies:
- dependency-name: org.jetbrains.kotlin:kotlin-test
  dependency-type: direct:production
  update-type: version-update:semver-patch
- dependency-name: org.jetbrains.kotlin:kotlin-test-junit
  dependency-type: direct:production
  update-type: version-update:semver-patch
- dependency-name: org.jetbrains.kotlin:kotlin-test-junit5
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

* build(deps): bump kotlin from 2.0.0 to 2.0.10 (#16834)

Bumps `kotlin` from 2.0.0 to 2.0.10.

Updates `org.jetbrains.kotlin:kotlin-stdlib` from 2.0.0 to 2.0.10
- [Release notes](https://github.com/JetBrains/kotlin/releases)
- [Changelog](https://github.com/JetBrains/kotlin/blob/master/ChangeLog.md)
- [Commits](https://github.com/JetBrains/kotlin/commits)

Updates `org.jetbrains.kotlin.android` from 2.0.0 to 2.0.10
- [Release notes](https://github.com/JetBrains/kotlin/releases)
- [Changelog](https://github.com/JetBrains/kotlin/blob/master/ChangeLog.md)
- [Commits](https://github.com/JetBrains/kotlin/commits)

Updates `org.jetbrains.kotlin.plugin.parcelize` from 2.0.0 to 2.0.10
- [Release notes](https://github.com/JetBrains/kotlin/releases)
- [Changelog](https://github.com/JetBrains/kotlin/blob/master/ChangeLog.md)
- [Commits](https://github.com/JetBrains/kotlin/commits)

Updates `org.jetbrains.kotlin.jvm` from 2.0.0 to 2.0.10
- [Release notes](https://github.com/JetBrains/kotlin/releases)
- [Changelog](https://github.com/JetBrains/kotlin/blob/master/ChangeLog.md)
- [Commits](https://github.com/JetBrains/kotlin/commits)

Updates `org.jetbrains.kotlin.plugin.serialization` from 2.0.0 to 2.0.10
- [Release notes](https://github.com/JetBrains/kotlin/releases)
- [Changelog](https://github.com/JetBrains/kotlin/blob/master/ChangeLog.md)
- [Commits](https://github.com/JetBrains/kotlin/commits)

---
updated-dependencies:
- dependency-name: org.jetbrains.kotlin:kotlin-stdlib
  dependency-type: direct:production
  update-type: version-update:semver-patch
- dependency-name: org.jetbrains.kotlin.android
  dependency-type: direct:production
  update-type: version-update:semver-patch
- dependency-name: org.jetbrains.kotlin.plugin.parcelize
  dependency-type: direct:production
  update-type: version-update:semver-patch
- dependency-name: org.jetbrains.kotlin.jvm
  dependency-type: direct:production
  update-type: version-update:semver-patch
- dependency-name: org.jetbrains.kotlin.plugin.serialization
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

* build(deps): bump org.jetbrains.kotlin:kotlin-reflect (#16833)

Bumps [org.jetbrains.kotlin:kotlin-reflect](https://github.com/JetBrains/kotlin) from 2.0.0 to 2.0.10.
- [Release notes](https://github.com/JetBrains/kotlin/releases)
- [Changelog](https://github.com/JetBrains/kotlin/blob/master/ChangeLog.md)
- [Commits](https://github.com/JetBrains/kotlin/commits)

---
updated-dependencies:
- dependency-name: org.jetbrains.kotlin:kotlin-reflect
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

* chore(deps): bump androidx.annotation:annotation from 1.8.1 to 1.8.2 (#16846)

Bumps androidx.annotation:annotation from 1.8.1 to 1.8.2.

---
updated-dependencies:
- dependency-name: androidx.annotation:annotation
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

* chore(deps): bump workRuntimeKtx from 2.9.0 to 2.9.1 (#16845)

Bumps `workRuntimeKtx` from 2.9.0 to 2.9.1.

Updates `androidx.work:work-runtime-ktx` from 2.9.0 to 2.9.1

Updates `androidx.work:work-testing` from 2.9.0 to 2.9.1

---
updated-dependencies:
- dependency-name: androidx.work:work-runtime-ktx
  dependency-type: direct:production
  update-type: version-update:semver-patch
- dependency-name: androidx.work:work-testing
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

* chore(deps): bump org.apache.commons:commons-compress (#16852)

Bumps org.apache.commons:commons-compress from 1.26.2 to 1.27.0.

---
updated-dependencies:
- dependency-name: org.apache.commons:commons-compress
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

* chore(deps): bump lint from 31.5.1 to 31.5.2 (#16854)

Bumps `lint` from 31.5.1 to 31.5.2.

Updates `com.android.tools.lint:lint-api` from 31.5.1 to 31.5.2

Updates `com.android.tools.lint:lint` from 31.5.1 to 31.5.2

Updates `com.android.tools.lint:lint-tests` from 31.5.1 to 31.5.2

---
updated-dependencies:
- dependency-name: com.android.tools.lint:lint-api
  dependency-type: direct:production
  update-type: version-update:semver-patch
- dependency-name: com.android.tools.lint:lint
  dependency-type: direct:production
  update-type: version-update:semver-patch
- dependency-name: com.android.tools.lint:lint-tests
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

* chore(deps): bump androidGradlePlugin from 8.5.1 to 8.5.2 (#16853)

Bumps `androidGradlePlugin` from 8.5.1 to 8.5.2.

Updates `com.android.application` from 8.5.1 to 8.5.2

Updates `com.android.library` from 8.5.1 to 8.5.2

---
updated-dependencies:
- dependency-name: com.android.application
  dependency-type: direct:production
  update-type: version-update:semver-patch
- dependency-name: com.android.library
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

* Update Gradle Wrapper from 8.9 to 8.10

(this was applied automatically but I inadvertently clobbered it while
untangling some git rebase conflicts since it went in between rebase
start and push)

* style(lint): fix lint errors from previous refactors

it appears lint is not run on checkin or CI here

* build(deps): update to / forward port to eslint v9+

* style(lint): result of `yarn format`

it appears this is not checked in CI

* test(ci): check localization lint + formatting in CI

* build(deps): `yarn upgrade-interactive` in tools/localization

all of these updates are minors, should be fine but will
need an i18n sync in production to verify

* build(deps): bump androidxMedia3 from 1.3.1 to 1.4.0

Bumps `androidxMedia3` from 1.3.1 to 1.4.0.

Updates `androidx.media3:media3-ui` from 1.3.1 to 1.4.0
- [Release notes](https://github.com/androidx/media/releases)
- [Changelog](https://github.com/androidx/media/blob/release/RELEASENOTES.md)
- [Commits](https://github.com/androidx/media/compare/1.3.1...1.4.0)

Updates `androidx.media3:media3-exoplayer-dash` from 1.3.1 to 1.4.0
- [Release notes](https://github.com/androidx/media/releases)
- [Changelog](https://github.com/androidx/media/blob/release/RELEASENOTES.md)
- [Commits](https://github.com/androidx/media/compare/1.3.1...1.4.0)

Updates `androidx.media3:media3-exoplayer` from 1.3.1 to 1.4.0
- [Release notes](https://github.com/androidx/media/releases)
- [Changelog](https://github.com/androidx/media/blob/release/RELEASENOTES.md)
- [Commits](https://github.com/androidx/media/compare/1.3.1...1.4.0)

---
updated-dependencies:
- dependency-name: androidx.media3:media3-ui
  dependency-type: direct:production
  update-type: version-update:semver-minor
- dependency-name: androidx.media3:media3-exoplayer-dash
  dependency-type: direct:production
  update-type: version-update:semver-minor
- dependency-name: androidx.media3:media3-exoplayer
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>

* build(deps): junit-jupiter moves as a locked-version set, consolidate it

* chore(deps): bump org.junit.jupiter:junit-jupiter

Bumps [org.junit.jupiter:junit-jupiter](https://github.com/junit-team/junit5) from 5.10.3 to 5.11.0.
- [Release notes](https://github.com/junit-team/junit5/releases)
- [Commits](https://github.com/junit-team/junit5/compare/r5.10.3...r5.11.0)

---
updated-dependencies:
- dependency-name: org.junit.jupiter:junit-jupiter-params
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-08-15 20:45:59 -05:00
AnkiDroid Translations
38272302d5 Updated strings from Crowdin 2024-08-15 22:51:56 +00:00
SanjaySargam
292d662d0b note-editor: drop files
This commit ensures that we can drop files (photos, videos, and audio) in NoteEditor (FixedEditText).

Fix: Handle minSdkVersion conflict with DropHelper and enable file drop in NoteEditor
Added DropHelperCompat to handle the incompatibility issue with DropHelper and minSdkVersion 23. The manifest merger failed with the following error:

> Manifest merger failed: uses-sdk:minSdkVersion 23 cannot be smaller than version 24 declared in library [androidx.draganddrop:draganddrop:1.0.0] /Users/davidallison/.gradle/cache> s/8.8/transforms/0a1688833d368c1b9b07d2054911030e/transformed/draganddrop-1.0.0/AndroidManifest.xml as the library might be using APIs not available in 23
> Suggestion: use a compatible library with a minSdk of at most 23,
>     or increase this project's minSdk version to at least 24,
>     or use tools:overrideLibrary="androidx.draganddrop" to force usage
>     (may lead to runtime failures)

To resolve this, the DropHelperCompat class is used to conditionally configure the view for drag and drop operations only when the SDK version is 24 or higher.
2024-08-15 18:49:35 +00:00
SanjaySargam
9d036f61e8 rename 'image' to 'media'
In preparation for 'Drag & Drop' work,
which will allow importing of media
2024-08-15 18:49:35 +00:00
David Allison
06e8ac2ef3 remove Kotlin's "Context Receiver" feature
Context Receivers are an experimental Kotlin feature
. They will be removed and replaced with Context Parameters.
It is unlikely that there will be any overlap period, so we need
to remove our Context Receiver code, with the intention of replacing it
at a later date

> * **2.0.20**: A warning is introduced for declarations that use
> context receivers.
> The warning should mention that the design of context receivers
> is about to change, according to the new design (add a link to the KEEP/YT).
> The safest workaround is to migrate your code to extensions.
>  * **2.1.20**: The implementation of context receivers is removed from the compiler.
> Effectively, this warning is turned into an error.
> Note that this part is most likely inevitable as the implementation
> of context parameters requires  quite extensive refactoring in the compiler,
> and there are significant chances that we won't have either
> context receivers or context parameters at that time.
>  [There is a slight chance that we'll have an early prototype of context parameters,
> but we are not counting on that.]
> * **2.2.0**: Context parameters are introduced under a new compiler flag.

https://youtrack.jetbrains.com/issue/KT-67119/Migration-warning-from-context-receivers-to-context-parameters

> **Phased removal of context receivers feature**
> In Kotlin 1.6.20, we introduced context receivers as an
> Experimental feature. After listening to community
> feedback, we've decided not to continue with it. Instead,
> we plan to introduce a replacement in future Kotlin
> releases: context parameters. You can find the proposal
> for context parameters in the KEEP.

https://kotlinlang.org/docs/whatsnew-eap.html#phased-removal-of-context-receivers-feature

Deprecated:
https://redirect.github.com/Kotlin/KEEP/blob/context-parameters/proposals/context-receivers.md
* https://redirect.github.com/Kotlin/KEEP/issues/259

To be replaced by:
https://redirect.github.com/Kotlin/KEEP/blob/context-parameters/proposals/context-parameters.md
* https://redirect.github.com/Kotlin/KEEP/issues/367

Fixes 16863

Reverts: 672b075a54
Reverts: 1c01e4cb6f
2024-08-14 22:40:48 +00:00
SanjaySargam
35cfd4de33 load fragment after one second of text change
refresh fragment after one second of text changed. And hide preview icon if fragmented as there is no point of having this option because the fragment will auto-refresh the content.
2024-08-11 19:56:14 +00:00
SanjaySargam
b1a94f5ec5 UI improvements
This commit updates the UI to ensure that the previewer theme matches the card template editor theme.

CardTemplateEditor
- Set navigation bar color to use alternative background color
- Update background color attribute

TemplatePreviewerFragment
- Apply style to TabLayout for consistent appearance
2024-08-11 19:56:14 +00:00
SanjaySargam
a98bdd5f54 Change in card type gets reflected in the previewer
This commit ensures that if we change card on leading side then the previewer fragment will load and shows same card on trailing side
2024-08-11 19:56:14 +00:00
SanjaySargam
502ce7f4eb load fragment when performing action on cards
This commit updates the previewer when addition, deletion, renaming of cards.
2024-08-11 19:56:14 +00:00
SanjaySargam
a256d952bf Merge the previewer's menu into the editor's when the view is fragmented
This commit switch the previewer menu from MateralToolbar to toolbar so that it has the same menu has the editor.
It introduces setupCommonMenu and handleCommonMenuItemSelected that add the previewer's menu entry and handle them. They are called from the editor's menu if the view is fragmented, and from the previewer's own menu otherwise.
2024-08-11 19:56:14 +00:00
SanjaySargam
c0405e5fb3 Merge previewer's back button into the editor's one when the view is fragmented.
This commit adds a fragmented variable to TemplatePreviewerArguments, to
let the previewer knows whether it belongs to a fragmented view. If so,
the previewer's back button is removed, hence only the editor's back
button remain.
2024-08-11 19:56:14 +00:00
SanjaySargam
edb562a3bc Attach TemplatePreviewerFragment to CardTemplateEditor
On xlarge screen, display the previewer on the trailing side of the card template editor

This commit introduces a new view, card_template_editor.xml, that contains the card template editor (implemented in card_template_editor_activity.xml) and potentially the previewer on xlarge screen.

CardTemplateEditor.kt simply set the content view to card_template_editor instead of card_template_editor_activity, and add the previewer if needed.
2024-08-11 19:56:14 +00:00
Shruti Gitte
7512a8e545 Fix:Status bar color 2024-08-11 00:18:24 +00:00
Rohanraj123
f5eedc8ba5 test: Added test case for requireLong() method at BundleUtils.kt 2024-08-10 16:54:46 +00:00
David Allison
773e74e0e7 docs: dependencies - changelogs (Apache Commons) 2024-08-09 17:10:08 +00:00
AnkiDroid Translations
f29722d2d6 Updated strings from Crowdin 2024-08-08 20:38:45 +00:00
David Allison
394462950e docs: dependencies - changelogs (androidx-work) 2024-08-08 18:27:47 +00:00
SanjaySargam
436d84b030 shortcut E: edit note 2024-08-08 18:13:55 +00:00
AnkiDroid Translations
463cec1239 Updated strings from Crowdin 2024-08-08 17:50:01 +00:00