@buoy-gg/storage 7.0.26 → 7.0.27
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/commonjs/storage/components/DiffViewer/DiffOptionsPanel.js +36 -36
- package/lib/commonjs/storage/components/DiffViewer/TreeDiffViewer.js +2 -2
- package/lib/commonjs/storage/components/DiffViewer/themes/diffThemes.js +19 -108
- package/lib/commonjs/storage/components/GameUIStorageBrowser.js +45 -42
- package/lib/commonjs/storage/components/MMKVInstanceInfoPanel.js +9 -9
- package/lib/commonjs/storage/components/MMKVInstanceSelector.js +24 -24
- package/lib/commonjs/storage/components/SelectionActionBar.js +13 -13
- package/lib/commonjs/storage/components/StorageActionButtons.js +12 -12
- package/lib/commonjs/storage/components/StorageEventActionButton.js +18 -18
- package/lib/commonjs/storage/components/StorageEventDetailContent.js +7 -7
- package/lib/commonjs/storage/components/StorageEventFilterView.js +9 -9
- package/lib/commonjs/storage/components/StorageFilterCards.js +15 -15
- package/lib/commonjs/storage/components/StorageKeyCard.js +21 -21
- package/lib/commonjs/storage/components/StorageKeyEditorScreen.js +19 -18
- package/lib/commonjs/storage/components/StorageKeyRow.js +23 -21
- package/lib/commonjs/storage/components/StorageKeySection.js +3 -3
- package/lib/commonjs/storage/components/StorageKeyStats.js +10 -10
- package/lib/commonjs/storage/components/StorageModalWithTabs.js +19 -14
- package/lib/commonjs/storage/components/StorageTypeFilterBar.js +8 -8
- package/lib/commonjs/storage/components/StorageValueEditModal.js +19 -19
- package/lib/module/storage/components/DiffViewer/DiffOptionsPanel.js +37 -37
- package/lib/module/storage/components/DiffViewer/TreeDiffViewer.js +3 -3
- package/lib/module/storage/components/DiffViewer/themes/diffThemes.js +6 -105
- package/lib/module/storage/components/GameUIStorageBrowser.js +46 -43
- package/lib/module/storage/components/MMKVInstanceInfoPanel.js +10 -10
- package/lib/module/storage/components/MMKVInstanceSelector.js +25 -25
- package/lib/module/storage/components/SelectionActionBar.js +14 -14
- package/lib/module/storage/components/StorageActionButtons.js +13 -13
- package/lib/module/storage/components/StorageEventActionButton.js +19 -19
- package/lib/module/storage/components/StorageEventDetailContent.js +8 -8
- package/lib/module/storage/components/StorageEventFilterView.js +10 -10
- package/lib/module/storage/components/StorageFilterCards.js +16 -16
- package/lib/module/storage/components/StorageKeyCard.js +22 -22
- package/lib/module/storage/components/StorageKeyEditorScreen.js +20 -19
- package/lib/module/storage/components/StorageKeyRow.js +24 -22
- package/lib/module/storage/components/StorageKeySection.js +4 -4
- package/lib/module/storage/components/StorageKeyStats.js +11 -11
- package/lib/module/storage/components/StorageModalWithTabs.js +20 -15
- package/lib/module/storage/components/StorageTypeFilterBar.js +9 -9
- package/lib/module/storage/components/StorageValueEditModal.js +20 -20
- package/lib/typescript/storage/components/DiffViewer/DiffOptionsPanel.d.ts.map +1 -1
- package/lib/typescript/storage/components/DiffViewer/themes/diffThemes.d.ts +6 -61
- package/lib/typescript/storage/components/DiffViewer/themes/diffThemes.d.ts.map +1 -1
- package/lib/typescript/storage/components/StorageEventActionButton.d.ts +8 -8
- package/lib/typescript/storage/components/StorageEventFilterView.d.ts.map +1 -1
- package/lib/typescript/storage/components/StorageKeyCard.d.ts.map +1 -1
- package/lib/typescript/storage/components/StorageKeyEditorScreen.d.ts.map +1 -1
- package/lib/typescript/storage/components/StorageModalWithTabs.d.ts.map +1 -1
- package/package.json +5 -5
|
@@ -22,7 +22,7 @@ import { onStorageBrowserRefresh } from "../utils/storageBrowserRefresh";
|
|
|
22
22
|
import { setStorageValue, storageEditBlockedReason } from "../utils/setStorageValue";
|
|
23
23
|
|
|
24
24
|
// Import shared Game UI components
|
|
25
|
-
import { gameUIColors, macOSColors,
|
|
25
|
+
import { gameUIColors, macOSColors, night, HardDrive } from "@buoy-gg/shared-ui";
|
|
26
26
|
import { useIsPro } from "@buoy-gg/license";
|
|
27
27
|
|
|
28
28
|
// MMKV Instance color palette - consistent colors per instance
|
|
@@ -576,7 +576,7 @@ export function GameUIStorageBrowser({
|
|
|
576
576
|
style: styles.emptyState,
|
|
577
577
|
children: [/*#__PURE__*/_jsx(Database, {
|
|
578
578
|
size: 48,
|
|
579
|
-
color:
|
|
579
|
+
color: night.color.textTertiary
|
|
580
580
|
}), /*#__PURE__*/_jsx(Text, {
|
|
581
581
|
style: styles.emptyTitle,
|
|
582
582
|
children: "Loading storage keys..."
|
|
@@ -645,7 +645,7 @@ export function GameUIStorageBrowser({
|
|
|
645
645
|
style: [styles.instanceNavbarButton, selectedMMKVInstance === null && styles.instanceNavbarButtonActive],
|
|
646
646
|
children: [/*#__PURE__*/_jsx(HardDrive, {
|
|
647
647
|
size: 12,
|
|
648
|
-
color: selectedMMKVInstance === null ?
|
|
648
|
+
color: selectedMMKVInstance === null ? night.color.text : night.color.textSecondary
|
|
649
649
|
}), /*#__PURE__*/_jsx(Text, {
|
|
650
650
|
style: [styles.instanceNavbarButtonText, selectedMMKVInstance === null && styles.instanceNavbarButtonTextActive],
|
|
651
651
|
children: "All"
|
|
@@ -667,13 +667,13 @@ export function GameUIStorageBrowser({
|
|
|
667
667
|
}
|
|
668
668
|
},
|
|
669
669
|
style: [styles.instanceNavbarButton, inst.id === selectedMMKVInstance && styles.instanceNavbarButtonActive, {
|
|
670
|
-
borderColor: isLocked ?
|
|
671
|
-
backgroundColor: inst.id === selectedMMKVInstance ? getInstanceColor(inst.id) + '20' :
|
|
670
|
+
borderColor: isLocked ? night.color.border : getInstanceColor(inst.id) + '40',
|
|
671
|
+
backgroundColor: inst.id === selectedMMKVInstance ? getInstanceColor(inst.id) + '20' : night.color.surfaceElevated,
|
|
672
672
|
opacity: isLocked ? 0.5 : 1
|
|
673
673
|
}],
|
|
674
674
|
children: [/*#__PURE__*/_jsx(HardDrive, {
|
|
675
675
|
size: 12,
|
|
676
|
-
color: inst.id === selectedMMKVInstance ? getInstanceColor(inst.id) :
|
|
676
|
+
color: inst.id === selectedMMKVInstance ? getInstanceColor(inst.id) : night.color.textSecondary
|
|
677
677
|
}), /*#__PURE__*/_jsx(Text, {
|
|
678
678
|
style: [styles.instanceNavbarButtonText, inst.id === selectedMMKVInstance && {
|
|
679
679
|
color: getInstanceColor(inst.id),
|
|
@@ -732,7 +732,7 @@ export function GameUIStorageBrowser({
|
|
|
732
732
|
style: styles.limitBannerLeft,
|
|
733
733
|
children: [/*#__PURE__*/_jsx(Zap, {
|
|
734
734
|
size: 16,
|
|
735
|
-
color:
|
|
735
|
+
color: night.color.accent
|
|
736
736
|
}), /*#__PURE__*/_jsx(Text, {
|
|
737
737
|
style: styles.limitBannerText,
|
|
738
738
|
children: searchQuery ? `${lockedKeyCount} matching ${lockedKeyCount === 1 ? 'key' : 'keys'} in locked storage` : `${lockedKeyCount} keys locked`
|
|
@@ -747,7 +747,7 @@ export function GameUIStorageBrowser({
|
|
|
747
747
|
style: styles.emptyState,
|
|
748
748
|
children: [/*#__PURE__*/_jsx(Database, {
|
|
749
749
|
size: 32,
|
|
750
|
-
color:
|
|
750
|
+
color: night.color.textTertiary
|
|
751
751
|
}), /*#__PURE__*/_jsx(Text, {
|
|
752
752
|
style: styles.emptyTitle,
|
|
753
753
|
children: searchQuery ? "No results found" : activeFilter === "all" ? "No valid keys found" : activeFilter === "missing" ? "No missing keys" : "No issues found"
|
|
@@ -849,11 +849,14 @@ const styles = StyleSheet.create({
|
|
|
849
849
|
},
|
|
850
850
|
scrollContainer: {
|
|
851
851
|
flex: 1,
|
|
852
|
-
|
|
852
|
+
// Transparent so JsModal's ToolBackground shows through (the modal paints opaque base beneath it).
|
|
853
|
+
backgroundColor: "transparent"
|
|
853
854
|
},
|
|
854
855
|
container: {
|
|
855
856
|
padding: 12,
|
|
856
|
-
|
|
857
|
+
// Generous so a key card expanded at the bottom of the list can scroll
|
|
858
|
+
// its full detail block above the modal edge.
|
|
859
|
+
paddingBottom: 120
|
|
857
860
|
},
|
|
858
861
|
backgroundGrid: {
|
|
859
862
|
...absoluteFill,
|
|
@@ -862,7 +865,7 @@ const styles = StyleSheet.create({
|
|
|
862
865
|
},
|
|
863
866
|
techFooter: {
|
|
864
867
|
fontSize: 8,
|
|
865
|
-
color:
|
|
868
|
+
color: night.color.textTertiary,
|
|
866
869
|
fontFamily: "monospace",
|
|
867
870
|
textAlign: "center",
|
|
868
871
|
marginTop: 20,
|
|
@@ -872,11 +875,11 @@ const styles = StyleSheet.create({
|
|
|
872
875
|
// Keys section
|
|
873
876
|
keysSection: {
|
|
874
877
|
marginTop: 8,
|
|
875
|
-
backgroundColor:
|
|
878
|
+
backgroundColor: night.color.bg,
|
|
876
879
|
borderRadius: 12,
|
|
877
880
|
padding: 12,
|
|
878
881
|
borderWidth: 1,
|
|
879
|
-
borderColor:
|
|
882
|
+
borderColor: night.color.border
|
|
880
883
|
},
|
|
881
884
|
sectionHeader: {
|
|
882
885
|
flexDirection: "row",
|
|
@@ -885,7 +888,7 @@ const styles = StyleSheet.create({
|
|
|
885
888
|
marginBottom: 10,
|
|
886
889
|
paddingBottom: 6,
|
|
887
890
|
borderBottomWidth: 1,
|
|
888
|
-
borderBottomColor:
|
|
891
|
+
borderBottomColor: night.color.separator
|
|
889
892
|
},
|
|
890
893
|
sectionHeaderLeft: {
|
|
891
894
|
flexDirection: "row",
|
|
@@ -895,22 +898,22 @@ const styles = StyleSheet.create({
|
|
|
895
898
|
sectionTitle: {
|
|
896
899
|
fontSize: 12,
|
|
897
900
|
fontWeight: "600",
|
|
898
|
-
color:
|
|
901
|
+
color: night.color.textSecondary,
|
|
899
902
|
letterSpacing: 0.4,
|
|
900
903
|
textTransform: "uppercase"
|
|
901
904
|
},
|
|
902
905
|
countBadge: {
|
|
903
|
-
backgroundColor:
|
|
906
|
+
backgroundColor: night.color.surfaceElevated,
|
|
904
907
|
paddingHorizontal: 8,
|
|
905
908
|
paddingVertical: 3,
|
|
906
909
|
borderRadius: 6,
|
|
907
910
|
borderWidth: 1,
|
|
908
|
-
borderColor:
|
|
911
|
+
borderColor: night.color.border
|
|
909
912
|
},
|
|
910
913
|
countText: {
|
|
911
914
|
fontSize: 11,
|
|
912
915
|
fontWeight: "600",
|
|
913
|
-
color:
|
|
916
|
+
color: night.color.text,
|
|
914
917
|
fontFamily: "monospace"
|
|
915
918
|
},
|
|
916
919
|
// Empty state
|
|
@@ -922,56 +925,56 @@ const styles = StyleSheet.create({
|
|
|
922
925
|
emptyTitle: {
|
|
923
926
|
fontSize: 16,
|
|
924
927
|
fontWeight: "600",
|
|
925
|
-
color:
|
|
928
|
+
color: night.color.text,
|
|
926
929
|
marginTop: 12,
|
|
927
930
|
marginBottom: 8
|
|
928
931
|
},
|
|
929
932
|
emptySubtitle: {
|
|
930
933
|
fontSize: 13,
|
|
931
|
-
color:
|
|
934
|
+
color: night.color.textSecondary,
|
|
932
935
|
textAlign: "center"
|
|
933
936
|
},
|
|
934
937
|
// Empty MMKV state
|
|
935
938
|
emptyMMKVState: {
|
|
936
|
-
backgroundColor:
|
|
939
|
+
backgroundColor: night.color.surface,
|
|
937
940
|
borderRadius: 12,
|
|
938
941
|
padding: 20,
|
|
939
942
|
borderWidth: 1,
|
|
940
|
-
borderColor:
|
|
943
|
+
borderColor: night.color.border,
|
|
941
944
|
marginTop: 8,
|
|
942
945
|
alignItems: "center"
|
|
943
946
|
},
|
|
944
947
|
emptyMMKVTitle: {
|
|
945
948
|
fontSize: 14,
|
|
946
949
|
fontWeight: "600",
|
|
947
|
-
color:
|
|
950
|
+
color: night.color.text,
|
|
948
951
|
marginBottom: 6
|
|
949
952
|
},
|
|
950
953
|
emptyMMKVSubtitle: {
|
|
951
954
|
fontSize: 12,
|
|
952
|
-
color:
|
|
955
|
+
color: night.color.textSecondary,
|
|
953
956
|
textAlign: "center",
|
|
954
957
|
marginBottom: 12
|
|
955
958
|
},
|
|
956
959
|
emptyMMKVCode: {
|
|
957
960
|
fontSize: 10,
|
|
958
961
|
fontFamily: "monospace",
|
|
959
|
-
color:
|
|
960
|
-
backgroundColor:
|
|
962
|
+
color: night.color.accent,
|
|
963
|
+
backgroundColor: night.color.bg,
|
|
961
964
|
padding: 12,
|
|
962
965
|
borderRadius: 8,
|
|
963
966
|
borderWidth: 1,
|
|
964
|
-
borderColor:
|
|
967
|
+
borderColor: night.color.border,
|
|
965
968
|
alignSelf: "stretch"
|
|
966
969
|
},
|
|
967
970
|
// Instance Navbar styles
|
|
968
971
|
instanceNavbar: {
|
|
969
972
|
marginTop: 12,
|
|
970
973
|
marginBottom: 8,
|
|
971
|
-
backgroundColor:
|
|
974
|
+
backgroundColor: night.color.surface,
|
|
972
975
|
borderRadius: 10,
|
|
973
976
|
borderWidth: 1,
|
|
974
|
-
borderColor:
|
|
977
|
+
borderColor: night.color.border,
|
|
975
978
|
padding: 10,
|
|
976
979
|
shadowColor: '#000',
|
|
977
980
|
shadowOpacity: 0.08,
|
|
@@ -991,7 +994,7 @@ const styles = StyleSheet.create({
|
|
|
991
994
|
instanceNavbarLabel: {
|
|
992
995
|
fontSize: 9,
|
|
993
996
|
fontWeight: '700',
|
|
994
|
-
color:
|
|
997
|
+
color: night.color.textTertiary,
|
|
995
998
|
textTransform: "uppercase",
|
|
996
999
|
letterSpacing: 1
|
|
997
1000
|
},
|
|
@@ -1005,10 +1008,10 @@ const styles = StyleSheet.create({
|
|
|
1005
1008
|
gap: 6,
|
|
1006
1009
|
paddingHorizontal: 12,
|
|
1007
1010
|
paddingVertical: 8,
|
|
1008
|
-
backgroundColor:
|
|
1011
|
+
backgroundColor: night.color.surfaceElevated,
|
|
1009
1012
|
borderRadius: 8,
|
|
1010
1013
|
borderWidth: 1,
|
|
1011
|
-
borderColor:
|
|
1014
|
+
borderColor: night.color.border,
|
|
1012
1015
|
minWidth: 90
|
|
1013
1016
|
},
|
|
1014
1017
|
instanceNavbarButtonActive: {
|
|
@@ -1024,16 +1027,16 @@ const styles = StyleSheet.create({
|
|
|
1024
1027
|
instanceNavbarButtonText: {
|
|
1025
1028
|
fontSize: 11,
|
|
1026
1029
|
fontWeight: '600',
|
|
1027
|
-
color:
|
|
1030
|
+
color: night.color.textSecondary,
|
|
1028
1031
|
fontFamily: 'monospace',
|
|
1029
1032
|
flex: 1
|
|
1030
1033
|
},
|
|
1031
1034
|
instanceNavbarButtonTextActive: {
|
|
1032
1035
|
fontWeight: '700',
|
|
1033
|
-
color:
|
|
1036
|
+
color: night.color.text
|
|
1034
1037
|
},
|
|
1035
1038
|
instanceNavbarBadge: {
|
|
1036
|
-
backgroundColor:
|
|
1039
|
+
backgroundColor: night.color.bg,
|
|
1037
1040
|
paddingHorizontal: 6,
|
|
1038
1041
|
paddingVertical: 2,
|
|
1039
1042
|
borderRadius: 6,
|
|
@@ -1043,29 +1046,29 @@ const styles = StyleSheet.create({
|
|
|
1043
1046
|
instanceNavbarBadgeText: {
|
|
1044
1047
|
fontSize: 10,
|
|
1045
1048
|
fontWeight: '700',
|
|
1046
|
-
color:
|
|
1049
|
+
color: night.color.textSecondary,
|
|
1047
1050
|
fontFamily: 'monospace'
|
|
1048
1051
|
},
|
|
1049
1052
|
clearSearchButton: {
|
|
1050
1053
|
marginTop: 16,
|
|
1051
1054
|
paddingHorizontal: 16,
|
|
1052
1055
|
paddingVertical: 8,
|
|
1053
|
-
backgroundColor:
|
|
1056
|
+
backgroundColor: night.color.surfaceElevated,
|
|
1054
1057
|
borderRadius: 6,
|
|
1055
1058
|
borderWidth: 1,
|
|
1056
|
-
borderColor:
|
|
1059
|
+
borderColor: night.color.border
|
|
1057
1060
|
},
|
|
1058
1061
|
clearSearchText: {
|
|
1059
1062
|
fontSize: 13,
|
|
1060
|
-
color:
|
|
1063
|
+
color: night.color.text,
|
|
1061
1064
|
fontWeight: "500"
|
|
1062
1065
|
},
|
|
1063
1066
|
// Free tier limit banner
|
|
1064
1067
|
limitBanner: {
|
|
1065
|
-
backgroundColor:
|
|
1068
|
+
backgroundColor: night.color.surface,
|
|
1066
1069
|
borderRadius: 10,
|
|
1067
1070
|
borderWidth: 1,
|
|
1068
|
-
borderColor:
|
|
1071
|
+
borderColor: night.color.accentBorderStrong,
|
|
1069
1072
|
padding: 12,
|
|
1070
1073
|
marginTop: 12
|
|
1071
1074
|
},
|
|
@@ -1081,12 +1084,12 @@ const styles = StyleSheet.create({
|
|
|
1081
1084
|
gap: 8
|
|
1082
1085
|
},
|
|
1083
1086
|
limitBannerText: {
|
|
1084
|
-
color:
|
|
1087
|
+
color: night.color.text,
|
|
1085
1088
|
fontSize: 13,
|
|
1086
1089
|
fontWeight: "600"
|
|
1087
1090
|
},
|
|
1088
1091
|
limitBannerSubtext: {
|
|
1089
|
-
color:
|
|
1092
|
+
color: night.color.textTertiary,
|
|
1090
1093
|
fontSize: 11
|
|
1091
1094
|
}
|
|
1092
1095
|
});
|
|
@@ -14,7 +14,7 @@
|
|
|
14
14
|
*/
|
|
15
15
|
|
|
16
16
|
import { View, Text, StyleSheet } from 'react-native';
|
|
17
|
-
import { macOSColors } from '@buoy-gg/shared-ui';
|
|
17
|
+
import { macOSColors, night } from '@buoy-gg/shared-ui';
|
|
18
18
|
import { useMMKVInstance } from '../hooks/useMMKVInstances';
|
|
19
19
|
import { jsxs as _jsxs, jsx as _jsx } from "react/jsx-runtime";
|
|
20
20
|
/**
|
|
@@ -80,11 +80,11 @@ export function MMKVInstanceInfoPanel({
|
|
|
80
80
|
}), /*#__PURE__*/_jsx(InfoItem, {
|
|
81
81
|
label: "Encryption",
|
|
82
82
|
value: instance.encrypted ? '🔒 Encrypted' : '🔓 Not encrypted',
|
|
83
|
-
valueColor: instance.encrypted ? macOSColors.semantic.success :
|
|
83
|
+
valueColor: instance.encrypted ? macOSColors.semantic.success : night.color.textTertiary
|
|
84
84
|
}), /*#__PURE__*/_jsx(InfoItem, {
|
|
85
85
|
label: "Access",
|
|
86
86
|
value: instance.readOnly ? '👁️ Read-only' : '✏️ Read-write',
|
|
87
|
-
valueColor: instance.readOnly ? macOSColors.semantic.warning :
|
|
87
|
+
valueColor: instance.readOnly ? macOSColors.semantic.warning : night.color.textTertiary
|
|
88
88
|
}), instance.size !== undefined && /*#__PURE__*/_jsx(InfoItem, {
|
|
89
89
|
label: "Size",
|
|
90
90
|
value: formatBytes(instance.size),
|
|
@@ -166,10 +166,10 @@ const styles = StyleSheet.create({
|
|
|
166
166
|
},
|
|
167
167
|
// Panel
|
|
168
168
|
panel: {
|
|
169
|
-
backgroundColor:
|
|
169
|
+
backgroundColor: night.color.surface,
|
|
170
170
|
borderRadius: 12,
|
|
171
171
|
borderWidth: 1,
|
|
172
|
-
borderColor:
|
|
172
|
+
borderColor: night.color.border,
|
|
173
173
|
overflow: 'hidden',
|
|
174
174
|
shadowColor: '#000000',
|
|
175
175
|
shadowOpacity: 0.03,
|
|
@@ -183,12 +183,12 @@ const styles = StyleSheet.create({
|
|
|
183
183
|
header: {
|
|
184
184
|
padding: 12,
|
|
185
185
|
borderBottomWidth: 1,
|
|
186
|
-
borderBottomColor:
|
|
186
|
+
borderBottomColor: night.color.separator
|
|
187
187
|
},
|
|
188
188
|
headerTitle: {
|
|
189
189
|
fontSize: 11,
|
|
190
190
|
fontWeight: '600',
|
|
191
|
-
color:
|
|
191
|
+
color: night.color.text,
|
|
192
192
|
textTransform: "uppercase",
|
|
193
193
|
letterSpacing: 0.5
|
|
194
194
|
},
|
|
@@ -205,18 +205,18 @@ const styles = StyleSheet.create({
|
|
|
205
205
|
},
|
|
206
206
|
infoLabel: {
|
|
207
207
|
fontSize: 12,
|
|
208
|
-
color:
|
|
208
|
+
color: night.color.textTertiary,
|
|
209
209
|
fontWeight: '500'
|
|
210
210
|
},
|
|
211
211
|
infoValue: {
|
|
212
212
|
fontSize: 12,
|
|
213
|
-
color:
|
|
213
|
+
color: night.color.text,
|
|
214
214
|
fontWeight: '500'
|
|
215
215
|
},
|
|
216
216
|
infoValueHighlight: {
|
|
217
217
|
fontSize: 14,
|
|
218
218
|
fontWeight: '600',
|
|
219
|
-
color:
|
|
219
|
+
color: night.color.accent
|
|
220
220
|
},
|
|
221
221
|
monoValue: {
|
|
222
222
|
fontFamily: 'monospace'
|
|
@@ -11,7 +11,7 @@
|
|
|
11
11
|
|
|
12
12
|
import { useState } from 'react';
|
|
13
13
|
import { View, Text, StyleSheet, TouchableOpacity, ScrollView, Modal } from 'react-native';
|
|
14
|
-
import { macOSColors } from '@buoy-gg/shared-ui';
|
|
14
|
+
import { macOSColors, night } from '@buoy-gg/shared-ui';
|
|
15
15
|
import { useMMKVInstances } from '../hooks/useMMKVInstances';
|
|
16
16
|
import { isMMKVAvailable, getMMKVUnavailableMessage } from '../utils/mmkvAvailability';
|
|
17
17
|
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
@@ -224,28 +224,28 @@ const styles = StyleSheet.create({
|
|
|
224
224
|
},
|
|
225
225
|
unavailableDescription: {
|
|
226
226
|
fontSize: 12,
|
|
227
|
-
color:
|
|
227
|
+
color: night.color.textSecondary,
|
|
228
228
|
textAlign: 'center',
|
|
229
229
|
lineHeight: 18
|
|
230
230
|
},
|
|
231
231
|
// Empty state
|
|
232
232
|
emptyState: {
|
|
233
|
-
backgroundColor:
|
|
233
|
+
backgroundColor: night.color.surface,
|
|
234
234
|
borderRadius: 12,
|
|
235
235
|
padding: 20,
|
|
236
236
|
borderWidth: 1,
|
|
237
|
-
borderColor:
|
|
237
|
+
borderColor: night.color.border,
|
|
238
238
|
alignItems: 'center',
|
|
239
239
|
gap: 12
|
|
240
240
|
},
|
|
241
241
|
emptyStateTitle: {
|
|
242
242
|
fontSize: 14,
|
|
243
243
|
fontWeight: '600',
|
|
244
|
-
color:
|
|
244
|
+
color: night.color.text
|
|
245
245
|
},
|
|
246
246
|
emptyStateDescription: {
|
|
247
247
|
fontSize: 12,
|
|
248
|
-
color:
|
|
248
|
+
color: night.color.textTertiary,
|
|
249
249
|
textAlign: 'center',
|
|
250
250
|
lineHeight: 18
|
|
251
251
|
},
|
|
@@ -253,22 +253,22 @@ const styles = StyleSheet.create({
|
|
|
253
253
|
marginTop: 8,
|
|
254
254
|
paddingHorizontal: 16,
|
|
255
255
|
paddingVertical: 8,
|
|
256
|
-
backgroundColor:
|
|
256
|
+
backgroundColor: night.color.accentSoft,
|
|
257
257
|
borderRadius: 8,
|
|
258
258
|
borderWidth: 1,
|
|
259
|
-
borderColor:
|
|
259
|
+
borderColor: night.color.accentBorderStrong
|
|
260
260
|
},
|
|
261
261
|
refreshButtonText: {
|
|
262
262
|
fontSize: 12,
|
|
263
263
|
fontWeight: '600',
|
|
264
|
-
color:
|
|
264
|
+
color: night.color.accent
|
|
265
265
|
},
|
|
266
266
|
// Selector button
|
|
267
267
|
selectorButton: {
|
|
268
|
-
backgroundColor:
|
|
268
|
+
backgroundColor: night.color.surface,
|
|
269
269
|
borderRadius: 12,
|
|
270
270
|
borderWidth: 1,
|
|
271
|
-
borderColor:
|
|
271
|
+
borderColor: night.color.border,
|
|
272
272
|
padding: 12,
|
|
273
273
|
flexDirection: 'row',
|
|
274
274
|
alignItems: 'center',
|
|
@@ -286,12 +286,12 @@ const styles = StyleSheet.create({
|
|
|
286
286
|
},
|
|
287
287
|
placeholderText: {
|
|
288
288
|
fontSize: 13,
|
|
289
|
-
color:
|
|
289
|
+
color: night.color.placeholder,
|
|
290
290
|
fontStyle: 'italic'
|
|
291
291
|
},
|
|
292
292
|
dropdownArrow: {
|
|
293
293
|
fontSize: 10,
|
|
294
|
-
color:
|
|
294
|
+
color: night.color.textTertiary,
|
|
295
295
|
marginLeft: 8
|
|
296
296
|
},
|
|
297
297
|
// Modal overlay
|
|
@@ -304,10 +304,10 @@ const styles = StyleSheet.create({
|
|
|
304
304
|
},
|
|
305
305
|
// Dropdown container
|
|
306
306
|
dropdownContainer: {
|
|
307
|
-
backgroundColor:
|
|
307
|
+
backgroundColor: night.color.surface,
|
|
308
308
|
borderRadius: 16,
|
|
309
309
|
borderWidth: 1,
|
|
310
|
-
borderColor:
|
|
310
|
+
borderColor: night.color.border,
|
|
311
311
|
width: '100%',
|
|
312
312
|
maxWidth: 500,
|
|
313
313
|
maxHeight: '70%',
|
|
@@ -326,19 +326,19 @@ const styles = StyleSheet.create({
|
|
|
326
326
|
justifyContent: 'space-between',
|
|
327
327
|
padding: 16,
|
|
328
328
|
borderBottomWidth: 1,
|
|
329
|
-
borderBottomColor:
|
|
329
|
+
borderBottomColor: night.color.separator
|
|
330
330
|
},
|
|
331
331
|
dropdownTitle: {
|
|
332
332
|
fontSize: 14,
|
|
333
333
|
fontWeight: '600',
|
|
334
|
-
color:
|
|
334
|
+
color: night.color.text
|
|
335
335
|
},
|
|
336
336
|
headerRefreshButton: {
|
|
337
337
|
padding: 4
|
|
338
338
|
},
|
|
339
339
|
headerRefreshText: {
|
|
340
340
|
fontSize: 18,
|
|
341
|
-
color:
|
|
341
|
+
color: night.color.accent
|
|
342
342
|
},
|
|
343
343
|
dropdownList: {
|
|
344
344
|
maxHeight: 400
|
|
@@ -346,10 +346,10 @@ const styles = StyleSheet.create({
|
|
|
346
346
|
dropdownItem: {
|
|
347
347
|
padding: 12,
|
|
348
348
|
borderBottomWidth: 1,
|
|
349
|
-
borderBottomColor:
|
|
349
|
+
borderBottomColor: night.color.separator
|
|
350
350
|
},
|
|
351
351
|
dropdownItemSelected: {
|
|
352
|
-
backgroundColor:
|
|
352
|
+
backgroundColor: night.color.accentSoft
|
|
353
353
|
},
|
|
354
354
|
// Instance row
|
|
355
355
|
instanceRow: {
|
|
@@ -365,12 +365,12 @@ const styles = StyleSheet.create({
|
|
|
365
365
|
instanceId: {
|
|
366
366
|
fontSize: 13,
|
|
367
367
|
fontWeight: '500',
|
|
368
|
-
color:
|
|
368
|
+
color: night.color.text,
|
|
369
369
|
fontFamily: 'monospace'
|
|
370
370
|
},
|
|
371
371
|
instanceIdSelected: {
|
|
372
372
|
fontWeight: '600',
|
|
373
|
-
color:
|
|
373
|
+
color: night.color.accent
|
|
374
374
|
},
|
|
375
375
|
instanceBadges: {
|
|
376
376
|
flexDirection: 'row',
|
|
@@ -394,7 +394,7 @@ const styles = StyleSheet.create({
|
|
|
394
394
|
badgeText: {
|
|
395
395
|
fontSize: 9,
|
|
396
396
|
fontWeight: '500',
|
|
397
|
-
color:
|
|
397
|
+
color: night.color.textSecondary
|
|
398
398
|
},
|
|
399
399
|
instanceRight: {
|
|
400
400
|
alignItems: 'flex-end'
|
|
@@ -402,12 +402,12 @@ const styles = StyleSheet.create({
|
|
|
402
402
|
keyCount: {
|
|
403
403
|
fontSize: 16,
|
|
404
404
|
fontWeight: '600',
|
|
405
|
-
color:
|
|
405
|
+
color: night.color.text,
|
|
406
406
|
fontFamily: 'monospace'
|
|
407
407
|
},
|
|
408
408
|
keyCountLabel: {
|
|
409
409
|
fontSize: 9,
|
|
410
|
-
color:
|
|
410
|
+
color: night.color.textTertiary,
|
|
411
411
|
textTransform: "uppercase",
|
|
412
412
|
letterSpacing: 0.5
|
|
413
413
|
}
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
import { useState, useEffect } from "react";
|
|
4
4
|
import { View, Text, StyleSheet, TouchableOpacity, Alert } from "react-native";
|
|
5
5
|
import { Trash2, CopyButton, CheckSquare, EyeOff, ProUpgradeModal } from "@buoy-gg/shared-ui";
|
|
6
|
-
import { macOSColors } from "@buoy-gg/shared-ui";
|
|
6
|
+
import { macOSColors, night } from "@buoy-gg/shared-ui";
|
|
7
7
|
import { useIsPro } from "@buoy-gg/license";
|
|
8
8
|
import { deleteStorageKeys } from "../utils/deleteStorageKeys";
|
|
9
9
|
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
@@ -85,7 +85,7 @@ export function SelectionActionBar({
|
|
|
85
85
|
onPress: allSelected ? onClearSelection : onSelectAll,
|
|
86
86
|
children: [/*#__PURE__*/_jsx(CheckSquare, {
|
|
87
87
|
size: 14,
|
|
88
|
-
color: allSelected ?
|
|
88
|
+
color: allSelected ? night.color.accent : night.color.textSecondary
|
|
89
89
|
}), /*#__PURE__*/_jsx(Text, {
|
|
90
90
|
style: styles.selectAllText,
|
|
91
91
|
children: allSelected ? "Deselect All" : "Select All"
|
|
@@ -104,7 +104,7 @@ export function SelectionActionBar({
|
|
|
104
104
|
size: 14,
|
|
105
105
|
buttonStyle: styles.actionButton,
|
|
106
106
|
colors: {
|
|
107
|
-
idle:
|
|
107
|
+
idle: night.color.accent,
|
|
108
108
|
success: macOSColors.semantic.success,
|
|
109
109
|
error: macOSColors.semantic.error
|
|
110
110
|
}
|
|
@@ -113,14 +113,14 @@ export function SelectionActionBar({
|
|
|
113
113
|
onPress: handleHideSelected,
|
|
114
114
|
children: /*#__PURE__*/_jsx(EyeOff, {
|
|
115
115
|
size: 14,
|
|
116
|
-
color:
|
|
116
|
+
color: night.color.warning
|
|
117
117
|
})
|
|
118
118
|
}), /*#__PURE__*/_jsx(TouchableOpacity, {
|
|
119
119
|
style: styles.actionButton,
|
|
120
120
|
onPress: handleDeleteSelected,
|
|
121
121
|
children: /*#__PURE__*/_jsx(Trash2, {
|
|
122
122
|
size: 14,
|
|
123
|
-
color:
|
|
123
|
+
color: night.color.danger
|
|
124
124
|
})
|
|
125
125
|
})]
|
|
126
126
|
}), /*#__PURE__*/_jsx(ProUpgradeModal, {
|
|
@@ -135,10 +135,10 @@ const styles = StyleSheet.create({
|
|
|
135
135
|
flexDirection: "row",
|
|
136
136
|
alignItems: "center",
|
|
137
137
|
justifyContent: "space-between",
|
|
138
|
-
backgroundColor:
|
|
138
|
+
backgroundColor: night.color.accentSoft,
|
|
139
139
|
borderRadius: 8,
|
|
140
140
|
borderWidth: 1,
|
|
141
|
-
borderColor:
|
|
141
|
+
borderColor: night.color.accentBorderStrong,
|
|
142
142
|
paddingHorizontal: 12,
|
|
143
143
|
paddingVertical: 8,
|
|
144
144
|
marginBottom: 10
|
|
@@ -154,18 +154,18 @@ const styles = StyleSheet.create({
|
|
|
154
154
|
gap: 6,
|
|
155
155
|
paddingVertical: 4,
|
|
156
156
|
paddingHorizontal: 8,
|
|
157
|
-
backgroundColor:
|
|
157
|
+
backgroundColor: night.color.surface,
|
|
158
158
|
borderRadius: 6,
|
|
159
159
|
borderWidth: 1,
|
|
160
|
-
borderColor:
|
|
160
|
+
borderColor: night.color.border
|
|
161
161
|
},
|
|
162
162
|
selectAllText: {
|
|
163
163
|
fontSize: 11,
|
|
164
164
|
fontWeight: "600",
|
|
165
|
-
color:
|
|
165
|
+
color: night.color.textSecondary
|
|
166
166
|
},
|
|
167
167
|
countBadge: {
|
|
168
|
-
backgroundColor:
|
|
168
|
+
backgroundColor: night.color.accentFill,
|
|
169
169
|
paddingHorizontal: 8,
|
|
170
170
|
paddingVertical: 4,
|
|
171
171
|
borderRadius: 6
|
|
@@ -173,7 +173,7 @@ const styles = StyleSheet.create({
|
|
|
173
173
|
countText: {
|
|
174
174
|
fontSize: 11,
|
|
175
175
|
fontWeight: "700",
|
|
176
|
-
color:
|
|
176
|
+
color: night.color.accent,
|
|
177
177
|
fontFamily: "monospace"
|
|
178
178
|
},
|
|
179
179
|
actionsSection: {
|
|
@@ -187,8 +187,8 @@ const styles = StyleSheet.create({
|
|
|
187
187
|
alignItems: "center",
|
|
188
188
|
justifyContent: "center",
|
|
189
189
|
borderRadius: 6,
|
|
190
|
-
backgroundColor:
|
|
190
|
+
backgroundColor: night.color.surface,
|
|
191
191
|
borderWidth: 1,
|
|
192
|
-
borderColor:
|
|
192
|
+
borderColor: night.color.border
|
|
193
193
|
}
|
|
194
194
|
});
|