diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md
index 7498a07..01160a5 100644
--- a/CONTRIBUTING.md
+++ b/CONTRIBUTING.md
@@ -1,6 +1,6 @@
# Contributing
-Thanks for helping improve simplenotes. The goal of this project is a simple, local-first, open-source notes app with a strong mobile ink foundation.
+Thanks for helping improve OpenNotes. The goal of this project is a simple, local-first, open-source notes app with a strong mobile ink foundation.
Small, focused contributions are welcome: bug reports, reproducible crashes, device-specific PDF import/export issues, documentation fixes, UI polish, and careful fixes to local storage or native integration all help.
@@ -30,7 +30,7 @@ Expo Go is not supported because the app depends on native code from `@mathnotes
## App And Engine Boundaries
-Use this repo for the simplenotes app: library UX, note storage, PDF import/export behavior, app chrome, and platform submission work.
+Use this repo for the OpenNotes app: library UX, note storage, PDF import/export behavior, app chrome, and platform submission work.
Use [`mathnotes-app/mobile-ink`](https://github.com/mathnotes-app/mobile-ink) for reusable ink-engine bugs, canvas primitives, native rendering, selection behavior, stroke serialization, and engine-level PDF/page handling.
diff --git a/NOTICE b/NOTICE
index 7453708..e449090 100644
--- a/NOTICE
+++ b/NOTICE
@@ -1,4 +1,4 @@
-simplenotes
+OpenNotes
Copyright 2026 BuilderPro LLC
This product includes software developed by BuilderPro LLC.
diff --git a/README.md b/README.md
index 2e9c378..1de35e1 100644
--- a/README.md
+++ b/README.md
@@ -1,20 +1,20 @@
-# simplenotes
+# OpenNotes
A no-bloat, local-first, open-source notes app.
-
-
+
+
-simplenotes is an iOS and Android notes app for people who want fast handwriting, PDFs, folders, and simple organization without the usual bloat. It is free, open source, and privacy focused: notes are stored on-device, the app does not collect analytics, and your notebooks never leave your device unless you choose to export or share them.
+OpenNotes is an iOS and Android notes app for people who want fast handwriting, PDFs, folders, and simple organization without the usual bloat. It is free, open source, and privacy focused: notes are stored on-device, the app does not collect analytics, and your notebooks never leave your device unless you choose to export or share them.
The app is built on [`@mathnotes/mobile-ink`](https://github.com/mathnotes-app/mobile-ink), the open-source React Native ink engine extracted from MathNotes.
## Status
-simplenotes is early and moving quickly. The repo is public now so the app, the ink engine, and the issue tracker can be maintained in the open. App Store and Play Store submissions are planned after the first public assets and submission metadata are ready.
+OpenNotes is early and moving quickly. The repo is public now so the app, the ink engine, and the issue tracker can be maintained in the open. App Store and Play Store submissions are planned after the first public assets and submission metadata are ready.
Screenshots and product images are coming soon.
@@ -59,9 +59,9 @@ npx expo run:ios --device
## Privacy
-simplenotes is designed to be local and private. The app does not include analytics SDKs, tracking, cloud sync, accounts, or server storage. Notes, imported PDFs, images, and thumbnails are stored on your device.
+OpenNotes is designed to be local and private. The app does not include analytics SDKs, tracking, cloud sync, accounts, or server storage. Notes, imported PDFs, images, and thumbnails are stored on your device.
-If you export, share, back up, or import files through another app or operating-system service, that service's behavior is outside simplenotes.
+If you export, share, back up, or import files through another app or operating-system service, that service's behavior is outside OpenNotes.
## Contributing
diff --git a/SECURITY.md b/SECURITY.md
index 0f06507..d661e04 100644
--- a/SECURITY.md
+++ b/SECURITY.md
@@ -11,4 +11,4 @@ Useful reports include:
- Native bridge issues in PDF import/export, image handling, or Mobile Ink integration.
- Dependency or build configuration issues that could compromise users or downstream contributors.
-simplenotes is local-first and does not run a hosted notes service. The most important security and privacy surfaces are local file storage, import/export flows, native parsing/rendering, and accidental inclusion of private data in issues or pull requests.
+OpenNotes is local-first and does not run a hosted notes service. The most important security and privacy surfaces are local file storage, import/export flows, native parsing/rendering, and accidental inclusion of private data in issues or pull requests.
diff --git a/android/app/build.gradle b/android/app/build.gradle
index f664f68..8c940d0 100644
--- a/android/app/build.gradle
+++ b/android/app/build.gradle
@@ -87,9 +87,9 @@ android {
buildToolsVersion rootProject.ext.buildToolsVersion
compileSdk rootProject.ext.compileSdkVersion
- namespace 'com.simplenotes.app'
+ namespace 'com.opennotes.app'
defaultConfig {
- applicationId 'com.simplenotes.app'
+ applicationId 'com.opennotes.app'
minSdkVersion rootProject.ext.minSdkVersion
targetSdkVersion rootProject.ext.targetSdkVersion
versionCode 1
diff --git a/android/app/src/main/AndroidManifest.xml b/android/app/src/main/AndroidManifest.xml
index 1221f3f..8c8b343 100644
--- a/android/app/src/main/AndroidManifest.xml
+++ b/android/app/src/main/AndroidManifest.xml
@@ -24,8 +24,8 @@
-
-
+
+
diff --git a/android/app/src/main/java/com/simplenotes/app/MainActivity.kt b/android/app/src/main/java/com/opennotes/app/MainActivity.kt
similarity index 98%
rename from android/app/src/main/java/com/simplenotes/app/MainActivity.kt
rename to android/app/src/main/java/com/opennotes/app/MainActivity.kt
index 159f896..ae1b2fe 100644
--- a/android/app/src/main/java/com/simplenotes/app/MainActivity.kt
+++ b/android/app/src/main/java/com/opennotes/app/MainActivity.kt
@@ -1,4 +1,4 @@
-package com.simplenotes.app
+package com.opennotes.app
import android.os.Build
import android.os.Bundle
diff --git a/android/app/src/main/java/com/simplenotes/app/MainApplication.kt b/android/app/src/main/java/com/opennotes/app/MainApplication.kt
similarity index 98%
rename from android/app/src/main/java/com/simplenotes/app/MainApplication.kt
rename to android/app/src/main/java/com/opennotes/app/MainApplication.kt
index 4ac1cd9..bea22a6 100644
--- a/android/app/src/main/java/com/simplenotes/app/MainApplication.kt
+++ b/android/app/src/main/java/com/opennotes/app/MainApplication.kt
@@ -1,4 +1,4 @@
-package com.simplenotes.app
+package com.opennotes.app
import android.app.Application
import android.content.res.Configuration
diff --git a/android/app/src/main/java/com/simplenotes/app/PDFUtilsModule.kt b/android/app/src/main/java/com/opennotes/app/PDFUtilsModule.kt
similarity index 99%
rename from android/app/src/main/java/com/simplenotes/app/PDFUtilsModule.kt
rename to android/app/src/main/java/com/opennotes/app/PDFUtilsModule.kt
index 970f334..7dd8d5d 100644
--- a/android/app/src/main/java/com/simplenotes/app/PDFUtilsModule.kt
+++ b/android/app/src/main/java/com/opennotes/app/PDFUtilsModule.kt
@@ -1,4 +1,4 @@
-package com.simplenotes.app
+package com.opennotes.app
import android.graphics.pdf.PdfRenderer
import android.net.Uri
diff --git a/android/app/src/main/java/com/simplenotes/app/PDFUtilsPackage.kt b/android/app/src/main/java/com/opennotes/app/PDFUtilsPackage.kt
similarity index 98%
rename from android/app/src/main/java/com/simplenotes/app/PDFUtilsPackage.kt
rename to android/app/src/main/java/com/opennotes/app/PDFUtilsPackage.kt
index 6e282cc..65582de 100644
--- a/android/app/src/main/java/com/simplenotes/app/PDFUtilsPackage.kt
+++ b/android/app/src/main/java/com/opennotes/app/PDFUtilsPackage.kt
@@ -1,4 +1,4 @@
-package com.simplenotes.app
+package com.opennotes.app
import com.facebook.react.TurboReactPackage
import com.facebook.react.bridge.NativeModule
diff --git a/android/app/src/main/res/values/strings.xml b/android/app/src/main/res/values/strings.xml
index b0bc990..4aa6430 100644
--- a/android/app/src/main/res/values/strings.xml
+++ b/android/app/src/main/res/values/strings.xml
@@ -1,3 +1,3 @@
- simplenotes
+ OpenNotes
\ No newline at end of file
diff --git a/android/settings.gradle b/android/settings.gradle
index 55361b7..fd9c1b2 100644
--- a/android/settings.gradle
+++ b/android/settings.gradle
@@ -31,7 +31,7 @@ extensions.configure(com.facebook.react.ReactSettingsExtension) { ex ->
}
expoAutolinking.useExpoModules()
-rootProject.name = 'simplenotes'
+rootProject.name = 'OpenNotes'
expoAutolinking.useExpoVersionCatalog()
diff --git a/app.json b/app.json
index d706225..3263daf 100644
--- a/app.json
+++ b/app.json
@@ -1,18 +1,18 @@
{
"expo": {
- "name": "simplenotes",
- "slug": "simplenotes",
+ "name": "OpenNotes",
+ "slug": "open-notes",
"version": "0.1.0",
- "scheme": "simplenotes",
+ "scheme": "opennotes",
"orientation": "default",
"userInterfaceStyle": "automatic",
"newArchEnabled": true,
"ios": {
- "bundleIdentifier": "com.simplenotes.app",
+ "bundleIdentifier": "com.opennotes.app",
"supportsTablet": true,
"infoPlist": {
- "NSPhotoLibraryUsageDescription": "simplenotes needs access to your photo library so you can insert images into your notes.",
- "NSCameraUsageDescription": "simplenotes needs camera access so you can capture images directly into your notes.",
+ "NSPhotoLibraryUsageDescription": "OpenNotes needs access to your photo library so you can insert images into your notes.",
+ "NSCameraUsageDescription": "OpenNotes needs camera access so you can capture images directly into your notes.",
"LSSupportsOpeningDocumentsInPlace": true,
"CFBundleDocumentTypes": [
{
@@ -45,7 +45,7 @@
}
},
"android": {
- "package": "com.simplenotes.app",
+ "package": "com.opennotes.app",
"permissions": [
"android.permission.READ_EXTERNAL_STORAGE",
"android.permission.WRITE_EXTERNAL_STORAGE",
@@ -83,8 +83,8 @@
[
"expo-image-picker",
{
- "photosPermission": "simplenotes accesses your photos to let you insert them into notes.",
- "cameraPermission": "simplenotes accesses the camera to let you capture images into notes."
+ "photosPermission": "OpenNotes accesses your photos to let you insert them into notes.",
+ "cameraPermission": "OpenNotes accesses the camera to let you capture images into notes."
}
]
]
diff --git a/app/index.tsx b/app/index.tsx
index f715ba5..9e1d31f 100644
--- a/app/index.tsx
+++ b/app/index.tsx
@@ -227,13 +227,13 @@ export default function LibraryScreen() {
return (
void openUrl('https://github.com/mathnotes-app/simplenotes'),
+ accessibilityLabel: 'Open OpenNotes on GitHub',
+ onPress: () => void openUrl('https://github.com/mathnotes-app/OpenNotes'),
},
{
key: 'x',
@@ -244,7 +244,7 @@ export default function LibraryScreen() {
{
key: 'about',
icon: 'information-circle-outline',
- accessibilityLabel: 'About simplenotes',
+ accessibilityLabel: 'About OpenNotes',
onPress: () => setAction({ kind: 'about' }),
},
]}
@@ -480,7 +480,7 @@ function AboutSheet({
- About simplenotes
+ About OpenNotes
Simple notes, open foundations.
@@ -489,7 +489,7 @@ function AboutSheet({
- simplenotes is meant to be a no-bloat, simple, free, open source notes
+ OpenNotes is meant to be a no-bloat, simple, free, open source notes
app. Most notes apps collect years of extra features, put important
tools behind a subscription, and keep the underlying ink technology
closed source.
@@ -504,7 +504,7 @@ function AboutSheet({
people write.
- simplenotes is powered by the open source Mobile Ink engine.
+ OpenNotes is powered by the open source Mobile Ink engine.
);
diff --git a/ios/simplenotes.xcodeproj/project.pbxproj b/ios/OpenNotes.xcodeproj/project.pbxproj
similarity index 82%
rename from ios/simplenotes.xcodeproj/project.pbxproj
rename to ios/OpenNotes.xcodeproj/project.pbxproj
index bc6b0dd..6a2db26 100644
--- a/ios/simplenotes.xcodeproj/project.pbxproj
+++ b/ios/OpenNotes.xcodeproj/project.pbxproj
@@ -13,27 +13,27 @@
4788858903E15B3CAEB129E6 /* ExpoModulesProvider.swift in Sources */ = {isa = PBXBuildFile; fileRef = 9B82DFB67047998EABD93C92 /* ExpoModulesProvider.swift */; };
7D3A80162E1A4CC89B1B09C1 /* PDFUtilsModule.swift in Sources */ = {isa = PBXBuildFile; fileRef = 7D3A80142E1A4CC89B1B09C1 /* PDFUtilsModule.swift */; };
7D3A80172E1A4CC89B1B09C1 /* PDFUtilsModule.m in Sources */ = {isa = PBXBuildFile; fileRef = 7D3A80152E1A4CC89B1B09C1 /* PDFUtilsModule.m */; };
- 9C2FD7C620026BB779139CCD /* libPods-simplenotes.a in Frameworks */ = {isa = PBXBuildFile; fileRef = A7A85B485F4321855B927960 /* libPods-simplenotes.a */; };
+ 9C2FD7C620026BB779139CCD /* libPods-OpenNotes.a in Frameworks */ = {isa = PBXBuildFile; fileRef = A7A85B485F4321855B927960 /* libPods-OpenNotes.a */; };
BB2F792D24A3F905000567C9 /* Expo.plist in Resources */ = {isa = PBXBuildFile; fileRef = BB2F792C24A3F905000567C9 /* Expo.plist */; };
F11748422D0307B40044C1D9 /* AppDelegate.swift in Sources */ = {isa = PBXBuildFile; fileRef = F11748412D0307B40044C1D9 /* AppDelegate.swift */; };
/* End PBXBuildFile section */
/* Begin PBXFileReference section */
- 13B07F961A680F5B00A75B9A /* simplenotes.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = simplenotes.app; sourceTree = BUILT_PRODUCTS_DIR; };
- 13B07FB51A68108700A75B9A /* Images.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; name = Images.xcassets; path = simplenotes/Images.xcassets; sourceTree = ""; };
- 13B07FB61A68108700A75B9A /* Info.plist */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.xml; name = Info.plist; path = simplenotes/Info.plist; sourceTree = ""; };
- 575BE98DD16F76BFF21A39E6 /* PrivacyInfo.xcprivacy */ = {isa = PBXFileReference; includeInIndex = 1; name = PrivacyInfo.xcprivacy; path = simplenotes/PrivacyInfo.xcprivacy; sourceTree = ""; };
- 7D3A80142E1A4CC89B1B09C1 /* PDFUtilsModule.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; name = PDFUtilsModule.swift; path = simplenotes/PDFUtilsModule.swift; sourceTree = ""; };
- 7D3A80152E1A4CC89B1B09C1 /* PDFUtilsModule.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; name = PDFUtilsModule.m; path = simplenotes/PDFUtilsModule.m; sourceTree = ""; };
- 9B82DFB67047998EABD93C92 /* ExpoModulesProvider.swift */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.swift; name = ExpoModulesProvider.swift; path = "Pods/Target Support Files/Pods-simplenotes/ExpoModulesProvider.swift"; sourceTree = ""; };
- A7A85B485F4321855B927960 /* libPods-simplenotes.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = "libPods-simplenotes.a"; sourceTree = BUILT_PRODUCTS_DIR; };
- AA286B85B6C04FC6940260E9 /* SplashScreen.storyboard */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = file.storyboard; name = SplashScreen.storyboard; path = simplenotes/SplashScreen.storyboard; sourceTree = ""; };
+ 13B07F961A680F5B00A75B9A /* OpenNotes.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = OpenNotes.app; sourceTree = BUILT_PRODUCTS_DIR; };
+ 13B07FB51A68108700A75B9A /* Images.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; name = Images.xcassets; path = OpenNotes/Images.xcassets; sourceTree = ""; };
+ 13B07FB61A68108700A75B9A /* Info.plist */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.xml; name = Info.plist; path = OpenNotes/Info.plist; sourceTree = ""; };
+ 575BE98DD16F76BFF21A39E6 /* PrivacyInfo.xcprivacy */ = {isa = PBXFileReference; includeInIndex = 1; name = PrivacyInfo.xcprivacy; path = OpenNotes/PrivacyInfo.xcprivacy; sourceTree = ""; };
+ 7D3A80142E1A4CC89B1B09C1 /* PDFUtilsModule.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; name = PDFUtilsModule.swift; path = OpenNotes/PDFUtilsModule.swift; sourceTree = ""; };
+ 7D3A80152E1A4CC89B1B09C1 /* PDFUtilsModule.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; name = PDFUtilsModule.m; path = OpenNotes/PDFUtilsModule.m; sourceTree = ""; };
+ 9B82DFB67047998EABD93C92 /* ExpoModulesProvider.swift */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.swift; name = ExpoModulesProvider.swift; path = "Pods/Target Support Files/Pods-OpenNotes/ExpoModulesProvider.swift"; sourceTree = ""; };
+ A7A85B485F4321855B927960 /* libPods-OpenNotes.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = "libPods-OpenNotes.a"; sourceTree = BUILT_PRODUCTS_DIR; };
+ AA286B85B6C04FC6940260E9 /* SplashScreen.storyboard */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = file.storyboard; name = SplashScreen.storyboard; path = OpenNotes/SplashScreen.storyboard; sourceTree = ""; };
BB2F792C24A3F905000567C9 /* Expo.plist */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.xml; path = Expo.plist; sourceTree = ""; };
- CEB267F85878647A5ACA788A /* Pods-simplenotes.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-simplenotes.release.xcconfig"; path = "Target Support Files/Pods-simplenotes/Pods-simplenotes.release.xcconfig"; sourceTree = ""; };
- E6710FB66EE811C212116106 /* Pods-simplenotes.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-simplenotes.debug.xcconfig"; path = "Target Support Files/Pods-simplenotes/Pods-simplenotes.debug.xcconfig"; sourceTree = ""; };
+ CEB267F85878647A5ACA788A /* Pods-OpenNotes.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-OpenNotes.release.xcconfig"; path = "Target Support Files/Pods-OpenNotes/Pods-OpenNotes.release.xcconfig"; sourceTree = ""; };
+ E6710FB66EE811C212116106 /* Pods-OpenNotes.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-OpenNotes.debug.xcconfig"; path = "Target Support Files/Pods-OpenNotes/Pods-OpenNotes.debug.xcconfig"; sourceTree = ""; };
ED297162215061F000B7C4FE /* JavaScriptCore.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = JavaScriptCore.framework; path = System/Library/Frameworks/JavaScriptCore.framework; sourceTree = SDKROOT; };
- F11748412D0307B40044C1D9 /* AppDelegate.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; name = AppDelegate.swift; path = simplenotes/AppDelegate.swift; sourceTree = ""; };
- F11748442D0722820044C1D9 /* simplenotes-Bridging-Header.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; name = "simplenotes-Bridging-Header.h"; path = "simplenotes/simplenotes-Bridging-Header.h"; sourceTree = ""; };
+ F11748412D0307B40044C1D9 /* AppDelegate.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; name = AppDelegate.swift; path = OpenNotes/AppDelegate.swift; sourceTree = ""; };
+ F11748442D0722820044C1D9 /* OpenNotes-Bridging-Header.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; name = "OpenNotes-Bridging-Header.h"; path = "OpenNotes/OpenNotes-Bridging-Header.h"; sourceTree = ""; };
/* End PBXFileReference section */
/* Begin PBXFrameworksBuildPhase section */
@@ -41,44 +41,44 @@
isa = PBXFrameworksBuildPhase;
buildActionMask = 2147483647;
files = (
- 9C2FD7C620026BB779139CCD /* libPods-simplenotes.a in Frameworks */,
+ 9C2FD7C620026BB779139CCD /* libPods-OpenNotes.a in Frameworks */,
);
runOnlyForDeploymentPostprocessing = 0;
};
/* End PBXFrameworksBuildPhase section */
/* Begin PBXGroup section */
- 13B07FAE1A68108700A75B9A /* simplenotes */ = {
+ 13B07FAE1A68108700A75B9A /* OpenNotes */ = {
isa = PBXGroup;
children = (
F11748412D0307B40044C1D9 /* AppDelegate.swift */,
7D3A80142E1A4CC89B1B09C1 /* PDFUtilsModule.swift */,
7D3A80152E1A4CC89B1B09C1 /* PDFUtilsModule.m */,
- F11748442D0722820044C1D9 /* simplenotes-Bridging-Header.h */,
+ F11748442D0722820044C1D9 /* OpenNotes-Bridging-Header.h */,
BB2F792B24A3F905000567C9 /* Supporting */,
13B07FB51A68108700A75B9A /* Images.xcassets */,
13B07FB61A68108700A75B9A /* Info.plist */,
AA286B85B6C04FC6940260E9 /* SplashScreen.storyboard */,
575BE98DD16F76BFF21A39E6 /* PrivacyInfo.xcprivacy */,
);
- name = simplenotes;
+ name = OpenNotes;
sourceTree = "";
};
2D16E6871FA4F8E400B85C8A /* Frameworks */ = {
isa = PBXGroup;
children = (
ED297162215061F000B7C4FE /* JavaScriptCore.framework */,
- A7A85B485F4321855B927960 /* libPods-simplenotes.a */,
+ A7A85B485F4321855B927960 /* libPods-OpenNotes.a */,
);
name = Frameworks;
sourceTree = "";
};
- 50EA7A6BE1D6947E458B577C /* simplenotes */ = {
+ 50EA7A6BE1D6947E458B577C /* OpenNotes */ = {
isa = PBXGroup;
children = (
9B82DFB67047998EABD93C92 /* ExpoModulesProvider.swift */,
);
- name = simplenotes;
+ name = OpenNotes;
sourceTree = "";
};
832341AE1AAA6A7D00B99B32 /* Libraries */ = {
@@ -91,7 +91,7 @@
83CBB9F61A601CBA00E9B192 = {
isa = PBXGroup;
children = (
- 13B07FAE1A68108700A75B9A /* simplenotes */,
+ 13B07FAE1A68108700A75B9A /* OpenNotes */,
832341AE1AAA6A7D00B99B32 /* Libraries */,
83CBBA001A601CBA00E9B192 /* Products */,
2D16E6871FA4F8E400B85C8A /* Frameworks */,
@@ -106,7 +106,7 @@
83CBBA001A601CBA00E9B192 /* Products */ = {
isa = PBXGroup;
children = (
- 13B07F961A680F5B00A75B9A /* simplenotes.app */,
+ 13B07F961A680F5B00A75B9A /* OpenNotes.app */,
);
name = Products;
sourceTree = "";
@@ -114,7 +114,7 @@
B025AFE641A7B146AB64069B /* ExpoModulesProviders */ = {
isa = PBXGroup;
children = (
- 50EA7A6BE1D6947E458B577C /* simplenotes */,
+ 50EA7A6BE1D6947E458B577C /* OpenNotes */,
);
name = ExpoModulesProviders;
sourceTree = "";
@@ -125,14 +125,14 @@
BB2F792C24A3F905000567C9 /* Expo.plist */,
);
name = Supporting;
- path = simplenotes/Supporting;
+ path = OpenNotes/Supporting;
sourceTree = "";
};
CCEB29EB4EA264547E3F22DF /* Pods */ = {
isa = PBXGroup;
children = (
- E6710FB66EE811C212116106 /* Pods-simplenotes.debug.xcconfig */,
- CEB267F85878647A5ACA788A /* Pods-simplenotes.release.xcconfig */,
+ E6710FB66EE811C212116106 /* Pods-OpenNotes.debug.xcconfig */,
+ CEB267F85878647A5ACA788A /* Pods-OpenNotes.release.xcconfig */,
);
name = Pods;
path = Pods;
@@ -141,9 +141,9 @@
/* End PBXGroup section */
/* Begin PBXNativeTarget section */
- 13B07F861A680F5B00A75B9A /* simplenotes */ = {
+ 13B07F861A680F5B00A75B9A /* OpenNotes */ = {
isa = PBXNativeTarget;
- buildConfigurationList = 13B07F931A680F5B00A75B9A /* Build configuration list for PBXNativeTarget "simplenotes" */;
+ buildConfigurationList = 13B07F931A680F5B00A75B9A /* Build configuration list for PBXNativeTarget "OpenNotes" */;
buildPhases = (
08A4A3CD28434E44B6B9DE2E /* [CP] Check Pods Manifest.lock */,
C0723C22CAA8DB53B683F90D /* [Expo] Configure project */,
@@ -158,9 +158,9 @@
);
dependencies = (
);
- name = simplenotes;
- productName = simplenotes;
- productReference = 13B07F961A680F5B00A75B9A /* simplenotes.app */;
+ name = OpenNotes;
+ productName = OpenNotes;
+ productReference = 13B07F961A680F5B00A75B9A /* OpenNotes.app */;
productType = "com.apple.product-type.application";
};
/* End PBXNativeTarget section */
@@ -178,7 +178,7 @@
};
};
};
- buildConfigurationList = 83CBB9FA1A601CBA00E9B192 /* Build configuration list for PBXProject "simplenotes" */;
+ buildConfigurationList = 83CBB9FA1A601CBA00E9B192 /* Build configuration list for PBXProject "OpenNotes" */;
compatibilityVersion = "Xcode 3.2";
developmentRegion = en;
hasScannedForEncodings = 0;
@@ -191,7 +191,7 @@
projectDirPath = "";
projectRoot = "";
targets = (
- 13B07F861A680F5B00A75B9A /* simplenotes */,
+ 13B07F861A680F5B00A75B9A /* OpenNotes */,
);
};
/* End PBXProject section */
@@ -243,7 +243,7 @@
outputFileListPaths = (
);
outputPaths = (
- "$(DERIVED_FILE_DIR)/Pods-simplenotes-checkManifestLockResult.txt",
+ "$(DERIVED_FILE_DIR)/Pods-OpenNotes-checkManifestLockResult.txt",
);
runOnlyForDeploymentPostprocessing = 0;
shellPath = /bin/sh;
@@ -256,7 +256,7 @@
files = (
);
inputPaths = (
- "${PODS_ROOT}/Target Support Files/Pods-simplenotes/Pods-simplenotes-frameworks.sh",
+ "${PODS_ROOT}/Target Support Files/Pods-OpenNotes/Pods-OpenNotes-frameworks.sh",
"${PODS_XCFRAMEWORKS_BUILD_DIR}/React-Core-prebuilt/React.framework/React",
"${PODS_XCFRAMEWORKS_BUILD_DIR}/ReactNativeDependencies/ReactNativeDependencies.framework/ReactNativeDependencies",
"${PODS_XCFRAMEWORKS_BUILD_DIR}/hermes-engine/Pre-built/hermes.framework/hermes",
@@ -269,7 +269,7 @@
);
runOnlyForDeploymentPostprocessing = 0;
shellPath = /bin/sh;
- shellScript = "\"${PODS_ROOT}/Target Support Files/Pods-simplenotes/Pods-simplenotes-frameworks.sh\"\n";
+ shellScript = "\"${PODS_ROOT}/Target Support Files/Pods-OpenNotes/Pods-OpenNotes-frameworks.sh\"\n";
showEnvVarsInLog = 0;
};
800E24972A6A228C8D4807E9 /* [CP] Copy Pods Resources */ = {
@@ -278,7 +278,7 @@
files = (
);
inputPaths = (
- "${PODS_ROOT}/Target Support Files/Pods-simplenotes/Pods-simplenotes-resources.sh",
+ "${PODS_ROOT}/Target Support Files/Pods-OpenNotes/Pods-OpenNotes-resources.sh",
"${PODS_CONFIGURATION_BUILD_DIR}/EXConstants/EXConstants.bundle",
"${PODS_CONFIGURATION_BUILD_DIR}/EXConstants/ExpoConstants_privacy.bundle",
"${PODS_CONFIGURATION_BUILD_DIR}/ExpoFileSystem/ExpoFileSystem_privacy.bundle",
@@ -301,7 +301,7 @@
);
runOnlyForDeploymentPostprocessing = 0;
shellPath = /bin/sh;
- shellScript = "\"${PODS_ROOT}/Target Support Files/Pods-simplenotes/Pods-simplenotes-resources.sh\"\n";
+ shellScript = "\"${PODS_ROOT}/Target Support Files/Pods-OpenNotes/Pods-OpenNotes-resources.sh\"\n";
showEnvVarsInLog = 0;
};
C0723C22CAA8DB53B683F90D /* [Expo] Configure project */ = {
@@ -315,18 +315,18 @@
inputPaths = (
"$(SRCROOT)/.xcode.env",
"$(SRCROOT)/.xcode.env.local",
- "$(SRCROOT)/simplenotes/simplenotes.entitlements",
- "$(SRCROOT)/Pods/Target Support Files/Pods-simplenotes/expo-configure-project.sh",
+ "$(SRCROOT)/OpenNotes/OpenNotes.entitlements",
+ "$(SRCROOT)/Pods/Target Support Files/Pods-OpenNotes/expo-configure-project.sh",
);
name = "[Expo] Configure project";
outputFileListPaths = (
);
outputPaths = (
- "$(SRCROOT)/Pods/Target Support Files/Pods-simplenotes/ExpoModulesProvider.swift",
+ "$(SRCROOT)/Pods/Target Support Files/Pods-OpenNotes/ExpoModulesProvider.swift",
);
runOnlyForDeploymentPostprocessing = 0;
shellPath = /bin/sh;
- shellScript = "# This script configures Expo modules and generates the modules provider file.\nbash -l -c \"./Pods/Target\\ Support\\ Files/Pods-simplenotes/expo-configure-project.sh\"\n";
+ shellScript = "# This script configures Expo modules and generates the modules provider file.\nbash -l -c \"./Pods/Target\\ Support\\ Files/Pods-OpenNotes/expo-configure-project.sh\"\n";
};
/* End PBXShellScriptBuildPhase section */
@@ -347,11 +347,11 @@
/* Begin XCBuildConfiguration section */
13B07F941A680F5B00A75B9A /* Debug */ = {
isa = XCBuildConfiguration;
- baseConfigurationReference = E6710FB66EE811C212116106 /* Pods-simplenotes.debug.xcconfig */;
+ baseConfigurationReference = E6710FB66EE811C212116106 /* Pods-OpenNotes.debug.xcconfig */;
buildSettings = {
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
CLANG_ENABLE_MODULES = YES;
- CODE_SIGN_ENTITLEMENTS = simplenotes/simplenotes.entitlements;
+ CODE_SIGN_ENTITLEMENTS = OpenNotes/OpenNotes.entitlements;
CODE_SIGN_IDENTITY = "Apple Development";
CODE_SIGN_STYLE = Automatic;
CURRENT_PROJECT_VERSION = 1;
@@ -361,7 +361,7 @@
"$(inherited)",
"FB_SONARKIT_ENABLED=1",
);
- INFOPLIST_FILE = simplenotes/Info.plist;
+ INFOPLIST_FILE = OpenNotes/Info.plist;
IPHONEOS_DEPLOYMENT_TARGET = 15.1;
LD_RUNPATH_SEARCH_PATHS = (
"$(inherited)",
@@ -374,9 +374,9 @@
"-lc++",
);
OTHER_SWIFT_FLAGS = "$(inherited) -D EXPO_CONFIGURATION_DEBUG";
- PRODUCT_BUNDLE_IDENTIFIER = com.simplenotes.app;
- PRODUCT_NAME = simplenotes;
- SWIFT_OBJC_BRIDGING_HEADER = "simplenotes/simplenotes-Bridging-Header.h";
+ PRODUCT_BUNDLE_IDENTIFIER = com.opennotes.app;
+ PRODUCT_NAME = OpenNotes;
+ SWIFT_OBJC_BRIDGING_HEADER = "OpenNotes/OpenNotes-Bridging-Header.h";
SWIFT_OPTIMIZATION_LEVEL = "-Onone";
SWIFT_VERSION = 5.0;
TARGETED_DEVICE_FAMILY = "1,2";
@@ -386,16 +386,16 @@
};
13B07F951A680F5B00A75B9A /* Release */ = {
isa = XCBuildConfiguration;
- baseConfigurationReference = CEB267F85878647A5ACA788A /* Pods-simplenotes.release.xcconfig */;
+ baseConfigurationReference = CEB267F85878647A5ACA788A /* Pods-OpenNotes.release.xcconfig */;
buildSettings = {
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
CLANG_ENABLE_MODULES = YES;
- CODE_SIGN_ENTITLEMENTS = simplenotes/simplenotes.entitlements;
+ CODE_SIGN_ENTITLEMENTS = OpenNotes/OpenNotes.entitlements;
CODE_SIGN_IDENTITY = "Apple Development";
CODE_SIGN_STYLE = Automatic;
CURRENT_PROJECT_VERSION = 1;
DEVELOPMENT_TEAM = U2CPXQV7AJ;
- INFOPLIST_FILE = simplenotes/Info.plist;
+ INFOPLIST_FILE = OpenNotes/Info.plist;
IPHONEOS_DEPLOYMENT_TARGET = 15.1;
LD_RUNPATH_SEARCH_PATHS = (
"$(inherited)",
@@ -408,9 +408,9 @@
"-lc++",
);
OTHER_SWIFT_FLAGS = "$(inherited) -D EXPO_CONFIGURATION_RELEASE";
- PRODUCT_BUNDLE_IDENTIFIER = com.simplenotes.app;
- PRODUCT_NAME = simplenotes;
- SWIFT_OBJC_BRIDGING_HEADER = "simplenotes/simplenotes-Bridging-Header.h";
+ PRODUCT_BUNDLE_IDENTIFIER = com.opennotes.app;
+ PRODUCT_NAME = OpenNotes;
+ SWIFT_OBJC_BRIDGING_HEADER = "OpenNotes/OpenNotes-Bridging-Header.h";
SWIFT_VERSION = 5.0;
TARGETED_DEVICE_FAMILY = "1,2";
VERSIONING_SYSTEM = "apple-generic";
@@ -538,7 +538,7 @@
/* End XCBuildConfiguration section */
/* Begin XCConfigurationList section */
- 13B07F931A680F5B00A75B9A /* Build configuration list for PBXNativeTarget "simplenotes" */ = {
+ 13B07F931A680F5B00A75B9A /* Build configuration list for PBXNativeTarget "OpenNotes" */ = {
isa = XCConfigurationList;
buildConfigurations = (
13B07F941A680F5B00A75B9A /* Debug */,
@@ -547,7 +547,7 @@
defaultConfigurationIsVisible = 0;
defaultConfigurationName = Release;
};
- 83CBB9FA1A601CBA00E9B192 /* Build configuration list for PBXProject "simplenotes" */ = {
+ 83CBB9FA1A601CBA00E9B192 /* Build configuration list for PBXProject "OpenNotes" */ = {
isa = XCConfigurationList;
buildConfigurations = (
83CBBA201A601CBA00E9B192 /* Debug */,
diff --git a/ios/simplenotes.xcodeproj/xcshareddata/xcschemes/simplenotes.xcscheme b/ios/OpenNotes.xcodeproj/xcshareddata/xcschemes/OpenNotes.xcscheme
similarity index 80%
rename from ios/simplenotes.xcodeproj/xcshareddata/xcschemes/simplenotes.xcscheme
rename to ios/OpenNotes.xcodeproj/xcshareddata/xcschemes/OpenNotes.xcscheme
index 7aaadc2..4abeace 100644
--- a/ios/simplenotes.xcodeproj/xcshareddata/xcschemes/simplenotes.xcscheme
+++ b/ios/OpenNotes.xcodeproj/xcshareddata/xcschemes/OpenNotes.xcscheme
@@ -15,9 +15,9 @@
+ BuildableName = "OpenNotes.app"
+ BlueprintName = "OpenNotes"
+ ReferencedContainer = "container:OpenNotes.xcodeproj">
@@ -33,9 +33,9 @@
+ BuildableName = "OpenNotesTests.xctest"
+ BlueprintName = "OpenNotesTests"
+ ReferencedContainer = "container:OpenNotes.xcodeproj">
@@ -55,9 +55,9 @@
+ BuildableName = "OpenNotes.app"
+ BlueprintName = "OpenNotes"
+ ReferencedContainer = "container:OpenNotes.xcodeproj">
@@ -72,9 +72,9 @@
+ BuildableName = "OpenNotes.app"
+ BlueprintName = "OpenNotes"
+ ReferencedContainer = "container:OpenNotes.xcodeproj">
diff --git a/ios/simplenotes.xcworkspace/contents.xcworkspacedata b/ios/OpenNotes.xcworkspace/contents.xcworkspacedata
similarity index 79%
rename from ios/simplenotes.xcworkspace/contents.xcworkspacedata
rename to ios/OpenNotes.xcworkspace/contents.xcworkspacedata
index e6fb771..e6531cf 100644
--- a/ios/simplenotes.xcworkspace/contents.xcworkspacedata
+++ b/ios/OpenNotes.xcworkspace/contents.xcworkspacedata
@@ -2,7 +2,7 @@
+ location = "group:OpenNotes.xcodeproj">
diff --git a/ios/simplenotes/AppDelegate.swift b/ios/OpenNotes/AppDelegate.swift
similarity index 100%
rename from ios/simplenotes/AppDelegate.swift
rename to ios/OpenNotes/AppDelegate.swift
diff --git a/ios/simplenotes/Images.xcassets/AppIcon.appiconset/App-Icon-1024x1024@1x.png b/ios/OpenNotes/Images.xcassets/AppIcon.appiconset/App-Icon-1024x1024@1x.png
similarity index 100%
rename from ios/simplenotes/Images.xcassets/AppIcon.appiconset/App-Icon-1024x1024@1x.png
rename to ios/OpenNotes/Images.xcassets/AppIcon.appiconset/App-Icon-1024x1024@1x.png
diff --git a/ios/simplenotes/Images.xcassets/AppIcon.appiconset/Contents.json b/ios/OpenNotes/Images.xcassets/AppIcon.appiconset/Contents.json
similarity index 100%
rename from ios/simplenotes/Images.xcassets/AppIcon.appiconset/Contents.json
rename to ios/OpenNotes/Images.xcassets/AppIcon.appiconset/Contents.json
diff --git a/ios/simplenotes/Images.xcassets/Contents.json b/ios/OpenNotes/Images.xcassets/Contents.json
similarity index 100%
rename from ios/simplenotes/Images.xcassets/Contents.json
rename to ios/OpenNotes/Images.xcassets/Contents.json
diff --git a/ios/simplenotes/Images.xcassets/SplashScreenBackground.colorset/Contents.json b/ios/OpenNotes/Images.xcassets/SplashScreenBackground.colorset/Contents.json
similarity index 100%
rename from ios/simplenotes/Images.xcassets/SplashScreenBackground.colorset/Contents.json
rename to ios/OpenNotes/Images.xcassets/SplashScreenBackground.colorset/Contents.json
diff --git a/ios/simplenotes/Info.plist b/ios/OpenNotes/Info.plist
similarity index 89%
rename from ios/simplenotes/Info.plist
rename to ios/OpenNotes/Info.plist
index e6dbd9f..77b8dfb 100644
--- a/ios/simplenotes/Info.plist
+++ b/ios/OpenNotes/Info.plist
@@ -7,7 +7,7 @@
CFBundleDevelopmentRegion
$(DEVELOPMENT_LANGUAGE)
CFBundleDisplayName
- simplenotes
+ OpenNotes
CFBundleDocumentTypes
@@ -42,14 +42,14 @@
CFBundleURLSchemes
- simplenotes
- com.simplenotes.app
+ opennotes
+ com.opennotes.app
CFBundleURLSchemes
- exp+simplenotes
+ exp+opennotes
@@ -69,11 +69,9 @@
NSCameraUsageDescription
- simplenotes accesses the camera to let you capture images into notes.
- NSMicrophoneUsageDescription
- Allow $(PRODUCT_NAME) to access your microphone
+ OpenNotes accesses the camera to let you capture images into notes.
NSPhotoLibraryUsageDescription
- simplenotes accesses your photos to let you insert them into notes.
+ OpenNotes accesses your photos to let you insert them into notes.
NSUserActivityTypes
$(PRODUCT_BUNDLE_IDENTIFIER).expo.index_route
diff --git a/ios/simplenotes/simplenotes-Bridging-Header.h b/ios/OpenNotes/OpenNotes-Bridging-Header.h
similarity index 100%
rename from ios/simplenotes/simplenotes-Bridging-Header.h
rename to ios/OpenNotes/OpenNotes-Bridging-Header.h
diff --git a/ios/simplenotes/simplenotes.entitlements b/ios/OpenNotes/OpenNotes.entitlements
similarity index 100%
rename from ios/simplenotes/simplenotes.entitlements
rename to ios/OpenNotes/OpenNotes.entitlements
diff --git a/ios/simplenotes/PDFUtilsModule.m b/ios/OpenNotes/PDFUtilsModule.m
similarity index 100%
rename from ios/simplenotes/PDFUtilsModule.m
rename to ios/OpenNotes/PDFUtilsModule.m
diff --git a/ios/simplenotes/PDFUtilsModule.swift b/ios/OpenNotes/PDFUtilsModule.swift
similarity index 100%
rename from ios/simplenotes/PDFUtilsModule.swift
rename to ios/OpenNotes/PDFUtilsModule.swift
diff --git a/ios/simplenotes/PrivacyInfo.xcprivacy b/ios/OpenNotes/PrivacyInfo.xcprivacy
similarity index 100%
rename from ios/simplenotes/PrivacyInfo.xcprivacy
rename to ios/OpenNotes/PrivacyInfo.xcprivacy
diff --git a/ios/simplenotes/SplashScreen.storyboard b/ios/OpenNotes/SplashScreen.storyboard
similarity index 100%
rename from ios/simplenotes/SplashScreen.storyboard
rename to ios/OpenNotes/SplashScreen.storyboard
diff --git a/ios/simplenotes/Supporting/Expo.plist b/ios/OpenNotes/Supporting/Expo.plist
similarity index 100%
rename from ios/simplenotes/Supporting/Expo.plist
rename to ios/OpenNotes/Supporting/Expo.plist
diff --git a/ios/Podfile b/ios/Podfile
index 661b924..fe01f90 100644
--- a/ios/Podfile
+++ b/ios/Podfile
@@ -20,7 +20,7 @@ platform :ios, podfile_properties['ios.deploymentTarget'] || '15.1'
prepare_react_native_project!
-target 'simplenotes' do
+target 'OpenNotes' do
use_expo_modules!
if ENV['EXPO_USE_COMMUNITY_AUTOLINKING'] == '1'
diff --git a/ios/Podfile.lock b/ios/Podfile.lock
index 944b3ae..49dcf32 100644
--- a/ios/Podfile.lock
+++ b/ios/Podfile.lock
@@ -2614,6 +2614,6 @@ SPEC CHECKSUMS:
RNWorklets: 76fce72926e28e304afb44f0da23b2d24f2c1fa0
Yoga: 5934998fbeaef7845dbf698f698518695ab4cd1a
-PODFILE CHECKSUM: 5a380f52556b3450b32390f45700b4b59e2fc7bb
+PODFILE CHECKSUM: 082bca60b719647a69d16b406d5f83b3106e6bbd
COCOAPODS: 1.16.2
diff --git a/package-lock.json b/package-lock.json
index 5d13c1c..e52cfb5 100644
--- a/package-lock.json
+++ b/package-lock.json
@@ -1,11 +1,11 @@
{
- "name": "simplenotes",
+ "name": "open-notes",
"version": "0.1.0",
"lockfileVersion": 3,
"requires": true,
"packages": {
"": {
- "name": "simplenotes",
+ "name": "open-notes",
"version": "0.1.0",
"license": "Apache-2.0",
"dependencies": {
diff --git a/package.json b/package.json
index 5dad032..03be57a 100644
--- a/package.json
+++ b/package.json
@@ -1,17 +1,17 @@
{
- "name": "simplenotes",
+ "name": "open-notes",
"version": "0.1.0",
"description": "A no-bloat, local-first, open-source notes app powered by Mobile Ink.",
"private": true,
"license": "Apache-2.0",
"repository": {
"type": "git",
- "url": "git+https://github.com/mathnotes-app/simplenotes.git"
+ "url": "git+https://github.com/mathnotes-app/OpenNotes.git"
},
"bugs": {
- "url": "https://github.com/mathnotes-app/simplenotes/issues"
+ "url": "https://github.com/mathnotes-app/OpenNotes/issues"
},
- "homepage": "https://github.com/mathnotes-app/simplenotes#readme",
+ "homepage": "https://github.com/mathnotes-app/OpenNotes#readme",
"main": "expo-router/entry",
"scripts": {
"start": "expo start",
diff --git a/src/hooks/useToolState.ts b/src/hooks/useToolState.ts
index 115fc15..6d02351 100644
--- a/src/hooks/useToolState.ts
+++ b/src/hooks/useToolState.ts
@@ -4,7 +4,8 @@ import type { ContinuousEnginePoolToolState } from '@mathnotes/mobile-ink';
import { DEFAULT_TOOL, TOOL_BY_TYPE, TOOL_DESCRIPTORS } from '../utils/toolPalette';
import type { SupportedTool } from '../utils/toolPalette';
-const KEY = '@simplenotes:toolStateV2';
+const KEY = '@opennotes:toolStateV2';
+const LEGACY_KEY = '@simple' + 'notes:toolStateV2';
export type ToolState = ContinuousEnginePoolToolState;
@@ -29,6 +30,15 @@ export function useToolState() {
useEffect(() => {
let mounted = true;
AsyncStorage.getItem(KEY)
+ .then((raw) => {
+ if (!raw) {
+ return AsyncStorage.getItem(LEGACY_KEY).then((legacyRaw) => {
+ if (legacyRaw) AsyncStorage.setItem(KEY, legacyRaw).catch(() => undefined);
+ return legacyRaw;
+ });
+ }
+ return raw;
+ })
.then((raw) => {
if (!mounted || !raw) {
hydratedRef.current = true;
diff --git a/src/services/foldersRepo.ts b/src/services/foldersRepo.ts
index fcac13f..9448d84 100644
--- a/src/services/foldersRepo.ts
+++ b/src/services/foldersRepo.ts
@@ -7,15 +7,26 @@ import {
listAllMetadata,
} from './notesRepo';
-const INDEX_KEY = '@simplenotes:folders:index';
-const FOLDER_PREFIX = '@simplenotes:folder:';
+const INDEX_KEY = '@opennotes:folders:index';
+const FOLDER_PREFIX = '@opennotes:folder:';
+const LEGACY_NAMESPACE = '@simple' + 'notes:';
+const LEGACY_INDEX_KEY = `${LEGACY_NAMESPACE}folders:index`;
+const LEGACY_FOLDER_PREFIX = `${LEGACY_NAMESPACE}folder:`;
function folderKey(id: string): string {
return `${FOLDER_PREFIX}${id}`;
}
+function legacyFolderKey(id: string): string {
+ return `${LEGACY_FOLDER_PREFIX}${id}`;
+}
+
async function readIndex(): Promise {
- const raw = await AsyncStorage.getItem(INDEX_KEY);
+ let raw = await AsyncStorage.getItem(INDEX_KEY);
+ if (!raw) {
+ raw = await AsyncStorage.getItem(LEGACY_INDEX_KEY);
+ if (raw) await AsyncStorage.setItem(INDEX_KEY, raw);
+ }
if (!raw) return [];
try {
const parsed = JSON.parse(raw);
@@ -47,7 +58,13 @@ export async function listFolders(): Promise {
if (ids.length === 0) return [];
const entries = await AsyncStorage.multiGet(ids.map(folderKey));
const out: FolderMetadata[] = [];
- for (const [, raw] of entries) {
+ for (let i = 0; i < entries.length; i += 1) {
+ const id = ids[i];
+ let raw = entries[i]?.[1] ?? null;
+ if (!raw) {
+ raw = await AsyncStorage.getItem(legacyFolderKey(id));
+ if (raw) await AsyncStorage.setItem(folderKey(id), raw);
+ }
if (!raw) continue;
try {
out.push(JSON.parse(raw) as FolderMetadata);
@@ -59,7 +76,11 @@ export async function listFolders(): Promise {
}
export async function getFolder(id: string): Promise {
- const raw = await AsyncStorage.getItem(folderKey(id));
+ let raw = await AsyncStorage.getItem(folderKey(id));
+ if (!raw) {
+ raw = await AsyncStorage.getItem(legacyFolderKey(id));
+ if (raw) await AsyncStorage.setItem(folderKey(id), raw);
+ }
if (!raw) return null;
try {
return JSON.parse(raw) as FolderMetadata;
@@ -104,6 +125,7 @@ export async function deleteFolder(id: string, mode: FolderDeleteMode): Promise<
}
await Promise.all([
AsyncStorage.removeItem(folderKey(id)),
+ AsyncStorage.removeItem(legacyFolderKey(id)),
removeFromIndex(id),
]);
}
diff --git a/src/services/notesRepo.ts b/src/services/notesRepo.ts
index 883b50e..3a99600 100644
--- a/src/services/notesRepo.ts
+++ b/src/services/notesRepo.ts
@@ -6,15 +6,26 @@ import { deleteBody, readBody, writeBody } from './noteBodyStorage';
import { deletePdfForNote } from './pdfStorage';
import { deleteImagesForNote } from './imageInsertStorage';
-const INDEX_KEY = '@simplenotes:notes:index';
-const NOTE_PREFIX = '@simplenotes:note:';
+const INDEX_KEY = '@opennotes:notes:index';
+const NOTE_PREFIX = '@opennotes:note:';
+const LEGACY_NAMESPACE = '@simple' + 'notes:';
+const LEGACY_INDEX_KEY = `${LEGACY_NAMESPACE}notes:index`;
+const LEGACY_NOTE_PREFIX = `${LEGACY_NAMESPACE}note:`;
function noteKey(id: string): string {
return `${NOTE_PREFIX}${id}`;
}
+function legacyNoteKey(id: string): string {
+ return `${LEGACY_NOTE_PREFIX}${id}`;
+}
+
async function readIndex(): Promise {
- const raw = await AsyncStorage.getItem(INDEX_KEY);
+ let raw = await AsyncStorage.getItem(INDEX_KEY);
+ if (!raw) {
+ raw = await AsyncStorage.getItem(LEGACY_INDEX_KEY);
+ if (raw) await AsyncStorage.setItem(INDEX_KEY, raw);
+ }
if (!raw) return [];
try {
const parsed = JSON.parse(raw);
@@ -46,7 +57,13 @@ export async function listAllMetadata(): Promise {
if (ids.length === 0) return [];
const entries = await AsyncStorage.multiGet(ids.map(noteKey));
const out: NoteMetadata[] = [];
- for (const [, raw] of entries) {
+ for (let i = 0; i < entries.length; i += 1) {
+ const id = ids[i];
+ let raw = entries[i]?.[1] ?? null;
+ if (!raw) {
+ raw = await AsyncStorage.getItem(legacyNoteKey(id));
+ if (raw) await AsyncStorage.setItem(noteKey(id), raw);
+ }
if (!raw) continue;
try {
out.push(JSON.parse(raw) as NoteMetadata);
@@ -63,7 +80,11 @@ export async function listNotes(folderId: string | null): Promise {
- const raw = await AsyncStorage.getItem(noteKey(id));
+ let raw = await AsyncStorage.getItem(noteKey(id));
+ if (!raw) {
+ raw = await AsyncStorage.getItem(legacyNoteKey(id));
+ if (raw) await AsyncStorage.setItem(noteKey(id), raw);
+ }
if (!raw) return null;
try {
return JSON.parse(raw) as NoteMetadata;
@@ -150,6 +171,7 @@ export async function deleteNote(id: string): Promise {
deletePdfForNote(id),
deleteImagesForNote(id),
AsyncStorage.removeItem(noteKey(id)),
+ AsyncStorage.removeItem(legacyNoteKey(id)),
removeFromIndex(id),
]);
}