From f720b7ad9d2054684542dd1810da0617b1499627 Mon Sep 17 00:00:00 2001
From: robertu <4065233+robertu7@users.noreply.github.com>
Date: Sun, 14 Jul 2024 17:30:44 +0800
Subject: [PATCH] feat(campaign): add pages for campaign
---
package-lock.json | 262 +-
src/components/Campaign/DigestList/index.tsx | 131 +
src/components/Campaign/Link/index.tsx | 18 +
src/components/Campaign/SetState/index.tsx | 144 +
.../Campaign/SetState/withSetState.tsx | 42 +
src/components/Campaign/StateTag/index.tsx | 33 +
src/components/Layout/Sider/index.tsx | 10 +-
src/constants/route.ts | 6 +
src/definitions/index.d.ts | 23 +
src/definitions/schema.d.ts | 23341 ++++++----------
src/gql/fragments/campaign/detail.gql | 37 +
src/gql/fragments/campaign/digest.gql | 18 +
src/gql/fragments/campaign/id.gql | 0
src/gql/queries/campaignDetail.gql | 7 +
src/gql/queries/campaignList.gql | 13 +
src/pages/CampaignList/index.tsx | 41 +
src/pages/CampaignList/withCampaignList.tsx | 52 +
src/routes/campaign.tsx | 36 +
18 files changed, 9781 insertions(+), 14433 deletions(-)
create mode 100644 src/components/Campaign/DigestList/index.tsx
create mode 100644 src/components/Campaign/Link/index.tsx
create mode 100644 src/components/Campaign/SetState/index.tsx
create mode 100644 src/components/Campaign/SetState/withSetState.tsx
create mode 100644 src/components/Campaign/StateTag/index.tsx
create mode 100644 src/gql/fragments/campaign/detail.gql
create mode 100644 src/gql/fragments/campaign/digest.gql
create mode 100644 src/gql/fragments/campaign/id.gql
create mode 100644 src/gql/queries/campaignDetail.gql
create mode 100644 src/gql/queries/campaignList.gql
create mode 100644 src/pages/CampaignList/index.tsx
create mode 100644 src/pages/CampaignList/withCampaignList.tsx
create mode 100644 src/routes/campaign.tsx
diff --git a/package-lock.json b/package-lock.json
index bc045db1..12fc1357 100644
--- a/package-lock.json
+++ b/package-lock.json
@@ -1,12 +1,12 @@
{
"name": "matters-oss",
- "version": "0.28.1",
+ "version": "0.30.0",
"lockfileVersion": 2,
"requires": true,
"packages": {
"": {
"name": "matters-oss",
- "version": "0.28.1",
+ "version": "0.30.0",
"dependencies": {
"@ant-design/icons": "^4.2.1",
"@babel/core": "7.10.5",
@@ -9496,14 +9496,12 @@
"node_modules/chokidar/node_modules/fsevents/node_modules/abbrev": {
"version": "1.1.1",
"inBundle": true,
- "license": "ISC",
- "optional": true
+ "license": "ISC"
},
"node_modules/chokidar/node_modules/fsevents/node_modules/ansi-regex": {
"version": "2.1.1",
"inBundle": true,
"license": "MIT",
- "optional": true,
"engines": {
"node": ">=0.10.0"
}
@@ -9511,14 +9509,12 @@
"node_modules/chokidar/node_modules/fsevents/node_modules/aproba": {
"version": "1.2.0",
"inBundle": true,
- "license": "ISC",
- "optional": true
+ "license": "ISC"
},
"node_modules/chokidar/node_modules/fsevents/node_modules/are-we-there-yet": {
"version": "1.1.5",
"inBundle": true,
"license": "ISC",
- "optional": true,
"dependencies": {
"delegates": "^1.0.0",
"readable-stream": "^2.0.6"
@@ -9527,14 +9523,12 @@
"node_modules/chokidar/node_modules/fsevents/node_modules/balanced-match": {
"version": "1.0.0",
"inBundle": true,
- "license": "MIT",
- "optional": true
+ "license": "MIT"
},
"node_modules/chokidar/node_modules/fsevents/node_modules/brace-expansion": {
"version": "1.1.11",
"inBundle": true,
"license": "MIT",
- "optional": true,
"dependencies": {
"balanced-match": "^1.0.0",
"concat-map": "0.0.1"
@@ -9543,14 +9537,12 @@
"node_modules/chokidar/node_modules/fsevents/node_modules/chownr": {
"version": "1.1.3",
"inBundle": true,
- "license": "ISC",
- "optional": true
+ "license": "ISC"
},
"node_modules/chokidar/node_modules/fsevents/node_modules/code-point-at": {
"version": "1.1.0",
"inBundle": true,
"license": "MIT",
- "optional": true,
"engines": {
"node": ">=0.10.0"
}
@@ -9558,26 +9550,22 @@
"node_modules/chokidar/node_modules/fsevents/node_modules/concat-map": {
"version": "0.0.1",
"inBundle": true,
- "license": "MIT",
- "optional": true
+ "license": "MIT"
},
"node_modules/chokidar/node_modules/fsevents/node_modules/console-control-strings": {
"version": "1.1.0",
"inBundle": true,
- "license": "ISC",
- "optional": true
+ "license": "ISC"
},
"node_modules/chokidar/node_modules/fsevents/node_modules/core-util-is": {
"version": "1.0.2",
"inBundle": true,
- "license": "MIT",
- "optional": true
+ "license": "MIT"
},
"node_modules/chokidar/node_modules/fsevents/node_modules/debug": {
"version": "3.2.6",
"inBundle": true,
"license": "MIT",
- "optional": true,
"dependencies": {
"ms": "^2.1.1"
}
@@ -9586,7 +9574,6 @@
"version": "0.6.0",
"inBundle": true,
"license": "MIT",
- "optional": true,
"engines": {
"node": ">=4.0.0"
}
@@ -9594,14 +9581,12 @@
"node_modules/chokidar/node_modules/fsevents/node_modules/delegates": {
"version": "1.0.0",
"inBundle": true,
- "license": "MIT",
- "optional": true
+ "license": "MIT"
},
"node_modules/chokidar/node_modules/fsevents/node_modules/detect-libc": {
"version": "1.0.3",
"inBundle": true,
"license": "Apache-2.0",
- "optional": true,
"bin": {
"detect-libc": "bin/detect-libc.js"
},
@@ -9613,7 +9598,6 @@
"version": "1.2.7",
"inBundle": true,
"license": "ISC",
- "optional": true,
"dependencies": {
"minipass": "^2.6.0"
}
@@ -9621,14 +9605,12 @@
"node_modules/chokidar/node_modules/fsevents/node_modules/fs.realpath": {
"version": "1.0.0",
"inBundle": true,
- "license": "ISC",
- "optional": true
+ "license": "ISC"
},
"node_modules/chokidar/node_modules/fsevents/node_modules/gauge": {
"version": "2.7.4",
"inBundle": true,
"license": "ISC",
- "optional": true,
"dependencies": {
"aproba": "^1.0.3",
"console-control-strings": "^1.0.0",
@@ -9644,7 +9626,6 @@
"version": "7.1.6",
"inBundle": true,
"license": "ISC",
- "optional": true,
"dependencies": {
"fs.realpath": "^1.0.0",
"inflight": "^1.0.4",
@@ -9663,14 +9644,12 @@
"node_modules/chokidar/node_modules/fsevents/node_modules/has-unicode": {
"version": "2.0.1",
"inBundle": true,
- "license": "ISC",
- "optional": true
+ "license": "ISC"
},
"node_modules/chokidar/node_modules/fsevents/node_modules/iconv-lite": {
"version": "0.4.24",
"inBundle": true,
"license": "MIT",
- "optional": true,
"dependencies": {
"safer-buffer": ">= 2.1.2 < 3"
},
@@ -9682,7 +9661,6 @@
"version": "3.0.3",
"inBundle": true,
"license": "ISC",
- "optional": true,
"dependencies": {
"minimatch": "^3.0.4"
}
@@ -9691,7 +9669,6 @@
"version": "1.0.6",
"inBundle": true,
"license": "ISC",
- "optional": true,
"dependencies": {
"once": "^1.3.0",
"wrappy": "1"
@@ -9700,14 +9677,12 @@
"node_modules/chokidar/node_modules/fsevents/node_modules/inherits": {
"version": "2.0.4",
"inBundle": true,
- "license": "ISC",
- "optional": true
+ "license": "ISC"
},
"node_modules/chokidar/node_modules/fsevents/node_modules/ini": {
"version": "1.3.5",
"inBundle": true,
"license": "ISC",
- "optional": true,
"engines": {
"node": "*"
}
@@ -9716,7 +9691,6 @@
"version": "1.0.0",
"inBundle": true,
"license": "MIT",
- "optional": true,
"dependencies": {
"number-is-nan": "^1.0.0"
},
@@ -9727,14 +9701,12 @@
"node_modules/chokidar/node_modules/fsevents/node_modules/isarray": {
"version": "1.0.0",
"inBundle": true,
- "license": "MIT",
- "optional": true
+ "license": "MIT"
},
"node_modules/chokidar/node_modules/fsevents/node_modules/minimatch": {
"version": "3.0.4",
"inBundle": true,
"license": "ISC",
- "optional": true,
"dependencies": {
"brace-expansion": "^1.1.7"
},
@@ -9745,14 +9717,12 @@
"node_modules/chokidar/node_modules/fsevents/node_modules/minimist": {
"version": "0.0.8",
"inBundle": true,
- "license": "MIT",
- "optional": true
+ "license": "MIT"
},
"node_modules/chokidar/node_modules/fsevents/node_modules/minipass": {
"version": "2.9.0",
"inBundle": true,
"license": "ISC",
- "optional": true,
"dependencies": {
"safe-buffer": "^5.1.2",
"yallist": "^3.0.0"
@@ -9762,7 +9732,6 @@
"version": "1.3.3",
"inBundle": true,
"license": "MIT",
- "optional": true,
"dependencies": {
"minipass": "^2.9.0"
}
@@ -9771,7 +9740,6 @@
"version": "0.5.1",
"inBundle": true,
"license": "MIT",
- "optional": true,
"dependencies": {
"minimist": "0.0.8"
},
@@ -9782,14 +9750,12 @@
"node_modules/chokidar/node_modules/fsevents/node_modules/ms": {
"version": "2.1.2",
"inBundle": true,
- "license": "MIT",
- "optional": true
+ "license": "MIT"
},
"node_modules/chokidar/node_modules/fsevents/node_modules/needle": {
"version": "2.4.0",
"inBundle": true,
"license": "MIT",
- "optional": true,
"dependencies": {
"debug": "^3.2.6",
"iconv-lite": "^0.4.4",
@@ -9806,7 +9772,6 @@
"version": "0.14.0",
"inBundle": true,
"license": "BSD-3-Clause",
- "optional": true,
"dependencies": {
"detect-libc": "^1.0.2",
"mkdirp": "^0.5.1",
@@ -9827,7 +9792,6 @@
"version": "4.0.1",
"inBundle": true,
"license": "ISC",
- "optional": true,
"dependencies": {
"abbrev": "1",
"osenv": "^0.1.4"
@@ -9840,7 +9804,6 @@
"version": "1.1.1",
"inBundle": true,
"license": "ISC",
- "optional": true,
"dependencies": {
"npm-normalize-package-bin": "^1.0.1"
}
@@ -9848,14 +9811,12 @@
"node_modules/chokidar/node_modules/fsevents/node_modules/npm-normalize-package-bin": {
"version": "1.0.1",
"inBundle": true,
- "license": "ISC",
- "optional": true
+ "license": "ISC"
},
"node_modules/chokidar/node_modules/fsevents/node_modules/npm-packlist": {
"version": "1.4.7",
"inBundle": true,
"license": "ISC",
- "optional": true,
"dependencies": {
"ignore-walk": "^3.0.1",
"npm-bundled": "^1.0.1"
@@ -9865,7 +9826,6 @@
"version": "4.1.2",
"inBundle": true,
"license": "ISC",
- "optional": true,
"dependencies": {
"are-we-there-yet": "~1.1.2",
"console-control-strings": "~1.1.0",
@@ -9877,7 +9837,6 @@
"version": "1.0.1",
"inBundle": true,
"license": "MIT",
- "optional": true,
"engines": {
"node": ">=0.10.0"
}
@@ -9886,7 +9845,6 @@
"version": "4.1.1",
"inBundle": true,
"license": "MIT",
- "optional": true,
"engines": {
"node": ">=0.10.0"
}
@@ -9895,7 +9853,6 @@
"version": "1.4.0",
"inBundle": true,
"license": "ISC",
- "optional": true,
"dependencies": {
"wrappy": "1"
}
@@ -9904,7 +9861,6 @@
"version": "1.0.2",
"inBundle": true,
"license": "MIT",
- "optional": true,
"engines": {
"node": ">=0.10.0"
}
@@ -9913,7 +9869,6 @@
"version": "1.0.2",
"inBundle": true,
"license": "MIT",
- "optional": true,
"engines": {
"node": ">=0.10.0"
}
@@ -9922,7 +9877,6 @@
"version": "0.1.5",
"inBundle": true,
"license": "ISC",
- "optional": true,
"dependencies": {
"os-homedir": "^1.0.0",
"os-tmpdir": "^1.0.0"
@@ -9932,7 +9886,6 @@
"version": "1.0.1",
"inBundle": true,
"license": "MIT",
- "optional": true,
"engines": {
"node": ">=0.10.0"
}
@@ -9940,14 +9893,12 @@
"node_modules/chokidar/node_modules/fsevents/node_modules/process-nextick-args": {
"version": "2.0.1",
"inBundle": true,
- "license": "MIT",
- "optional": true
+ "license": "MIT"
},
"node_modules/chokidar/node_modules/fsevents/node_modules/rc": {
"version": "1.2.8",
"inBundle": true,
"license": "(BSD-2-Clause OR MIT OR Apache-2.0)",
- "optional": true,
"dependencies": {
"deep-extend": "^0.6.0",
"ini": "~1.3.0",
@@ -9961,14 +9912,12 @@
"node_modules/chokidar/node_modules/fsevents/node_modules/rc/node_modules/minimist": {
"version": "1.2.0",
"inBundle": true,
- "license": "MIT",
- "optional": true
+ "license": "MIT"
},
"node_modules/chokidar/node_modules/fsevents/node_modules/readable-stream": {
"version": "2.3.6",
"inBundle": true,
"license": "MIT",
- "optional": true,
"dependencies": {
"core-util-is": "~1.0.0",
"inherits": "~2.0.3",
@@ -9983,7 +9932,6 @@
"version": "2.7.1",
"inBundle": true,
"license": "ISC",
- "optional": true,
"dependencies": {
"glob": "^7.1.3"
},
@@ -9994,26 +9942,22 @@
"node_modules/chokidar/node_modules/fsevents/node_modules/safe-buffer": {
"version": "5.1.2",
"inBundle": true,
- "license": "MIT",
- "optional": true
+ "license": "MIT"
},
"node_modules/chokidar/node_modules/fsevents/node_modules/safer-buffer": {
"version": "2.1.2",
"inBundle": true,
- "license": "MIT",
- "optional": true
+ "license": "MIT"
},
"node_modules/chokidar/node_modules/fsevents/node_modules/sax": {
"version": "1.2.4",
"inBundle": true,
- "license": "ISC",
- "optional": true
+ "license": "ISC"
},
"node_modules/chokidar/node_modules/fsevents/node_modules/semver": {
"version": "5.7.1",
"inBundle": true,
"license": "ISC",
- "optional": true,
"bin": {
"semver": "bin/semver"
}
@@ -10021,20 +9965,17 @@
"node_modules/chokidar/node_modules/fsevents/node_modules/set-blocking": {
"version": "2.0.0",
"inBundle": true,
- "license": "ISC",
- "optional": true
+ "license": "ISC"
},
"node_modules/chokidar/node_modules/fsevents/node_modules/signal-exit": {
"version": "3.0.2",
"inBundle": true,
- "license": "ISC",
- "optional": true
+ "license": "ISC"
},
"node_modules/chokidar/node_modules/fsevents/node_modules/string_decoder": {
"version": "1.1.1",
"inBundle": true,
"license": "MIT",
- "optional": true,
"dependencies": {
"safe-buffer": "~5.1.0"
}
@@ -10043,7 +9984,6 @@
"version": "1.0.2",
"inBundle": true,
"license": "MIT",
- "optional": true,
"dependencies": {
"code-point-at": "^1.0.0",
"is-fullwidth-code-point": "^1.0.0",
@@ -10057,7 +9997,6 @@
"version": "3.0.1",
"inBundle": true,
"license": "MIT",
- "optional": true,
"dependencies": {
"ansi-regex": "^2.0.0"
},
@@ -10069,7 +10008,6 @@
"version": "2.0.1",
"inBundle": true,
"license": "MIT",
- "optional": true,
"engines": {
"node": ">=0.10.0"
}
@@ -10078,7 +10016,6 @@
"version": "4.4.13",
"inBundle": true,
"license": "ISC",
- "optional": true,
"dependencies": {
"chownr": "^1.1.1",
"fs-minipass": "^1.2.5",
@@ -10095,14 +10032,12 @@
"node_modules/chokidar/node_modules/fsevents/node_modules/util-deprecate": {
"version": "1.0.2",
"inBundle": true,
- "license": "MIT",
- "optional": true
+ "license": "MIT"
},
"node_modules/chokidar/node_modules/fsevents/node_modules/wide-align": {
"version": "1.1.3",
"inBundle": true,
"license": "ISC",
- "optional": true,
"dependencies": {
"string-width": "^1.0.2 || 2"
}
@@ -10110,14 +10045,12 @@
"node_modules/chokidar/node_modules/fsevents/node_modules/wrappy": {
"version": "1.0.2",
"inBundle": true,
- "license": "ISC",
- "optional": true
+ "license": "ISC"
},
"node_modules/chokidar/node_modules/fsevents/node_modules/yallist": {
"version": "3.1.1",
"inBundle": true,
- "license": "ISC",
- "optional": true
+ "license": "ISC"
},
"node_modules/chokidar/node_modules/glob-parent": {
"version": "3.1.0",
@@ -37982,23 +37915,19 @@
"dependencies": {
"abbrev": {
"version": "1.1.1",
- "bundled": true,
- "optional": true
+ "bundled": true
},
"ansi-regex": {
"version": "2.1.1",
- "bundled": true,
- "optional": true
+ "bundled": true
},
"aproba": {
"version": "1.2.0",
- "bundled": true,
- "optional": true
+ "bundled": true
},
"are-we-there-yet": {
"version": "1.1.5",
"bundled": true,
- "optional": true,
"requires": {
"delegates": "^1.0.0",
"readable-stream": "^2.0.6"
@@ -38006,13 +37935,11 @@
},
"balanced-match": {
"version": "1.0.0",
- "bundled": true,
- "optional": true
+ "bundled": true
},
"brace-expansion": {
"version": "1.1.11",
"bundled": true,
- "optional": true,
"requires": {
"balanced-match": "^1.0.0",
"concat-map": "0.0.1"
@@ -38020,69 +37947,57 @@
},
"chownr": {
"version": "1.1.3",
- "bundled": true,
- "optional": true
+ "bundled": true
},
"code-point-at": {
"version": "1.1.0",
- "bundled": true,
- "optional": true
+ "bundled": true
},
"concat-map": {
"version": "0.0.1",
- "bundled": true,
- "optional": true
+ "bundled": true
},
"console-control-strings": {
"version": "1.1.0",
- "bundled": true,
- "optional": true
+ "bundled": true
},
"core-util-is": {
"version": "1.0.2",
- "bundled": true,
- "optional": true
+ "bundled": true
},
"debug": {
"version": "3.2.6",
"bundled": true,
- "optional": true,
"requires": {
"ms": "^2.1.1"
}
},
"deep-extend": {
"version": "0.6.0",
- "bundled": true,
- "optional": true
+ "bundled": true
},
"delegates": {
"version": "1.0.0",
- "bundled": true,
- "optional": true
+ "bundled": true
},
"detect-libc": {
"version": "1.0.3",
- "bundled": true,
- "optional": true
+ "bundled": true
},
"fs-minipass": {
"version": "1.2.7",
"bundled": true,
- "optional": true,
"requires": {
"minipass": "^2.6.0"
}
},
"fs.realpath": {
"version": "1.0.0",
- "bundled": true,
- "optional": true
+ "bundled": true
},
"gauge": {
"version": "2.7.4",
"bundled": true,
- "optional": true,
"requires": {
"aproba": "^1.0.3",
"console-control-strings": "^1.0.0",
@@ -38097,7 +38012,6 @@
"glob": {
"version": "7.1.6",
"bundled": true,
- "optional": true,
"requires": {
"fs.realpath": "^1.0.0",
"inflight": "^1.0.4",
@@ -38109,13 +38023,11 @@
},
"has-unicode": {
"version": "2.0.1",
- "bundled": true,
- "optional": true
+ "bundled": true
},
"iconv-lite": {
"version": "0.4.24",
"bundled": true,
- "optional": true,
"requires": {
"safer-buffer": ">= 2.1.2 < 3"
}
@@ -38123,7 +38035,6 @@
"ignore-walk": {
"version": "3.0.3",
"bundled": true,
- "optional": true,
"requires": {
"minimatch": "^3.0.4"
}
@@ -38131,7 +38042,6 @@
"inflight": {
"version": "1.0.6",
"bundled": true,
- "optional": true,
"requires": {
"once": "^1.3.0",
"wrappy": "1"
@@ -38139,44 +38049,37 @@
},
"inherits": {
"version": "2.0.4",
- "bundled": true,
- "optional": true
+ "bundled": true
},
"ini": {
"version": "1.3.5",
- "bundled": true,
- "optional": true
+ "bundled": true
},
"is-fullwidth-code-point": {
"version": "1.0.0",
"bundled": true,
- "optional": true,
"requires": {
"number-is-nan": "^1.0.0"
}
},
"isarray": {
"version": "1.0.0",
- "bundled": true,
- "optional": true
+ "bundled": true
},
"minimatch": {
"version": "3.0.4",
"bundled": true,
- "optional": true,
"requires": {
"brace-expansion": "^1.1.7"
}
},
"minimist": {
"version": "0.0.8",
- "bundled": true,
- "optional": true
+ "bundled": true
},
"minipass": {
"version": "2.9.0",
"bundled": true,
- "optional": true,
"requires": {
"safe-buffer": "^5.1.2",
"yallist": "^3.0.0"
@@ -38185,7 +38088,6 @@
"minizlib": {
"version": "1.3.3",
"bundled": true,
- "optional": true,
"requires": {
"minipass": "^2.9.0"
}
@@ -38193,20 +38095,17 @@
"mkdirp": {
"version": "0.5.1",
"bundled": true,
- "optional": true,
"requires": {
"minimist": "0.0.8"
}
},
"ms": {
"version": "2.1.2",
- "bundled": true,
- "optional": true
+ "bundled": true
},
"needle": {
"version": "2.4.0",
"bundled": true,
- "optional": true,
"requires": {
"debug": "^3.2.6",
"iconv-lite": "^0.4.4",
@@ -38216,7 +38115,6 @@
"node-pre-gyp": {
"version": "0.14.0",
"bundled": true,
- "optional": true,
"requires": {
"detect-libc": "^1.0.2",
"mkdirp": "^0.5.1",
@@ -38233,7 +38131,6 @@
"nopt": {
"version": "4.0.1",
"bundled": true,
- "optional": true,
"requires": {
"abbrev": "1",
"osenv": "^0.1.4"
@@ -38242,20 +38139,17 @@
"npm-bundled": {
"version": "1.1.1",
"bundled": true,
- "optional": true,
"requires": {
"npm-normalize-package-bin": "^1.0.1"
}
},
"npm-normalize-package-bin": {
"version": "1.0.1",
- "bundled": true,
- "optional": true
+ "bundled": true
},
"npm-packlist": {
"version": "1.4.7",
"bundled": true,
- "optional": true,
"requires": {
"ignore-walk": "^3.0.1",
"npm-bundled": "^1.0.1"
@@ -38264,7 +38158,6 @@
"npmlog": {
"version": "4.1.2",
"bundled": true,
- "optional": true,
"requires": {
"are-we-there-yet": "~1.1.2",
"console-control-strings": "~1.1.0",
@@ -38274,36 +38167,30 @@
},
"number-is-nan": {
"version": "1.0.1",
- "bundled": true,
- "optional": true
+ "bundled": true
},
"object-assign": {
"version": "4.1.1",
- "bundled": true,
- "optional": true
+ "bundled": true
},
"once": {
"version": "1.4.0",
"bundled": true,
- "optional": true,
"requires": {
"wrappy": "1"
}
},
"os-homedir": {
"version": "1.0.2",
- "bundled": true,
- "optional": true
+ "bundled": true
},
"os-tmpdir": {
"version": "1.0.2",
- "bundled": true,
- "optional": true
+ "bundled": true
},
"osenv": {
"version": "0.1.5",
"bundled": true,
- "optional": true,
"requires": {
"os-homedir": "^1.0.0",
"os-tmpdir": "^1.0.0"
@@ -38311,18 +38198,15 @@
},
"path-is-absolute": {
"version": "1.0.1",
- "bundled": true,
- "optional": true
+ "bundled": true
},
"process-nextick-args": {
"version": "2.0.1",
- "bundled": true,
- "optional": true
+ "bundled": true
},
"rc": {
"version": "1.2.8",
"bundled": true,
- "optional": true,
"requires": {
"deep-extend": "^0.6.0",
"ini": "~1.3.0",
@@ -38332,15 +38216,13 @@
"dependencies": {
"minimist": {
"version": "1.2.0",
- "bundled": true,
- "optional": true
+ "bundled": true
}
}
},
"readable-stream": {
"version": "2.3.6",
"bundled": true,
- "optional": true,
"requires": {
"core-util-is": "~1.0.0",
"inherits": "~2.0.3",
@@ -38354,45 +38236,37 @@
"rimraf": {
"version": "2.7.1",
"bundled": true,
- "optional": true,
"requires": {
"glob": "^7.1.3"
}
},
"safe-buffer": {
"version": "5.1.2",
- "bundled": true,
- "optional": true
+ "bundled": true
},
"safer-buffer": {
"version": "2.1.2",
- "bundled": true,
- "optional": true
+ "bundled": true
},
"sax": {
"version": "1.2.4",
- "bundled": true,
- "optional": true
+ "bundled": true
},
"semver": {
"version": "5.7.1",
- "bundled": true,
- "optional": true
+ "bundled": true
},
"set-blocking": {
"version": "2.0.0",
- "bundled": true,
- "optional": true
+ "bundled": true
},
"signal-exit": {
"version": "3.0.2",
- "bundled": true,
- "optional": true
+ "bundled": true
},
"string_decoder": {
"version": "1.1.1",
"bundled": true,
- "optional": true,
"requires": {
"safe-buffer": "~5.1.0"
}
@@ -38400,7 +38274,6 @@
"string-width": {
"version": "1.0.2",
"bundled": true,
- "optional": true,
"requires": {
"code-point-at": "^1.0.0",
"is-fullwidth-code-point": "^1.0.0",
@@ -38410,20 +38283,17 @@
"strip-ansi": {
"version": "3.0.1",
"bundled": true,
- "optional": true,
"requires": {
"ansi-regex": "^2.0.0"
}
},
"strip-json-comments": {
"version": "2.0.1",
- "bundled": true,
- "optional": true
+ "bundled": true
},
"tar": {
"version": "4.4.13",
"bundled": true,
- "optional": true,
"requires": {
"chownr": "^1.1.1",
"fs-minipass": "^1.2.5",
@@ -38436,26 +38306,22 @@
},
"util-deprecate": {
"version": "1.0.2",
- "bundled": true,
- "optional": true
+ "bundled": true
},
"wide-align": {
"version": "1.1.3",
"bundled": true,
- "optional": true,
"requires": {
"string-width": "^1.0.2 || 2"
}
},
"wrappy": {
"version": "1.0.2",
- "bundled": true,
- "optional": true
+ "bundled": true
},
"yallist": {
"version": "3.1.1",
- "bundled": true,
- "optional": true
+ "bundled": true
}
}
},
diff --git a/src/components/Campaign/DigestList/index.tsx b/src/components/Campaign/DigestList/index.tsx
new file mode 100644
index 00000000..cfb32cef
--- /dev/null
+++ b/src/components/Campaign/DigestList/index.tsx
@@ -0,0 +1,131 @@
+import * as React from 'react'
+import { Table } from 'antd'
+import _compact from 'lodash/compact'
+
+import DateTime from '../../DateTime'
+import CampaignLink from '../Link'
+import CampaignSetState from '../SetState'
+
+import { PAGE_SIZE } from '../../../constants'
+import { CampaignDigest } from '../../../definitions'
+import { onPaginationChange, getCurrentPaginationFromUrl } from '../../../utils'
+
+type CampaignDigestListProps = {
+ data: CampaignDigest[]
+ loading?: boolean
+ pagination?: {
+ totalCount: number
+ pageSize?: number
+ fetchMore?: any
+ variables?: any
+ }
+}
+
+type CampaignDigestListState = {
+ selectedRowKeys: string[] | number[]
+ selectedRows: CampaignDigest[]
+}
+
+class CampaignDigestList extends React.Component<
+ CampaignDigestListProps,
+ CampaignDigestListState
+> {
+ state = {
+ selectedRowKeys: [],
+ selectedRows: [],
+ }
+
+ private _renderNameCell(_: any, record: CampaignDigest): React.ReactNode {
+ return
+ }
+
+ private _renderStateCell(_: any, record: CampaignDigest): React.ReactNode {
+ return
+ }
+
+ private _renderApplicationPeriod(
+ _: any,
+ record: CampaignDigest
+ ): React.ReactNode {
+ const { start, end } = record.applicationPeriod || {}
+ return (
+ <>
+
+ {' ~ '}
+ {end && }
+ >
+ )
+ }
+
+ private _renderWritingPeriod(
+ _: any,
+ record: CampaignDigest
+ ): React.ReactNode {
+ const { start, end } = record.writingPeriod || {}
+ return (
+ <>
+
+ {' ~ '}
+ {end && }
+ >
+ )
+ }
+
+ public render() {
+ const { data, loading = false, pagination } = this.props
+ const currentPagination = getCurrentPaginationFromUrl()
+
+ return (
+ <>
+
+ bordered
+ loading={loading}
+ dataSource={_compact(data)}
+ scroll={{ x: 1200, y: '70vh' }}
+ pagination={
+ pagination
+ ? {
+ defaultCurrent: currentPagination && currentPagination.page,
+ pageSize: pagination.pageSize || PAGE_SIZE,
+ total: pagination.totalCount,
+ onChange: (page) => onPaginationChange({ pagination, page }),
+ showTotal: (t) => `共 ${t} 項`,
+ position: 'both',
+ }
+ : false
+ }
+ rowKey={(record) => record.id}
+ >
+
+ dataIndex="name"
+ title="標題"
+ render={this._renderNameCell}
+ />
+
+
+ dataIndex="applicationPeriod"
+ title="報名期"
+ width={300}
+ render={this._renderApplicationPeriod}
+ />
+
+
+ dataIndex="writingPeriod"
+ title="活動期"
+ width={300}
+ render={this._renderWritingPeriod}
+ />
+
+
+ dataIndex="state"
+ title="狀態"
+ width={150}
+ render={this._renderStateCell}
+ />
+
+ >
+ )
+ }
+}
+
+export default CampaignDigestList
diff --git a/src/components/Campaign/Link/index.tsx b/src/components/Campaign/Link/index.tsx
new file mode 100644
index 00000000..2bf2307f
--- /dev/null
+++ b/src/components/Campaign/Link/index.tsx
@@ -0,0 +1,18 @@
+import * as React from 'react'
+import { Link } from 'react-router-dom'
+
+import { PATH } from '../../../constants'
+
+type CampaignLinkProps = {
+ id: string
+ name: string
+}
+
+const CampaignLink: React.FunctionComponent = ({
+ id,
+ name,
+}) => {
+ return {name}
+}
+
+export default CampaignLink
diff --git a/src/components/Campaign/SetState/index.tsx b/src/components/Campaign/SetState/index.tsx
new file mode 100644
index 00000000..1d1963c1
--- /dev/null
+++ b/src/components/Campaign/SetState/index.tsx
@@ -0,0 +1,144 @@
+import * as React from 'react'
+import { Select, Modal, message } from 'antd'
+import _get from 'lodash/get'
+
+import ErrorMessage from '../../ErrorMessage'
+import CampaignStateTag from '../StateTag'
+
+import withSetState, { ChildProps, CampaignState } from './withSetState'
+
+type SetStateState = {
+ campaignState?: CampaignState
+ loading: boolean
+ error: any
+}
+
+const PLACEHOLDER_KEY = 'placeholder'
+
+const COMMENT_STATES: {
+ key: CampaignState
+ text: string
+ disabled?: boolean
+}[] = [
+ { key: 'active', text: '正常' },
+ { key: 'archived', text: '已隱藏', disabled: true },
+ { key: 'pending', text: '編輯中' },
+ { key: 'finished', text: '已結束' },
+]
+
+class SetState extends React.Component {
+ state: Readonly = {
+ campaignState: this.props.campaignState,
+ loading: false,
+ error: null,
+ }
+
+ private _onSelectCampaignState = (
+ value: CampaignState | typeof PLACEHOLDER_KEY
+ ) => {
+ if (!value || value === PLACEHOLDER_KEY) {
+ return
+ }
+
+ this.setState({ campaignState: value }, () => {
+ if (this.props.campaignState !== value) {
+ this.preConfirm()
+ }
+ })
+ }
+
+ private _onConfirmChange = async () => {
+ this.setState({ loading: true, error: null })
+
+ const { mutate, ids, onSuccess } = this.props
+ const { campaignState } = this.state
+
+ if (!campaignState) {
+ return
+ }
+
+ try {
+ const result = await mutate({
+ variables: {
+ input: {
+ ids,
+ state: campaignState,
+ },
+ },
+ })
+ const newCampaignState = _get(result, 'data.updateCommentsState.0.state')
+ this.setState({
+ campaignState: newCampaignState,
+ loading: false,
+ error: null,
+ })
+ message.success('修改成功', 1, () => {
+ if (onSuccess) {
+ onSuccess()
+ }
+ })
+ } catch (error) {
+ this.setState({ loading: false, error })
+ }
+ }
+
+ private preConfirm = () => {
+ Modal.confirm({
+ title: `確認修改評論狀態?`,
+ content: (
+
+
+ 修改後,評論狀態將從
+ {this.props.campaignState && (
+
+ )}
+ 改為
+ {this.state.campaignState && (
+
+ )}
+
+
+ ),
+ cancelText: '取消',
+ okText: '確認',
+ onOk: () => {
+ this._onConfirmChange()
+ },
+ onCancel: this.revertChange,
+ })
+ }
+
+ private revertChange = () => {
+ this.setState({ campaignState: this.props.campaignState })
+ }
+
+ public render() {
+ const { disabled } = this.props
+ const { campaignState, loading, error } = this.state
+
+ if (error) {
+ return
+ }
+
+ return (
+
+
+
+ )
+ }
+}
+
+export default withSetState(SetState)
diff --git a/src/components/Campaign/SetState/withSetState.tsx b/src/components/Campaign/SetState/withSetState.tsx
new file mode 100644
index 00000000..7222af34
--- /dev/null
+++ b/src/components/Campaign/SetState/withSetState.tsx
@@ -0,0 +1,42 @@
+import { graphql, ChildMutateProps } from 'react-apollo'
+import gql from 'graphql-tag'
+
+const SET_STATE = gql`
+ mutation updateCampaignState($id: ID!, $state: CampaignState!) {
+ putWritingChallenge(input: { id: $id, state: $state }) {
+ id
+ state
+ }
+ }
+`
+
+type Response = {
+ updateCampaignState: {
+ id: string
+ state: string
+ }
+}
+
+export type CampaignState = 'active' | 'pending' | 'finished' | 'archived'
+
+type InputProps = {
+ ids: string[]
+ campaignState?: CampaignState
+ disabled?: boolean
+ onSuccess?: () => void
+}
+
+type Variables = {
+ input: {
+ ids: string[]
+ state: CampaignState
+ }
+}
+
+export type ChildProps = ChildMutateProps
+
+const withSetState = graphql(
+ SET_STATE
+)
+
+export default withSetState
diff --git a/src/components/Campaign/StateTag/index.tsx b/src/components/Campaign/StateTag/index.tsx
new file mode 100644
index 00000000..a1272b96
--- /dev/null
+++ b/src/components/Campaign/StateTag/index.tsx
@@ -0,0 +1,33 @@
+import * as React from 'react'
+
+import LevelTag, { LevelEnum } from '../../../components/LevelTag'
+
+const StateMap = {
+ active: {
+ level: LevelEnum.SUCCESS,
+ text: '正常',
+ },
+ pending: {
+ level: LevelEnum.INFO,
+ text: '編輯中',
+ },
+ finished: {
+ level: LevelEnum.SUCCESS,
+ text: '已結束',
+ },
+ archived: {
+ level: LevelEnum.ERROR,
+ text: '已隱藏',
+ },
+}
+
+const StateTag = ({
+ state,
+}: {
+ state: 'active' | 'pending' | 'finished' | 'archived'
+}) => {
+ const { level, text } = StateMap[state]
+ return {text}
+}
+
+export default StateTag
diff --git a/src/components/Layout/Sider/index.tsx b/src/components/Layout/Sider/index.tsx
index 2033d815..d935fe0c 100644
--- a/src/components/Layout/Sider/index.tsx
+++ b/src/components/Layout/Sider/index.tsx
@@ -103,8 +103,14 @@ export const Sider: React.FC = ({ location }) => {
評論}>
-
- {PAGE_TITLE[PATH.COMMENT_DETAIL]}
+ {PAGE_TITLE[PATH.COMMENT_LIST]}
+
+
+
+ 自由寫}>
+
+
+ {PAGE_TITLE[PATH.CAMPAIGN_LIST]}
diff --git a/src/constants/route.ts b/src/constants/route.ts
index af97c1b8..bd66cd3f 100644
--- a/src/constants/route.ts
+++ b/src/constants/route.ts
@@ -22,6 +22,9 @@ export const PATH = {
COMMENT_LIST: '/comments',
COMMENT_DETAIL: '/comments/:id',
+ CAMPAIGN_LIST: '/campaigns',
+ CAMPAIGN_DETAIL: '/campaigns/:id',
+
REPORT_LIST: '/reports',
OAUTH_CLIENT_LIST: '/oauth-clients',
@@ -66,6 +69,9 @@ export const PAGE_TITLE = {
[PATH.COMMENT_LIST]: '評論清單',
[PATH.COMMENT_DETAIL]: '評論詳情',
+ [PATH.CAMPAIGN_LIST]: '自由寫清單',
+ [PATH.CAMPAIGN_DETAIL]: '自由寫詳情',
+
[PATH.REPORT_LIST]: '報告清單',
[PATH.OAUTH_CLIENT_LIST]: 'OAuth Client 清單',
diff --git a/src/definitions/index.d.ts b/src/definitions/index.d.ts
index 20cadae1..6edf5284 100644
--- a/src/definitions/index.d.ts
+++ b/src/definitions/index.d.ts
@@ -10,6 +10,8 @@ import {
GQLLiker,
GQLIcymiTopic,
GQLUserRestrictionType,
+ GQLCampaignState,
+ GQLDatetimeRangeInput,
} from './schema'
export * from './schema'
@@ -158,6 +160,27 @@ export type CommentDigest = {
export type CommentDetail = CommentDigest
+/**
+ * Campaign: Writing Challenge
+ */
+export type CampaignDigest = {
+ id: string
+ shortHash: string
+ name: string
+ state: GQLCampaignState
+ applicationPeriod: GQLDatetimeRangeInput
+ writingPeriod: GQLDatetimeRangeInput
+}
+
+export type CampaignDetail = CampaignDigest & {
+ description: string
+ cover: string
+ link: string
+ stages: Array
+ participants: Connection
+ articles: Connection
+}
+
/**
* Report
*/
diff --git a/src/definitions/schema.d.ts b/src/definitions/schema.d.ts
index d05ac77f..1a146809 100644
--- a/src/definitions/schema.d.ts
+++ b/src/definitions/schema.d.ts
@@ -1,14979 +1,9854 @@
-import { Context } from './index'
-/* tslint:disable */
-/* eslint-disable */
-import { GraphQLResolveInfo, GraphQLScalarType } from 'graphql'
+import {
+ GraphQLResolveInfo,
+ GraphQLScalarType,
+ GraphQLScalarTypeConfig,
+} from 'graphql'
+import {
+ User as UserModel,
+ Wallet as WalletModel,
+ OAuthClientDB as OAuthClientDBModel,
+} from './user'
+import { Tag as TagModel } from './tag'
+import { Collection as CollectionModel } from './collection'
+import { Comment as CommentModel } from './comment'
+import {
+ Article as ArticleModel,
+ ArticleVersion as ArticleVersionModel,
+} from './article'
+import { Draft as DraftModel } from './draft'
+import {
+ Circle as CircleModel,
+ CircleInvitation as CircleInvitationModel,
+ CircleMember as CircleMemberModel,
+} from './circle'
+import {
+ CirclePrice as CirclePriceModel,
+ Transaction as TransactionModel,
+ Writing as WritingModel,
+ Context,
+} from './index'
+import { PayoutAccount as PayoutAccountModel } from './payment'
+import { Asset as AssetModel } from './asset'
+import { NoticeItem as NoticeItemModel } from './notification'
+import { Appreciation as AppreciationModel } from './appreciation'
+import { Report as ReportModel } from './report'
+import { MattersChoiceTopic as MattersChoiceTopicModel } from './misc'
+import { Moment as MomentModel } from './moment'
+import {
+ Campaign as CampaignModel,
+ CampaignStage as CampaignStageModel,
+} from './campaign'
+export type Maybe = T | null
+export type InputMaybe = T | undefined
+export type Exact = {
+ [K in keyof T]: T[K]
+}
+export type MakeOptional = Omit &
+ {
+ [SubKey in K]?: Maybe
+ }
+export type MakeMaybe = Omit &
+ {
+ [SubKey in K]: Maybe
+ }
+export type MakeEmpty<
+ T extends { [key: string]: unknown },
+ K extends keyof T
+> = { [_ in K]?: never }
+export type Incremental =
+ | T
+ | {
+ [P in keyof T]?: P extends ' $fragmentName' | '__typename' ? T[P] : never
+ }
+export type Omit = Pick>
+export type RequireFields = Omit &
+ {
+ [P in K]-?: NonNullable
+ }
+/** All built-in and custom scalars, mapped to their actual values */
+export type Scalars = {
+ ID: { input: string; output: string }
+ String: { input: string; output: string }
+ Boolean: { input: boolean; output: boolean }
+ Int: { input: number; output: number }
+ Float: { input: number; output: number }
+ DateTime: { input: any; output: any }
+ Upload: { input: any; output: any }
+}
+
+export type GQLAddArticlesTagsInput = {
+ articles?: InputMaybe>
+ id: Scalars['ID']['input']
+ selected?: InputMaybe
+}
+
+export type GQLAddCollectionsArticlesInput = {
+ articles: Array
+ collections: Array
+}
+
+export type GQLAddCreditInput = {
+ amount: Scalars['Float']['input']
+}
+
+export type GQLAddCreditResult = {
+ __typename?: 'AddCreditResult'
+ /** The client secret of this PaymentIntent. */
+ client_secret: Scalars['String']['output']
+ transaction: GQLTransaction
+}
+
+export type GQLAnnouncement = {
+ __typename?: 'Announcement'
+ content?: Maybe
+ cover?: Maybe
+ createdAt: Scalars['DateTime']['output']
+ expiredAt?: Maybe
+ id: Scalars['ID']['output']
+ link?: Maybe
+ order: Scalars['Int']['output']
+ title?: Maybe
+ translations?: Maybe>
+ type: GQLAnnouncementType
+ updatedAt: Scalars['DateTime']['output']
+ visible: Scalars['Boolean']['output']
+}
+
+export type GQLAnnouncementType = 'community' | 'product' | 'seminar'
+
+export type GQLAnnouncementsInput = {
+ id?: InputMaybe
+ visible?: InputMaybe
+}
+
+export type GQLApplyCampaignInput = {
+ id: Scalars['ID']['input']
+}
+
+export type GQLAppreciateArticleInput = {
+ amount: Scalars['Int']['input']
+ id: Scalars['ID']['input']
+ superLike?: InputMaybe
+ token?: InputMaybe
+}
+
+export type GQLAppreciation = {
+ __typename?: 'Appreciation'
+ amount: Scalars['Int']['output']
+ content: Scalars['String']['output']
+ /** Timestamp of appreciation. */
+ createdAt: Scalars['DateTime']['output']
+ purpose: GQLAppreciationPurpose
+ /** Recipient of appreciation. */
+ recipient: GQLUser
+ /** Sender of appreciation. */
+ sender?: Maybe
+ /** Object that appreciation is meant for. */
+ target?: Maybe
+}
+
+export type GQLAppreciationConnection = GQLConnection & {
+ __typename?: 'AppreciationConnection'
+ edges?: Maybe>
+ pageInfo: GQLPageInfo
+ totalCount: Scalars['Int']['output']
+}
+
+export type GQLAppreciationEdge = {
+ __typename?: 'AppreciationEdge'
+ cursor: Scalars['String']['output']
+ node: GQLAppreciation
+}
+
+export type GQLAppreciationPurpose =
+ | 'appreciate'
+ | 'appreciateComment'
+ | 'appreciateSubsidy'
+ | 'firstPost'
+ | 'invitationAccepted'
+ | 'joinByInvitation'
+ | 'joinByTask'
+ | 'systemSubsidy'
+
/**
- * This file is auto-generated by graphql-schema-typescript
- * Please note that any changes in this file may be overwritten
+ * This type contains metadata, content, hash and related data of an article. If you
+ * want information about article's comments. Please check Comment type.
*/
+export type GQLArticle = GQLNode &
+ GQLPinnableWork & {
+ __typename?: 'Article'
+ /** Access related fields on circle */
+ access: GQLArticleAccess
+ /** Number represents how many times per user can appreciate this article. */
+ appreciateLeft: Scalars['Int']['output']
+ /** Limit the nuhmber of appreciate per user. */
+ appreciateLimit: Scalars['Int']['output']
+ /** Appreciations history of this article. */
+ appreciationsReceived: GQLAppreciationConnection
+ /** Total number of appreciations recieved of this article. */
+ appreciationsReceivedTotal: Scalars['Int']['output']
+ /** List of assets are belonged to this article (Only the author can access currently). */
+ assets: Array
+ /** Author of this article. */
+ author: GQLUser
+ /** Available translation languages. */
+ availableTranslations?: Maybe>
+ /** associated campaigns */
+ campaigns: Array
+ /** whether readers can comment */
+ canComment: Scalars['Boolean']['output']
+ /** This value determines if current viewer can SuperLike or not. */
+ canSuperLike: Scalars['Boolean']['output']
+ /** List of articles which added this article into their collections. */
+ collectedBy: GQLArticleConnection
+ /** List of articles added into this article' collection. */
+ collection: GQLArticleConnection
+ /** The counting number of comments. */
+ commentCount: Scalars['Int']['output']
+ /** List of comments of this article. */
+ comments: GQLCommentConnection
+ /** Content (HTML) of this article. */
+ content: Scalars['String']['output']
+ /** Different foramts of content. */
+ contents: GQLArticleContents
+ /** Article cover's link. */
+ cover?: Maybe
+ /** Time of this article was created. */
+ createdAt: Scalars['DateTime']['output']
+ /** IPFS hash of this article. */
+ dataHash: Scalars['String']['output']
+ /** whether current viewer has donated to this article */
+ donated: Scalars['Boolean']['output']
+ /** Total number of donation recieved of this article. */
+ donationCount: Scalars['Int']['output']
+ /** Donations of this article, grouped by sender */
+ donations: GQLArticleDonationConnection
+ /**
+ * Drafts linked to this article.
+ * @deprecated Use Article.newestUnpublishedDraft or Article.newestPublishedDraft instead
+ */
+ drafts?: Maybe>
+ /** List of featured comments of this article. */
+ featuredComments: GQLCommentConnection
+ /** This value determines if current viewer has appreciated or not. */
+ hasAppreciate: Scalars['Boolean']['output']
+ /** Unique ID of this article */
+ id: Scalars['ID']['output']
+ /** the iscnId if published to ISCN */
+ iscnId?: Maybe
+ /** Original language of content */
+ language?: Maybe
+ /** License Type */
+ license: GQLArticleLicenseType
+ /** Media hash, composed of cid encoding, of this article. */
+ mediaHash: Scalars['String']['output']
+ /** Newest published draft linked to this article. */
+ newestPublishedDraft: GQLDraft
+ /** Newest unpublished draft linked to this article. */
+ newestUnpublishedDraft?: Maybe
+ oss: GQLArticleOss
+ /** The number determines how many comments can be set as pinned comment. */
+ pinCommentLeft: Scalars['Int']['output']
+ /** The number determines how many pinned comments can be set. */
+ pinCommentLimit: Scalars['Int']['output']
+ pinned: Scalars['Boolean']['output']
+ /** List of pinned comments. */
+ pinnedComments?: Maybe>
+ /** Cumulative reading time in seconds */
+ readTime: Scalars['Float']['output']
+ /** Total number of readers of this article. */
+ readerCount: Scalars['Int']['output']
+ /** Related articles to this article. */
+ relatedArticles: GQLArticleConnection
+ /** Donation-related articles to this article. */
+ relatedDonationArticles: GQLArticleConnection
+ remark?: Maybe
+ /** creator message after support */
+ replyToDonator?: Maybe
+ /** creator message asking for support */
+ requestForDonation?: Maybe
+ /** The counting number of this article. */
+ responseCount: Scalars['Int']['output']
+ /** List of responses of a article. */
+ responses: GQLResponseConnection
+ /** Time of this article was revised. */
+ revisedAt?: Maybe
+ /** Revision Count */
+ revisionCount: Scalars['Int']['output']
+ /** whether content is marked as sensitive by admin */
+ sensitiveByAdmin: Scalars['Boolean']['output']
+ /** whether content is marked as sensitive by author */
+ sensitiveByAuthor: Scalars['Boolean']['output']
+ /** Short hash for shorter url addressing */
+ shortHash: Scalars['String']['output']
+ /** Slugified article title. */
+ slug: Scalars['String']['output']
+ /** State of this article. */
+ state: GQLArticleState
+ /**
+ * This value determines if this article is an author selected article or not.
+ * @deprecated Use pinned instead
+ */
+ sticky: Scalars['Boolean']['output']
+ /** This value determines if current Viewer has subscribed of not. */
+ subscribed: Scalars['Boolean']['output']
+ /** Subscribers of this article. */
+ subscribers: GQLUserConnection
+ /** A short summary for this article. */
+ summary: Scalars['String']['output']
+ /** This value determines if the summary is customized or not. */
+ summaryCustomized: Scalars['Boolean']['output']
+ /** Tags attached to this article. */
+ tags?: Maybe>
+ /** Article title. */
+ title: Scalars['String']['output']
+ /** The number represents how popular is this article. */
+ topicScore?: Maybe
+ /** Transactions history of this article. */
+ transactionsReceivedBy: GQLUserConnection
+ /** Translation of article title and content. */
+ translation?: Maybe
+ /** history versions */
+ versions: GQLArticleVersionsConnection
+ /** Word count of this article. */
+ wordCount?: Maybe
+ }
-/*******************************
- * *
- * TYPE DEFS *
- * *
- *******************************/
-export interface GQLQuery {
- article?: GQLArticle
- circle?: GQLCircle
- node?: GQLNode
- nodes?: Array
- frequentSearch?: Array
- search: GQLSearchResultConnection
- official: GQLOfficial
- oss: GQLOSS
- viewer?: GQLUser
- user?: GQLUser
- oauthRequestToken?: string
- exchangeRates?: Array
- oauthClient?: GQLOAuthClient
+/**
+ * This type contains metadata, content, hash and related data of an article. If you
+ * want information about article's comments. Please check Comment type.
+ */
+export type GQLArticleAppreciationsReceivedArgs = {
+ input: GQLConnectionArgs
}
-export interface GQLArticleInput {
- mediaHash?: string
- shortHash?: string
+/**
+ * This type contains metadata, content, hash and related data of an article. If you
+ * want information about article's comments. Please check Comment type.
+ */
+export type GQLArticleCollectedByArgs = {
+ input: GQLConnectionArgs
}
/**
* This type contains metadata, content, hash and related data of an article. If you
* want information about article's comments. Please check Comment type.
*/
-export interface GQLArticle extends GQLNode, GQLPinnableWork {
- /**
- * Unique ID of this article
- */
- id: string
+export type GQLArticleCollectionArgs = {
+ input: GQLConnectionArgs
+}
- /**
- * The number represents how popular is this article.
- */
- topicScore?: number
+/**
+ * This type contains metadata, content, hash and related data of an article. If you
+ * want information about article's comments. Please check Comment type.
+ */
+export type GQLArticleCommentsArgs = {
+ input: GQLCommentsInput
+}
- /**
- * Slugified article title.
- */
- slug: string
+/**
+ * This type contains metadata, content, hash and related data of an article. If you
+ * want information about article's comments. Please check Comment type.
+ */
+export type GQLArticleDonationsArgs = {
+ input: GQLConnectionArgs
+}
- /**
- * Time of this article was created.
- */
- createdAt: GQLDateTime
+/**
+ * This type contains metadata, content, hash and related data of an article. If you
+ * want information about article's comments. Please check Comment type.
+ */
+export type GQLArticleFeaturedCommentsArgs = {
+ input: GQLFeaturedCommentsInput
+}
- /**
- * Time of this article was revised.
- */
- revisedAt?: GQLDateTime
+/**
+ * This type contains metadata, content, hash and related data of an article. If you
+ * want information about article's comments. Please check Comment type.
+ */
+export type GQLArticleRelatedArticlesArgs = {
+ input: GQLConnectionArgs
+}
- /**
- * State of this article.
- */
- state: GQLArticleState
+/**
+ * This type contains metadata, content, hash and related data of an article. If you
+ * want information about article's comments. Please check Comment type.
+ */
+export type GQLArticleRelatedDonationArticlesArgs = {
+ input: GQLRelatedDonationArticlesInput
+}
- /**
- * Author of this article.
- */
- author: GQLUser
+/**
+ * This type contains metadata, content, hash and related data of an article. If you
+ * want information about article's comments. Please check Comment type.
+ */
+export type GQLArticleResponsesArgs = {
+ input: GQLResponsesInput
+}
- /**
- * Article title.
- */
- title: string
+/**
+ * This type contains metadata, content, hash and related data of an article. If you
+ * want information about article's comments. Please check Comment type.
+ */
+export type GQLArticleSubscribersArgs = {
+ input: GQLConnectionArgs
+}
- /**
- * Article cover's link.
- */
- cover?: string
+/**
+ * This type contains metadata, content, hash and related data of an article. If you
+ * want information about article's comments. Please check Comment type.
+ */
+export type GQLArticleTransactionsReceivedByArgs = {
+ input: GQLTransactionsReceivedByArgs
+}
- /**
- * List of assets are belonged to this article (Only the author can access currently).
- */
- assets: Array
+/**
+ * This type contains metadata, content, hash and related data of an article. If you
+ * want information about article's comments. Please check Comment type.
+ */
+export type GQLArticleTranslationArgs = {
+ input?: InputMaybe
+}
- /**
- * A short summary for this article.
- */
- summary: string
+/**
+ * This type contains metadata, content, hash and related data of an article. If you
+ * want information about article's comments. Please check Comment type.
+ */
+export type GQLArticleVersionsArgs = {
+ input: GQLArticleVersionsInput
+}
- /**
- * This value determines if the summary is customized or not.
- */
- summaryCustomized: boolean
+export type GQLArticleAccess = {
+ __typename?: 'ArticleAccess'
+ circle?: Maybe
+ secret?: Maybe
+ type: GQLArticleAccessType
+}
- /**
- * Tags attached to this article.
- */
- tags?: Array
+/** Enums for types of article access */
+export type GQLArticleAccessType = 'paywall' | 'public'
- /**
- * Word count of this article.
- */
- wordCount?: number
+export type GQLArticleArticleNotice = GQLNotice & {
+ __typename?: 'ArticleArticleNotice'
+ /** List of notice actors. */
+ actors?: Maybe>
+ article: GQLArticle
+ /** Time of this notice was created. */
+ createdAt: Scalars['DateTime']['output']
+ /** Unique ID of this notice. */
+ id: Scalars['ID']['output']
+ target: GQLArticle
+ type: GQLArticleArticleNoticeType
+ /** The value determines if the notice is unread or not. */
+ unread: Scalars['Boolean']['output']
+}
- /**
- * IPFS hash of this article.
- */
- dataHash: string
+export type GQLArticleArticleNoticeType = 'ArticleNewCollected'
- /**
- * Media hash, composed of cid encoding, of this article.
- */
- mediaHash: string
+export type GQLArticleCampaign = {
+ __typename?: 'ArticleCampaign'
+ campaign: GQLCampaign
+ stage: GQLCampaignStage
+}
- /**
- * Short hash for shorter url addressing
- */
- shortHash: string
+export type GQLArticleCampaignInput = {
+ campaign: Scalars['ID']['input']
+ stage: Scalars['ID']['input']
+}
- /**
- * Content (HTML) of this article.
- */
- content: string
+export type GQLArticleConnection = GQLConnection & {
+ __typename?: 'ArticleConnection'
+ edges?: Maybe>
+ pageInfo: GQLPageInfo
+ totalCount: Scalars['Int']['output']
+}
- /**
- * Different foramts of content.
- */
- contents: GQLArticleContents
+export type GQLArticleContents = {
+ __typename?: 'ArticleContents'
+ /** HTML content of this article. */
+ html: Scalars['String']['output']
+ /** Markdown content of this article. */
+ markdown: Scalars['String']['output']
+}
- /**
- * Original language of content
- */
- language?: string
+export type GQLArticleDonation = {
+ __typename?: 'ArticleDonation'
+ id: Scalars['ID']['output']
+ sender?: Maybe
+}
- /**
- * List of articles which added this article into their collections.
- */
- collectedBy: GQLArticleConnection
+export type GQLArticleDonationConnection = {
+ __typename?: 'ArticleDonationConnection'
+ edges?: Maybe>
+ pageInfo: GQLPageInfo
+ totalCount: Scalars['Int']['output']
+}
- /**
- * List of articles added into this article' collection.
- */
- collection: GQLArticleConnection
+export type GQLArticleDonationEdge = {
+ __typename?: 'ArticleDonationEdge'
+ cursor: Scalars['String']['output']
+ node: GQLArticleDonation
+}
- /**
- * Related articles to this article.
- */
- relatedArticles: GQLArticleConnection
+export type GQLArticleEdge = {
+ __typename?: 'ArticleEdge'
+ cursor: Scalars['String']['output']
+ node: GQLArticle
+}
- /**
- * Donation-related articles to this article.
- */
- relatedDonationArticles: GQLArticleConnection
+export type GQLArticleInput = {
+ mediaHash?: InputMaybe
+ shortHash?: InputMaybe
+}
- /**
- * Appreciations history of this article.
- */
- appreciationsReceived: GQLAppreciationConnection
+/** Enums for types of article license */
+export type GQLArticleLicenseType =
+ | 'arr'
+ | 'cc_0'
+ | 'cc_by_nc_nd_2'
+ | 'cc_by_nc_nd_4'
- /**
- * Total number of appreciations recieved of this article.
- */
- appreciationsReceivedTotal: number
+export type GQLArticleNotice = GQLNotice & {
+ __typename?: 'ArticleNotice'
+ /** List of notice actors. */
+ actors?: Maybe>
+ /** Time of this notice was created. */
+ createdAt: Scalars['DateTime']['output']
+ /** Unique ID of this notice. */
+ id: Scalars['ID']['output']
+ target: GQLArticle
+ type: GQLArticleNoticeType
+ /** The value determines if the notice is unread or not. */
+ unread: Scalars['Boolean']['output']
+}
+
+export type GQLArticleNoticeType =
+ | 'ArticleMentionedYou'
+ | 'ArticleNewAppreciation'
+ | 'ArticleNewSubscriber'
+ | 'ArticlePublished'
+ | 'CircleNewArticle'
+ | 'RevisedArticleNotPublished'
+ | 'RevisedArticlePublished'
+
+export type GQLArticleOss = {
+ __typename?: 'ArticleOSS'
+ boost: Scalars['Float']['output']
+ inRecommendHottest: Scalars['Boolean']['output']
+ inRecommendIcymi: Scalars['Boolean']['output']
+ inRecommendNewest: Scalars['Boolean']['output']
+ inSearch: Scalars['Boolean']['output']
+ score: Scalars['Float']['output']
+}
+
+export type GQLArticleRecommendationActivity = {
+ __typename?: 'ArticleRecommendationActivity'
+ /** Recommended articles */
+ nodes?: Maybe>
+ /** The source type of recommendation */
+ source?: Maybe
+}
+
+export type GQLArticleRecommendationActivitySource =
+ | 'ReadArticlesTags'
+ | 'UserDonation'
+
+/** Enums for an article state. */
+export type GQLArticleState = 'active' | 'archived' | 'banned'
+
+export type GQLArticleTranslation = {
+ __typename?: 'ArticleTranslation'
+ content?: Maybe
+ language?: Maybe
+ summary?: Maybe
+ title?: Maybe
+}
+
+export type GQLArticleVersion = GQLNode & {
+ __typename?: 'ArticleVersion'
+ contents: GQLArticleContents
+ createdAt: Scalars['DateTime']['output']
+ dataHash?: Maybe
+ description?: Maybe
+ id: Scalars['ID']['output']
+ mediaHash?: Maybe
+ summary: Scalars['String']['output']
+ title: Scalars['String']['output']
+ translation?: Maybe
+}
- /**
- * Total number of donation recieved of this article.
- */
- donationCount: number
+export type GQLArticleVersionTranslationArgs = {
+ input?: InputMaybe
+}
- /**
- * Total number of readers of this article.
- */
- readerCount: number
+export type GQLArticleVersionEdge = {
+ __typename?: 'ArticleVersionEdge'
+ cursor: Scalars['String']['output']
+ node: GQLArticleVersion
+}
- /**
- * Subscribers of this article.
- */
- subscribers: GQLUserConnection
+export type GQLArticleVersionsConnection = GQLConnection & {
+ __typename?: 'ArticleVersionsConnection'
+ edges: Array>
+ pageInfo: GQLPageInfo
+ totalCount: Scalars['Int']['output']
+}
- /**
- * Limit the nuhmber of appreciate per user.
- */
- appreciateLimit: number
+export type GQLArticleVersionsInput = {
+ after?: InputMaybe
+ first?: InputMaybe
+}
- /**
- * Number represents how many times per user can appreciate this article.
- */
- appreciateLeft: number
+/** This type contains type, link and related data of an asset. */
+export type GQLAsset = {
+ __typename?: 'Asset'
+ /** Time of this asset was created. */
+ createdAt: Scalars['DateTime']['output']
+ draft?: Maybe
+ /** Unique ID of this Asset. */
+ id: Scalars['ID']['output']
+ /** Link of this asset. */
+ path: Scalars['String']['output']
+ /** Types of this asset. */
+ type: GQLAssetType
+ uploadURL?: Maybe
+}
+
+/** Enums for asset types. */
+export type GQLAssetType =
+ | 'announcementCover'
+ | 'avatar'
+ | 'campaignCover'
+ | 'circleAvatar'
+ | 'circleCover'
+ | 'collectionCover'
+ | 'cover'
+ | 'embed'
+ | 'embedaudio'
+ | 'moment'
+ | 'oauthClientAvatar'
+ | 'profileCover'
+ | 'tagCover'
+
+export type GQLAuthResult = {
+ __typename?: 'AuthResult'
+ auth: Scalars['Boolean']['output']
+ token?: Maybe
+ type: GQLAuthResultType
+ user?: Maybe
+}
- /**
- * This value determines if current viewer has appreciated or not.
- */
- hasAppreciate: boolean
+export type GQLAuthResultType = 'LinkAccount' | 'Login' | 'Signup'
- /**
- * This value determines if current viewer can SuperLike or not.
- */
- canSuperLike: boolean
+export type GQLAuthorsType = 'active' | 'appreciated' | 'default' | 'trendy'
- /**
- * This value determines if current Viewer has subscribed of not.
- */
- subscribed: boolean
+export type GQLBadge = {
+ __typename?: 'Badge'
+ type: GQLBadgeType
+}
- /**
- * This value determines if this article is an author selected article or not.
- * @deprecated Use pinned instead
- */
- sticky: boolean
- pinned: boolean
+export type GQLBadgeType =
+ | 'architect'
+ | 'golden_motor'
+ | 'grand_slam'
+ | 'nomad1'
+ | 'nomad2'
+ | 'nomad3'
+ | 'nomad4'
+ | 'seed'
- /**
- * Translation of article title and content.
- */
- translation?: GQLArticleTranslation
+export type GQLBadgedUsersInput = {
+ after?: InputMaybe
+ first?: InputMaybe
+ type?: InputMaybe
+}
- /**
- * Available translation languages.
- */
- availableTranslations?: Array
+export type GQLBalance = {
+ __typename?: 'Balance'
+ HKD: Scalars['Float']['output']
+}
- /**
- * Transactions history of this article.
- */
- transactionsReceivedBy: GQLUserConnection
+export type GQLBlockchainTransaction = {
+ __typename?: 'BlockchainTransaction'
+ chain: GQLChain
+ txHash: Scalars['String']['output']
+}
- /**
- * Donations of this article, grouped by sender
- */
- donations: GQLArticleDonationConnection
+export type GQLBlockedSearchKeyword = {
+ __typename?: 'BlockedSearchKeyword'
+ /** Time of this search keyword was created. */
+ createdAt: Scalars['DateTime']['output']
+ /** Unique ID of bloked search keyword. */
+ id: Scalars['ID']['output']
+ /** Types of this search keyword. */
+ searchKey: Scalars['String']['output']
+}
- /**
- * Cumulative reading time in seconds
- */
- readTime: number
+export type GQLBoostTypes = 'Article' | 'Tag' | 'User'
- /**
- * Drafts linked to this article.
- * @deprecated Use Article.newestUnpublishedDraft or Article.newestPublishedDraft instead
- */
- drafts?: Array
+export type GQLCacheControlScope = 'PRIVATE' | 'PUBLIC'
- /**
- * Newest unpublished draft linked to this article.
- */
- newestUnpublishedDraft?: GQLDraft
+export type GQLCampaign = {
+ description: Scalars['String']['output']
+ id: Scalars['ID']['output']
+ name: Scalars['String']['output']
+ shortHash: Scalars['String']['output']
+ state: GQLCampaignState
+}
- /**
- * Newest published draft linked to this article.
- */
- newestPublishedDraft: GQLDraft
+export type GQLCampaignApplicationState = 'pending' | 'rejected' | 'succeeded'
- /**
- * Revision Count
- */
- revisionCount: number
+export type GQLCampaignArticlesFilter = {
+ stage: Scalars['ID']['input']
+}
- /**
- * Access related fields on circle
- */
- access: GQLArticleAccess
+export type GQLCampaignArticlesInput = {
+ after?: InputMaybe
+ filter?: InputMaybe
+ first?: InputMaybe
+}
- /**
- * whether content is marked as sensitive by author
- */
- sensitiveByAuthor: boolean
+export type GQLCampaignConnection = GQLConnection & {
+ __typename?: 'CampaignConnection'
+ edges?: Maybe>
+ pageInfo: GQLPageInfo
+ totalCount: Scalars['Int']['output']
+}
- /**
- * whether content is marked as sensitive by admin
- */
- sensitiveByAdmin: boolean
+export type GQLCampaignEdge = {
+ __typename?: 'CampaignEdge'
+ cursor: Scalars['String']['output']
+ node: GQLCampaign
+}
- /**
- * License Type
- */
- license: GQLArticleLicenseType
+export type GQLCampaignInput = {
+ shortHash: Scalars['String']['input']
+}
- /**
- * whether current viewer has donated to this article
- */
- donated: boolean
+export type GQLCampaignStage = {
+ __typename?: 'CampaignStage'
+ id: Scalars['ID']['output']
+ name: Scalars['String']['output']
+ period?: Maybe
+}
- /**
- * creator message asking for support
- */
- requestForDonation?: string
+export type GQLCampaignStageInput = {
+ name: Array
+ period?: InputMaybe
+}
+
+export type GQLCampaignState = 'active' | 'archived' | 'finished' | 'pending'
+
+export type GQLCampaignsInput = {
+ after?: InputMaybe
+ first?: InputMaybe
+ /** return pending and archived campaigns */
+ oss?: InputMaybe
+}
+
+export type GQLChain = 'Optimism' | 'Polygon'
+
+export type GQLChangeEmailInput = {
+ newEmail: Scalars['String']['input']
+ newEmailCodeId: Scalars['ID']['input']
+ oldEmail: Scalars['String']['input']
+ oldEmailCodeId: Scalars['ID']['input']
+}
+export type GQLCircle = GQLNode & {
+ __typename?: 'Circle'
+ /** Analytics dashboard. */
+ analytics: GQLCircleAnalytics
/**
- * creator message after support
+ * Circle avatar's link.
+ * @deprecated No longer in use
*/
- replyToDonator?: string
-
+ avatar?: Maybe
+ /** Comments broadcasted by Circle owner. */
+ broadcast: GQLCommentConnection
/**
- * the iscnId if published to ISCN
+ * Circle cover's link.
+ * @deprecated No longer in use
*/
- iscnId?: string
-
+ cover?: Maybe
/**
- * whether readers can comment
+ * Created time.
+ * @deprecated No longer in use
*/
- canComment: boolean
-
+ createdAt: Scalars['DateTime']['output']
+ /** A short description of this Circle. */
+ description?: Maybe
+ /** Comments made by Circle member. */
+ discussion: GQLCommentConnection
+ /** Discussion (include replies) count of this circle. */
+ discussionCount: Scalars['Int']['output']
+ /** Discussion (exclude replies) count of this circle. */
+ discussionThreadCount: Scalars['Int']['output']
/**
- * history versions
+ * Human readable name of this Circle.
+ * @deprecated No longer in use
*/
- versions: GQLArticleVersionsConnection
- oss: GQLArticleOSS
- remark?: string
-
+ displayName: Scalars['String']['output']
/**
- * The counting number of comments.
+ * List of Circle follower.
+ * @deprecated No longer in use
*/
- commentCount: number
-
+ followers: GQLUserConnection
+ /** Unique ID. */
+ id: Scalars['ID']['output']
+ /** Invitation used by current viewer. */
+ invitedBy?: Maybe
+ /** Invitations belonged to this Circle. */
+ invites: GQLInvites
/**
- * The number determines how many pinned comments can be set.
+ * This value determines if current viewer is following Circle or not.
+ * @deprecated No longer in use
*/
- pinCommentLimit: number
-
+ isFollower: Scalars['Boolean']['output']
/**
- * The number determines how many comments can be set as pinned comment.
+ * This value determines if current viewer is Member or not.
+ * @deprecated No longer in use
*/
- pinCommentLeft: number
-
+ isMember: Scalars['Boolean']['output']
/**
- * List of pinned comments.
+ * List of Circle member.
+ * @deprecated No longer in use
*/
- pinnedComments?: Array
-
+ members: GQLMemberConnection
/**
- * List of featured comments of this article.
+ * Slugified name of this Circle.
+ * @deprecated No longer in use
*/
- featuredComments: GQLCommentConnection
-
+ name: Scalars['String']['output']
+ /** Circle owner. */
+ owner: GQLUser
+ /** Pinned comments broadcasted by Circle owner. */
+ pinnedBroadcast?: Maybe>
+ /** Prices offered by this Circle. */
+ prices?: Maybe>
/**
- * List of comments of this article.
+ * State of this Circle.
+ * @deprecated No longer in use
*/
- comments: GQLCommentConnection
-
+ state: GQLCircleState
/**
- * The counting number of this article.
+ * Updated time.
+ * @deprecated No longer in use
*/
- responseCount: number
-
+ updatedAt: Scalars['DateTime']['output']
/**
- * List of responses of a article.
+ * List of works belong to this Circle.
+ * @deprecated No longer in use
*/
- responses: GQLResponseConnection
+ works: GQLArticleConnection
}
-export interface GQLNode {
- id: string
+export type GQLCircleBroadcastArgs = {
+ input: GQLCommentsInput
}
-/** Use this to resolve interface type Node */
-export type GQLPossibleNodeTypeNames =
- | 'Article'
- | 'User'
- | 'Circle'
- | 'Comment'
- | 'Tag'
- | 'IcymiTopic'
- | 'Collection'
- | 'Draft'
- | 'ArticleVersion'
- | 'Report'
+export type GQLCircleDiscussionArgs = {
+ input: GQLCommentsInput
+}
-export interface GQLNodeNameMap {
- Node: GQLNode
- Article: GQLArticle
- User: GQLUser
- Circle: GQLCircle
- Comment: GQLComment
- Tag: GQLTag
- IcymiTopic: GQLIcymiTopic
- Collection: GQLCollection
- Draft: GQLDraft
- ArticleVersion: GQLArticleVersion
- Report: GQLReport
+export type GQLCircleFollowersArgs = {
+ input: GQLConnectionArgs
}
-export interface GQLPinnableWork {
- id: string
- pinned: boolean
- title: string
- cover?: string
+export type GQLCircleMembersArgs = {
+ input: GQLConnectionArgs
}
-/** Use this to resolve interface type PinnableWork */
-export type GQLPossiblePinnableWorkTypeNames = 'Article' | 'Collection'
+export type GQLCircleWorksArgs = {
+ input: GQLConnectionArgs
+}
-export interface GQLPinnableWorkNameMap {
- PinnableWork: GQLPinnableWork
- Article: GQLArticle
- Collection: GQLCollection
+export type GQLCircleAnalytics = {
+ __typename?: 'CircleAnalytics'
+ content: GQLCircleContentAnalytics
+ follower: GQLCircleFollowerAnalytics
+ income: GQLCircleIncomeAnalytics
+ subscriber: GQLCircleSubscriberAnalytics
}
-/**
- * A date-time string at UTC, such as 2007-12-03T10:15:30Z, compliant with the
- * `date-time` format outlined in section 5.6 of the RFC 3339 profile of the ISO
- * 8601 standard for representation of dates and times using the Gregorian calendar.
- */
-export type GQLDateTime = any
+export type GQLCircleConnection = GQLConnection & {
+ __typename?: 'CircleConnection'
+ edges?: Maybe>
+ pageInfo: GQLPageInfo
+ totalCount: Scalars['Int']['output']
+}
-/**
- * Enums for an article state.
- */
-export const enum GQLArticleState {
- active = 'active',
- archived = 'archived',
- banned = 'banned',
+export type GQLCircleContentAnalytics = {
+ __typename?: 'CircleContentAnalytics'
+ paywall?: Maybe>
+ public?: Maybe>
}
-export interface GQLUser extends GQLNode {
- /**
- * Circles belong to current user.
- */
- ownCircles?: Array
+export type GQLCircleContentAnalyticsDatum = {
+ __typename?: 'CircleContentAnalyticsDatum'
+ node: GQLArticle
+ readCount: Scalars['Int']['output']
+}
- /**
- * Circles whiches user has subscribed.
- */
- subscribedCircles: GQLCircleConnection
- notices: GQLNoticeConnection
+export type GQLCircleEdge = {
+ __typename?: 'CircleEdge'
+ cursor: Scalars['String']['output']
+ node: GQLCircle
+}
- /**
- * Global id of an user.
- */
- id: string
+export type GQLCircleFollowerAnalytics = {
+ __typename?: 'CircleFollowerAnalytics'
+ /** current follower count */
+ current: Scalars['Int']['output']
+ /** the percentage of follower count in reader count of circle articles */
+ followerPercentage: Scalars['Float']['output']
+ /** subscriber count history of last 4 months */
+ history: Array
+}
- /**
- * Global unique user name of a user.
- */
- userName?: string
+export type GQLCircleIncomeAnalytics = {
+ __typename?: 'CircleIncomeAnalytics'
+ /** income history of last 4 months */
+ history: Array
+ /** income of next month */
+ nextMonth: Scalars['Float']['output']
+ /** income of this month */
+ thisMonth: Scalars['Float']['output']
+ /** total income of all time */
+ total: Scalars['Float']['output']
+}
+
+export type GQLCircleInput = {
+ /** Slugified name of a Circle. */
+ name: Scalars['String']['input']
+}
+
+export type GQLCircleNotice = GQLNotice & {
+ __typename?: 'CircleNotice'
+ /** List of notice actors. */
+ actors?: Maybe>
+ /** Optional discussion/broadcast comments for bundled notices */
+ comments?: Maybe>
+ /** Time of this notice was created. */
+ createdAt: Scalars['DateTime']['output']
+ /** Unique ID of this notice. */
+ id: Scalars['ID']['output']
+ /** Optional mention comments for bundled notices */
+ mentions?: Maybe>
+ /** Optional discussion/broadcast replies for bundled notices */
+ replies?: Maybe>
+ target: GQLCircle
+ type: GQLCircleNoticeType
+ /** The value determines if the notice is unread or not. */
+ unread: Scalars['Boolean']['output']
+}
- /**
- * Display name on user profile, can be duplicated.
- */
- displayName?: string
+export type GQLCircleNoticeType =
+ | 'CircleInvitation'
+ | 'CircleNewBroadcastComments'
+ | 'CircleNewDiscussionComments'
+ | 'CircleNewFollower'
+ | 'CircleNewSubscriber'
+ | 'CircleNewUnsubscriber'
- /**
- * LikerID of LikeCoin, being used by LikeCoin OAuth
- */
- likerId?: string
+export type GQLCircleRecommendationActivity = {
+ __typename?: 'CircleRecommendationActivity'
+ /** Recommended circles */
+ nodes?: Maybe>
+ /** The source type of recommendation */
+ source?: Maybe
+}
- /**
- * Liker info of current user
- */
- liker: GQLLiker
+export type GQLCircleRecommendationActivitySource = 'UserSubscription'
- /**
- * URL for user avatar.
- */
- avatar?: string
+export type GQLCircleState = 'active' | 'archived'
- /**
- * User information.
- */
- info: GQLUserInfo
+export type GQLCircleSubscriberAnalytics = {
+ __typename?: 'CircleSubscriberAnalytics'
+ /** current invitee count */
+ currentInvitee: Scalars['Int']['output']
+ /** current subscriber count */
+ currentSubscriber: Scalars['Int']['output']
+ /** invitee count history of last 4 months */
+ inviteeHistory: Array
+ /** subscriber count history of last 4 months */
+ subscriberHistory: Array
+}
- /**
- * User settings.
- */
- settings: GQLUserSettings
+export type GQLClaimLogbooksInput = {
+ ethAddress: Scalars['String']['input']
+ /** nonce from generateSigningMessage */
+ nonce: Scalars['String']['input']
+ /** sign'ed by wallet */
+ signature: Scalars['String']['input']
+ /** the message being sign'ed, including nonce */
+ signedMessage: Scalars['String']['input']
+}
- /**
- * Article recommendations for current user.
- */
- recommendation: GQLRecommendation
+export type GQLClaimLogbooksResult = {
+ __typename?: 'ClaimLogbooksResult'
+ ids?: Maybe>
+ txHash: Scalars['String']['output']
+}
- /**
- * Articles authored by current user.
- */
- articles: GQLArticleConnection
+export type GQLClearReadHistoryInput = {
+ id?: InputMaybe
+}
- /**
- * collections authored by current user.
- */
- collections: GQLCollectionConnection
+export type GQLCollection = GQLNode &
+ GQLPinnableWork & {
+ __typename?: 'Collection'
+ articles: GQLArticleConnection
+ author: GQLUser
+ /** Check if the collection contains the article */
+ contains: Scalars['Boolean']['output']
+ cover?: Maybe
+ description?: Maybe
+ id: Scalars['ID']['output']
+ pinned: Scalars['Boolean']['output']
+ title: Scalars['String']['output']
+ updatedAt: Scalars['DateTime']['output']
+ }
- /**
- * user latest articles or collections
- */
- latestWorks: Array
+export type GQLCollectionArticlesArgs = {
+ input: GQLCollectionArticlesInput
+}
- /**
- * user pinned articles or collections
- */
- pinnedWorks: Array
+export type GQLCollectionContainsArgs = {
+ input: GQLNodeInput
+}
- /**
- * Tags by by usage order of current user.
- */
- tags: GQLTagConnection
+export type GQLCollectionArticlesInput = {
+ after?: InputMaybe
+ first?: InputMaybe
+ reversed?: InputMaybe
+}
- /**
- * Tags owned and maintained by current user.
- */
- maintainedTags: GQLTagConnection
+export type GQLCollectionConnection = GQLConnection & {
+ __typename?: 'CollectionConnection'
+ edges?: Maybe>
+ pageInfo: GQLPageInfo
+ totalCount: Scalars['Int']['output']
+}
- /**
- * Tags pinned by current user.
- */
- pinnedTags: GQLTagConnection
+export type GQLCollectionEdge = {
+ __typename?: 'CollectionEdge'
+ cursor: Scalars['String']['output']
+ node: GQLCollection
+}
+/** This type contains content, author, descendant comments and related data of a comment. */
+export type GQLComment = GQLNode & {
+ __typename?: 'Comment'
+ /** Author of this comment. */
+ author: GQLUser
+ /** Descendant comments of this comment. */
+ comments: GQLCommentConnection
+ /** Content of this comment. */
+ content?: Maybe
+ /** Time of this comment was created. */
+ createdAt: Scalars['DateTime']['output']
/**
- * Drafts authored by current user.
+ * The counting number of downvotes.
+ * @deprecated No longer in use in querying
*/
- drafts: GQLDraftConnection
+ downvotes: Scalars['Int']['output']
+ /** This value determines this comment is from article donator or not. */
+ fromDonator: Scalars['Boolean']['output']
+ /** Unique ID of this comment. */
+ id: Scalars['ID']['output']
+ /** The value determines current user's vote. */
+ myVote?: Maybe
+ /** Current comment belongs to which Node. */
+ node: GQLNode
+ /** Parent comment of this comment. */
+ parentComment?: Maybe
+ /** This value determines this comment is pinned or not. */
+ pinned: Scalars['Boolean']['output']
+ remark?: Maybe
+ /** A Comment that this comment replied to. */
+ replyTo?: Maybe
+ /** State of this comment. */
+ state: GQLCommentState
+ type: GQLCommentType
+ /** The counting number of upvotes. */
+ upvotes: Scalars['Int']['output']
+}
- /**
- * Articles current user commented on
- */
- commentedArticles: GQLArticleConnection
+/** This type contains content, author, descendant comments and related data of a comment. */
+export type GQLCommentCommentsArgs = {
+ input: GQLCommentCommentsInput
+}
- /**
- * Artilces current user subscribed to.
- */
- subscriptions: GQLArticleConnection
+export type GQLCommentCommentNotice = GQLNotice & {
+ __typename?: 'CommentCommentNotice'
+ /** List of notice actors. */
+ actors?: Maybe>
+ comment: GQLComment
+ /** Time of this notice was created. */
+ createdAt: Scalars['DateTime']['output']
+ /** Unique ID of this notice. */
+ id: Scalars['ID']['output']
+ target: GQLComment
+ type: GQLCommentCommentNoticeType
+ /** The value determines if the notice is unread or not. */
+ unread: Scalars['Boolean']['output']
+}
- /**
- * Record of user activity, only accessable by current user.
- */
- activity: GQLUserActivity
+export type GQLCommentCommentNoticeType = 'CommentNewReply'
- /**
- * Followers of this user.
- */
- followers: GQLUserConnection
+export type GQLCommentCommentsInput = {
+ after?: InputMaybe
+ author?: InputMaybe
+ first?: InputMaybe
+ sort?: InputMaybe
+}
- /**
- * Following contents of this user.
- */
- following: GQLFollowing
+export type GQLCommentConnection = GQLConnection & {
+ __typename?: 'CommentConnection'
+ edges?: Maybe>
+ pageInfo: GQLPageInfo
+ totalCount: Scalars['Int']['output']
+}
- /**
- * Whether current user is following viewer.
- */
- isFollower: boolean
+export type GQLCommentEdge = {
+ __typename?: 'CommentEdge'
+ cursor: Scalars['String']['output']
+ node: GQLComment
+}
- /**
- * Whether viewer is following current user.
- */
- isFollowee: boolean
+export type GQLCommentInput = {
+ articleId?: InputMaybe
+ circleId?: InputMaybe
+ content: Scalars['String']['input']
+ mentions?: InputMaybe>
+ momentId?: InputMaybe
+ parentId?: InputMaybe
+ replyTo?: InputMaybe
+ type: GQLCommentType
+}
- /**
- * Users that blocked by current user.
- */
- blockList: GQLUserConnection
+export type GQLCommentNotice = GQLNotice & {
+ __typename?: 'CommentNotice'
+ /** List of notice actors. */
+ actors?: Maybe>
+ /** Time of this notice was created. */
+ createdAt: Scalars['DateTime']['output']
+ /** Unique ID of this notice. */
+ id: Scalars['ID']['output']
+ target: GQLComment
+ type: GQLCommentNoticeType
+ /** The value determines if the notice is unread or not. */
+ unread: Scalars['Boolean']['output']
+}
+
+export type GQLCommentNoticeType =
+ | 'ArticleNewComment'
+ | 'CircleNewBroadcast'
+ | 'CommentLiked'
+ | 'CommentMentionedYou'
+ | 'CommentPinned'
+ | 'MomentNewComment'
+ | 'SubscribedArticleNewComment'
+
+/** Enums for sorting comments by time. */
+export type GQLCommentSort = 'newest' | 'oldest'
+
+/** Enums for comment state. */
+export type GQLCommentState = 'active' | 'archived' | 'banned' | 'collapsed'
+
+export type GQLCommentType =
+ | 'article'
+ | 'circleBroadcast'
+ | 'circleDiscussion'
+ | 'moment'
+
+export type GQLCommentsFilter = {
+ author?: InputMaybe
+ parentComment?: InputMaybe
+ state?: InputMaybe
+}
+
+export type GQLCommentsInput = {
+ after?: InputMaybe
+ before?: InputMaybe
+ filter?: InputMaybe
+ first?: InputMaybe
+ includeAfter?: InputMaybe
+ includeBefore?: InputMaybe
+ sort?: InputMaybe
+}
+
+export type GQLConfirmVerificationCodeInput = {
+ code: Scalars['String']['input']
+ email: Scalars['String']['input']
+ type: GQLVerificationCodeType
+}
- /**
- * Whether current user is blocking viewer.
- */
- isBlocking: boolean
+export type GQLConnectStripeAccountInput = {
+ country: GQLStripeAccountCountry
+}
- /**
- * Whether current user is blocked by viewer.
- */
- isBlocked: boolean
+export type GQLConnectStripeAccountResult = {
+ __typename?: 'ConnectStripeAccountResult'
+ redirectUrl: Scalars['String']['output']
+}
- /**
- * user data analytics, only accessable by current user.
- */
- analytics: GQLUserAnalytics
+export type GQLConnection = {
+ pageInfo: GQLPageInfo
+ totalCount: Scalars['Int']['output']
+}
- /**
- * Status of current user.
- */
- status?: GQLUserStatus
- oss: GQLUserOSS
- remark?: string
+export type GQLConnectionArgs = {
+ after?: InputMaybe
+ filter?: InputMaybe
+ first?: InputMaybe
+ oss?: InputMaybe
+}
- /**
- * User Wallet
- */
- wallet: GQLWallet
+export type GQLCryptoWallet = {
+ __typename?: 'CryptoWallet'
+ address: Scalars['String']['output']
+ /** does this address own any Travelogger NFTs? this value is cached at most 1day, and refreshed at next `nfts` query */
+ hasNFTs: Scalars['Boolean']['output']
+ id: Scalars['ID']['output']
+ /** NFT assets owned by this wallet address */
+ nfts?: Maybe>
+}
- /**
- * Payment pointer that resolves to Open Payments endpoints
- */
- paymentPointer?: string
+export type GQLCryptoWalletSignaturePurpose =
+ | 'airdrop'
+ | 'connect'
+ | 'login'
+ | 'signup'
+
+export type GQLDatetimeRange = {
+ __typename?: 'DatetimeRange'
+ end?: Maybe
+ start: Scalars['DateTime']['output']
}
-export interface GQLCircle extends GQLNode {
- /**
- * Unique ID.
- */
- id: string
+export type GQLDatetimeRangeInput = {
+ end?: InputMaybe
+ start: Scalars['DateTime']['input']
+}
- /**
- * Circle avatar's link.
- * @deprecated No longer in use
- */
- avatar?: string
+export type GQLDeleteAnnouncementsInput = {
+ ids?: InputMaybe>
+}
- /**
- * Circle cover's link.
- * @deprecated No longer in use
- */
- cover?: string
+export type GQLDeleteArticlesTagsInput = {
+ articles?: InputMaybe>
+ id: Scalars['ID']['input']
+}
- /**
- * Slugified name of this Circle.
- * @deprecated No longer in use
- */
- name: string
+export type GQLDeleteCollectionArticlesInput = {
+ articles: Array
+ collection: Scalars['ID']['input']
+}
- /**
- * Human readable name of this Circle.
- * @deprecated No longer in use
- */
- displayName: string
+export type GQLDeleteCollectionsInput = {
+ ids: Array
+}
- /**
- * A short description of this Circle.
- */
- description?: string
+export type GQLDeleteCommentInput = {
+ id: Scalars['ID']['input']
+}
- /**
- * Prices offered by this Circle.
- */
- prices?: Array
+export type GQLDeleteDraftInput = {
+ id: Scalars['ID']['input']
+}
- /**
- * Circle owner.
- */
- owner: GQLUser
-
- /**
- * List of Circle member.
- * @deprecated No longer in use
- */
- members: GQLMemberConnection
-
- /**
- * List of Circle follower.
- * @deprecated No longer in use
- */
- followers: GQLUserConnection
-
- /**
- * List of works belong to this Circle.
- * @deprecated No longer in use
- */
- works: GQLArticleConnection
-
- /**
- * State of this Circle.
- * @deprecated No longer in use
- */
- state: GQLCircleState
-
- /**
- * Created time.
- * @deprecated No longer in use
- */
- createdAt: GQLDateTime
-
- /**
- * Updated time.
- * @deprecated No longer in use
- */
- updatedAt: GQLDateTime
-
- /**
- * This value determines if current viewer is following Circle or not.
- * @deprecated No longer in use
- */
- isFollower: boolean
-
- /**
- * This value determines if current viewer is Member or not.
- * @deprecated No longer in use
- */
- isMember: boolean
-
- /**
- * Invitations belonged to this Circle.
- */
- invites: GQLInvites
-
- /**
- * Invitation used by current viewer.
- */
- invitedBy?: GQLInvitation
-
- /**
- * Analytics dashboard.
- */
- analytics: GQLCircleAnalytics
-
- /**
- * Comments broadcasted by Circle owner.
- */
- broadcast: GQLCommentConnection
-
- /**
- * Pinned comments broadcasted by Circle owner.
- */
- pinnedBroadcast?: Array
-
- /**
- * Comments made by Circle member.
- */
- discussion: GQLCommentConnection
-
- /**
- * Discussion (exclude replies) count of this circle.
- */
- discussionThreadCount: number
-
- /**
- * Discussion (include replies) count of this circle.
- */
- discussionCount: number
+export type GQLDeleteMomentInput = {
+ id: Scalars['ID']['input']
}
-export interface GQLPrice {
- /**
- * Unique ID.
- */
- id: string
-
- /**
- * Amount of Price.
- */
- amount: number
-
- /**
- * Current Price belongs to whcih Circle.
- */
- circle: GQLCircle
+export type GQLDeleteTagsInput = {
+ ids: Array
+}
- /**
- * Currency of Price.
- */
- currency: GQLTransactionCurrency
+export type GQLDirectImageUploadInput = {
+ draft?: InputMaybe
+ entityId?: InputMaybe
+ entityType: GQLEntityType
+ mime?: InputMaybe
+ type: GQLAssetType
+ url?: InputMaybe
+}
- /**
- * State of Price.
- */
- state: GQLPriceState
+/** This type contains content, collections, assets and related data of a draft. */
+export type GQLDraft = GQLNode & {
+ __typename?: 'Draft'
+ /** Access related fields on circle */
+ access: GQLDraftAccess
+ /** Published article */
+ article?: Maybe
+ /** List of assets are belonged to this draft. */
+ assets: Array
+ /** associated campaigns */
+ campaigns: Array
+ /** whether readers can comment */
+ canComment: Scalars['Boolean']['output']
+ /** Collection list of this draft. */
+ collection: GQLArticleConnection
+ /** Content (HTML) of this draft. */
+ content?: Maybe
+ /** Draft's cover link. */
+ cover?: Maybe
+ /** Time of this draft was created. */
+ createdAt: Scalars['DateTime']['output']
+ /** Unique ID of this draft. */
+ id: Scalars['ID']['output']
+ /** whether publish to ISCN */
+ iscnPublish?: Maybe
+ /** License Type */
+ license: GQLArticleLicenseType
+ /** Media hash, composed of cid encoding, of this draft. */
+ mediaHash?: Maybe
+ /** State of draft during publihsing. */
+ publishState: GQLPublishState
+ /** creator message after support */
+ replyToDonator?: Maybe
+ /** creator message asking for support */
+ requestForDonation?: Maybe
+ /** whether content is marked as sensitive by author */
+ sensitiveByAuthor: Scalars['Boolean']['output']
+ /** Slugified draft title. */
+ slug: Scalars['String']['output']
+ /** Summary of this draft. */
+ summary?: Maybe
+ /** This value determines if the summary is customized or not. */
+ summaryCustomized: Scalars['Boolean']['output']
+ /** Tags are attached to this draft. */
+ tags?: Maybe>
+ /** Draft title. */
+ title?: Maybe
+ /** Last time of this draft was upadted. */
+ updatedAt: Scalars['DateTime']['output']
+ /** The counting number of words in this draft. */
+ wordCount: Scalars['Int']['output']
+}
+
+/** This type contains content, collections, assets and related data of a draft. */
+export type GQLDraftCollectionArgs = {
+ input: GQLConnectionArgs
+}
- /**
- * Created time.
- * @deprecated No longer in use
- */
- createdAt: GQLDateTime
+export type GQLDraftAccess = {
+ __typename?: 'DraftAccess'
+ circle?: Maybe
+ type: GQLArticleAccessType
+}
- /**
- * Updated time.
- * @deprecated No longer in use
- */
- updatedAt: GQLDateTime
+export type GQLDraftConnection = GQLConnection & {
+ __typename?: 'DraftConnection'
+ edges?: Maybe>
+ pageInfo: GQLPageInfo
+ totalCount: Scalars['Int']['output']
}
-export const enum GQLTransactionCurrency {
- HKD = 'HKD',
- LIKE = 'LIKE',
- USDT = 'USDT',
+export type GQLDraftEdge = {
+ __typename?: 'DraftEdge'
+ cursor: Scalars['String']['output']
+ node: GQLDraft
}
-export const enum GQLPriceState {
- active = 'active',
- archived = 'archived',
+export type GQLEditArticleInput = {
+ accessType?: InputMaybe
+ /** which campaigns to attach */
+ campaigns?: InputMaybe>
+ /** whether readers can comment */
+ canComment?: InputMaybe
+ circle?: InputMaybe
+ collection?: InputMaybe>
+ content?: InputMaybe
+ cover?: InputMaybe
+ /** revision description */
+ description?: InputMaybe
+ id: Scalars['ID']['input']
+ /** whether publish to ISCN */
+ iscnPublish?: InputMaybe
+ license?: InputMaybe
+ pinned?: InputMaybe
+ replyToDonator?: InputMaybe
+ requestForDonation?: InputMaybe
+ sensitive?: InputMaybe
+ state?: InputMaybe
+ /** deprecated, use pinned instead */
+ sticky?: InputMaybe
+ summary?: InputMaybe
+ tags?: InputMaybe>
+ title?: InputMaybe
+}
+
+export type GQLEmailLoginInput = {
+ email: Scalars['String']['input']
+ /** used in register */
+ language?: InputMaybe
+ passwordOrCode: Scalars['String']['input']
+ referralCode?: InputMaybe
+}
+
+export type GQLEntityType =
+ | 'announcement'
+ | 'article'
+ | 'circle'
+ | 'collection'
+ | 'draft'
+ | 'moment'
+ | 'tag'
+ | 'user'
+
+export type GQLExchangeRate = {
+ __typename?: 'ExchangeRate'
+ from: GQLTransactionCurrency
+ rate: Scalars['Float']['output']
+ to: GQLQuoteCurrency
+ /** Last updated time from currency convertor APIs */
+ updatedAt: Scalars['DateTime']['output']
}
-export interface GQLConnectionArgs {
- after?: string
- first?: GQLfirst_Int_min_0
- oss?: boolean
- filter?: GQLFilterInput
+export type GQLExchangeRatesInput = {
+ from?: InputMaybe
+ to?: InputMaybe
}
-export type GQLfirst_Int_min_0 = any
+export type GQLFeature = {
+ __typename?: 'Feature'
+ enabled: Scalars['Boolean']['output']
+ name: GQLFeatureName
+}
-export interface GQLFilterInput {
- /**
- * index of list, min: 0, max: 49
- */
- random?: GQLrandom_Int_min_0_max_49
+export type GQLFeatureFlag = 'admin' | 'off' | 'on' | 'seeding'
- /**
- * Used in RecommendInput
- */
- followed?: boolean
+export type GQLFeatureName =
+ | 'add_credit'
+ | 'circle_interact'
+ | 'circle_management'
+ | 'fingerprint'
+ | 'payment'
+ | 'payout'
+ | 'tag_adoption'
+ | 'verify_appreciate'
- /**
- * Used in User Articles filter, by tags or by time range, or both
- */
- tagIds?: Array
- inRangeStart?: GQLDateTime
- inRangeEnd?: GQLDateTime
+export type GQLFeaturedCommentsInput = {
+ after?: InputMaybe
+ first?: InputMaybe
+ sort?: InputMaybe
}
-export type GQLrandom_Int_min_0_max_49 = any
-
-export interface GQLMemberConnection extends GQLConnection {
- totalCount: number
- pageInfo: GQLPageInfo
- edges?: Array
+export type GQLFeaturedTagsInput = {
+ /** tagIds */
+ ids: Array
}
-export interface GQLConnection {
- totalCount: number
- pageInfo: GQLPageInfo
+export type GQLFilterInput = {
+ /** Used in RecommendInput */
+ followed?: InputMaybe
+ inRangeEnd?: InputMaybe
+ inRangeStart?: InputMaybe
+ /** index of list, min: 0, max: 49 */
+ random?: InputMaybe
+ /** Used in User Articles filter, by tags or by time range, or both */
+ tagIds?: InputMaybe>
}
-/** Use this to resolve interface type Connection */
-export type GQLPossibleConnectionTypeNames =
- | 'MemberConnection'
- | 'UserConnection'
- | 'ArticleConnection'
- | 'InvitationConnection'
- | 'CommentConnection'
- | 'CircleConnection'
- | 'NoticeConnection'
- | 'TagConnection'
- | 'FollowingActivityConnection'
- | 'CollectionConnection'
- | 'DraftConnection'
- | 'ReadHistoryConnection'
- | 'RecentSearchConnection'
- | 'AppreciationConnection'
- | 'TopDonatorConnection'
- | 'TransactionConnection'
- | 'ArticleVersionsConnection'
- | 'ResponseConnection'
- | 'SearchResultConnection'
- | 'OAuthClientConnection'
- | 'SkippedListItemsConnection'
- | 'ReportConnection'
- | 'IcymiTopicConnection'
-
-export interface GQLConnectionNameMap {
- Connection: GQLConnection
- MemberConnection: GQLMemberConnection
- UserConnection: GQLUserConnection
- ArticleConnection: GQLArticleConnection
- InvitationConnection: GQLInvitationConnection
- CommentConnection: GQLCommentConnection
- CircleConnection: GQLCircleConnection
- NoticeConnection: GQLNoticeConnection
- TagConnection: GQLTagConnection
- FollowingActivityConnection: GQLFollowingActivityConnection
- CollectionConnection: GQLCollectionConnection
- DraftConnection: GQLDraftConnection
- ReadHistoryConnection: GQLReadHistoryConnection
- RecentSearchConnection: GQLRecentSearchConnection
- AppreciationConnection: GQLAppreciationConnection
- TopDonatorConnection: GQLTopDonatorConnection
- TransactionConnection: GQLTransactionConnection
- ArticleVersionsConnection: GQLArticleVersionsConnection
- ResponseConnection: GQLResponseConnection
- SearchResultConnection: GQLSearchResultConnection
- OAuthClientConnection: GQLOAuthClientConnection
- SkippedListItemsConnection: GQLSkippedListItemsConnection
- ReportConnection: GQLReportConnection
- IcymiTopicConnection: GQLIcymiTopicConnection
+export type GQLFollowing = {
+ __typename?: 'Following'
+ circles: GQLCircleConnection
+ tags: GQLTagConnection
+ users: GQLUserConnection
}
-export interface GQLPageInfo {
- startCursor?: string
- endCursor?: string
- hasNextPage: boolean
- hasPreviousPage: boolean
+export type GQLFollowingCirclesArgs = {
+ input: GQLConnectionArgs
}
-export interface GQLMemberEdge {
- cursor: string
- node: GQLMember
+export type GQLFollowingTagsArgs = {
+ input: GQLConnectionArgs
}
-export interface GQLMember {
- /**
- * User who join to a Circle.
- */
- user: GQLUser
-
- /**
- * Price chosen by user when joining a Circle.
- */
- price: GQLPrice
+export type GQLFollowingUsersArgs = {
+ input: GQLConnectionArgs
}
-export interface GQLUserConnection extends GQLConnection {
- totalCount: number
- pageInfo: GQLPageInfo
- edges?: Array
-}
+export type GQLFollowingActivity =
+ | GQLArticleRecommendationActivity
+ | GQLCircleRecommendationActivity
+ | GQLUserAddArticleTagActivity
+ | GQLUserBroadcastCircleActivity
+ | GQLUserCreateCircleActivity
+ | GQLUserPostMomentActivity
+ | GQLUserPublishArticleActivity
+ | GQLUserRecommendationActivity
-export interface GQLUserEdge {
- cursor: string
- node: GQLUser
+export type GQLFollowingActivityConnection = GQLConnection & {
+ __typename?: 'FollowingActivityConnection'
+ edges?: Maybe>
+ pageInfo: GQLPageInfo
+ totalCount: Scalars['Int']['output']
}
-export interface GQLArticleConnection extends GQLConnection {
- totalCount: number
- pageInfo: GQLPageInfo
- edges?: Array
+export type GQLFollowingActivityEdge = {
+ __typename?: 'FollowingActivityEdge'
+ cursor: Scalars['String']['output']
+ node: GQLFollowingActivity
}
-export interface GQLArticleEdge {
- cursor: string
- node: GQLArticle
+export type GQLFrequentSearchInput = {
+ first?: InputMaybe
+ key?: InputMaybe
}
-export const enum GQLCircleState {
- active = 'active',
- archived = 'archived',
+export type GQLGenerateSigningMessageInput = {
+ address: Scalars['String']['input']
+ purpose?: InputMaybe
}
-export interface GQLInvites {
- /**
- * Accepted invitation list
- */
- accepted: GQLInvitationConnection
+export type GQLGrantType = 'authorization_code' | 'refresh_token'
- /**
- * Pending invitation list
- */
- pending: GQLInvitationConnection
+export type GQLIcymiTopic = GQLNode & {
+ __typename?: 'IcymiTopic'
+ archivedAt?: Maybe
+ articles: Array
+ id: Scalars['ID']['output']
+ note?: Maybe
+ pinAmount: Scalars['Int']['output']
+ publishedAt?: Maybe
+ state: GQLIcymiTopicState
+ title: Scalars['String']['output']
}
-export interface GQLInvitationConnection extends GQLConnection {
- totalCount: number
+export type GQLIcymiTopicConnection = GQLConnection & {
+ __typename?: 'IcymiTopicConnection'
+ edges: Array
pageInfo: GQLPageInfo
- edges?: Array
+ totalCount: Scalars['Int']['output']
}
-export interface GQLInvitationEdge {
- cursor: string
- node: GQLInvitation
+export type GQLIcymiTopicEdge = {
+ __typename?: 'IcymiTopicEdge'
+ cursor: Scalars['String']['output']
+ node: GQLIcymiTopic
}
-export interface GQLInvitation {
- /**
- * Unique ID.
- */
- id: string
+export type GQLIcymiTopicState = 'archived' | 'editing' | 'published'
- /**
- * Target person of this invitation.
- */
+export type GQLInvitation = {
+ __typename?: 'Invitation'
+ /** Accepted time. */
+ acceptedAt?: Maybe
+ /** Invitation of current Circle. */
+ circle: GQLCircle
+ /** Created time. */
+ createdAt: Scalars['DateTime']['output']
+ /** Free period of this invitation. */
+ freePeriod: Scalars['Int']['output']
+ /** Unique ID. */
+ id: Scalars['ID']['output']
+ /** Target person of this invitation. */
invitee: GQLInvitee
-
- /**
- * Creator of this invitation.
- */
+ /** Creator of this invitation. */
inviter: GQLUser
+ /** Sent time. */
+ sentAt: Scalars['DateTime']['output']
+ /** Determine it's specific state. */
+ state: GQLInvitationState
+}
- /**
- * Invitation of current Circle.
- */
- circle: GQLCircle
-
- /**
- * Free period of this invitation.
- */
- freePeriod: number
+export type GQLInvitationConnection = GQLConnection & {
+ __typename?: 'InvitationConnection'
+ edges?: Maybe>
+ pageInfo: GQLPageInfo
+ totalCount: Scalars['Int']['output']
+}
- /**
- * Created time.
- */
- createdAt: GQLDateTime
+export type GQLInvitationEdge = {
+ __typename?: 'InvitationEdge'
+ cursor: Scalars['String']['output']
+ node: GQLInvitation
+}
- /**
- * Sent time.
- */
- sentAt: GQLDateTime
+export type GQLInvitationState =
+ | 'accepted'
+ | 'pending'
+ | 'transfer_failed'
+ | 'transfer_succeeded'
- /**
- * Accepted time.
- */
- acceptedAt?: GQLDateTime
+export type GQLInviteCircleInput = {
+ circleId: Scalars['ID']['input']
+ freePeriod: Scalars['Int']['input']
+ invitees: Array
+}
- /**
- * Determine it's specific state.
- */
- state: GQLInvitationState
+export type GQLInviteCircleInvitee = {
+ email?: InputMaybe
+ id?: InputMaybe
}
export type GQLInvitee = GQLPerson | GQLUser
-/** Use this to resolve union type Invitee */
-export type GQLPossibleInviteeTypeNames = 'Person' | 'User'
+export type GQLInvites = {
+ __typename?: 'Invites'
+ /** Accepted invitation list */
+ accepted: GQLInvitationConnection
+ /** Pending invitation list */
+ pending: GQLInvitationConnection
+}
-export interface GQLInviteeNameMap {
- Invitee: GQLInvitee
- Person: GQLPerson
- User: GQLUser
+export type GQLInvitesAcceptedArgs = {
+ input: GQLConnectionArgs
}
-export interface GQLPerson {
- email: GQLemail_String_NotNull_format_email
+export type GQLInvitesPendingArgs = {
+ input: GQLConnectionArgs
}
-export type GQLemail_String_NotNull_format_email = any
+export type GQLKeywordInput = {
+ keyword: Scalars['String']['input']
+}
-export const enum GQLInvitationState {
- accepted = 'accepted',
- pending = 'pending',
- transfer_succeeded = 'transfer_succeeded',
- transfer_failed = 'transfer_failed',
+export type GQLKeywordsInput = {
+ keywords?: InputMaybe>
}
-export interface GQLCircleAnalytics {
- income: GQLCircleIncomeAnalytics
- subscriber: GQLCircleSubscriberAnalytics
- follower: GQLCircleFollowerAnalytics
- content: GQLCircleContentAnalytics
+export type GQLLikeMomentInput = {
+ id: Scalars['ID']['input']
}
-export interface GQLCircleIncomeAnalytics {
+export type GQLLiker = {
+ __typename?: 'Liker'
+ /** Whether liker is a civic liker */
+ civicLiker: Scalars['Boolean']['output']
+ /** Liker ID of LikeCoin */
+ likerId?: Maybe
/**
- * income history of last 4 months
+ * Rate of LikeCoin/USD
+ * @deprecated No longer in use
*/
- history: Array
+ rateUSD?: Maybe
+ /** Total LIKE left in wallet. */
+ total: Scalars['Float']['output']
+}
- /**
- * total income of all time
- */
- total: number
+export type GQLLogRecordInput = {
+ type: GQLLogRecordTypes
+}
- /**
- * income of this month
- */
- thisMonth: number
+export type GQLLogRecordTypes =
+ | 'ReadFolloweeArticles'
+ | 'ReadFollowingFeed'
+ | 'ReadResponseInfoPopUp'
- /**
- * income of next month
- */
- nextMonth: number
+export type GQLMember = {
+ __typename?: 'Member'
+ /** Price chosen by user when joining a Circle. */
+ price: GQLPrice
+ /** User who join to a Circle. */
+ user: GQLUser
}
-export interface GQLMonthlyDatum {
- value: number
- date: GQLDateTime
+export type GQLMemberConnection = GQLConnection & {
+ __typename?: 'MemberConnection'
+ edges?: Maybe>
+ pageInfo: GQLPageInfo
+ totalCount: Scalars['Int']['output']
}
-export interface GQLCircleSubscriberAnalytics {
- /**
- * subscriber count history of last 4 months
- */
- subscriberHistory: Array