notesoup 0.55.1 → 0.55.2
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/package.json
CHANGED
|
@@ -50,7 +50,7 @@ export function NotesOpCard({ item, layout, theme }: PluginTimelineItemProps<Not
|
|
|
50
50
|
disabled={!hasBody}
|
|
51
51
|
style={({ pressed }) => ({ gap: 4, opacity: pressed && hasBody ? 0.7 : 1 })}
|
|
52
52
|
>
|
|
53
|
-
<View style={{ flexDirection: "row", alignItems: "center", gap: 8 }}>
|
|
53
|
+
<View style={{ flexDirection: "row", alignItems: "center", gap: 8, paddingRight: 10 }}>
|
|
54
54
|
<Text style={{ color: paper.inkMuted, fontSize: 11.5 }}>
|
|
55
55
|
{data.crumpled ? "crumpled" : title}{data.status === "running" ? " …" : ""}
|
|
56
56
|
</Text>
|
|
@@ -4,12 +4,12 @@ import type { PaperPalette } from "./paper-palette.ts";
|
|
|
4
4
|
|
|
5
5
|
export const MONO = Platform.select({ ios: "Menlo", android: "monospace", default: "ui-monospace, Menlo, monospace" });
|
|
6
6
|
|
|
7
|
-
function
|
|
7
|
+
function Crease({ paper }: { paper: PaperPalette }) {
|
|
8
8
|
return (
|
|
9
9
|
<View style={{
|
|
10
|
-
|
|
11
|
-
backgroundColor: paper.
|
|
12
|
-
|
|
10
|
+
position: "absolute", top: 0, right: 0, width: 14, height: 14,
|
|
11
|
+
backgroundColor: paper.crease, borderBottomLeftRadius: 3,
|
|
12
|
+
borderLeftWidth: StyleSheet.hairlineWidth, borderBottomWidth: StyleSheet.hairlineWidth, borderColor: paper.edge,
|
|
13
13
|
}} />
|
|
14
14
|
);
|
|
15
15
|
}
|
|
@@ -21,20 +21,20 @@ export function PaperCard({ paper, compact, crumpled = false, children }: {
|
|
|
21
21
|
children: ReactNode;
|
|
22
22
|
}) {
|
|
23
23
|
return (
|
|
24
|
-
<View style={{
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
24
|
+
<View style={{
|
|
25
|
+
paddingVertical: compact ? 8 : 9,
|
|
26
|
+
paddingHorizontal: 12,
|
|
27
|
+
gap: 6,
|
|
28
|
+
minWidth: 0,
|
|
29
|
+
borderRadius: 4,
|
|
30
|
+
borderWidth: StyleSheet.hairlineWidth,
|
|
31
|
+
borderColor: paper.edge,
|
|
32
|
+
backgroundColor: crumpled ? paper.crumpled : paper.background,
|
|
33
|
+
position: "relative",
|
|
34
|
+
overflow: "hidden",
|
|
35
|
+
}}>
|
|
36
|
+
<Crease paper={paper} />
|
|
37
|
+
{children}
|
|
38
38
|
</View>
|
|
39
39
|
);
|
|
40
40
|
}
|
|
@@ -1,29 +1,27 @@
|
|
|
1
1
|
import type { PluginTheme } from "@getpaseo/plugin";
|
|
2
2
|
|
|
3
3
|
const LIGHT_PAPER = {
|
|
4
|
-
background: "#
|
|
5
|
-
edge: "#
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
crumpled: "#f1ead8",
|
|
4
|
+
background: "#faf7f0",
|
|
5
|
+
edge: "#e2d9c8",
|
|
6
|
+
crease: "#ede5d5",
|
|
7
|
+
ink: "#26221b",
|
|
8
|
+
inkMuted: "#827866",
|
|
9
|
+
added: "#2b6e3c",
|
|
10
|
+
removed: "#ad3e34",
|
|
11
|
+
crumpled: "#efeae0",
|
|
13
12
|
};
|
|
14
13
|
|
|
15
14
|
export type PaperPalette = typeof LIGHT_PAPER;
|
|
16
15
|
|
|
17
16
|
const DARK_PAPER: PaperPalette = {
|
|
18
|
-
background: "#
|
|
19
|
-
edge: "#
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
crumpled: "#1e1b16",
|
|
17
|
+
background: "#201d18",
|
|
18
|
+
edge: "#383228",
|
|
19
|
+
crease: "#2d2820",
|
|
20
|
+
ink: "#ede6da",
|
|
21
|
+
inkMuted: "#968c7a",
|
|
22
|
+
added: "#84c294",
|
|
23
|
+
removed: "#de877e",
|
|
24
|
+
crumpled: "#171511",
|
|
27
25
|
};
|
|
28
26
|
|
|
29
27
|
/** Paseo theme colors are hex (#RGB, #RRGGBB or #RRGGBBAA). */
|
|
@@ -30,8 +30,8 @@ test("paper follows the host theme and preserves the light palette when switchin
|
|
|
30
30
|
const light = theme("#ffffff", "#18181b");
|
|
31
31
|
const dark = theme("#18181b", "#fafafa");
|
|
32
32
|
const paper = paperPalette(light);
|
|
33
|
-
assert.equal(paper.background, "#
|
|
34
|
-
assert.equal(paper.ink, "#
|
|
33
|
+
assert.equal(paper.background, "#faf7f0");
|
|
34
|
+
assert.equal(paper.ink, "#26221b");
|
|
35
35
|
assert.ok(luminance(paperPalette(dark).background) < 0.05);
|
|
36
36
|
assert.notDeepEqual(paperPalette(dark), paper);
|
|
37
37
|
assert.deepEqual(paperPalette(light), paper);
|
|
@@ -41,7 +41,7 @@ test("host hex shorthand and alpha colors select the same dark paper", () => {
|
|
|
41
41
|
const paper = paperPalette(theme("#000000", "#ffffff"));
|
|
42
42
|
assert.deepEqual(paperPalette(theme("#000", "#fff")), paper);
|
|
43
43
|
assert.deepEqual(paperPalette(theme("#000000ff", "#ffffffff")), paper);
|
|
44
|
-
assert.equal(paperPalette(theme("#fff", "#000")).background, "#
|
|
44
|
+
assert.equal(paperPalette(theme("#fff", "#000")).background, "#faf7f0");
|
|
45
45
|
});
|
|
46
46
|
|
|
47
47
|
test("dark text, muted labels, additions and errors remain readable on normal and crumpled paper", () => {
|