Skip to content

Commit 0b5d29b

Browse files
committed
fix mobile/android notes not showing until refresh/change mode
1 parent 7ab4f64 commit 0b5d29b

File tree

9 files changed

+38
-15
lines changed

9 files changed

+38
-15
lines changed

android/app/src/main/assets/public/assets/index-DhE_q3AR.js renamed to android/app/src/main/assets/public/assets/index-B1frYiu1.js

Lines changed: 2 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

android/app/src/main/assets/public/assets/mobileInit-BjDn5VWt.js renamed to android/app/src/main/assets/public/assets/mobileInit-si7He02f.js

Lines changed: 2 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

android/app/src/main/assets/public/assets/web-KEPh1bJr.js renamed to android/app/src/main/assets/public/assets/web-DYjHHYsn.js

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

android/app/src/main/assets/public/assets/web-BBNafJl7.js renamed to android/app/src/main/assets/public/assets/web-DyTx0sUG.js

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

android/app/src/main/assets/public/index.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
<link rel="manifest" href="/site.webmanifest"> <meta name="viewport" content="width=device-width, initial-scale=1.0" />
99
<title>Trusty Notes</title>
1010
<script defer data-domain="notes.toolworks.dev" src="https://plausible.toolworks.dev/js/script.js"></script>
11-
<script type="module" crossorigin src="/assets/index-DhE_q3AR.js"></script>
11+
<script type="module" crossorigin src="/assets/index-B1frYiu1.js"></script>
1212
<link rel="modulepreload" crossorigin href="/assets/buffer-Cq5fL-tY.js">
1313
<link rel="stylesheet" crossorigin href="/assets/index-BHNR0Rya.css">
1414
</head>

android/capacitor-cordova-android-plugins/build.gradle

Lines changed: 7 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ buildscript {
99
mavenCentral()
1010
}
1111
dependencies {
12-
classpath 'com.android.tools.build:gradle:8.7.2'
12+
classpath 'com.android.tools.build:gradle:8.2.1'
1313
}
1414
}
1515

@@ -19,16 +19,18 @@ android {
1919
namespace "capacitor.cordova.android.plugins"
2020
compileSdk project.hasProperty('compileSdkVersion') ? rootProject.ext.compileSdkVersion : 34
2121
defaultConfig {
22-
minSdkVersion project.hasProperty('minSdkVersion') ? rootProject.ext.minSdkVersion : 23
22+
minSdkVersion project.hasProperty('minSdkVersion') ? rootProject.ext.minSdkVersion : 22
2323
targetSdkVersion project.hasProperty('targetSdkVersion') ? rootProject.ext.targetSdkVersion : 34
24+
versionCode 1
25+
versionName "1.0"
26+
}
27+
lintOptions {
28+
abortOnError false
2429
}
2530
compileOptions {
2631
sourceCompatibility JavaVersion.VERSION_17
2732
targetCompatibility JavaVersion.VERSION_17
2833
}
29-
lint {
30-
abortOnError false
31-
}
3234
}
3335

3436
repositories {

android/capacitor-cordova-android-plugins/cordova.variables.gradle

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
// DO NOT EDIT THIS FILE! IT IS GENERATED EACH TIME "capacitor update" IS RUN
22
ext {
3-
cdvMinSdkVersion = project.hasProperty('minSdkVersion') ? rootProject.ext.minSdkVersion : 23
3+
cdvMinSdkVersion = project.hasProperty('minSdkVersion') ? rootProject.ext.minSdkVersion : 22
44
// Plugin gradle extensions can append to this to have code run at the end.
55
cdvPluginPostBuildExtras = []
66
cordovaConfig = [:]

src/components/RichTextEditor.tsx

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,13 +44,14 @@ export function RichTextEditor({ content, onChange }: RichTextEditorProps) {
4444
editorProps: {
4545
attributes: {
4646
class: 'rich-text-editor',
47+
style: 'height: 100%'
4748
},
4849
},
4950
});
5051

5152
useEffect(() => {
5253
if (editor && content !== editor.getHTML()) {
53-
editor.commands.setContent(content);
54+
editor.commands.setContent(content, false);
5455
}
5556
}, [content, editor]);
5657

src/styles/mobile.css

Lines changed: 21 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,8 +11,10 @@
1111
padding-top: var(--ion-safe-area-top);
1212
padding-bottom: var(--ion-safe-area-bottom);
1313
background-color: var(--mantine-color-body);
14+
height: 100vh;
15+
overflow: hidden;
1416
}
15-
17+
1618
.keyboard-visible .markdown-editor {
1719
max-height: calc(100vh - 270px);
1820
}
@@ -23,6 +25,24 @@
2325
overflow-x: hidden;
2426
-webkit-text-size-adjust: 100%;
2527
}
28+
29+
.android .ProseMirror {
30+
min-height: 50vh;
31+
height: calc(100vh - 200px);
32+
overflow-y: auto;
33+
-webkit-overflow-scrolling: touch;
34+
}
35+
36+
.android .rich-text-editor {
37+
display: flex;
38+
flex-direction: column;
39+
height: calc(100vh - 120px);
40+
}
41+
42+
.android .mantine-AppShell-main {
43+
height: 100vh;
44+
overflow: hidden;
45+
}
2646

2747
.mantine-AppShell-main {
2848
padding: 2px !important;

0 commit comments

Comments
 (0)