Show forum topics on homepage (#2562)

Signed-off-by: Daniel Gray <dngray@privacyguides.org>
This commit is contained in:
Jonah Aragon 2024-05-19 03:00:45 +00:00 committed by Daniel Gray
parent 2356a3a49b
commit 26f3300424
No known key found for this signature in database
GPG Key ID: 41911F722B0F9AE3
5 changed files with 358 additions and 122 deletions

232
Pipfile.lock generated
View File

@ -26,11 +26,11 @@
},
"cairocffi": {
"hashes": [
"sha256:78e6bbe47357640c453d0be929fa49cd05cce2e1286f3d2a1ca9cbda7efdb8b7",
"sha256:aa78ee52b9069d7475eeac457389b6275aa92111895d78fbaa2202a52dac112e"
"sha256:1f29a8d41dbda4090c0aa33bcdea64f3b493e95f74a43ea107c4a8a7b7f632ef",
"sha256:7761863603894305f3160eca68452f373433ca8745ab7dd445bd2c6ce50dcab7"
],
"markers": "python_version >= '3.7'",
"version": "==1.6.1"
"markers": "python_version >= '3.8'",
"version": "==1.7.0"
},
"cairosvg": {
"hashes": [
@ -258,11 +258,11 @@
},
"idna": {
"hashes": [
"sha256:9ecdbbd083b06798ae1e86adcbfe8ab1479cf864e4ee30fe4e46a003d12491ca",
"sha256:c05567e9c24a6b9faaa835c4821bad0590fbb9d5779e7caa6e1cc4978e7eb24f"
"sha256:028ff3aadf0609c1fd278d8ea3089299412a7a8b9bd005dd08b9f8285bcb5cfc",
"sha256:82fee1fc78add43492d3a1898bfa6d8a904cc97d8427f683ed8e798d07761aa0"
],
"markers": "python_version >= '3.5'",
"version": "==3.6"
"version": "==3.7"
},
"jieba": {
"hashes": [
@ -363,11 +363,19 @@
},
"mkdocs": {
"hashes": [
"sha256:3b3a78e736b31158d64dbb2f8ba29bd46a379d0c6e324c2246c3bc3d2189cfc1",
"sha256:eb7c99214dcb945313ba30426c2451b735992c73c2e10838f76d09e39ff4d0e2"
"sha256:1eb5cb7676b7d89323e62b56235010216319217d4af5ddc543a91beb8d125ea7",
"sha256:a73f735824ef83a4f3bcb7a231dcab23f5a838f88b7efc54a0eef5fbdbc3c512"
],
"markers": "python_version >= '3.7'",
"version": "==1.5.3"
"markers": "python_version >= '3.8'",
"version": "==1.6.0"
},
"mkdocs-get-deps": {
"hashes": [
"sha256:162b3d129c7fad9b19abfdcb9c1458a651628e4b1dea628ac68790fb3061c60c",
"sha256:2bf11d0b133e77a0dd036abeeb06dec8775e46efa526dc70667d8863eefc6134"
],
"markers": "python_version >= '3.8'",
"version": "==0.2.0"
},
"mkdocs-git-authors-plugin": {
"hashes": [
@ -380,12 +388,12 @@
},
"mkdocs-git-revision-date-localized-plugin": {
"hashes": [
"sha256:08fd0c6f33c8da9e00daf40f7865943113b3879a1c621b2bbf0fa794ffe997d3",
"sha256:1f94eb510862ef94e982a2910404fa17a1657ecf29f45a07b0f438c00767fc85"
"sha256:0c439816d9d0dba48e027d9d074b2b9f1d7cd179f74ba46b51e4da7bb3dc4b9b",
"sha256:d796a18b07cfcdb154c133e3ec099d2bb5f38389e4fd54d3eb516a8a736815b8"
],
"index": "pypi",
"markers": "python_version >= '3.8'",
"version": "==1.2.4"
"version": "==1.2.5"
},
"mkdocs-macros-plugin": {
"hashes": [
@ -509,11 +517,11 @@
},
"platformdirs": {
"hashes": [
"sha256:0614df2a2f37e1a662acbd8e2b25b92ccf8632929bc6d43467e17fe89c75e068",
"sha256:ef0cc731df711022c174543cb70a9b5bd22e5a9337c8624ef2c2ceb8ddad8768"
"sha256:031cd18d4ec63ec53e82dceaac0417d218a6863f7745dfcc9efe7793b7039bdf",
"sha256:17d5a1161b3fd67b390023cb2d3b026bbd40abde6fdb052dfbd3a29c3ba22ee1"
],
"markers": "python_version >= '3.8'",
"version": "==4.2.0"
"version": "==4.2.1"
},
"pycparser": {
"hashes": [
@ -533,11 +541,11 @@
},
"pymdown-extensions": {
"hashes": [
"sha256:c70e146bdd83c744ffc766b4671999796aba18842b268510a329f7f64700d584",
"sha256:f5cc7000d7ff0d1ce9395d216017fa4df3dde800afb1fb72d1c7d3fd35e710f4"
"sha256:3ab1db5c9e21728dabf75192d71471f8e50f216627e9a1fa9535ecb0231b9940",
"sha256:f938326115884f48c6059c67377c46cf631c733ef3629b6eed1349989d1b30cb"
],
"markers": "python_version >= '3.8'",
"version": "==10.7.1"
"version": "==10.8.1"
},
"python-dateutil": {
"hashes": [
@ -622,102 +630,88 @@
},
"regex": {
"hashes": [
"sha256:0694219a1d54336fd0445ea382d49d36882415c0134ee1e8332afd1529f0baa5",
"sha256:086dd15e9435b393ae06f96ab69ab2d333f5d65cbe65ca5a3ef0ec9564dfe770",
"sha256:094ba386bb5c01e54e14434d4caabf6583334090865b23ef58e0424a6286d3dc",
"sha256:09da66917262d9481c719599116c7dc0c321ffcec4b1f510c4f8a066f8768105",
"sha256:0ecf44ddf9171cd7566ef1768047f6e66975788258b1c6c6ca78098b95cf9a3d",
"sha256:0fda75704357805eb953a3ee15a2b240694a9a514548cd49b3c5124b4e2ad01b",
"sha256:11a963f8e25ab5c61348d090bf1b07f1953929c13bd2309a0662e9ff680763c9",
"sha256:150c39f5b964e4d7dba46a7962a088fbc91f06e606f023ce57bb347a3b2d4630",
"sha256:1b9d811f72210fa9306aeb88385b8f8bcef0dfbf3873410413c00aa94c56c2b6",
"sha256:1e0eabac536b4cc7f57a5f3d095bfa557860ab912f25965e08fe1545e2ed8b4c",
"sha256:22a86d9fff2009302c440b9d799ef2fe322416d2d58fc124b926aa89365ec482",
"sha256:22f3470f7524b6da61e2020672df2f3063676aff444db1daa283c2ea4ed259d6",
"sha256:263ef5cc10979837f243950637fffb06e8daed7f1ac1e39d5910fd29929e489a",
"sha256:283fc8eed679758de38fe493b7d7d84a198b558942b03f017b1f94dda8efae80",
"sha256:29171aa128da69afdf4bde412d5bedc335f2ca8fcfe4489038577d05f16181e5",
"sha256:298dc6354d414bc921581be85695d18912bea163a8b23cac9a2562bbcd5088b1",
"sha256:2aae8101919e8aa05ecfe6322b278f41ce2994c4a430303c4cd163fef746e04f",
"sha256:2f4e475a80ecbd15896a976aa0b386c5525d0ed34d5c600b6d3ebac0a67c7ddf",
"sha256:34e4af5b27232f68042aa40a91c3b9bb4da0eeb31b7632e0091afc4310afe6cb",
"sha256:37f8e93a81fc5e5bd8db7e10e62dc64261bcd88f8d7e6640aaebe9bc180d9ce2",
"sha256:3a17d3ede18f9cedcbe23d2daa8a2cd6f59fe2bf082c567e43083bba3fb00347",
"sha256:3b1de218d5375cd6ac4b5493e0b9f3df2be331e86520f23382f216c137913d20",
"sha256:43f7cd5754d02a56ae4ebb91b33461dc67be8e3e0153f593c509e21d219c5060",
"sha256:4558410b7a5607a645e9804a3e9dd509af12fb72b9825b13791a37cd417d73a5",
"sha256:4719bb05094d7d8563a450cf8738d2e1061420f79cfcc1fa7f0a44744c4d8f73",
"sha256:4bfc2b16e3ba8850e0e262467275dd4d62f0d045e0e9eda2bc65078c0110a11f",
"sha256:518440c991f514331f4850a63560321f833979d145d7d81186dbe2f19e27ae3d",
"sha256:51f4b32f793812714fd5307222a7f77e739b9bc566dc94a18126aba3b92b98a3",
"sha256:531ac6cf22b53e0696f8e1d56ce2396311254eb806111ddd3922c9d937151dae",
"sha256:5cd05d0f57846d8ba4b71d9c00f6f37d6b97d5e5ef8b3c3840426a475c8f70f4",
"sha256:5dd58946bce44b53b06d94aa95560d0b243eb2fe64227cba50017a8d8b3cd3e2",
"sha256:60080bb3d8617d96f0fb7e19796384cc2467447ef1c491694850ebd3670bc457",
"sha256:636ba0a77de609d6510235b7f0e77ec494d2657108f777e8765efc060094c98c",
"sha256:67d3ccfc590e5e7197750fcb3a2915b416a53e2de847a728cfa60141054123d4",
"sha256:68191f80a9bad283432385961d9efe09d783bcd36ed35a60fb1ff3f1ec2efe87",
"sha256:7502534e55c7c36c0978c91ba6f61703faf7ce733715ca48f499d3dbbd7657e0",
"sha256:7aa47c2e9ea33a4a2a05f40fcd3ea36d73853a2aae7b4feab6fc85f8bf2c9704",
"sha256:7d2af3f6b8419661a0c421584cfe8aaec1c0e435ce7e47ee2a97e344b98f794f",
"sha256:7e316026cc1095f2a3e8cc012822c99f413b702eaa2ca5408a513609488cb62f",
"sha256:88ad44e220e22b63b0f8f81f007e8abbb92874d8ced66f32571ef8beb0643b2b",
"sha256:88d1f7bef20c721359d8675f7d9f8e414ec5003d8f642fdfd8087777ff7f94b5",
"sha256:89723d2112697feaa320c9d351e5f5e7b841e83f8b143dba8e2d2b5f04e10923",
"sha256:8a0ccf52bb37d1a700375a6b395bff5dd15c50acb745f7db30415bae3c2b0715",
"sha256:8c2c19dae8a3eb0ea45a8448356ed561be843b13cbc34b840922ddf565498c1c",
"sha256:905466ad1702ed4acfd67a902af50b8db1feeb9781436372261808df7a2a7bca",
"sha256:9852b76ab558e45b20bf1893b59af64a28bd3820b0c2efc80e0a70a4a3ea51c1",
"sha256:98a2636994f943b871786c9e82bfe7883ecdaba2ef5df54e1450fa9869d1f756",
"sha256:9aa1a67bbf0f957bbe096375887b2505f5d8ae16bf04488e8b0f334c36e31360",
"sha256:9eda5f7a50141291beda3edd00abc2d4a5b16c29c92daf8d5bd76934150f3edc",
"sha256:a6d1047952c0b8104a1d371f88f4ab62e6275567d4458c1e26e9627ad489b445",
"sha256:a9b6d73353f777630626f403b0652055ebfe8ff142a44ec2cf18ae470395766e",
"sha256:a9cc99d6946d750eb75827cb53c4371b8b0fe89c733a94b1573c9dd16ea6c9e4",
"sha256:ad83e7545b4ab69216cef4cc47e344d19622e28aabec61574b20257c65466d6a",
"sha256:b014333bd0217ad3d54c143de9d4b9a3ca1c5a29a6d0d554952ea071cff0f1f8",
"sha256:b43523d7bc2abd757119dbfb38af91b5735eea45537ec6ec3a5ec3f9562a1c53",
"sha256:b521dcecebc5b978b447f0f69b5b7f3840eac454862270406a39837ffae4e697",
"sha256:b77e27b79448e34c2c51c09836033056a0547aa360c45eeeb67803da7b0eedaf",
"sha256:b7a635871143661feccce3979e1727c4e094f2bdfd3ec4b90dfd4f16f571a87a",
"sha256:b7fca9205b59c1a3d5031f7e64ed627a1074730a51c2a80e97653e3e9fa0d415",
"sha256:ba1b30765a55acf15dce3f364e4928b80858fa8f979ad41f862358939bdd1f2f",
"sha256:ba99d8077424501b9616b43a2d208095746fb1284fc5ba490139651f971d39d9",
"sha256:c25a8ad70e716f96e13a637802813f65d8a6760ef48672aa3502f4c24ea8b400",
"sha256:c3c4a78615b7762740531c27cf46e2f388d8d727d0c0c739e72048beb26c8a9d",
"sha256:c40281f7d70baf6e0db0c2f7472b31609f5bc2748fe7275ea65a0b4601d9b392",
"sha256:c7ad32824b7f02bb3c9f80306d405a1d9b7bb89362d68b3c5a9be53836caebdb",
"sha256:cb3fe77aec8f1995611f966d0c656fdce398317f850d0e6e7aebdfe61f40e1cd",
"sha256:cc038b2d8b1470364b1888a98fd22d616fba2b6309c5b5f181ad4483e0017861",
"sha256:cc37b9aeebab425f11f27e5e9e6cf580be7206c6582a64467a14dda211abc232",
"sha256:cc6bb9aa69aacf0f6032c307da718f61a40cf970849e471254e0e91c56ffca95",
"sha256:d126361607b33c4eb7b36debc173bf25d7805847346dd4d99b5499e1fef52bc7",
"sha256:d15b274f9e15b1a0b7a45d2ac86d1f634d983ca40d6b886721626c47a400bf39",
"sha256:d166eafc19f4718df38887b2bbe1467a4f74a9830e8605089ea7a30dd4da8887",
"sha256:d498eea3f581fbe1b34b59c697512a8baef88212f92e4c7830fcc1499f5b45a5",
"sha256:d6f7e255e5fa94642a0724e35406e6cb7001c09d476ab5fce002f652b36d0c39",
"sha256:d78bd484930c1da2b9679290a41cdb25cc127d783768a0369d6b449e72f88beb",
"sha256:d865984b3f71f6d0af64d0d88f5733521698f6c16f445bb09ce746c92c97c586",
"sha256:d902a43085a308cef32c0d3aea962524b725403fd9373dea18110904003bac97",
"sha256:d94a1db462d5690ebf6ae86d11c5e420042b9898af5dcf278bd97d6bda065423",
"sha256:da695d75ac97cb1cd725adac136d25ca687da4536154cdc2815f576e4da11c69",
"sha256:db2a0b1857f18b11e3b0e54ddfefc96af46b0896fb678c85f63fb8c37518b3e7",
"sha256:df26481f0c7a3f8739fecb3e81bc9da3fcfae34d6c094563b9d4670b047312e1",
"sha256:e14b73607d6231f3cc4622809c196b540a6a44e903bcfad940779c80dffa7be7",
"sha256:e2610e9406d3b0073636a3a2e80db05a02f0c3169b5632022b4e81c0364bcda5",
"sha256:e692296c4cc2873967771345a876bcfc1c547e8dd695c6b89342488b0ea55cd8",
"sha256:e693e233ac92ba83a87024e1d32b5f9ab15ca55ddd916d878146f4e3406b5c91",
"sha256:e81469f7d01efed9b53740aedd26085f20d49da65f9c1f41e822a33992cb1590",
"sha256:e8c7e08bb566de4faaf11984af13f6bcf6a08f327b13631d41d62592681d24fe",
"sha256:ed19b3a05ae0c97dd8f75a5d8f21f7723a8c33bbc555da6bbe1f96c470139d3c",
"sha256:efb2d82f33b2212898f1659fb1c2e9ac30493ac41e4d53123da374c3b5541e64",
"sha256:f44dd4d68697559d007462b0a3a1d9acd61d97072b71f6d1968daef26bc744bd",
"sha256:f72cbae7f6b01591f90814250e636065850c5926751af02bb48da94dfced7baa",
"sha256:f7bc09bc9c29ebead055bcba136a67378f03d66bf359e87d0f7c759d6d4ffa31",
"sha256:ff100b203092af77d1a5a7abe085b3506b7eaaf9abf65b73b7d6905b6cb76988"
"sha256:05d9b6578a22db7dedb4df81451f360395828b04f4513980b6bd7a1412c679cc",
"sha256:08a1749f04fee2811c7617fdd46d2e46d09106fa8f475c884b65c01326eb15c5",
"sha256:0940038bec2fe9e26b203d636c44d31dd8766abc1fe66262da6484bd82461ccf",
"sha256:0a2a512d623f1f2d01d881513af9fc6a7c46e5cfffb7dc50c38ce959f9246c94",
"sha256:0a54a047b607fd2d2d52a05e6ad294602f1e0dec2291152b745870afc47c1397",
"sha256:0dd3f69098511e71880fb00f5815db9ed0ef62c05775395968299cb400aeab82",
"sha256:1031a5e7b048ee371ab3653aad3030ecfad6ee9ecdc85f0242c57751a05b0ac4",
"sha256:108e2dcf0b53a7c4ab8986842a8edcb8ab2e59919a74ff51c296772e8e74d0ae",
"sha256:144a1fc54765f5c5c36d6d4b073299832aa1ec6a746a6452c3ee7b46b3d3b11d",
"sha256:19d6c11bf35a6ad077eb23852827f91c804eeb71ecb85db4ee1386825b9dc4db",
"sha256:1f687a28640f763f23f8a9801fe9e1b37338bb1ca5d564ddd41619458f1f22d1",
"sha256:224803b74aab56aa7be313f92a8d9911dcade37e5f167db62a738d0c85fdac4b",
"sha256:23a412b7b1a7063f81a742463f38821097b6a37ce1e5b89dd8e871d14dbfd86b",
"sha256:25f87ae6b96374db20f180eab083aafe419b194e96e4f282c40191e71980c666",
"sha256:2630ca4e152c221072fd4a56d4622b5ada876f668ecd24d5ab62544ae6793ed6",
"sha256:28e1f28d07220c0f3da0e8fcd5a115bbb53f8b55cecf9bec0c946eb9a059a94c",
"sha256:2b51739ddfd013c6f657b55a508de8b9ea78b56d22b236052c3a85a675102dc6",
"sha256:2cc1b87bba1dd1a898e664a31012725e48af826bf3971e786c53e32e02adae6c",
"sha256:2fef0b38c34ae675fcbb1b5db760d40c3fc3612cfa186e9e50df5782cac02bcd",
"sha256:36f392dc7763fe7924575475736bddf9ab9f7a66b920932d0ea50c2ded2f5636",
"sha256:374f690e1dd0dbdcddea4a5c9bdd97632cf656c69113f7cd6a361f2a67221cb6",
"sha256:3986217ec830c2109875be740531feb8ddafe0dfa49767cdcd072ed7e8927962",
"sha256:39fb166d2196413bead229cd64a2ffd6ec78ebab83fff7d2701103cf9f4dfd26",
"sha256:4290035b169578ffbbfa50d904d26bec16a94526071ebec3dadbebf67a26b25e",
"sha256:43548ad74ea50456e1c68d3c67fff3de64c6edb85bcd511d1136f9b5376fc9d1",
"sha256:44a22ae1cfd82e4ffa2066eb3390777dc79468f866f0625261a93e44cdf6482b",
"sha256:457c2cd5a646dd4ed536c92b535d73548fb8e216ebee602aa9f48e068fc393f3",
"sha256:459226445c7d7454981c4c0ce0ad1a72e1e751c3e417f305722bbcee6697e06a",
"sha256:47af45b6153522733aa6e92543938e97a70ce0900649ba626cf5aad290b737b6",
"sha256:499334ad139557de97cbc4347ee921c0e2b5e9c0f009859e74f3f77918339257",
"sha256:57ba112e5530530fd175ed550373eb263db4ca98b5f00694d73b18b9a02e7185",
"sha256:5ce479ecc068bc2a74cb98dd8dba99e070d1b2f4a8371a7dfe631f85db70fe6e",
"sha256:5dbc1bcc7413eebe5f18196e22804a3be1bfdfc7e2afd415e12c068624d48247",
"sha256:6277d426e2f31bdbacb377d17a7475e32b2d7d1f02faaecc48d8e370c6a3ff31",
"sha256:66372c2a01782c5fe8e04bff4a2a0121a9897e19223d9eab30c54c50b2ebeb7f",
"sha256:670fa596984b08a4a769491cbdf22350431970d0112e03d7e4eeaecaafcd0fec",
"sha256:6f435946b7bf7a1b438b4e6b149b947c837cb23c704e780c19ba3e6855dbbdd3",
"sha256:7413167c507a768eafb5424413c5b2f515c606be5bb4ef8c5dee43925aa5718b",
"sha256:7c3d389e8d76a49923683123730c33e9553063d9041658f23897f0b396b2386f",
"sha256:7d77b6f63f806578c604dca209280e4c54f0fa9a8128bb8d2cc5fb6f99da4150",
"sha256:7e76b9cfbf5ced1aca15a0e5b6f229344d9b3123439ffce552b11faab0114a02",
"sha256:7f3502f03b4da52bbe8ba962621daa846f38489cae5c4a7b5d738f15f6443d17",
"sha256:7fe9739a686dc44733d52d6e4f7b9c77b285e49edf8570754b322bca6b85b4cc",
"sha256:83ab366777ea45d58f72593adf35d36ca911ea8bd838483c1823b883a121b0e4",
"sha256:84077821c85f222362b72fdc44f7a3a13587a013a45cf14534df1cbbdc9a6796",
"sha256:8bb381f777351bd534462f63e1c6afb10a7caa9fa2a421ae22c26e796fe31b1f",
"sha256:92da587eee39a52c91aebea8b850e4e4f095fe5928d415cb7ed656b3460ae79a",
"sha256:9301cc6db4d83d2c0719f7fcda37229691745168bf6ae849bea2e85fc769175d",
"sha256:965fd0cf4694d76f6564896b422724ec7b959ef927a7cb187fc6b3f4e4f59833",
"sha256:99d6a550425cc51c656331af0e2b1651e90eaaa23fb4acde577cf15068e2e20f",
"sha256:99ef6289b62042500d581170d06e17f5353b111a15aa6b25b05b91c6886df8fc",
"sha256:a1409c4eccb6981c7baabc8888d3550df518add6e06fe74fa1d9312c1838652d",
"sha256:a74fcf77d979364f9b69fcf8200849ca29a374973dc193a7317698aa37d8b01c",
"sha256:aaa179975a64790c1f2701ac562b5eeb733946eeb036b5bcca05c8d928a62f10",
"sha256:ac69b394764bb857429b031d29d9604842bc4cbfd964d764b1af1868eeebc4f0",
"sha256:b45d4503de8f4f3dc02f1d28a9b039e5504a02cc18906cfe744c11def942e9eb",
"sha256:b7d893c8cf0e2429b823ef1a1d360a25950ed11f0e2a9df2b5198821832e1947",
"sha256:b8eb28995771c087a73338f695a08c9abfdf723d185e57b97f6175c5051ff1ae",
"sha256:b91d529b47798c016d4b4c1d06cc826ac40d196da54f0de3c519f5a297c5076a",
"sha256:bc365ce25f6c7c5ed70e4bc674f9137f52b7dd6a125037f9132a7be52b8a252f",
"sha256:bf29304a8011feb58913c382902fde3395957a47645bf848eea695839aa101b7",
"sha256:c06bf3f38f0707592898428636cbb75d0a846651b053a1cf748763e3063a6925",
"sha256:c77d10ec3c1cf328b2f501ca32583625987ea0f23a0c2a49b37a39ee5c4c4630",
"sha256:cd196d056b40af073d95a2879678585f0b74ad35190fac04ca67954c582c6b61",
"sha256:d7a353ebfa7154c871a35caca7bfd8f9e18666829a1dc187115b80e35a29393e",
"sha256:d84308f097d7a513359757c69707ad339da799e53b7393819ec2ea36bc4beb58",
"sha256:dd7ef715ccb8040954d44cfeff17e6b8e9f79c8019daae2fd30a8806ef5435c0",
"sha256:e672cf9caaf669053121f1766d659a8813bd547edef6e009205378faf45c67b8",
"sha256:ecc6148228c9ae25ce403eade13a0961de1cb016bdb35c6eafd8e7b87ad028b1",
"sha256:f1c5742c31ba7d72f2dedf7968998730664b45e38827637e0f04a2ac7de2f5f1",
"sha256:f1d6e4b7b2ae3a6a9df53efbf199e4bfcff0959dbdb5fd9ced34d4407348e39a",
"sha256:f2fc053228a6bd3a17a9b0a3f15c3ab3cf95727b00557e92e1cfe094b88cc662",
"sha256:f57515750d07e14743db55d59759893fdb21d2668f39e549a7d6cad5d70f9fea",
"sha256:f85151ec5a232335f1be022b09fbbe459042ea1951d8a48fef251223fc67eee1",
"sha256:fb0315a2b26fde4005a7c401707c5352df274460f2f85b209cf6024271373013",
"sha256:fc0916c4295c64d6890a46e02d4482bb5ccf33bf1a824c0eaa9e83b148291f90",
"sha256:fd24fd140b69f0b0bcc9165c397e9b2e89ecbeda83303abf2a072609f60239e2",
"sha256:fdae0120cddc839eb8e3c15faa8ad541cc6d906d3eb24d82fb041cfe2807bc1e",
"sha256:fe00f4fe11c8a521b173e6324d862ee7ee3412bf7107570c9b564fe1119b56fb"
],
"markers": "python_version >= '3.7'",
"version": "==2023.12.25"
"markers": "python_version >= '3.8'",
"version": "==2024.4.28"
},
"requests": {
"hashes": [
@ -753,11 +747,11 @@
},
"tinycss2": {
"hashes": [
"sha256:2b80a96d41e7c3914b8cda8bc7f705a4d9c49275616e886103dd839dfc847847",
"sha256:8cff3a8f066c2ec677c06dbc7b45619804a6938478d9d73c284b29d14ecb0627"
"sha256:152f9acabd296a8375fbca5b84c961ff95971fcfc32e79550c8df8e29118c54d",
"sha256:54a8dbdffb334d536851be0226030e9505965bb2f30f21a4a82c55fb2a80fae7"
],
"markers": "python_version >= '3.7'",
"version": "==1.2.1"
"markers": "python_version >= '3.8'",
"version": "==1.3.0"
},
"urllib3": {
"hashes": [

@ -1 +1 @@
Subproject commit 2ab4dc8ce4f249164ac1d8d3e46a12c5c0b71230
Subproject commit e02ab721aa9fafe7785f9ce2f53fe9675d57d351

View File

@ -0,0 +1,149 @@
/**
* @overview Generates a list of topics on a Discourse forum.
* @author Jonah Aragon <jonah@triplebit.net>
* @version 3.0.0
* @license
* Copyright (c) 2023 - 2024 Jonah Aragon
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
* in the Software without restriction, including without limitation the rights
* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
* copies of the Software, and to permit persons to whom the Software is
* furnished to do so, subject to the following conditions:
*
* The above copyright notice and this permission notice shall be included in all
* copies or substantial portions of the Software.
*
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
* SOFTWARE.
*/
async function getData(url) {
const response = await fetch(url);
return response.json()
}
async function main() {
const elements = document.querySelectorAll("div[data-forum]");
for (let j = 0; j < elements.length; j++) {
var topics = elements[j];
var dataset = topics.dataset;
console.log("Fetching data from " + dataset.feed)
const data = await getData(dataset.feed);
var list = data['topic_list']['topics'];
var profiles = data['users'];
var count = dataset.count;
for (var i = 0; i < count; i++) {
if (list[i]['pinned'] == true) {
count++;
continue;
}
var title = list[i]['title'];
var id = list[i]['id'];
var topic = document.createElement("div");
topic.className = "discourse-topic";
var h3 = document.createElement('p');
h3.className = "discourse-title";
var a1 = document.createElement('a');
a1.href = dataset.forum + '/t/' + id;
a1.innerText = title;
h3.appendChild(a1);
var postinfo = document.createElement('ul');
postinfo.className = "discourse-data";
var date = document.createElement('li');
date.className = "discourse-date";
var datestring = list[i]['bumped_at'];
var dateobject = new Date(datestring);
var now = new Date();
var diff = now - dateobject;
var minutes = Math.floor(diff / 60000);
var hours = Math.floor(minutes / 60);
var days = Math.floor(hours / 24);
if (days > 0) {
if (days == 1) {
date.innerText = "Last reply 1 day ago";
}
else {
date.innerText = "Last reply " + days + " days ago";
}
}
else if (hours > 0){
if (hours == 1) {
date.innerText = "Last reply 1 hour ago";
}
else {
date.innerText = "Last reply "+ hours + " hours ago";
}
}
else {
if (minutes == 1) {
date.innerText = "Last reply 1 minute ago";
}
else {
date.innerText = "Last reply " + minutes + " minutes ago";
}
}
postinfo.appendChild(date);
var author_id = list[i]['posters'][0]['user_id'];
var author_data = profiles.find(profile => profile['id'] == author_id);
var author = document.createElement('li');
author.className = "discourse-author";
var avatar = document.createElement('img');
avatar.src = dataset.forum + author_data['avatar_template'].replace("{size}", "40");
avatar.width = 20;
avatar.height = 20;
author.appendChild(avatar);
var namespan = document.createElement('span');
namespan.innerText = " " + author_data['username'];
author.appendChild(namespan);
postinfo.appendChild(author);
var likes = document.createElement('li');
likes.className = "discourse-likes";
if (list[i]['like_count'] == 1) {
likes.innerText = "1 Like";
}
else {
likes.innerText = list[i]['like_count'] + " Likes";
}
postinfo.appendChild(likes);
var replies = document.createElement('li');
replies.className = "discourse-replies";
var reply_count = list[i]['posts_count'] - 1;
if (reply_count == 1) {
replies.innerText = "1 Reply"
}
else {
replies.innerText = reply_count + " Replies"
}
postinfo.appendChild(replies);
topic.appendChild(h3);
topic.appendChild(postinfo);
topics.appendChild(topic);
}
}
}
main();

View File

@ -114,7 +114,7 @@ article.md-content__inner > * {
margin-right: 0;
text-align: right;
} */
#what-should-i-do, #what-should-i-do ~ :not( .mdx-cat ~ * ):not( .mdx-cta ) {
#what-should-i-do, #what-should-i-do ~ :not( .mdx-cat ~ * ):not( .mdx-cta ):not( .mdx-discourse-topics) {
margin-left: auto;
margin-right: 0;
text-align: right;
@ -134,3 +134,56 @@ article.md-content__inner > hr {
--md-icon-size: 1.8em;
margin: 0.4rem;
}
.mdx-discourse-topics {
max-width: 100% !important;
margin-left: auto;
margin-right: auto;
text-align: center;
}
.mdx-discourse-topics .topics-list {
grid-template-columns: repeat(5, 1fr);
}
.mdx-discourse-topics .discourse-title {
min-height: 4em;
}
.mdx-discourse-topics .topics-list {
display: grid;
text-align: left;
}
.mdx-discourse-topics .topics-list .discourse-title {
line-height: 1.2;
margin: 0;
}
.mdx-discourse-topics .topics-list .discourse-topic {
padding: 0.4em;
margin-bottom: 1em;
}
.mdx-discourse-topics .topics-list .discourse-data {
color: var(--md-default-fg-color--light);
list-style: none;
padding: 0;
margin: 0;
}
.mdx-discourse-topics .topics-list .discourse-data li {
margin: 0;
}
.mdx-discourse-topics .topics-list .discourse-data li img {
vertical-align: middle;
}
@media screen and (max-width: 1000px) {
.mdx-discourse-topics .topics-list {
grid-template-columns: repeat(3, 1fr);
}
.mdx-discourse-topics .topics-list .discourse-title {
min-height: 0;
}
}
@media screen and (max-width: 600px) {
.mdx-discourse-topics .topics-list {
grid-template-columns: repeat(1, 1fr);
}
.mdx-discourse-topics .topics-list .discourse-title {
min-height: 0;
}
}

View File

@ -23,7 +23,7 @@
{% extends "main.html" %}
{% set homepage = config.extra.privacy_guides.homepage %}
{% block extrahead %}
<link rel="stylesheet" href="{{ 'assets/stylesheets/home.css?v=3.3.0' | url }}">
<link rel="stylesheet" href="{{ 'assets/stylesheets/home.css?v=20240501' | url }}">
{% for feed in homepage.rss %}
<link rel="alternate" type="application/rss+xml" title="{{ feed.title }}" href="{{ feed.link }}">
{% endfor %}
@ -49,6 +49,24 @@
</section>
{% endblock %}
{% block content %}
{% if config.theme.language == "en" %}
<div class="mdx-discourse-topics">
<h2>Top discussions this week</h2>
<div
class="topics-list"
data-forum="https://discuss.privacyguides.net"
data-feed="https://discuss.privacyguides.net/top.json?period=weekly"
data-count="5">
</div>
<noscript>
<a href="https://discuss.privacyguides.net/" class="md-button md-button--primary">
Join the forum
</a>
</noscript>
<hr />
</div>
{% endif %}
{{ page.content }}
<div class="mdx-cta">
<hr />
@ -62,4 +80,26 @@
<p>{{ cta.description }}</p>
{% endfor %}
</div>
{% if config.theme.language == "en" %}
<div class="mdx-discourse-topics">
<h3>Join a discussion</h3>
<div
class="topics-list"
data-forum="https://discuss.privacyguides.net"
data-feed="https://discuss.privacyguides.net/latest.json"
data-count="15">
</div>
<noscript>
<a href="https://discuss.privacyguides.net/" class="md-button md-button--primary">
Join the forum
</a>
</noscript>
<hr />
</div>
{% endif %}
{% endblock %}
{% block scripts %}
<script src="{{ 'assets/javascripts/discourse-topics.js' | url }}"></script>
{{ super() }}
{% endblock %}