diff --git a/dnas/mewsfeed/zomes/integrity/mews/tests/create_mew_test.rs b/dnas/mewsfeed/zomes/integrity/mews/tests/create_mew_test.rs
deleted file mode 100644
index d02d5ca0..00000000
--- a/dnas/mewsfeed/zomes/integrity/mews/tests/create_mew_test.rs
+++ /dev/null
@@ -1,62 +0,0 @@
-use hdk::prelude::*;
-use holochain::{conductor::config::ConductorConfig, prelude::DnaFile, sweettest::*};
-use mews_types::{Mew, MewType};
-
-pub async fn load_dna() -> DnaFile {
- let dna_path = std::env::current_dir()
- .unwrap()
- .join("../../../workdir/mewsfeed.dna");
- SweetDnaFile::from_bundle(&dna_path).await.unwrap()
-}
-
-#[tokio::test]
-async fn create_mew() {
- /*let dna = load_dna().await;
- let mut conductors: SweetConductorBatch =
- SweetConductorBatch::from_config(2, ConductorConfig::default()).await;
- let ((alice,), (bob,)) = conductors
- .setup_app("mewsfeed", &[dna])
- .await
- .unwrap()
- .into_tuples();
- conductors.exchange_peer_info().await;
-
- let action_hash: ActionHash = conductors[0]
- .call(
- &alice.zome("mews"),
- "create_mew",
- Mew {
- text: "blah",
- links: vec![],
- mew_type: MewType::Original
- }
- )
- .await.unwrap();
-
- let mew_record: Record = conductors[0]
- .call(
- &alice.zome("mews"),
- "get_mew",
- action_hash
- )
- .await.unwrap().unwrap();*/
-
- let mew = Mew {
- text: "blah".into(),
- links: vec![],
- mew_type: MewType::Original
- };
-
- let mut buf = vec![];
- mew.serialize(&mut rmp_serde::Serializer::new(&mut buf)).unwrap();
- println!("msgpack serialized: {:?}", buf);
-
- // let deserialized = rmp_serde::as_str(serialized);
- // println!("msgpack deserialized: {}", deserialized);
-
- let serialized = serde_json::to_string(&mew).unwrap();
- println!("json serialized: {}", serialized);
- let deserialized: Mew = serde_json::from_str(serialized.as_str()).unwrap();
- println!("json deserialized: {:?}", deserialized);
-
-}
\ No newline at end of file
diff --git a/tests/src/mewsfeed/mews/followed-creators-mews.test.ts b/tests/src/mewsfeed/mews/followed-creators-mews.test.ts
index e488dfe8..58baac30 100644
--- a/tests/src/mewsfeed/mews/followed-creators-mews.test.ts
+++ b/tests/src/mewsfeed/mews/followed-creators-mews.test.ts
@@ -268,7 +268,7 @@ it("Unfollowing should exclude creators mews from feed", async () => {
const aliceMewInput: Mew = {
text: aliceMewContent,
links: [],
- mew_type: { [MewTypeName.Original]: null },
+ mew_type: { type: MewTypeName.Original },
};
await alice.cells[0].callZome({
zome_name: "mews",
@@ -339,7 +339,7 @@ it("Followed creators mews should be ordered by timestamp in descending order",
const firstMewInput: Mew = {
text: firstMewContent,
links: [],
- mew_type: { [MewTypeName.Original]: null },
+ mew_type: { type: MewTypeName.Original },
};
await alice.cells[0].callZome({
zome_name: "mews",
@@ -351,7 +351,7 @@ it("Followed creators mews should be ordered by timestamp in descending order",
const secondMewInput: Mew = {
text: secondMewContent,
links: [],
- mew_type: { [MewTypeName.Original]: null },
+ mew_type: { type: MewTypeName.Original },
};
await bob.cells[0].callZome({
zome_name: "mews",
@@ -363,7 +363,7 @@ it("Followed creators mews should be ordered by timestamp in descending order",
const thirdMewInput: Mew = {
text: thirdMewContent,
links: [],
- mew_type: { [MewTypeName.Original]: null },
+ mew_type: { type: MewTypeName.Original },
};
await carol.cells[0].callZome({
zome_name: "mews",
@@ -375,7 +375,7 @@ it("Followed creators mews should be ordered by timestamp in descending order",
const fourthMewInput: Mew = {
text: fourthMewContent,
links: [],
- mew_type: { [MewTypeName.Original]: null },
+ mew_type: { type: MewTypeName.Original },
};
await alice.cells[0].callZome({
zome_name: "mews",
@@ -453,7 +453,7 @@ it("Followed creators mews list are time-paginated", async () => {
const createMewInput1: Mew = {
text: mewContent1,
links: [],
- mew_type: { [MewTypeName.Original]: null },
+ mew_type: { type: MewTypeName.Original },
};
const mewActionHash1 = await alice.cells[0].callZome({
zome_name: "mews",
@@ -465,7 +465,7 @@ it("Followed creators mews list are time-paginated", async () => {
const createMewInput2: Mew = {
text: mewContent2,
links: [],
- mew_type: { [MewTypeName.Original]: null },
+ mew_type: { type: MewTypeName.Original },
};
const mewActionHash2 = await alice.cells[0].callZome({
zome_name: "mews",
@@ -477,7 +477,7 @@ it("Followed creators mews list are time-paginated", async () => {
const createMewInput3: Mew = {
text: mewContent3,
links: [],
- mew_type: { [MewTypeName.Original]: null },
+ mew_type: { type: MewTypeName.Original },
};
const mewActionHash3 = await alice.cells[0].callZome({
zome_name: "mews",
@@ -489,7 +489,7 @@ it("Followed creators mews list are time-paginated", async () => {
const createMewInput4: Mew = {
text: mewContent4,
links: [],
- mew_type: { [MewTypeName.Original]: null },
+ mew_type: { type: MewTypeName.Original },
};
const mewActionHash4 = await alice.cells[0].callZome({
zome_name: "mews",
@@ -501,7 +501,7 @@ it("Followed creators mews list are time-paginated", async () => {
const createMewInput5: Mew = {
text: mewContent5,
links: [],
- mew_type: { [MewTypeName.Original]: null },
+ mew_type: { type: MewTypeName.Original },
};
const mewActionHash5 = await alice.cells[0].callZome({
zome_name: "mews",
@@ -513,7 +513,7 @@ it("Followed creators mews list are time-paginated", async () => {
const createMewInput6: Mew = {
text: mewContent6,
links: [],
- mew_type: { [MewTypeName.Original]: null },
+ mew_type: { type: MewTypeName.Original },
};
const mewActionHash6 = await alice.cells[0].callZome({
zome_name: "mews",
@@ -525,7 +525,7 @@ it("Followed creators mews list are time-paginated", async () => {
const createMewInput7: Mew = {
text: mewContent7,
links: [],
- mew_type: { [MewTypeName.Original]: null },
+ mew_type: { type: MewTypeName.Original },
};
const mewActionHash7 = await alice.cells[0].callZome({
zome_name: "mews",
diff --git a/tests/src/mewsfeed/mews/mention-to-mews.test.ts b/tests/src/mewsfeed/mews/mention-to-mews.test.ts
index a555db88..ad5fdc18 100644
--- a/tests/src/mewsfeed/mews/mention-to-mews.test.ts
+++ b/tests/src/mewsfeed/mews/mention-to-mews.test.ts
@@ -30,19 +30,19 @@ it("mention in mews", async () => {
await createMew(alice.cells[0], {
text: "this is for @bob",
links: [{ [LinkTargetName.Mention]: bob.agentPubKey }],
- mew_type: { Original: null },
+ mew_type: { type: MewTypeName.Original },
});
const actionHash2: ActionHash = await createMew(bob.cells[0], {
text: "this is for @bob 2",
links: [{ [LinkTargetName.Mention]: bob.agentPubKey }],
- mew_type: { Original: null },
+ mew_type: { type: MewTypeName.Original },
});
const actionHash3: ActionHash = await createMew(alice.cells[0], {
text: "this is for @alice",
links: [{ [LinkTargetName.Mention]: alice.agentPubKey }],
- mew_type: { Original: null },
+ mew_type: { type: MewTypeName.Original },
});
await dhtSync([alice, bob], alice.cells[0].cell_id[0]);
@@ -90,7 +90,7 @@ it("Mentions list are time-paginated", async () => {
const createMewInput1: Mew = {
text: mewContent1,
links: [{ [LinkTargetName.Mention]: alice.agentPubKey }],
- mew_type: { [MewTypeName.Original]: null },
+ mew_type: { type: MewTypeName.Original },
};
const mewActionHash1 = await alice.cells[0].callZome({
zome_name: "mews",
@@ -102,7 +102,7 @@ it("Mentions list are time-paginated", async () => {
const createMewInput2: Mew = {
text: mewContent2,
links: [{ [LinkTargetName.Mention]: alice.agentPubKey }],
- mew_type: { [MewTypeName.Original]: null },
+ mew_type: { type: MewTypeName.Original },
};
const mewActionHash2 = await alice.cells[0].callZome({
zome_name: "mews",
@@ -114,7 +114,7 @@ it("Mentions list are time-paginated", async () => {
const createMewInput3: Mew = {
text: mewContent3,
links: [{ [LinkTargetName.Mention]: alice.agentPubKey }],
- mew_type: { [MewTypeName.Original]: null },
+ mew_type: { type: MewTypeName.Original },
};
const mewActionHash3 = await alice.cells[0].callZome({
zome_name: "mews",
@@ -126,7 +126,7 @@ it("Mentions list are time-paginated", async () => {
const createMewInput4: Mew = {
text: mewContent4,
links: [{ [LinkTargetName.Mention]: alice.agentPubKey }],
- mew_type: { [MewTypeName.Original]: null },
+ mew_type: { type: MewTypeName.Original },
};
const mewActionHash4 = await alice.cells[0].callZome({
zome_name: "mews",
@@ -138,7 +138,7 @@ it("Mentions list are time-paginated", async () => {
const createMewInput5: Mew = {
text: mewContent5,
links: [{ [LinkTargetName.Mention]: alice.agentPubKey }],
- mew_type: { [MewTypeName.Original]: null },
+ mew_type: { type: MewTypeName.Original },
};
const mewActionHash5 = await alice.cells[0].callZome({
zome_name: "mews",
@@ -150,7 +150,7 @@ it("Mentions list are time-paginated", async () => {
const createMewInput6: Mew = {
text: mewContent6,
links: [{ [LinkTargetName.Mention]: alice.agentPubKey }],
- mew_type: { [MewTypeName.Original]: null },
+ mew_type: { type: MewTypeName.Original },
};
const mewActionHash6 = await alice.cells[0].callZome({
zome_name: "mews",
@@ -162,7 +162,7 @@ it("Mentions list are time-paginated", async () => {
const createMewInput7: Mew = {
text: mewContent7,
links: [{ [LinkTargetName.Mention]: alice.agentPubKey }],
- mew_type: { [MewTypeName.Original]: null },
+ mew_type: { type: MewTypeName.Original },
};
const mewActionHash7 = await alice.cells[0].callZome({
zome_name: "mews",
diff --git a/tests/src/mewsfeed/mews/mew-to-responses.test.ts b/tests/src/mewsfeed/mews/mew-to-responses.test.ts
index 61871fca..8cce3f3d 100644
--- a/tests/src/mewsfeed/mews/mew-to-responses.test.ts
+++ b/tests/src/mewsfeed/mews/mew-to-responses.test.ts
@@ -21,7 +21,7 @@ it("Agent can reply to a mew", async () => {
const aliceMewInput: Mew = {
text: aliceMewContent,
links: [],
- mew_type: { [MewTypeName.Original]: null },
+ mew_type: { type: MewTypeName.Original },
};
const action_hash: ActionHash = await alice.cells[0].callZome({
zome_name: "mews",
@@ -33,7 +33,7 @@ it("Agent can reply to a mew", async () => {
const aliceReplyInput: Mew = {
text: aliceReplyContent,
links: [],
- mew_type: { [MewTypeName.Reply]: action_hash },
+ mew_type: { type: MewTypeName.Reply, original_action_hash: action_hash },
};
const reply_action_hash: ActionHash = await alice.cells[0].callZome({
zome_name: "mews",
@@ -46,7 +46,7 @@ it("Agent can reply to a mew", async () => {
fn_name: "get_mew_with_context",
payload: reply_action_hash,
});
- assert.ok(MewTypeName.Reply in replyMew.mew.mew_type, "mew is a reply");
+ assert.ok(MewTypeName.Reply === replyMew.mew.mew_type.type, "mew is a reply");
assert.equal(
replyMew.mew.text,
aliceReplyContent,
@@ -59,7 +59,7 @@ it("Agent can reply to a mew", async () => {
payload: action_hash,
});
assert.ok(
- MewTypeName.Original in originalMew.mew.mew_type,
+ MewTypeName.Original === originalMew.mew.mew_type.type,
"mew is an original mew"
);
assert.equal(originalMew.mew.text, aliceMewContent, "mew is alice's mew");
@@ -89,7 +89,7 @@ it("Agent can mewmew a mew, only once", async () => {
const aliceMewInput: Mew = {
text: aliceMewContent,
links: [],
- mew_type: { [MewTypeName.Original]: null },
+ mew_type: { type: MewTypeName.Original },
};
const action_hash: ActionHash = await alice.cells[0].callZome({
zome_name: "mews",
@@ -100,7 +100,7 @@ it("Agent can mewmew a mew, only once", async () => {
const aliceMewmewInput: Mew = {
text: "",
links: [],
- mew_type: { [MewTypeName.Mewmew]: action_hash },
+ mew_type: { type: MewTypeName.Mewmew, original_action_hash: action_hash },
};
const mewmew_action_hash: ActionHash = await alice.cells[0].callZome({
zome_name: "mews",
@@ -113,7 +113,7 @@ it("Agent can mewmew a mew, only once", async () => {
fn_name: "get_mew_with_context",
payload: mewmew_action_hash,
});
- assert.ok(MewTypeName.Mewmew in mewmew.mew.mew_type, "mew is a mewmew");
+ assert.ok(MewTypeName.Mewmew === mewmew.mew.mew_type.type, "mew is a mewmew");
assert.deepEqual(
mewmew.mew,
aliceMewmewInput,
@@ -126,7 +126,7 @@ it("Agent can mewmew a mew, only once", async () => {
payload: action_hash,
});
assert.ok(
- MewTypeName.Original in originalMew.mew.mew_type,
+ MewTypeName.Original === originalMew.mew.mew_type.type,
"mew is an original mew"
);
assert.equal(originalMew.mew.text, aliceMewContent, "mew is alice's mew");
@@ -167,7 +167,7 @@ it("Agent can quote a mew", async () => {
const aliceMewInput: Mew = {
text: aliceMewContent,
links: [],
- mew_type: { [MewTypeName.Original]: null },
+ mew_type: { type: MewTypeName.Original },
};
const action_hash: ActionHash = await alice.cells[0].callZome({
zome_name: "mews",
@@ -180,7 +180,8 @@ it("Agent can quote a mew", async () => {
text: aliceQuoteText,
links: [],
mew_type: {
- [MewTypeName.Quote]: action_hash,
+ type: MewTypeName.Quote,
+ original_action_hash: action_hash,
},
};
const quote_action_hash: ActionHash = await alice.cells[0].callZome({
@@ -194,7 +195,7 @@ it("Agent can quote a mew", async () => {
fn_name: "get_mew_with_context",
payload: quote_action_hash,
});
- assert.ok(MewTypeName.Quote in quote.mew.mew_type, "mew is a quote");
+ assert.ok(MewTypeName.Quote === quote.mew.mew_type.type, "mew is a quote");
assert.equal(quote.mew.text, aliceQuoteText, "quote is alice's quote");
const originalMew: FeedMew = await alice.cells[0].callZome({
@@ -203,7 +204,7 @@ it("Agent can quote a mew", async () => {
payload: action_hash,
});
assert.ok(
- MewTypeName.Original in originalMew.mew.mew_type,
+ MewTypeName.Original === originalMew.mew.mew_type.type,
"mew is an original mew"
);
assert.equal(originalMew.mew.text, aliceMewContent, "mew is alice's mew");
diff --git a/tests/src/mewsfeed/mews/mew-with-context.test.ts b/tests/src/mewsfeed/mews/mew-with-context.test.ts
index c2be1113..bf8f193a 100644
--- a/tests/src/mewsfeed/mews/mew-with-context.test.ts
+++ b/tests/src/mewsfeed/mews/mew-with-context.test.ts
@@ -117,7 +117,7 @@ it("Mew with context contains replies count and is_replied", async () => {
payload: {
text: "my reply blah blah",
links: [],
- mew_type: { [MewTypeName.Reply]: actionHash },
+ mew_type: { type: MewTypeName.Reply, original_action_hash: actionHash },
},
});
@@ -176,7 +176,7 @@ it("Mew with context contains quotes count and is_quoted", async () => {
payload: {
text: "this is a quote blah blah",
links: [],
- mew_type: { [MewTypeName.Quote]: actionHash },
+ mew_type: { type: MewTypeName.Quote, original_action_hash: actionHash },
},
});
@@ -235,7 +235,7 @@ it("Mew with context contains mewmews count and is_mewmewed", async () => {
payload: {
text: "",
links: [],
- mew_type: { [MewTypeName.Mewmew]: actionHash },
+ mew_type: { type: MewTypeName.Mewmew, original_action_hash: actionHash },
},
});
diff --git a/tests/src/mewsfeed/mews/tags-to-mews.test.ts b/tests/src/mewsfeed/mews/tags-to-mews.test.ts
index fb9367a7..78060c17 100644
--- a/tests/src/mewsfeed/mews/tags-to-mews.test.ts
+++ b/tests/src/mewsfeed/mews/tags-to-mews.test.ts
@@ -29,7 +29,7 @@ it("Hashtag, cashtag and mention", async () => {
const createMewInput: Mew = {
text: mewContent,
links: [{ [LinkTargetName.Mention]: alice.agentPubKey }],
- mew_type: { [MewTypeName.Original]: null },
+ mew_type: { type: MewTypeName.Original },
};
const action_hash: ActionHash = await alice.cells[0].callZome({
@@ -126,7 +126,7 @@ it("Prefix index should return hashtags and cashtags", async () => {
const createMewInput: Mew = {
text: mewContent,
links: [{ [LinkTargetName.Mention]: alice.agentPubKey }],
- mew_type: { [MewTypeName.Original]: null },
+ mew_type: { type: MewTypeName.Original },
};
const action_hash: ActionHash = await alice.cells[0].callZome({
@@ -211,7 +211,7 @@ it("Hashtags list are time-paginated", async () => {
const createMewInput1: Mew = {
text: mewContent1,
links: [],
- mew_type: { [MewTypeName.Original]: null },
+ mew_type: { type: MewTypeName.Original },
};
const mewActionHash1 = await alice.cells[0].callZome({
zome_name: "mews",
@@ -223,7 +223,7 @@ it("Hashtags list are time-paginated", async () => {
const createMewInput2: Mew = {
text: mewContent2,
links: [],
- mew_type: { [MewTypeName.Original]: null },
+ mew_type: { type: MewTypeName.Original },
};
const mewActionHash2 = await alice.cells[0].callZome({
zome_name: "mews",
@@ -235,7 +235,7 @@ it("Hashtags list are time-paginated", async () => {
const createMewInput3: Mew = {
text: mewContent3,
links: [],
- mew_type: { [MewTypeName.Original]: null },
+ mew_type: { type: MewTypeName.Original },
};
const mewActionHash3 = await alice.cells[0].callZome({
zome_name: "mews",
@@ -247,7 +247,7 @@ it("Hashtags list are time-paginated", async () => {
const createMewInput4: Mew = {
text: mewContent4,
links: [],
- mew_type: { [MewTypeName.Original]: null },
+ mew_type: { type: MewTypeName.Original },
};
const mewActionHash4 = await alice.cells[0].callZome({
zome_name: "mews",
@@ -259,7 +259,7 @@ it("Hashtags list are time-paginated", async () => {
const createMewInput5: Mew = {
text: mewContent5,
links: [],
- mew_type: { [MewTypeName.Original]: null },
+ mew_type: { type: MewTypeName.Original },
};
const mewActionHash5 = await alice.cells[0].callZome({
zome_name: "mews",
@@ -271,7 +271,7 @@ it("Hashtags list are time-paginated", async () => {
const createMewInput6: Mew = {
text: mewContent6,
links: [],
- mew_type: { [MewTypeName.Original]: null },
+ mew_type: { type: MewTypeName.Original },
};
const mewActionHash6 = await alice.cells[0].callZome({
zome_name: "mews",
@@ -283,7 +283,7 @@ it("Hashtags list are time-paginated", async () => {
const createMewInput7: Mew = {
text: mewContent7,
links: [],
- mew_type: { [MewTypeName.Original]: null },
+ mew_type: { type: MewTypeName.Original },
};
const mewActionHash7 = await alice.cells[0].callZome({
zome_name: "mews",
@@ -410,7 +410,7 @@ it("Cashtags list are time-paginated", async () => {
const createMewInput1: Mew = {
text: mewContent1,
links: [],
- mew_type: { [MewTypeName.Original]: null },
+ mew_type: { type: MewTypeName.Original },
};
const mewActionHash1 = await alice.cells[0].callZome({
zome_name: "mews",
@@ -422,7 +422,7 @@ it("Cashtags list are time-paginated", async () => {
const createMewInput2: Mew = {
text: mewContent2,
links: [],
- mew_type: { [MewTypeName.Original]: null },
+ mew_type: { type: MewTypeName.Original },
};
const mewActionHash2 = await alice.cells[0].callZome({
zome_name: "mews",
@@ -434,7 +434,7 @@ it("Cashtags list are time-paginated", async () => {
const createMewInput3: Mew = {
text: mewContent3,
links: [],
- mew_type: { [MewTypeName.Original]: null },
+ mew_type: { type: MewTypeName.Original },
};
const mewActionHash3 = await alice.cells[0].callZome({
zome_name: "mews",
@@ -446,7 +446,7 @@ it("Cashtags list are time-paginated", async () => {
const createMewInput4: Mew = {
text: mewContent4,
links: [],
- mew_type: { [MewTypeName.Original]: null },
+ mew_type: { type: MewTypeName.Original },
};
const mewActionHash4 = await alice.cells[0].callZome({
zome_name: "mews",
@@ -458,7 +458,7 @@ it("Cashtags list are time-paginated", async () => {
const createMewInput5: Mew = {
text: mewContent5,
links: [],
- mew_type: { [MewTypeName.Original]: null },
+ mew_type: { type: MewTypeName.Original },
};
const mewActionHash5 = await alice.cells[0].callZome({
zome_name: "mews",
@@ -470,7 +470,7 @@ it("Cashtags list are time-paginated", async () => {
const createMewInput6: Mew = {
text: mewContent6,
links: [],
- mew_type: { [MewTypeName.Original]: null },
+ mew_type: { type: MewTypeName.Original },
};
const mewActionHash6 = await alice.cells[0].callZome({
zome_name: "mews",
@@ -482,7 +482,7 @@ it("Cashtags list are time-paginated", async () => {
const createMewInput7: Mew = {
text: mewContent7,
links: [],
- mew_type: { [MewTypeName.Original]: null },
+ mew_type: { type: MewTypeName.Original },
};
const mewActionHash7 = await alice.cells[0].callZome({
zome_name: "mews",
diff --git a/ui/src/components/BaseMewListItem.vue b/ui/src/components/BaseMewListItem.vue
index 7a5205ce..197392df 100644
--- a/ui/src/components/BaseMewListItem.vue
+++ b/ui/src/components/BaseMewListItem.vue
@@ -149,7 +149,7 @@
}"
@click.stop.prevent="
openCreateMewDialog(
- { [MewTypeName.Reply]: feedMew.action_hash },
+ { type: MewTypeName.Reply, original_action_hash: feedMew.action_hash },
feedMew,
() => {
onCreateReply(feedMew);
@@ -178,7 +178,7 @@
}"
@click.stop.prevent="
openCreateMewDialog(
- { [MewTypeName.Quote]: feedMew.action_hash },
+ { type: MewTypeName.Quote, original_action_hash: feedMew.action_hash },
feedMew,
() => {
onCreateQuote(feedMew);
@@ -207,7 +207,7 @@
}"
@click.stop.prevent="
openCreateMewDialog(
- { [MewTypeName.Mewmew]: feedMew.action_hash },
+ { type: MewTypeName.Mewmew, original_action_hash: feedMew.action_hash },
feedMew,
() => {
onCreateMewmew(feedMew);
@@ -376,10 +376,10 @@ const isUpdatingPin = ref(false);
const isUpdatingLick = ref(false);
const isMewmew = computed(
- () => MewTypeName.Mewmew in props.feedMew.mew.mew_type
+ () => MewTypeName.Mewmew === props.feedMew.mew.mew_type.type
);
-const isQuote = computed(() => MewTypeName.Quote in props.feedMew.mew.mew_type);
-const isReply = computed(() => MewTypeName.Reply in props.feedMew.mew.mew_type);
+const isQuote = computed(() => MewTypeName.Quote === props.feedMew.mew.mew_type.type);
+const isReply = computed(() => MewTypeName.Reply === props.feedMew.mew.mew_type.type);
const responseLabel = computed(() =>
isMewmew.value ? "mewmewed from" : isReply.value ? "replied to" : "quoted"
);
diff --git a/ui/src/layouts/MainLayout.vue b/ui/src/layouts/MainLayout.vue
index b523b426..515cdddc 100644
--- a/ui/src/layouts/MainLayout.vue
+++ b/ui/src/layouts/MainLayout.vue
@@ -25,7 +25,7 @@
style="-webkit-backdrop-filter: blur(10px)"
>
@@ -34,7 +34,7 @@
class="z-10 btn btn-md btn-neutral rounded-full py-3 flex justify-start items-center"
@click="
openCreateMewDialog(
- { [MewTypeName.Original]: null },
+ { type: MewTypeName.Original },
undefined,
onCreateMew
)
@@ -52,7 +52,7 @@
class="block sm:hidden z-10 fixed bottom-32 right-3 btn btn-md btn-neutral rounded-full py-3 flex justify-start items-center"
@click="
openCreateMewDialog(
- { [MewTypeName.Original]: null },
+ { type: MewTypeName.Original },
undefined,
onCreateMew
)
diff --git a/ui/src/stores/createMewDialog.ts b/ui/src/stores/createMewDialog.ts
index dd8044b8..578c0e65 100644
--- a/ui/src/stores/createMewDialog.ts
+++ b/ui/src/stores/createMewDialog.ts
@@ -8,7 +8,7 @@ export const useCreateMewDialogStore = defineStore("createMewDialog", () => {
console.log("completed createMew callback");
};
- const createMewDialogType = ref({ [MewTypeName.Original]: null });
+ const createMewDialogType = ref({ type: MewTypeName.Original });
const createMewDialogProps = ref<{
originalMew?: FeedMew;
originalAuthor?: Profile;